diff options
author | Ned Batchelder <ned@nedbatchelder.com> | 2009-09-17 06:05:19 -0400 |
---|---|---|
committer | Ned Batchelder <ned@nedbatchelder.com> | 2009-09-17 06:05:19 -0400 |
commit | c6edabced0b503a7a1a2058056ef8704c8087964 (patch) | |
tree | fc576b296407940c55b3f7563bad8329d21c8ccf | |
parent | e0cf0dd127248637ba68969ed7156c378f78c3bd (diff) | |
download | python-coveragepy-git-c6edabced0b503a7a1a2058056ef8704c8087964.tar.gz |
Change how run_timid checks the name of the Tracer class, so that 2.x and 3.x will do it the same.
-rw-r--r-- | test/farm/run/run_timid.py | 8 | ||||
-rw-r--r-- | test/farm/run/src/showtrace.py | 2 |
2 files changed, 5 insertions, 5 deletions
diff --git a/test/farm/run/run_timid.py b/test/farm/run/run_timid.py index bbc322e2..3810e6db 100644 --- a/test/farm/run/run_timid.py +++ b/test/farm/run/run_timid.py @@ -16,7 +16,7 @@ run(""" """, rundir="out", outfile="showtraceout.txt") # When running timidly, the trace function is always Python. -contains("out/showtraceout.txt", "timid coverage.collector.PyTracer") +contains("out/showtraceout.txt", "timid PyTracer") if os.environ.get('COVERAGE_TEST_TRACER', 'c') == 'c': # If the C trace function is being tested, then regular running should have @@ -26,7 +26,7 @@ if os.environ.get('COVERAGE_TEST_TRACER', 'c') == 'c': else: # If the Python trace function is being tested, then regular running will # also show the Python function. - contains("out/showtraceout.txt", "regular coverage.collector.PyTracer") + contains("out/showtraceout.txt", "regular PyTracer") # Try the environment variable. old_opts = os.environ.get('COVERAGE_OPTIONS') @@ -38,8 +38,8 @@ run(""" """, rundir="out", outfile="showtraceout.txt") contains("out/showtraceout.txt", - "timid coverage.collector.PyTracer", - "regular coverage.collector.PyTracer" + "timid PyTracer", + "regular PyTracer" ) if old_opts: diff --git a/test/farm/run/src/showtrace.py b/test/farm/run/src/showtrace.py index 49e212e8..3708ac08 100644 --- a/test/farm/run/src/showtrace.py +++ b/test/farm/run/src/showtrace.py @@ -12,4 +12,4 @@ trace_fn = sys._getframe(0).f_trace if trace_fn is None: print "None" else: - print trace_fn.im_class + print trace_fn.im_class.__name__ |