py3: byte-stringify test-import.t
authorYuya Nishihara <yuya@tcha.org>
Sat, 07 Apr 2018 13:46:32 +0900
changeset 37457 d83191e9749b
parent 37456 19becdf565ef
child 37458 00e4bd97b095
py3: byte-stringify test-import.t Still the test doesn't pass. # skip-blame because just adding some b''
tests/test-import.t
--- a/tests/test-import.t	Sat Apr 07 13:42:37 2018 +0900
+++ b/tests/test-import.t	Sat Apr 07 13:46:32 2018 +0900
@@ -1839,17 +1839,17 @@
   > import mercurial.cmdutil
   > 
   > def processfoo(repo, data, extra, opts):
-  >     if 'foo' in data:
-  >         extra['foo'] = data['foo']
+  >     if b'foo' in data:
+  >         extra[b'foo'] = data[b'foo']
   > def postimport(ctx):
-  >     if 'foo' in ctx.extra():
-  >         ctx.repo().ui.write('imported-foo: %s\n' % ctx.extra()['foo'])
+  >     if b'foo' in ctx.extra():
+  >         ctx.repo().ui.write(b'imported-foo: %s\n' % ctx.extra()[b'foo'])
   > 
-  > mercurial.patch.patchheadermap.append(('Foo', 'foo'))
-  > mercurial.cmdutil.extrapreimport.append('foo')
-  > mercurial.cmdutil.extrapreimportmap['foo'] = processfoo
-  > mercurial.cmdutil.extrapostimport.append('foo')
-  > mercurial.cmdutil.extrapostimportmap['foo'] = postimport
+  > mercurial.patch.patchheadermap.append((b'Foo', b'foo'))
+  > mercurial.cmdutil.extrapreimport.append(b'foo')
+  > mercurial.cmdutil.extrapreimportmap[b'foo'] = processfoo
+  > mercurial.cmdutil.extrapostimport.append(b'foo')
+  > mercurial.cmdutil.extrapostimportmap[b'foo'] = postimport
   > EOF
   $ cat >> $HGRCPATH <<EOF
   > [extensions]