Reverted r92364 (per-namespace permissions).
[lhc/web/wiklou.git] / tests / phpunit / includes / TitlePermissionTest.php
index 9594f0c..4c6ad92 100644 (file)
@@ -62,15 +62,11 @@ class TitlePermissionTest extends MediaWikiLangTestCase {
        function setUserPerm( $perm ) {
                // Setting member variables is evil!!!
 
-               if ( !is_array( $perm ) ) {
-                       $perm = array( $perm );
-               }
-               for ($i = 0; $i < 100; $i++) {
-                       $this->user->mRights[$i] = $perm;
+               if ( is_array( $perm ) ) {
+                       $this->user->mRights = $perm;
+               } else {
+                       $this->user->mRights = array( $perm );
                }
-
-               // Hack, hack hack ...
-               $this->user->mRights['*'] = $perm;
        }
 
        function setTitle( $ns, $title = "Main_Page" ) {