Skip to content

Commit

Permalink
refactor(CI): codecov 설정 변경
Browse files Browse the repository at this point in the history
  • Loading branch information
limehee committed Dec 22, 2024
1 parent 1d50703 commit 27348e3
Show file tree
Hide file tree
Showing 4 changed files with 87 additions and 5 deletions.
17 changes: 16 additions & 1 deletion .github/workflows/test-and-quality-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,22 @@ jobs:
uses: codecov/codecov-action@v5
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: '**/build/reports/jacoco/test/jacocoTestReport.xml'
files: |
stempo-api/build/reports/jacoco/test/jacocoTestReport.xml
stempo-application/build/reports/jacoco/test/jacocoTestReport.xml
stempo-auth/build/reports/jacoco/test/jacocoTestReport.xml
stempo-common/build/reports/jacoco/test/jacocoTestReport.xml
stempo-domain/build/reports/jacoco/test/jacocoTestReport.xml
stempo-infrastructure/build/reports/jacoco/test/jacocoTestReport.xml
flags: |
stempo-api
stempo-application
stempo-auth
stempo-common
stempo-domain
stempo-infrastructure
fail_ci_if_error: false
verbose: true

- name: Post Coverage & Quality Results to PR
if: always()
Expand Down
2 changes: 2 additions & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ plugins {
id("org.sonarqube") version Versions.sonarQube
id("checkstyle")
id("jacoco")
kotlin("jvm")
}

repositories {
Expand All @@ -17,6 +18,7 @@ repositories {

dependencies {
implementation(project(":stempo-api"))
implementation(kotlin("stdlib-jdk8"))
}

tasks.named<Jar>("jar") {
Expand Down
67 changes: 63 additions & 4 deletions codecov.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,66 @@
coverage:
precision: 2
round: down
range: '70...100'
status:
project:
default:
target: auto
threshold: 1%
flags:
- stempo-api
- stempo-application
- stempo-auth
- stempo-common
- stempo-domain
- stempo-infrastructure
patch:
default:
target: auto
threshold: 1%

flags:
stempo-api:
paths:
- 'stempo-api/src/**'
stempo-application:
paths:
- 'stempo-application/src/**'
stempo-auth:
paths:
- 'stempo-auth/src/**'
stempo-common:
paths:
- 'stempo-common/src/**'
stempo-domain:
paths:
- 'stempo-domain/src/**'
stempo-infrastructure:
paths:
- 'stempo-infrastructure/src/**'

comment:
layout: "diff, flags, files"
layout: 'diff, flags, files'
behavior: default
require_changes: false
require_base: false # 테스트를 위한 임시 설정
require_head: false # 테스트를 위한 임시 설정
require_changes: true
require_base: false
require_head: false
hide_project_coverage: false

codecov:
notify:
require_ci_to_pass: true
require_ci_to_pass: true

exclude:
- '**/Test*.java'
- '**/*Test*.java'
- '**/*Dto*.java'
- '**/*Entity*.java'
- '**/*Service*.java'
- '**/*Repository*.java'
- '**/*Exception*.java'
- '**/ApiApplication.java'

max_report_age: '30d'
mode: all
6 changes: 6 additions & 0 deletions settings.gradle
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
pluginManagement {
plugins {
id 'org.jetbrains.kotlin.jvm' version '2.1.0'
}
}

rootProject.name = 'api'
include(":stempo-common",
":stempo-auth",
Expand Down

0 comments on commit 27348e3

Please sign in to comment.