Merge "ChangeTags: Fix double escaping of tag descriptions"
[lhc/web/wiklou.git] / maintenance / benchmarks / benchmarkCSSMin.php
index 3eaa88d..8e2acb2 100644 (file)
@@ -52,25 +52,16 @@ class BenchmarkCSSMin extends Benchmarker {
 
                $this->bench( [
                        "minify ($filename)" => [
-                               'function' => [ 'CSSMin', 'minify' ],
+                               'function' => [ CSSMin::class, 'minify' ],
                                'args' => [ $css ]
                        ],
                        "remap ($filename)" => [
-                               'function' => [ 'CSSMin', 'remap' ],
+                               'function' => [ CSSMin::class, 'remap' ],
                                'args' => [ $css, dirname( $file ), 'https://example.org/test/', true ]
                        ],
                ] );
        }
-
-       private function loadFile( $file ) {
-               $css = file_get_contents( $file );
-               // Detect GZIP compression header
-               if ( substr( $css, 0, 2 ) === "\037\213" ) {
-                       $css = gzdecode( $css );
-               }
-               return $css;
-       }
 }
 
-$maintClass = 'BenchmarkCSSMin';
+$maintClass = BenchmarkCSSMin::class;
 require_once RUN_MAINTENANCE_IF_MAIN;