-
Notifications
You must be signed in to change notification settings - Fork 4
45 lines (39 loc) · 1.38 KB
/
test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
name: test
# Run on pull requests and on the master branch itself.
on:
push:
branches:
- master
- refactor
tags:
- "*"
pull_request:
workflow_dispatch:
jobs:
build_and_test:
runs-on: ubuntu-20.04
steps:
# Checkout the code.
- uses: actions/checkout@v2
- name: build
run: docker compose build --build-arg uid=`id -u` --build-arg gid=`id -g`
- name: test
run: |
docker compose run -e QT_QPA_PLATFORM=offscreen qgis-desktop make check
docker compose run -e QT_QPA_PLATFORM=offscreen qgis-desktop make test
docker compose run -e QT_QPA_PLATFORM=offscreen qgis-desktop make flake8
docker compose run qgis-desktop make docstrings
docker compose run qgis-desktop coveralls || true
docker compose run qgis-desktop make zip
env:
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
- name: Publish package
if: startsWith(github.event.ref, 'refs/tags')
run: bash upload-artifact.sh
env:
THREEDITOOLBOX_ARTIFACTS_KEY: ${{ secrets.THREEDITOOLBOX_ARTIFACTS_KEY }}
- name: Publish dev-only package
if: ${{ !startsWith(github.event.ref, 'refs/tags') }}
run: bash upload-dev-artifact.sh
env:
THREEDITOOLBOX_DEV_ARTIFACTS_KEY: ${{ secrets.THREEDITOOLBOX_DEV_ARTIFACTS_KEY }}