update phpunit & hide output during tests

This commit is contained in:
troosan 2017-09-13 23:15:46 +02:00
parent 34ac7170a2
commit 9d57693acd
5 changed files with 5 additions and 1 deletions

View File

@ -39,7 +39,7 @@
"phpoffice/common": "^0.2"
},
"require-dev": {
"phpunit/phpunit": "3.7.*",
"phpunit/phpunit": "4.8.*",
"phpdocumentor/phpdocumentor":"2.*",
"twig/twig":"1.27",
"squizlabs/php_codesniffer": "1.*",

View File

@ -152,6 +152,7 @@ class PhpWordTest extends \PHPUnit_Framework_TestCase
*/
public function testSave()
{
$this->setOutputCallback(function() {});
$phpWord = new PhpWord();
$section = $phpWord->addSection();
$section->addText('Hello world!');

View File

@ -102,6 +102,7 @@ class ODTextTest extends \PHPUnit_Framework_TestCase
*/
public function testSavePhpOutput()
{
$this->setOutputCallback(function() {});
$phpWord = new PhpWord();
$section = $phpWord->addSection();
$section->addText('Test');

View File

@ -103,6 +103,7 @@ class RTFTest extends \PHPUnit_Framework_TestCase
*/
public function testSavePhpOutput()
{
$this->setOutputCallback(function() {});
$phpWord = new PhpWord();
$section = $phpWord->addSection();
$section->addText(htmlspecialchars('Test', ENT_COMPAT, 'UTF-8'));

View File

@ -166,6 +166,7 @@ class Word2007Test extends \PHPUnit_Framework_TestCase
*/
public function testSetGetUseDiskCaching()
{
$this->setOutputCallback(function() {});
$phpWord = new PhpWord();
$phpWord->addSection();
$object = new Word2007($phpWord);