@@ -79,7 +79,7 @@ def parse_args(args):
79
79
help = ('If specified, all unfreed (but still referenced) pointers at the'
80
80
' end of execution are considered memory leaks. Default: disabled.' ))
81
81
parser .add_argument (
82
- '--spec-test' , action = 'append' , nargs = '*' , default = [], dest = 'spec_tests' ,
82
+ '--spec-test' , action = 'append' , default = [], dest = 'spec_tests' ,
83
83
help = 'Names specific spec tests to run.' )
84
84
parser .add_argument (
85
85
'positional_args' , metavar = 'TEST_SUITE' , nargs = '*' ,
@@ -159,7 +159,6 @@ def warn(text):
159
159
160
160
if not os .path .exists (options .out_dir ):
161
161
os .makedirs (options .out_dir )
162
- os .chdir (options .out_dir )
163
162
164
163
165
164
# Finds the given executable 'program' in PATH.
@@ -384,10 +383,12 @@ def get_tests(test_dir, extensions=[], recursive=False):
384
383
return sorted (tests )
385
384
386
385
387
- if not options .spec_tests :
388
- options .spec_tests = get_tests ( get_test_dir ( 'spec' ), [ '.wast' ])
386
+ if options .spec_tests :
387
+ options .spec_tests = [ os . path . abspath ( t ) for t in options . spec_tests ]
389
388
else :
390
- options .spec_tests = options .spec_tests [:]
389
+ options .spec_tests = get_tests (get_test_dir ('spec' ), ['.wast' ])
390
+
391
+ os .chdir (options .out_dir )
391
392
392
393
# 11/27/2019: We updated the spec test suite to upstream spec repo. For some
393
394
# files that started failing after this update, we added the new files to this
0 commit comments