From 091ef37ff36cfa0a67a6cf4e6356d362320a8c07 Mon Sep 17 00:00:00 2001 From: mo khan Date: Sat, 7 Sep 2019 13:37:58 -0600 Subject: rename example spec --- test/example.bats | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 test/example.bats (limited to 'test/example.bats') 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' +} -- cgit v1.2.3