Bolt\Tests\Twig\UserHandlerTest::testIsAllowedString PHP Method

testIsAllowedString() public method

public testIsAllowedString ( )
    public function testIsAllowedString()
    {
        $app = $this->getApp();
        $handler = new UserHandler($app);
        $users = $this->getMockUsers();
        $users->expects($this->atLeastOnce())->method('isAllowed')->will($this->returnValue(true));
        $app['users'] = $users;
        $result = $handler->isAllowed('koala', 'clippy');
        $this->assertTrue($result);
    }