You are here

public function AdminFunctionalityTest::setUp in Synonyms 2.0.x

Same name in this branch
  1. 2.0.x tests/src/Functional/AdminFunctionalityTest.php \Drupal\Tests\synonyms\Functional\AdminFunctionalityTest::setUp()
  2. 2.0.x modules/synonyms_autocomplete/tests/src/Functional/AdminFunctionalityTest.php \Drupal\Tests\synonyms_autocomplete\Functional\AdminFunctionalityTest::setUp()
  3. 2.0.x modules/synonyms_list_field/tests/src/Functional/AdminFunctionalityTest.php \Drupal\Tests\synonyms_list_field\Functional\AdminFunctionalityTest::setUp()
  4. 2.0.x modules/synonyms_search/tests/src/Functional/AdminFunctionalityTest.php \Drupal\Tests\synonyms_search\Functional\AdminFunctionalityTest::setUp()
  5. 2.0.x modules/synonyms_select/tests/src/Functional/AdminFunctionalityTest.php \Drupal\Tests\synonyms_select\Functional\AdminFunctionalityTest::setUp()

Overrides BrowserTestBase::setUp

File

modules/synonyms_search/tests/src/Functional/AdminFunctionalityTest.php, line 30

Class

AdminFunctionalityTest
Checks if admin functionality works correctly.

Namespace

Drupal\Tests\synonyms_search\Functional

Code

public function setUp() {
  parent::setUp();
  $this->container
    ->get('router.builder')
    ->rebuild();

  // Log in an admin user.
  $account = $this
    ->drupalCreateUser([
    'administer site configuration',
    'administer synonyms',
  ]);
  $this
    ->drupalLogin($account);
}