Adjusted test configs structure
This commit is contained in:
parent
e7dcdf7c71
commit
229c352f78
@ -21,11 +21,11 @@ $I->see('The verification code is incorrect');
|
||||
|
||||
$I->amGoingTo('submit contact form with not correct email');
|
||||
$contactPage->submit([
|
||||
'name' => 'tester',
|
||||
'email' => 'tester.email',
|
||||
'subject' => 'test subject',
|
||||
'body' => 'test content',
|
||||
'verifyCode' => 'testme',
|
||||
'name' => 'tester',
|
||||
'email' => 'tester.email',
|
||||
'subject' => 'test subject',
|
||||
'body' => 'test content',
|
||||
'verifyCode' => 'testme',
|
||||
]);
|
||||
$I->expectTo('see that email adress is wrong');
|
||||
$I->dontSee('Name cannot be blank', '.help-inline');
|
||||
@ -36,11 +36,11 @@ $I->dontSee('The verification code is incorrect', '.help-inline');
|
||||
|
||||
$I->amGoingTo('submit contact form with correct data');
|
||||
$contactPage->submit([
|
||||
'name' => 'tester',
|
||||
'email' => 'tester@example.com',
|
||||
'subject' => 'test subject',
|
||||
'body' => 'test content',
|
||||
'verifyCode' => 'testme',
|
||||
'name' => 'tester',
|
||||
'email' => 'tester@example.com',
|
||||
'subject' => 'test subject',
|
||||
'body' => 'test content',
|
||||
'verifyCode' => 'testme',
|
||||
]);
|
||||
if (method_exists($I, 'wait')) {
|
||||
$I->wait(3); // only for selenium
|
||||
|
@ -1,3 +1,2 @@
|
||||
<?php
|
||||
|
||||
new yii\web\Application(require(__DIR__ . '/_config.php'));
|
||||
new yii\web\Application(require(dirname(__DIR__) . '/config/acceptance.php'));
|
||||
|
@ -1,7 +1,5 @@
|
||||
<?php
|
||||
|
||||
defined('YII_DEBUG') or define('YII_DEBUG', true);
|
||||
|
||||
defined('YII_ENV') or define('YII_ENV', 'test');
|
||||
|
||||
// fcgi doesn't have STDIN and STDOUT defined by default
|
@ -8,11 +8,11 @@
|
||||
* @license http://www.yiiframework.com/license/
|
||||
*/
|
||||
|
||||
require_once __DIR__ . '/_console_bootstrap.php';
|
||||
require_once __DIR__ . '/_bootstrap.php';
|
||||
|
||||
$config = yii\helpers\ArrayHelper::merge(
|
||||
require(ROOT_DIR . '/config/console.php'),
|
||||
require(__DIR__ . '/../_config.php'),
|
||||
require(__DIR__ . '/../config/config.php'),
|
||||
[
|
||||
'components' => [
|
||||
'db' => [
|
||||
|
@ -8,11 +8,11 @@
|
||||
* @license http://www.yiiframework.com/license/
|
||||
*/
|
||||
|
||||
require_once __DIR__ . '/_console_bootstrap.php';
|
||||
require_once __DIR__ . '/_bootstrap.php';
|
||||
|
||||
$config = yii\helpers\ArrayHelper::merge(
|
||||
require(ROOT_DIR . '/config/console.php'),
|
||||
require(__DIR__ . '/../_config.php'),
|
||||
require(__DIR__ . '/../config/config.php'),
|
||||
[
|
||||
'components' => [
|
||||
'db' => [
|
||||
|
@ -8,11 +8,11 @@
|
||||
* @license http://www.yiiframework.com/license/
|
||||
*/
|
||||
|
||||
require_once __DIR__ . '/_console_bootstrap.php';
|
||||
require_once __DIR__ . '/_bootstrap.php';
|
||||
|
||||
$config = yii\helpers\ArrayHelper::merge(
|
||||
require(ROOT_DIR . '/config/console.php'),
|
||||
require(__DIR__ . '/../_config.php'),
|
||||
require(__DIR__ . '/../config/config.php'),
|
||||
[
|
||||
'components' => [
|
||||
'db' => [
|
||||
|
@ -1,8 +1,10 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Application configuration for acceptance tests
|
||||
*/
|
||||
return yii\helpers\ArrayHelper::merge(
|
||||
require(__DIR__ . '/../../../config/web.php'),
|
||||
require(__DIR__ . '/../_config.php'),
|
||||
require(__DIR__ . '/config.php'),
|
||||
[
|
||||
'components' => [
|
||||
'db' => [
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/**
|
||||
* application configurations shared by all test types
|
||||
* Application configuration shared by all test types
|
||||
*/
|
||||
return [
|
||||
'components' => [
|
@ -2,9 +2,12 @@
|
||||
$_SERVER['SCRIPT_FILENAME'] = TEST_ENTRY_FILE;
|
||||
$_SERVER['SCRIPT_NAME'] = TEST_ENTRY_URL;
|
||||
|
||||
/**
|
||||
* Application configuration for functional tests
|
||||
*/
|
||||
return yii\helpers\ArrayHelper::merge(
|
||||
require(__DIR__ . '/../../../config/web.php'),
|
||||
require(__DIR__ . '/../_config.php'),
|
||||
require(__DIR__ . '/config.php'),
|
||||
[
|
||||
'components' => [
|
||||
'db' => [
|
@ -1,8 +1,10 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Application configuration for unit tests
|
||||
*/
|
||||
return yii\helpers\ArrayHelper::merge(
|
||||
require(__DIR__ . '/../../../config/web.php'),
|
||||
require(__DIR__ . '/../_config.php'),
|
||||
require(__DIR__ . '/config.php'),
|
||||
[
|
||||
'components' => [
|
||||
'db' => [
|
@ -13,4 +13,4 @@ modules:
|
||||
- Yii2
|
||||
config:
|
||||
Yii2:
|
||||
configFile: 'codeception/functional/_config.php'
|
||||
configFile: 'codeception/config/functional.php'
|
||||
|
@ -1,3 +1,2 @@
|
||||
<?php
|
||||
|
||||
new yii\web\Application(require(__DIR__ . '/_config.php'));
|
||||
new yii\web\Application(require(dirname(__DIR__) . '/config/functional.php'));
|
||||
|
@ -11,6 +11,6 @@ defined('YII_ENV') or define('YII_ENV', 'test');
|
||||
require(__DIR__ . '/../vendor/autoload.php');
|
||||
require(__DIR__ . '/../vendor/yiisoft/yii2/Yii.php');
|
||||
|
||||
$config = require(__DIR__ . '/../tests/codeception/acceptance/_config.php');
|
||||
$config = require(__DIR__ . '/../tests/codeception/config/acceptance.php');
|
||||
|
||||
(new yii\web\Application($config))->run();
|
||||
|
Loading…
Reference in New Issue
Block a user