Skip to content

Commit

Permalink
build: test python module in workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
gudzpoz committed Feb 4, 2024
1 parent 42a2121 commit 0242b68
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion .github/workflows/cmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ jobs:
- name: Configure CMake
# Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make.
# See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type
run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} ${{matrix.config.cmake_args}} -DBUILD_DEBUG=ON -DPython_FIND_VERSION_MAJOR=${{matrix.config.PY_MAJOR}}
run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} ${{matrix.config.cmake_args}} -DBUILD_DEBUG=ON -DPython_FIND_VERSION_MAJOR=${{matrix.config.PY_MAJOR}}
env:
BOOST_ROOT: ${{ steps.install-boost.outputs.BOOST_ROOT }}

Expand All @@ -73,3 +73,8 @@ jobs:
# Execute tests defined by the CMake configuration.
# See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail
run: ctest -C ${{env.BUILD_TYPE}} || ctest -C ${{env.BUILD_TYPE}} --rerun-failed --output-on-failure

- name: Python Tests
run: |
sudo cmake --install ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}
python3 -m unittest discover test/python -p '*.py'

0 comments on commit 0242b68

Please sign in to comment.