D11725: windows: use raw string in test log paths
Alphare (Raphaël Gomès)
phabricator at mercurial-scm.org
Thu Oct 28 09:19:11 UTC 2021
Alphare created this revision.
Herald added a reviewer: hg-reviewers.
Herald added a subscriber: mercurial-patches.
REVISION SUMMARY
Otherwise the backslashes will work as escapes on Windows and break everything.
REPOSITORY
rHG Mercurial
BRANCH
default
REVISION DETAIL
https://phab.mercurial-scm.org/D11725
AFFECTED FILES
tests/test-fix.t
CHANGE DETAILS
diff --git a/tests/test-fix.t b/tests/test-fix.t
--- a/tests/test-fix.t
+++ b/tests/test-fix.t
@@ -1785,7 +1785,7 @@
$ cat >> $LOGGER <<EOF
> # Appends the input file's name to the log file.
> import sys
- > with open('$LOGFILE', 'a') as f:
+ > with open(r'$LOGFILE', 'a') as f:
> f.write(sys.argv[1] + '\n')
> sys.stdout.write(sys.stdin.read())
> EOF
To: Alphare, #hg-reviewers
Cc: mercurial-patches, mercurial-devel
More information about the Mercurial-devel
mailing list