You are here

public function FloodControlUiPageTest::testFloodUnblockUiPageAdminUser in Flood control 2.0.x

Test flood control with admin user.

File

tests/src/Functional/FloodControlUiPageTest.php, line 60

Class

FloodControlUiPageTest
Tests that the Flood control UI pages are reachable.

Namespace

Drupal\Tests\flood_control\Functional

Code

public function testFloodUnblockUiPageAdminUser() {
  $this
    ->drupalLogin($this->adminUser);
  $this
    ->drupalGet('admin/people/flood-unblock');
  $this
    ->assertSession()
    ->statusCodeEquals(200, 'Status code is equal to 200');

  // Test that there is an empty flood list
  $this
    ->assertSession()
    ->pageTextContains('There are no failed logins at this time.');
}