You are here

protected function SettingsFormTest::assertAutotimeout in Automated Logout 8

Asserts the timeout for a particular user.

Parameters

int $uid: User uid to assert the timeout for.

int $expected_timeout: The expected timeout.

string $message: The test message.

2 calls to SettingsFormTest::assertAutotimeout()
SettingsFormTest::testSettingsForm in tests/src/Kernel/SettingsFormTest.php
Tests the behaviour of the settings upon submission.
SettingsFormTest::testTimeoutPrecedence in tests/src/Kernel/SettingsFormTest.php
Tests the precedence of the timeouts.

File

tests/src/Kernel/SettingsFormTest.php, line 282

Class

SettingsFormTest
Tests the settings form.

Namespace

Drupal\Tests\autologout\Kernel

Code

protected function assertAutotimeout($uid, $expected_timeout, $message = '') {
  self::assertEquals($this->container
    ->get('autologout.manager')
    ->getUserTimeout($uid), $expected_timeout, $message);
}