2019-01-26 02:42:01 -06:00
|
|
|
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
|
|
|
|
namespace ShlinkioTest\Shlink;
|
|
|
|
|
2019-01-26 03:19:20 -06:00
|
|
|
use GuzzleHttp\Client;
|
2019-01-26 03:59:24 -06:00
|
|
|
use Zend\ConfigAggregator\ConfigAggregator;
|
2019-01-26 02:42:01 -06:00
|
|
|
use Zend\ServiceManager\Factory\InvokableFactory;
|
|
|
|
use function realpath;
|
|
|
|
use function sys_get_temp_dir;
|
|
|
|
|
|
|
|
return [
|
|
|
|
|
2019-01-26 03:59:24 -06:00
|
|
|
'debug' => true,
|
|
|
|
ConfigAggregator::ENABLE_CACHE => false,
|
|
|
|
|
2019-01-26 02:42:01 -06:00
|
|
|
'zend-expressive-swoole' => [
|
|
|
|
'swoole-http-server' => [
|
|
|
|
'port' => 9999,
|
2019-01-26 03:19:20 -06:00
|
|
|
'host' => '127.0.0.1',
|
|
|
|
'process-name' => 'shlink_test',
|
2019-01-26 02:42:01 -06:00
|
|
|
],
|
|
|
|
],
|
|
|
|
|
|
|
|
'dependencies' => [
|
|
|
|
'factories' => [
|
|
|
|
Common\TestHelper::class => InvokableFactory::class,
|
2019-01-26 03:19:20 -06:00
|
|
|
'shlink_test_api_client' => function () {
|
|
|
|
return new Client(['base_uri' => 'http://localhost:9999/']);
|
|
|
|
},
|
2019-01-26 02:42:01 -06:00
|
|
|
],
|
|
|
|
],
|
|
|
|
|
|
|
|
'entity_manager' => [
|
|
|
|
'connection' => [
|
|
|
|
'driver' => 'pdo_sqlite',
|
|
|
|
'path' => realpath(sys_get_temp_dir()) . '/shlink-tests.db',
|
|
|
|
],
|
|
|
|
],
|
|
|
|
|
|
|
|
];
|