test for Cabal where exec depends on its lib and its fix code.
This commit is contained in:
14
test/CheckSpec.hs
Normal file
14
test/CheckSpec.hs
Normal file
@@ -0,0 +1,14 @@
|
||||
module CheckSpec where
|
||||
|
||||
import Test.Hspec
|
||||
import Check
|
||||
import Expectation
|
||||
import Types
|
||||
|
||||
spec :: Spec
|
||||
spec = do
|
||||
describe "checkSyntax" $ do
|
||||
it "can check even if an executable depends on its library" $ do
|
||||
withDirectory "test/data/ghc-mod-check" $ do
|
||||
res <- checkSyntax defaultOptions "main.hs"
|
||||
res `shouldBe` "main.hs:5:1:Warning:Top-level binding with no type signature: main :: IO ()\NUL\n"
|
||||
Reference in New Issue
Block a user