Improved continuous integration testing #3
Workflow file for this run
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: build/test | |
| on: [push, pull_request] | |
| jobs: | |
| osmatrix: | |
| strategy: | |
| matrix: | |
| # A full list of runners can be found here: | |
| # https://docs.github.com/en/actions/reference/runners/github-hosted-runners | |
| os: [ubuntu-latest, macos-latest, windows-latest] | |
| build-type: [RelWithDebInfo] | |
| cxx-standard: [17,20] | |
| # In theory, we would test on older compilers such as gcc 7.5, clang 9, and vs 2019 | |
| # They are not installed on the runners by default, leaving this as a TODO item for now. | |
| runs-on: ${{ matrix.os }} | |
| steps: | |
| - name: Check Out mdspan | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: kokkos/mdspan | |
| path: mdspan-src | |
| - name: create directories | |
| run: cmake -E make_directory mdspan-build stdblas-build | |
| - name: Configure mdspan | |
| run: cmake -S mdspan-src -B mdspan-build -DMDSPAN_CXX_STANDARD=${{matrix.cxx-standard}} -DCMAKE_BUILD_TYPE=${{matrix.build-type}} -DCMAKE_INSTALL_PREFIX=mdspan-install | |
| - name: Build mdspan | |
| run: cmake --build mdspan-build -j 3 | |
| - name: Install mdspan | |
| run: cmake --install mdspan-build | |
| - name: Check Out stdblas | |
| uses: actions/checkout@v4 | |
| with: | |
| path: stdblas-src | |
| - name: Configure stdblas | |
| run: cmake -S stdblas-src -B stdblas-build -Dmdspan_DIR=mdspan-install -DLINALG_CXX_STANDARD=${{matrix.cxx-standard}} -DLINALG_ENABLE_TESTS=On -DLINALG_ENABLE_EXAMPLES=On -DCMAKE_BUILD_TYPE=${{matrix.build-type}} -DCMAKE_INSTALL_PREFIX=stdblas-install | |
| - name: Build stdblas | |
| run: cmake --build stdblas-build -j 3 | |
| - name: Test stdblas | |
| working-directory: stdblas-build | |
| run: ctest --output-on-failure | |
| - name: Install stdblas | |
| run: cmake --install stdblas-build |