Un-ignore .bat files
[cabal.git] / cabal-testsuite / PackageTests / CustomWithoutCabalDefaultMain / cabal.test.hs
blob1f45729c71e468f1dab6a56f891c1a0219311b67
1 import Test.Cabal.Prelude
2 main = cabalTest $ do
4 -- This package has explicit setup dependencies that do not include Cabal.
5 -- Compilation should fail because Setup.hs imports Distribution.Simple.
6 r <- fails $ cabal' "v2-build" ["custom-setup-without-cabal-defaultMain"]
7 assertRegex "Should not have been able to import Cabal"
8 "(Could not (find|load) module|Failed to load interface for).*Distribution\\.Simple" r
9 {-
10 -- TODO: With GHC 8.2, this no longer is displayed
11 -- When using --with-ghc, this message is not necessarily output
12 has_cabal <- hasCabalForGhc
13 when has_cabal $
14 assertRegex "It is a member of the hidden package .*Cabal-"
15 "It is a member of the hidden package" r