diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index a3075256..4ad01dd2 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -10,36 +10,26 @@ jobs: strategy: matrix: os: [macos-latest, ubuntu-latest, windows-latest] + package: [atchops, atclient] runs-on: ${{ matrix.os }} steps: - uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - - - name: atchops - CMake Configure - working-directory: packages/atchops - run: | - cmake -S . -B build -DATCHOPS_BUILD_TESTS=ON -DCMAKE_INSTALL_PREFIX=./install - - - name: atchops - Build with Unix Makefiles - working-directory: packages/atchops - run: | - cmake --build build --target install - - - name: atchops - Run CTest - working-directory: packages/atchops/build/tets + - name: CMake Configure, Make Install, and CTest + uses: threeal/cmake-action@v1.3.0 + with: + source-dir: packages/${{ matrix.package }} + generator: Unix Makefiles + # args: -D$(echo "${{ matrix.package }}" | tr '[:lower:]' '[:upper:]')_BUILD_TESTS=ON # this doesn't work :/ + args: -DATCLIENT_BUILD_TESTS=ON -DATCHOPS_BUILD_TESTS=ON + build-dir: packages/${{ matrix.package }}/build + run-build: true + build-args: --target install + run-test: false + # run-test: true + # test-args: -V --output-on-failure + - name: CTest + working-directory: packages/${{ matrix.package}}/build/tests run: | - ctest -V + ctest -V --output-on-failure + - - name: atclient - CMake Configure - working-directory: packages/atclient - run: | - cmake -S . -B build -DATCLIENTS_BUILD_TESTS=ON -DCMAKE_INSTALL_PREFIX=./install - - - name: atclient - Build with Unix Makefiles - working-directory: packages/atclient - run: | - cmake --build build --target install - - - name: atclient - Run CTest - working-directory: packages/atclient/build/tets - run: | - ctest -V