public function RedirectOnLoginTest::testEnabled in Moderation Dashboard 8
Same name and namespace in other branches
- 2.0.x tests/src/Functional/RedirectOnLoginTest.php \Drupal\Tests\moderation_dashboard\Functional\RedirectOnLoginTest::testEnabled()
Tests enabled redirect on login.
File
- tests/
src/ Functional/ RedirectOnLoginTest.php, line 15
Class
- RedirectOnLoginTest
- Tests redirect on login configuration.
Namespace
Drupal\Tests\moderation_dashboard\FunctionalCode
public function testEnabled() {
// Redirect is enabled by default.
$this
->assertSame(TRUE, $this
->config('moderation_dashboard.settings')
->get('redirect_on_login'));
// User is redirected.
$this
->drupalLogin($this->user);
$this
->assertSession()
->addressEquals("user/{$this->user->id()}/moderation/dashboard");
}