Created
September 13, 2013 06:21
-
-
Save yupe/6547244 to your computer and use it in GitHub Desktop.
А вот так тесты писать приятнее +) Codeception рулит =)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
use \WebGuy; | |
class UserLoginCest | |
{ | |
public function testLoginPage(WebGuy $I) { | |
$I->amOnPage('/user/account/login'); | |
$I->seeInTitle('Войти'); | |
$I->seeLink('Забыли пароль?'); | |
$I->see('Войти'); | |
$I->seeLink('Регистрация'); | |
$I->seeInField('LoginForm[email]',''); | |
$I->seeInField('LoginForm[password]',''); | |
} | |
public function testAuthWrongFormat(WebGuy $I) { | |
$I->amOnPage('/user/account/login'); | |
$I->fillField('LoginForm[email]','test'); | |
$I->fillField('LoginForm[password]','test'); | |
$I->click('Войти'); | |
$I->see('Email не является правильным E-Mail адресом','.alert-error'); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment