Skip to content

Commit

Permalink
build: fail on CI if leftover processes
Browse files Browse the repository at this point in the history
If any tests leave processes running after testing results are complete,
fail the test run.

PR-URL: #11269
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Santiago Gimeno <[email protected]>
Reviewed-By: Michael Dawson <[email protected]>
Reviewed-By: Sakthipriyan Vairamani <[email protected]>
Reviewed-By: Johan Bergström <[email protected]>
  • Loading branch information
Trott authored and MylesBorins committed Mar 9, 2017
1 parent f0eee61 commit bfc553d
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -199,12 +199,22 @@ test-ci-js:
$(PYTHON) tools/test.py -p tap --logfile test.tap \
--mode=release --flaky-tests=$(FLAKY_TESTS) \
$(TEST_CI_ARGS) $(CI_JS_SUITES)
# Clean up any leftover processes
PS_OUT=`ps awwx | grep Release/node | grep -v grep | awk '{print $$1}'`; \
if [ "$${PS_OUT}" ]; then \
echo $${PS_OUT} | $(XARGS) kill; exit 1; \
fi

test-ci: LOGLEVEL := info
test-ci: | build-addons
out/Release/cctest --gtest_output=tap:cctest.tap
$(PYTHON) tools/test.py -p tap --logfile test.tap --mode=release --flaky-tests=$(FLAKY_TESTS) \
$(TEST_CI_ARGS) $(CI_NATIVE_SUITES) $(CI_JS_SUITES)
# Clean up any leftover processes
PS_OUT=`ps awwx | grep Release/node | grep -v grep | awk '{print $$1}'`; \
if [ "$${PS_OUT}" ]; then \
echo $${PS_OUT} | $(XARGS) kill; exit 1; \
fi

test-release: test-build
$(PYTHON) tools/test.py --mode=release
Expand Down

0 comments on commit bfc553d

Please sign in to comment.