Skip to content

Comments

Migrate code coverage from Codecov to Datadog Code Coverage#3665

Draft
ManuelPalenzuelaDD wants to merge 1 commit intoDataDog:masterfrom
ManuelPalenzuelaDD:migrate-codecov-to-datadog-coverage
Draft

Migrate code coverage from Codecov to Datadog Code Coverage#3665
ManuelPalenzuelaDD wants to merge 1 commit intoDataDog:masterfrom
ManuelPalenzuelaDD:migrate-codecov-to-datadog-coverage

Conversation

@ManuelPalenzuelaDD
Copy link
Contributor

Summary

  • Replace Codecov uploader with datadog-ci coverage upload in the appsec code coverage CI job
  • Replace codecov.yml with code-coverage.datadog.yml (PR gates with 90% patch coverage threshold + ignored paths)
  • Remove Codecov badge from README

Details

CI pipeline (.gitlab/generate-appsec.php)

  • Removed: Codecov token fetch from Vault, GPG verification, codecov binary installation
  • Added: DATADOG_API_KEY fetch from Vault (same path used by JUnit uploads), datadog-ci standalone binary installation
  • Upload commands now use datadog-ci coverage upload --flags <name> instead of codecov -n <name> -f <file>

Configuration (code-coverage.datadog.yml)

  • Patch coverage gate at 90% (was patch.target: 90% in Codecov)
  • Ignored paths: appsec/build/, appsec/tests/, appsec/third_party/
  • Note: Codecov's project.target: auto (coverage must not decrease) has no direct Datadog equivalent — total_coverage_percentage only supports fixed thresholds. Omitted for now; can be added with a fixed floor if desired.

Test plan

  • Verify the appsec code coverage CI job runs successfully and uploads to Datadog
  • Verify coverage data appears in Datadog Code Coverage UI
  • Verify PR gate check triggers on subsequent PRs

🤖 Generated with Claude Code

Replace Codecov with Datadog Code Coverage for the appsec extension
and helper coverage uploads. This uses the datadog-ci CLI (same tool
already used for JUnit uploads) and a code-coverage.datadog.yml config
file for PR gates and ignored paths.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant