summaryrefslogtreecommitdiff
path: root/coverage/data.py
diff options
context:
space:
mode:
Diffstat (limited to 'coverage/data.py')
-rw-r--r--coverage/data.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/coverage/data.py b/coverage/data.py
index 5d482eac..3263cb38 100644
--- a/coverage/data.py
+++ b/coverage/data.py
@@ -228,6 +228,11 @@ class CoverageData(object):
"""A map containing all the arcs executed in `filename`."""
return self.arcs.get(filename) or {}
+ def add_to_hash(self, filename, hasher):
+ """Contribute `filename`'s data to the Md5Hash `hasher`."""
+ hasher.update(self.executed_lines(filename))
+ hasher.update(self.executed_arcs(filename))
+
def summary(self, fullpath=False):
"""Return a dict summarizing the coverage data.