X-Git-Url: https://git.heureux-cyclage.org/?p=lhc%2Fweb%2Fwiklou.git;a=blobdiff_plain;f=tests%2Fphpunit%2Fincludes%2Fexception%2FErrorPageErrorTest.php;h=e72865f6be537f1d88640a8988e88fc940fec0cf;hp=9c4e4a0b4afa24e999f2ba52a7550cf08e582a07;hb=7ececd89751310a7d46310b10ca80d5a0aa77528;hpb=4d78d40d821227a9368e87306f447ffd3be5db88 diff --git a/tests/phpunit/includes/exception/ErrorPageErrorTest.php b/tests/phpunit/includes/exception/ErrorPageErrorTest.php index 9c4e4a0b4a..e72865f6be 100644 --- a/tests/phpunit/includes/exception/ErrorPageErrorTest.php +++ b/tests/phpunit/includes/exception/ErrorPageErrorTest.php @@ -2,7 +2,7 @@ /** * @covers ErrorPageError - * @author Adam Shorland + * @author Addshore */ class ErrorPageErrorTest extends MediaWikiTestCase { @@ -22,7 +22,7 @@ class ErrorPageErrorTest extends MediaWikiTestCase { public function testConstruction() { $mockMessage = $this->getMockMessage(); $title = 'Foo'; - $params = array( 'Baz' ); + $params = [ 'Baz' ]; $e = new ErrorPageError( $title, $mockMessage, $params ); $this->assertEquals( $title, $e->title ); $this->assertEquals( $mockMessage, $e->msg ); @@ -32,7 +32,7 @@ class ErrorPageErrorTest extends MediaWikiTestCase { public function testReport() { $mockMessage = $this->getMockMessage(); $title = 'Foo'; - $params = array( 'Baz' ); + $params = [ 'Baz' ]; $mock = $this->getMockBuilder( 'OutputPage' ) ->disableOriginalConstructor() @@ -43,6 +43,7 @@ class ErrorPageErrorTest extends MediaWikiTestCase { $mock->expects( $this->once() ) ->method( 'output' ); $this->setMwGlobals( 'wgOut', $mock ); + $this->setMwGlobals( 'wgCommandLineMode', false ); $e = new ErrorPageError( $title, $mockMessage, $params ); $e->report();