-
Notifications
You must be signed in to change notification settings - Fork 0
62 lines (60 loc) · 1.96 KB
/
ci.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
52
53
54
55
56
57
58
59
60
61
62
name: ci
on:
push:
jobs:
build-test:
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v2
- name: set-up-jdk
uses: actions/setup-java@v1
with:
java-version: '15' # The JDK version to make available on the path.
java-package: jdk # (jre, jdk, or jdk+fx) - defaults to jdk
architecture: x64 # (x64 or x86) - defaults to x64
- name: cache-local-repository
uses: actions/cache@v2
with:
path: |
~/.m2/repository
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }}
restore-keys: |
${{ runner.os }}-gradle-
- name: grant-execute-permission-for-gradlew
run: chmod +x gradlew
- name: build-with-gradle
run: ./gradlew build -x test
# - name: upload-build-dir
# uses: actions/upload-artifact@v2
# with:
# name: build-dir
# path: |
# build/libs
# docker/
# retention-days: 7
- name: run-tests
run: ./gradlew test
# - name: upload-test-results-dir
# uses: actions/upload-artifact@v2
# with:
# name: test-results-dir
# path: build/test-results/
# retention-days: 7
# publish-test-results:
# runs-on: ubuntu-18.04
# needs: build-test
# steps:
# - name: download-test-results
# uses: actions/download-artifact@v2
# with:
# name: test-results-dir
# path: build/test-results/ # keep the same structure everywhere
# - name: publish-test-results
# uses: EnricoMi/publish-unit-test-result-action@v1.6
# if: always() # guarantees that this action always runs, even if earlier steps (e.g., the unit test step) in your workflow fail.
# with:
# report_individual_runs: true
# github_token: ${{ secrets.GITHUB_TOKEN }}
# files: build/test-results/**/*.xml