Skip to content

Commit 8407849

Browse files
committed
Be explicit about the test GHC
1 parent 7171c71 commit 8407849

File tree

2 files changed

+9
-13
lines changed

2 files changed

+9
-13
lines changed

.github/scripts/test.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,13 +21,15 @@ esac
2121
cd ..
2222

2323
ghcup --no-verbose install ghc --set --install-targets "${GHC_TARGETS}" "${GHC_VERSION}"
24+
ghcup --no-verbose install ghc --install-targets "${GHC_TEST_TARGETS}" "${GHC_TEST_VERSION}"
2425

2526
cabal update
2627

2728
# TODO: we want to avoid building here... we should just
2829
# be using the previously built 'cabal-tests' binary
29-
cabal run ${ADD_CABAL_ARGS} cabal-testsuite:cabal-tests -- \
30+
cabal run -w "ghc-${GHC_VERSION}" ${ADD_CABAL_ARGS} cabal-testsuite:cabal-tests -- \
3031
--with-cabal "$(pwd)/out/cabal" \
32+
--with-ghc "ghc-${GHC_TEST_VERSION}" \
3133
--intree-cabal-lib "$(pwd)" \
3234
--test-tmp "$(pwd)/testdb" \
3335
--skip-setup-tests \

.github/workflows/reusable-release.yml

Lines changed: 6 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,12 @@ on:
2424
env:
2525
GHC_VERSION: ${{ inputs.ghc }}
2626
GHC_TARGETS: ${{ inputs.ghc_targets }}
27+
# This shouldn't be necessary, but cabal developers
28+
# whant to build with 9.10.2, which causes test failures
29+
# when used as runtime GHC version as well. So we need a different
30+
# runtime GHC version than the build GHC.
31+
GHC_TEST_VERSION: 9.6.7
32+
GHC_TEST_TARGETS: "install_bin install_lib update_package_db install_extra"
2733
CABAL_VERSION: ${{ inputs.cabal }}
2834
BOOTSTRAP_HASKELL_NONINTERACTIVE: 1
2935
BOOTSTRAP_HASKELL_MINIMAL: 1
@@ -458,8 +464,6 @@ jobs:
458464
env:
459465
TARBALL_EXT: tar.xz
460466
ARCH: 64
461-
GHC_VERSION: 9.6.7
462-
GHC_TARGETS: "install_bin install_lib update_package_db"
463467
ADD_CABAL_ARGS: ""
464468
strategy:
465469
fail-fast: false
@@ -610,8 +614,6 @@ jobs:
610614
ADD_CABAL_ARGS: ""
611615
TARBALL_EXT: tar.xz
612616
ARCH: ARM64
613-
GHC_VERSION: 9.6.7
614-
GHC_TARGETS: "install_bin install_lib update_package_db"
615617
strategy:
616618
fail-fast: false
617619
matrix:
@@ -665,8 +667,6 @@ jobs:
665667
ARCH: 64
666668
TARBALL_EXT: tar.xz
667669
DISTRO: na
668-
GHC_VERSION: 9.6.7
669-
GHC_TARGETS: "install_bin install_lib update_package_db"
670670
strategy:
671671
fail-fast: false
672672
matrix:
@@ -704,8 +704,6 @@ jobs:
704704
DISTRO: na
705705
HOMEBREW_CHANGE_ARCH_TO_ARM: 1
706706
GHCUP_INSTALL_BASE_PREFIX: ${{ github.workspace }}
707-
GHC_VERSION: 9.6.7
708-
GHC_TARGETS: "install_bin install_lib update_package_db"
709707
strategy:
710708
fail-fast: false
711709
matrix:
@@ -742,8 +740,6 @@ jobs:
742740
DISTRO: na
743741
CABAL_DIR: "C:\\Users\\runneradmin\\AppData\\Roaming\\cabal"
744742
GHCUP_INSTALL_BASE_PREFIX: "/c"
745-
GHC_VERSION: 9.6.7
746-
GHC_TARGETS: "install_bin install_lib update_package_db"
747743
strategy:
748744
fail-fast: false
749745
matrix:
@@ -793,8 +789,6 @@ jobs:
793789
RUNNER_OS: FreeBSD
794790
CABAL_DIR: ${{ github.workspace }}/.cabal
795791
GHCUP_INSTALL_BASE_PREFIX: ${{ github.workspace }}
796-
GHC_VERSION: 9.6.7
797-
GHC_TARGETS: "install_bin install_lib update_package_db"
798792
strategy:
799793
fail-fast: false
800794
matrix:

0 commit comments

Comments
 (0)