diff --git a/docker/tests/init.sh b/docker/tests/init.sh index 9e37faeb..6c1e6e3c 100755 --- a/docker/tests/init.sh +++ b/docker/tests/init.sh @@ -1,114 +1,113 @@ #!/bin/bash set -e set -x rsync -av \ --exclude=vendor \ --exclude=composer.lock \ --exclude=node_modules \ --exclude=package-lock.json \ --exclude=public \ --exclude=storage \ --exclude=resources/build \ - --exclude=bootstrap \ --exclude=.gitignore \ /src/kolabsrc.orig/ /opt/app-root/src/ | tee /tmp/rsync.output cd /opt/app-root/src/ if [ "$1" == "--refresh" ]; then /update.sh shift fi ./artisan route:list EXCLUDE_GROUPS=${EXCLUDE_GROUPS:-"skipci,ldap,coinbase,mollie,stripe,meet,dns,slow"} if [ "$1" == "browsertest" ]; then ./artisan octane:start --port=80 & echo "127.0.0.1 kolab.local admin.kolab.local reseller.kolab.local" >> /etc/hosts php \ -dmemory_limit=-1 \ vendor/bin/phpunit \ --exclude-group "$EXCLUDE_GROUPS" \ --verbose \ --testsuite Browser elif [ "$1" == "testsuite" ]; then php \ -dmemory_limit=-1 \ vendor/bin/phpunit \ --exclude-group "$EXCLUDE_GROUPS" \ --verbose \ --testsuite Unit php \ -dmemory_limit=-1 \ vendor/bin/phpunit \ --exclude-group "$EXCLUDE_GROUPS" \ --verbose \ --testsuite Functional php \ -dmemory_limit=-1 \ vendor/bin/phpunit \ --exclude-group "$EXCLUDE_GROUPS" \ --verbose \ --testsuite Feature elif [ "$1" == "quicktest" ]; then php \ -dmemory_limit=-1 \ vendor/bin/phpunit \ --exclude-group "$EXCLUDE_GROUPS" \ --verbose \ --stop-on-defect \ --stop-on-error \ --stop-on-failure \ --testsuite Unit php \ -dmemory_limit=-1 \ vendor/bin/phpunit \ --exclude-group "$EXCLUDE_GROUPS" \ --verbose \ --stop-on-defect \ --stop-on-error \ --stop-on-failure \ --testsuite Functional php \ -dmemory_limit=-1 \ vendor/bin/phpunit \ --exclude-group "$EXCLUDE_GROUPS" \ --verbose \ --stop-on-defect \ --stop-on-error \ --stop-on-failure \ --testsuite Feature elif [ "$1" == "shell" ]; then exec /bin/bash elif [ "$1" == "lint" ]; then php -dmemory_limit=-1 vendor/bin/phpcs -p php -dmemory_limit=-1 vendor/bin/phpstan analyse npm run lint else if [[ "$1" =~ "Browser" ]]; then echo "Assuming a browsertest and starting octane" ./artisan octane:start --port=80 & echo "127.0.0.1 kolab.local admin.kolab.local reseller.kolab.local" >> /etc/hosts fi php \ -dmemory_limit=-1 \ vendor/bin/phpunit \ --exclude-group "$EXCLUDE_GROUPS" \ --verbose \ --stop-on-defect \ --stop-on-error \ --stop-on-failure \ $@ fi diff --git a/src/bootstrap/app.php b/src/bootstrap/app.php index def6d60c..a70ba683 100644 --- a/src/bootstrap/app.php +++ b/src/bootstrap/app.php @@ -1,78 +1,83 @@ singleton( Illuminate\Contracts\Http\Kernel::class, App\Http\Kernel::class ); $app->singleton( Illuminate\Contracts\Console\Kernel::class, App\Console\Kernel::class ); $app->singleton( Illuminate\Contracts\Debug\ExceptionHandler::class, App\Exceptions\Handler::class ); /* |-------------------------------------------------------------------------- | Return The Application |-------------------------------------------------------------------------- | | This script returns the application instance. The instance is given to | the calling script so we can separate the building of the instances | from the actual running of the application and sending responses. | */ return $app;