Set visibility of monolog tests setUp method to protected
authoraude <aude.wiki@gmail.com>
Tue, 22 Sep 2015 14:57:55 +0000 (16:57 +0200)
committeraude <aude.wiki@gmail.com>
Tue, 22 Sep 2015 14:57:55 +0000 (16:57 +0200)
In phpunit and MediaWikiTestCase, the setUp method is protected,
and it's nice if the subclasses are consistent.

Change-Id: I4b8ac612951168913bb2dc9cf16d3dc18762a211

tests/phpunit/includes/debug/logger/monolog/AvroFormatterTest.php
tests/phpunit/includes/debug/logger/monolog/KafkaHandlerTest.php
tests/phpunit/includes/debug/logger/monolog/LineFormatterTest.php

index 5cbb247..44242ed 100644 (file)
@@ -25,7 +25,7 @@ use PHPUnit_Framework_Error_Notice;
 
 class AvroFormatterTest extends MediaWikiTestCase {
 
-       public function setUp() {
+       protected function setUp() {
                if ( !class_exists( 'AvroStringIO' ) ) {
                        $this->markTestSkipped( 'Avro is required for the AvroFormatterTest' );
                }
index b6f33d8..090f439 100644 (file)
@@ -28,7 +28,7 @@ require_once __DIR__ . '/../../../ConsecutiveParametersMatcher.php';
 
 class KafkaHandlerTest extends MediaWikiTestCase {
 
-       public function setUp() {
+       protected function setUp() {
                if ( !class_exists( 'Monolog\Handler\AbstractProcessingHandler' )
                        || !class_exists( 'Kafka\Produce' )
                ) {
index 6ee54d3..be23c4a 100644 (file)
@@ -28,7 +28,7 @@ use TestingAccessWrapper;
 
 class LineFormatterTest extends MediaWikiTestCase {
 
-       public function setUp() {
+       protected function setUp() {
                if ( !class_exists( 'Monolog\Formatter\LineFormatter' ) ) {
                        $this->markTestSkipped( 'This test requires monolog to be installed' );
                }