lundi 3 octobre 2016

How to hide cakephp log in console result phpunit?

When running unit test by phpunit on console, it always displays the message I input in logfile: This the sample file I will test:

Sample.php

public funtion testThis() {
    CakeLog::write('error', "This is a test");
}

then when I run in console

$ ./Console/cake test app

I will get this result:

PHPUnit 3.7.38 by Sebastian Bergmann.

............This is a test..........50/50 (100%)

Aucun commentaire:

Enregistrer un commentaire