diff options
Diffstat (limited to 'coverage/annotate.py')
-rw-r--r-- | coverage/annotate.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/coverage/annotate.py b/coverage/annotate.py index 5b96448a..3487feb6 100644 --- a/coverage/annotate.py +++ b/coverage/annotate.py @@ -53,7 +53,9 @@ class AnnotateReporter(Reporter): if self.directory: dest_file = os.path.join(self.directory, cu.flat_rootname()) - dest_file += ".py,cover" + if dest_file.endswith("_py"): + dest_file = dest_file[:-3] + ".py" + dest_file += ",cover" else: dest_file = cu.filename + ",cover" |