Merge "Made RepoGroup use ProcessCacheLRU"
[lhc/web/wiklou.git] / tests / phpunit / includes / ExceptionTest.php
index 9e76045..eaef1f7 100644 (file)
@@ -38,7 +38,6 @@ class ExceptionTest extends MediaWikiTestCase {
                );
        }
 
-
        /**
         * Lame JSON schema validation.
         *
@@ -49,7 +48,7 @@ class ExceptionTest extends MediaWikiTestCase {
         * @param $key String Name of the key to validate in the serialized JSON
         * @dataProvider provideJsonSerializedKeys
         */
-       function testJsonserializeexceptionKeys($expectedKeyType, $exClass, $key) {
+       function testJsonserializeexceptionKeys( $expectedKeyType, $exClass, $key ) {
 
                # Make sure we log a backtrace:
                $this->setMwGlobals( array( 'wgLogExceptionBacktrace' => true ) );
@@ -61,7 +60,7 @@ class ExceptionTest extends MediaWikiTestCase {
                        "JSON serialized exception is missing key '$key'"
                );
                $this->assertInternalType( $expectedKeyType, $json->$key,
-                       "JSON serialized key '$key' has type " . gettype($json->$key)
+                       "JSON serialized key '$key' has type " . gettype( $json->$key )
                        . " (expected: $expectedKeyType)."
                );
        }
@@ -71,17 +70,17 @@ class ExceptionTest extends MediaWikiTestCase {
         */
        function provideJsonSerializedKeys() {
                $testCases = array();
-               foreach( array( 'Exception', 'MWException' ) as $exClass ) {
+               foreach ( array( 'Exception', 'MWException' ) as $exClass ) {
                        $exTests = array(
-                               array( 'string',  $exClass,  'id' ),
-                               array( 'string',  $exClass,  'file' ),
-                               array( 'integer', $exClass,  'line' ),
-                               array( 'string',  $exClass,  'message' ),
-                               array( 'null',    $exClass,  'url' ),
+                               array( 'string', $exClass, 'id' ),
+                               array( 'string', $exClass, 'file' ),
+                               array( 'integer', $exClass, 'line' ),
+                               array( 'string', $exClass, 'message' ),
+                               array( 'null', $exClass, 'url' ),
                                # Backtrace only enabled with wgLogExceptionBacktrace = true
-                               array( 'array',   $exClass,  'backtrace' ),
+                               array( 'array', $exClass, 'backtrace' ),
                        );
-                       $testCases = array_merge($testCases, $exTests);
+                       $testCases = array_merge( $testCases, $exTests );
                }
                return $testCases;
        }