From bff5ee3fcd562d662d01b974f70ac0b8651e8ff0 Mon Sep 17 00:00:00 2001 From: Alex Bethel Date: Sat, 27 Nov 2021 21:39:41 -0700 Subject: [PATCH] Fix alt header test --- src/lib.rs | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/src/lib.rs b/src/lib.rs index a7fbe1e..fc1415d 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -265,9 +265,12 @@ Paragraph 4", let doc = parse( "\ Text -Header ------- -More text", +Header 1 +======== +More text +Header 2 +-------- +", ); let doc_ref = Document(vec![ Node::Paragraph(vec![StyledText { @@ -278,7 +281,7 @@ More text", text: "Text".to_string(), }]), Node::Header(Header { - label: "Header".to_string(), + label: "Header 1".to_string(), level: 1, }), Node::Paragraph(vec![StyledText { @@ -288,6 +291,10 @@ More text", color: None, text: "More text".to_string(), }]), + Node::Header(Header { + label: "Header 2".to_string(), + level: 2, + }), ]); assert_eq!(doc, doc_ref);