cabal icon indicating copy to clipboard operation
cabal copied to clipboard

ConfigFile/T8487/cabal.test.hs is fragile to changing compiler

Open mpickering opened this issue 6 months ago • 1 comments

This test modifies --config-file, which overrides the means the testsuite used to specify the compiler which cabal-install should use.

  • If you use a -w flag to choose which ghc to compile the cabal-tests executable with.
  • If you pass --with-ghc=... when running the tests

This doesn't show up in CI as we only test cabal-install against the ghc it was bootstrapped against.

I more robust way to write the test is to perhaps augment the testUserCabalConfigFile, which is local to each test, rather than override it completely. However, I will leave that for now.

mpickering avatar Feb 22 '24 15:02 mpickering

The failure mode is:

-Build profile: -w ghc-<GHCVER> -O2
+Build profile: -w ghc-9.6.2 -O2
 In order, the following will be built:
  - test-0.1.0.0 (lib) (first run)
 Configuring library for test-0.1.0.0...
*** Exception: ExitFailure 1

mpickering avatar Feb 22 '24 15:02 mpickering