Mercurial > public > mercurial-scm > hg-stable
diff tests/dummyssh @ 35570:3e3f4c03876b
tests: add b'' to string literals where bytes are required
Since we are internally dealing with bytes only, we need to use bytes in the
tests too. This is one of the many patches which will make all the tests
completely use bytes.
# skip-blame because we are just adding b''
Differential Revision: https://phab.mercurial-scm.org/D1788
author | Pulkit Goyal <7895pulkit@gmail.com> |
---|---|
date | Fri, 29 Dec 2017 03:37:36 +0530 |
parents | bfdb0741f9f2 |
children | 3a763d7f40e1 |
line wrap: on
line diff
--- a/tests/dummyssh Wed Jan 10 08:53:22 2018 -0800 +++ b/tests/dummyssh Fri Dec 29 03:37:36 2017 +0530 @@ -13,9 +13,9 @@ os.environ["SSH_CLIENT"] = "%s 1 2" % os.environ.get('LOCALIP', '127.0.0.1') log = open("dummylog", "ab") -log.write("Got arguments") +log.write(b"Got arguments") for i, arg in enumerate(sys.argv[1:]): - log.write(" %d:%s" % (i + 1, arg)) + log.write(b" %d:%s" % (i + 1, arg)) log.write("\n") log.close() hgcmd = sys.argv[2]