Skip to content

Commit 2060c25

Browse files
author
grq
committed
junit test with Maven
1 parent 1fa03d3 commit 2060c25

File tree

1 file changed

+43
-0
lines changed

1 file changed

+43
-0
lines changed

.github/workflows/test.yml

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: junit test with Maven
2+
3+
on:
4+
push:
5+
branches: [ test ]
6+
pull_request:
7+
branches: [ test ]
8+
9+
jobs:
10+
build:
11+
12+
runs-on: ubuntu-latest
13+
14+
steps:
15+
- name: Checkout gsp_sqlfiles
16+
uses: actions/checkout@v3
17+
with:
18+
repository: liaowuhen2/gsp_sqlfiles@dev
19+
path: gsp_sqlfiles
20+
fetch-depth: 0
21+
- name: Checkout gsp_demo
22+
- uses: actions/checkout@v3
23+
- name: Set up JDK 8
24+
uses: actions/setup-java@v3
25+
with:
26+
java-version: '8'
27+
distribution: 'temurin'
28+
- name: Cache local Maven repository
29+
uses: actions/cache@v3
30+
with:
31+
path: ~/.m2/repository
32+
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
33+
restore-keys: ${{ runner.os }}-m2
34+
- name: Build with Maven
35+
env:
36+
MAVEN_OPTS: -Xss2M
37+
JAVA_OPTS: -Xss2M
38+
run: mvn -B package --file pom.xml
39+
- name: Run tests with Maven
40+
env:
41+
MAVEN_OPTS: -Xss2M
42+
JAVA_OPTS: -Xss2M
43+
run: mvn -B test --file pom.xml

0 commit comments

Comments
 (0)