コード例 #1
0
ファイル: WebDriverTest.php プロジェクト: aleguisf/fvdev1
 public function testSubmitUnchecked()
 {
     $this->module->amOnPage('/form/unchecked');
     $this->module->seeCheckboxIsChecked('#checkbox');
     $this->module->uncheckOption('#checkbox');
     $this->module->click('#submit');
     $this->module->see('0', '#notice');
 }
コード例 #2
0
 public function testBug1637()
 {
     $this->module->amOnPage('/form/bug1637');
     // confirm that options outside a form are still selectable
     $this->module->selectOption('input[name=first_test_radio]', 'Yes');
     // confirm that it did what we expected and did not do anything else
     $this->module->seeOptionIsSelected('input[name=first_test_radio]', 'Yes');
     $this->module->dontSeeOptionIsSelected('input[name=first_test_radio]', 'No');
 }
コード例 #3
0
ファイル: WebDriverTest.php プロジェクト: Marfuz/c4t_test
 public function testAppendFieldDiv()
 {
     $this->module->amOnPage('/form/div_content_editable');
     //make sure we see 'sunrise' which is the default text in the textarea
     $this->module->see('sunrise', '#description');
     //fill in some new text and see if we can see it
     $textarea_value = 'moonrise';
     $this->module->appendField('#description', $textarea_value);
     $this->module->see('sunrise' . $textarea_value, '#description');
 }
コード例 #4
0
 public function testSessionSnapshots()
 {
     $this->module->amOnPage('/');
     $this->module->setCookie('PHPSESSID', '123456', ['path' => '/']);
     $this->module->saveSessionSnapshot('login');
     $this->module->seeCookie('PHPSESSID');
     $this->webDriver->manage()->deleteAllCookies();
     $this->module->dontSeeCookie('PHPSESSID');
     $this->module->loadSessionSnapshot('login');
     $this->module->seeCookie('PHPSESSID');
 }
コード例 #5
0
 public function testEmptyFormSubmit()
 {
     $this->shouldFail();
     $this->module->amOnPage('/form/complex');
     $this->module->submitForm('form111', array());
 }
コード例 #6
0
 public function testSeeElementMalformedWdLocator()
 {
     $this->setExpectedException('Codeception\\Exception\\MalformedLocator');
     $this->module->amOnPage('/');
     $this->module->seeElement(WebDriverBy::xpath('H---EY!'));
 }
コード例 #7
0
 /**
  * @Issue 2921
  */
 public function testSeeInFieldForTextarea()
 {
     $this->module->amOnPage('/form/bug2921');
     $this->module->seeInField('foo', 'bar baz');
 }