bin/test
: run test, and reload on library change (#32)
* test script now runs on test file update * added src to cabal tests to get auto reload * fixed formatting * removed unneeded test dependency * fixed cabal formatting issue * Remove library stanza; no longer needed * hs-source-dirs belongs to shared Because we are sharing 'src' * Fix compilation * Move other-modules as well. Co-authored-by: Sridhar Ratnakumar <srid@srid.ca>
This commit is contained in:
parent
1aa9e81142
commit
df6efcff60
3 changed files with 6 additions and 12 deletions
2
bin/test
2
bin/test
|
@ -1,4 +1,4 @@
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
set -xe
|
set -xe
|
||||||
|
|
||||||
exec nix develop -c ghcid -c "cabal repl test:tests"
|
exec nix develop -c ghcid -c "cabal repl test:tests" -T :main
|
||||||
|
|
|
@ -91,23 +91,17 @@ common shared
|
||||||
, time
|
, time
|
||||||
, with-utf8
|
, with-utf8
|
||||||
|
|
||||||
|
hs-source-dirs: src
|
||||||
|
other-modules: Lib
|
||||||
|
|
||||||
executable haskell-template
|
executable haskell-template
|
||||||
import: shared
|
import: shared
|
||||||
main-is: Main.hs
|
main-is: Main.hs
|
||||||
hs-source-dirs: src
|
|
||||||
default-language: Haskell2010
|
default-language: Haskell2010
|
||||||
other-modules: Lib
|
|
||||||
|
|
||||||
library
|
|
||||||
import: shared
|
|
||||||
exposed-modules: Lib
|
|
||||||
hs-source-dirs: src
|
|
||||||
|
|
||||||
test-suite tests
|
test-suite tests
|
||||||
import: shared
|
import: shared
|
||||||
main-is: Main.hs
|
main-is: Spec.hs
|
||||||
type: exitcode-stdio-1.0
|
type: exitcode-stdio-1.0
|
||||||
hs-source-dirs: tests
|
hs-source-dirs: tests
|
||||||
build-depends:
|
build-depends: hspec
|
||||||
, haskell-template
|
|
||||||
, hspec
|
|
||||||
|
|
Loading…
Reference in a new issue