function MemoryBackendTest::testAllowedProceeding

Same name in other branches
  1. 9 core/tests/Drupal/Tests/Core/Flood/MemoryBackendTest.php \Drupal\Tests\Core\Flood\MemoryBackendTest::testAllowedProceeding()
  2. 10 core/tests/Drupal/Tests/Core/Flood/MemoryBackendTest.php \Drupal\Tests\Core\Flood\MemoryBackendTest::testAllowedProceeding()

Tests an allowed flood event.

File

core/tests/Drupal/Tests/Core/Flood/MemoryBackendTest.php, line 41

Class

MemoryBackendTest
Tests the memory flood implementation.

Namespace

Drupal\Tests\Core\Flood

Code

public function testAllowedProceeding() : void {
    $threshold = 2;
    $window_expired = -1;
    $this->flood
        ->register('test_event', $window_expired);
    $this->assertTrue($this->flood
        ->isAllowed('test_event', $threshold));
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.