diff --git a/.gitignore b/.gitignore index 58250120..11f82a76 100644 --- a/.gitignore +++ b/.gitignore @@ -1,6 +1,9 @@ /vendor *.DS_Store* -.env +!.env.ci +!.env.dusk +!.env.example +.env* .vagrant/* .vscode/* storage/framework/* diff --git a/composer.json b/composer.json index bafe1dec..75d21cf2 100644 --- a/composer.json +++ b/composer.json @@ -11,7 +11,7 @@ } ], "require": { - "php": "^7.3 | ^8.0", + "php": "^7.3|^8.0", "ext-json": "*", "ext-mbstring": "*", "ext-pdo_mysql": "*", @@ -20,7 +20,6 @@ "aws/aws-sdk-php": "^3.171", "cakephp/chronos": "^1.3", "doctrine/dbal": "^2.12", - "facade/ignition": "^2.5", "fideloper/proxy": "^4.4", "guzzlehttp/guzzle": "^7.2", "hashids/hashids": "^4.1", @@ -33,7 +32,6 @@ "league/flysystem-aws-s3-v3": "^1.0", "league/flysystem-memory": "^1.0", "matriphe/iso-639": "^1.2", - "nunomaduro/collision": "^5.2", "pragmarx/google2fa": "^5.0", "predis/predis": "^1.1", "prologue/alerts": "^0.4", @@ -49,10 +47,12 @@ "barryvdh/laravel-debugbar": "^3.5", "barryvdh/laravel-ide-helper": "^2.9", "codedungeon/phpunit-result-printer": "^0.28", + "facade/ignition": "^2.5", + "fakerphp/faker": "^1.13", "friendsofphp/php-cs-fixer": "^2.17", - "fzaninotto/faker": "^1.9", "laravel/dusk": "^6.11", "mockery/mockery": "^1.4", + "nunomaduro/collision": "^5.2", "php-mock/php-mock-phpunit": "^2.6", "phpunit/phpunit": "^9.0" }, diff --git a/composer.lock b/composer.lock index e9b759ba..94be46bc 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "b545063ba708121d151a0d80e0259955", + "content-hash": "f12494defb79b412566ee0f5104e3986", "packages": [ { "name": "appstract/laravel-blade-directives", @@ -917,201 +917,6 @@ ], "time": "2020-12-29T14:50:06+00:00" }, - { - "name": "facade/flare-client-php", - "version": "1.3.7", - "source": { - "type": "git", - "url": "https://github.com/facade/flare-client-php.git", - "reference": "fd688d3c06658f2b3b5f7bb19f051ee4ddf02492" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/facade/flare-client-php/zipball/fd688d3c06658f2b3b5f7bb19f051ee4ddf02492", - "reference": "fd688d3c06658f2b3b5f7bb19f051ee4ddf02492", - "shasum": "" - }, - "require": { - "facade/ignition-contracts": "~1.0", - "illuminate/pipeline": "^5.5|^6.0|^7.0|^8.0", - "php": "^7.1|^8.0", - "symfony/http-foundation": "^3.3|^4.1|^5.0", - "symfony/mime": "^3.4|^4.0|^5.1", - "symfony/var-dumper": "^3.4|^4.0|^5.0" - }, - "require-dev": { - "friendsofphp/php-cs-fixer": "^2.14", - "phpunit/phpunit": "^7.5.16", - "spatie/phpunit-snapshot-assertions": "^2.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0-dev" - } - }, - "autoload": { - "psr-4": { - "Facade\\FlareClient\\": "src" - }, - "files": [ - "src/helpers.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "description": "Send PHP errors to Flare", - "homepage": "https://github.com/facade/flare-client-php", - "keywords": [ - "exception", - "facade", - "flare", - "reporting" - ], - "support": { - "issues": "https://github.com/facade/flare-client-php/issues", - "source": "https://github.com/facade/flare-client-php/tree/1.3.7" - }, - "funding": [ - { - "url": "https://github.com/spatie", - "type": "github" - } - ], - "time": "2020-10-21T16:02:39+00:00" - }, - { - "name": "facade/ignition", - "version": "2.5.8", - "source": { - "type": "git", - "url": "https://github.com/facade/ignition.git", - "reference": "8e907d81244649c5ea746e2ec30c32c5f59df472" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/facade/ignition/zipball/8e907d81244649c5ea746e2ec30c32c5f59df472", - "reference": "8e907d81244649c5ea746e2ec30c32c5f59df472", - "shasum": "" - }, - "require": { - "ext-json": "*", - "ext-mbstring": "*", - "facade/flare-client-php": "^1.3.7", - "facade/ignition-contracts": "^1.0.2", - "filp/whoops": "^2.4", - "illuminate/support": "^7.0|^8.0", - "monolog/monolog": "^2.0", - "php": "^7.2.5|^8.0", - "symfony/console": "^5.0", - "symfony/var-dumper": "^5.0" - }, - "require-dev": { - "friendsofphp/php-cs-fixer": "^2.14", - "mockery/mockery": "^1.3", - "orchestra/testbench": "^5.0|^6.0", - "psalm/plugin-laravel": "^1.2" - }, - "suggest": { - "laravel/telescope": "^3.1" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.x-dev" - }, - "laravel": { - "providers": [ - "Facade\\Ignition\\IgnitionServiceProvider" - ], - "aliases": { - "Flare": "Facade\\Ignition\\Facades\\Flare" - } - } - }, - "autoload": { - "psr-4": { - "Facade\\Ignition\\": "src" - }, - "files": [ - "src/helpers.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "description": "A beautiful error page for Laravel applications.", - "homepage": "https://github.com/facade/ignition", - "keywords": [ - "error", - "flare", - "laravel", - "page" - ], - "support": { - "docs": "https://flareapp.io/docs/ignition-for-laravel/introduction", - "forum": "https://twitter.com/flareappio", - "issues": "https://github.com/facade/ignition/issues", - "source": "https://github.com/facade/ignition" - }, - "time": "2020-12-29T09:12:55+00:00" - }, - { - "name": "facade/ignition-contracts", - "version": "1.0.2", - "source": { - "type": "git", - "url": "https://github.com/facade/ignition-contracts.git", - "reference": "3c921a1cdba35b68a7f0ccffc6dffc1995b18267" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/facade/ignition-contracts/zipball/3c921a1cdba35b68a7f0ccffc6dffc1995b18267", - "reference": "3c921a1cdba35b68a7f0ccffc6dffc1995b18267", - "shasum": "" - }, - "require": { - "php": "^7.3|^8.0" - }, - "require-dev": { - "friendsofphp/php-cs-fixer": "^v2.15.8", - "phpunit/phpunit": "^9.3.11", - "vimeo/psalm": "^3.17.1" - }, - "type": "library", - "autoload": { - "psr-4": { - "Facade\\IgnitionContracts\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Freek Van der Herten", - "email": "freek@spatie.be", - "homepage": "https://flareapp.io", - "role": "Developer" - } - ], - "description": "Solution contracts for Ignition", - "homepage": "https://github.com/facade/ignition-contracts", - "keywords": [ - "contracts", - "flare", - "ignition" - ], - "support": { - "issues": "https://github.com/facade/ignition-contracts/issues", - "source": "https://github.com/facade/ignition-contracts/tree/1.0.2" - }, - "time": "2020-10-16T08:27:54+00:00" - }, { "name": "fideloper/proxy", "version": "4.4.1", @@ -1170,71 +975,6 @@ }, "time": "2020-10-22T13:48:01+00:00" }, - { - "name": "filp/whoops", - "version": "2.9.1", - "source": { - "type": "git", - "url": "https://github.com/filp/whoops.git", - "reference": "307fb34a5ab697461ec4c9db865b20ff2fd40771" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/filp/whoops/zipball/307fb34a5ab697461ec4c9db865b20ff2fd40771", - "reference": "307fb34a5ab697461ec4c9db865b20ff2fd40771", - "shasum": "" - }, - "require": { - "php": "^5.5.9 || ^7.0 || ^8.0", - "psr/log": "^1.0.1" - }, - "require-dev": { - "mockery/mockery": "^0.9 || ^1.0", - "phpunit/phpunit": "^4.8.36 || ^5.7.27 || ^6.5.14 || ^7.5.20 || ^8.5.8 || ^9.3.3", - "symfony/var-dumper": "^2.6 || ^3.0 || ^4.0 || ^5.0" - }, - "suggest": { - "symfony/var-dumper": "Pretty print complex values better with var-dumper available", - "whoops/soap": "Formats errors as SOAP responses" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.7-dev" - } - }, - "autoload": { - "psr-4": { - "Whoops\\": "src/Whoops/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Filipe Dobreira", - "homepage": "https://github.com/filp", - "role": "Developer" - } - ], - "description": "php error handling for cool kids", - "homepage": "https://filp.github.io/whoops/", - "keywords": [ - "error", - "exception", - "handling", - "library", - "throwable", - "whoops" - ], - "support": { - "issues": "https://github.com/filp/whoops/issues", - "source": "https://github.com/filp/whoops/tree/2.9.1" - }, - "time": "2020-11-01T12:00:00+00:00" - }, { "name": "graham-campbell/result-type", "version": "v1.0.1", @@ -2869,94 +2609,6 @@ }, "time": "2020-12-20T10:01:03+00:00" }, - { - "name": "nunomaduro/collision", - "version": "v5.2.0", - "source": { - "type": "git", - "url": "https://github.com/nunomaduro/collision.git", - "reference": "aca954fd03414ba0dd85d7d8e42ba9b251893d1f" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/nunomaduro/collision/zipball/aca954fd03414ba0dd85d7d8e42ba9b251893d1f", - "reference": "aca954fd03414ba0dd85d7d8e42ba9b251893d1f", - "shasum": "" - }, - "require": { - "facade/ignition-contracts": "^1.0", - "filp/whoops": "^2.7.2", - "php": "^7.3 || ^8.0", - "symfony/console": "^5.0" - }, - "require-dev": { - "brianium/paratest": "^6.1", - "fideloper/proxy": "^4.4.1", - "friendsofphp/php-cs-fixer": "^2.17.3", - "fruitcake/laravel-cors": "^2.0.3", - "laravel/framework": "^9.0", - "nunomaduro/larastan": "^0.6.2", - "nunomaduro/mock-final-classes": "^1.0", - "orchestra/testbench": "^7.0", - "phpstan/phpstan": "^0.12.64", - "phpunit/phpunit": "^9.5.0" - }, - "type": "library", - "extra": { - "laravel": { - "providers": [ - "NunoMaduro\\Collision\\Adapters\\Laravel\\CollisionServiceProvider" - ] - } - }, - "autoload": { - "psr-4": { - "NunoMaduro\\Collision\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nuno Maduro", - "email": "enunomaduro@gmail.com" - } - ], - "description": "Cli error handling for console/command-line PHP applications.", - "keywords": [ - "artisan", - "cli", - "command-line", - "console", - "error", - "handling", - "laravel", - "laravel-zero", - "php", - "symfony" - ], - "support": { - "issues": "https://github.com/nunomaduro/collision/issues", - "source": "https://github.com/nunomaduro/collision" - }, - "funding": [ - { - "url": "https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=66BYDWAT92N6L", - "type": "custom" - }, - { - "url": "https://github.com/nunomaduro", - "type": "github" - }, - { - "url": "https://www.patreon.com/nunomaduro", - "type": "patreon" - } - ], - "time": "2021-01-13T10:00:08+00:00" - }, { "name": "opis/closure", "version": "3.6.1", @@ -7884,6 +7536,318 @@ ], "time": "2020-11-10T18:47:58+00:00" }, + { + "name": "facade/flare-client-php", + "version": "1.3.7", + "source": { + "type": "git", + "url": "https://github.com/facade/flare-client-php.git", + "reference": "fd688d3c06658f2b3b5f7bb19f051ee4ddf02492" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/facade/flare-client-php/zipball/fd688d3c06658f2b3b5f7bb19f051ee4ddf02492", + "reference": "fd688d3c06658f2b3b5f7bb19f051ee4ddf02492", + "shasum": "" + }, + "require": { + "facade/ignition-contracts": "~1.0", + "illuminate/pipeline": "^5.5|^6.0|^7.0|^8.0", + "php": "^7.1|^8.0", + "symfony/http-foundation": "^3.3|^4.1|^5.0", + "symfony/mime": "^3.4|^4.0|^5.1", + "symfony/var-dumper": "^3.4|^4.0|^5.0" + }, + "require-dev": { + "friendsofphp/php-cs-fixer": "^2.14", + "phpunit/phpunit": "^7.5.16", + "spatie/phpunit-snapshot-assertions": "^2.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "autoload": { + "psr-4": { + "Facade\\FlareClient\\": "src" + }, + "files": [ + "src/helpers.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "Send PHP errors to Flare", + "homepage": "https://github.com/facade/flare-client-php", + "keywords": [ + "exception", + "facade", + "flare", + "reporting" + ], + "support": { + "issues": "https://github.com/facade/flare-client-php/issues", + "source": "https://github.com/facade/flare-client-php/tree/1.3.7" + }, + "funding": [ + { + "url": "https://github.com/spatie", + "type": "github" + } + ], + "time": "2020-10-21T16:02:39+00:00" + }, + { + "name": "facade/ignition", + "version": "2.5.8", + "source": { + "type": "git", + "url": "https://github.com/facade/ignition.git", + "reference": "8e907d81244649c5ea746e2ec30c32c5f59df472" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/facade/ignition/zipball/8e907d81244649c5ea746e2ec30c32c5f59df472", + "reference": "8e907d81244649c5ea746e2ec30c32c5f59df472", + "shasum": "" + }, + "require": { + "ext-json": "*", + "ext-mbstring": "*", + "facade/flare-client-php": "^1.3.7", + "facade/ignition-contracts": "^1.0.2", + "filp/whoops": "^2.4", + "illuminate/support": "^7.0|^8.0", + "monolog/monolog": "^2.0", + "php": "^7.2.5|^8.0", + "symfony/console": "^5.0", + "symfony/var-dumper": "^5.0" + }, + "require-dev": { + "friendsofphp/php-cs-fixer": "^2.14", + "mockery/mockery": "^1.3", + "orchestra/testbench": "^5.0|^6.0", + "psalm/plugin-laravel": "^1.2" + }, + "suggest": { + "laravel/telescope": "^3.1" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.x-dev" + }, + "laravel": { + "providers": [ + "Facade\\Ignition\\IgnitionServiceProvider" + ], + "aliases": { + "Flare": "Facade\\Ignition\\Facades\\Flare" + } + } + }, + "autoload": { + "psr-4": { + "Facade\\Ignition\\": "src" + }, + "files": [ + "src/helpers.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "A beautiful error page for Laravel applications.", + "homepage": "https://github.com/facade/ignition", + "keywords": [ + "error", + "flare", + "laravel", + "page" + ], + "support": { + "docs": "https://flareapp.io/docs/ignition-for-laravel/introduction", + "forum": "https://twitter.com/flareappio", + "issues": "https://github.com/facade/ignition/issues", + "source": "https://github.com/facade/ignition" + }, + "time": "2020-12-29T09:12:55+00:00" + }, + { + "name": "facade/ignition-contracts", + "version": "1.0.2", + "source": { + "type": "git", + "url": "https://github.com/facade/ignition-contracts.git", + "reference": "3c921a1cdba35b68a7f0ccffc6dffc1995b18267" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/facade/ignition-contracts/zipball/3c921a1cdba35b68a7f0ccffc6dffc1995b18267", + "reference": "3c921a1cdba35b68a7f0ccffc6dffc1995b18267", + "shasum": "" + }, + "require": { + "php": "^7.3|^8.0" + }, + "require-dev": { + "friendsofphp/php-cs-fixer": "^v2.15.8", + "phpunit/phpunit": "^9.3.11", + "vimeo/psalm": "^3.17.1" + }, + "type": "library", + "autoload": { + "psr-4": { + "Facade\\IgnitionContracts\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Freek Van der Herten", + "email": "freek@spatie.be", + "homepage": "https://flareapp.io", + "role": "Developer" + } + ], + "description": "Solution contracts for Ignition", + "homepage": "https://github.com/facade/ignition-contracts", + "keywords": [ + "contracts", + "flare", + "ignition" + ], + "support": { + "issues": "https://github.com/facade/ignition-contracts/issues", + "source": "https://github.com/facade/ignition-contracts/tree/1.0.2" + }, + "time": "2020-10-16T08:27:54+00:00" + }, + { + "name": "fakerphp/faker", + "version": "v1.13.0", + "source": { + "type": "git", + "url": "https://github.com/FakerPHP/Faker.git", + "reference": "ab3f5364d01f2c2c16113442fb987d26e4004913" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/FakerPHP/Faker/zipball/ab3f5364d01f2c2c16113442fb987d26e4004913", + "reference": "ab3f5364d01f2c2c16113442fb987d26e4004913", + "shasum": "" + }, + "require": { + "php": "^7.1 || ^8.0" + }, + "conflict": { + "fzaninotto/faker": "*" + }, + "require-dev": { + "bamarni/composer-bin-plugin": "^1.4.1", + "ext-intl": "*", + "phpunit/phpunit": "^7.5.20 || ^8.5.8 || ^9.4.2" + }, + "type": "library", + "autoload": { + "psr-4": { + "Faker\\": "src/Faker/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "François Zaninotto" + } + ], + "description": "Faker is a PHP library that generates fake data for you.", + "keywords": [ + "data", + "faker", + "fixtures" + ], + "support": { + "issues": "https://github.com/FakerPHP/Faker/issues", + "source": "https://github.com/FakerPHP/Faker/tree/v1.13.0" + }, + "time": "2020-12-18T16:50:48+00:00" + }, + { + "name": "filp/whoops", + "version": "2.9.1", + "source": { + "type": "git", + "url": "https://github.com/filp/whoops.git", + "reference": "307fb34a5ab697461ec4c9db865b20ff2fd40771" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/filp/whoops/zipball/307fb34a5ab697461ec4c9db865b20ff2fd40771", + "reference": "307fb34a5ab697461ec4c9db865b20ff2fd40771", + "shasum": "" + }, + "require": { + "php": "^5.5.9 || ^7.0 || ^8.0", + "psr/log": "^1.0.1" + }, + "require-dev": { + "mockery/mockery": "^0.9 || ^1.0", + "phpunit/phpunit": "^4.8.36 || ^5.7.27 || ^6.5.14 || ^7.5.20 || ^8.5.8 || ^9.3.3", + "symfony/var-dumper": "^2.6 || ^3.0 || ^4.0 || ^5.0" + }, + "suggest": { + "symfony/var-dumper": "Pretty print complex values better with var-dumper available", + "whoops/soap": "Formats errors as SOAP responses" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.7-dev" + } + }, + "autoload": { + "psr-4": { + "Whoops\\": "src/Whoops/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Filipe Dobreira", + "homepage": "https://github.com/filp", + "role": "Developer" + } + ], + "description": "php error handling for cool kids", + "homepage": "https://filp.github.io/whoops/", + "keywords": [ + "error", + "exception", + "handling", + "library", + "throwable", + "whoops" + ], + "support": { + "issues": "https://github.com/filp/whoops/issues", + "source": "https://github.com/filp/whoops/tree/2.9.1" + }, + "time": "2020-11-01T12:00:00+00:00" + }, { "name": "friendsofphp/php-cs-fixer", "version": "v2.17.3", @@ -7988,61 +7952,6 @@ ], "time": "2020-12-24T11:14:44+00:00" }, - { - "name": "fzaninotto/faker", - "version": "v1.9.2", - "source": { - "type": "git", - "url": "https://github.com/fzaninotto/Faker.git", - "reference": "848d8125239d7dbf8ab25cb7f054f1a630e68c2e" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/fzaninotto/Faker/zipball/848d8125239d7dbf8ab25cb7f054f1a630e68c2e", - "reference": "848d8125239d7dbf8ab25cb7f054f1a630e68c2e", - "shasum": "" - }, - "require": { - "php": "^5.3.3 || ^7.0" - }, - "require-dev": { - "ext-intl": "*", - "phpunit/phpunit": "^4.8.35 || ^5.7", - "squizlabs/php_codesniffer": "^2.9.2" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.9-dev" - } - }, - "autoload": { - "psr-4": { - "Faker\\": "src/Faker/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "François Zaninotto" - } - ], - "description": "Faker is a PHP library that generates fake data for you.", - "keywords": [ - "data", - "faker", - "fixtures" - ], - "support": { - "issues": "https://github.com/fzaninotto/Faker/issues", - "source": "https://github.com/fzaninotto/Faker/tree/v1.9.2" - }, - "abandoned": true, - "time": "2020-12-11T09:56:16+00:00" - }, { "name": "hamcrest/hamcrest-php", "version": "v2.0.1", @@ -8492,6 +8401,94 @@ ], "time": "2020-11-13T09:40:50+00:00" }, + { + "name": "nunomaduro/collision", + "version": "v5.2.0", + "source": { + "type": "git", + "url": "https://github.com/nunomaduro/collision.git", + "reference": "aca954fd03414ba0dd85d7d8e42ba9b251893d1f" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/nunomaduro/collision/zipball/aca954fd03414ba0dd85d7d8e42ba9b251893d1f", + "reference": "aca954fd03414ba0dd85d7d8e42ba9b251893d1f", + "shasum": "" + }, + "require": { + "facade/ignition-contracts": "^1.0", + "filp/whoops": "^2.7.2", + "php": "^7.3 || ^8.0", + "symfony/console": "^5.0" + }, + "require-dev": { + "brianium/paratest": "^6.1", + "fideloper/proxy": "^4.4.1", + "friendsofphp/php-cs-fixer": "^2.17.3", + "fruitcake/laravel-cors": "^2.0.3", + "laravel/framework": "^9.0", + "nunomaduro/larastan": "^0.6.2", + "nunomaduro/mock-final-classes": "^1.0", + "orchestra/testbench": "^7.0", + "phpstan/phpstan": "^0.12.64", + "phpunit/phpunit": "^9.5.0" + }, + "type": "library", + "extra": { + "laravel": { + "providers": [ + "NunoMaduro\\Collision\\Adapters\\Laravel\\CollisionServiceProvider" + ] + } + }, + "autoload": { + "psr-4": { + "NunoMaduro\\Collision\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nuno Maduro", + "email": "enunomaduro@gmail.com" + } + ], + "description": "Cli error handling for console/command-line PHP applications.", + "keywords": [ + "artisan", + "cli", + "command-line", + "console", + "error", + "handling", + "laravel", + "laravel-zero", + "php", + "symfony" + ], + "support": { + "issues": "https://github.com/nunomaduro/collision/issues", + "source": "https://github.com/nunomaduro/collision" + }, + "funding": [ + { + "url": "https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=66BYDWAT92N6L", + "type": "custom" + }, + { + "url": "https://github.com/nunomaduro", + "type": "github" + }, + { + "url": "https://www.patreon.com/nunomaduro", + "type": "patreon" + } + ], + "time": "2021-01-13T10:00:08+00:00" + }, { "name": "phar-io/manifest", "version": "2.0.1", @@ -11077,7 +11074,7 @@ "prefer-stable": true, "prefer-lowest": false, "platform": { - "php": "^7.3 | ^8.0", + "php": "^7.3|^8.0", "ext-json": "*", "ext-mbstring": "*", "ext-pdo_mysql": "*", diff --git a/database/factories/ServerFactory.php b/database/factories/ServerFactory.php index 20f49aad..b87c5741 100644 --- a/database/factories/ServerFactory.php +++ b/database/factories/ServerFactory.php @@ -3,6 +3,7 @@ namespace Database\Factories; use Carbon\Carbon; +use Ramsey\Uuid\Uuid; use Illuminate\Support\Str; use Pterodactyl\Models\Server; use Illuminate\Database\Eloquent\Factories\Factory; @@ -24,7 +25,7 @@ class ServerFactory extends Factory public function definition() { return [ - 'uuid' => $this->faker->unique()->uuid, + 'uuid' => Uuid::uuid4()->toString(), 'uuidShort' => Str::random(8), 'name' => $this->faker->firstName, 'description' => implode(' ', $this->faker->sentences()), diff --git a/database/factories/UserFactory.php b/database/factories/UserFactory.php index 23a9c5ca..34c48941 100644 --- a/database/factories/UserFactory.php +++ b/database/factories/UserFactory.php @@ -3,6 +3,7 @@ namespace Database\Factories; use Carbon\Carbon; +use Ramsey\Uuid\Uuid; use Pterodactyl\Models\User; use Illuminate\Database\Eloquent\Factories\Factory; @@ -26,7 +27,7 @@ class UserFactory extends Factory return [ 'external_id' => $this->faker->unique()->isbn10, - 'uuid' => $this->faker->unique()->uuid, + 'uuid' => Uuid::uuid4()->toString(), 'username' => $this->faker->userName, 'email' => $this->faker->safeEmail, 'name_first' => $this->faker->firstName, diff --git a/tests/Integration/Api/Client/Server/WebsocketControllerTest.php b/tests/Integration/Api/Client/Server/WebsocketControllerTest.php index e39f3ba0..a792c09f 100644 --- a/tests/Integration/Api/Client/Server/WebsocketControllerTest.php +++ b/tests/Integration/Api/Client/Server/WebsocketControllerTest.php @@ -5,6 +5,7 @@ namespace Pterodactyl\Tests\Integration\Api\Client\Server; use Carbon\Carbon; use Lcobucci\JWT\Parser; use Carbon\CarbonImmutable; +use Lcobucci\JWT\Signer\Key; use Illuminate\Http\Response; use Pterodactyl\Models\Permission; use Lcobucci\JWT\Signer\Hmac\Sha256; @@ -54,7 +55,7 @@ class WebsocketControllerTest extends ClientApiIntegrationTestCase $token = (new Parser)->parse($response->json('data.token')); $this->assertTrue( - $token->verify(new Sha256, $server->node->getDecryptedKey()), + $token->verify(new Sha256, new Key($server->node->getDecryptedKey())), 'Failed to validate that the JWT data returned was signed using the Node\'s secret key.' ); @@ -88,7 +89,7 @@ class WebsocketControllerTest extends ClientApiIntegrationTestCase $token = (new Parser)->parse($response->json('data.token')); $this->assertTrue( - $token->verify(new Sha256, $server->node->getDecryptedKey()), + $token->verify(new Sha256, new Key($server->node->getDecryptedKey())), 'Failed to validate that the JWT data returned was signed using the Node\'s secret key.' ); diff --git a/tests/Integration/Services/Databases/DatabaseManagementServiceTest.php b/tests/Integration/Services/Databases/DatabaseManagementServiceTest.php index 4b12ac67..7a862c65 100644 --- a/tests/Integration/Services/Databases/DatabaseManagementServiceTest.php +++ b/tests/Integration/Services/Databases/DatabaseManagementServiceTest.php @@ -167,7 +167,7 @@ class DatabaseManagementServiceTest extends IntegrationTestCase $this->assertInstanceOf(Database::class, $response); $this->assertSame($response->server_id, $server->id); - $this->assertRegExp('/^(u[\d]+_)(\w){10}$/', $username); + $this->assertMatchesRegularExpression('/^(u[\d]+_)(\w){10}$/', $username); $this->assertSame($username, $secondUsername); $this->assertSame(24, strlen($password)); diff --git a/tests/Integration/Services/Servers/ServerCreationServiceTest.php b/tests/Integration/Services/Servers/ServerCreationServiceTest.php index abe26e7b..b03f8803 100644 --- a/tests/Integration/Services/Servers/ServerCreationServiceTest.php +++ b/tests/Integration/Services/Servers/ServerCreationServiceTest.php @@ -158,9 +158,12 @@ class ServerCreationServiceTest extends IntegrationTestCase /** @var \Pterodactyl\Models\User $user */ $user = User::factory()->create(); + /** @var \Pterodactyl\Models\Location $location */ + $location = Location::factory()->create(); + /** @var \Pterodactyl\Models\Node $node */ $node = Node::factory()->create([ - 'location_id' => Location::factory()->create()->id, + 'location_id' => $location->id, ]); /** @var \Pterodactyl\Models\Allocation $allocation */