You are here

protected function DrupalUnitTestCase::tearDown in SimpleTest 7.2

Same name and namespace in other branches
  1. 6.2 drupal_web_test_case.php \DrupalUnitTestCase::tearDown()
  2. 7 drupal_web_test_case.php \DrupalUnitTestCase::tearDown()

File

./drupal_web_test_case.php, line 701
Provides DrupalTestCase, DrupalUnitTestCase, and DrupalWebTestCase classes.

Class

DrupalUnitTestCase
Test case for Drupal unit tests.

Code

protected function tearDown() {
  global $conf;

  // Get back to the original connection.
  Database::removeConnection('default');
  Database::renameConnection('simpletest_original_default', 'default');
  $conf['file_public_path'] = $this->originalFileDirectory;

  // Restore modules if necessary.
  if (isset($this->originalModuleList)) {
    module_list(TRUE, FALSE, FALSE, $this->originalModuleList);
  }
}