use super::*;
#[test]
fn test_simple_ordered_lists()
{
test_html_compile!(
"1. Item 1\n",
"2. Item 2\n",
"3. Item 3\n"
=>
"
",
"- Item 1
",
"- Item 2
",
"- Item 3
",
"
"
);
}
#[test]
fn test_simple_unordered_lists()
{
test_html_compile!(
"* Item 1\n",
"* Item 2\n",
"* Item 3\n"
=>
"",
"- Item 1
",
"- Item 2
",
"- Item 3
",
"
"
);
}
#[test]
fn test_nested_unordered_lists()
{
test_html_compile!(
"* Item 1\n",
" * Item 2\n"
=>
""
);
}
#[test]
fn test_continued_outer_item_in_nested_unordered_lists()
{
test_html_compile!(
"* Item 1\n",
" * Item 2\n\n",
" Item 1 (continued)"
=>
"- Item 1",
"",
"
Item 1 (continued)
",
"
"
);
}
#[test]
fn test_continued_inner_item_in_nested_unordered_lists()
{
test_html_compile!(
"* Item 1\n",
" * Item 2\n\n",
" Item 2 (continued)"
=>
"- Item 1",
"
- Item 2",
"
Item 2 (continued)
",
"
",
"
"
);
}
#[test]
fn test_unordered_list_lorem_ipsum()
{
test_html_compile!(
" * ", lorem_ipsum!(), "\n",
" * ", lorem_ipsum!(), "\n"
=>
"",
"- ", lorem_ipsum!(), "
",
"- ", lorem_ipsum!(), "
",
"
"
);
}
#[test]
fn test_ordered_list_lorem_ipsum()
{
test_html_compile!(
" 1. ", lorem_ipsum!(), "\n",
" 2. ", lorem_ipsum!(), "\n"
=>
"",
"- ", lorem_ipsum!(), "
",
"- ", lorem_ipsum!(), "
",
"
"
);
}