Beispiel #1
0
def test_no_tags() -> None:
    assert process_tags("No tags") == "No tags"
Beispiel #2
0
def test_passthrough_int() -> None:
    assert process_tags(1) == 1
Beispiel #3
0
def test_passthrough_float() -> None:
    assert process_tags(0.1) == 0.1
Beispiel #4
0
def test_passthrough_none() -> None:
    assert process_tags(None) is None
Beispiel #5
0
def test_mixed_tags() -> None:
    assert process_tags(
        "__foo__ bar _baz_") == "<strong>foo</strong> bar <em>baz</em>"
Beispiel #6
0
def test_em_tags() -> None:
    assert process_tags("_foo_ bar _baz_") == "<em>foo</em> bar <em>baz</em>"
Beispiel #7
0
def test_strong_tags() -> None:
    assert process_tags("__foo__ bar __baz__"
                        ) == "<strong>foo</strong> bar <strong>baz</strong>"
Beispiel #8
0
def test_no_matched_tag() -> None:
    assert process_tags("no _matched tag") == "no _matched tag"