Removed overzealous cleanup that was responsible for failures of tests in CruiseContr...
authorMax Semenik <maxsem@users.mediawiki.org>
Mon, 25 Oct 2010 17:45:46 +0000 (17:45 +0000)
committerMax Semenik <maxsem@users.mediawiki.org>
Mon, 25 Oct 2010 17:45:46 +0000 (17:45 +0000)
maintenance/tests/phpunit/includes/search/SearchDbTest.php
maintenance/tests/phpunit/includes/search/SearchUpdateTest.php

index eecedfd..f35e8b3 100644 (file)
@@ -26,10 +26,6 @@ class SearchDbTest extends SearchEngineTest {
 
        function tearDown() {
                $this->removeSearchData();
-               if ( !is_null( $this->db ) ) {
-                       wfGetLB()->closeConnecton( $this->db );
-               }
-               unset( $this->db );
                unset( $this->search );
                $GLOBALS['wgContLang'] = null;
        }
index fd7230d..1cfb276 100644 (file)
@@ -74,14 +74,11 @@ class SearchUpdateTest extends PHPUnit_Framework_TestCase {
                $wgLBFactoryConf['class'] = 'LBFactory_Simple';
                $wgDBservers = null;
                $wgContLang = Language::factory( 'en' );
-               LBFactory::destroyInstance();
        }
 
        function tearDown() {
                global $wgSearchType, $wgDBtype, $wgLBFactoryConf, $wgDBservers, $wgContLang;
 
-               LBFactory::destroyInstance();
-
                $wgSearchType = self::$searchType;
                $wgDBtype = self::$dbtype;
                $wgLBFactoryConf = self::$factoryconf;