From 19e52a9bdcfc3318efb2cdcbf1e9cf3343b3dbf8 Mon Sep 17 00:00:00 2001 From: Ned Batchelder Date: Thu, 15 Oct 2009 06:38:10 -0400 Subject: Refactor the analysis results so we aren't passing so many tuples around. --- coverage/annotate.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'coverage/annotate.py') diff --git a/coverage/annotate.py b/coverage/annotate.py index 3130c001..2fa9d5cf 100644 --- a/coverage/annotate.py +++ b/coverage/annotate.py @@ -37,7 +37,7 @@ class AnnotateReporter(Reporter): """Run the report.""" self.report_files(self.annotate_file, morfs, directory, omit_prefixes) - def annotate_file(self, cu, statements, excluded, missing): + def annotate_file(self, cu, analysis): """Annotate a single file. `cu` is the CodeUnit for the file to annotate. @@ -55,6 +55,10 @@ class AnnotateReporter(Reporter): dest_file = filename + ",cover" dest = open(dest_file, 'w') + statements = analysis.statements + missing = analysis.missing + excluded = analysis.excluded + lineno = 0 i = 0 j = 0 -- cgit v1.2.1