public function _addInterface(WebGuy $I)
 {
     $I->waitForText('interfaces', 10);
     $I->click('.create-child[rel="--*?1!"]');
     CommonScenarios::waitAndClickInTypeahead($I, 'interface');
     $I->fillField('.generatedForm input.value[name*="--*?1!--*?1!--*?1!"]', 'test-name' . time());
     $I->selectOption('.generatedForm select[name*="--*?1!--*?1!--*?2!"]', 'ianaift:other');
     $I->click('.create-child', '.generatedForm');
     CommonScenarios::waitAndClickInTypeahead($I, 'description');
     $I->fillField('input.value[name*="--*?1!--*?1!--*?3!"]', 'loopback interface');
 }
 public function _createEmptyModule(WebGuy $I)
 {
     $I->canSee('Create empty root element');
     $I->wait(2);
     $I->click('.typeaheadName');
     $I->waitForElement('.typeahead');
     $I->click('interfaces');
     $I->click('.typeaheadNS');
     $I->expectTo('see only one available NS');
     $I->seeNumberOfElements('.typeaheadNS + .typeahead a', 1);
     $I->click('urn:ietf:params:xml:ns:yang:ietf-interfaces');
     $I->click('Create');
     $I->waitForText('interfaces');
 }
 public function _turingAddTransition(WebGuy $I, $addDelta = false, $state = 0)
 {
     $I->wait(2);
     if ($addDelta === false) {
         $I->click('.create-child');
         $I->waitForText('transition-function');
         $I->click('transition-function');
         $I->wait(2);
         $I->click('.create-child[rel*="--*?1!--*?1!"]', '.generatedForm');
         $prefix = '--*?1!';
     } else {
         $I->click('.create-child[rel*="--*--*?1!"]');
         $prefix = '--*';
     }
     CommonScenarios::waitAndClickInTypeahead($I, 'delta');
     $I->fillField('.generatedForm input.value[name*="' . $prefix . '--*?1!--*?1!--*?1!"]', 'test-name' . time());
     // add input subtree
     $I->click('.create-child[rel*="' . $prefix . '--*?1!--*?1!"]', '.generatedForm');
     CommonScenarios::waitAndClickInTypeahead($I, 'input');
     $I->waitForElement('.generatedForm input.value[name*="' . $prefix . '--*?1!--*?1!--*?2!--*?1!"]');
     $I->fillField('.generatedForm input.value[name*="' . $prefix . '--*?1!--*?1!--*?2!--*?1!"]', $state);
     $I->fillField('.generatedForm input.value[name*="' . $prefix . '--*?1!--*?1!--*?2!--*?2!"]', '1');
     // add output subtree
     $I->click('.create-child[rel*="' . $prefix . '--*?1!--*?1!"]', '.generatedForm');
     CommonScenarios::waitAndClickInTypeahead($I, 'output');
     $I->click('.create-child[rel*="' . $prefix . '--*?1!--*?1!--*?3!"]', '.generatedForm');
     CommonScenarios::waitAndClickInTypeahead($I, 'state');
     $I->waitForElement('.generatedForm input.value[name*="' . $prefix . '--*?1!--*?1!--*?3!--*?1!"]');
     $I->fillField('.generatedForm input.value[name*="' . $prefix . '--*?1!--*?1!--*?3!--*?1!"]', $state + 1);
     $I->click('.create-child[rel*="' . $prefix . '--*?1!--*?1!--*?3!"]', '.generatedForm');
     CommonScenarios::waitAndClickInTypeahead($I, 'symbol');
     $I->waitForElement('.generatedForm input.value[name*="' . $prefix . '--*?1!--*?1!--*?3!--*?2!"]');
     $I->fillField('.generatedForm input.value[name*="' . $prefix . '--*?1!--*?1!--*?3!--*?2!"]', '2');
     $I->click('.create-child[rel*="' . $prefix . '--*?1!--*?1!--*?3!"]', '.generatedForm');
     CommonScenarios::waitAndClickInTypeahead($I, 'head-move');
     $I->waitForElement('.generatedForm select[name*="' . $prefix . '--*?1!--*?1!--*?3!--*?3!"]');
     $I->selectOption('.generatedForm select[name*="' . $prefix . '--*?1!--*?1!--*?3!--*?3!"]', 'right');
 }
예제 #4
0
<?php

$I = new WebGuy($scenario);
include 'constant.php';
$I->wantTo('Register new user');
$I->amOnPage("/");
$I->see('Registration');
$I->see('Login');
$I->see('Genre');
$I->see('Stations');
$I->click(Registration::$registrationlink);
$I->waitForText('Sign Up');
$I->see('Sign Up');
$I->seeElement(Registration::$username);
$I->seeElement(Registration::$emailField);
$I->seeElement(Registration::$passwordField);
$I->seeElement(Registration::$confirmPasswordField);
$I->seeElement(Registration::$registrationButton);
$I->fillField(Registration::$username, $username);
$I->fillField(Registration::$emailField, $email);
$I->fillField(Registration::$passwordField, $pass);
$I->fillField(Registration::$confirmPasswordField, $pass_conf);
$I->click(Registration::$registrationButton);
예제 #5
0
<?php

$I = new WebGuy($scenario);
include 'constant.php';
$I->wantTo('Reset my password');
$I->amOnPage('/');
$I->click(LoginPopUp::$loginPopup);
$I->waitForText('Create account');
$I->click(ForgotPopUp::$passwordLink);
$I->waitForText('Forgot password');
$I->wait(1);
$I->waitForElement(ForgotPopUp::$emailField);
$I->seeElement(ForgotPopUp::$emailField);
$I->seeElement(ForgotPopUp::$resetButton);
$I->fillField(ForgotPopUp::$emailField, $email);
$I->click(ForgotPopUp::$resetButton);
$I->waitForText('Reset password link was sent on your e-mail address');
예제 #6
0
<?php

$I = new WebGuy($scenario);
include 'constant.php';
$I->wantTo('Login to muzza.life');
$I->amOnPage(LoginPopUp::$URL);
$I->click(LoginPopUp::$loginPopup);
$I->waitForText(LoginPopUp::$createAccountLink);
$I->see(LoginPopUp::$createAccountLink);
$I->see(LoginPopUp::$createAccountLink);
$I->seeElement(LoginPopUp::$emailField);
$I->seeElement(LoginPopUp::$passwordField);
$I->seeElement(LoginPopUp::$loginButton);
$I->fillField(LoginPopUp::$emailField, $email);
$I->fillField(LoginPopUp::$passwordField, $pass);
$I->click(LoginPopUp::$loginButton);
$I->waitForText($username);
$I->wait(3);
///
예제 #7
0
<?php

$I = new WebGuy($scenario);
include 'constant.php';
$I->wantTo('Check My mail Box');
$I->amOnUrl('http://temp-mail.ru/option/change');
$I->fillField('//*[@id="input_mail"]', $mail);
$I->click('//*[@id="postbut"]');
$I->wait(1);
$I->click('//*[@id="click-to-refresh"]');
$I->click('//*[@id="mails"]/tbody/tr/td[2]/a');
$I->waitForElement('//*[@id="templateBody"]/tbody/tr/td/table/tbody/tr[2]/td/table/tbody/tr/td/div/a');
$I->click('//*[@id="templateBody"]/tbody/tr/td/table/tbody/tr[2]/td/table/tbody/tr/td/div/a');
$I->waitForText('Create account');
$I->see('Create account');
$I->see('Forgot password?');
$I->seeElement('#email');
$I->seeElement('$password');
$I->seeElement('#loginButton');