diff --git a/testsuite/driver/testlib.py b/testsuite/driver/testlib.py index 6b5fe3ebbb6bee7135d9b28fb5c87c8feebb95a1..c1bc44de3adf1f4a933deee0484362b39eb29517 100644 --- a/testsuite/driver/testlib.py +++ b/testsuite/driver/testlib.py @@ -336,6 +336,20 @@ def req_th( name, opts ): if ghc_dynamic(): return _omit_ways(name, opts, ['profasm', 'profthreaded']) +def req_plugins( name, opts ): + """ + Mark a test as requiring GHC plugins. In additional to having + interpreter support, currently we don't run the test for cross + GHCs, since plugin support for cross GHC (!7377) is unfinished + work (#14335) and completely untested in CI, and we don't enable + the internal-interpreter flag for the ghc library for cross GHC + anyway. + """ + req_interp(name, opts) + + if config.cross: + opts.skip = True + def req_ghc_smp( name, opts ): """ Mark a test as requiring GHC to be linked with an RTS that supports smp. diff --git a/testsuite/tests/plugins/all.T b/testsuite/tests/plugins/all.T index 427f35c4f376356c45833f1e5213e76bc4944f48..36b40f3a239ba2ec2715b7ffdec8b934289307dc 100644 --- a/testsuite/tests/plugins/all.T +++ b/testsuite/tests/plugins/all.T @@ -1,5 +1,5 @@ setTestOpts([ - req_interp, + req_plugins, # Plugins aren't supported with the JS backend so we get unexpected passes # for tests that expected to fail... Just skipping them for now until #14335 # is fixed diff --git a/testsuite/tests/simplCore/should_compile/all.T b/testsuite/tests/simplCore/should_compile/all.T index 41d25200a15827592fd6a3addc97bb661c6363a1..f1c37e1bab563e319a3ef4560d6e7cbbe8a859e8 100644 --- a/testsuite/tests/simplCore/should_compile/all.T +++ b/testsuite/tests/simplCore/should_compile/all.T @@ -152,7 +152,7 @@ test('T7702', # allocation done by the plugin... but a regression allocates > 90mb collect_compiler_stats('peak_megabytes_allocated',70), when(opsys('mingw32'), [multi_cpu_race]), - req_interp + req_plugins ], compile, ['-v0 -package-db T7702plugin/pkg.T7702/local.package.conf -fplugin T7702Plugin -package T7702plugin ' + config.plugin_way_flags]) diff --git a/testsuite/tests/tcplugins/all.T b/testsuite/tests/tcplugins/all.T index cf496e4198708308964e81ba23028673cad0e8be..9ccb224ef933bf31144ef85b5b272e50c9d2fa79 100644 --- a/testsuite/tests/tcplugins/all.T +++ b/testsuite/tests/tcplugins/all.T @@ -1,4 +1,7 @@ -setTestOpts(js_broken(22261)) +setTestOpts([ + req_plugins, + js_broken(22261) +]) # See NullaryPlugin.hs for a description of this plugin. test('TcPlugin_Nullary' diff --git a/testsuite/tests/typecheck/should_compile/all.T b/testsuite/tests/typecheck/should_compile/all.T index f8a91849b565407752c5074f224d1463337acc67..4da51dabda3b85bbe03f43a8994e07bf323051bb 100644 --- a/testsuite/tests/typecheck/should_compile/all.T +++ b/testsuite/tests/typecheck/should_compile/all.T @@ -500,7 +500,7 @@ test('T10592', normal, compile, ['']) test('T11305', normal, compile, ['']) test('T11254', normal, compile, ['']) test('T11379', normal, compile, ['']) -test('T11462', [js_broken(22261), req_th], multi_compile, +test('T11462', [js_broken(22261), req_th, req_plugins], multi_compile, [None, [('T11462_Plugin.hs', '-package ghc'), ('T11462.hs', '')], '-dynamic' if have_dynamic() else '']) test('T11480', normal, compile, ['']) @@ -568,7 +568,7 @@ test('T11723', normal, compile, ['']) test('T12987', normal, compile, ['']) test('T11736', normal, compile, ['']) test('T13248', expect_broken(13248), compile, ['']) -test('T11525', [js_broken(22261), req_th], multi_compile, +test('T11525', [js_broken(22261), req_th, req_plugins], multi_compile, [None, [('T11525_Plugin.hs', '-package ghc'), ('T11525.hs', '')], '-dynamic' if have_dynamic() else '']) test('T12923_1', normal, compile, [''])