testsuite: Add test for #14335
authorBen Gamari <bgamari.foss@gmail.com>
Thu, 18 Jan 2018 23:23:06 +0000 (18:23 -0500)
committerBen Gamari <ben@smart-cactus.org>
Thu, 18 Jan 2018 23:23:58 +0000 (18:23 -0500)
Subscribers: rwbarton, thomie

GHC Trac Issues: #14335

Differential Revision: https://phabricator.haskell.org/D4202

testsuite/tests/plugins/Makefile
testsuite/tests/plugins/all.T

index 1ff8d40..96443c9 100644 (file)
@@ -52,3 +52,8 @@ T12567a:
        "$(TEST_HC)" $(TEST_HC_OPTS) $(ghcPluginWayFlags) --make T12567a.hs -package-db simple-plugin/pkg.T12567a/local.package.conf -hide-all-plugin-packages -plugin-package simple-plugin 1>&2
        "$(TEST_HC)" $(TEST_HC_OPTS) $(ghcPluginWayFlags) --make T12567a.hs -package-db simple-plugin/pkg.T12567a/local.package.conf -hide-all-plugin-packages -plugin-package simple-plugin 2>&1 | grep "T12567a.hs, T12567a.o" 1>&2
        "$(TEST_HC)" $(TEST_HC_OPTS) $(ghcPluginWayFlags) --make T12567b.hs -package-db simple-plugin/pkg.T12567a/local.package.conf -hide-all-plugin-packages -plugin-package simple-plugin 1>&2
+
+.PHONY: T14335
+T14335:
+       "$(TEST_HC)" $(TEST_HC_OPTS) $(ghcPluginWayFlags) -fexternal-interpreter --make -v0 plugins01.hs -package-db simple-plugin/pkg.plugins01/local.package.conf -fplugin Simple.Plugin -fplugin-opt Simple.Plugin:Irrelevant_Option -hide-all-plugin-packages -plugin-package simple-plugin
+       ./plugins01
index 5f53531..0e523f0 100644 (file)
@@ -67,3 +67,9 @@ test('T12567a',
      [extra_files(['T12567b.hs', 'simple-plugin/']),
       pre_cmd('$MAKE -s --no-print-directory -C simple-plugin package.T12567a TOP={top}')],
      run_command, ['$MAKE -s --no-print-directory T12567a'])
+
+test('T14335',
+     [extra_files(['simple-plugin/', 'plugins01.hs']),
+      pre_cmd('$MAKE -s --no-print-directory -C simple-plugin package.plugins01 TOP={top}'),
+      expect_broken(14335)],
+     run_command, ['$MAKE -s --no-print-directory T14335'])