-
-
Notifications
You must be signed in to change notification settings - Fork 4
50 lines (41 loc) · 1.12 KB
/
build.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
name: Build
on:
# Trigger on push to develop or main branches
push:
branches:
- develop
- main
# Trigger on pull request (any branch that creates a PR)
pull_request:
branches:
- develop
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Setup Java
uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: 17
- name: Cache local Maven repository
uses: actions/cache@v3
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
- name: Build
run: mvn --batch-mode --update-snapshots install
- name: Integration tests
run: mvn --batch-mode clean verify -pl it.tests -Pit
# Save logs only if the job fails
- name: Upload logs on failure
if: failure()
uses: actions/upload-artifact@v3
with:
name: failure-logs
path: it.tests/target/launchers/model/logs/*