public function CheckboxTest::testManipulate in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/behat/mink/driver-testsuite/tests/Form/CheckboxTest.php \Behat\Mink\Tests\Driver\Form\CheckboxTest::testManipulate()
File
- vendor/
behat/ mink/ driver-testsuite/ tests/ Form/ CheckboxTest.php, line 9
Class
Namespace
Behat\Mink\Tests\Driver\FormCode
public function testManipulate() {
$this
->getSession()
->visit($this
->pathTo('advanced_form.html'));
$checkbox = $this
->getAssertSession()
->fieldExists('agreement');
$this
->assertNull($checkbox
->getValue());
$this
->assertFalse($checkbox
->isChecked());
$checkbox
->check();
$this
->assertEquals('yes', $checkbox
->getValue());
$this
->assertTrue($checkbox
->isChecked());
$checkbox
->uncheck();
$this
->assertNull($checkbox
->getValue());
$this
->assertFalse($checkbox
->isChecked());
}