def test_variable_interpolation(template, context, expected):
    output = render_string(template, context)

    assert (BeautifulSoup(
        output,
        features="html.parser",
    ).prettify() == BeautifulSoup(expected, features="html.parser").prettify())
def test_basic_conditional_rendering(template, context, expected):
    output = render_string(template, context)

    assert (BeautifulSoup(
        output,
        features="html.parser",
    ).prettify() == BeautifulSoup(expected, features="html.parser").prettify())
def test_no_syntax():
    input_ = "Coucou toi"

    output = render_string(input_, {})

    assert f"{input_}\n" == output