cmake.yml 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. name: CMake
  2. on:
  3. push:
  4. branches: [ master ]
  5. pull_request:
  6. branches: [ master ]
  7. env:
  8. # Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
  9. BUILD_TYPE: Release
  10. jobs:
  11. build:
  12. runs-on: ${{ matrix.os }}
  13. continue-on-error: ${{ matrix.allow_failure }}
  14. strategy:
  15. fail-fast: false
  16. matrix:
  17. os: [ ubuntu-18.04, ubuntu-20.04, ubuntu-latest, macos-latest ]
  18. allow_failure: false
  19. include:
  20. - os: macos-latest
  21. allow_failure: true
  22. steps:
  23. - uses: actions/checkout@v2
  24. with:
  25. submodule: true
  26. - name: Configure CMake
  27. run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}}
  28. - name: Build
  29. run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}
  30. - name: Test round 1
  31. working-directory: ${{github.workspace}}/build
  32. run: make test
  33. - name: Test round 2
  34. working-directory: ${{github.workspace}}/build/tests
  35. run: make test