You are here

function BlockAccessDisableTestCase::testOperationGranted in Block Access 7

Test $user1 can do operation

File

tests/op_basic_disable.test, line 61
Tests for block_access / operation disable

Class

BlockAccessDisableTestCase
Tests for block_access / operation disable

Code

function testOperationGranted() {
  $this
    ->drupalLogin($this->user1);

  // Disable block
  $edit = array(
    'blocks[block_' . $this->block->delta . '][region]' => BLOCK_REGION_NONE,
  );
  $this
    ->drupalPost('admin/structure/block', $edit, t('Save blocks'));
  $this
    ->assertResponse(200);

  // Verify block in disabled region
  $this
    ->assertBlockInRegion($this->block, BLOCK_REGION_NONE);
}