hotfix: 코드 커버리지 제한 50%로 상향조정 #44
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: 'CI' | |
on: | |
push: | |
branches: | |
- main | |
- develop | |
pull_request: | |
branches: | |
- main | |
- develop | |
env: | |
DOCKER_ID: ${{ secrets.DOCKER_ID }} | |
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }} | |
DOCKER_IMAGE_NAME: ${{ secrets.DOCKER_IMAGE_NAME }} | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: 리포지토리를 가져옵니다 | |
uses: actions/checkout@v3 | |
with: | |
token: ${{ secrets.SUBMODULE_TOKEN }} | |
submodules: recursive | |
- name: JDK 11을 설치합니다 | |
uses: actions/setup-java@v3 | |
with: | |
java-version: '11' | |
distribution: 'temurin' | |
- name: Gradle 명령 실행을 위한 권한을 부여합니다 | |
run: chmod +x gradlew | |
- name: Gradle build를 수행합니다 | |
run: ./gradlew build -P DOCKER_ID=${{ secrets.DOCKER_ID }} -P DOCKER_PASSWORD=${{ secrets.DOCKER_PASSWORD }} -P DOCKER_IMAGE_NAME=${{ secrets.DOCKER_IMAGE_NAME }} | |
- name: 테스트 결과를 PR에 코멘트로 등록합니다 | |
uses: EnricoMi/publish-unit-test-result-action@v1 | |
if: always() | |
with: | |
files: '**/build/test-results/test/TEST-*.xml' | |
- name: 테스트 커버리지를 PR에 코멘트로 등록합니다 | |
id: jacoco | |
uses: madrapps/[email protected] | |
with: | |
title: 📝 테스트 커버리지 리포트입니다 | |
paths: ${{ github.workspace }}/build/reports/jacoco/test/jacocoTestReport.xml | |
# paths: /build/reports/jacoco/test/jacocoTestReport.xml | |
token: ${{ secrets.GITHUB_TOKEN }} | |
min-coverage-overall: 50 | |
min-coverage-changed-files: 50 |