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 ++++++++++++++++++++ test/problem-6.bats | 20 -------------------- 2 files changed, 20 insertions(+), 20 deletions(-) create mode 100644 test/example.bats delete mode 100644 test/problem-6.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' +} diff --git a/test/problem-6.bats b/test/problem-6.bats deleted file mode 100644 index ff5ceb4..0000000 --- a/test/problem-6.bats +++ /dev/null @@ -1,20 +0,0 @@ -#!/usr/bin/env bats - -load test_helper - -@test "testing" { - result="$(echo 2+2 | bc)" - [ "$result" -eq 4 ] -} - -@test "invoke with a single integer" { - run echo 'hello' - - assert_success $'hello' -} - -@test "invoke with single non-numeric" { - run rm blah - - assert_failure $'rm: blah: No such file or directory' -} -- cgit v1.2.3