aboutsummaryrefslogblamecommitdiffstats
path: root/tests/text.rs
blob: a2ef1fb243c5535c357733fac33b3e42e17a805d (plain) (tree)
1
2
3
4
5
6

                         
                                 

       
                                 
















                                                  

          
 
extern crate micromark;
use micromark::micromark;
use pretty_assertions::assert_eq;

#[test]
fn text() -> Result<(), String> {
    assert_eq!(
        micromark("hello $.;'there"),
        "<p>hello $.;'there</p>",
        "should support ascii text"
    );

    assert_eq!(
        micromark("Foo χρῆν"),
        "<p>Foo χρῆν</p>",
        "should support unicode text"
    );

    assert_eq!(
        micromark("Multiple     spaces"),
        "<p>Multiple     spaces</p>",
        "should preserve internal spaces verbatim"
    );

    Ok(())
}