diff --git a/core/lib/Drupal/Core/Test/AssertMailTrait.php b/core/lib/Drupal/Core/Test/AssertMailTrait.php
index 57bd288a42443780acd261321c9af7632d26802f..5adc24efa2a1d075861d11ba25c4c4486f7be2db 100644
--- a/core/lib/Drupal/Core/Test/AssertMailTrait.php
+++ b/core/lib/Drupal/Core/Test/AssertMailTrait.php
@@ -149,8 +149,14 @@ protected function assertMailPattern($field_name, $regex, $message = '', $group
    *
    * @param int $count
    *   Optional number of emails to output.
+   *
+   * @deprecated in drupal:9.2.0 and is removed from drupal:10.0.0. Use
+   *   dump() instead.
+   *
+   * @see https://www.drupal.org/node/3197514
    */
   protected function verboseEmail($count = 1) {
+    @trigger_error('AssertMailTrait::verboseEmail() is deprecated in drupal:9.2.0 and is removed from drupal:10.0.0. Use dump() instead. See https://www.drupal.org/node/3197514', E_USER_DEPRECATED);
     $mails = $this->getMails();
     for ($i = count($mails) - 1; $i >= count($mails) - $count && $i >= 0; $i--) {
       $mail = $mails[$i];
diff --git a/core/modules/comment/tests/src/Kernel/Views/CommentAdminViewTest.php b/core/modules/comment/tests/src/Kernel/Views/CommentAdminViewTest.php
index cdc3cd9c608ccd68f0eee45aadda1ebf3d2cf77c..681347d09c70af4f55278e2b23d4127ec13f21d6 100644
--- a/core/modules/comment/tests/src/Kernel/Views/CommentAdminViewTest.php
+++ b/core/modules/comment/tests/src/Kernel/Views/CommentAdminViewTest.php
@@ -161,7 +161,6 @@ protected function doTestFilters($display_id) {
     $executable = Views::getView('comment');
     $build = $executable->preview($display_id);
     $this->setRawContent($renderer->renderRoot($build));
-    $this->verbose($this->getRawContent());
 
     // Assert the exposed filters on the admin page.
     $this->assertField('subject');
@@ -178,7 +177,6 @@ protected function doTestFilters($display_id) {
     $executable->setExposedInput(['subject' => 'Anonymous']);
     $build = $executable->preview($display_id);
     $this->setRawContent($renderer->renderRoot($build));
-    $this->verbose($this->getRawContent());
 
     $elements = $this->cssSelect('input[type="checkbox"]');
     $this->assertCount(1, $elements, 'Only anonymous comment is visible.');
@@ -189,7 +187,6 @@ protected function doTestFilters($display_id) {
     $executable->setExposedInput(['subject' => 'My comment']);
     $build = $executable->preview($display_id);
     $this->setRawContent($renderer->renderRoot($build));
-    $this->verbose($this->getRawContent());
 
     $elements = $this->cssSelect('input[type="checkbox"]');
     $this->assertCount(1, $elements, 'Only admin comment is visible.');
@@ -201,7 +198,6 @@ protected function doTestFilters($display_id) {
     $executable->setExposedInput(['author_name' => 'barry']);
     $build = $executable->preview($display_id);
     $this->setRawContent($renderer->renderRoot($build));
-    $this->verbose($this->getRawContent());
 
     $elements = $this->cssSelect('input[type="checkbox"]');
     $this->assertCount(1, $elements, 'Only anonymous comment is visible.');
@@ -213,7 +209,6 @@ protected function doTestFilters($display_id) {
     $executable->setExposedInput(['author_name' => $this->adminUser->label()]);
     $build = $executable->preview($display_id);
     $this->setRawContent($renderer->renderRoot($build));
-    $this->verbose($this->getRawContent());
 
     $elements = $this->cssSelect('input[type="checkbox"]');
     $this->assertCount(1, $elements, 'Only admin comment is visible.');
@@ -225,7 +220,6 @@ protected function doTestFilters($display_id) {
     $executable->setExposedInput(['langcode' => '***LANGUAGE_site_default***']);
     $build = $executable->preview($display_id);
     $this->setRawContent($renderer->renderRoot($build));
-    $this->verbose($this->getRawContent());
 
     $elements = $this->cssSelect('input[type="checkbox"]');
     $this->assertCount(2, $elements, 'Both comments are visible.');
@@ -260,7 +254,6 @@ protected function doTestFilters($display_id) {
     $executable->setExposedInput(['langcode' => 'ur']);
     $build = $executable->preview($display_id);
     $this->setRawContent($renderer->renderRoot($build));
-    $this->verbose($this->getRawContent());
 
     $elements = $this->cssSelect('input[type="checkbox"]');
     $this->assertCount(2, $elements, 'Both comments are visible.');
diff --git a/core/modules/comment/tests/src/Kernel/Views/CommentUserNameTest.php b/core/modules/comment/tests/src/Kernel/Views/CommentUserNameTest.php
index d312ea23407444b6e994ab97e6433f4bf2ef05c4..53b4074d1a1ad44d5ff3e4ab1dc8d993e61384ba 100644
--- a/core/modules/comment/tests/src/Kernel/Views/CommentUserNameTest.php
+++ b/core/modules/comment/tests/src/Kernel/Views/CommentUserNameTest.php
@@ -149,7 +149,6 @@ public function testUsername() {
     $executable = Views::getView($view_id);
     $build = $executable->preview();
     $this->setRawContent($renderer->renderRoot($build));
-    $this->verbose($this->getRawContent());
 
     $this->assertLink('My comment title');
     $this->assertLink('Anonymous comment title');
@@ -174,7 +173,6 @@ public function testUsername() {
     $this->assertNoLink($this->adminUser->label());
     // Note: External users aren't pointing to drupal user profiles.
     $this->assertLink('barry (not verified)');
-    $this->verbose($this->getRawContent());
     $this->assertLink('My comment title');
     $this->assertLink('Anonymous comment title');
   }
diff --git a/core/modules/datetime_range/tests/src/Kernel/SeparatorTranslationTest.php b/core/modules/datetime_range/tests/src/Kernel/SeparatorTranslationTest.php
index 90989156279f4eeebeb4d28538e12f467d8046c1..e4134c601aa8439c4e67f1bb5dfe7ef6c43aa39e 100644
--- a/core/modules/datetime_range/tests/src/Kernel/SeparatorTranslationTest.php
+++ b/core/modules/datetime_range/tests/src/Kernel/SeparatorTranslationTest.php
@@ -106,7 +106,6 @@ public function testSeparatorTranslation() {
     $display = EntityViewDisplay::collectRenderDisplay($entity, 'default');
     $build = $display->build($entity);
     $output = $this->container->get('renderer')->renderRoot($build);
-    $this->verbose($output);
     $this->assertStringContainsString('UNTRANSLATED', (string) $output);
 
     // Translate the separator.
@@ -123,7 +122,6 @@ public function testSeparatorTranslation() {
     $display = EntityViewDisplay::collectRenderDisplay($entity, 'default');
     $build = $display->build($entity);
     $output = $this->container->get('renderer')->renderRoot($build);
-    $this->verbose($output);
     $this->assertStringContainsString('NL_TRANSLATED!', (string) $output);
   }
 
diff --git a/core/modules/filter/tests/src/Kernel/FilterAPITest.php b/core/modules/filter/tests/src/Kernel/FilterAPITest.php
index dfcfe7a4ffb8d8d2b4e07be8751d9b01bf0c7121..aba51baa314ccdf247e3b6cb87b19db64fa9b6a0 100644
--- a/core/modules/filter/tests/src/Kernel/FilterAPITest.php
+++ b/core/modules/filter/tests/src/Kernel/FilterAPITest.php
@@ -68,17 +68,14 @@ public function testCheckMarkupFilterSubset() {
     $expected_filter_text_without_html_generators = "Text with evil content and a URL: https://www.drupal.org!";
 
     $actual_filtered_text = check_markup($text, 'filtered_html', '', []);
-    $this->verbose("Actual:<pre>$actual_filtered_text</pre>Expected:<pre>$expected_filtered_text</pre>");
     $this->assertEqual($expected_filtered_text, $actual_filtered_text, 'Expected filter result.');
     $actual_filtered_text_without_html_generators = check_markup($text, 'filtered_html', '', [FilterInterface::TYPE_MARKUP_LANGUAGE]);
-    $this->verbose("Actual:<pre>$actual_filtered_text_without_html_generators</pre>Expected:<pre>$expected_filter_text_without_html_generators</pre>");
     $this->assertEqual($expected_filter_text_without_html_generators, $actual_filtered_text_without_html_generators, 'Expected filter result when skipping FilterInterface::TYPE_MARKUP_LANGUAGE filters.');
     // Related to @see FilterSecurityTest.php/testSkipSecurityFilters(), but
     // this check focuses on the ability to filter multiple filter types at once.
     // Drupal core only ships with these two types of filters, so this is the
     // most extensive test possible.
     $actual_filtered_text_without_html_generators = check_markup($text, 'filtered_html', '', [FilterInterface::TYPE_HTML_RESTRICTOR, FilterInterface::TYPE_MARKUP_LANGUAGE]);
-    $this->verbose("Actual:<pre>$actual_filtered_text_without_html_generators</pre>Expected:<pre>$expected_filter_text_without_html_generators</pre>");
     $this->assertEqual($expected_filter_text_without_html_generators, $actual_filtered_text_without_html_generators, 'Expected filter result when skipping FilterInterface::TYPE_MARKUP_LANGUAGE filters, even when trying to disable filters of the FilterInterface::TYPE_HTML_RESTRICTOR type.');
   }
 
diff --git a/core/modules/filter/tests/src/Kernel/FilterKernelTest.php b/core/modules/filter/tests/src/Kernel/FilterKernelTest.php
index 077abfe70a8c459fa4a3ff85ec07f247678d2897..effcb7b78e4ba9c2bc2d47e4a6f5ada05018b1be 100644
--- a/core/modules/filter/tests/src/Kernel/FilterKernelTest.php
+++ b/core/modules/filter/tests/src/Kernel/FilterKernelTest.php
@@ -389,10 +389,7 @@ public function testLineBreakFilter() {
     $limit = max(ini_get('pcre.backtrack_limit'), ini_get('pcre.recursion_limit'));
     $source = $this->randomMachineName($limit);
     $result = _filter_autop($source);
-    $success = $this->assertEqual($result, '<p>' . $source . "</p>\n", 'Line break filter can process very long strings.');
-    if (!$success) {
-      $this->verbose("\n" . $source . "\n<hr />\n" . $result);
-    }
+    $this->assertEqual($result, '<p>' . $source . "</p>\n", 'Line break filter can process very long strings.');
   }
 
   /**
diff --git a/core/modules/link/tests/src/Functional/LinkFieldTest.php b/core/modules/link/tests/src/Functional/LinkFieldTest.php
index 8e881290cd768efc772e65f5cdab02e2bfef682d..5c51f9bd595fb0157ed03d8e766f515ef63df5f7 100644
--- a/core/modules/link/tests/src/Functional/LinkFieldTest.php
+++ b/core/modules/link/tests/src/Functional/LinkFieldTest.php
@@ -841,9 +841,7 @@ protected function renderTestEntity($id, $view_mode = 'full', $reset = TRUE) {
       ->getViewDisplay($entity->getEntityTypeId(), $entity->bundle(), $view_mode);
     $content = $display->build($entity);
     $output = \Drupal::service('renderer')->renderRoot($content);
-    $output = (string) $output;
-    $this->verbose($output);
-    return $output;
+    return (string) $output;
   }
 
 }
diff --git a/core/modules/locale/tests/src/Functional/LocaleUpdateDevelopmentReleaseTest.php b/core/modules/locale/tests/src/Functional/LocaleUpdateDevelopmentReleaseTest.php
index 1473aa483457146493b80d099b39f31f19ea57f0..ad07b5298d9c5e7c6ddb8040ee084c017c6297a9 100644
--- a/core/modules/locale/tests/src/Functional/LocaleUpdateDevelopmentReleaseTest.php
+++ b/core/modules/locale/tests/src/Functional/LocaleUpdateDevelopmentReleaseTest.php
@@ -33,9 +33,7 @@ protected function setUp(): void {
 
   public function testLocaleUpdateDevelopmentRelease() {
     $projects = locale_translation_build_projects();
-    $this->verbose($projects['drupal']->info['version']);
     $this->assertEqual('8.0.x', $projects['drupal']->info['version'], 'The branch of the core dev release.');
-    $this->verbose($projects['contrib']->info['version']);
     $this->assertEqual('12.x-10.x', $projects['contrib']->info['version'], 'The branch of the contrib module dev release.');
   }
 
diff --git a/core/modules/search/tests/src/Kernel/SearchExcerptTest.php b/core/modules/search/tests/src/Kernel/SearchExcerptTest.php
index eed87ef1641a61aae6208a36dc1a0316f79daaf9..ab786e34a6d181ac6d7566779a561311e1643d54 100644
--- a/core/modules/search/tests/src/Kernel/SearchExcerptTest.php
+++ b/core/modules/search/tests/src/Kernel/SearchExcerptTest.php
@@ -173,8 +173,6 @@ public function testSearchExcerptSimplified() {
     $text = str_repeat($lorem3, 20) . ' ' . $lorem1;
     $result = $this->doSearchExcerpt('Lìbêró', $text);
     $this->assertStringContainsString('<strong>libero</strong>', $result, 'Search excerpt works with caps and accents in longer text with whitespace');
-
-    $this->verbose('Elapsed time: ' . (microtime(TRUE) - $start_time));
   }
 
   /**
diff --git a/core/modules/system/tests/src/Functional/Mail/HtmlToTextTest.php b/core/modules/system/tests/src/Functional/Mail/HtmlToTextTest.php
index 9185687f16a22db4b122d65976edfb1ea77ed4c6..59d7e07e921750f8d27f2705680abafff706b783 100644
--- a/core/modules/system/tests/src/Functional/Mail/HtmlToTextTest.php
+++ b/core/modules/system/tests/src/Functional/Mail/HtmlToTextTest.php
@@ -58,11 +58,6 @@ protected function assertHtmlToText($html, $text, $message, $allowed_tags = NULL
     $message .= ' (' . $tested_tags . ')';
     $result = MailFormatHelper::htmlToText($html, $allowed_tags);
     $this->assertEqual($text, $result, Html::escape($message));
-    $verbose = 'html = <pre>' . $this->stringToHtml($html)
-      . '</pre><br />result = <pre>' . $this->stringToHtml($result)
-      . '</pre><br />expected = <pre>' . $this->stringToHtml($text)
-      . '</pre>';
-    $this->verbose($verbose);
   }
 
   /**
@@ -239,25 +234,11 @@ public function testDrupalHtmlToTextBlockTagToNewline() {
 EOT;
     $input = str_replace(["\r", "\n"], '', $input);
     $output = MailFormatHelper::htmlToText($input);
-    $pass = $this->assertNotRegExp('/\][^\n]*\[/s', $output, 'Block-level HTML tags should force newlines');
-    if (!$pass) {
-      $this->verbose($this->stringToHtml($output));
-    }
+    $this->assertNotRegExp('/\][^\n]*\[/s', $output, 'Block-level HTML tags should force newlines');
     $output_upper = mb_strtoupper($output);
     $upper_input = mb_strtoupper($input);
     $upper_output = MailFormatHelper::htmlToText($upper_input);
-    $pass = $this->assertEqual(
-      $upper_output,
-      $output_upper,
-      'Tag recognition should be case-insensitive'
-    );
-    if (!$pass) {
-      $this->verbose(
-        $upper_output
-        . '<br />should  be equal to <br />'
-        . $output_upper
-      );
-    }
+    $this->assertEquals($output_upper, $upper_output, 'Tag recognition should be case-insensitive');
   }
 
   /**
diff --git a/core/modules/tracker/tests/src/Functional/TrackerTest.php b/core/modules/tracker/tests/src/Functional/TrackerTest.php
index 9e8a302eb4b045b75a57e73d56e0ef93ee2982fe..f6b7429d3233b753eed20a9a389faf04ca47769f 100644
--- a/core/modules/tracker/tests/src/Functional/TrackerTest.php
+++ b/core/modules/tracker/tests/src/Functional/TrackerTest.php
@@ -351,7 +351,6 @@ public function testTrackerOrderingNewComments() {
     // on the tracker page.
     // It's almost certainly too brittle.
     $pattern = '/' . preg_quote($node_one->getTitle()) . '.+' . preg_quote($node_two->getTitle()) . '/s';
-    $this->verbose($pattern);
     // Verify that the most recent comment on node appears at the top of
     // tracker.
     $this->assertSession()->responseMatches($pattern);
diff --git a/core/modules/views/src/Tests/ViewResultAssertionTrait.php b/core/modules/views/src/Tests/ViewResultAssertionTrait.php
index ac04e21b39d9150b0fcddf5374a6d4b326dccab8..09a373d406ef0457f08a9c33e37fd8f7633518c7 100644
--- a/core/modules/views/src/Tests/ViewResultAssertionTrait.php
+++ b/core/modules/views/src/Tests/ViewResultAssertionTrait.php
@@ -126,12 +126,6 @@ protected function assertIdenticalResultsetHelper($view, $expected_result, $colu
       $expected_result[$key] = $row;
     }
 
-    $this->verbose('<pre style="white-space: pre-wrap;">'
-      . "\n\nQuery:\n" . $view->build_info['query']
-      . "\n\nQuery arguments:\n" . var_export($view->build_info['query']->getArguments(), TRUE)
-      . "\n\nActual result:\n" . var_export($result, TRUE)
-      . "\n\nExpected result:\n" . var_export($expected_result, TRUE));
-
     // Reset the numbering of the arrays.
     $result = array_values($result);
     $expected_result = array_values($expected_result);
diff --git a/core/modules/views/tests/src/Functional/ViewTestBase.php b/core/modules/views/tests/src/Functional/ViewTestBase.php
index ce6f3bd84619634270a726b7d195fad1f3905e34..c5fc8d75e223caaf6f2699d67d49f939860bb562 100644
--- a/core/modules/views/tests/src/Functional/ViewTestBase.php
+++ b/core/modules/views/tests/src/Functional/ViewTestBase.php
@@ -4,7 +4,6 @@
 
 use Behat\Mink\Exception\ElementNotFoundException;
 use Drupal\Core\Database\Database;
-use Drupal\Core\Database\Query\SelectInterface;
 use Drupal\Tests\BrowserTestBase;
 use Drupal\views\Tests\ViewResultAssertionTrait;
 use Drupal\views\Tests\ViewTestData;
@@ -114,7 +113,7 @@ protected function helperButtonHasLabel($id, $expected_label, $message = 'Label
   }
 
   /**
-   * Executes a view with debugging.
+   * Executes a view.
    *
    * @param \Drupal\views\ViewExecutable $view
    *   The view object.
@@ -127,11 +126,6 @@ protected function executeView(ViewExecutable $view, $args = []) {
     $view->setDisplay();
     $view->preExecute($args);
     $view->execute();
-    $verbose_message = '<pre>Executed view: ' . ((string) $view->build_info['query']) . '</pre>';
-    if ($view->build_info['query'] instanceof SelectInterface) {
-      $verbose_message .= '<pre>Arguments: ' . print_r($view->build_info['query']->getArguments(), TRUE) . '</pre>';
-    }
-    $this->verbose($verbose_message);
   }
 
   /**
diff --git a/core/modules/views/tests/src/Kernel/ViewsKernelTestBase.php b/core/modules/views/tests/src/Kernel/ViewsKernelTestBase.php
index 429614b18a915445cac0d70fbef48aa6f628e64e..6d76bbd1501ef62bedde284d019340bf2f8dd7d4 100644
--- a/core/modules/views/tests/src/Kernel/ViewsKernelTestBase.php
+++ b/core/modules/views/tests/src/Kernel/ViewsKernelTestBase.php
@@ -3,7 +3,6 @@
 namespace Drupal\Tests\views\Kernel;
 
 use Drupal\Core\Database\Database;
-use Drupal\Core\Database\Query\SelectInterface;
 use Drupal\KernelTests\KernelTestBase;
 use Drupal\views\Tests\ViewResultAssertionTrait;
 use Drupal\views\Tests\ViewTestData;
@@ -118,7 +117,7 @@ protected function orderResultSet($result_set, $column, $reverse = FALSE) {
   }
 
   /**
-   * Executes a view with debugging.
+   * Executes a view.
    *
    * @param \Drupal\views\ViewExecutable $view
    *   The view object.
@@ -129,11 +128,6 @@ protected function executeView($view, array $args = []) {
     $view->setDisplay();
     $view->preExecute($args);
     $view->execute();
-    $verbose_message = '<pre>Executed view: ' . ((string) $view->build_info['query']) . '</pre>';
-    if ($view->build_info['query'] instanceof SelectInterface) {
-      $verbose_message .= '<pre>Arguments: ' . print_r($view->build_info['query']->getArguments(), TRUE) . '</pre>';
-    }
-    $this->verbose($verbose_message);
   }
 
   /**
diff --git a/core/tests/Drupal/KernelTests/AssertContentTrait.php b/core/tests/Drupal/KernelTests/AssertContentTrait.php
index 61623f2bf8136201298fede557c9e1e0ba2f4446..5c684f0ca41f40beb204a66b253db5e599a600b7 100644
--- a/core/tests/Drupal/KernelTests/AssertContentTrait.php
+++ b/core/tests/Drupal/KernelTests/AssertContentTrait.php
@@ -885,11 +885,6 @@ protected function assertThemeOutput($callback, array $variables = [], $expected
     $output = (string) $renderer->executeInRenderContext(new RenderContext(), function () use ($callback, $variables) {
       return \Drupal::theme()->render($callback, $variables);
     });
-    $this->verbose(
-      '<hr />' . 'Result:' . '<pre>' . Html::escape(var_export($output, TRUE)) . '</pre>'
-      . '<hr />' . 'Expected:' . '<pre>' . Html::escape(var_export($expected, TRUE)) . '</pre>'
-      . '<hr />' . $output
-    );
     if (!$message) {
       $message = '%callback rendered correctly.';
     }
diff --git a/core/tests/Drupal/KernelTests/AssertLegacyTrait.php b/core/tests/Drupal/KernelTests/AssertLegacyTrait.php
index f2281004134eaa8d6e4271738ef8da532a82b399..1f7698e916323d243448f320f1809bb65e7d0f4c 100644
--- a/core/tests/Drupal/KernelTests/AssertLegacyTrait.php
+++ b/core/tests/Drupal/KernelTests/AssertLegacyTrait.php
@@ -113,8 +113,14 @@ protected function pass($message) {
 
   /**
    * @see \Drupal\simpletest\TestBase::verbose()
+   *
+   * @deprecated in drupal:9.2.0 and is removed from drupal:10.0.0. Use
+   *   dump() instead.
+   *
+   * @see https://www.drupal.org/node/3197514
    */
   protected function verbose($message) {
+    @trigger_error('AssertLegacyTrait::verbose() is deprecated in drupal:9.2.0 and is removed from drupal:10.0.0. Use dump() instead. See https://www.drupal.org/node/3197514', E_USER_DEPRECATED);
     if (in_array('--debug', $_SERVER['argv'], TRUE)) {
       // Write directly to STDOUT to not produce unexpected test output.
       // The STDOUT stream does not obey output buffering.
diff --git a/core/tests/Drupal/KernelTests/Core/Config/ConfigCRUDTest.php b/core/tests/Drupal/KernelTests/Core/Config/ConfigCRUDTest.php
index 87b0ad9c2cca475f07b109742847742b5af0ce4c..16c4182e47a0146ac1057fc6c40106fb04918b5b 100644
--- a/core/tests/Drupal/KernelTests/Core/Config/ConfigCRUDTest.php
+++ b/core/tests/Drupal/KernelTests/Core/Config/ConfigCRUDTest.php
@@ -271,7 +271,6 @@ public function testDataTypes() {
     $name = 'config_test.types';
     $config = $this->config($name);
     $original_content = file_get_contents(drupal_get_path('module', 'config_test') . '/' . InstallStorage::CONFIG_INSTALL_DIRECTORY . "/$name.yml");
-    $this->verbose('<pre>' . $original_content . "\n" . var_export($storage->read($name), TRUE));
 
     // Verify variable data types are intact.
     $data = [
@@ -297,7 +296,6 @@ public function testDataTypes() {
     $this->assertSame($data, $config->get());
     // Assert the data against the file storage.
     $this->assertSame($data, $storage->read($name));
-    $this->verbose('<pre>' . $name . var_export($storage->read($name), TRUE));
 
     // Set data using config::setData().
     $config->setData($data)->save();
diff --git a/core/tests/Drupal/KernelTests/Core/Render/Element/RenderElementTypesTest.php b/core/tests/Drupal/KernelTests/Core/Render/Element/RenderElementTypesTest.php
index 32ba294d325cf0dd909996c9a42b9d875e8dd18b..286ea3554ed0ac8b346f6bd38f50661f8a1a424b 100644
--- a/core/tests/Drupal/KernelTests/Core/Render/Element/RenderElementTypesTest.php
+++ b/core/tests/Drupal/KernelTests/Core/Render/Element/RenderElementTypesTest.php
@@ -37,13 +37,6 @@ protected function setUp(): void {
    */
   protected function assertElements(array $elements, $expected_html, $message) {
     $actual_html = (string) \Drupal::service('renderer')->renderRoot($elements);
-
-    $out = '<table><tr>';
-    $out .= '<td valign="top"><pre>' . Html::escape($expected_html) . '</pre></td>';
-    $out .= '<td valign="top"><pre>' . Html::escape($actual_html) . '</pre></td>';
-    $out .= '</tr></table>';
-    $this->verbose($out);
-
     $this->assertSame($expected_html, $actual_html, Html::escape($message));
   }
 
diff --git a/core/tests/Drupal/KernelTests/Core/Render/Element/TableSortExtenderTest.php b/core/tests/Drupal/KernelTests/Core/Render/Element/TableSortExtenderTest.php
index c4fca1f7b4bdcf2bfa8b47dd8592dd7fa02a938b..9c207105db4414bb3c394b399caaf554603e975d 100644
--- a/core/tests/Drupal/KernelTests/Core/Render/Element/TableSortExtenderTest.php
+++ b/core/tests/Drupal/KernelTests/Core/Render/Element/TableSortExtenderTest.php
@@ -2,7 +2,6 @@
 
 namespace Drupal\KernelTests\Core\Render\Element;
 
-use Drupal\Component\Utility\Html;
 use Drupal\Core\Utility\TableSort;
 use Drupal\KernelTests\KernelTestBase;
 use Symfony\Component\HttpFoundation\Request;
@@ -34,7 +33,6 @@ public function testTableSortInit() {
     $request->query->replace([]);
     \Drupal::getContainer()->get('request_stack')->push($request);
     $ts = TableSort::getContextFromRequest($headers, $request);
-    $this->verbose(strtr('$ts: <pre>!ts</pre>', ['!ts' => Html::escape(var_export($ts, TRUE))]));
     $this->assertEqual($expected_ts, $ts, 'Simple table headers sorted correctly.');
 
     // Test with simple table headers plus $_GET parameters that should _not_
@@ -47,7 +45,6 @@ public function testTableSortInit() {
     ]);
     \Drupal::getContainer()->get('request_stack')->push($request);
     $ts = TableSort::getContextFromRequest($headers, $request);
-    $this->verbose(strtr('$ts: <pre>!ts</pre>', ['!ts' => Html::escape(var_export($ts, TRUE))]));
     $this->assertEqual($expected_ts, $ts, 'Simple table headers plus non-overriding $_GET parameters sorted correctly.');
 
     // Test with simple table headers plus $_GET parameters that _should_
@@ -63,7 +60,6 @@ public function testTableSortInit() {
     $expected_ts['sort'] = 'desc';
     $expected_ts['query'] = ['alpha' => 'beta'];
     $ts = TableSort::getContextFromRequest($headers, $request);
-    $this->verbose(strtr('$ts: <pre>!ts</pre>', ['!ts' => Html::escape(var_export($ts, TRUE))]));
     $this->assertEqual($expected_ts, $ts, 'Simple table headers plus $_GET parameters sorted correctly.');
 
     // Test complex table headers.
@@ -95,7 +91,6 @@ public function testTableSortInit() {
       'sort' => 'desc',
       'query' => [],
     ];
-    $this->verbose(strtr('$ts: <pre>!ts</pre>', ['!ts' => Html::escape(var_export($ts, TRUE))]));
     $this->assertEqual($expected_ts, $ts, 'Complex table headers sorted correctly.');
 
     // Test complex table headers plus $_GET parameters that should _not_
@@ -114,7 +109,6 @@ public function testTableSortInit() {
       'sort' => 'asc',
       'query' => [],
     ];
-    $this->verbose(strtr('$ts: <pre>!ts</pre>', ['!ts' => Html::escape(var_export($ts, TRUE))]));
     $this->assertEqual($expected_ts, $ts, 'Complex table headers plus non-overriding $_GET parameters sorted correctly.');
 
     // Test complex table headers plus $_GET parameters that _should_
@@ -135,7 +129,6 @@ public function testTableSortInit() {
       'query' => ['alpha' => 'beta'],
     ];
     $ts = TableSort::getContextFromRequest($headers, $request);
-    $this->verbose(strtr('$ts: <pre>!ts</pre>', ['!ts' => Html::escape(var_export($ts, TRUE))]));
     $this->assertEquals($expected_ts, $ts, 'Complex table headers plus $_GET parameters sorted correctly.');
 
     // Test the initial_click_sort parameter.
@@ -174,14 +167,12 @@ public function testTableSortInit() {
     ]);
     \Drupal::getContainer()->get('request_stack')->push($request);
     $ts = TableSort::getContextFromRequest($headers, $request);
-    $this->verbose(strtr('$ts: <pre>!ts</pre>', ['!ts' => Html::escape(var_export($ts, TRUE))]));
     $expected_ts = [
       'name' => '1',
       'sql' => 'one',
       'sort' => 'desc',
       'query' => [],
     ];
-    $this->verbose(strtr('$ts: <pre>!ts</pre>', ['!ts' => Html::escape(var_export($ts, TRUE))]));
     $this->assertEquals($expected_ts, $ts, 'Complex table headers using the initial_click_sort parameter are sorted correctly.');
 
     // Test that if the initial_click_sort parameter is not defined, the default
@@ -198,7 +189,6 @@ public function testTableSortInit() {
       'sort' => 'asc',
       'query' => [],
     ];
-    $this->verbose(strtr('$ts: <pre>!ts</pre>', ['!ts' => Html::escape(var_export($ts, TRUE))]));
     $this->assertEquals($expected_ts, $ts, 'Complex table headers without using the initial_click_sort parameter are sorted correctly.');
 
     // Test that if the initial_click_sort parameter is defined, and the sort
@@ -215,7 +205,6 @@ public function testTableSortInit() {
       'sort' => 'asc',
       'query' => [],
     ];
-    $this->verbose(strtr('$ts: <pre>!ts</pre>', ['!ts' => Html::escape(var_export($ts, TRUE))]));
     $this->assertEquals($expected_ts, $ts, 'Complex table headers using the initial_click_sort and sort parameters are sorted correctly.');
 
     // Test that if the initial_click_sort parameter is defined and the value
@@ -232,7 +221,6 @@ public function testTableSortInit() {
       'sort' => 'asc',
       'query' => [],
     ];
-    $this->verbose(strtr('$ts: <pre>!ts</pre>', ['!ts' => Html::escape(var_export($ts, TRUE))]));
     $this->assertEquals($expected_ts, $ts, 'Complex table headers with the initial_click_sort set as ASC are sorted correctly.');
 
     // Tests that if the initial_click_sort is defined with a non expected value
@@ -249,7 +237,6 @@ public function testTableSortInit() {
       'sort' => 'foo',
       'query' => [],
     ];
-    $this->verbose(strtr('$ts: <pre>!ts</pre>', ['!ts' => Html::escape(var_export($ts, TRUE))]));
     $this->assertEquals($expected_ts, $ts, 'Complex table headers with the initial_click_sort set as foo are sorted correctly.');
   }
 
diff --git a/core/tests/Drupal/KernelTests/KernelTestBase.php b/core/tests/Drupal/KernelTests/KernelTestBase.php
index 1c520289dee216f7d3d71529a938a2203fe8d8a5..26ce0a8a7e8e37b654d563fea46c51ebd2efcbd9 100644
--- a/core/tests/Drupal/KernelTests/KernelTestBase.php
+++ b/core/tests/Drupal/KernelTests/KernelTestBase.php
@@ -5,7 +5,6 @@
 use Drupal\Component\FileCache\ApcuFileCacheBackend;
 use Drupal\Component\FileCache\FileCache;
 use Drupal\Component\FileCache\FileCacheFactory;
-use Drupal\Component\Utility\Html;
 use Drupal\Core\Config\Development\ConfigSchemaChecker;
 use Drupal\Core\Database\Database;
 use Drupal\Core\DependencyInjection\ContainerBuilder;
@@ -901,7 +900,6 @@ protected function render(array &$elements) {
     // Glean the content from the response object.
     $content = $response->getContent();
     $this->setRawContent($content);
-    $this->verbose('<pre style="white-space: pre-wrap">' . Html::escape($content));
     return $content;
   }
 
diff --git a/core/tests/Drupal/KernelTests/KernelTestBaseTest.php b/core/tests/Drupal/KernelTests/KernelTestBaseTest.php
index 025c5a490b5433d8d718c62585ca10ce21a37085..a188703f93ebf4557e94ddf4f7d8cf0f08a1731f 100644
--- a/core/tests/Drupal/KernelTests/KernelTestBaseTest.php
+++ b/core/tests/Drupal/KernelTests/KernelTestBaseTest.php
@@ -386,6 +386,16 @@ public function testAssertNotIdentical() {
     $this->assertNotIdentical('foo', 'bar');
   }
 
+  /**
+   * Tests the deprecation of AssertLegacyTrait::verbose().
+   *
+   * @group legacy
+    */
+  public function testVerbose() {
+    $this->expectDeprecation('AssertLegacyTrait::verbose() is deprecated in drupal:9.2.0 and is removed from drupal:10.0.0. Use dump() instead. See https://www.drupal.org/node/3197514');
+    $this->verbose('The show must go on');
+  }
+
   /**
    * Tests the deprecation of ::installSchema with the tables key_value(_expire).
    *