diff options
Diffstat (limited to 'testsuite/driver/testglobals.py')
-rw-r--r-- | testsuite/driver/testglobals.py | 47 |
1 files changed, 28 insertions, 19 deletions
diff --git a/testsuite/driver/testglobals.py b/testsuite/driver/testglobals.py index fc050e6908..311e39be7f 100644 --- a/testsuite/driver/testglobals.py +++ b/testsuite/driver/testglobals.py @@ -1,4 +1,4 @@ -# +# # (c) Simon Marlow 2002 # @@ -9,7 +9,7 @@ # variable config below. The fields of the structure are filled in by # the appropriate config script(s) for this compiler/platform, in # ../config. -# +# # Bits of the structure may also be filled in from the command line, # via the build system, using the '-e' option to runtests. @@ -27,7 +27,9 @@ class TestConfig: self.only = set() # Accept new output which differs from the sample? - self.accept = 0 + self.accept = False + self.accept_platform = False + self.accept_os = False # File in which to save the summary self.summary_file = '' @@ -41,9 +43,6 @@ class TestConfig: # with --verbose=0. self.no_print_summary = False - # File in which to save the times - self.times_file = '' - # What platform are we running on? self.platform = '' self.os = '' @@ -70,7 +69,7 @@ class TestConfig: # Flags we always give to this compiler self.compiler_always_flags = [] - + # Which ways to run tests (when compiling and running respectively) # Other ways are added from the command line if we have the appropriate # libraries. @@ -103,16 +102,22 @@ class TestConfig: # Do we have SMP support? self.have_smp = False + # Is gdb avaliable? + self.have_gdb = False + + # Is readelf available? + self.have_readelf = False + # Are we testing an in-tree compiler? self.in_tree_compiler = True # the timeout program self.timeout_prog = '' self.timeout = 300 - + # threads self.threads = 1 - self.use_threads = 0 + self.use_threads = False # Should we skip performance tests self.skip_perf_tests = False @@ -123,6 +128,12 @@ config = TestConfig() def getConfig(): return config +import os +# Hold our modified GHC testrunning environment so we don't poison the current +# python's environment. +global ghc_env +ghc_env = os.environ.copy() + # ----------------------------------------------------------------------------- # Information about the current test run @@ -140,6 +151,7 @@ class TestRun: self.framework_failures = [] self.framework_warnings = [] + self.expected_passes = [] self.unexpected_passes = [] self.unexpected_failures = [] self.unexpected_stat_failures = [] @@ -156,7 +168,7 @@ def getTestRun(): class TestOptions: def __init__(self): # skip this test? - self.skip = 0 + self.skip = False # skip these ways self.omit_ways = [] @@ -181,7 +193,7 @@ class TestOptions: self.ignore_stderr = False # Backpack test - self.compile_backpack = 0 + self.compile_backpack = False # We sometimes want to modify the compiler_always_flags, so # they are copied from config.compiler_always_flags when we @@ -218,15 +230,15 @@ class TestOptions: self.alone = False # Does this test use a literate (.lhs) file? - self.literate = 0 + self.literate = False # Does this test use a .c, .m or .mm file? - self.c_src = 0 - self.objc_src = 0 - self.objcpp_src = 0 + self.c_src = False + self.objc_src = False + self.objcpp_src = False # Does this test use a .cmm file? - self.cmm_src = 0 + self.cmm_src = False # Should we put .hi/.o files in a subdirectory? self.outputdir = None @@ -234,9 +246,6 @@ class TestOptions: # Command to run before the test self.pre_cmd = None - # Command to run for extra cleaning - self.clean_cmd = None - # Command wrapper: a function to apply to the command before running it self.cmd_wrapper = None |