py3port: exec, subprocess: 'python' -> 'python3'
This commit is contained in:
parent
af2bec1220
commit
81548b9a35
4 changed files with 7 additions and 7 deletions
|
|
@ -12,7 +12,7 @@ gentest_py='test/gentest.py'
|
|||
scrambletest_py='test/scrambletest.py'
|
||||
mmgen_tool='cmds/mmgen-tool'
|
||||
mmgen_keygen='cmds/mmgen-keygen'
|
||||
python='python'
|
||||
python='python3'
|
||||
rounds=100 rounds_low=20 rounds_spec=500 gen_rounds=10
|
||||
monero_addrs='3,99,2,22-24,101-104'
|
||||
|
||||
|
|
@ -59,7 +59,7 @@ do
|
|||
test_py="$test_py --coverage"
|
||||
tooltest_py="$tooltest_py --coverage"
|
||||
scrambletest_py="$scrambletest_py --coverage"
|
||||
python="python -m trace --count --file=test/trace.acc --coverdir=test/trace"
|
||||
python="python3 -m trace --count --file=test/trace.acc --coverdir=test/trace"
|
||||
objtest_py="$python $objtest_py"
|
||||
gentest_py="$python $gentest_py"
|
||||
mmgen_tool="$python $mmgen_tool"
|
||||
|
|
|
|||
|
|
@ -99,7 +99,7 @@ class MMGenPexpect(object):
|
|||
) for k in passthru_args if getattr(opt,k)] \
|
||||
+ ['--data-dir='+data_dir] + cmd_args
|
||||
|
||||
if g.platform == 'win': cmd,args = 'python',[mmgen_cmd]+cmd_args
|
||||
if g.platform == 'win': cmd,args = 'python3',[mmgen_cmd]+cmd_args
|
||||
else: cmd,args = mmgen_cmd,cmd_args
|
||||
|
||||
for i in args:
|
||||
|
|
@ -113,7 +113,7 @@ class MMGenPexpect(object):
|
|||
|
||||
cmd_str = '{} {}'.format(cmd,' '.join(args)).replace('\\','/')
|
||||
if opt.coverage:
|
||||
fs = 'python -m trace --count --coverdir={} --file={} {c}'
|
||||
fs = 'python3 -m trace --count --coverdir={} --file={} {c}'
|
||||
cmd_str = fs.format(*init_coverage(),c=cmd_str)
|
||||
|
||||
if opt.log:
|
||||
|
|
|
|||
|
|
@ -76,7 +76,7 @@ test_data = OrderedDict([
|
|||
('xmr', ('c76af3b088da3364','xmr:monero', '-XMR-M','XMR:MONERO','41tmwZd2CdXEGtWqGY9fH9FVtQM8VxZASYPQ3VJQhFjtGWYzQFuidD21vJYTi2yy3tXRYXTNXBTaYVLav62rwUUpFFyicZU')),
|
||||
])
|
||||
|
||||
cmd_base = 'python{} cmds/mmgen-addrgen -qS'.format(
|
||||
cmd_base = 'python3{} cmds/mmgen-addrgen -qS'.format(
|
||||
' -m trace --count --coverdir={} --file={}'.format(*init_coverage()) if opt.coverage else '')
|
||||
|
||||
def run_tests():
|
||||
|
|
|
|||
|
|
@ -93,7 +93,7 @@ if not any(e in ('--skip-deps','--resume','-S','-r') for e in sys.argv+shortopts
|
|||
else:
|
||||
try: shutil.rmtree(tdir)
|
||||
except: # we couldn't remove data dir - perhaps regtest daemon is running
|
||||
try: subprocess.call(['python',os.path.join('cmds','mmgen-regtest'),'stop'])
|
||||
try: subprocess.call(['python3',os.path.join('cmds','mmgen-regtest'),'stop'])
|
||||
except: rdie(1,"Unable to remove {!r}!".format(tdir))
|
||||
else:
|
||||
time.sleep(2)
|
||||
|
|
@ -3056,7 +3056,7 @@ class MMGenTestSuite(object):
|
|||
def gen_pairs(n):
|
||||
disable_debug()
|
||||
ret = [subprocess.check_output(
|
||||
['python',os.path.join('cmds','mmgen-tool'),'--testnet=1'] +
|
||||
['python3',os.path.join('cmds','mmgen-tool'),'--testnet=1'] +
|
||||
(['--type=compressed'],[])[i==0] +
|
||||
['-r0','randpair']
|
||||
).decode().split() for i in range(n)]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue