From: Wouter Wijngaards Date: Mon, 16 Aug 2010 12:59:37 +0000 (+0000) Subject: - make test more portable (make longtest needs special support programs, X-Git-Tag: release-1.4.7rc1~111 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a34fe6ea8a865ca9bcac2f85c10ea8edbe69ed61;p=thirdparty%2Funbound.git - make test more portable (make longtest needs special support programs, ldns, wdiff, dig, port-numbers). - moved not-always-portable testbound scripts to names .crpl. git-svn-id: file:///svn/unbound/trunk@2214 be551aaa-1e26-0410-a405-d3ace91eadb9 --- diff --git a/Makefile.in b/Makefile.in index 7a0ff4e2e..aabd0f118 100644 --- a/Makefile.in +++ b/Makefile.in @@ -179,7 +179,7 @@ COMPILE=$(LIBTOOL) --tag=CC --mode=compile $(CC) $(CPPFLAGS) $(CFLAGS) LINK=$(LIBTOOL) --tag=CC --mode=link $(strip $(CC) $(staticexe) $(RUNTIME_PATH) $(CFLAGS) $(LDFLAGS)) LINK_LIB=$(LIBTOOL) --tag=CC --mode=link $(strip $(CC) $(RUNTIME_PATH) $(CFLAGS) $(LDFLAGS) $(staticexe) -version-number @LIBUNBOUND_CURRENT@:@LIBUNBOUND_REVISION@:@LIBUNBOUND_AGE@ -no-undefined) -.PHONY: clean realclean doc lint all install uninstall tests test download_ldns strip lib +.PHONY: clean realclean doc lint all install uninstall tests test download_ldns strip lib longtest longcheck check $(BUILD)%.lo: $(srcdir)/%.c $(INFO) Build $< @@ -194,7 +194,15 @@ TEST_BIN=$(addsuffix $(EXEEXT),asynclook delayer harvest lock-verify \ memstats perf pktview signit streamtcp testbound unittest) tests: all $(TEST_BIN) -test: tests +check: test +longcheck: longtest + +test: unittest$(EXEEXT) testbound$(EXEEXT) + ./unittest$(EXEEXT) + for x in testdata/*.rpl; do if ./testbound$(EXEEXT) -p $$x >/dev/null 2>&1; then echo $$x OK; else echo $$x failed; exit 1; fi done + @echo test OK + +longtest: tests if test -x "`which bash`"; then bash testcode/do-tests.sh; else sh testcode/do-tests.sh; fi lib: libunbound.la diff --git a/doc/Changelog b/doc/Changelog index 024ddec99..444377abd 100644 --- a/doc/Changelog +++ b/doc/Changelog @@ -1,6 +1,8 @@ 16 August 2010: Wouter - Fix acx_nlnetlabs.m4 configure output for autoconf-2.66 AS_TR_CPP changes, uses m4_bpatsubst now. + - make test (or make check) should be more portable and run the unit + test and testbound scripts. (make longtest has special requirements). 13 August 2010: Wouter - More pleasant remote control command parsing. diff --git a/testdata/03-testbound.tpkg b/testdata/03-testbound.tpkg index 432e94264..30a184564 100644 Binary files a/testdata/03-testbound.tpkg and b/testdata/03-testbound.tpkg differ diff --git a/testdata/val_ds_gost.rpl b/testdata/val_ds_gost.crpl similarity index 100% rename from testdata/val_ds_gost.rpl rename to testdata/val_ds_gost.crpl diff --git a/testdata/val_ds_gost_downgrade.rpl b/testdata/val_ds_gost_downgrade.crpl similarity index 100% rename from testdata/val_ds_gost_downgrade.rpl rename to testdata/val_ds_gost_downgrade.crpl diff --git a/testdata/val_ds_sha2.rpl b/testdata/val_ds_sha2.crpl similarity index 100% rename from testdata/val_ds_sha2.rpl rename to testdata/val_ds_sha2.crpl diff --git a/testdata/val_ds_sha2_downgrade.rpl b/testdata/val_ds_sha2_downgrade.crpl similarity index 100% rename from testdata/val_ds_sha2_downgrade.rpl rename to testdata/val_ds_sha2_downgrade.crpl