Re: Test 9500 - unhelpful without Perl::CGI
From: Junio C Hamano <hidden>
Date: 2016-06-15 22:51:28
Linus Torvalds [off-list ref] writes:
This has probably been going on forever, and the only reason I noticed is that I had a machine that doesn't have perl-CGI installed. I'm talking about t9500-gitweb-standalone-no-errors. Anyway, if you don't have that, the test fails at everything, and it does so without any clues about _why_ it fails.
Something like this would hopefully suffice. It seems that we do test for the version of Encode, but we do not specifically test CGI or other modules that people do not have to slurp from CPAN? t/gitweb-lib.sh | 5 +++++ 1 files changed, 5 insertions(+), 0 deletions(-)
diff --git a/t/gitweb-lib.sh b/t/gitweb-lib.sh
index 143eb1f..292753f 100644
--- a/t/gitweb-lib.sh
+++ b/t/gitweb-lib.sh@@ -107,4 +107,9 @@ perl -MEncode -e '$e="";decode_utf8($e, Encode::FB_CROAK)' >/dev/null 2>&1 || { test_done } +perl -MCGI -MCGI::Util -MCGI::Carp -e 0 >/dev/null 2>&1 || { + skip_all='skipping gitweb tests, CGI module unusable' + test_done +} + gitweb_init