-
Notifications
You must be signed in to change notification settings - Fork 13
71 lines (61 loc) · 3.33 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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven
name: Build
on:
push:
branches: [main, '*-development']
pull_request:
branches: [main, '*-development']
jobs:
build:
runs-on: ubuntu-latest
services:
redis:
image: redis
ports:
- 6379/tcp
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Checkout submodules
run: git submodule update --init --recursive
- name: Set up JDK 11
uses: actions/setup-java@v1
with:
java-version: 11
- name: Cache Maven packages
uses: actions/cache@v2
with:
path: ~/.m2
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-m2
- name: Build with Maven
run: mvn -B -U -pl '!integration' clean install -DskipTests
- name: Package integration module with Maven
run: mvn -B -U -pl integration clean package -DskipTests
- name: Set up nodejs
uses: actions/setup-node@v2
with:
node-version: '16'
- name: Cache npm modules
uses: actions/cache@v2
with:
path: ~/.npm
key: v1-npm-deps-${{ hashFiles('**/package-lock.json') }}
restore-keys: v1-npm-deps-
- run: npm --prefix static/js/vue-cdr-access install
- run: npm --prefix static/js/admin/vue-permissions-editor install
- run: npm install -g [email protected]
- run: npm --prefix static/js/vue-cdr-access run test
- run: npm --prefix static/js/admin/vue-permissions-editor run test
- name: Report to CodeClimate
uses: paambaati/[email protected]
env:
CC_TEST_REPORTER_ID: ${{secrets.CC_TEST_REPORTER_ID}}
JACOCO_SOURCE_PATH: "${{github.workspace}}/auth-api/src/main/java ${{github.workspace}}/auth-fcrepo/src/main/java ${{github.workspace}}/common-utils/src/main/java ${{github.workspace}}/deposit-app/src/main/java ${{github.workspace}}/deposit-utils/src/main/java ${{github.workspace}}/fcrepo-utils/src/main/java ${{github.workspace}}/indexing-solr/src/main/java ${{github.workspace}}/integration/src/main/java ${{github.workspace}}/model-api/src/main/java ${{github.workspace}}/model-fcrepo/src/main/java ${{github.workspace}}/operations/src/main/java ${{github.workspace}}/operations-jms/src/main/java ${{github.workspace}}/persistence/src/main/java ${{github.workspace}}/persistence-api/src/main/java ${{github.workspace}}/search-api/src/main/java ${{github.workspace}}/search-solr/src/main/java ${{github.workspace}}/services-camel-app/src/main/java ${{github.workspace}}/web-access-app/src/main/java ${{github.workspace}}/web-access-war/src/main/java ${{github.workspace}}/web-admin-app/src/main/java ${{github.workspace}}/web-common/src/main/java ${{github.workspace}}/web-services-app/src/main/java ${{github.workspace}}/web-sword/src/main/java ${{github.workspace}}/clamav-java/src/main/java"
with:
coverageCommand: mvn -pl !clamav-java verify
coverageLocations: |
${{github.workspace}}/**/target/site/jacoco/jacoco.xml:jacoco
${{github.workspace}}/**/target/site/jacoco-it/jacoco.xml:jacoco
${{github.workspace}}/static/js/vue-cdr-access/coverage/lcov.info:lcov
${{github.workspace}}/static/js/admin/vue-permissions-editor/coverage/lcov.info:lcov