summaryrefslogtreecommitdiff
path: root/tests/test_parser.py
diff options
context:
space:
mode:
authorNed Batchelder <ned@nedbatchelder.com>2016-01-10 15:33:01 -0500
committerNed Batchelder <ned@nedbatchelder.com>2016-01-10 15:33:01 -0500
commit55ab897f5d822920b3086be4677bd989a3f8b051 (patch)
tree7862d291cdbe4c3477538fb40f1708bdab806a64 /tests/test_parser.py
parenta0a90eb342410a6fccf4898ed64135d109577151 (diff)
downloadpython-coveragepy-55ab897f5d822920b3086be4677bd989a3f8b051.tar.gz
Class docstrings are executable.
Diffstat (limited to 'tests/test_parser.py')
-rw-r--r--tests/test_parser.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/test_parser.py b/tests/test_parser.py
index c32fdc4..fe90711 100644
--- a/tests/test_parser.py
+++ b/tests/test_parser.py
@@ -145,8 +145,8 @@ class PythonParserTest(CoverageTest):
def func(x, y=5):
return 6
- class Foo: # the only statement...
- '''9'''
+ class Foo: # only this..
+ '''9''' # ..and this are statements.
@foo # nocover
def __init__(self):
'''12'''
@@ -169,7 +169,7 @@ class PythonParserTest(CoverageTest):
parser.raw_statements,
set([3, 4, 5, 6, 8, 9, 10, 13, 15, 16, 17, 20, 22, 23, 25, 26])
)
- self.assertEqual(parser.statements, set([8]))
+ self.assertEqual(parser.statements, set([8, 9]))
def test_class_decorator_pragmas(self):
parser = self.parse_source("""\