| 1 | name: Build and test |
| 2 | |
| 3 | on: |
| 4 | push: |
| 5 | branches: |
| 6 | - master |
| 7 | pull_request: |
| 8 | branches: |
| 9 | - master |
| 10 | |
| 11 | jobs: |
| 12 | build: |
| 13 | strategy: |
| 14 | fail-fast: false |
| 15 | matrix: |
| 16 | os: |
| 17 | - ubuntu-latest |
| 18 | - macos-latest |
| 19 | runs-on: ${{ matrix.os }} |
| 20 | steps: |
| 21 | - uses: actions/checkout@v2 |
| 22 | - name: Install dependencies (Ubuntu) |
| 23 | if: matrix.os == 'ubuntu-latest' |
| 24 | run: | |
| 25 | sudo apt install -y \ |
| 26 | python3-dev \ |
| 27 | qt5-qmake qtbase5-dev qtdeclarative5-dev libqt5svg5-dev |
| 28 | - name: Install dependencies (macOS) |
| 29 | if: matrix.os == 'macos-latest' |
| 30 | run: | |
| 31 | brew install qt@5 [email protected] |
| 32 | echo PATH=/opt/homebrew/opt/qt@5/bin:/usr/local/opt/qt@5/bin:$PATH >> ${GITHUB_ENV} |
| 33 | - run: qmake |
| 34 | - run: make |
| 35 | - run: env QT_QPA_PLATFORM=offscreen tests/tests |