diff --git a/.github/workflows/continuous-integration.yml b/.github/workflows/continuous-integration.yml index 248d455c..56740929 100644 --- a/.github/workflows/continuous-integration.yml +++ b/.github/workflows/continuous-integration.yml @@ -35,3 +35,9 @@ jobs: glpi-version: "${{ matrix.glpi-version }}" php-version: "${{ matrix.php-version }}" db-image: "${{ matrix.db-image }}" + + coverage-report: + needs: "ci" + uses: "froozeify/GLPI_plugin-ci-workflows/.github/workflows/coverage-report.yml@code-coverage" + with: + plugin-key: "carbon" diff --git a/.github/workflows/coverage-refresh.yml b/.github/workflows/coverage-refresh.yml new file mode 100644 index 00000000..359fb4f8 --- /dev/null +++ b/.github/workflows/coverage-refresh.yml @@ -0,0 +1,16 @@ +name: "Coverage refresh" + +on: + schedule: + - cron: "0 0 * * *" + workflow_dispatch: + +concurrency: + group: "${{ github.workflow }}-${{ github.ref }}" + cancel-in-progress: true + +jobs: + coverage-refresh: + uses: "froozeify/GLPI_plugin-ci-workflows/.github/workflows/coverage-refresh.yml@code-coverage" + with: + plugin-key: "carbon" \ No newline at end of file diff --git a/.glpi-coverage.json b/.glpi-coverage.json new file mode 100644 index 00000000..2a063f32 --- /dev/null +++ b/.glpi-coverage.json @@ -0,0 +1,10 @@ +{ + "enabled": true, + "only_list_changed_files": true, + "badge": true, + "overall_coverage_fail_threshold": 0, + "file_coverage_error_min": 50, + "file_coverage_warning_max": 75, + "fail_on_negative_difference": false, + "retention_days": 90 +} \ No newline at end of file