diff options
Diffstat (limited to 'test/test_def.py')
-rw-r--r-- | test/test_def.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/test/test_def.py b/test/test_def.py index 5c7608f..73c1091 100644 --- a/test/test_def.py +++ b/test/test_def.py @@ -1,7 +1,7 @@ from mako.template import Template from mako import lookup from test import TemplateTest -from util import flatten_result, result_lines +from .util import flatten_result, result_lines from test import eq_, assert_raises class DefTest(TemplateTest): @@ -63,8 +63,8 @@ class DefTest(TemplateTest): </%def> """) # check that "a" is declared in "b", but not in "c" - assert "a" not in template.module.render_c.func_code.co_varnames - assert "a" in template.module.render_b.func_code.co_varnames + assert "a" not in template.module.render_c.__code__.co_varnames + assert "a" in template.module.render_b.__code__.co_varnames # then test output eq_( @@ -390,7 +390,7 @@ class ScopeTest(TemplateTest): ${enclosing()} """) try: - print t.render() + print(t.render()) assert False except UnboundLocalError: assert True |