From b0a0f00a433d7c3467d07ce7cea4cfbaaa6ae49e Mon Sep 17 00:00:00 2001 From: Ned Batchelder Date: Mon, 24 Nov 2014 20:30:53 -0500 Subject: Change how dynamic source filenames work in plugins. --- tests/plugin1.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'tests/plugin1.py') diff --git a/tests/plugin1.py b/tests/plugin1.py index 9401e327..21e64aeb 100644 --- a/tests/plugin1.py +++ b/tests/plugin1.py @@ -1,4 +1,4 @@ -"""Plugins for test_plugins.py to import.""" +"""A plugin for test_plugins.py to import.""" import os.path @@ -12,8 +12,7 @@ class Plugin(coverage.CoveragePlugin): def file_tracer(self, filename): """Trace only files named xyz.py""" if "xyz.py" in filename: - file_tracer = FileTracer(filename) - return file_tracer + return FileTracer(filename) def file_reporter(self, filename): return FileReporter(filename) -- cgit v1.2.1