You are here

function AdminMenuWebTestCase::setUp in Administration menu 6.3

Same name and namespace in other branches
  1. 7.3 tests/admin_menu.test \AdminMenuWebTestCase::setUp()

Generates a random database prefix, runs the install scripts on the prefixed database and enable the specified modules. After installation many caches are flushed and the internal browser is setup so that the page requests will run on the new prefix. A temporary files directory is created with the same name as the database prefix.

Parameters

...: List of modules to enable for the duration of the test. This can be either a single array or a variable number of string arguments.

Overrides DrupalWebTestCase::setUp

3 calls to AdminMenuWebTestCase::setUp()
AdminMenuDynamicLinksTestCase::setUp in tests/admin_menu.test
Generates a random database prefix, runs the install scripts on the prefixed database and enable the specified modules. After installation many caches are flushed and the internal browser is setup so that the page requests will run on the new prefix.…
AdminMenuLinkTypesTestCase::setUp in tests/admin_menu.test
Generates a random database prefix, runs the install scripts on the prefixed database and enable the specified modules. After installation many caches are flushed and the internal browser is setup so that the page requests will run on the new prefix.…
AdminMenuPermissionsTestCase::setUp in tests/admin_menu.test
Generates a random database prefix, runs the install scripts on the prefixed database and enable the specified modules. After installation many caches are flushed and the internal browser is setup so that the page requests will run on the new prefix.…
3 methods override AdminMenuWebTestCase::setUp()
AdminMenuDynamicLinksTestCase::setUp in tests/admin_menu.test
Generates a random database prefix, runs the install scripts on the prefixed database and enable the specified modules. After installation many caches are flushed and the internal browser is setup so that the page requests will run on the new prefix.…
AdminMenuLinkTypesTestCase::setUp in tests/admin_menu.test
Generates a random database prefix, runs the install scripts on the prefixed database and enable the specified modules. After installation many caches are flushed and the internal browser is setup so that the page requests will run on the new prefix.…
AdminMenuPermissionsTestCase::setUp in tests/admin_menu.test
Generates a random database prefix, runs the install scripts on the prefixed database and enable the specified modules. After installation many caches are flushed and the internal browser is setup so that the page requests will run on the new prefix.…

File

tests/admin_menu.test, line 17
Tests for the Administration menu module.

Class

AdminMenuWebTestCase
Base class for all administration menu web test cases.

Code

function setUp() {

  // Enable admin menu module and any other modules.
  $modules = func_get_args();
  $modules = isset($modules[0]) ? $modules[0] : $modules;
  $modules[] = 'admin_menu';
  parent::setUp($modules);

  // Disable client-side caching.
  variable_set('admin_menu_cache_client', FALSE);

  // Disable Clean URLs to ensure drupal.org testbot compatibility.
  variable_set('clean_url', 0);
}