Catalog / GitHub

Manage the code coverage ruleset condition with the REST API

todaychangedOriginal notes

You can now use the generally available REST API to manage the Restrict code coverage repository ruleset option, in addition to the existing UI support.

This ruleset lets you enforce a minimum code coverage percentage based on line coverage or set a maximum tolerable coverage drop for a pull request. Previously, configuring this rule required using the web interface. Now you can create, update, and read this ruleset option programmatically, making it easier to manage code coverage requirements consistently across many repositories or as part of your existing infrastructure-as-code workflows.

To use this rule, your repository must have GitHub Code Quality enabled and code coverage uploads configured. It’s available on GitHub Enterprise Cloud and GitHub Team, including GitHub Enterprise Cloud with data residency. It isn’t available on GitHub Enterprise Server.

Learn more about available rules for rulesets and the REST API endpoints for rules.

The post Manage the code coverage ruleset condition with the REST API appeared first on The GitHub Blog.