Move test assertion to mirror parameter order
authorKosta Harlan <kharlan@wikimedia.org>
Wed, 3 Oct 2018 20:42:55 +0000 (16:42 -0400)
committerKosta Harlan <kharlan@wikimedia.org>
Wed, 3 Oct 2018 20:42:55 +0000 (16:42 -0400)
Follow up from I2df0551c5837adc578b27082ab6ba2ac95d937f8

Bug: T206130
Change-Id: Ib669c77fdb709846d0182cb28796cf53914114c4

tests/phpunit/includes/TitlePermissionTest.php

index f53b059..baf8243 100644 (file)
@@ -660,10 +660,6 @@ class TitlePermissionTest extends MediaWikiLangTestCase {
                $result = $this->title->getUserPermissionsErrors( 'bogus', $this->user );
                $this->assertEquals( $resultNone, $result );
 
-               $this->setUserPerm( '' );
-               $result = $this->title->getUserPermissionsErrors( 'patrol', $this->user );
-               $this->assertEquals( $resultPatrol, $result );
-
                $this->setUserPerm( 'editmyusercss' );
                $result = $this->title->getUserPermissionsErrors( 'bogus', $this->user );
                $this->assertEquals( $resultMyCss, $result );
@@ -688,6 +684,10 @@ class TitlePermissionTest extends MediaWikiLangTestCase {
                $result = $this->title->getUserPermissionsErrors( 'bogus', $this->user );
                $this->assertEquals( $resultUserJs, $result );
 
+               $this->setUserPerm( '' );
+               $result = $this->title->getUserPermissionsErrors( 'patrol', $this->user );
+               $this->assertEquals( $resultPatrol, $result );
+
                $this->setUserPerm( [ 'edituserjs', 'edituserjson', 'editusercss' ] );
                $result = $this->title->getUserPermissionsErrors( 'bogus', $this->user );
                $this->assertEquals( [ [ 'badaccess-group0' ] ], $result );