/** * Make sure that superuser has access to create an article. */ public function testCreateAccess() { $path = new Path('node/add/article'); $this->assertTrue($path->hasAccess(), 'Superuser does not have access to create an article.'); $this->assertTrue(Article::hasCreateAccess(), "Superuser does not have access to create an article."); }
/** * Make sure that the authenticated user has access to create an article. */ public function testCreateAccess() { $path = new Path('node/add/article'); $this->assertFalse($path->hasAccess(), 'Authenticated user has access to create an article.'); $this->assertFalse(Article::hasCreateAccess(), "Authenticated user has access to create an article."); }