diff --git a/src/Makefile.am b/src/Makefile.am index fc731a53..650141e9 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -20,7 +20,7 @@ endif EXTRA_DIST = tests AM_TESTS_ENVIRONMENT = \ - TESTDIR=$(abs_top_builddir)/src/tests; export TESTDIR; \ + TESTDIR=$(abs_top_builddir)/src/tests/; export TESTDIR; \ PATH=$(abs_top_builddir)/src:$$PATH; export PATH; TESTS = tests/test01-start-and-stop \ diff --git a/src/tests/runtests b/src/tests/runtests deleted file mode 100755 index f89ff644..00000000 --- a/src/tests/runtests +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/bash -# (until we get automake/autoconf configured right.) - -set -o errexit - -for t in test*; do - echo -n -e "$t\t" - bash $t - if [ "$?" != "0" ]; then - echo "FAILED" - else - echo "OK" - fi -done - diff --git a/src/tests/test02-simple-request b/src/tests/test02-simple-request index 2cabdaa0..a840613a 100755 --- a/src/tests/test02-simple-request +++ b/src/tests/test02-simple-request @@ -2,7 +2,7 @@ # Test basic argument handling. # This implements T2 in the original test plan. -. common.sh +. ${TESTDIR}common.sh set -o errexit hitch $HITCH_ARGS --backend=[hitch-tls.org]:80 "--frontend=[${LISTENADDR}]:$LISTENPORT" certs/site1.example.com diff --git a/src/tests/test03-multiple-listen b/src/tests/test03-multiple-listen index d6967827..60816796 100755 --- a/src/tests/test03-multiple-listen +++ b/src/tests/test03-multiple-listen @@ -3,7 +3,7 @@ # Test multiple listening sockets. # # This implements T3 in the original test plan. -. common.sh +. ${TESTDIR}common.sh PORT2=$(($RANDOM + 1024)) diff --git a/src/tests/test04-listen-with-own-certs b/src/tests/test04-listen-with-own-certs index a0b97a16..9f8df813 100755 --- a/src/tests/test04-listen-with-own-certs +++ b/src/tests/test04-listen-with-own-certs @@ -4,7 +4,7 @@ # # This implements T3 in the original test plan. -. common.sh +. ${TESTDIR}common.sh PORT2=$(($RANDOM + 1024)) diff --git a/src/tests/test05-multiple-listen-SNI b/src/tests/test05-multiple-listen-SNI index 9ffb800d..6e832b2a 100755 --- a/src/tests/test05-multiple-listen-SNI +++ b/src/tests/test05-multiple-listen-SNI @@ -4,7 +4,7 @@ # # This implements T4 in the original test plan. -. common.sh +. ${TESTDIR}common.sh #PORT2=$(($RANDOM + 1024)) diff --git a/src/tests/test06-ticket-resume b/src/tests/test06-ticket-resume index b71776ef..3b9b39f9 100755 --- a/src/tests/test06-ticket-resume +++ b/src/tests/test06-ticket-resume @@ -2,7 +2,7 @@ # # Test resuming a session via a session ticket -. common.sh +. ${TESTDIR}common.sh set +o errexit sessfile=$(mktemp) diff --git a/src/tests/test07-nomatch-abort b/src/tests/test07-nomatch-abort index 9ac1386c..69fa4a77 100755 --- a/src/tests/test07-nomatch-abort +++ b/src/tests/test07-nomatch-abort @@ -2,7 +2,7 @@ # # Test --sni-nomatch-abort # -. common.sh +. ${TESTDIR}common.sh set +o errexit #PORT2=$(($RANDOM + 1024)) diff --git a/src/tests/test08-test-configs b/src/tests/test08-test-configs index ccacc64a..15982378 100755 --- a/src/tests/test08-test-configs +++ b/src/tests/test08-test-configs @@ -1,6 +1,6 @@ #/bin/bash # Test configuration parser. -. common.sh +. ${TESTDIR}common.sh set +o errexit hitch --test --config=configs/default.cfg certs/default.example.com 2>/dev/null 1>&2 diff --git a/src/tests/test09-wildcard-cert b/src/tests/test09-wildcard-cert index 54413862..6cddac56 100755 --- a/src/tests/test09-wildcard-cert +++ b/src/tests/test09-wildcard-cert @@ -1,6 +1,6 @@ #/bin/bash -. common.sh +. ${TESTDIR}common.sh set +o errexit hitch $HITCH_ARGS --backend=[hitch-tls.org]:80 "--frontend=[${LISTENADDR}]:$LISTENPORT" certs/wildcard.example.com certs/default.example.com diff --git a/src/tests/test10-dflt-certs b/src/tests/test10-dflt-certs index 40c59ba4..6cacf576 100755 --- a/src/tests/test10-dflt-certs +++ b/src/tests/test10-dflt-certs @@ -1,8 +1,7 @@ #/bin/bash # -# # -. common.sh +. ${TESTDIR}common.sh set +o errexit PORT1=$(($RANDOM + 1024)) diff --git a/src/tests/test11-cfg b/src/tests/test11-cfg index 11d7c88c..6127e99a 100755 --- a/src/tests/test11-cfg +++ b/src/tests/test11-cfg @@ -1,6 +1,6 @@ #/bin/bash -. common.sh +. ${TESTDIR}common.sh set +o errexit diff --git a/src/tests/test12-cfg b/src/tests/test12-cfg index fa5e0321..5f7f5cf1 100755 --- a/src/tests/test12-cfg +++ b/src/tests/test12-cfg @@ -1,9 +1,8 @@ #/bin/bash -. common.sh +. ${TESTDIR}common.sh set +o errexit - mk_cfg <