From 3d80c32dd2e49078f041d144a0a6634a707bcc27 Mon Sep 17 00:00:00 2001 From: catch <6915-catch@users.noreply.drupalcode.org> Date: Tue, 20 May 2025 11:39:01 +0100 Subject: [PATCH] Issue #3496319 by quietone: [random test failure] CommentPreviewTest::testCommentPreview (follow-up) --- core/modules/tracker/tests/src/Functional/TrackerTest.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/modules/tracker/tests/src/Functional/TrackerTest.php b/core/modules/tracker/tests/src/Functional/TrackerTest.php index 76a2e48d94ee..b8030b7f0338 100644 --- a/core/modules/tracker/tests/src/Functional/TrackerTest.php +++ b/core/modules/tracker/tests/src/Functional/TrackerTest.php @@ -223,11 +223,11 @@ public function testTrackerUser(): void { // Test escaping of title on user's tracker tab. \Drupal::service('module_installer')->install(['user_hooks_test']); Cache::invalidateTags(['rendered']); - \Drupal::state()->set('user_hooks_test_user_format_name_alter', TRUE); + \Drupal::keyvalue('user_hooks_test')->set('user_format_name_alter', TRUE); $this->drupalGet('user/' . $this->user->id() . '/activity'); $this->assertSession()->assertEscaped('<em>' . $this->user->id() . '</em>'); - \Drupal::state()->set('user_hooks_test_user_format_name_alter_safe', TRUE); + \Drupal::keyvalue('user_hooks_test')->set('user_format_name_alter_safe', TRUE); Cache::invalidateTags(['rendered']); $this->drupalGet('user/' . $this->user->id() . '/activity'); $this->assertSession()->assertNoEscaped('<em>' . $this->user->id() . '</em>'); -- GitLab