Merge branch 'develop' into cmake-3.16
This commit is contained in:
@ -79,13 +79,10 @@ if(Python_EXECUTABLE)
|
||||
WORKING_DIRECTORY ${EXECUTABLE_OUTPUT_PATH})
|
||||
set_tests_properties(PythonOpen PROPERTIES ENVIRONMENT "${PYTHON_TEST_ENVIRONMENT}")
|
||||
|
||||
# some of the tests in this file will fail without exceptions enabled
|
||||
if(LAMMPS_EXCEPTIONS)
|
||||
add_test(NAME PythonCommands
|
||||
COMMAND ${PYTHON_TEST_RUNNER} ${CMAKE_CURRENT_SOURCE_DIR}/python-commands.py -v
|
||||
WORKING_DIRECTORY ${EXECUTABLE_OUTPUT_PATH})
|
||||
set_tests_properties(PythonCommands PROPERTIES ENVIRONMENT "${PYTHON_TEST_ENVIRONMENT}")
|
||||
endif()
|
||||
add_test(NAME PythonCommands
|
||||
COMMAND ${PYTHON_TEST_RUNNER} ${CMAKE_CURRENT_SOURCE_DIR}/python-commands.py -v
|
||||
WORKING_DIRECTORY ${EXECUTABLE_OUTPUT_PATH})
|
||||
set_tests_properties(PythonCommands PROPERTIES ENVIRONMENT "${PYTHON_TEST_ENVIRONMENT}")
|
||||
|
||||
add_test(NAME PythonNumpy
|
||||
COMMAND ${PYTHON_TEST_RUNNER} ${CMAKE_CURRENT_SOURCE_DIR}/python-numpy.py -v
|
||||
|
||||
@ -4,7 +4,7 @@ from lammps import lammps
|
||||
|
||||
has_mpi=False
|
||||
has_mpi4py=False
|
||||
has_exceptions=False
|
||||
|
||||
try:
|
||||
from mpi4py import __version__ as mpi4py_version
|
||||
# tested to work with mpi4py versions 2 and 3
|
||||
@ -19,7 +19,6 @@ try:
|
||||
machine = ""
|
||||
lmp = lammps(name=machine)
|
||||
has_mpi = lmp.has_mpi_support
|
||||
has_exceptions = lmp.has_exceptions
|
||||
lmp.close()
|
||||
except:
|
||||
pass
|
||||
@ -79,7 +78,6 @@ class PythonOpen(unittest.TestCase):
|
||||
self.assertEqual(lmp.opened,1)
|
||||
lmp.close()
|
||||
|
||||
@unittest.skipIf(not has_exceptions,"Skipping death test since LAMMPS isn't compiled with exception support")
|
||||
def testUnknownCommand(self):
|
||||
lmp = lammps(name=self.machine)
|
||||
|
||||
@ -88,7 +86,6 @@ class PythonOpen(unittest.TestCase):
|
||||
|
||||
lmp.close()
|
||||
|
||||
@unittest.skipIf(not has_exceptions,"Skipping death test since LAMMPS isn't compiled with exception support")
|
||||
def testUnknownCommandInList(self):
|
||||
lmp = lammps(name=self.machine)
|
||||
|
||||
@ -97,7 +94,6 @@ class PythonOpen(unittest.TestCase):
|
||||
|
||||
lmp.close()
|
||||
|
||||
@unittest.skipIf(not has_exceptions,"Skipping death test since LAMMPS isn't compiled with exception support")
|
||||
def testUnknownCommandInString(self):
|
||||
lmp = lammps(name=self.machine)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user