]> rtime.felk.cvut.cz Git - frescor/frsh-forb.git/blobdiff - src/frsh/frsh_api/tests/negotiation.sh
wvtest/sh: Introduce cleanup function and exit on the first error
[frescor/frsh-forb.git] / src / frsh / frsh_api / tests / negotiation.sh
index a788859a7a76a89d557920be02ed91dfb725eede..1962317fc19b7d5c7483469ef2725415a29bcd1b 100755 (executable)
@@ -2,7 +2,12 @@
 
 . $(dirname $0)/wvtest.sh
 
-trap '' SIGINT
+wvtest_cleanup() {
+    WVPASS kill `cat fcb.pid`
+    WVPASS rm fcb.pid
+    WVPASS kill `cat frm.pid`
+    WVPASS rm frm.pid
+}
 
 WVSTART Setup
 WVPASS fcb -dfcb.pid
@@ -11,8 +16,3 @@ WVPASS frm_dummy -dfrm.pid
 
 WVPASS negotiation
 
-WVSTART Kill
-WVPASS kill `cat fcb.pid`
-WVPASS rm fcb.pid
-WVPASS kill `cat frm.pid`
-WVPASS rm frm.pid