Skip to content
Snippets Groups Projects
Commit 3ce1aec5 authored by Jean-Matthieu Etancelin's avatar Jean-Matthieu Etancelin
Browse files

Fix bug in python setup for tests

parent cb29e1b0
No related branches found
No related tags found
No related merge requests found
...@@ -99,12 +99,14 @@ config = Configuration(name=name, ...@@ -99,12 +99,14 @@ config = Configuration(name=name,
setup(**config.todict()) setup(**config.todict())
cTestFile = open('@CMAKE_CURRENT_BINARY_DIR@/CTestTestfile.cmake','r') # In case of cmake WITH_TESTS=ON
cTestStr = "" if('@WITH_TESTS@' is "ON"):
for line in cTestFile: cTestFile = open('@CMAKE_CURRENT_BINARY_DIR@/CTestTestfile.cmake','r')
cTestStr += line.replace('BUILD_MAIN_PYTEST', config.get_build_temp_dir().replace('temp','lib')+'/parmepy/test/main_unit_tests.py') cTestStr = ""
cTestFile.close() for line in cTestFile:
cTestFile = open('@CMAKE_CURRENT_BINARY_DIR@/CTestTestfile.cmake','w') cTestStr += line.replace('BUILD_MAIN_PYTEST', config.get_build_temp_dir().replace('temp','lib')+'/parmepy/test/main_unit_tests.py')
cTestFile.write(cTestStr) cTestFile.close()
cTestFile.close() cTestFile = open('@CMAKE_CURRENT_BINARY_DIR@/CTestTestfile.cmake','w')
cTestFile.write(cTestStr)
cTestFile.close()
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment