From 868fb04577daf9c47a4a2bcdd9a92cb78e6cf056 Mon Sep 17 00:00:00 2001 From: Ralf Wildenhues Date: Sat, 28 Mar 2009 21:01:43 +0100 Subject: [PATCH] check-html: Always create HTML output, note conversion failure. * lib/am/check.am (check-html): Create `$(TEST_SUITE_HTML)' in any case. Exit unsuccessfully if HTML creation failed. * tests/parallel-tests2.test: Amend test to expose this. Signed-off-by: Ralf Wildenhues --- ChangeLog | 7 +++++++ lib/Automake/tests/Makefile.in | 10 +++++----- lib/am/check.am | 10 +++++----- tests/Makefile.in | 10 +++++----- tests/parallel-tests2.test | 7 +++++++ 5 files changed, 29 insertions(+), 15 deletions(-) diff --git a/ChangeLog b/ChangeLog index b4c7b4b..f063cde 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2009-03-28 Ralf Wildenhues + + check-html: Always create HTML output, note conversion failure. + * lib/am/check.am (check-html): Create `$(TEST_SUITE_HTML)' in + any case. Exit unsuccessfully if HTML creation failed. + * tests/parallel-tests2.test: Amend test to expose this. + 2009-03-24 Ralf Wildenhues parallel-tests: per-extension test driver: _LOG_COMPILER. diff --git a/lib/Automake/tests/Makefile.in b/lib/Automake/tests/Makefile.in index c732762..73e27ff 100644 --- a/lib/Automake/tests/Makefile.in +++ b/lib/Automake/tests/Makefile.in @@ -411,11 +411,11 @@ check-TESTS: # Be sure to run check-TESTS first, and then to convert the result. # Beware of concurrent executions. And expect check-TESTS to fail. check-html: - @if $(MAKE) $(AM_MAKEFLAGS) check-TESTS; then :; else \ - rv=$$?; \ - $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_HTML); \ - exit $$rv; \ - fi + @if $(MAKE) $(AM_MAKEFLAGS) check-TESTS; then \ + rv=0; else rv=$$?; \ + fi; \ + $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_HTML) || exit 4; \ + exit $$rv .pl.log: @p='$<'; $(am__check_pre) $(PL_LOG_COMPILE) "$$tst" $(am__check_post) diff --git a/lib/am/check.am b/lib/am/check.am index 28af2ee..b8b512e 100644 --- a/lib/am/check.am +++ b/lib/am/check.am @@ -266,11 +266,11 @@ check-TESTS: # Be sure to run check-TESTS first, and then to convert the result. # Beware of concurrent executions. And expect check-TESTS to fail. check-html: - @if $(MAKE) $(AM_MAKEFLAGS) check-TESTS; then :; else \ - rv=$$?; \ - $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_HTML); \ - exit $$rv; \ - fi + @if $(MAKE) $(AM_MAKEFLAGS) check-TESTS; then \ + rv=0; else rv=$$?; \ + fi; \ + $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_HTML) || exit 4; \ + exit $$rv .PHONY: check-html .MAKE: check-html diff --git a/tests/Makefile.in b/tests/Makefile.in index 49cb2a2..7547a2c 100644 --- a/tests/Makefile.in +++ b/tests/Makefile.in @@ -1122,11 +1122,11 @@ check-TESTS: # Be sure to run check-TESTS first, and then to convert the result. # Beware of concurrent executions. And expect check-TESTS to fail. check-html: - @if $(MAKE) $(AM_MAKEFLAGS) check-TESTS; then :; else \ - rv=$$?; \ - $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_HTML); \ - exit $$rv; \ - fi + @if $(MAKE) $(AM_MAKEFLAGS) check-TESTS; then \ + rv=0; else rv=$$?; \ + fi; \ + $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_HTML) || exit 4; \ + exit $$rv .test.log: @p='$<'; $(am__check_pre) $(TEST_LOG_COMPILE) "$$tst" $(am__check_post) diff --git a/tests/parallel-tests2.test b/tests/parallel-tests2.test index 17a5108..61b05e8 100755 --- a/tests/parallel-tests2.test +++ b/tests/parallel-tests2.test @@ -56,4 +56,11 @@ $AUTOMAKE -a $MAKE check-html >stdout && { cat stdout; Exit 1; } cat stdout test -f mylog.html + +# Always create the HTML output, even if there were no failures. +rm -f mylog.html +env TESTS=foo.test $MAKE -e check-html >stdout || { cat stdout; Exit 1; } +cat stdout +test -f mylog.html + : -- 2.7.4