Updated Drupal to 8.6. This goes with the following updates because it's possible...
[yaffs-website] / web / core / modules / tracker / tests / src / Functional / TrackerTest.php
index 1a77d95ac8967aab279b93aab69847dbe94d2977..75b7b5cde797a64bd0ee7b5357287d72a6ced6b7 100644 (file)
@@ -93,6 +93,7 @@ class TrackerTest extends BrowserTestBase {
     $expected_tags = Cache::mergeTags($expected_tags, $role_tags);
     $block_tags = [
       'block_view',
+      'local_task',
       'config:block.block.page_actions_block',
       'config:block.block.page_tabs_block',
       'config:block_list',
@@ -179,6 +180,7 @@ class TrackerTest extends BrowserTestBase {
     $expected_tags = Cache::mergeTags($expected_tags, $role_tags);
     $block_tags = [
       'block_view',
+      'local_task',
       'config:block.block.page_actions_block',
       'config:block.block.page_tabs_block',
       'config:block_list',
@@ -361,8 +363,14 @@ class TrackerTest extends BrowserTestBase {
     ];
     $this->drupalPostForm('comment/reply/node/' . $nodes[3]->id() . '/comment', $comment, t('Save'));
 
-    // Start indexing backwards from node 3.
-    \Drupal::state()->set('tracker.index_nid', 3);
+    // Create an unpublished node.
+    $unpublished = $this->drupalCreateNode([
+      'title' => $this->randomMachineName(8),
+      'status' => 0,
+    ]);
+
+    // Start indexing backwards from node 4.
+    \Drupal::state()->set('tracker.index_nid', 4);
 
     // Clear the current tracker tables and rebuild them.
     db_delete('tracker_node')