Commit ab157ce3 authored by Jeremy C. Reed's avatar Jeremy C. Reed

Exit if a single test script fails.

Also add some comments.


git-svn-id: svn://bind10.isc.org/svn/bind10/branches/trac316@2771 e5f2f494-b856-4b98-b285-d166d9295462
parent cf135a48
#PYTESTS = args_test.py bind10_test.py
PYTESTS = bind10_test.py PYTESTS = bind10_test.py
EXTRA_DIST = $(PYTESTS) EXTRA_DIST = $(PYTESTS)
...@@ -8,5 +9,5 @@ check-local: ...@@ -8,5 +9,5 @@ check-local:
for pytest in $(PYTESTS) ; do \ for pytest in $(PYTESTS) ; do \
echo Running test: $$pytest ; \ echo Running test: $$pytest ; \
env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_builddir)/src/bin/bind10 \ env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_builddir)/src/bin/bind10 \
$(PYCOVERAGE) $(abs_srcdir)/$$pytest ; \ $(PYCOVERAGE) $(abs_srcdir)/$$pytest || exit ; \
done done
...@@ -8,5 +8,5 @@ check-local: ...@@ -8,5 +8,5 @@ check-local:
for pytest in $(PYTESTS) ; do \ for pytest in $(PYTESTS) ; do \
echo Running test: $$pytest ; \ echo Running test: $$pytest ; \
env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_srcdir)/src/bin \ env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_srcdir)/src/bin \
$(PYCOVERAGE) $(abs_srcdir)/$$pytest ; \ $(PYCOVERAGE) $(abs_srcdir)/$$pytest || exit ; \
done done
...@@ -9,5 +9,5 @@ check-local: ...@@ -9,5 +9,5 @@ check-local:
for pytest in $(PYTESTS) ; do \ for pytest in $(PYTESTS) ; do \
echo Running test: $$pytest ; \ echo Running test: $$pytest ; \
env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_builddir)/src/bin/cfgmgr \ env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_builddir)/src/bin/cfgmgr \
$(PYCOVERAGE) $(abs_builddir)/$$pytest ; \ $(PYCOVERAGE) $(abs_builddir)/$$pytest || exit ; \
done done
...@@ -10,5 +10,5 @@ check-local: ...@@ -10,5 +10,5 @@ check-local:
env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_builddir)/src/bin/cmdctl \ env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_builddir)/src/bin/cmdctl \
CMDCTL_SPEC_PATH=$(abs_top_builddir)/src/bin/cmdctl \ CMDCTL_SPEC_PATH=$(abs_top_builddir)/src/bin/cmdctl \
CMDCTL_SRC_PATH=$(abs_top_srcdir)/src/bin/cmdctl \ CMDCTL_SRC_PATH=$(abs_top_srcdir)/src/bin/cmdctl \
$(PYCOVERAGE) $(abs_srcdir)/$$pytest ; \ $(PYCOVERAGE) $(abs_srcdir)/$$pytest || exit ; \
done done
...@@ -46,5 +46,5 @@ EXTRA_DIST += tests/normal/sql2.example.com ...@@ -46,5 +46,5 @@ EXTRA_DIST += tests/normal/sql2.example.com
EXTRA_DIST += tests/normal/sql2.example.com.signed EXTRA_DIST += tests/normal/sql2.example.com.signed
pytest: pytest:
$(SHELL) tests/correct/correct_test.sh $(SHELL) tests/correct/correct_test.sh-NOEXIST
$(SHELL) tests/error/error_test.sh $(SHELL) tests/error/error_test.sh
# TODO: this is a not a python script!
PYTESTS = correct_test.sh PYTESTS = correct_test.sh
EXTRA_DIST = get_zonedatas.py EXTRA_DIST = get_zonedatas.py
EXTRA_DIST += include.db EXTRA_DIST += include.db
...@@ -21,5 +22,5 @@ check-local: ...@@ -21,5 +22,5 @@ check-local:
for pytest in $(PYTESTS) ; do \ for pytest in $(PYTESTS) ; do \
echo Running test: $$pytest ; \ echo Running test: $$pytest ; \
env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_builddir)/src/bin/loadzone \ env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_builddir)/src/bin/loadzone \
$(SHELL) $(abs_builddir)/$$pytest ; \ $(SHELL) $(abs_builddir)/$$pytest || exit ; \
done done
# TODO: this is not a python script
PYTESTS = error_test.sh PYTESTS = error_test.sh
EXTRA_DIST = error.known EXTRA_DIST = error.known
...@@ -21,5 +22,5 @@ check-local: ...@@ -21,5 +22,5 @@ check-local:
for pytest in $(PYTESTS) ; do \ for pytest in $(PYTESTS) ; do \
echo Running test: $$pytest ; \ echo Running test: $$pytest ; \
env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/bin/loadzone \ env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/bin/loadzone \
$(SHELL) $(abs_builddir)/$$pytest ; \ $(SHELL) $(abs_builddir)/$$pytest || exit ; \
done done
...@@ -8,6 +8,6 @@ check-local: ...@@ -8,6 +8,6 @@ check-local:
for pytest in $(PYTESTS) ; do \ for pytest in $(PYTESTS) ; do \
echo Running test: $$pytest ; \ echo Running test: $$pytest ; \
env PYTHONPATH=$(abs_top_builddir)/src/bin/msgq:$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python \ env PYTHONPATH=$(abs_top_builddir)/src/bin/msgq:$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python \
$(PYCOVERAGE) $(abs_srcdir)/$$pytest ; \ $(PYCOVERAGE) $(abs_srcdir)/$$pytest || exit ; \
done done
...@@ -8,5 +8,5 @@ check-local: ...@@ -8,5 +8,5 @@ check-local:
for pytest in $(PYTESTS) ; do \ for pytest in $(PYTESTS) ; do \
echo Running test: $$pytest ; \ echo Running test: $$pytest ; \
env PYTHONPATH=$(abs_top_builddir)/src/lib/dns/python/.libs:$(abs_top_builddir)/src/bin/xfrin:$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python \ env PYTHONPATH=$(abs_top_builddir)/src/lib/dns/python/.libs:$(abs_top_builddir)/src/bin/xfrin:$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python \
$(PYCOVERAGE) $(abs_srcdir)/$$pytest ; \ $(PYCOVERAGE) $(abs_srcdir)/$$pytest || exit ; \
done done
...@@ -8,5 +8,5 @@ check-local: ...@@ -8,5 +8,5 @@ check-local:
for pytest in $(PYTESTS) ; do \ for pytest in $(PYTESTS) ; do \
echo Running test: $$pytest ; \ echo Running test: $$pytest ; \
env PYTHONPATH=$(abs_top_builddir)/src/bin/xfrout:$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_builddir)/src/lib/dns/python/.libs:$(abs_top_builddir)/src/lib/xfr/.libs \ env PYTHONPATH=$(abs_top_builddir)/src/bin/xfrout:$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_builddir)/src/lib/dns/python/.libs:$(abs_top_builddir)/src/lib/xfr/.libs \
$(PYCOVERAGE) $(abs_srcdir)/$$pytest ; \ $(PYCOVERAGE) $(abs_srcdir)/$$pytest || exit ; \
done done
...@@ -8,5 +8,5 @@ check-local: ...@@ -8,5 +8,5 @@ check-local:
for pytest in $(PYTESTS) ; do \ for pytest in $(PYTESTS) ; do \
echo Running test: $$pytest ; \ echo Running test: $$pytest ; \
env PYTHONPATH=$(abs_top_builddir)/src/bin/zonemgr:$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_builddir)/src/lib/dns/.libs:$(abs_top_builddir)/src/lib/dns/python/.libs:$(abs_top_builddir)/src/lib/xfr/.libs \ env PYTHONPATH=$(abs_top_builddir)/src/bin/zonemgr:$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_builddir)/src/lib/dns/.libs:$(abs_top_builddir)/src/lib/dns/python/.libs:$(abs_top_builddir)/src/lib/xfr/.libs \
$(PYCOVERAGE) $(abs_srcdir)/$$pytest ; \ $(PYCOVERAGE) $(abs_srcdir)/$$pytest || exit ; \
done done
...@@ -18,5 +18,5 @@ check-local: ...@@ -18,5 +18,5 @@ check-local:
echo Running test: $$pytest ; \ echo Running test: $$pytest ; \
env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_builddir)/src/lib/dns/python/.libs \ env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_builddir)/src/lib/dns/python/.libs \
TESTDATA_PATH=$(abs_top_srcdir)/src/lib/dns/tests/testdata \ TESTDATA_PATH=$(abs_top_srcdir)/src/lib/dns/tests/testdata \
$(PYCOVERAGE) $(abs_srcdir)/$$pytest ; \ $(PYCOVERAGE) $(abs_srcdir)/$$pytest || exit ; \
done done
...@@ -12,5 +12,5 @@ check-local: ...@@ -12,5 +12,5 @@ check-local:
echo Running test: $$pytest ; \ echo Running test: $$pytest ; \
env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python \ env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python \
BIND10_TEST_SOCKET_FILE=$(builddir)/test_socket.sock \ BIND10_TEST_SOCKET_FILE=$(builddir)/test_socket.sock \
$(PYCOVERAGE) $(abs_srcdir)/$$pytest ; \ $(PYCOVERAGE) $(abs_srcdir)/$$pytest || exit ; \
done done
...@@ -11,5 +11,5 @@ check-local: ...@@ -11,5 +11,5 @@ check-local:
echo Running test: $$pytest ; \ echo Running test: $$pytest ; \
env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python \ env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python \
CONFIG_TESTDATA_PATH=$(abs_top_srcdir)/src/lib/config/testdata \ CONFIG_TESTDATA_PATH=$(abs_top_srcdir)/src/lib/config/testdata \
$(PYCOVERAGE) $(abs_srcdir)/$$pytest ; \ $(PYCOVERAGE) $(abs_srcdir)/$$pytest || exit ; \
done done
...@@ -8,5 +8,5 @@ check-local: ...@@ -8,5 +8,5 @@ check-local:
for pytest in $(PYTESTS) ; do \ for pytest in $(PYTESTS) ; do \
echo Running test: $$pytest ; \ echo Running test: $$pytest ; \
env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_builddir)/src/lib/python/isc/log \ env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_builddir)/src/lib/python/isc/log \
$(PYCOVERAGE) $(abs_srcdir)/$$pytest ; \ $(PYCOVERAGE) $(abs_srcdir)/$$pytest || exit ; \
done done
...@@ -8,5 +8,5 @@ check-local: ...@@ -8,5 +8,5 @@ check-local:
for pytest in $(PYTESTS) ; do \ for pytest in $(PYTESTS) ; do \
echo Running test: $$pytest ; \ echo Running test: $$pytest ; \
env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_builddir)/src/lib/dns/python/.libs \ env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_builddir)/src/lib/dns/python/.libs \
$(PYCOVERAGE) $(abs_srcdir)/$$pytest ; \ $(PYCOVERAGE) $(abs_srcdir)/$$pytest || exit ; \
done done
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment