diff --git a/configure/RULES.Db b/configure/RULES.Db index 6c8d8f1c1..fcb7737f4 100644 --- a/configure/RULES.Db +++ b/configure/RULES.Db @@ -134,7 +134,7 @@ ACTIONS += build ACTIONS += install ACTIONS += buildInstall ACTIONS += browse -ACTIONS += runtests tapfiles junitfiles +ACTIONS += runtests tapfiles clean-tests test-results junitfiles actionArchTargets = $(foreach x, $(ACTIONS),\ $(foreach arch,$(BUILD_ARCHS), $(x)$(DIVIDER)$(arch))) @@ -150,6 +150,7 @@ buildInstall : build rebuild: clean install .PHONY: all inc build install clean rebuild buildInstall +.PHONY: runtests tapfiles clean-tests test-results junitfiles $(actionArchTargets) $(BUILD_ARCHS):install $(cleanArchTargets):clean diff --git a/configure/RULES_ARCHS b/configure/RULES_ARCHS index fb0ad523f..abb756fca 100644 --- a/configure/RULES_ARCHS +++ b/configure/RULES_ARCHS @@ -14,7 +14,7 @@ ACTIONS += build ACTIONS += install ACTIONS += buildInstall ACTIONS += browse -ACTIONS += runtests tapfiles junitfiles +ACTIONS += runtests tapfiles clean-tests test-results junitfiles #ACTIONS += rebuild actionArchTargets = $(foreach action, $(ACTIONS), \ diff --git a/configure/RULES_BUILD b/configure/RULES_BUILD index 3762579bd..2c8de45c5 100644 --- a/configure/RULES_BUILD +++ b/configure/RULES_BUILD @@ -354,6 +354,21 @@ testspec: $(TESTSCRIPTS) $(if $^, @echo Tests: $^ >> $@) $(if $(TESTSPEC_$(OS_CLASS)), @echo "Harness: $(TESTSPEC_$(OS_CLASS))" >> $@) +test-results: tapfiles +ifneq ($(TAPFILES),) +ifdef RUNTESTS_ENABLED + prove --failures --ext .tap --exec cat --color $(TAPFILES) +endif +endif + +clean-tests: +ifneq ($(TAPFILES),) + $(RM) $(TAPFILES) +endif +ifneq ($(JUNITFILES),) + $(RM) $(JUNITFILES) +endif + tapfiles: $(TESTSCRIPTS) $(TAPFILES) junitfiles: $(JUNITFILES) @@ -499,7 +514,7 @@ $(INSTALL_TEMPLATES_SUBDIR)/%: % .PRECIOUS: $(COMMON_INC) .PHONY: all inc build install clean rebuild buildInstall -.PHONY: runtests tapfiles junitfiles +.PHONY: runtests tapfiles clean-tests test-results junitfiles .PHONY: checkRelease warnRelease noCheckRelease endif # BASE_RULES_BUILD diff --git a/configure/RULES_DIRS b/configure/RULES_DIRS index eda8d9a05..c798e53c9 100644 --- a/configure/RULES_DIRS +++ b/configure/RULES_DIRS @@ -9,7 +9,7 @@ ARCHS += $(BUILD_ARCHS) ACTIONS += inc build install buildInstall clean realclean archclean -ACTIONS += runtests tapfiles junitfiles +ACTIONS += runtests tapfiles clean-tests test-results junitfiles dirActionArchTargets = $(foreach dir, $(DIRS), \ $(foreach action, $(ACTIONS), \ diff --git a/documentation/RELEASE_NOTES.html b/documentation/RELEASE_NOTES.html index e925334fc..78964d5ee 100644 --- a/documentation/RELEASE_NOTES.html +++ b/documentation/RELEASE_NOTES.html @@ -14,13 +14,38 @@ -
This release adds a new make target junitfiles which if necessary
-runs the self-tests and then converts the TAP (Perl Test-Anything-Protocol)
-output files (as generated by the tapfiles target) into the more
-commonly-recognized JUnit XML format. The program that performs this conversion
-needs the Perl module XML::Generator
to have been installed.
This release adds several new make targets intended for use by developers +and Continuous Integration systems which simplify the task of running the +built-in self-test programs and viewing the results. Since these targets are +intended for limited use they can have requirements for the build host which +go beyond the standard minimum set needed to build and run Base.
+ ++ +test-results — Summarize test results
+ +The new make target test-results will run the self-tests if +necessary to generate a TAP file for each test, then summarizes the TAP output +files in each test directory in turn, displaying the details of any failures. +This step uses the program
+ +provewhich comes with Perl, but also needs +catto be provided in the default search path so will not work on most +Windows systems.junitfiles — Convert test results to JUnit XML Format
+ +The new make target junitfiles will run the self-tests if necessary +and then convert the TAP output files into the more commonly-supported JUnit +XML format. The program that performs this conversion needs the Perl module +
+ +XML::Generatorto have been installed.clean-tests — Delete test result files
+ +The new make target clean-tests removes any test result files from +previous test runs. It cleans both TAP and JUnit XML files.
+ +