diff --git a/libexec/bats-exec-test b/libexec/bats-exec-test index f897eb7..d77c234 100755 --- a/libexec/bats-exec-test +++ b/libexec/bats-exec-test @@ -105,7 +105,7 @@ bats_exit_trap() { if [ -z "$BATS_TEST_COMPLETED" ]; then echo "not ok $BATS_TEST_NUMBER $BATS_TEST_DESCRIPTION" >&3 echo "# (in test file $BATS_TEST_FILENAME, line $BATS_LINE_NUMBER)" >&3 - sed -e "s/^/# /" < "$BATS_OUT" >&3 + sed -e "s/^/# /" < "$BATS_OUT" >&3 status=1 else echo "ok ${BATS_TEST_NUMBER}${skipped} ${BATS_TEST_DESCRIPTION}" >&3 diff --git a/test/bats.bats b/test/bats.bats index b6ab93b..e636ca9 100755 --- a/test/bats.bats +++ b/test/bats.bats @@ -85,9 +85,9 @@ fixtures bats @test "output is discarded for passing tests and printed for failing tests" { run bats "$FIXTURE_ROOT/output.bats" [ $status -eq 1 ] - [ "${lines[5]}" = "# failure stdout 1" ] - [ "${lines[6]}" = "# failure stdout 2" ] - [ "${lines[9]}" = "# failure stderr" ] + [ "${lines[5]}" = "# failure stdout 1" ] + [ "${lines[6]}" = "# failure stdout 2" ] + [ "${lines[9]}" = "# failure stderr" ] } @test "-c prints the number of tests" {