summaryrefslogtreecommitdiff
path: root/tests/test_oddball.py
diff options
context:
space:
mode:
authordesmaj <matthew.desmarais@gmail.com>2013-03-18 00:03:39 -0400
committerdesmaj <matthew.desmarais@gmail.com>2013-03-18 00:03:39 -0400
commit0c8152d5d237bcfcb846e17f7907ea8a1ec352bf (patch)
tree6b66e1eaa7014a0e9d346d806397c27934cce985 /tests/test_oddball.py
parent65586d18d36f28da6bdf99aada5d821cc6b2846d (diff)
downloadpython-coveragepy-0c8152d5d237bcfcb846e17f7907ea8a1ec352bf.tar.gz
Removed redundant code; Changed a setup.py test to ensure that the proper setup.py is imported; Changed the 'oddball' tests to use a filename whitelist instead of a blacklist (so that tests run better under instrumental
Diffstat (limited to 'tests/test_oddball.py')
-rw-r--r--tests/test_oddball.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/test_oddball.py b/tests/test_oddball.py
index 60fab48..f136eb4 100644
--- a/tests/test_oddball.py
+++ b/tests/test_oddball.py
@@ -306,7 +306,10 @@ class ExceptionTest(CoverageTest):
lines = cov.data.line_data()
clean_lines = {}
for f, llist in lines.items():
- if f == __file__:
+ # f is a path to a python module, so we drop the '.py' to get
+ # a callname
+ callname = os.path.basename(f)[:-3]
+ if callname not in callnames:
# ignore this file.
continue
clean_lines[os.path.basename(f)] = llist