From ae63040934f954b95444023f8c3962803f9c782f Mon Sep 17 00:00:00 2001 From: Eugene Triguba Date: Mon, 30 Jun 2025 21:11:54 -0400 Subject: Fix bats tests --- .github/workflows/test.yml | 4 ++++ tests/justify.bats | 37 +++++++++++++++---------------------- 2 files changed, 19 insertions(+), 22 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 05ebee9..c5a5235 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -27,3 +27,7 @@ jobs: - name: Test working-directory: ${{ steps.build-output-dir.outputs.path }} run: ctest --output-on-failure + + - name: Bats tests + run: ./tests/vendor/bats-core/bin/bats tests/ + diff --git a/tests/justify.bats b/tests/justify.bats index 6fac7ef..86ae4df 100644 --- a/tests/justify.bats +++ b/tests/justify.bats @@ -19,26 +19,18 @@ EOF Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt EOF assert_success - expected_output="Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do -eiusmod tempor incididunt" + expected_output="Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod +tempor incididunt" assert_output "$expected_output" } @test "lines are justified to both margins except last line with custom line width" { - run "${JUSTIFY_BIN}" -w 60 <