From f8c17e79fab13a3d1de976c1c3564df7f8c2a175 Mon Sep 17 00:00:00 2001 From: Joseph Myers Date: Thu, 27 Feb 2014 03:25:27 +0000 Subject: Support expected failures in .test-result files. This patch, an updated version of , makes it possible for .test-result files for individual tests to contain XPASS and XFAIL rather than PASS and FAIL in cases where failure is expected. This replaces the marking of two individual tests with "-" to cause them to be expected at makefile level to fail; evaluate-test.sh will ensure it exits with status 0 for an expected failure. Tested x86_64. * scripts/evaluate-test.sh: Take new argument indicating whether failure is expected. * Makeconfig (evaluate-test): Pass argument to evaluate-test.sh indicating whether failure is expected. * conform/Makefile (test-xfail-run-conformtest): New variable. ($(objpfx)run-conformtest.out): Don't expect to fail at makefile level. * posix/Makefile (test-xfail-annexc): New variable. ($(objpfx)annexc.out): Don't expect to fail at makefile level. --- Makeconfig | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'Makeconfig') diff --git a/Makeconfig b/Makeconfig index 21a7d6ea65..3709c88a45 100644 --- a/Makeconfig +++ b/Makeconfig @@ -1083,8 +1083,11 @@ endif # The name to give to a test in test results summaries. test-name = $(strip $(patsubst %.out, %, $(patsubst $(common-objpfx)%, %, $@))) -# Command to output a test status line (such as PASS: test-name). +# Command to output a test status line (such as PASS: test-name). If +# test-xfail-$(@F:.out=) has a nonempty value, the status will be +# XPASS or XFAIL rather than PASS or FAIL. evaluate-test = $(..)scripts/evaluate-test.sh $(test-name) $$? \ + $(if $(test-xfail-$(@F:.out=)),true,false) \ > $(common-objpfx)$(test-name).test-result endif # Makeconfig not yet included -- cgit 1.4.1