From 1d92666865b35341e076efbefddf6e73b5e1542e Mon Sep 17 00:00:00 2001
From: Titus Wormer A call.1 Noot.1 A paragraph. a[^b] a1 !^a !^a !^ Call.1. Call.1. Call.1. Call.1. Call.[^a+b]. Call.[^a[b]. 1. 1. 1. 1.Footnotes
@@ -28,6 +28,7 @@ fn gfm_footnote() {
",
"should support footnotes"
);
+
assert_eq!(
micromark_with_options(
"Noot.[^a]\n\n[^a]: dingen",
@@ -37,7 +38,7 @@ fn gfm_footnote() {
gfm_footnote_back_label: Some("Terug naar de inhoud".to_string()),
..Options::default()
}
- ),
+ )?,
"
Voetnoten
@@ -58,7 +59,7 @@ fn gfm_footnote() {
gfm_footnote_label_tag_name: Some("h1".to_string()),
..Options::default()
}
- ),
+ )?,
"
Footnotes
@@ -79,7 +80,7 @@ fn gfm_footnote() {
gfm_footnote_label_attributes: Some("class=\"footnote-heading\"".to_string()),
..Options::default()
}
- ),
+ )?,
"
Footnotes
@@ -100,7 +101,7 @@ fn gfm_footnote() {
gfm_footnote_clobber_prefix: Some("".to_string()),
..Options::default()
}
- ),
+ )?,
"
Footnotes
@@ -114,19 +115,19 @@ fn gfm_footnote() {
);
assert_eq!(
- micromark_with_options("A paragraph.\n\n[^a]: whatevs", &gfm),
+ micromark_with_options("A paragraph.\n\n[^a]: whatevs", &gfm)?,
"
Footnotes
@@ -140,7 +141,7 @@ fn gfm_footnote() {
);
assert_eq!(
- micromark_with_options("a[^b], c[^b]\n\n[^b]: d", &gfm),
+ micromark_with_options("a[^b], c[^b]\n\n[^b]: d", &gfm)?,
"
Footnotes
@@ -154,32 +155,32 @@ fn gfm_footnote() {
);
assert_eq!(
- micromark_with_options("![^a](b)", &gfm),
+ micromark_with_options("![^a](b)", &gfm)?,
"
Footnotes
@@ -193,7 +194,7 @@ fn gfm_footnote() {
);
assert_eq!(
- micromark_with_options("Call.[^a©b].\n\n[^a©b]: y", &gfm),
+ micromark_with_options("Call.[^a©b].\n\n[^a©b]: y", &gfm)?,
"
Footnotes
@@ -209,7 +210,7 @@ fn gfm_footnote() {
//
Footnotes
@@ -223,7 +224,7 @@ fn gfm_footnote() {
);
assert_eq!(
- micromark_with_options("Call.[^a[b].\n\n[^a[b]: y", &gfm),
+ micromark_with_options("Call.[^a[b].\n\n[^a[b]: y", &gfm)?,
"
Footnotes
@@ -237,19 +238,19 @@ fn gfm_footnote() {
);
assert_eq!(
- micromark_with_options("Call.[^a\\+b].\n\n[^a+b]: y", &gfm),
+ micromark_with_options("Call.[^a\\+b].\n\n[^a+b]: y", &gfm)?,
"
Footnotes
@@ -264,7 +265,7 @@ b [^1]: a\nb", &gfm),
+ micromark_with_options("[^1].\n\n> [^1]: a\nb", &gfm)?,
"
@@ -281,7 +282,7 @@ b [^1]: a\n> b", &gfm),
+ micromark_with_options("[^1].\n\n> [^1]: a\n> b", &gfm)?,
"
@@ -298,7 +299,7 @@ b b", &gfm),
+ micromark_with_options("[^1].\n\n[^1]: a\n\n > b", &gfm)?,
"Footnotes
[^a{}]: y
", max, max), "should not support 1000 characters in a call / definition" ); @@ -354,7 +355,7 @@ a![^1] [i]: c"###, &gfm - ), + )?, r###"a a!i a @@ -373,7 +374,7 @@ a!a![^1]
", "should match bang/caret interplay (undefined) like GitHub" ); @@ -385,7 +386,7 @@ a!a!1Calls may not be empty: ^.
Calls cannot contain whitespace only: ^ .
Calls cannot contain whitespace at all: ^ , ^ , ^ @@ -482,7 +483,7 @@ even another caret.
[^![image](#)]: a "###, &gfm - ), + )?, // Note: // * GH does not support colons. // See:More.
@@ -598,7 +599,7 @@ even another caret. - list "###, &gfm - ), + )?, r###"Heading
@@ -655,7 +656,7 @@ Lazy? Lazy! "###, &gfm - ), + )?, r###"Lazy?
Lazy!
@@ -711,7 +712,7 @@ Lazy! [^10]:- - - kilo "###, &gfm - ), + )?, r###"Footnotes
@@ -784,7 +785,7 @@ indented delta Call11
Footnotes
@@ -806,7 +807,7 @@ indented delta Call1
Footnotes
@@ -848,7 +849,7 @@ indented delta emphasis1
strong2
@@ -885,7 +886,7 @@ indented delta What are these!1, !2[], and ![this]3.
code[^3]
Footnotes
@@ -927,7 +928,7 @@ indented delta 123456
Heading
@@ -980,7 +981,7 @@ indented delta What are these1, 2[], and [this]3.Footnotes
@@ -1030,7 +1031,7 @@ indented delta 1234
Heading
@@ -1092,7 +1093,7 @@ indented delta 1234Footnotes
@@ -1141,7 +1142,7 @@ more code [^3]: [^4]: Paragraph "###, &gfm - ), + )?, r###"
@@ -1191,7 +1192,7 @@ more code - list "###, &gfm - ), + )?, r###"
Heading
@@ -1245,7 +1246,7 @@ more code - list "###, &gfm - ), + )?, r###"Footnotes
@@ -1303,7 +1304,7 @@ This paragraph won’t be part of the note, because it isn’t indented. "###, &gfm - ), + )?, r###"
Here is a footnote reference,1 and another.2
This paragraph won’t be part of the note, because it isn’t indented.
@@ -1371,7 +1372,7 @@ multi-paragraph list items. Call[^1][^2]12345678910.[^1]: 5 @@ -1463,7 +1464,7 @@ multi-paragraph list items. Call123456789.
3
2
@@ -1522,9 +1523,11 @@ multi-paragraph list items. Here is a short reference,1, a collapsed one,2, and a full one. "###, "should match references and definitions like GitHub" ); + + Ok(()) } -- cgit