git.iko.soy/typeable/servant-reflex
on nixify-ci help sign in
typeable/servant-reflex/nix/testresults.nix
17 lines 553 B history raw
1{ curl, reflexPlatform, testdriver, testserver, phantomjs }:
3reflexPlatform.nixpkgs.pkgs.runCommand "runWebdriveTest.sh" {} ''
4 echo About to phantom
5 ${phantomjs}/bin/phantomjs --webdriver=127.0.0.1:4444 &
6 sleep 3
7 echo About to Server
8 STATIC_DIR=${testserver}/static ${testserver}/back -q --no-access-log --no-error-log -p 8000 &
9 sleep 3
10 ${curl}/bin/curl localhost:8000
11 ${curl}/bin/curl localhost:8000/runmain.js
12 echo About to testdrive
13 ${testdriver}/bin/spec > $out 2>&1
14 echo Done
15 trap "exit" INT TERM
16 trap "kill 0" EXIT
17 ''