summaryrefslogtreecommitdiff
path: root/yarn.tests
diff options
context:
space:
mode:
Diffstat (limited to 'yarn.tests')
-rwxr-xr-xyarn.tests/finally.script26
1 files changed, 26 insertions, 0 deletions
diff --git a/yarn.tests/finally.script b/yarn.tests/finally.script
new file mode 100755
index 0000000..2d383a0
--- /dev/null
+++ b/yarn.tests/finally.script
@@ -0,0 +1,26 @@
+#!/bin/sh
+
+set -eu
+
+cat <<EOF > "$DATADIR/finally.yarn"
+ SCENARIO finally
+ GIVEN nothing
+ WHEN nothing
+ THEN nothing
+ FINALLY yeehaa
+
+ IMPLEMENTS GIVEN nothing
+ true
+
+ IMPLEMENTS WHEN nothing
+ true
+
+ IMPLEMENTS THEN nothing
+ true
+
+ IMPLEMENTS FINALLY yeehaa
+ touch "$DATADIR/finally.has.run"
+EOF
+
+./yarn -q "$DATADIR/finally.yarn"
+test -e "$DATADIR/finally.has.run"