[ZPT] CVS: Packages/TAL - runtest.py:1.17

guido@digicool.com guido@digicool.com
Fri, 18 May 2001 15:17:26 -0400 (EDT)


Update of /cvs-repository/Packages/TAL
In directory korak.digicool.com:/tmp/cvs-serv23796

Modified Files:
	runtest.py 
Log Message:
main(): automatically add "-m" option to the driver command line when
the test input filename contains the substring "metal".



--- Updated File runtest.py in package Packages/TAL --
--- runtest.py	2001/04/27 20:09:12	1.16
+++ runtest.py	2001/05/18 19:17:17	1.17
@@ -140,6 +140,9 @@
              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 @@
         try:
             try:
                 sys.stdout = stdout = StringIO()
-                sys.argv = [""] + opts + [arg]
+                sys.argv = [""] + opts + locopts + [arg]
                 driver.main()
             finally:
                 sys.stdout, sys.argv = save