diff options
Diffstat (limited to 'test/example.bats')
| -rw-r--r-- | test/example.bats | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/test/example.bats b/test/example.bats new file mode 100644 index 0000000..5acd1ad --- /dev/null +++ b/test/example.bats @@ -0,0 +1,20 @@ +#!/usr/bin/env bats + +load test_helper + +@test "testing" { + result="$(echo 2+2 | bc)" + [ "$result" -eq 4 ] +} + +@test "is successfull" { + run echo 'hello' + + assert_success $'hello' +} + +@test "produces an error" { + run rm blah + + assert_failure $'rm: blah: No such file or directory' +} |
