Adjusted test configs structure
This commit is contained in:
parent
e7dcdf7c71
commit
229c352f78
@ -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