diff options
Diffstat (limited to 'deps/v8/tools/test-wrapper-gypbuild.py')
-rwxr-xr-x | deps/v8/tools/test-wrapper-gypbuild.py | 30 |
1 files changed, 23 insertions, 7 deletions
diff --git a/deps/v8/tools/test-wrapper-gypbuild.py b/deps/v8/tools/test-wrapper-gypbuild.py index ad5449a40..a990b7ee5 100755 --- a/deps/v8/tools/test-wrapper-gypbuild.py +++ b/deps/v8/tools/test-wrapper-gypbuild.py @@ -131,16 +131,20 @@ def BuildOptions(): def ProcessOptions(options): - if options.arch_and_mode != None and options.arch_and_mode != "": - tokens = options.arch_and_mode.split(".") - options.arch = tokens[0] - options.mode = tokens[1] - options.mode = options.mode.split(',') + if options.arch_and_mode == ".": + options.arch = [] + options.mode = [] + else: + if options.arch_and_mode != None and options.arch_and_mode != "": + tokens = options.arch_and_mode.split(".") + options.arch = tokens[0] + options.mode = tokens[1] + options.mode = options.mode.split(',') + options.arch = options.arch.split(',') for mode in options.mode: if not mode in ['debug', 'release']: print "Unknown mode %s" % mode return False - options.arch = options.arch.split(',') for arch in options.arch: if not arch in ['ia32', 'x64', 'arm']: print "Unknown architecture %s" % arch @@ -165,7 +169,7 @@ def PassOnOptions(options): if options.snapshot: result += ['--snapshot'] if options.special_command: - result += ['--special-command=' + options.special_command] + result += ['--special-command="%s"' % options.special_command] if options.valgrind: result += ['--valgrind'] if options.cat: @@ -232,6 +236,18 @@ def Main(): env=env) returncodes += child.wait() + if len(options.mode) == 0 and len(options.arch) == 0: + print ">>> running tests" + shellpath = workspace + '/' + options.outdir + env['LD_LIBRARY_PATH'] = shellpath + '/lib.target' + shell = shellpath + '/d8' + child = subprocess.Popen(' '.join(args_for_children + + ['--shell=' + shell]), + shell=True, + cwd=workspace, + env=env) + returncodes = child.wait() + return returncodes |