コード例 #1
0
def test_compile_multiple_files_by_directory(template_writer, tmpdir):
    tmpl1 = template_writer.write('foo')
    tmpl2 = template_writer.write('bar')
    compile_all([tmpdir.strpath])
    assert run_python(tmpl1.replace('.tmpl', '.py')) == 'foo'
    assert run_python(tmpl2.replace('.tmpl', '.py')) == 'bar'
コード例 #2
0
def test_compile_multiple_files_by_directory(template_writer, tmpdir):
    tmpl1 = template_writer.write('foo')
    tmpl2 = template_writer.write('bar')
    compile_all([tmpdir.strpath])
    assert run_python(tmpl1.replace('.tmpl', '.py')) == 'foo'
    assert run_python(tmpl2.replace('.tmpl', '.py')) == 'bar'
コード例 #3
0
def test_compile_multiple_files(template_writer):
    tmpl1 = template_writer.write('foo')
    tmpl2 = template_writer.write('bar')
    compile_all([tmpl1, tmpl2])
    assert run_python(tmpl1.replace('.tmpl', '.py')) == 'foo'
    assert run_python(tmpl2.replace('.tmpl', '.py')) == 'bar'
コード例 #4
0
def test_compile_multiple_files(template_writer):
    tmpl1 = template_writer.write('foo')
    tmpl2 = template_writer.write('bar')
    compile_all([tmpl1, tmpl2])
    assert run_python(tmpl1.replace('.tmpl', '.py')) == 'foo'
    assert run_python(tmpl2.replace('.tmpl', '.py')) == 'bar'