diff options
author | yoni206 <yoni206@users.noreply.github.com> | 2021-06-02 09:47:09 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-06-02 16:47:09 +0000 |
commit | 338982182dbdabecf6f3b06e659621cf43bed916 (patch) | |
tree | 37c43593a6573c443457ba55bfbd74385cae771c /test | |
parent | e1d476724171293d324ea9f144d1171d9b36b571 (diff) |
Move `toPythonObj` tests to the new API unit test directory (#6656)
This is the last test file that we move from the old directory to the new one, and so the old directory is deleted.
Diffstat (limited to 'test')
-rw-r--r-- | test/api/CMakeLists.txt | 6 | ||||
-rw-r--r-- | test/api/python/CMakeLists.txt | 41 | ||||
-rw-r--r-- | test/python/CMakeLists.txt | 1 | ||||
-rw-r--r-- | test/python/unit/api/test_to_python_obj.py (renamed from test/api/python/test_to_python_obj.py) | 0 |
4 files changed, 1 insertions, 47 deletions
diff --git a/test/api/CMakeLists.txt b/test/api/CMakeLists.txt index b340ec8ba..e9fd47261 100644 --- a/test/api/CMakeLists.txt +++ b/test/api/CMakeLists.txt @@ -72,9 +72,3 @@ if (USE_EDITLINE) ) endif() endif() - - -# add Python bindings tests if building with Python bindings -if (BUILD_BINDINGS_PYTHON) - add_subdirectory(python) -endif() diff --git a/test/api/python/CMakeLists.txt b/test/api/python/CMakeLists.txt deleted file mode 100644 index 4e77c0ead..000000000 --- a/test/api/python/CMakeLists.txt +++ /dev/null @@ -1,41 +0,0 @@ -############################################################################### -# Top contributors (to current version): -# Makai Mann -# -# This file is part of the cvc5 project. -# -# Copyright (c) 2009-2021 by the authors listed in the file AUTHORS -# in the top-level source directory and their institutional affiliations. -# All rights reserved. See the file COPYING in the top-level source -# directory for licensing information. -# ############################################################################# -# -# The build system configuration. -## - -# Check if the pytest Python module is installed. -execute_process( - COMMAND - ${PYTHON_EXECUTABLE} -c "import pytest" - RESULT_VARIABLE - RET_PYTEST - ERROR_QUIET -) - -if(RET_PYTEST) - message(FATAL_ERROR - "Could not find Python module pytest. Install via `pip install pytest'.") -endif() - -macro(cvc5_add_python_api_test name filename) - - # we create test target 'api/<output_dir>/myapitest' - # and run it with 'ctest -R "api/<output_dir>/myapitest"'. - add_test (NAME api/api/python/${name} - COMMAND ${PYTHON_EXECUTABLE} -m pytest ${CMAKE_CURRENT_SOURCE_DIR}/${filename} - # directory for importing the python bindings - WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/src/api/python) - -endmacro() - -cvc5_add_python_api_test(pytest_to_python_obj test_to_python_obj.py) diff --git a/test/python/CMakeLists.txt b/test/python/CMakeLists.txt index 88fd817f2..54134b510 100644 --- a/test/python/CMakeLists.txt +++ b/test/python/CMakeLists.txt @@ -32,3 +32,4 @@ cvc5_add_python_api_test(pytest_sort unit/api/test_sort.py) cvc5_add_python_api_test(pytest_term unit/api/test_term.py) cvc5_add_python_api_test(pytest_datatype_api unit/api/test_datatype_api.py) cvc5_add_python_api_test(pytest_grammar unit/api/test_grammar.py) +cvc5_add_python_api_test(pytest_to_python_obj unit/api/test_to_python_obj.py) diff --git a/test/api/python/test_to_python_obj.py b/test/python/unit/api/test_to_python_obj.py index 2ba685d50..2ba685d50 100644 --- a/test/api/python/test_to_python_obj.py +++ b/test/python/unit/api/test_to_python_obj.py |