diff --git a/core/modules/datetime/src/Tests/DateTestBase.php b/core/modules/datetime/src/Tests/DateTestBase.php index 0f1277e..eb7b881 100644 --- a/core/modules/datetime/src/Tests/DateTestBase.php +++ b/core/modules/datetime/src/Tests/DateTestBase.php @@ -92,6 +92,7 @@ protected function setUp() { 'administer entity_test content', 'administer entity_test form display', 'administer content types', + 'bypass node access', 'administer node fields', ]); $this->drupalLogin($web_user); diff --git a/core/modules/node/src/Tests/NodeAccessMenuLinkTest.php b/core/modules/node/src/Tests/NodeAccessMenuLinkTest.php index c1bc0eb..6d3320a 100644 --- a/core/modules/node/src/Tests/NodeAccessMenuLinkTest.php +++ b/core/modules/node/src/Tests/NodeAccessMenuLinkTest.php @@ -33,6 +33,7 @@ protected function setUp() { $this->contentAdminUser = $this->drupalCreateUser(array( 'access content', 'administer content types', + 'bypass node access', 'administer menu' )); diff --git a/core/modules/node/src/Tests/NodeCreationTest.php b/core/modules/node/src/Tests/NodeCreationTest.php index 7c4e142..d62737c 100644 --- a/core/modules/node/src/Tests/NodeCreationTest.php +++ b/core/modules/node/src/Tests/NodeCreationTest.php @@ -78,6 +78,13 @@ function testNodeCreation() { $this->drupalLogin($admin_user); $this->drupalGet('node/add/page'); $this->assertNoFieldById('edit-revision', NULL , 'The revision checkbox is not present.'); + + // Check that a user with user administer content types permission is not + // allowed to create content. + $content_types_admin = $this->drupalCreateUser(['administer content types']); + $this->drupalLogin($content_types_admin); + $this->drupalGet('node/add/page'); + $this->assertResponse(403); } /** diff --git a/core/modules/node/src/Tests/NodeTypeTranslationTest.php b/core/modules/node/src/Tests/NodeTypeTranslationTest.php index 1c3a768..f26cf78 100644 --- a/core/modules/node/src/Tests/NodeTypeTranslationTest.php +++ b/core/modules/node/src/Tests/NodeTypeTranslationTest.php @@ -55,6 +55,7 @@ protected function setUp() { $admin_permissions = array( 'administer content types', + 'bypass node access', 'administer node fields', 'administer languages', 'administer site configuration', diff --git a/core/modules/page_cache/src/Tests/PageCacheTagsIntegrationTest.php b/core/modules/page_cache/src/Tests/PageCacheTagsIntegrationTest.php index c8db96e..21a52fa 100644 --- a/core/modules/page_cache/src/Tests/PageCacheTagsIntegrationTest.php +++ b/core/modules/page_cache/src/Tests/PageCacheTagsIntegrationTest.php @@ -102,6 +102,7 @@ function testPageCacheTags() { 'user:0', 'user:' . $author_1->id(), 'config:filter.format.basic_html', + 'config:node_type_list', 'config:color.theme.bartik', 'config:search.settings', 'config:system.menu.account', @@ -142,6 +143,7 @@ function testPageCacheTags() { 'user:' . $author_2->id(), 'config:color.theme.bartik', 'config:filter.format.full_html', + 'config:node_type_list', 'config:search.settings', 'config:system.menu.account', 'config:system.menu.tools',