Certificationy\Cli\Tests\Command\StartCommandTest::testCanGetQuestions PHP Method

testCanGetQuestions() public method

public testCanGetQuestions ( )
    public function testCanGetQuestions()
    {
        $helper = $this->command->getHelper('question');
        $helper->setInputStream($this->getInputStream(str_repeat("0\n", 20)));
        $commandTester = new CommandTester($this->command);
        $commandTester->execute(array('command' => $this->command->getName(), 'categories' => ['Templating']));
        $output = $commandTester->getDisplay();
        $this->assertRegExp('/Twig/', $output);
        $this->assertRegExp('/Starting a new set of 20 questions/', $commandTester->getDisplay());
    }