Changeset View
Changeset View
Standalone View
Standalone View
src/docs/user/userguide/arcanist_coverage.diviner
@title Arcanist User Guide: Code Coverage | @title Arcanist User Guide: Code Coverage | ||||
@group userguide | @group userguide | ||||
Explains code coverage features in Arcanist and Phabricator. | Explains code coverage features in Arcanist and Phorge. | ||||
This is a configuration guide that helps you set up advanced features. If you're | This is a configuration guide that helps you set up advanced features. If you're | ||||
just getting started, you don't need to look at this yet. Instead, start with | just getting started, you don't need to look at this yet. Instead, start with | ||||
the @{article:Arcanist User Guide}. | the @{article:Arcanist User Guide}. | ||||
Before you can configure coverage features, you must set up unit test | Before you can configure coverage features, you must set up unit test | ||||
integration. For instructions, see @{article:Arcanist User Guide: Configuring | integration. For instructions, see @{article:Arcanist User Guide: Configuring | ||||
a New Project} and @{article:Arcanist User Guide: Customizing | a New Project} and @{article:Arcanist User Guide: Customizing | ||||
Show All 9 Lines | For example: | ||||
arc unit --detailed-coverage src/some/file.php | arc unit --detailed-coverage src/some/file.php | ||||
Depending on how your test engine is configured, this will run tests relevant | Depending on how your test engine is configured, this will run tests relevant | ||||
to `src/some/file.php` and give you a detailed coverage report. | to `src/some/file.php` and give you a detailed coverage report. | ||||
If the test engine enables coverage by default, it will be uploaded to | If the test engine enables coverage by default, it will be uploaded to | ||||
Differential and displayed in the right gutter when viewing diffs. | Differential and displayed in the right gutter when viewing diffs. | ||||
= Enabling Coverage for Arcanist and Phabricator = | = Enabling Coverage for Arcanist and Phorge = | ||||
If you're contributing, Arcanist and Phabricator support coverage if | If you're contributing, Arcanist and Phorge support coverage if | ||||
you install Xdebug: | you install Xdebug: | ||||
http://xdebug.org/ | http://xdebug.org/ | ||||
It should be sufficient to correctly install Xdebug; coverage information will | It should be sufficient to correctly install Xdebug; coverage information will | ||||
be automatically enabled. | be automatically enabled. | ||||
= Building Coverage Support = | = Building Coverage Support = | ||||
Show All 29 Lines |
Content licensed under Creative Commons Attribution-ShareAlike 4.0 (CC-BY-SA) unless otherwise noted; code licensed under Apache 2.0 or other open source licenses. · CC BY-SA 4.0 · Apache 2.0