10000 [RFC] add input to the arguments of dialog helper by cordoval · Pull Request #8366 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content

[RFC] add input to the arguments of dialog helper #8366

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
add test for no interaction aka -n
  • Loading branch information
cordoval committed Jun 27, 2013
commit 1a458271645bb24ed3cb8466dd85589cd47f89aa
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,14 @@ public function testAskAndValidate()
}
}

public function testNoInteraction()
{
$dialog = new DialogHelper();
$input = new ArrayInput(array());
$input->setInteractive(false);
$this->assertEquals('not yet', $dialog->ask($input, $this->getOutputStream(), 'Do you have a job?', 'not yet'));
}

protected function getInputStream($input)
{
$stream = fopen('php://memory', 'r+', false);
Expand Down
0