protected property DrupalTestCase::$setup

Flag to indicate whether the test has been set up.

The setUp() method isolates the test from the parent Drupal site by creating a random prefix for the database and setting up a clean file storage directory. The tearDown() method then cleans up this test environment. We must ensure that setUp() has been run. Otherwise, tearDown() will act on the parent Drupal site rather than the test environment, destroying live data.

File

drupal-7.x/modules/simpletest/drupal_web_test_case.php, line 86

Class

DrupalTestCase
Base class for Drupal tests.

Code

protected $setup = FALSE;