Mercurial > public > mercurial-scm > hg
diff tests/test-verify-repo-operations.py @ 52009:5713adc51f2a
branching: merge stable into default
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Tue, 15 Oct 2024 13:52:21 +0200 |
parents | ca7bde5dbafb cd788962c6d9 |
children | 5cc8deb96b48 |
line wrap: on
line diff
--- a/tests/test-verify-repo-operations.py Tue Oct 01 12:29:10 2024 +0200 +++ b/tests/test-verify-repo-operations.py Tue Oct 15 13:52:21 2024 +0200 @@ -36,7 +36,7 @@ import binascii from contextlib import contextmanager -import pipes +import shlex import shutil import silenttestrunner import subprocess @@ -267,7 +267,7 @@ if os.path.exists(path): return self.log.append( - "$ mkdir -p -- %s" % (pipes.quote(os.path.relpath(path)),) + "$ mkdir -p -- %s" % (shlex.quote(os.path.relpath(path)),) ) os.makedirs(path) @@ -276,7 +276,7 @@ if path == ".": return os.chdir(path) - self.log.append("$ cd -- %s" % (pipes.quote(path),)) + self.log.append("$ cd -- %s" % (shlex.quote(path),)) def hg(self, *args): extra_flags = [] @@ -286,7 +286,7 @@ self.command("hg", *(tuple(extra_flags) + args)) def command(self, *args): - self.log.append("$ " + ' '.join(map(pipes.quote, args))) + self.log.append("$ " + ' '.join(map(shlex.quote, args))) subprocess.check_output(args, stderr=subprocess.STDOUT) # Section: Set up basic data @@ -355,7 +355,7 @@ ) % ( binascii.hexlify(content), - pipes.quote(path), + shlex.quote(path), ) ) @@ -405,7 +405,7 @@ if amend: errors.append("cannot amend public changesets") command.append("--amend") - command.append("-m" + pipes.quote(message)) + command.append("-m" + shlex.quote(message)) if secret: command.append("--secret") if close_branch: