当前位置: 首页>>代码示例>>PHP>>正文


PHP WebGuy::click方法代码示例

本文整理汇总了PHP中WebGuy::click方法的典型用法代码示例。如果您正苦于以下问题:PHP WebGuy::click方法的具体用法?PHP WebGuy::click怎么用?PHP WebGuy::click使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在WebGuy的用法示例。


在下文中一共展示了WebGuy::click方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: gebruikerKoppelenAanCursus

 /**
  * Test for requirement 130 of SLC
  * @param  WebGuy $I [description]
  */
 public function gebruikerKoppelenAanCursus(\WebGuy $I)
 {
     $I->amOnPage('/login');
     $I->see('Uren');
     $I->fillField('Username', 'slc');
     $I->fillField('Password', 'slc');
     $I->click('Login');
     $I->amOnPage('/slc/3');
     $I->amOnPage('/slc/3/course/students/1');
     $I->click('Voeg toe');
     $I->amOnPage('/slc/3/course/students/1');
     $I->see('student');
 }
开发者ID:jkaan,项目名称:Time-Registration,代码行数:17,代码来源:SLCCest.php

示例2: _createEmptyModule

 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');
 }
开发者ID:Barathi07,项目名称:Netopeer-GUI,代码行数:14,代码来源:DatastoreConfigureCest.php

示例3: _addInterface

 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');
 }
开发者ID:Barathi07,项目名称:Netopeer-GUI,代码行数:11,代码来源:InterfacesConfigureCest.php

示例4: _turingAddTransition

 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');
 }
开发者ID:Barathi07,项目名称:Netopeer-GUI,代码行数:38,代码来源:TuringConfigureCest.php

示例5: testEditConfig

 public function testEditConfig(WebGuy $I)
 {
     $I->wantTo('create new interface using submit button');
     $inputValue = 'test-name' . time();
     $I->click('.create-child[rel="--*--*?3!"]');
     CommonScenarios::waitAndClickInTypeahead($I, 'group');
     $I->waitForElement('input.value[name*="--*--*?3!--*?1!--*?1!"]');
     $I->fillField('input.value[name*="--*--*?3!--*?1!--*?1!"]', $inputValue);
     $I->click('Create new node');
     $I->waitForElementNotVisible('#ajax-spinner');
     $I->wait(2);
     //		$I->canSee($inputValue);
     CommonScenarios::checkNumberOfFlashes($I, 1);
     $I->canSee('group');
 }
开发者ID:Barathi07,项目名称:Netopeer-GUI,代码行数:15,代码来源:NacmConfigureCest.php

示例6: WebGuy

<?php

/**
 * DefaultController Test
 *
 * @var $scenario \Codeception\Scenario
 *
 * @author Brett O'Donnell <cornernote@gmail.com>
 * @author Zain Ul abidin <zainengineer@gmail.com>
 * @copyright 2013 Mr PHP
 * @link https://github.com/cornernote/yii-email-module
 * @license BSD-3-Clause https://raw.github.com/cornernote/yii-email-module/master/LICENSE
 *
 * @package yii-email-module
 */
$I = new WebGuy($scenario);
$I->wantTo('ensure DefaultController works');
$I->amOnPage('email');
$I->see('You may use the following tools');
$I->click('Spool');
$I->see('Spools');
$I->click('Template');
$I->see('Templates');
$I->click('Email');
$I->see('You may use the following tools');
开发者ID:Khan143,项目名称:yii-email-module,代码行数:25,代码来源:DefaultControllerCept.php

示例7: WebGuy

<?php

$I = new WebGuy($scenario);
/* Vendor login with wrong password fails */
$I->amOnPage('/signin');
$I->fillField('email', 'vendor1@example.com');
$I->fillField('password', 'wrongpassword');
$I->click('button.btn');
$I->see('Login incorrect', '.alert');
$I = new WebGuy($scenario);
/* Vendor login succeeds */
$I->fillField('email', 'vendor1@example.com');
$I->fillField('password', 'password');
$I->click('button.btn');
$I->see('Projects', 'h4');
/* Signout works */
$I->click('Sign Out');
$I->see('RFP-EZ Marketplace');
/* Officer login wrong password fails */
$I->amOnPage('/signin');
$I->fillField('email', 'officer1@example.gov');
$I->fillField('password', 'wrongpassword');
$I->click('button.btn');
$I->see('Login incorrect', '.alert');
/* Then officer login works */
$I->fillField('email', 'officer1@example.gov');
$I->fillField('password', 'password');
$I->click('button.btn');
$I->see('My Projects', 'h4');
开发者ID:ajb,项目名称:rfpez,代码行数:29,代码来源:LoginCept.php

示例8: array

$I->see('Hello guest');
// add user to the database
$I->haveInDatabase('account_user', array('username' => 'demo-activate', 'password' => '$2a$13$.m7wlozeIJuRtKp01lR4peYybArVLdO6Pf1JsPSnX6eISL9GXDWBu', 'first_name' => 'demo-activate', 'last_name' => 'demo-activate', 'email' => 'demo-activate@mailinator.com', 'activated' => 0));
// add a token to the database
$I->haveInDatabase('token', array('token' => '$2a$13$lRkdb6kwbIC9aGTkdei2h.NQNlZht9Bpdo2J0PqsJ3tHAFsYJNg7C', 'model_name' => 'AccountActivate', 'model_id' => 2, 'uses_allowed' => 1, 'uses_remaining' => 1, 'expires' => strtotime('+1day'), 'created' => time()));
// check with invalid token
$I->amOnPage('/account/account/activate/user_id/2/token/test-invalid-token');
$I->see('Invalid token.');
// reset password with empty details
$I->amOnPage('/account/account/activate/user_id/2/token/test-token');
$I->see('Your account has been activated and you have been logged in.');
// check login
$I->amOnPage('/');
$I->see('Hello demo-activate');
// logout
$I->amOnPage('/account/account/logout');
$I->see('Your have been logged out.');
// ensure token is expired
$I->amOnPage('/account/account/activate/user_id/2/token/test-token');
$I->see('Invalid token.');
// check login
$I->amOnPage('/account/account/login');
$I->fillField('AccountLogin_username', 'demo-activate');
$I->fillField('AccountLogin_password', 'demo-activate');
$I->click('Login');
$I->see('You have successfully logged in.');
$I->amOnPage('/');
$I->see('Hello demo-activate');
// logout
$I->amOnPage('/account/account/logout');
$I->see('Your have been logged out.');
开发者ID:cornernote,项目名称:yii-account-module,代码行数:31,代码来源:AccountAccountControllerActivateCept.php

示例9: WebGuy

<?php

$I = new WebGuy($scenario);
$I->wantTo('create and edit Pages as pagewriter user');
$I->loginAs($users['pagewriter']);
$I->see('New Page');
$I->click('New Page');
$I->see('Actions for this Page');
$I->fillField('title', 'A page I made');
$I->fillField('teaser', 'Woop woop woop! Crazy nice stuff inside!');
$I->fillField('body', 'Take it, take it! I have three more of these!');
$I->click('Save Page');
$I->see('A page I made');
$I->see('Woop woop woop');
开发者ID:ArdKuijpers,项目名称:bolt,代码行数:14,代码来源:010-pagesEditorCanEditPagesCept.php

示例10: WebGuy

 * @copyright 2013 Mr PHP
 * @link https://github.com/cornernote/yii-account-module
 * @license BSD-3-Clause https://raw.github.com/cornernote/yii-account-module/master/LICENSE
 *
 * @package yii-account-module
 */
$I = new WebGuy($scenario);
$I->wantTo('ensure AccountAccountController update works');
// check we are not logged in
$I->amOnPage('/');
$I->see('Hello guest');
// login
$I->amOnPage('/account/account/login');
$I->fillField('AccountLogin_username', 'admin');
$I->fillField('AccountLogin_password', 'admin');
$I->click('Login');
$I->see('You have successfully logged in.');
// update details with empty fields
$I->amOnPage('/account/account/update');
$I->fillField('AccountUpdate_first_name', '');
$I->fillField('AccountUpdate_last_name', '');
$I->fillField('AccountUpdate_email', '');
$I->fillField('AccountUpdate_username', '');
$I->click('Save');
$I->see('Please fix the following input errors:');
$I->see('Email cannot be blank.');
$I->see('Username cannot be blank.');
$I->see('First Name cannot be blank.');
// update details with invalid email
$I->amOnPage('/account/account/update');
$I->fillField('AccountUpdate_first_name', 'admin-first-name');
开发者ID:cornernote,项目名称:yii-account-module,代码行数:31,代码来源:AccountAccountControllerUpdateCept.php

示例11: array

<?php

