cabal sandbox init
cabal configure --enable-tests
cabal install --only-dependencies --enable-tests
$ cabal run repl
Tests are written using Hspec.
cabal test
For this you need Ruby and the guard-haskell
gem installed.
guard
Now edit and save a test or a source file and the tests will run automatically.