aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorLibravatar Titus Wormer <tituswormer@gmail.com>2022-07-11 14:53:45 +0200
committerLibravatar Titus Wormer <tituswormer@gmail.com>2022-07-11 15:04:32 +0200
commitb7bd2b734fae09c40d738fcd57d5ee6876f0f504 (patch)
treeea3b7dc9b6e668823323187dbe2f2030d6965905 /tests
parent8e78fc8f209d20e8f9a76321fcbebf77fa4c57fc (diff)
downloadmarkdown-rs-b7bd2b734fae09c40d738fcd57d5ee6876f0f504.tar.gz
markdown-rs-b7bd2b734fae09c40d738fcd57d5ee6876f0f504.tar.bz2
markdown-rs-b7bd2b734fae09c40d738fcd57d5ee6876f0f504.zip
Fix block quote bugs
Diffstat (limited to 'tests')
-rw-r--r--tests/block_quote.rs11
-rw-r--r--tests/code_fenced.rs11
-rw-r--r--tests/code_indented.rs39
3 files changed, 28 insertions, 33 deletions
diff --git a/tests/block_quote.rs b/tests/block_quote.rs
index 5e5adce..c0b10b7 100644
--- a/tests/block_quote.rs
+++ b/tests/block_quote.rs
@@ -67,12 +67,11 @@ fn block_quote() {
// "should not support lazy lists in block quotes"
// );
- // To do: block quote (lazy, code (indented), some bug).
- // assert_eq!(
- // micromark("> a\n b"),
- // "<blockquote>\n<pre><code>a\n</code></pre>\n</blockquote>\n<pre><code>b\n</code></pre>",
- // "should not support lazy indented code in block quotes"
- // );
+ assert_eq!(
+ micromark("> a\n b"),
+ "<blockquote>\n<pre><code>a\n</code></pre>\n</blockquote>\n<pre><code>b\n</code></pre>",
+ "should not support lazy indented code in block quotes"
+ );
assert_eq!(
micromark("> ```\na\n```"),
diff --git a/tests/code_fenced.rs b/tests/code_fenced.rs
index a777f9f..fa9ed5f 100644
--- a/tests/code_fenced.rs
+++ b/tests/code_fenced.rs
@@ -226,12 +226,11 @@ fn code_fenced() {
"should not support a closing sequence w/ too much indent, regardless of opening sequence (1)"
);
- // To do: blockquote (fix compiler).
- // assert_eq!(
- // micromark("> ```\n>\n>\n>\n\na"),
- // "<blockquote>\n<pre><code>\n\n\n</code></pre>\n</blockquote>\n<p>a</p>",
- // "should not support a closing sequence w/ too much indent, regardless of opening sequence (2)"
- // );
+ assert_eq!(
+ micromark("> ```\n>\n>\n>\n\na"),
+ "<blockquote>\n<pre><code>\n\n\n</code></pre>\n</blockquote>\n<p>a</p>",
+ "should not support a closing sequence w/ too much indent, regardless of opening sequence (2)"
+ );
assert_eq!(
micromark("> ```a\nb"),
diff --git a/tests/code_indented.rs b/tests/code_indented.rs
index f06cf4c..f462792 100644
--- a/tests/code_indented.rs
+++ b/tests/code_indented.rs
@@ -82,47 +82,44 @@ fn code_indented() {
"should not support lazyness (1)"
);
- // To do: blockquote (lazy, some bug).
+ // To do: blockquote (lazy).
// assert_eq!(
// micromark("> a\n b"),
// "<blockquote>\n<p>a\nb</p>\n</blockquote>",
// "should not support lazyness (2)"
// );
- // To do: blockquote (lazy, some bug).
+ // To do: blockquote (lazy).
// assert_eq!(
// micromark("> a\n b"),
// "<blockquote>\n<p>a\nb</p>\n</blockquote>",
// "should not support lazyness (3)"
// );
- // To do: blockquote (lazy, some bug).
+ // To do: blockquote (lazy).
// assert_eq!(
// micromark("> a\n b"),
// "<blockquote>\n<p>a\nb</p>\n</blockquote>",
// "should not support lazyness (4)"
// );
- // To do: blockquote (lazy, some bug).
- // assert_eq!(
- // micromark("> a\n b"),
- // "<blockquote>\n<pre><code>a\n</code></pre>\n</blockquote>\n<pre><code>b\n</code></pre>",
- // "should not support lazyness (5)"
- // );
+ assert_eq!(
+ micromark("> a\n b"),
+ "<blockquote>\n<pre><code>a\n</code></pre>\n</blockquote>\n<pre><code>b\n</code></pre>",
+ "should not support lazyness (5)"
+ );
- // To do: blockquote (lazy, some bug).
- // assert_eq!(
- // micromark("> a\n b"),
- // "<blockquote>\n<pre><code>a\n</code></pre>\n</blockquote>\n<pre><code> b\n</code></pre>",
- // "should not support lazyness (6)"
- // );
+ assert_eq!(
+ micromark("> a\n b"),
+ "<blockquote>\n<pre><code>a\n</code></pre>\n</blockquote>\n<pre><code> b\n</code></pre>",
+ "should not support lazyness (6)"
+ );
- // To do: blockquote (lazy, some bug).
- // assert_eq!(
- // micromark("> a\n b"),
- // "<blockquote>\n<pre><code>a\n</code></pre>\n</blockquote>\n<pre><code> b\n</code></pre>",
- // "should not support lazyness (7)"
- // );
+ assert_eq!(
+ micromark("> a\n b"),
+ "<blockquote>\n<pre><code>a\n</code></pre>\n</blockquote>\n<pre><code> b\n</code></pre>",
+ "should not support lazyness (7)"
+ );
// To do: turning things off.
// assert_eq!(