From ebb192e036284b5006ecac08343c72be6e93e19b Mon Sep 17 00:00:00 2001 From: Mike Bland Date: Thu, 28 Sep 2017 06:34:03 -0400 Subject: [PATCH] Fix test failures due to unquoted variables The four test cases updated in this commit were failing on my Windows virtual machine because my username contains a space. Quoting the file paths containing "$FIXTURE_ROOT" solved the problem. --- test/bats.bats | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/test/bats.bats b/test/bats.bats index 9bed998..44b573c 100755 --- a/test/bats.bats +++ b/test/bats.bats @@ -41,25 +41,25 @@ fixtures bats } @test "summary passing tests" { - run filter_control_sequences bats -p $FIXTURE_ROOT/passing.bats + run filter_control_sequences bats -p "$FIXTURE_ROOT/passing.bats" [ $status -eq 0 ] [ "${lines[1]}" = "1 test, 0 failures" ] } @test "summary passing and skipping tests" { - run filter_control_sequences bats -p $FIXTURE_ROOT/passing_and_skipping.bats + run filter_control_sequences bats -p "$FIXTURE_ROOT/passing_and_skipping.bats" [ $status -eq 0 ] [ "${lines[2]}" = "2 tests, 0 failures, 1 skipped" ] } @test "summary passing and failing tests" { - run filter_control_sequences bats -p $FIXTURE_ROOT/failing_and_passing.bats + run filter_control_sequences bats -p "$FIXTURE_ROOT/failing_and_passing.bats" [ $status -eq 0 ] [ "${lines[4]}" = "2 tests, 1 failure" ] } @test "summary passing, failing and skipping tests" { - run filter_control_sequences bats -p $FIXTURE_ROOT/passing_failing_and_skipping.bats + run filter_control_sequences bats -p "$FIXTURE_ROOT/passing_failing_and_skipping.bats" [ $status -eq 0 ] [ "${lines[5]}" = "3 tests, 1 failure, 1 skipped" ] }