X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=tests%2Fphpunit%2Fincludes%2Flogging%2FPatrolLogFormatterTest.php;h=b680454354855c32011800c2e8d37ce18439a5fe;hb=2f885ee6b797e5a176ce7b270b674a04b5945b06;hp=6e1c5efc79be0f994b32e84ef0d0a26c8a3fe9cd;hpb=012248fc5a7d6d0257df1a0feadbda5ae4a477e2;p=lhc%2Fweb%2Fwiklou.git diff --git a/tests/phpunit/includes/logging/PatrolLogFormatterTest.php b/tests/phpunit/includes/logging/PatrolLogFormatterTest.php index 6e1c5efc79..b680454354 100644 --- a/tests/phpunit/includes/logging/PatrolLogFormatterTest.php +++ b/tests/phpunit/includes/logging/PatrolLogFormatterTest.php @@ -8,105 +8,105 @@ class PatrolLogFormatterTest extends LogFormatterTestCase { * Do not change the existing data, just add a new database row */ public static function providePatrolLogDatabaseRows() { - return array( + return [ // Current format - array( - array( + [ + [ 'type' => 'patrol', 'action' => 'patrol', 'comment' => 'patrol comment', 'namespace' => NS_MAIN, 'title' => 'Page', - 'params' => array( + 'params' => [ '4::curid' => 2, '5::previd' => 1, '6::auto' => 0, - ), - ), - array( + ], + ], + [ 'text' => 'User marked revision 2 of page Page patrolled', - 'api' => array( + 'api' => [ 'curid' => 2, 'previd' => 1, 'auto' => false, - ), - ), - ), + ], + ], + ], // Current format - autopatrol - array( - array( + [ + [ 'type' => 'patrol', 'action' => 'patrol', 'comment' => 'patrol comment', 'namespace' => NS_MAIN, 'title' => 'Page', - 'params' => array( + 'params' => [ '4::curid' => 2, '5::previd' => 1, '6::auto' => 1, - ), - ), - array( + ], + ], + [ 'text' => 'User automatically marked revision 2 of page Page patrolled', - 'api' => array( + 'api' => [ 'curid' => 2, 'previd' => 1, 'auto' => true, - ), - ), - ), + ], + ], + ], // Legacy format - array( - array( + [ + [ 'type' => 'patrol', 'action' => 'patrol', 'comment' => 'patrol comment', 'namespace' => NS_MAIN, 'title' => 'Page', - 'params' => array( + 'params' => [ '2', '1', '0', - ), - ), - array( + ], + ], + [ 'legacy' => true, 'text' => 'User marked revision 2 of page Page patrolled', - 'api' => array( + 'api' => [ 'curid' => 2, 'previd' => 1, 'auto' => false, - ), - ), - ), + ], + ], + ], // Legacy format - autopatrol - array( - array( + [ + [ 'type' => 'patrol', 'action' => 'patrol', 'comment' => 'patrol comment', 'namespace' => NS_MAIN, 'title' => 'Page', - 'params' => array( + 'params' => [ '2', '1', '1', - ), - ), - array( + ], + ], + [ 'legacy' => true, 'text' => 'User automatically marked revision 2 of page Page patrolled', - 'api' => array( + 'api' => [ 'curid' => 2, 'previd' => 1, 'auto' => true, - ), - ), - ), - ); + ], + ], + ], + ]; } /**