Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Glasgow Haskell Compiler
GHC
Commits
4b87abf8
Commit
4b87abf8
authored
Jun 27, 2007
by
Simon Marlow
Browse files
clean up the extra_ways machinery
parent
0dc8518a
Changes
3
Hide whitespace changes
Inline
Side-by-side
testsuite/driver/runtests.py
View file @
4b87abf8
...
...
@@ -59,8 +59,10 @@ for opt,arg in opts:
sys
.
stderr
.
write
(
"ERROR: requested way
\'
"
+
arg
+
"
\'
does not exist
\n
"
)
sys
.
exit
(
1
)
config
.
run_ways
=
filter
(
eq
(
arg
),
config
.
run_ways
+
config
.
other_ways
)
config
.
compile_ways
=
filter
(
eq
(
arg
),
config
.
compile_ways
+
config
.
other_ways
)
config
.
cmdline_ways
=
[
arg
]
+
config
.
cmdline_ways
if
(
arg
in
config
.
other_ways
):
config
.
run_ways
=
[
arg
]
+
config
.
run_ways
config
.
compile_ways
=
[
arg
]
+
config
.
compile_ways
if
opt
==
'--skipway'
:
if
(
arg
not
in
config
.
run_ways
and
arg
not
in
config
.
compile_ways
and
arg
not
in
config
.
other_ways
):
...
...
testsuite/driver/testglobals.py
View file @
4b87abf8
...
...
@@ -66,6 +66,10 @@ class TestConfig:
# libraries.
self
.
compile_ways
=
[]
self
.
run_ways
=
[]
self
.
other_ways
=
[]
# The ways selected via the command line.
self
.
cmdline_ways
=
[]
# Lists of flags for each way
self
.
way_flags
=
{}
...
...
testsuite/driver/testlib.py
View file @
4b87abf8
...
...
@@ -345,7 +345,9 @@ def test_common_work (name, opts, func, args):
else
:
all_ways
=
[
'normal'
]
all_ways
=
all_ways
+
opts
.
extra_ways
# A test itself can request extra ways by setting opts.extra_ways
all_ways
=
all_ways
+
filter
(
lambda
way
:
way
not
in
all_ways
,
opts
.
extra_ways
)
t
.
total_test_cases
=
t
.
total_test_cases
+
len
(
all_ways
)
...
...
@@ -353,6 +355,7 @@ def test_common_work (name, opts, func, args):
not
getTestOpts
().
skip
\
and
(
config
.
only
==
[]
or
name
in
config
.
only
)
\
and
(
getTestOpts
().
only_ways
==
[]
or
way
in
getTestOpts
().
only_ways
)
\
and
(
config
.
cmdline_ways
==
[]
or
way
in
config
.
cmdline_ways
)
\
and
way
not
in
getTestOpts
().
omit_ways
# Which ways we are asked to skip
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment