MediaWiki  REL1_19
SpecialSearchTest Class Reference

Test class for SpecialSearch class Copyright © 2012, Antoine Musso. More...

Inheritance diagram for SpecialSearchTest:
Collaboration diagram for SpecialSearchTest:

List of all members.

Public Member Functions

 newUserWithSearchNS ($opt=null)
 Helper to create a new User object with given options User remains anonymous though.
 provideSearchOptionsTests ()
 setUp ()
 tearDown ()
 testProfileAndNamespaceLoading ($requested, $userOptions, $expectedProfile, $expectedNS, $message= 'Profile name and namespaces mismatches!')
 SpecialSearch::load provideSearchOptionsTests

Private Attributes

 $search

Detailed Description

Test class for SpecialSearch class Copyright © 2012, Antoine Musso.

Author:
Antoine Musso Database

Definition at line 10 of file SpecialSearchTest.php.


Member Function Documentation

Helper to create a new User object with given options User remains anonymous though.

Definition at line 97 of file SpecialSearchTest.php.

References User\newFromId().

Referenced by testProfileAndNamespaceLoading().

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 62 of file SpecialSearchTest.php.

References SearchEngine\defaultNamespaces().

Here is the call graph for this function:

Definition at line 13 of file SpecialSearchTest.php.

Definition at line 14 of file SpecialSearchTest.php.

SpecialSearchTest::testProfileAndNamespaceLoading ( requested,
userOptions,
expectedProfile,
expectedNS,
message = 'Profile name and namespaces mismatches!' 
)

SpecialSearch::load provideSearchOptionsTests

Parameters:
$requestedArray Request parameters. For example array( 'ns5' => true, 'ns6' => true). NULL to use default options.
$userOptionsArray User options to test with. For example array('searchNs5' => 1 );. NULL to use default options.
$expectedProfileAn expected search profile name
$expectedNsArray Expected namespaces

Definition at line 24 of file SpecialSearchTest.php.

References $search, newUserWithSearchNS(), and RequestContext\setUser().

Here is the call graph for this function:


Member Data Documentation

SpecialSearchTest::$search [private]

Definition at line 11 of file SpecialSearchTest.php.

Referenced by testProfileAndNamespaceLoading().


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