1 common.test CommonBackdropArrayUnitTest::setUp()

Sets up unit test environment.

Unlike BackdropWebTestCase::setUp(), BackdropUnitTestCase::setUp() does not install modules because tests are performed without accessing the database. Any required files must be explicitly included by the child class setUp() method.

Overrides BackdropUnitTestCase::setUp

File

core/modules/simpletest/tests/common.test, line 3030
Tests for common.inc functionality.

Class

CommonBackdropArrayUnitTest
Tests the various backdrop_array_* helper functions.

Code

function setUp() {
  parent::setUp();

  // Create a form structure with a nested element.
  $this->form['fieldset']['element'] = array(
    '#value' => 'Nested element',
  );

  // Set up parent array.
  $this->parents = array('fieldset', 'element');
}