I'm getting an error when I try to run tests using the --coverage flag.
php codecept.phar run acceptance testCest.php --coverage
[ErrorException] file_get_contents(http://project.local/c3/report/clear): failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found
coverage: remote: false enabled: true include: - application/*
<?php require __DIR__.'/../c3.php'; ?>
PHP: 5.5.12 Xdebug: 2.5.0 Codeception: 2.0.7
Thanks for any help!
J
In computer science, code coverage is a measure used to describe the degree to which the source code of a program is tested by a particular test suite.
Codeception is a framework used for creating tests, including unit tests, functional tests, and acceptance tests.
go to phpunit.xml
and make sure you have something like this in the file:
< logging >
< log type="coverage-html" target="./CodeCoverage/"/>
< /logging >
run this command:
$ phpunit --coverage-html ./report
now check go to the directory and open the html file.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With