Makefile.am 826 Bytes
Newer Older
1 2 3
PYTESTS = notify_out_test.py
EXTRA_DIST = $(PYTESTS)

4 5 6 7 8 9 10
# If necessary (rare cases), explicitly specify paths to dynamic libraries
# required by loadable python modules.
B10_LIBRARY_PATH =
if SET_ENV_LIBRARY_PATH
B10_LIBRARY_PATH += $(ENV_LIBRARY_PATH)=$(abs_top_builddir)/src/lib/dns/.libs:$(abs_top_builddir)/src/lib/exceptions/.libs:$$$(ENV_LIBRARY_PATH)
endif

11 12 13 14 15 16
# later will have configure option to choose this, like: coverage run --branch
PYCOVERAGE = $(PYTHON)
# test using command-line arguments, so use check-local target instead of TESTS
check-local:
	for pytest in $(PYTESTS) ; do \
	echo Running test: $$pytest ; \
Jelte Jansen's avatar
Jelte Jansen committed
17
	env PYTHONPATH=$(abs_top_srcdir)/src/lib/python:$(abs_top_builddir)/src/lib/python:$(abs_top_builddir)/src/lib/dns/python/.libs \
18
	$(B10_LIBRARY_PATH) \
19 20
	$(PYCOVERAGE) $(abs_srcdir)/$$pytest ; \
	done