Neos\Flow\Tests\Unit\Security\Authorization\PrivilegeManagerTest::isGrantedGrantsAccessIfNoPolicyEntryCouldBeFound PHP Method

isGrantedGrantsAccessIfNoPolicyEntryCouldBeFound() public method

    public function isGrantedGrantsAccessIfNoPolicyEntryCouldBeFound()
    {
        $testRole1 = $this->getAccessibleMock(Security\Policy\Role::class, ['getPrivilegesByType'], ['Acme.Demo:TestRole1']);
        $testRole1->expects($this->once())->method('getPrivilegesByType')->with(MethodPrivilegeInterface::class)->will($this->returnValue([]));
        $this->mockSecurityContext->expects($this->once())->method('getRoles')->will($this->returnValue([$testRole1]));
        $this->assertTrue($this->privilegeManager->isGranted(MethodPrivilegeInterface::class, $this->mockJoinPoint));
    }