summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNed Batchelder <ned@nedbatchelder.com>2021-07-18 07:07:06 -0400
committerNed Batchelder <ned@nedbatchelder.com>2021-07-18 07:07:06 -0400
commit163bc534ac53ca9183d83b6c886ccec3c62828ad (patch)
tree3cb79ab09a7387ae93e7e71f997e112463d15f5f
parentc0da97eb03d4ffe8be8854ad6ff1a2736f169003 (diff)
downloadpython-coveragepy-git-163bc534ac53ca9183d83b6c886ccec3c62828ad.tar.gz
test: mark some only-failure code in the recent goldtest changes
-rw-r--r--tests/goldtest.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/goldtest.py b/tests/goldtest.py
index 96d3cf81..7321166c 100644
--- a/tests/goldtest.py
+++ b/tests/goldtest.py
@@ -67,7 +67,7 @@ def compare(
expected_only = fnmatch_list(dc.left_only, file_pattern)
actual_only = fnmatch_list(dc.right_only, file_pattern)
- def save_mismatch(f):
+ def save_mismatch(f): # pragma: only failure
"""Save a mismatched result to tests/actual."""
save_path = expected_dir.replace("/gold/", "/actual/")
os.makedirs(save_path, exist_ok=True)
@@ -105,7 +105,7 @@ def compare(
print(f":::: end diff {expected_file!r} and {actual_file!r}")
save_mismatch(f)
- if not actual_extra:
+ if not actual_extra: # pragma: only failure
for f in actual_only:
save_mismatch(f)