$node_storage->
resetCache([$node->
id()]);
$node =
$node_storage->
load($node->
id());
$this->
assertFalse($node->
isPublished(), 'A single node has been unpublished.'
);
// The second node should still be published.
$node_storage->
resetCache([$nodes[1
]->
id()]);
$node =
$node_storage->
load($nodes[1
]->
id());
$this->
assertTrue($node->
isPublished(), 'An unchecked node is still published.'
);
// Set up to include just the sticky actions.
$view = Views::
getView('test_bulk_form'
);
$display = &
$view->storage->
getDisplay('default'
);
$display['display_options'
]['fields'
]['node_bulk_form'
]['include_exclude'
] = 'include';
$display['display_options'
]['fields'
]['node_bulk_form'
]['selected_actions'
]['node_make_sticky_action'
] = 'node_make_sticky_action';
$display['display_options'
]['fields'
]['node_bulk_form'
]['selected_actions'
]['node_make_unsticky_action'
] = 'node_make_unsticky_action';
$view->
save();
$this->
drupalGet('test_bulk_form'
);
$options =
$this->
assertSession()->
selectExists('edit-action'
)->
findAll('css', 'option'
);
$this->
assertCount(3,
$options);
$this->
assertSession()->
optionExists('edit-action', 'node_make_sticky_action'
);
$this->
assertSession()->
optionExists('edit-action', 'node_make_unsticky_action'
);