Merge "Warn if stateful ParserOutput transforms are used"
[lhc/web/wiklou.git] / maintenance / benchmarks / bench_if_switch.php
index 46c9d39..5f661f2 100644 (file)
@@ -42,11 +42,10 @@ class BenchIfSwitch extends Benchmarker {
                        [ 'function' => [ $this, 'doElseIf' ] ],
                        [ 'function' => [ $this, 'doSwitch' ] ],
                ] );
-               print $this->getFormattedResults();
        }
 
        // bench function 1
-       function doElseIf() {
+       protected function doElseIf() {
                $a = 'z';
                if ( $a == 'a' ) {
                } elseif ( $a == 'b' ) {
@@ -69,7 +68,7 @@ class BenchIfSwitch extends Benchmarker {
        }
 
        // bench function 2
-       function doSwitch() {
+       protected function doSwitch() {
                $a = 'z';
                switch ( $a ) {
                        case 'b':
@@ -107,5 +106,5 @@ class BenchIfSwitch extends Benchmarker {
        }
 }
 
-$maintClass = 'BenchIfSwitch';
+$maintClass = BenchIfSwitch::class;
 require_once RUN_MAINTENANCE_IF_MAIN;