function DrupalTestCase::checkOriginalModules in SimpleTest 6
Retrieves and saves current modules list into $_originalModules and $_modules.
2 calls to DrupalTestCase::checkOriginalModules()
- DrupalTestCase::drupalModuleDisable in ./
drupal_test_case.php - Disables a drupal module
- DrupalTestCase::drupalModuleEnable in ./
drupal_test_case.php - Enables a drupal module
File
- ./
drupal_test_case.php, line 322
Class
- DrupalTestCase
- Test case for typical Drupal tests. Extends WebTestCase for comfortable browser usage but also implements all UnitTestCase methods, I wish WebTestCase would do this.
Code
function checkOriginalModules() {
if (empty($this->_originalModules)) {
require_once './modules/system/system.admin.inc';
$form_state = array();
$form = drupal_retrieve_form('system_modules', $form_state);
$this->_originalModules = drupal_map_assoc($form['status']['#default_value']);
$this->_modules = $this->_originalModules;
}
}