Tests the node bulk form.
public function testBulkForm() {
$this
->drupalLogin($this
->drupalCreateUser(array(
'administer nodes',
)));
$node = $this
->drupalCreateNode();
$this
->drupalGet('test-node-bulk-form');
$elements = $this
->xpath('//select[@id="edit-action"]//option');
$this
->assertIdentical(count($elements), 8, 'All node operations are found.');
// Block a node using the bulk form.
$this
->assertTrue($node->status);
$edit = array(
'node_bulk_form[0]' => TRUE,
'action' => 'node_unpublish_action',
);
$this
->drupalPost(NULL, $edit, t('Apply'));
// Re-load the node and check their status.
$node = entity_load('node', $node
->id());
$this
->assertFalse($node->status);
}