protected function ViewsBulkOperationsBulkFormTest::setUp in Views Bulk Operations (VBO) 8
Same name and namespace in other branches
- 8.2 tests/src/Functional/ViewsBulkOperationsBulkFormTest.php \Drupal\Tests\views_bulk_operations\Functional\ViewsBulkOperationsBulkFormTest::setUp()
Overrides BrowserTestBase::setUp
File
- tests/
src/ Functional/ ViewsBulkOperationsBulkFormTest.php, line 28
Class
- ViewsBulkOperationsBulkFormTest
- @coversDefaultClass \Drupal\views_bulk_operations\Plugin\views\field\ViewsBulkOperationsBulkForm @group views_bulk_operations
Namespace
Drupal\Tests\views_bulk_operations\FunctionalCode
protected function setUp() {
parent::setUp();
// Create some nodes for testing.
$this
->drupalCreateContentType([
'type' => 'page',
]);
$this->testNodes = [];
$time = REQUEST_TIME;
for ($i = 0; $i < 15; $i++) {
// Ensure nodes are sorted in the same order they are inserted in the
// array.
$time -= $i;
$this->testNodes[] = $this
->drupalCreateNode([
'type' => 'page',
'title' => 'Title ' . $i,
'sticky' => FALSE,
'created' => $time,
'changed' => $time,
]);
}
}