Loading core/modules/user/tests/src/FunctionalJavascript/UserPasswordResetTest.php +8 −14 Original line number Diff line number Diff line Loading @@ -24,17 +24,6 @@ class UserPasswordResetTest extends WebDriverTestBase { getTestFiles as drupalGetTestFiles; } /** * The profile to install as a basis for testing. * * This test uses the standard profile to test the password reset in * combination with an ajax request provided by the user picture configuration * in the standard profile. * * @var string */ protected $profile = 'standard'; /** * The user object to test password resetting. * Loading @@ -45,7 +34,12 @@ class UserPasswordResetTest extends WebDriverTestBase { /** * {@inheritdoc} */ protected static $modules = ['block']; protected static $modules = ['block', 'test_user_config']; /** * {@inheritdoc} */ protected $defaultTheme = 'stark'; /** * {@inheritdoc} Loading @@ -54,7 +48,7 @@ protected function setUp(): void { parent::setUp(); // Create a user. $account = $this->drupalCreateUser(); $account = $this->drupalCreateUser(['access content']); // Activate user by logging in. $this->drupalLogin($account); Loading @@ -65,7 +59,7 @@ protected function setUp(): void { // Set the last login time that is used to generate the one-time link so // that it is definitely over a second ago. $account->login = REQUEST_TIME - mt_rand(10, 100000); $account->login = \Drupal::time()->getRequestTime() - mt_rand(10, 100000); Database::getConnection()->update('users_field_data') ->fields(['login' => $account->getLastLoginTime()]) ->condition('uid', $account->id()) Loading core/phpstan-baseline.neon +0 −5 Original line number Diff line number Diff line Loading @@ -2430,11 +2430,6 @@ parameters: count: 1 path: modules/user/tests/src/Functional/Views/UserChangedTest.php - message: "#^Call to deprecated constant REQUEST_TIME\\: Deprecated in drupal\\:8\\.3\\.0 and is removed from drupal\\:11\\.0\\.0\\. Use \\\\Drupal\\:\\:time\\(\\)\\-\\>getRequestTime\\(\\); $#" count: 1 path: modules/user/tests/src/FunctionalJavascript/UserPasswordResetTest.php - message: "#^Variable \\$result in isset\\(\\) always exists and is not nullable\\.$#" count: 1 Loading Loading
core/modules/user/tests/src/FunctionalJavascript/UserPasswordResetTest.php +8 −14 Original line number Diff line number Diff line Loading @@ -24,17 +24,6 @@ class UserPasswordResetTest extends WebDriverTestBase { getTestFiles as drupalGetTestFiles; } /** * The profile to install as a basis for testing. * * This test uses the standard profile to test the password reset in * combination with an ajax request provided by the user picture configuration * in the standard profile. * * @var string */ protected $profile = 'standard'; /** * The user object to test password resetting. * Loading @@ -45,7 +34,12 @@ class UserPasswordResetTest extends WebDriverTestBase { /** * {@inheritdoc} */ protected static $modules = ['block']; protected static $modules = ['block', 'test_user_config']; /** * {@inheritdoc} */ protected $defaultTheme = 'stark'; /** * {@inheritdoc} Loading @@ -54,7 +48,7 @@ protected function setUp(): void { parent::setUp(); // Create a user. $account = $this->drupalCreateUser(); $account = $this->drupalCreateUser(['access content']); // Activate user by logging in. $this->drupalLogin($account); Loading @@ -65,7 +59,7 @@ protected function setUp(): void { // Set the last login time that is used to generate the one-time link so // that it is definitely over a second ago. $account->login = REQUEST_TIME - mt_rand(10, 100000); $account->login = \Drupal::time()->getRequestTime() - mt_rand(10, 100000); Database::getConnection()->update('users_field_data') ->fields(['login' => $account->getLastLoginTime()]) ->condition('uid', $account->id()) Loading
core/phpstan-baseline.neon +0 −5 Original line number Diff line number Diff line Loading @@ -2430,11 +2430,6 @@ parameters: count: 1 path: modules/user/tests/src/Functional/Views/UserChangedTest.php - message: "#^Call to deprecated constant REQUEST_TIME\\: Deprecated in drupal\\:8\\.3\\.0 and is removed from drupal\\:11\\.0\\.0\\. Use \\\\Drupal\\:\\:time\\(\\)\\-\\>getRequestTime\\(\\); $#" count: 1 path: modules/user/tests/src/FunctionalJavascript/UserPasswordResetTest.php - message: "#^Variable \\$result in isset\\(\\) always exists and is not nullable\\.$#" count: 1 Loading