function BigPipeRegressionTest::testMultipleReplacements
Test BigPipe replacement of multiple complex replacements.
In some situations with either a large number of replacements or multiple replacements involving complex operations, some replacements were not completed. This is a simulation of such a situation by rendering a lot of placeholders on a page.
See also
https://www.drupal.org/node/3390178
File
-
core/
modules/ big_pipe/ tests/ src/ FunctionalJavascript/ BigPipeRegressionTest.php, line 122
Class
- BigPipeRegressionTest
- BigPipe regression tests.
Namespace
Drupal\Tests\big_pipe\FunctionalJavascriptCode
public function testMultipleReplacements() : void {
// @todo re-enable this test in https://www.drupal.org/project/drupal/issues/3590200
$this->markTestSkipped();
$assert_session = $this->assertSession();
$this->drupalGet(Url::fromRoute('big_pipe_test_multiple_replacements'));
$this->assertNotNull($assert_session->waitForElement('css', 'script[data-big-pipe-event="stop"]'));
$this->assertCount(0, $this->getDrupalSettings()['bigPipePlaceholderIds']);
$this->assertCount(0, $this->getSession()
->getPage()
->findAll('css', 'span[data-big-pipe-placeholder-id]'));
$this->assertCount(BigPipeRegressionTestController::PLACEHOLDER_COUNT + 1, $this->getSession()
->getPage()
->findAll('css', 'script[data-big-pipe-replacement-for-placeholder-with-id]'));
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.