forked from M-Labs/nix-scripts
windows tests: capture failure, shutdown vm cleanly
This commit is contained in:
parent
19fd1a8e50
commit
287fb4a28b
@ -60,7 +60,8 @@ stdenv.mkDerivation {
|
||||
# Allow tests to run for 2 minutes
|
||||
${ssh "shutdown -s -t ${toString testTimeout}"}
|
||||
|
||||
${ssh "anaconda\\scripts\\activate ${condaEnv} && ${testCommand}"}
|
||||
FAIL=n
|
||||
${ssh "anaconda\\scripts\\activate ${condaEnv} && ${testCommand}"} || FAIL=y
|
||||
|
||||
# Abort timeouted shutdown
|
||||
${ssh "shutdown -a"}
|
||||
@ -68,6 +69,8 @@ stdenv.mkDerivation {
|
||||
${ssh "shutdown -p -f"}
|
||||
wait
|
||||
|
||||
[ "\\$FAIL" = "y" ] && exit 1
|
||||
|
||||
EOF
|
||||
chmod a+x $out/bin/run.sh
|
||||
'';
|
||||
|
Loading…
Reference in New Issue
Block a user