diff options
author | Ned Batchelder <ned@nedbatchelder.com> | 2014-09-28 19:44:20 -0400 |
---|---|---|
committer | Ned Batchelder <ned@nedbatchelder.com> | 2014-09-28 19:44:20 -0400 |
commit | 9453fa062539ac28b60c325e39c0fcbfd3b2ea10 (patch) | |
tree | be81d9b59be8c0c9a3b4a4ae59c047df2d332d8b /tests/test_templite.py | |
parent | f8455cc745ccbde7ee1cc13bd302a7bdc3369d6c (diff) | |
download | python-coveragepy-git-9453fa062539ac28b60c325e39c0fcbfd3b2ea10.tar.gz |
Pragmas for uncovered code
Diffstat (limited to 'tests/test_templite.py')
-rw-r--r-- | tests/test_templite.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/test_templite.py b/tests/test_templite.py index a4667a62..aa697b78 100644 --- a/tests/test_templite.py +++ b/tests/test_templite.py @@ -31,8 +31,10 @@ class TempliteTest(CoverageTest): an exception and never get to the result comparison. """ actual = Templite(text).render(ctx or {}) - if result: - self.assertEqual(actual, result) + # If result is None, then an exception should have prevented us getting + # to here. + assert result is not None + self.assertEqual(actual, result) def assertSynErr(self, msg): """Assert that a `TempliteSyntaxError` will happen. |