Skip to content

Commit

Permalink
Update jacoco-1.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
ravishanigarapu authored May 6, 2024
1 parent 90aff8a commit f468800
Showing 1 changed file with 25 additions and 20 deletions.
45 changes: 25 additions & 20 deletions .github/workflows/jacoco-1.yml
Original file line number Diff line number Diff line change
@@ -1,34 +1,39 @@
name: Jacoco Coverage
name: jacoco-1

on:
push:
branches:
- feature/Junit
branches: [ "feature/Junit"]
paths-ignore:
- 'target/**'
pull_request:
branches:
- feature/Junit
branches: [ "feature/Junit" ]
paths-ignore:
- 'target/**'

env:
ENV_VAR: test

jobs:
build:
Package-test:
runs-on: ubuntu-latest

steps:
- name: Checkout code
- name: Checkout code
uses: actions/checkout@v2

- name: Set up JDK
- name: Setup JDK 17
uses: actions/setup-java@v2
with:
java-version: '17'

- name: Build with Gradle
run: ./gradlew build

- name: Run tests with Jacoco
run: mvn clean install

- name: Upload Jacoco report
java-version: 17
distribution: 'adopt'

- name: Build with Maven
run: mvn clean install -DENV_VAR=${{ env.ENV_VAR }}

- name: Build WAR file
run: mvn -B package --file pom.xml

- name: Upload JaCoCo coverage report
uses: actions/upload-artifact@v2
with:
name: jacoco-report
path: build/reports/jacoco/test/html
path: target/site/jacoco/index.html

0 comments on commit f468800

Please sign in to comment.