Skip to content

Commit

Permalink
adding logging to makefile
Browse files Browse the repository at this point in the history
  • Loading branch information
narfdre authored and ljharb committed Jul 22, 2024
1 parent 18f362e commit 981d19c
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,14 @@ list:
# Note that preexisting NVM_* variables are unset to avoid interfering with tests, except when running the Travis tests (where NVM_DIR must be passed in and the env. is assumed to be pristine).
.PHONY: $(SHELL_TARGETS)
$(SHELL_TARGETS):
@shell='$@'; shell=$${shell##*-}; which "$$shell" >/dev/null || { printf '\033[0;31m%s\033[0m\n' "WARNING: Cannot test with shell '$$shell': not found." >&2; exit 0; } && \
@shell='$@'; shell=$${shell##*-}; \
which "$$shell" >/dev/null || { printf '\033[0;31m%s\033[0m\n' "WARNING: Cannot test with shell '$$shell': not found." >&2; exit 0; } && \
printf '\n\033[0;34m%s\033[0m\n' "Running tests in $$shell"; \
[ -z "$$TRAVIS_BUILD_DIR" ] && for v in $$(set | awk -F'=' '$$1 ~ "^NVM_" { print $$1 }'); do unset $$v; done && unset v; \
for suite in $(TEST_SUITE); do $(URCHIN) -f -s $$shell test/$$suite || exit; done
for suite in $(TEST_SUITE); do \
echo "Running test suite: $$suite"; \
$(URCHIN) -f -s $$shell test/$$suite || exit; \
done

# All-tests target: invokes the specified test suites for ALL shells defined in $(SHELLS).
.PHONY: test
Expand Down

0 comments on commit 981d19c

Please sign in to comment.