Commit c2ec3bb4 authored by Guido van Rossum's avatar Guido van Rossum

main(): automatically add "-m" option to the driver command line when

the test input filename contains the substring "metal".
parent 9ff83db7
......@@ -140,6 +140,9 @@ def main():
sys.exit(1)
errors = 0
for arg in args:
locopts = []
if string.find(arg, "metal") >= 0 and "-m" not in opts:
locopts.append("-m")
if not unittesting:
print arg,
sys.stdout.flush()
......@@ -147,7 +150,7 @@ def main():
try:
try:
sys.stdout = stdout = StringIO()
sys.argv = [""] + opts + [arg]
sys.argv = [""] + opts + locopts + [arg]
driver.main()
finally:
sys.stdout, sys.argv = save
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment