tests #63
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: tests | |
| on: | |
| push: | |
| branches: [ main ] | |
| pull_request: | |
| branches: [ main ] | |
| # Run tests once a week on Sunday. | |
| schedule: | |
| - cron: "0 6 * * 0" | |
| jobs: | |
| run-tests: | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| sphinx: [ "5", "6", "7", "8" ] | |
| cmake: [ "3.20", "4.1" ] | |
| os: [ "ubuntu", "macos", "windows" ] | |
| python: [ "3.8", "3.12", "3.13" ] | |
| exclude: | |
| - sphinx: "8" | |
| python: "3.8" | |
| - sphinx: "5" | |
| python: "3.13" | |
| name: | | |
| v${{ matrix.sphinx }}-${{ matrix.cmake }} | |
| [${{ matrix.os }}-py${{ matrix.python }}] | |
| runs-on: "${{ matrix.os }}-latest" | |
| env: | |
| BUNDLE_PYTHON_TESTS: ${{ matrix.bundled }} | |
| steps: | |
| - uses: actions/setup-python@v5 | |
| with: | |
| python-version: "${{ matrix.python }}" | |
| - uses: actions/checkout@v4 | |
| - name: Setup cmake | |
| uses: jwlawson/actions-setup-cmake@v2.0 | |
| if: ${{matrix.os != 'windows' || matrix.cmake != '3.20'}} | |
| with: | |
| cmake-version: "${{ matrix.cmake }}.x" | |
| - name: Setup cmake (Bump up CMake minimal version for Visual Studio 17 2022) | |
| uses: jwlawson/actions-setup-cmake@v2.0 | |
| if: ${{matrix.os == 'windows' && matrix.cmake == '3.20'}} | |
| with: | |
| # Visual Studio 17 2022 requires at least CMake 3.21. | |
| # https://cmake.org/cmake/help/latest/generator/Visual%20Studio%2017%202022.html | |
| cmake-version: "3.21.x" | |
| - name: Install sphinx + sphinx-cmake | |
| run: pip install . sphinx==${{ matrix.sphinx }}.* | |
| - name: Build Tests | |
| run: | | |
| cmake --version | |
| cmake -S ./test -B ./build | |
| cmake --build ./build --config Release | |
| - name: Run Tests | |
| working-directory: build | |
| run: ctest -VV -C Release |