$foobar = array('username' => 'foobar', 'password' => 'foobar123');
$I = new WebGuy($scenario);
$I->wantTo('Create a user');
$I->loginAs($users['admin']);
$I->click('Users');
$I->click('New user');
$I->see("Create a new user");
$I->fillField('form[username]', $foobar['username']);
$I->fillField('form[password]', $foobar['password']);
$I->fillField('form[password_confirmation]', $foobar['password']);
$I->fillField('form[email]', 'foobar@example.org');
$I->fillField('form[displayname]', 'Foo Bar');
$I->click('input[type=submit]');
$I->see("has been saved");
$I->click('Logout');
$I->loginAs($foobar);
$I->see('Dashboard');
开发者ID:ArdKuijpers,项目名称:bolt,代码行数:19,代码来源:510-createUserAsAdminCept.php

示例12: profielInzienStudent

 /**
  * Test for requirement 50 of student
  * @param  WebGuy $I [description]
  * @return [type]    [description]
  */
 public function profielInzienStudent(\WebGuy $I)
 {
     $I->amOnPage('/login');
     $I->see('Uren');
     $I->fillField('Username', 'student');
     $I->fillField('Password', 'student');
     $I->click('Login');
     $I->amOnPage('/student/1');
     $I->see('Student Page');
     $I->wantTo('Profiel Inzien');
     $I->click('Profiel');
     $I->amOnPage('/student/1/profiel');
     $I->see('student');
     $I->see('I12R');
 }
开发者ID:jkaan,项目名称:Time-Registration,代码行数:20,代码来源:StudentCest.php

示例13: WebGuy

<?php

$I = new WebGuy($scenario);
include 'loginCept.php';
$I->wantTo('Logout');
$I->click(LoginPopUp::$imgAvatar);
$I->click(LoginPopUp::$logoutButton);
开发者ID:unlimUA,项目名称:Codeception,代码行数:7,代码来源:logoutCept.php

示例14: WebGuy

<?php

$I = new WebGuy($scenario);
$I->wantTo('install component/module/plugin');
// Direct install URL call
$I->amOnPage('/administrator/index.php?option=com_installer');
// Login first
$I->fillField("#mod-login-username", 'TestAdmin');
$I->fillField("#mod-login-password", 'PassAdmin');
$I->click('Log in');
// Where i want to be
$I->see('Extension Manager: Install');
// Move "directory tab" into foreground
$I->seeLink('Install from Directory');
$I->click('Install from Directory');
// -> find input button (Can be found twice)
// <div id="directory"
//     <fieldset class="uploadform">
//         <div class="form-actions">
//             <input class="btn btn-primary" type="button" onclick="Joomla.submitbutton3()" value="Install">
$I->seeElement('#directory > fieldset > div > input');
$I->click('#directory > fieldset > div > input');
$I->see('was successful');
开发者ID:RSGallery2,项目名称:RoboLiTasks,代码行数:23,代码来源:InstallProjectWithTmpFolderCept.php

示例15: WebGuy

$I = new WebGuy($scenario);
$WP = new wordpress_controller($I);
$I->wantTo('Test the Authentication Plugin');
$WP->admin_login('admin', 'password');
$I->resizeWindow(1280, 1024);
$I->see('Dashboard');
$WP->enable_plugins($plugins);
$WP->logout();
foreach ($affiliates as $a) {
    $I->amGoingTo('Input settings for the base plugin');
    $WP->admin_login();
    $I->amOnPage($plugins['base']['admin_page']);
    // Fill out the form
    $I->fillField('agora_core_framework_config[prod_token]', $mw_settings[$a]['prod_token']);
    $I->fillField('agora_core_framework_config[uat_token]', $mw_settings[$a]['uat_token']);
    $I->click('Save');
    $I->amGoingTo('Configure some Authcodes');
    $I->amOnPage($plugins['auth']['admin_page']);
    $I->see('Add new Authentication Code');
    foreach ($pubcodes[$a] as $authcode) {
        $I->fillField('#add_new_authcode .authcode_name', $authcode['name']);
        $I->fillField('#add_new_authcode .authcode_advantage_code', $authcode['advantage_code']);
        $I->fillField('#add_new_authcode .authcode_description', $authcode['description']);
        $I->selectOption('#add_new_authcode .authcode_type', $authcode['auth_type']);
        $I->click('Add New', '#add_new_authcode');
        $I->waitForJS('return jQuery.active == 0', 5);
        $I->see($authcode['description']);
    }
    $I->amGoingTo('Insert some Test Content');
    foreach ($pubcodes[$a] as $authcode) {
        $I->amOnPage('/wp-admin/post-new.php');
开发者ID:gargallo,项目名称:tfs-test,代码行数:31,代码来源:AuthPluginCept.php


注:本文中的WebGuy::click方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。