Skip to content

Commit b1087a5

Browse files
committed
Keep tests only for GHC 9
1 parent 1a8fa2c commit b1087a5

File tree

2 files changed

+22
-20
lines changed

2 files changed

+22
-20
lines changed

.github/workflows/test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ jobs:
170170
name: Test hls-class-plugin
171171
run: cabal test hls-class-plugin --test-options="-j1 --rerun-update" || cabal test hls-class-plugin --test-options="-j1 --rerun" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-class-plugin --test-options="-j1 --rerun"
172172

173-
- if: ${{ needs.pre_job.outputs.should_skip != 'true' && matrix.test }}
173+
- if: ${{ needs.pre_job.outputs.should_skip != 'true' && matrix.test && matrix.ghc == '9.0.1' }}
174174
name: Test hls-eval-plugin
175175
run: cabal test hls-eval-plugin --test-options="-j1 --rerun-update" || cabal test hls-eval-plugin --test-options="-j1 --rerun" || LSP_TEST_LOG_COLOR=0 LSP_TEST_LOG_MESSAGES=true LSP_TEST_LOG_STDERR=true cabal test hls-eval-plugin --test-options="-j1 --rerun"
176176

plugins/hls-eval-plugin/hls-eval-plugin.cabal

Lines changed: 21 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,13 @@ build-type: Simple
1919
extra-source-files:
2020
LICENSE
2121
README.md
22+
test/cabal.project
23+
test/info-util/*.cabal
24+
test/info-util/*.hs
2225
test/testdata/*.cabal
2326
test/testdata/*.hs
2427
test/testdata/*.lhs
2528
test/testdata/*.yaml
26-
test/info-util/*.cabal
27-
test/info-util/*.hs
28-
test/cabal.project
2929

3030
flag pedantic
3131
description: Enable -Werror
@@ -94,19 +94,21 @@ library
9494
DataKinds
9595
TypeOperators
9696

97-
test-suite tests
98-
type: exitcode-stdio-1.0
99-
default-language: Haskell2010
100-
hs-source-dirs: test
101-
main-is: Main.hs
102-
ghc-options: -threaded -rtsopts -with-rtsopts=-N
103-
build-depends:
104-
, aeson
105-
, base
106-
, directory
107-
, extra
108-
, filepath
109-
, hls-eval-plugin
110-
, hls-test-utils ^>=1.0
111-
, lens
112-
, lsp-types
97+
-- test suites are only available in GHC 9
98+
if impl(ghc >=9.0)
99+
test-suite tests
100+
type: exitcode-stdio-1.0
101+
default-language: Haskell2010
102+
hs-source-dirs: test
103+
main-is: Main.hs
104+
ghc-options: -threaded -rtsopts -with-rtsopts=-N
105+
build-depends:
106+
, aeson
107+
, base
108+
, directory
109+
, extra
110+
, filepath
111+
, hls-eval-plugin
112+
, hls-test-utils ^>=1.0
113+
, lens
114+
, lsp-types

0 commit comments

Comments
 (0)