Fix Python test-suite makefile to show which tests have runtime tests (for Python 3).
This commit is contained in:
parent
af8f77a627
commit
72f2d8ac8f
1 changed files with 11 additions and 8 deletions
|
|
@ -110,19 +110,22 @@ VALGRIND_OPT += --suppressions=pythonswig.supp
|
|||
|
||||
# Rules for the different types of tests
|
||||
%.cpptest:
|
||||
+$(convert_testcase)
|
||||
$(setup)
|
||||
+$(swig_and_compile_cpp)
|
||||
+$(run_testcase)
|
||||
$(run_testcase)
|
||||
|
||||
%.ctest:
|
||||
+$(convert_testcase)
|
||||
$(setup)
|
||||
+$(swig_and_compile_c)
|
||||
+$(run_testcase)
|
||||
$(run_testcase)
|
||||
|
||||
%.multicpptest:
|
||||
+$(convert_testcase)
|
||||
$(setup)
|
||||
+$(swig_and_compile_multi_cpp)
|
||||
+$(run_testcase)
|
||||
$(run_testcase)
|
||||
|
||||
|
||||
# Call 2to3 to generate Python 3.x test from the Python 2.x's *_runme.py file
|
||||
|
|
@ -139,17 +142,17 @@ run_python = env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH PYTHONPATH=.:$(srcdir):$$PY
|
|||
py2_runme = $(srcdir)/$(SCRIPTPREFIX)$*$(PY2SCRIPTSUFFIX)
|
||||
py3_runme = $(srcdir)/$(SCRIPTPREFIX)$*$(PY3SCRIPTSUFFIX)
|
||||
|
||||
ifeq (,$(PY3))
|
||||
run_testcase = \
|
||||
if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \
|
||||
$(run_python);\
|
||||
fi
|
||||
|
||||
ifeq (,$(PY3))
|
||||
convert_testcase =
|
||||
else
|
||||
run_testcase = \
|
||||
convert_testcase = \
|
||||
if [ -f $(py2_runme) ]; then \
|
||||
$(MAKE) -f $(srcdir)/Makefile $(py3_runme) && $(run_python); \
|
||||
elif [ -f $(py3_runme) ]; then \
|
||||
$(run_python); \
|
||||
$(MAKE) -f $(srcdir)/Makefile $(py3_runme); \
|
||||
fi
|
||||
endif
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue