summaryrefslogtreecommitdiff
path: root/tests/test_farm.py
diff options
context:
space:
mode:
authorNed Batchelder <ned@nedbatchelder.com>2018-06-27 15:09:56 -0400
committerNed Batchelder <ned@nedbatchelder.com>2018-06-27 15:09:56 -0400
commit1ca7c5b8bc6edf785ef0af2adfd9bc9b82f70cd4 (patch)
treeac501d1068b68a57f8cd09bb5ea79b76ce082794 /tests/test_farm.py
parent9312de1b5c0730a65bd5ecd35a3d085b19a20fa6 (diff)
downloadpython-coveragepy-git-1ca7c5b8bc6edf785ef0af2adfd9bc9b82f70cd4.tar.gz
Lose a little less information when scrubbing HTML
Diffstat (limited to 'tests/test_farm.py')
-rw-r--r--tests/test_farm.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/test_farm.py b/tests/test_farm.py
index a23931a5..942bdd5c 100644
--- a/tests/test_farm.py
+++ b/tests/test_farm.py
@@ -219,8 +219,8 @@ def compare(dir1, dir2, file_pattern=None, size_within=0, left_extra=False, scru
`left_extra` true means the left directory can have extra files in it
without triggering an assertion.
- `scrubs` is a list of pairs, regexes to find and literal strings to
- replace them with to scrub the files of unimportant differences.
+ `scrubs` is a list of pairs, regexes to find and replace to scrub the
+ files of unimportant differences.
An assertion will be raised if the directories fail one of their
matches.
@@ -378,7 +378,7 @@ def scrub(strdata, scrubs):
"""
for rgx_find, rgx_replace in scrubs:
- strdata = re.sub(rgx_find, rgx_replace.replace("\\", "\\\\"), strdata)
+ strdata = re.sub(rgx_find, rgx_replace, strdata)
return strdata