Interpreting PHP module output

My PHP module prints this to the console. What exactly does 63/129 ( 48%) and the thing in general mean? Does he perform all the tests or not?

 PHPUnit 3.7.22 by Sebastian Bergmann. Configuration read from phpunit.xml ............................................................... 63 / 129 ( 48%) ............................................................... 126 / 129 ( 97%) ... Time: 0 seconds, Memory: 6.75Mb OK (129 tests, 245 assertions) 

phpunit.xml looks like this:

 <?xml version="1.0" encoding="utf-8" ?> <phpunit bootstrap="vendor/autoload.php"> <testsuites> <testsuite name="SDK Testsuite"> <directory suffix="Test.php">src/MyNamespace/Test/Unit</directory> </testsuite> </testsuites> </phpunit> 
+7
phpunit
source share
2 answers

Each point represents one unit test. It prints one dot after running each test. The first line has 63 points, which means 63 of 129 tests (about 48%). The second line has 63 more points, which gives a total of 126 tests. The last three tests are on the third line.

This function is intended for those cases when the tests take a lot of time, and you can monitor the progress on the screen. It is also useful if one of the tests puts the system at a standstill. A progress bar allows you to determine which one is the problem.

+8
source share

Each point represents a successfully completed test. Other output characters include “I,” “S,” “F,” and “E.”

An 'I' is created when the test includes a string

 $this->markTestIncomplete('Your reason for being incomplete string'); 

An 'S' is created when the test includes a string

 $this->markTestSkipped('Your reason for skipping string'); 

An "E" is created when phpunit detects an error during the execution of the test, and an "F" is created when the statement is executed in the running test.

+4
source share

All Articles