diff --git a/core/modules/block/block.module b/core/modules/block/block.module index 3566534..b2898fc 100644 --- a/core/modules/block/block.module +++ b/core/modules/block/block.module @@ -318,7 +318,7 @@ function block_page_build(&$page) { // With the block module, it's possible to disable the main content block. // By default, Drupal gets mad at us if we do that to protect users from // completely locking themselves out of the site by disabling page-managing - // modules, but since this is a page-manging module, we're in charge of the + // modules, but since this is a page-managing module, we're in charge of the // main content, not system module. $system_main_content_added = &drupal_static('system_main_content_added'); $system_main_content_added = TRUE; diff --git a/core/modules/block/lib/Drupal/block/Tests/ContentBlockTest.php b/core/modules/block/lib/Drupal/block/Tests/ContentBlockTest.php index 14290fb..78aaa4a 100644 --- a/core/modules/block/lib/Drupal/block/Tests/ContentBlockTest.php +++ b/core/modules/block/lib/Drupal/block/Tests/ContentBlockTest.php @@ -24,14 +24,14 @@ class ContentBlockTest extends WebTestBase { } function setUp() { - parent::setUp(); + parent::setUp(array('block')); // Create and log in an administrative user having access to the Full HTML // text format. $this->admin_user = $this->drupalCreateUser(array( 'administer blocks', 'access administration pages', - 'create page content', + 'bypass node access', )); $this->drupalLogin($this->admin_user); } @@ -54,13 +54,13 @@ class ContentBlockTest extends WebTestBase { $nid2 = $node->nid; // Set the block to be hidden on the first node path that we just created. - $edit = array(); - $edit['pages'] = 'node/' . $nid1; + $edit = array('pages' => "node/$nid1"); $this->drupalPost('admin/structure/block/manage/system/main/configure', $edit, t('Save block')); // Check that the body text is properly hiding. $this->drupalGet('node/' . $nid1); $this->assertNoText($body, 'Content block is properly hiding.'); + // Check that the body text is properly displaying. $this->drupalGet('node/' . $nid2); $this->assertText($body, 'Content block is properly displaying.');