I have a Haskell project and Cabal package-description that allows me to build and install my package with
$ cabal configure $ cabal build $ cabal install
But what about cabal test? Cabal’s help says to configure a test suite with UserHooks, but how can I do that?
As Duncan mentioned in Greg’s answer, Cabal-1.10 has support for test suites out of the box.
The manual seems to have the best information that’s I’ve found regarding how to make use of this.
Here’s a snippet from the manual which shows how to use the
exitcode-stdiotest type:foo.cabal
test-foo.hs: