diff --git a/.github/workflows/run-tests.yaml b/.github/workflows/run-tests.yaml index d42dc68..34a2cd4 100644 --- a/.github/workflows/run-tests.yaml +++ b/.github/workflows/run-tests.yaml @@ -37,7 +37,3 @@ jobs: - name: Run tests run: | npm run test - if [ $? -ne 0 ]; then - echo "Tests failed" - exit 1 - fi diff --git a/package.json b/package.json index ee4ba94..394c6f4 100644 --- a/package.json +++ b/package.json @@ -13,7 +13,7 @@ "build": "npm run clean && npx tsc", "start": "node build/src/index.js", "dev": "cross-env NODE_NO_WARNINGS=1 npx nodemon src/index.ts", - "test": "npx tsc && for testfile in $(find build/tests -type f -name '*.test.js'); do node $testfile; done", + "test": "npx tsc && for testfile in $(find build/tests -type f -name '*.test.js'); do node $testfile || exit 1; done", "clean": "rimraf ./build", "gen-test-mocks": "cross-env NODE_NO_WARNINGS=1 node --loader ts-node/esm tests/mocked_sql/generate_mock_data.ts", "benchmark": "cross-env NODE_NO_WARNINGS=1 node --loader ts-node/esm benchmark/setup.ts && npx artillery run benchmark/graphql.yaml --output benchmark/report.json",