mirror of
https://github.com/elyby/accounts.git
synced 2025-05-31 14:11:46 +05:30
Тестовое окружение отделено от основного, упрощены билды для контейнеров MariaDB и RabbitMQ, написаны скрипты для быстрого прогона тестов
This commit is contained in:
@@ -21,6 +21,4 @@ $_SERVER['SERVER_NAME'] = parse_url(\Codeception\Configuration::config()['confi
|
||||
$_SERVER['SERVER_PORT'] = parse_url(\Codeception\Configuration::config()['config']['test_entry_url'], PHP_URL_PORT) ?: '80';
|
||||
|
||||
Yii::setAlias('@tests', dirname(dirname(__DIR__)));
|
||||
|
||||
// disable deep cloning of properties inside specify block
|
||||
\Codeception\Specify\Config::setDeepClone(false);
|
||||
|
@@ -12,11 +12,11 @@ modules:
|
||||
Yii2:
|
||||
configFile: '../config/api/functional.php'
|
||||
Redis:
|
||||
host: redis
|
||||
host: testredis
|
||||
port: 6379
|
||||
database: 1
|
||||
database: 0
|
||||
AMQP:
|
||||
host: rabbitmq
|
||||
host: testrabbit
|
||||
port: 5672
|
||||
username: 'ely-accounts-tester'
|
||||
password: 'tester-password'
|
||||
|
@@ -1,7 +1,4 @@
|
||||
<?php
|
||||
/**
|
||||
* Application configuration shared by all applications and test types
|
||||
*/
|
||||
return [
|
||||
'language' => 'en-US',
|
||||
'controllerMap' => [
|
||||
@@ -14,7 +11,9 @@ return [
|
||||
],
|
||||
'components' => [
|
||||
'db' => [
|
||||
'dsn' => 'mysql:host=db;dbname=ely_accounts_test',
|
||||
'dsn' => 'mysql:host=testdb;dbname=ely_accounts_test',
|
||||
'username' => 'ely_accounts_tester',
|
||||
'password' => 'ely_accounts_tester_password',
|
||||
],
|
||||
'mailer' => [
|
||||
'useFileTransport' => true,
|
||||
@@ -23,9 +22,10 @@ return [
|
||||
'showScriptName' => true,
|
||||
],
|
||||
'redis' => [
|
||||
'database' => 1,
|
||||
'hostname' => 'testredis',
|
||||
],
|
||||
'amqp' => [
|
||||
'host' => 'testrabbit',
|
||||
'user' => 'ely-accounts-tester',
|
||||
'password' => 'tester-password',
|
||||
'vhost' => '/account.ely.by/tests',
|
||||
|
@@ -14,3 +14,4 @@ $_SERVER['SERVER_NAME'] = 'localhost';
|
||||
$_SERVER['SERVER_PORT'] = '80';
|
||||
|
||||
Yii::setAlias('@tests', dirname(dirname(__DIR__)));
|
||||
\Codeception\Specify\Config::setDeepClone(false);
|
||||
|
Reference in New Issue
Block a user