From: Amos Jeffries Date: Sat, 28 Sep 2013 09:01:23 +0000 (-0600) Subject: Automated squid.conf parser testing with squid -k parse X-Git-Tag: SQUID_3_5_0_1~630 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=9b2c99ced33a7c35891ae916fec77f18d81ddb44;p=thirdparty%2Fsquid.git Automated squid.conf parser testing with squid -k parse This make the build process testing run 'squid -k parse' with a series of test configuration files to exercise edge cases and backward compatibility. The default squid.conf which is to be installed on new systems is always tested. Other config files with unit tests can be dropped into test-suite/squidconf/ and will be parse tested automatically. --- diff --git a/test-suite/Makefile.am b/test-suite/Makefile.am index fa486c8767..a917a61564 100644 --- a/test-suite/Makefile.am +++ b/test-suite/Makefile.am @@ -34,7 +34,8 @@ TESTS += debug \ MemPoolTest\ mem_node_test\ mem_hdr_test\ - $(ESI_TESTS) + $(ESI_TESTS) \ + squid-conf-tests ## Sort by alpha - any build failures are significant. check_PROGRAMS += debug \ @@ -111,3 +112,9 @@ VirtualDeleteOperator_SOURCES = VirtualDeleteOperator.cc $(DEBUG_SOURCE) ## ##$(TARGLIB): $(LIBOBJS) ## $(AR_R) $(TARGLIB) $(LIBOBJS) + +squid-conf-tests: + ../src/squid -k parse -f ../src/squid.conf.default || exit 1 + for t in `ls -1 $(srcdir)/squidconf/*`; do + ../src/squid -k parse -f $t || exit 1 + done diff --git a/test-suite/squidconf/empty b/test-suite/squidconf/empty new file mode 100644 index 0000000000..e69de29bb2