Merge "Bug 36785 Special:Shortpages lists only NS_MAIN pages. (pages from all $wgCont...
[lhc/web/wiklou.git] / tests / parser / parserTest.inc
index ac557a3..deb5c5a 100644 (file)
@@ -140,7 +140,7 @@ class ParserTest {
                        $wgNamespaceAliases, $wgNamespaceProtection, $wgLocalFileRepo,
                        $parserMemc, $wgThumbnailScriptPath, $wgScriptPath,
                        $wgArticlePath, $wgStyleSheetPath, $wgScript, $wgStylePath, $wgExtensionAssetsPath,
-                       $wgMainCacheType, $wgMessageCacheType, $wgParserCacheType;
+                       $wgMainCacheType, $wgMessageCacheType, $wgParserCacheType, $wgLockManagers;
 
                $wgScript = '/index.php';
                $wgScriptPath = '/';
@@ -149,6 +149,11 @@ class ParserTest {
                $wgStylePath = '/skins';
                $wgExtensionAssetsPath = '/extensions';
                $wgThumbnailScriptPath = false;
+               $wgLockManagers = array( array(
+                       'name'          => 'fsLockManager',
+                       'class'         => 'FSLockManager',
+                       'lockDirectory' => wfTempDir() . '/test-repo/lockdir',
+               ) );
                $wgLocalFileRepo = array(
                        'class'           => 'LocalRepo',
                        'name'            => 'local',
@@ -627,6 +632,11 @@ class ParserTest {
                        'wgScriptPath' => '/',
                        'wgArticlePath' => '/wiki/$1',
                        'wgActionPaths' => array(),
+                       'wgLockManagers' => array(
+                               'name'          => 'fsLockManager',
+                               'class'         => 'FSLockManager',
+                               'lockDirectory' => $this->uploadDir . '/lockdir',
+                       ),
                        'wgLocalFileRepo' => array(
                                'class' => 'LocalRepo',
                                'name' => 'local',
@@ -837,7 +847,6 @@ class ParserTest {
                                   'iw_local'  => 1 ),
                        ) );
 
-
                # Update certain things in site_stats
                $this->db->insert( 'site_stats', array( 'ss_row_id' => 1, 'ss_images' => 2, 'ss_good_articles' => 1 ) );
 
@@ -952,6 +961,8 @@ class ParserTest {
         */
        private function teardownGlobals() {
                RepoGroup::destroySingleton();
+               FileBackendGroup::destroySingleton();
+               LockManagerGroup::destroySingleton();
                LinkCache::singleton()->clear();
 
                foreach ( $this->savedGlobals as $var => $val ) {