diff --git a/.github/workflows/codecov.yml b/.github/workflows/codecov.yml new file mode 100644 index 000000000..da79efcbc --- /dev/null +++ b/.github/workflows/codecov.yml @@ -0,0 +1,14 @@ +name: Develop branch build +on: + workflow_call: + +jobs: + codecov-job: + runs-on: ubuntu-latest + steps: + - name: Upload coverage unittests reports to Codecov + uses: codecov/codecov-action@v4 + with: + fail_ci_if_error: true + token: ${{ secrets.CODECOV_TOKEN }} + verbose: true \ No newline at end of file diff --git a/.github/workflows/pull-request.yml b/.github/workflows/pull-request.yml index 6f539926b..17f233560 100644 --- a/.github/workflows/pull-request.yml +++ b/.github/workflows/pull-request.yml @@ -27,18 +27,5 @@ jobs: - name: Step 4 - Build & Test run: mvn clean verify -ntp -PIT - - name: Step 5 - Upload coverage unittests reports to Codecov - uses: codecov/codecov-action@v4 - with: - token: ${{ secrets.CODECOV_TOKEN }} - exclude: '*datasafe-business*' - flags: unittests - verbose: true - - - name: Step 6 - Upload coverage e2e tests reports to Codecov - uses: codecov/codecov-action@v4 - with: - token: ${{ secrets.CODECOV_TOKEN }} - exclude: '!*datasafe-business*' - flags: e2e_tests - verbose: true \ No newline at end of file + call-codecov-workflow: + uses: ./.github/workflows/codecov.yml \ No newline at end of file diff --git a/.github/workflows/push-develop.yml b/.github/workflows/push-develop.yml index 381b4427d..38c224df9 100644 --- a/.github/workflows/push-develop.yml +++ b/.github/workflows/push-develop.yml @@ -36,18 +36,5 @@ jobs: GPG_SECRET_KEY: ${{ secrets.GPG_SECRET_KEY }} GPG_OWNERTRUST: ${{ secrets.GPG_OWNERTRUST }} - - name: Step 6 - Upload coverage unittests reports to Codecov - uses: codecov/codecov-action@v4 - with: - token: ${{ secrets.CODECOV_TOKEN }} - exclude: '*datasafe-business*' - flags: unittests - verbose: true - - - name: Step 7 - Upload coverage e2e tests reports to Codecov - uses: codecov/codecov-action@v4 - with: - token: ${{ secrets.CODECOV_TOKEN }} - exclude: '!*datasafe-business*' - flags: e2e_tests - verbose: true \ No newline at end of file + call-codecov-workflow: + uses: ./.github/workflows/codecov.yml \ No newline at end of file