mirror of
https://github.com/shlinkio/shlink.git
synced 2025-02-25 18:45:27 -06:00
Fixed openswoole E2E tests
This commit is contained in:
10
.github/workflows/ci.yml
vendored
10
.github/workflows/ci.yml
vendored
@@ -29,6 +29,11 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
test-group: unit
|
test-group: unit
|
||||||
|
|
||||||
|
cli-tests:
|
||||||
|
uses: './.github/workflows/ci-tests.yml'
|
||||||
|
with:
|
||||||
|
test-group: cli
|
||||||
|
|
||||||
openswoole-api-tests:
|
openswoole-api-tests:
|
||||||
uses: './.github/workflows/ci-tests.yml'
|
uses: './.github/workflows/ci-tests.yml'
|
||||||
with:
|
with:
|
||||||
@@ -50,11 +55,6 @@ jobs:
|
|||||||
- run: ./vendor/bin/rr get --no-interaction --location bin/ && chmod +x bin/rr
|
- run: ./vendor/bin/rr get --no-interaction --location bin/ && chmod +x bin/rr
|
||||||
- run: composer test:api:rr
|
- run: composer test:api:rr
|
||||||
|
|
||||||
cli-tests:
|
|
||||||
uses: './.github/workflows/ci-tests.yml'
|
|
||||||
with:
|
|
||||||
test-group: cli
|
|
||||||
|
|
||||||
sqlite-db-tests:
|
sqlite-db-tests:
|
||||||
uses: './.github/workflows/ci-db-tests.yml'
|
uses: './.github/workflows/ci-db-tests.yml'
|
||||||
with:
|
with:
|
||||||
|
|||||||
@@ -13,11 +13,12 @@ use Shlinkio\Shlink\Config\ConfigAggregator\EnvVarLoaderProvider;
|
|||||||
|
|
||||||
use function class_exists;
|
use function class_exists;
|
||||||
use function Shlinkio\Shlink\Config\env;
|
use function Shlinkio\Shlink\Config\env;
|
||||||
use function Shlinkio\Shlink\Config\runningInOpenswoole;
|
|
||||||
use function Shlinkio\Shlink\Config\runningInRoadRunner;
|
use function Shlinkio\Shlink\Config\runningInRoadRunner;
|
||||||
|
|
||||||
|
use const PHP_SAPI;
|
||||||
|
|
||||||
$isTestEnv = env('APP_ENV') === 'test';
|
$isTestEnv = env('APP_ENV') === 'test';
|
||||||
$enableSwoole = ! runningInRoadRunner() && runningInOpenswoole();
|
$enableSwoole = PHP_SAPI === 'cli' && ! runningInRoadRunner();
|
||||||
|
|
||||||
return (new ConfigAggregator\ConfigAggregator([
|
return (new ConfigAggregator\ConfigAggregator([
|
||||||
! $isTestEnv
|
! $isTestEnv
|
||||||
|
|||||||
Reference in New Issue
Block a user