##// END OF EJS Templates
py3: add b'' prefixes in tests/test-lfs-serve.t...
Pulkit Goyal -
r41392:23c80ce1 default
parent child Browse files
Show More
@@ -110,14 +110,14 non-lfs content, and the extension enabl
110 ... def diff(server):
110 ... def diff(server):
111 ... readchannel(server)
111 ... readchannel(server)
112 ... # run an arbitrary command in the repo with the extension loaded
112 ... # run an arbitrary command in the repo with the extension loaded
113 ... runcommand(server, ['id', '-R', '../cmdservelfs'])
113 ... runcommand(server, [b'id', b'-R', b'../cmdservelfs'])
114 ... # now run a command in a repo without the extension to ensure that
114 ... # now run a command in a repo without the extension to ensure that
115 ... # files are added safely..
115 ... # files are added safely..
116 ... runcommand(server, ['ci', '-Aqm', 'non-lfs'])
116 ... runcommand(server, [b'ci', b'-Aqm', b'non-lfs'])
117 ... # .. and that scmutil.prefetchfiles() safely no-ops..
117 ... # .. and that scmutil.prefetchfiles() safely no-ops..
118 ... runcommand(server, ['diff', '-r', '.~1'])
118 ... runcommand(server, [b'diff', b'-r', b'.~1'])
119 ... # .. and that debugupgraderepo safely no-ops.
119 ... # .. and that debugupgraderepo safely no-ops.
120 ... runcommand(server, ['debugupgraderepo', '-q', '--run'])
120 ... runcommand(server, [b'debugupgraderepo', b'-q', b'--run'])
121 *** runcommand id -R ../cmdservelfs
121 *** runcommand id -R ../cmdservelfs
122 000000000000 tip
122 000000000000 tip
123 *** runcommand ci -Aqm non-lfs
123 *** runcommand ci -Aqm non-lfs
@@ -257,12 +257,12 times.
257 ... def addrequirement(server):
257 ... def addrequirement(server):
258 ... readchannel(server)
258 ... readchannel(server)
259 ... # change the repo in a way that adds the lfs requirement
259 ... # change the repo in a way that adds the lfs requirement
260 ... runcommand(server, ['pull', '-qu'])
260 ... runcommand(server, [b'pull', b'-qu'])
261 ... # Now cause the requirement adding hook to fire again, without going
261 ... # Now cause the requirement adding hook to fire again, without going
262 ... # through reposetup() again.
262 ... # through reposetup() again.
263 ... with open('file.txt', 'wb') as fp:
263 ... with open('file.txt', 'wb') as fp:
264 ... fp.write('data')
264 ... fp.write(b'data')
265 ... runcommand(server, ['ci', '-Aqm', 'non-lfs'])
265 ... runcommand(server, [b'ci', b'-Aqm', b'non-lfs'])
266 *** runcommand pull -qu
266 *** runcommand pull -qu
267 *** runcommand ci -Aqm non-lfs
267 *** runcommand ci -Aqm non-lfs
268
268
@@ -365,16 +365,16 lfs content, and the extension enabled.
365 ... readchannel(server)
365 ... readchannel(server)
366 ... print('')
366 ... print('')
367 ... print('# LFS required- both lfs and non-lfs revlogs have 0x2000 flag')
367 ... print('# LFS required- both lfs and non-lfs revlogs have 0x2000 flag')
368 ... runcommand(server, ['debugprocessors', 'lfs.bin', '-R',
368 ... runcommand(server, [b'debugprocessors', b'lfs.bin', b'-R',
369 ... '../server'])
369 ... b'../server'])
370 ... runcommand(server, ['debugprocessors', 'nonlfs2.txt', '-R',
370 ... runcommand(server, [b'debugprocessors', b'nonlfs2.txt', b'-R',
371 ... '../server'])
371 ... b'../server'])
372 ... runcommand(server, ['config', 'extensions', '--cwd',
372 ... runcommand(server, [b'config', b'extensions', b'--cwd',
373 ... '../server'])
373 ... b'../server'])
374 ...
374 ...
375 ... print("\n# LFS not enabled- revlogs don't have 0x2000 flag")
375 ... print("\n# LFS not enabled- revlogs don't have 0x2000 flag")
376 ... runcommand(server, ['debugprocessors', 'nonlfs3.txt'])
376 ... runcommand(server, [b'debugprocessors', b'nonlfs3.txt'])
377 ... runcommand(server, ['config', 'extensions'])
377 ... runcommand(server, [b'config', b'extensions'])
378
378
379 # LFS required- both lfs and non-lfs revlogs have 0x2000 flag
379 # LFS required- both lfs and non-lfs revlogs have 0x2000 flag
380 *** runcommand debugprocessors lfs.bin -R ../server
380 *** runcommand debugprocessors lfs.bin -R ../server
@@ -409,16 +409,16 lfs content, and the extension enabled.
409 ... readchannel(server)
409 ... readchannel(server)
410 ... print('')
410 ... print('')
411 ... print('# LFS enabled- both lfs and non-lfs revlogs have 0x2000 flag')
411 ... print('# LFS enabled- both lfs and non-lfs revlogs have 0x2000 flag')
412 ... runcommand(server, ['debugprocessors', 'lfs.bin', '-R',
412 ... runcommand(server, [b'debugprocessors', b'lfs.bin', b'-R',
413 ... '../server'])
413 ... b'../server'])
414 ... runcommand(server, ['debugprocessors', 'nonlfs2.txt', '-R',
414 ... runcommand(server, [b'debugprocessors', b'nonlfs2.txt', b'-R',
415 ... '../server'])
415 ... b'../server'])
416 ... runcommand(server, ['config', 'extensions', '--cwd',
416 ... runcommand(server, [b'config', b'extensions', b'--cwd',
417 ... '../server'])
417 ... b'../server'])
418 ...
418 ...
419 ... print('\n# LFS enabled without requirement- revlogs have 0x2000 flag')
419 ... print('\n# LFS enabled without requirement- revlogs have 0x2000 flag')
420 ... runcommand(server, ['debugprocessors', 'nonlfs3.txt'])
420 ... runcommand(server, [b'debugprocessors', b'nonlfs3.txt'])
421 ... runcommand(server, ['config', 'extensions'])
421 ... runcommand(server, [b'config', b'extensions'])
422 ...
422 ...
423 ... print("\n# LFS disabled locally- revlogs don't have 0x2000 flag")
423 ... print("\n# LFS disabled locally- revlogs don't have 0x2000 flag")
424 ... runcommand(server, ['debugprocessors', 'nonlfs.txt', '-R',
424 ... runcommand(server, ['debugprocessors', 'nonlfs.txt', '-R',
General Comments 0
You need to be logged in to leave comments. Login now