forked from rusefi/fw-custom-example
-
Notifications
You must be signed in to change notification settings - Fork 4
57 lines (48 loc) · 1.57 KB
/
Copy pathunit-tests.yaml
File metadata and controls
57 lines (48 loc) · 1.57 KB
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
52
53
54
55
56
57
name: Build Unit Tests
on:
schedule:
- cron: '0 1 * * *'
push:
branches: [master]
# pull_request:
workflow_dispatch:
jobs:
build-unit-tests:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
board:
- mazduino-lite
- mazduino-compact
- mazduino-mini6ch
- mazduino-mega100
- mazduino-mega100-512
steps:
- uses: actions/checkout@v4
with:
submodules: false
token: ${{ secrets.MY_REPO_PAT }}
- name: Checkout submodules
run: |
git config --global url."https://x-access-token:${{ secrets.MY_REPO_PAT }}@github.com/".insteadOf "git@github.com:"
git submodule update --init --force
- name: Checkout rusefi submodules
run: git -C ext/rusefi submodule update --init --force --depth=1
- uses: actions/setup-java@v4
with:
distribution: 'zulu'
java-version: '11'
- name: Print Compiler version
run: gcc -v
- name: Set Env Variables
run: |
echo "ABSOLUTE_BOARD_DIR=${{ github.workspace }}/boards/${{ matrix.board }}" >> $GITHUB_ENV
echo "META_OUTPUT_ROOT_FOLDER=$(realpath --relative-to=ext/rusefi/firmware generated)/" >> $GITHUB_ENV
- name: Compile and execute Unit Tests
run: |
cd ext/rusefi/unit_tests/
MI="../../../boards/${{ matrix.board }}/meta-info.env"
source ../firmware/config/boards/common_script_read_meta_env.inc "$MI"
make -j$(nproc)
timeout 20m build/rusefi_test