diff --git a/create_framework/unit_testing.rst b/create_framework/unit_testing.rst index 580b1d7e428..d5fe007f128 100644 --- a/create_framework/unit_testing.rst +++ b/create_framework/unit_testing.rst @@ -26,6 +26,11 @@ using `PHPUnit`_. Create a PHPUnit configuration file in ./tests + + + ./src + + This configuration defines sensible defaults for most PHPUnit settings; more @@ -180,6 +185,12 @@ Open ``example.com/cov/src/Simplex/Framework.php.html`` in a browser and check that all the lines for the Framework class are green (it means that they have been visited when the tests were executed). +Alternatively you can output the result directly to the console: + +.. code-block:: bash + + $ phpunit --coverage-text + Thanks to the simple object-oriented code that we have written so far, we have been able to write unit-tests to cover all possible use cases of our framework; test doubles ensured that we were actually testing our code and not