From 11e1f94f42752a0a7d602ad12b3f6aa1d3d0338d Mon Sep 17 00:00:00 2001 From: "Minjie.ZHOU" Date: Sun, 8 Sep 2024 22:16:58 +0800 Subject: [PATCH 1/2] Update master-ci.yml --- .github/workflows/master-ci.yml | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/.github/workflows/master-ci.yml b/.github/workflows/master-ci.yml index 5224208a..49fe4eac 100644 --- a/.github/workflows/master-ci.yml +++ b/.github/workflows/master-ci.yml @@ -38,4 +38,16 @@ jobs: - name: Build run: dotnet build --no-restore - name: Test - run: dotnet test --no-build --verbosity normal + run: dotnet test --no-build --verbosity normal --collect:"XPlat Code Coverage" --results-directory ./coverage + - name: Code Coverage Report + uses: irongut/CodeCoverageSummary@v1.3.0 + with: + filename: coverage/**/coverage.cobertura.xml + badge: true + fail_below_min: true + format: markdown + hide_branch_rate: false + hide_complexity: true + indicators: true + output: both + thresholds: '60 80' From dec524c23c7b7e227e2916d71feb8c0eab23d449 Mon Sep 17 00:00:00 2001 From: "Minjie.ZHOU" Date: Sun, 8 Sep 2024 23:06:08 +0800 Subject: [PATCH 2/2] Update master-ci.yml --- .github/workflows/master-ci.yml | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) diff --git a/.github/workflows/master-ci.yml b/.github/workflows/master-ci.yml index 49fe4eac..f5e144c8 100644 --- a/.github/workflows/master-ci.yml +++ b/.github/workflows/master-ci.yml @@ -39,15 +39,12 @@ jobs: run: dotnet build --no-restore - name: Test run: dotnet test --no-build --verbosity normal --collect:"XPlat Code Coverage" --results-directory ./coverage - - name: Code Coverage Report - uses: irongut/CodeCoverageSummary@v1.3.0 + - name: Upload coverage to Codecov + uses: codecov/codecov-action@v4 with: - filename: coverage/**/coverage.cobertura.xml - badge: true - fail_below_min: true - format: markdown - hide_branch_rate: false - hide_complexity: true - indicators: true - output: both - thresholds: '60 80' + directory: ./coverage + fail_ci_if_error: false + flags: unittests + name: agileconfig + token: ${{ secrets.CODECOV_TOKEN }} + verbose: true