gnucash unstable: Provide fallback value for test_core_dir in case it hasn't been built yet.
John Ralls
jralls at code.gnucash.org
Fri Mar 9 16:48:44 EST 2018
Updated via https://github.com/Gnucash/gnucash/commit/c9f3c076 (commit)
from https://github.com/Gnucash/gnucash/commit/fbb172d0 (commit)
commit c9f3c0760cb06225e4c011af2bceafe7029e17e0
Author: John Ralls <jralls at ceridwen.us>
Date: Fri Mar 9 13:48:36 2018 -0800
Provide fallback value for test_core_dir in case it hasn't been built yet.
diff --git a/bindings/python/tests/CMakeLists.txt b/bindings/python/tests/CMakeLists.txt
index 93476ff..ea5e5f2 100644
--- a/bindings/python/tests/CMakeLists.txt
+++ b/bindings/python/tests/CMakeLists.txt
@@ -1,6 +1,10 @@
IF (WITH_PYTHON)
find_path(test_core_dir "unittest_support.py" PATHS ${CMAKE_BINARY_DIR}/common/test-core ${CMAKE_SOURCE_DIR}/common/test-core)
+ if (${test_core_dir} STREQUAL "test_core_dir-NOTFOUND")
+ # Because it hasn't been built yet
+ set(test_core_dir ${CMAKE_BINARY_DIR}/common/test-core)
+ endif()
add_custom_target(test-python-bindings ALL DEPENDS unittest_support gnucash-core-c-build gnucash-core-c-py)
add_dependencies(check test-python-bindings)
ADD_TEST(python-bindings ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/runTests.py.in)
Summary of changes:
bindings/python/tests/CMakeLists.txt | 4 ++++
1 file changed, 4 insertions(+)
More information about the gnucash-changes
mailing list