protected function DataCollectorTableTest::assertRowsIncreased in Charts 5.0.x
Same name and namespace in other branches
- 8.4 tests/src/FunctionalJavascript/DataCollectorTableTest.php \Drupal\Tests\charts\FunctionalJavascript\DataCollectorTableTest::assertRowsIncreased()
Assert rows.
1 call to DataCollectorTableTest::assertRowsIncreased()
- DataCollectorTableTest::doTableOperation in tests/
src/ FunctionalJavascript/ DataCollectorTableTest.php - Do table operation.
File
- tests/
src/ FunctionalJavascript/ DataCollectorTableTest.php, line 158
Class
- DataCollectorTableTest
- Tests the data collector table element.
Namespace
Drupal\Tests\charts\FunctionalJavascriptCode
protected function assertRowsIncreased() {
$page = $this
->getSession()
->getPage();
$this
->assertTrue($page
->waitFor(10, function ($page) {
$expected_rows = DataCollectorTableTestForm::INITIAL_ROWS + 1;
$rows = $page
->findAll('css', static::TABLE_ROW_SELECTOR);
return count($rows) === $expected_rows;
}), 'Expected rows were increased by one after add row click.');
}