diff options
Diffstat (limited to 'tests/test_inheritance.py')
-rw-r--r-- | tests/test_inheritance.py | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/tests/test_inheritance.py b/tests/test_inheritance.py index 7746c2d..e753506 100644 --- a/tests/test_inheritance.py +++ b/tests/test_inheritance.py @@ -242,7 +242,5 @@ class TestBugFix(object): """Ensures that a template with more than 1 {% extends ... %} usage raises a ``TemplateError``. """ - try: + with pytest.raises(TemplateError): tmpl = env.get_template('doublee') - except Exception as e: - assert isinstance(e, TemplateError) |