added test.sh and updated development.markdown

This commit is contained in:
Paul Chiusano 2018-08-02 10:08:11 -04:00
parent 1417b57737
commit b98afb5ec8
2 changed files with 10 additions and 4 deletions

View File

@ -1,5 +1,8 @@
These are commands that will likely be useful during development.
__General:__ `./test.sh` compiles and builds both the Haskell and Scala code and runs all tests. Recommended that you run this before pushing any code to a branch that others might be working on.
## Scala
Launch `sbt` in `runtime-jvm` directory, then here are various useful commands:
@ -32,13 +35,14 @@ For doing compilation you can do:
stack repl unison-parser-typechecker
From here, do `Main.main` to run the tests and `:r` for rapid recompile.
You can also do:
stack build unison-parser-typechecker
stack build unison-parser-typechecker && stack exec tests
If you want to run the tests outside the REPL.
If you want to run the tests outside the REPL. The `stack exec tests` takes an optional command line arg specifying the test prefix. In the REPL, you can also do:
> import EasyTest as ET
> ET.runOnly "typechecker" Main.test
What if you want a profiled build? Do:

2
test.sh Executable file
View File

@ -0,0 +1,2 @@
#!/bin/sh
stack build && stack exec tests && (cd runtime-jvm && sbt benchmark/compile && sbt test)