You are here

protected function NestedArrayTest::setUp in Drupal 10

Same name and namespace in other branches
  1. 8 core/tests/Drupal/Tests/Component/Utility/NestedArrayTest.php \Drupal\Tests\Component\Utility\NestedArrayTest::setUp()
  2. 9 core/tests/Drupal/Tests/Component/Utility/NestedArrayTest.php \Drupal\Tests\Component\Utility\NestedArrayTest::setUp()

File

core/tests/Drupal/Tests/Component/Utility/NestedArrayTest.php, line 31

Class

NestedArrayTest
@coversDefaultClass \Drupal\Component\Utility\NestedArray @group Utility

Namespace

Drupal\Tests\Component\Utility

Code

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

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

  // Set up parent array.
  $this->parents = [
    'details',
    'element',
  ];
}