-
Notifications
You must be signed in to change notification settings - Fork 32
Readme update required software #26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
jeffrafter
merged 2 commits into
codeclimate:master
from
enygma:readme-update-required-software
Feb 20, 2015
Merged
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,17 +2,35 @@ | |
|
||
# codeclimate-test-reporter | ||
|
||
Collects test coverage data from your PHP test suite and sends it to | ||
Collects test coverage data from your PHP test suite and sends it to | ||
Code Climate's hosted, automated code review service. | ||
|
||
Code Climate - https://codeclimate.com | ||
|
||
**Important:** If you encounter an error involving SSL certificates, see the **Known Issue: SSL Certificate Error** section below. | ||
|
||
## Requirements | ||
|
||
There are several requirements you'll need in order to use the PHP test reporter on your system: | ||
|
||
- [PHPUnit](http://phpunit.de) | ||
- [Xdebug](http://xdebug.org) | ||
- [Composer](http://getcomposer.org) | ||
|
||
The test reporter uses the [PHPUnit](http://phpunit.de) testing tool to generate [code coverage](http://en.wikipedia.org/wiki/Code_coverage) information. These results show how much of your application's code is being executed by your unit tests. PHPUnit can't generate this information on it's own though - it needs another tool, [Xdebug](http://xdebug.org). This is *not* included as a part of the PHPUnit (or PHP) install by default so you'll need to install it yourself. | ||
|
||
Xdebug is installed as an extension to PHP, not a library. You can find more information about installing the tool via PECL [on the project website](http://xdebug.org/docs/install). | ||
|
||
If you execute your PHPUnit tests with the `--coverage-clover` option and receive the message "The Xdebug extension is not loaded. No code coverage will be generated." you will need to visit the Xdebug website and install the extension. If you do not, you'll most likely get an error something like this: | ||
|
||
``` | ||
PHP Warning: simplexml_load_file(): I/O warning : failed to load external entity "[...]/build/logs/clover.xml" in [...]/vendor/satooshi/php-coveralls/src/Contrib/Bundle/CoverallsV1Bundle/Api/Jobs.php on line 52 | ||
``` | ||
|
||
## Installation | ||
|
||
This package requires a user, but not necessarily a paid account, on | ||
Code Climate, so if you don't have one the first step is to signup at: | ||
This package requires a user, but not necessarily a paid account, on | ||
Code Climate, so if you don't have one the first step is to signup at: | ||
https://codeclimate.com. | ||
|
||
To install php-test-reporter with Composer run the following command. | ||
|
@@ -50,18 +68,18 @@ Or invoke `phpunit` as follows: | |
$ phpunit --coverage-clover build/logs/clover.xml | ||
``` | ||
|
||
- Specifying your repo token as an environment variable, invoke the | ||
- Specifying your repo token as an environment variable, invoke the | ||
test-reporter: | ||
|
||
``` | ||
$ CODECLIMATE_REPO_TOKEN="..." vendor/bin/test-reporter | ||
``` | ||
|
||
The `CODECLIMATE_REPO_TOKEN` value is provided after you add your repo | ||
to your Code Climate account by clicking on "Setup Test Coverage" on the | ||
The `CODECLIMATE_REPO_TOKEN` value is provided after you add your repo | ||
to your Code Climate account by clicking on "Setup Test Coverage" on the | ||
right hand side of your feed. | ||
|
||
Please contact [email protected] if you need any assistance setting | ||
Please contact [email protected] if you need any assistance setting | ||
this up. | ||
|
||
## Known Issue: SSL Certificate Error | ||
|
@@ -83,7 +101,7 @@ More details can be found in [this issue][issue]. | |
|
||
## Contributions | ||
|
||
Patches, bug fixes, feature requests, and pull requests are welcome on | ||
Patches, bug fixes, feature requests, and pull requests are welcome on | ||
the GitHub page for this project: | ||
|
||
https://github.com/codeclimate/php-test-reporter | ||
|
@@ -94,6 +112,6 @@ This package is maintained by Bryan Helmkamp ([email protected]). | |
|
||
See LICENSE.txt | ||
|
||
Portions of the implementation were inspired by the php-coveralls | ||
Portions of the implementation were inspired by the php-coveralls | ||
project. | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -19,7 +19,8 @@ | |
"symfony/console": ">=2.0" | ||
}, | ||
"require-dev": { | ||
"phpunit/phpunit": "3.7.*@stable" | ||
"phpunit/phpunit": "3.7.*@stable", | ||
"ext-xdebug": "*" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. You should actually specify a version to use in here. |
||
}, | ||
"autoload": { | ||
"psr-0": { | ||
|
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This
@stable
annotation means nothing at all and should be removed.