summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNed Batchelder <ned@nedbatchelder.com>2014-10-31 07:03:03 -0400
committerNed Batchelder <ned@nedbatchelder.com>2014-10-31 07:03:03 -0400
commite8691a2d8edcf40daba8a4c20220b73477cd4648 (patch)
treef23aaf74df698229d3cf7ff8554bffc016654138
parentc8d32271f96e0b3a3e0505c2acb28e07eaaabe27 (diff)
downloadpython-coveragepy-e8691a2d8edcf40daba8a4c20220b73477cd4648.tar.gz
Travis still failing, don't know why: get more info when sizes differ
-rw-r--r--tests/test_farm.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/tests/test_farm.py b/tests/test_farm.py
index df8fa66..9805a67 100644
--- a/tests/test_farm.py
+++ b/tests/test_farm.py
@@ -241,6 +241,7 @@ class FarmTestCase(object):
diff_files = self.fnmatch_list(dc.diff_files, file_pattern)
left_only = self.fnmatch_list(dc.left_only, file_pattern)
right_only = self.fnmatch_list(dc.right_only, file_pattern)
+ show_diff = True
if size_within:
# The files were already compared, use the diff_files list as a
@@ -261,7 +262,11 @@ class FarmTestCase(object):
"File sizes differ between %s and %s: %s" % (
dir1, dir2, ", ".join(wrong_size)
))
- else:
+
+ # We'll show the diff if the files differed enough in size.
+ show_diff = bool(wrong_size)
+
+ if show_diff:
# filecmp only compares in binary mode, but we want text mode. So
# look through the list of different files, and compare them
# ourselves.