You are here

public function FormModeManagerUiTest::testEntityFormModeManagerLinksUi in Form mode manager 8

Same name and namespace in other branches
  1. 8.2 tests/src/Functional/FormModeManagerUiTest.php \Drupal\Tests\form_mode_manager\Functional\FormModeManagerUiTest::testEntityFormModeManagerLinksUi()

Tests the Form Mode Manager user Links positions interface.

File

tests/src/Functional/FormModeManagerUiTest.php, line 89

Class

FormModeManagerUiTest
Tests the Form mode manager user interfaces.

Namespace

Drupal\Tests\form_mode_manager\Functional

Code

public function testEntityFormModeManagerLinksUi() {

  // Test the Form Mode Manager UI page.
  $this
    ->drupalLogin($this->anonymousUser);
  $this
    ->drupalGet('admin/config/content/form_mode_manager/links-task');
  $this
    ->assertSession()
    ->statusCodeEquals(403);
  $this
    ->drupalLogin($this->adminUser);
  $this
    ->drupalGet('admin/config/content/form_mode_manager/links-task');
  $this
    ->assertSession()
    ->statusCodeEquals(200);
  $this
    ->assertSession()
    ->titleEquals('Form Mode Manager settings Links task | Drupal');
  $this
    ->assertLocalTasks(self::$uiLocalTabsExpected);
  $this
    ->assertSession()
    ->selectExists('tasks_location_node');
}