Контроллер Users переименован в Accounts

This commit is contained in:
ErickSkrauch
2016-02-26 01:45:21 +03:00
parent d9987a3185
commit 179d610eef
3 changed files with 6 additions and 6 deletions

View File

@ -0,0 +1,36 @@
<?php
namespace tests\codeception\api\functional;
use Codeception\Scenario;
use Codeception\Specify;
use tests\codeception\api\_pages\AccountsRoute;
use tests\codeception\api\functional\_steps\AccountSteps;
use tests\codeception\api\FunctionalTester;
class AccountsCurrentCest {
/**
* @var AccountsRoute
*/
private $route;
public function _before(FunctionalTester $I) {
$this->route = new AccountsRoute($I);
}
public function testCurrent(FunctionalTester $I, Scenario $scenario) {
$I = new AccountSteps($scenario);
$I->loggedInAsActiveAccount();
$this->route->current();
$I->canSeeResponseCodeIs(200);
$I->canSeeResponseIsJson();
$I->canSeeResponseContainsJson([
'id' => 1,
'username' => 'Admin',
'email' => 'admin@ely.by',
'shouldChangePassword' => false,
]);
}
}