Skip to content

hello-world.yml

hello-world.yml #38

Workflow file for this run

name: hello-world
on: push
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Set up Java 1.8
uses: actions/setup-java@v3
with:
java-version: '8.0'
distribution: 'temurin'
- name: Run a build
run: ./gradlew compileJava --stacktrace
- name: Run tests
run: ./gradlew test
- name: Build test coverage report
run: ./gradlew jacocoTestReport
- name: Send test coverage report Codacy
uses: codacy/codacy-coverage-reporter-action@v1
with:
project-token: ${{ secrets.CODACY_PROJECT_TOKEN }}
coverage-reports: build/reports/jacoco/test/jacocoTestReport.xml