From 616a5b2e7eced9f806359ab4ad0c3e4e9c76ab9a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Kozlovsk=C3=BD?= Date: Wed, 4 Dec 2024 17:26:29 +0100 Subject: [PATCH] codecov base report update (#213) --- .github/workflows/ci.yaml | 10 +++++++++- .github/workflows/codecov.yaml | 26 ++++++++++++++++++++++++++ 2 files changed, 35 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/codecov.yaml diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 397f3083..c53030ba 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -2,7 +2,7 @@ name: CI on: pull_request: - branches: [ dev, main ] + branches: [ main ] paths: - 'luxonis_ml/**' - 'tests/**' @@ -100,3 +100,11 @@ jobs: with: token: ${{ secrets.CODECOV_TOKEN }} fail_ci_if_error: false + + - name: Upload coverage as artifact + if: matrix.os == 'ubuntu-latest' && matrix.python-version == '3.8' + uses: actions/upload-artifact@v4 + with: + name: coverage + path: coverage.xml + overwrite: true diff --git a/.github/workflows/codecov.yaml b/.github/workflows/codecov.yaml new file mode 100644 index 00000000..ce85d1a6 --- /dev/null +++ b/.github/workflows/codecov.yaml @@ -0,0 +1,26 @@ +on: + push: + branches: [ main ] + paths: + - 'luxonis_ml/**' + - 'tests/**' +jobs: + update-base-report: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + with: + ref: ${{ github.head_ref }} + + - name: Download artifacts + uses: actions/download-artifact@v4 + with: + name: coverage + path: coverage.xml + + - name: Upload coverage results to Codecov + uses: codecov/codecov-action@v4 + with: + token: ${{ secrets.CODECOV_TOKEN }} + fail_ci_if_error: false