forked from musescore/MuseScore
-
Notifications
You must be signed in to change notification settings - Fork 0
51 lines (48 loc) · 1.57 KB
/
ci_utests.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
46
47
48
49
50
51
name: CI_utests
on:
pull_request:
branches:
- master
workflow_dispatch:
jobs:
run_tests:
runs-on: ubuntu-20.04
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- name: Clone repository
uses: actions/checkout@v4
- name: "Configure workflow"
run: |
sudo bash ./build/ci/tools/make_build_number.sh
BUILD_NUMBER=$(cat ./build.artifacts/env/build_number.env)
echo "BUILD_NUMBER=$BUILD_NUMBER" >> $GITHUB_ENV
echo "BUILD_NUMBER: $BUILD_NUMBER"
- name: Ccache cache files
uses: actions/cache@v3
with:
path: ~/.ccache
key: ${{github.workflow}}-ccache-$(date -u +"%F-%T")
restore-keys: ${{github.workflow}}-ccache- # restore ccache from either previous build on this branch or on master
- name: Setup ccache
run: |
sudo bash ./build/ci/tools/setup_ccache.sh
- name: Setup environment
run: |
sudo bash ./build/ci/linux/setup.sh
- name: Build
run: |
mkdir -p build.artifacts/env
sudo bash ./build/ci/linux/build_utest.sh -n ${{ env.BUILD_NUMBER }}
- name: Run tests
run: |
# At moment build and run tests consume 13.4 Gb of the disk.
# After left too little free space.
# So, we remove unnecessary tools, for more free space
sudo docker system prune -a -f
sudo rm -rf /usr/local/lib/android
sudo bash ./build/ci/linux/runutests.sh
env:
ASAN_OPTIONS: "detect_leaks=0"