MediaWiki  1.28.0
MWRestrictionsTest Class Reference
Inheritance diagram for MWRestrictionsTest:
Collaboration diagram for MWRestrictionsTest:

Public Member Functions

 provideCheck ()
 
 testArray ($data, $expect)
 MWRestrictions::newFromArray MWRestrictions::__construct MWRestrictions::loadFromArray MWRestrictions::toArray provideArray. More...
 
 testCheck ($request, $expect)
 MWRestrictions::check provideCheck. More...
 
 testCheckIP ($ip, $pass)
 MWRestrictions::checkIP provideCheckIP. More...
 
 testJson ($json, $expect)
 MWRestrictions::newFromJson MWRestrictions::__construct MWRestrictions::loadFromArray MWRestrictions::toJson MWRestrictions::__toString provideJson. More...
 
 testNewDefault ()
 MWRestrictions::newDefault MWRestrictions::__construct. More...
 

Static Public Member Functions

static provideArray ()
 
static provideCheckIP ()
 
static provideJson ()
 
static setUpBeforeClass ()
 

Static Protected Attributes

static $restrictionsForChecks
 

Detailed Description

Definition at line 2 of file MWRestrictionsTest.php.

Member Function Documentation

static MWRestrictionsTest::provideArray ( )
static

Definition at line 54 of file MWRestrictionsTest.php.

References true.

MWRestrictionsTest::provideCheck ( )

Definition at line 178 of file MWRestrictionsTest.php.

References $request, $ret, $status, as, and StatusValue\newGood().

static MWRestrictionsTest::provideCheckIP ( )
static

Definition at line 157 of file MWRestrictionsTest.php.

References false, and true.

static MWRestrictionsTest::provideJson ( )
static

Definition at line 110 of file MWRestrictionsTest.php.

static MWRestrictionsTest::setUpBeforeClass ( )
static

Definition at line 6 of file MWRestrictionsTest.php.

References MWRestrictions\newFromArray().

MWRestrictionsTest::testArray (   $data,
  $expect 
)

MWRestrictions::newFromArray MWRestrictions::__construct MWRestrictions::loadFromArray MWRestrictions::toArray provideArray.

Parameters
array$data
bool | InvalidArgumentException$expectTrue if the call succeeds, otherwise the exception that should be thrown.

Definition at line 39 of file MWRestrictionsTest.php.

References $ret, and MWRestrictions\newFromArray().

MWRestrictionsTest::testCheck (   $request,
  $expect 
)

MWRestrictions::check provideCheck.

Parameters
WebRequest$request
Status$expect

Definition at line 174 of file MWRestrictionsTest.php.

References $request, and check.

MWRestrictionsTest::testCheckIP (   $ip,
  $pass 
)

MWRestrictions::checkIP provideCheckIP.

Parameters
string$ip
bool$pass

Definition at line 153 of file MWRestrictionsTest.php.

MWRestrictionsTest::testJson (   $json,
  $expect 
)
MWRestrictionsTest::testNewDefault ( )

Member Data Documentation

MWRestrictionsTest::$restrictionsForChecks
staticprotected

Definition at line 4 of file MWRestrictionsTest.php.


The documentation for this class was generated from the following file: