use super::*; #[test] fn greentext_preserved() { html_opts!( [extension.greentext, render.hardbreaks], ">implying\n>>implying", "
>implying
\n>>implying
>
\n"); } #[test] fn separate_quotes_on_line_end() { html_opts!( [extension.greentext], "> 1\n>\n> 2", "\n\n" ); } #[test] fn unnest_quotes_on_line_end() { html_opts!( [extension.greentext], "> 1\n> > 2\n> 1", "1
\n2
\n
\n\n" ); } #[test] fn unnest_quotes_on_line_end_commonmark() { html_opts!( [extension.greentext], "> 1\n> > 2\n> \n> 1", "1
\n\n\n2
\n1
\n
\n\n" ); } #[test] fn greentext_disabled_blockquote() { assert_ast_match!( [], "> First line.\n> The second sentence in the first line.\n>\n> Second line.", (document (1:1-4:14) [ (block_quote (1:1-4:14) [ (paragraph (1:3-2:40) [ (text (1:3-1:13) "First line.") (softbreak (1:14-1:14)) (text (2:3-2:40) "The second sentence in the first line.") ]) (paragraph (4:3-4:14) [ (text (4:3-4:14) "Second line.") ]) ]) ]) ); } #[test] fn greentext_enabled_blockquote() { assert_ast_match!( [extension.greentext], "> First line.\n> The second sentence in the first line.\n>\n> Second line.", (document (1:1-4:14) [ (block_quote (1:1-4:14) [ (paragraph (1:3-2:40) [ (text (1:3-1:13) "First line.") (softbreak (1:14-1:14)) (text (2:3-2:40) "The second sentence in the first line.") ]) (paragraph (4:3-4:14) [ (text (4:3-4:14) "Second line.") ]) ]) ]) ); } #[test] fn greentext_disabled_blockquote_alerts() { html_opts!( [extension.alerts], "> [!Note]\n> This is the first line.\n>\n> Second line.", concat!( "1
\n\n\n2
\n1
\n
Note
\n", "This is the first line.
\n", "Second line.
\n", "Note
\n", "This is the first line.
\n", "Second line.
\n", "