Mercurial > hg
changeset 39951:a339b5e0d7c6
py3: suppress the output from .write() calls in more tests
I missed these in 803b7569c9ea because I forgot about `...` lines.
author | Matt Harbison <matt_harbison@yahoo.com> |
---|---|
date | Mon, 01 Oct 2018 23:26:24 -0400 |
parents | 8d41097dfe7d |
children | 75452c1e68f6 |
files | tests/test-commandserver.t tests/test-keyword.t tests/test-largefiles-wireproto.t tests/test-lfs.t |
diffstat | 4 files changed, 9 insertions(+), 9 deletions(-) [+] |
line wrap: on
line diff
--- a/tests/test-commandserver.t Mon Oct 01 23:07:19 2018 -0400 +++ b/tests/test-commandserver.t Mon Oct 01 23:26:24 2018 -0400 @@ -298,7 +298,7 @@ ... ... runcommand(server, ['bookmarks', 'bm3']) ... f = open('a', 'ab') - ... f.write('a\n') + ... f.write('a\n') and None ... f.close() ... runcommand(server, ['commit', '-Amm']) ... runcommand(server, ['bookmarks']) @@ -391,7 +391,7 @@ ... readchannel(server) ... runcommand(server, ['commit', '-Am.']) ... f = open('ignored-file', 'ab') - ... f.write('') + ... f.write('') and None ... f.close() ... f = open('.hgignore', 'ab') ... f.write('ignored-file') @@ -418,7 +418,7 @@ ... for i in range(5, 7): ... f = open('a', 'ab') ... f.seek(0, os.SEEK_END) - ... f.write('a\n') + ... f.write('a\n') and None ... f.close() ... os.system('hg commit -Aqm%d' % i) ... # new commits should be listed as draft revisions @@ -463,7 +463,7 @@ ... # create new head, 5:731265503d86 ... runcommand(server, ['update', '-C', '0']) ... f = open('a', 'ab') - ... f.write('a\n') + ... f.write('a\n') and None ... f.close() ... runcommand(server, ['commit', '-Am.', 'a']) ... runcommand(server, ['log', '-Gq'])
--- a/tests/test-keyword.t Mon Oct 01 23:07:19 2018 -0400 +++ b/tests/test-keyword.t Mon Oct 01 23:26:24 2018 -0400 @@ -217,7 +217,7 @@ >>> open("i", "wb").write("\1\nfoo") and None $ hg -q commit -Am metasep i $ hg status - >>> open("i", "wb").write("\1\nbar") + >>> open("i", "wb").write("\1\nbar") and None $ hg status M i $ hg -q commit -m "modify metasep" i @@ -943,7 +943,7 @@ >>> import re >>> text = re.sub(r'(Id.*)', r'\1 rejecttest', open('a').read()) - >>> open('a', 'wb').write(text) + >>> open('a', 'wb').write(text) and None $ hg --debug commit -m'rejects?' -d '3 0' -u 'User Name <user@example.com>' committing files: a
--- a/tests/test-largefiles-wireproto.t Mon Oct 01 23:07:19 2018 -0400 +++ b/tests/test-largefiles-wireproto.t Mon Oct 01 23:26:24 2018 -0400 @@ -243,7 +243,7 @@ >>> import urllib2 >>> u = 'http://localhost:%s/archive/default.zip' % os.environ['HGPORT2'] >>> with open('archive.zip', 'w') as f: - ... f.write(urllib2.urlopen(u).read()) + ... f.write(urllib2.urlopen(u).read()) and None $ unzip -t archive.zip Archive: archive.zip testing: empty-default/.hg_archival.txt*OK (glob)
--- a/tests/test-lfs.t Mon Oct 01 23:07:19 2018 -0400 +++ b/tests/test-lfs.t Mon Oct 01 23:26:24 2018 -0400 @@ -327,9 +327,9 @@ $ hg commit -m b $ hg status >>> with open('a2', 'wb') as f: - ... f.write(b'\1\nSTART-WITH-HG-FILELOG-METADATA') + ... f.write(b'\1\nSTART-WITH-HG-FILELOG-METADATA') and None >>> with open('a1', 'wb') as f: - ... f.write(b'\1\nMETA\n') + ... f.write(b'\1\nMETA\n') and None $ hg commit -m meta $ hg status $ hg log -T '{rev}: {file_copies} | {file_dels} | {file_adds}\n'