##// END OF EJS Templates
py3: make sure commands name are bytes in tests
Pulkit Goyal -
r33097:fce4ed29 default
parent child Browse files
Show More
@@ -65,7 +65,7 b' names of extensions failed to load can b'
65 > from mercurial import commands, extensions, registrar
65 > from mercurial import commands, extensions, registrar
66 > cmdtable = {}
66 > cmdtable = {}
67 > command = registrar.command(cmdtable)
67 > command = registrar.command(cmdtable)
68 > @command('showbadexts', norepo=True)
68 > @command(b'showbadexts', norepo=True)
69 > def showbadexts(ui, *pats, **opts):
69 > def showbadexts(ui, *pats, **opts):
70 > ui.write('BADEXTS: %s\n' % ' '.join(sorted(extensions.notloaded())))
70 > ui.write('BADEXTS: %s\n' % ' '.join(sorted(extensions.notloaded())))
71 > EOF
71 > EOF
@@ -70,7 +70,7 b' Create an extension to test bundle2 API'
70 > for val in op.reply.capabilities[cap]:
70 > for val in op.reply.capabilities[cap]:
71 > op.ui.write('debugreply: %r\n' % val)
71 > op.ui.write('debugreply: %r\n' % val)
72 >
72 >
73 > @command('bundle2',
73 > @command(b'bundle2',
74 > [('', 'param', [], 'stream level parameter'),
74 > [('', 'param', [], 'stream level parameter'),
75 > ('', 'unknown', False, 'include an unknown mandatory part in the bundle'),
75 > ('', 'unknown', False, 'include an unknown mandatory part in the bundle'),
76 > ('', 'unknownparams', False, 'include an unknown part parameters in the bundle'),
76 > ('', 'unknownparams', False, 'include an unknown part parameters in the bundle'),
@@ -169,7 +169,7 b' Create an extension to test bundle2 API'
169 > finally:
169 > finally:
170 > file.flush()
170 > file.flush()
171 >
171 >
172 > @command('unbundle2', [], '')
172 > @command(b'unbundle2', [], '')
173 > def cmdunbundle2(ui, repo, replypath=None):
173 > def cmdunbundle2(ui, repo, replypath=None):
174 > """process a bundle2 stream from stdin on the current repo"""
174 > """process a bundle2 stream from stdin on the current repo"""
175 > try:
175 > try:
@@ -200,7 +200,7 b' Create an extension to test bundle2 API'
200 > for chunk in op.reply.getchunks():
200 > for chunk in op.reply.getchunks():
201 > file.write(chunk)
201 > file.write(chunk)
202 >
202 >
203 > @command('statbundle2', [], '')
203 > @command(b'statbundle2', [], '')
204 > def cmdstatbundle2(ui, repo):
204 > def cmdstatbundle2(ui, repo):
205 > """print statistic on the bundle2 container read from stdin"""
205 > """print statistic on the bundle2 container read from stdin"""
206 > unbundler = bundle2.getunbundler(ui, sys.stdin)
206 > unbundler = bundle2.getunbundler(ui, sys.stdin)
@@ -108,7 +108,7 b' chg waits for pager if runcommand raises'
108 > from mercurial import registrar
108 > from mercurial import registrar
109 > cmdtable = {}
109 > cmdtable = {}
110 > command = registrar.command(cmdtable)
110 > command = registrar.command(cmdtable)
111 > @command('crash')
111 > @command(b'crash')
112 > def pagercrash(ui, repo, *pats, **opts):
112 > def pagercrash(ui, repo, *pats, **opts):
113 > ui.write('going to crash\n')
113 > ui.write('going to crash\n')
114 > raise Exception('.')
114 > raise Exception('.')
@@ -575,16 +575,16 b' changelog and manifest would have invali'
575 > from mercurial import commands, registrar
575 > from mercurial import commands, registrar
576 > cmdtable = {}
576 > cmdtable = {}
577 > command = registrar.command(cmdtable)
577 > command = registrar.command(cmdtable)
578 > @command("debuggetpass", norepo=True)
578 > @command(b"debuggetpass", norepo=True)
579 > def debuggetpass(ui):
579 > def debuggetpass(ui):
580 > ui.write("%s\\n" % ui.getpass())
580 > ui.write("%s\\n" % ui.getpass())
581 > @command("debugprompt", norepo=True)
581 > @command(b"debugprompt", norepo=True)
582 > def debugprompt(ui):
582 > def debugprompt(ui):
583 > ui.write("%s\\n" % ui.prompt("prompt:"))
583 > ui.write("%s\\n" % ui.prompt("prompt:"))
584 > @command("debugreadstdin", norepo=True)
584 > @command(b"debugreadstdin", norepo=True)
585 > def debugreadstdin(ui):
585 > def debugreadstdin(ui):
586 > ui.write("read: %r\n" % sys.stdin.read(1))
586 > ui.write("read: %r\n" % sys.stdin.read(1))
587 > @command("debugwritestdout", norepo=True)
587 > @command(b"debugwritestdout", norepo=True)
588 > def debugwritestdout(ui):
588 > def debugwritestdout(ui):
589 > os.write(1, "low-level stdout fd and\n")
589 > os.write(1, "low-level stdout fd and\n")
590 > sys.stdout.write("stdout should be redirected to /dev/null\n")
590 > sys.stdout.write("stdout should be redirected to /dev/null\n")
@@ -203,7 +203,7 b' Test warning on config option access and'
203 > cmdtable = {}
203 > cmdtable = {}
204 > command = registrar.command(cmdtable)
204 > command = registrar.command(cmdtable)
205 >
205 >
206 > @command('buggyconfig')
206 > @command(b'buggyconfig')
207 > def cmdbuggyconfig(ui, repo):
207 > def cmdbuggyconfig(ui, repo):
208 > repo.ui.config('ui', 'quiet', False)
208 > repo.ui.config('ui', 'quiet', False)
209 > repo.ui.config('ui', 'interactive', None)
209 > repo.ui.config('ui', 'interactive', None)
@@ -20,7 +20,7 b' Test alignment of multibyte characters'
20 > cmdtable = {}
20 > cmdtable = {}
21 > command = registrar.command(cmdtable)
21 > command = registrar.command(cmdtable)
22 >
22 >
23 > @command('showoptlist',
23 > @command(b'showoptlist',
24 > [('s', 'opt1', '', 'short width' + ' %(s)s' * 8, '%(s)s'),
24 > [('s', 'opt1', '', 'short width' + ' %(s)s' * 8, '%(s)s'),
25 > ('m', 'opt2', '', 'middle width' + ' %(m)s' * 8, '%(m)s'),
25 > ('m', 'opt2', '', 'middle width' + ' %(m)s' * 8, '%(m)s'),
26 > ('l', 'opt3', '', 'long width' + ' %(l)s' * 8, '%(l)s')],
26 > ('l', 'opt3', '', 'long width' + ' %(l)s' * 8, '%(l)s')],
@@ -12,7 +12,7 b' define commands to display help text'
12 > command = registrar.command(cmdtable)
12 > command = registrar.command(cmdtable)
13 >
13 >
14 > # Japanese full-width characters:
14 > # Japanese full-width characters:
15 > @command('show_full_ja', [], '')
15 > @command(b'show_full_ja', [], '')
16 > def show_full_ja(ui, **opts):
16 > def show_full_ja(ui, **opts):
17 > u'''\u3042\u3044\u3046\u3048\u304a\u304b\u304d\u304f\u3051 \u3042\u3044\u3046\u3048\u304a\u304b\u304d\u304f\u3051 \u3042\u3044\u3046\u3048\u304a\u304b\u304d\u304f\u3051
17 > u'''\u3042\u3044\u3046\u3048\u304a\u304b\u304d\u304f\u3051 \u3042\u3044\u3046\u3048\u304a\u304b\u304d\u304f\u3051 \u3042\u3044\u3046\u3048\u304a\u304b\u304d\u304f\u3051
18 >
18 >
@@ -22,7 +22,7 b' define commands to display help text'
22 > '''
22 > '''
23 >
23 >
24 > # Japanese half-width characters:
24 > # Japanese half-width characters:
25 > @command('show_half_ja', [], '')
25 > @command(b'show_half_ja', [], '')
26 > def show_half_ja(ui, *opts):
26 > def show_half_ja(ui, *opts):
27 > u'''\uff71\uff72\uff73\uff74\uff75\uff76\uff77\uff78\uff79 \uff71\uff72\uff73\uff74\uff75\uff76\uff77\uff78\uff79 \uff71\uff72\uff73\uff74\uff75\uff76\uff77\uff78\uff79 \uff71\uff72\uff73\uff74\uff75\uff76\uff77\uff78\uff79
27 > u'''\uff71\uff72\uff73\uff74\uff75\uff76\uff77\uff78\uff79 \uff71\uff72\uff73\uff74\uff75\uff76\uff77\uff78\uff79 \uff71\uff72\uff73\uff74\uff75\uff76\uff77\uff78\uff79 \uff71\uff72\uff73\uff74\uff75\uff76\uff77\uff78\uff79
28 >
28 >
@@ -32,7 +32,7 b' define commands to display help text'
32 > '''
32 > '''
33 >
33 >
34 > # Japanese ambiguous-width characters:
34 > # Japanese ambiguous-width characters:
35 > @command('show_ambig_ja', [], '')
35 > @command(b'show_ambig_ja', [], '')
36 > def show_ambig_ja(ui, **opts):
36 > def show_ambig_ja(ui, **opts):
37 > u'''\u03b1\u03b2\u03b3\u03b4\u03c5\u03b6\u03b7\u03b8\u25cb \u03b1\u03b2\u03b3\u03b4\u03c5\u03b6\u03b7\u03b8\u25cb \u03b1\u03b2\u03b3\u03b4\u03c5\u03b6\u03b7\u03b8\u25cb
37 > u'''\u03b1\u03b2\u03b3\u03b4\u03c5\u03b6\u03b7\u03b8\u25cb \u03b1\u03b2\u03b3\u03b4\u03c5\u03b6\u03b7\u03b8\u25cb \u03b1\u03b2\u03b3\u03b4\u03c5\u03b6\u03b7\u03b8\u25cb
38 >
38 >
@@ -42,7 +42,7 b' define commands to display help text'
42 > '''
42 > '''
43 >
43 >
44 > # Russian ambiguous-width characters:
44 > # Russian ambiguous-width characters:
45 > @command('show_ambig_ru', [], '')
45 > @command(b'show_ambig_ru', [], '')
46 > def show_ambig_ru(ui, **opts):
46 > def show_ambig_ru(ui, **opts):
47 > u'''\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438
47 > u'''\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438
48 >
48 >
@@ -12,10 +12,10 b' Test basic extension support'
12 > ui.write("reposetup called for %s\\n" % os.path.basename(repo.root))
12 > ui.write("reposetup called for %s\\n" % os.path.basename(repo.root))
13 > ui.write("ui %s= repo.ui\\n" % (ui == repo.ui and "=" or "!"))
13 > ui.write("ui %s= repo.ui\\n" % (ui == repo.ui and "=" or "!"))
14 > ui.flush()
14 > ui.flush()
15 > @command('foo', [], 'hg foo')
15 > @command(b'foo', [], 'hg foo')
16 > def foo(ui, *args, **kwargs):
16 > def foo(ui, *args, **kwargs):
17 > ui.write("Foo\\n")
17 > ui.write("Foo\\n")
18 > @command('bar', [], 'hg bar', norepo=True)
18 > @command(b'bar', [], 'hg bar', norepo=True)
19 > def bar(ui, *args, **kwargs):
19 > def bar(ui, *args, **kwargs):
20 > ui.write("Bar\\n")
20 > ui.write("Bar\\n")
21 > EOF
21 > EOF
@@ -408,12 +408,12 b' Setup main procedure of extension.'
408 > # preceding import (= instantiate "demandmod" object instead of
408 > # preceding import (= instantiate "demandmod" object instead of
409 > # real "module" object) might hide problem of succeeding import.
409 > # real "module" object) might hide problem of succeeding import.
410 >
410 >
411 > @command('showabsolute', [], norepo=True)
411 > @command(b'showabsolute', [], norepo=True)
412 > def showabsolute(ui, *args, **opts):
412 > def showabsolute(ui, *args, **opts):
413 > from absextroot import absolute
413 > from absextroot import absolute
414 > ui.write('ABS: %s\n' % '\nABS: '.join(absolute.getresult()))
414 > ui.write('ABS: %s\n' % '\nABS: '.join(absolute.getresult()))
415 >
415 >
416 > @command('showrelative', [], norepo=True)
416 > @command(b'showrelative', [], norepo=True)
417 > def showrelative(ui, *args, **opts):
417 > def showrelative(ui, *args, **opts):
418 > from . import relative
418 > from . import relative
419 > ui.write('REL: %s\n' % '\nREL: '.join(relative.getresult()))
419 > ui.write('REL: %s\n' % '\nREL: '.join(relative.getresult()))
@@ -470,7 +470,7 b' See also issue5208 for detail about exam'
470 > # demand import avoids failure of importing notexist here
470 > # demand import avoids failure of importing notexist here
471 > import extlibroot.lsub1.lsub2.notexist
471 > import extlibroot.lsub1.lsub2.notexist
472 >
472 >
473 > @command('checkrelativity', [], norepo=True)
473 > @command(b'checkrelativity', [], norepo=True)
474 > def checkrelativity(ui, *args, **opts):
474 > def checkrelativity(ui, *args, **opts):
475 > try:
475 > try:
476 > ui.write(extlibroot.lsub1.lsub2.notexist.text)
476 > ui.write(extlibroot.lsub1.lsub2.notexist.text)
@@ -509,11 +509,11 b' hide outer repo'
509 > from mercurial import registrar
509 > from mercurial import registrar
510 > cmdtable = {}
510 > cmdtable = {}
511 > command = registrar.command(cmdtable)
511 > command = registrar.command(cmdtable)
512 > @command('debugfoobar', [], 'hg debugfoobar')
512 > @command(b'debugfoobar', [], 'hg debugfoobar')
513 > def debugfoobar(ui, repo, *args, **opts):
513 > def debugfoobar(ui, repo, *args, **opts):
514 > "yet another debug command"
514 > "yet another debug command"
515 > pass
515 > pass
516 > @command('foo', [], 'hg foo')
516 > @command(b'foo', [], 'hg foo')
517 > def foo(ui, repo, *args, **opts):
517 > def foo(ui, repo, *args, **opts):
518 > """yet another foo command
518 > """yet another foo command
519 > This command has been DEPRECATED since forever.
519 > This command has been DEPRECATED since forever.
@@ -750,7 +750,7 b' Test help topic with same name as extens'
750 > command = registrar.command(cmdtable)
750 > command = registrar.command(cmdtable)
751 > """multirevs extension
751 > """multirevs extension
752 > Big multi-line module docstring."""
752 > Big multi-line module docstring."""
753 > @command('multirevs', [], 'ARG', norepo=True)
753 > @command(b'multirevs', [], 'ARG', norepo=True)
754 > def multirevs(ui, repo, arg, *args, **opts):
754 > def multirevs(ui, repo, arg, *args, **opts):
755 > """multirevs command"""
755 > """multirevs command"""
756 > pass
756 > pass
@@ -825,11 +825,11 b' along with extension help itself'
825 > from mercurial import commands, registrar
825 > from mercurial import commands, registrar
826 > cmdtable = {}
826 > cmdtable = {}
827 > command = registrar.command(cmdtable)
827 > command = registrar.command(cmdtable)
828 > @command('dodo', [], 'hg dodo')
828 > @command(b'dodo', [], 'hg dodo')
829 > def dodo(ui, *args, **kwargs):
829 > def dodo(ui, *args, **kwargs):
830 > """Does nothing"""
830 > """Does nothing"""
831 > ui.write("I do nothing. Yay\\n")
831 > ui.write("I do nothing. Yay\\n")
832 > @command('foofoo', [], 'hg foofoo')
832 > @command(b'foofoo', [], 'hg foofoo')
833 > def foofoo(ui, *args, **kwargs):
833 > def foofoo(ui, *args, **kwargs):
834 > """Writes 'Foo foo'"""
834 > """Writes 'Foo foo'"""
835 > ui.write("Foo foo\\n")
835 > ui.write("Foo foo\\n")
@@ -936,11 +936,11 b' along with extension help'
936 > from mercurial import commands, registrar
936 > from mercurial import commands, registrar
937 > cmdtable = {}
937 > cmdtable = {}
938 > command = registrar.command(cmdtable)
938 > command = registrar.command(cmdtable)
939 > @command('something', [], 'hg something')
939 > @command(b'something', [], 'hg something')
940 > def something(ui, *args, **kwargs):
940 > def something(ui, *args, **kwargs):
941 > """Does something"""
941 > """Does something"""
942 > ui.write("I do something. Yaaay\\n")
942 > ui.write("I do something. Yaaay\\n")
943 > @command('beep', [], 'hg beep')
943 > @command(b'beep', [], 'hg beep')
944 > def beep(ui, *args, **kwargs):
944 > def beep(ui, *args, **kwargs):
945 > """Writes 'Beep beep'"""
945 > """Writes 'Beep beep'"""
946 > ui.write("Beep beep\\n")
946 > ui.write("Beep beep\\n")
@@ -1180,7 +1180,7 b' Broken disabled extension and command:'
1180 > cmdtable = {}
1180 > cmdtable = {}
1181 > command = registrar.command(cmdtable)
1181 > command = registrar.command(cmdtable)
1182 > class Bogon(Exception): pass
1182 > class Bogon(Exception): pass
1183 > @command('throw', [], 'hg throw', norepo=True)
1183 > @command(b'throw', [], 'hg throw', norepo=True)
1184 > def throw(ui, **opts):
1184 > def throw(ui, **opts):
1185 > """throws an exception"""
1185 > """throws an exception"""
1186 > raise Bogon()
1186 > raise Bogon()
@@ -1617,7 +1617,7 b' Show deprecation warning for the use of '
1617 > from mercurial import cmdutil
1617 > from mercurial import cmdutil
1618 > cmdtable = {}
1618 > cmdtable = {}
1619 > command = cmdutil.command(cmdtable)
1619 > command = cmdutil.command(cmdtable)
1620 > @command('foo', [], norepo=True)
1620 > @command(b'foo', [], norepo=True)
1621 > def foo(ui):
1621 > def foo(ui):
1622 > pass
1622 > pass
1623 > EOF
1623 > EOF
@@ -26,7 +26,7 b' Test that raising an exception in the re'
26 > l = repo._lock(repo.vfs, 'testlock', False, unlock, None, 'test lock')
26 > l = repo._lock(repo.vfs, 'testlock', False, unlock, None, 'test lock')
27 > return l
27 > return l
28 >
28 >
29 > @command('testlockexc')
29 > @command(b'testlockexc')
30 > def testlockexc(ui, repo):
30 > def testlockexc(ui, repo):
31 > testlock = acquiretestlock(repo, True)
31 > testlock = acquiretestlock(repo, True)
32 > try:
32 > try:
@@ -12,7 +12,7 b' Test if logtoprocess correctly captures '
12 > from time import sleep
12 > from time import sleep
13 > cmdtable = {}
13 > cmdtable = {}
14 > command = registrar.command(cmdtable)
14 > command = registrar.command(cmdtable)
15 > @command('foo', [])
15 > @command(b'foo', [])
16 > def foo(ui, repo):
16 > def foo(ui, repo):
17 > ui.log('foo', 'a message: %(bar)s\n', bar='spam')
17 > ui.log('foo', 'a message: %(bar)s\n', bar='spam')
18 > EOF
18 > EOF
@@ -1107,7 +1107,7 b' Test heads computation on pending index '
1107 >
1107 >
1108 > cmdtable = {}
1108 > cmdtable = {}
1109 > command = registrar.command(cmdtable)
1109 > command = registrar.command(cmdtable)
1110 > @command("amendtransient",[], _('hg amendtransient [rev]'))
1110 > @command(b"amendtransient",[], _('hg amendtransient [rev]'))
1111 > def amend(ui, repo, *pats, **opts):
1111 > def amend(ui, repo, *pats, **opts):
1112 > def commitfunc(ui, repo, message, match, opts):
1112 > def commitfunc(ui, repo, message, match, opts):
1113 > return repo.commit(message, repo['.'].user(), repo['.'].date(), match)
1113 > return repo.commit(message, repo['.'].user(), repo['.'].date(), match)
@@ -217,7 +217,7 b' Pager should not override the exit code '
217 > from mercurial import registrar, commands
217 > from mercurial import registrar, commands
218 > cmdtable = {}
218 > cmdtable = {}
219 > command = registrar.command(cmdtable)
219 > command = registrar.command(cmdtable)
220 > @command('fortytwo', [], 'fortytwo', norepo=True)
220 > @command(b'fortytwo', [], 'fortytwo', norepo=True)
221 > def fortytwo(ui, *opts):
221 > def fortytwo(ui, *opts):
222 > ui.write('42\n')
222 > ui.write('42\n')
223 > return 42
223 > return 42
@@ -230,7 +230,7 b' Pager should not override the exit code '
230 > from mercurial import commands, registrar
230 > from mercurial import commands, registrar
231 > cmdtable = {}
231 > cmdtable = {}
232 > command = registrar.command(cmdtable)
232 > command = registrar.command(cmdtable)
233 > @command('fortytwo', [], 'fortytwo', norepo=True)
233 > @command(b'fortytwo', [], 'fortytwo', norepo=True)
234 > def fortytwo(ui, *opts):
234 > def fortytwo(ui, *opts):
235 > ui.write('42\n')
235 > ui.write('42\n')
236 > return 42
236 > return 42
@@ -68,7 +68,7 b' Install an extension that can sleep and '
68 > from mercurial import registrar, commands
68 > from mercurial import registrar, commands
69 > cmdtable = {}
69 > cmdtable = {}
70 > command = registrar.command(cmdtable)
70 > command = registrar.command(cmdtable)
71 > @command('sleep', [], 'hg sleep')
71 > @command(b'sleep', [], 'hg sleep')
72 > def sleep(ui, *args, **kwargs):
72 > def sleep(ui, *args, **kwargs):
73 > time.sleep(0.1)
73 > time.sleep(0.1)
74 > EOF
74 > EOF
@@ -14,7 +14,7 b''
14 > return self._time
14 > return self._time
15 > time.time = incrementingtime()
15 > time.time = incrementingtime()
16 >
16 >
17 > @command('loop',
17 > @command(b'loop',
18 > [('', 'total', '', 'override for total'),
18 > [('', 'total', '', 'override for total'),
19 > ('', 'nested', False, 'show nested results'),
19 > ('', 'nested', False, 'show nested results'),
20 > ('', 'parallel', False, 'show parallel sets of results')],
20 > ('', 'parallel', False, 'show parallel sets of results')],
@@ -3,7 +3,7 b''
3 > from mercurial import registrar
3 > from mercurial import registrar
4 > cmdtable = {}
4 > cmdtable = {}
5 > command = registrar.command(cmdtable)
5 > command = registrar.command(cmdtable)
6 > @command('debugadddrop',
6 > @command(b'debugadddrop',
7 > [('', 'drop', False, 'drop file from dirstate', 'FILE'),
7 > [('', 'drop', False, 'drop file from dirstate', 'FILE'),
8 > ('', 'normal-lookup', False, 'add file to dirstate', 'FILE')],
8 > ('', 'normal-lookup', False, 'add file to dirstate', 'FILE')],
9 > 'hg debugadddrop')
9 > 'hg debugadddrop')
@@ -88,7 +88,7 b" don't allow marking or unmarking driver-"
88 > from mercurial import merge, registrar, scmutil
88 > from mercurial import merge, registrar, scmutil
89 > cmdtable = {}
89 > cmdtable = {}
90 > command = registrar.command(cmdtable)
90 > command = registrar.command(cmdtable)
91 > @command('markdriver',
91 > @command(b'markdriver',
92 > [('u', 'unmark', None, '')],
92 > [('u', 'unmark', None, '')],
93 > 'FILE...')
93 > 'FILE...')
94 > def markdriver(ui, repo, *pats, **opts):
94 > def markdriver(ui, repo, *pats, **opts):
@@ -45,7 +45,7 b" these predicates use '\\0' as a separator"
45 > )
45 > )
46 > cmdtable = {}
46 > cmdtable = {}
47 > command = registrar.command(cmdtable)
47 > command = registrar.command(cmdtable)
48 > @command('debugrevlistspec',
48 > @command(b'debugrevlistspec',
49 > [('', 'optimize', None, 'print parsed tree after optimizing'),
49 > [('', 'optimize', None, 'print parsed tree after optimizing'),
50 > ('', 'bin', None, 'unhexlify arguments')])
50 > ('', 'bin', None, 'unhexlify arguments')])
51 > def debugrevlistspec(ui, repo, fmt, *args, **opts):
51 > def debugrevlistspec(ui, repo, fmt, *args, **opts):
@@ -31,7 +31,7 b' Test UI worker interaction'
31 > }
31 > }
32 > cmdtable = {}
32 > cmdtable = {}
33 > command = registrar.command(cmdtable)
33 > command = registrar.command(cmdtable)
34 > @command('test', [], 'hg test [COST] [FUNC]')
34 > @command(b'test', [], 'hg test [COST] [FUNC]')
35 > def t(ui, repo, cost=1.0, func='runme'):
35 > def t(ui, repo, cost=1.0, func='runme'):
36 > cost = float(cost)
36 > cost = float(cost)
37 > func = functable[func]
37 > func = functable[func]
General Comments 0
You need to be logged in to leave comments. Login now