Bolt\Tests\Nut\UserRoleAddTest::testRoleFails PHP Метод

testRoleFails() публичный Метод

public testRoleFails ( )
    public function testRoleFails()
    {
        $app = $this->getApp();
        $app['users'] = $this->getUserMockWithReturns(false, false);
        $command = new UserRoleAdd($app);
        $tester = new CommandTester($command);
        $tester->execute(['username' => 'test', 'role' => 'admin']);
        $result = $tester->getDisplay();
        $this->assertRegExp('/Could not add role/', trim($result));
    }