Skip to content

Commit c88eae7

Browse files
v1.1.1-SNAPSHOT
1 parent 906194c commit c88eae7

File tree

3 files changed

+35
-7
lines changed

3 files changed

+35
-7
lines changed

.github/workflows/coverage.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: Measure coverage
2+
3+
on:
4+
pull_request:
5+
6+
jobs:
7+
build:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- uses: actions/checkout@v2
11+
- name: Set up JDK 1.8
12+
uses: actions/setup-java@v1
13+
with:
14+
java-version: 1.8
15+
- name: Run Coverage
16+
run: |
17+
chmod +x gradlew
18+
./gradlew testCoverage
19+
20+
- name: Add coverage to PR
21+
id: jacoco
22+
uses: madrapps/jacoco-report@v1.3
23+
with:
24+
paths: ${{ github.workspace }}/build/reports/jacoco/testCoverage/testCoverage.xml
25+
token: ${{ secrets.GITHUB_TOKEN }}
26+
min-coverage-overall: 40
27+
min-coverage-changed-files: 60
28+
- name: Build with Maven
29+
run: mvn -B package -Pcoverage

.github/workflows/publish.yml

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,4 @@ jobs:
2626
- name: Set up Java for publishing to GitHub Packages
2727
run: mvn --batch-mode deploy
2828
env:
29-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
30-
- name: Publish Coverage Report
31-
uses: actions/upload-artifact@v2
32-
with:
33-
name: Coverage Report
34-
path: target/site/jacoco/index.html
29+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

pom.xml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,9 +65,13 @@
6565
<id>ossrh</id>
6666
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
6767
</snapshotRepository>
68-
<repository>
68+
<!-- <repository>
6969
<id>ossrh</id>
7070
<url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/</url>
71+
</repository> -->
72+
<repository>
73+
<id>github</id>
74+
<url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/</url>
7175
</repository>
7276
</distributionManagement>
7377

0 commit comments

Comments
 (0)