O'Reilly logo

Learn CakePHP: With Unit Testing, Second Edition by Rādhārādhya Dāsa

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

© Sándor Gömöri 2016

Rādhārādhya Dāsa, Learn CakePHP, 10.1007/978-1-4842-1212-7_14

14. Goodies

Rādhārādhya Dāsa

(1)Somogyvamos, Hungary

A337704_2_En_14_Figa_HTML.jpg

There are other yummies

Code Coverage

Code coverage helps you to identify code parts that are not covered by tests. Theoretically, 100% coverage is attainable, but most of the time, you will achieve less than that percentage.

Generating code coverage is simple, like a piece of cake. We can generate coverage for all tests, test suites, or only for test files, with the same options described in the previous chapter.

$ cd ∼/public_html/cakeBlog              $ vendor/bin/phpunit --coverage-html webroot/coverage tests/TestCase/Model/Table/UsersTableTest.php ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required