From 3ad6ed8bfa823e4dcf82945e7092797d9858081f Mon Sep 17 00:00:00 2001 From: Chris Mancuso Date: Sun, 30 May 2021 08:20:41 +0000 Subject: [PATCH] upgrade to laravel 8.x --- .env | 2 +- app/Providers/AppServiceProvider.php | 2 + composer.json | 16 +- composer.lock | 1679 +- ..._145620_create_schedule_monitor_tables.php | 50 + ..._155240_create_schedule_monitor_tables.php | 50 + ..._160844_create_schedule_monitor_tables.php | 50 + ..._001202_create_schedule_monitor_tables.php | 50 + public/alliance_moons.txt | 1810 ++ public/index.php | 3 + vendor/bin/php-parse | 1 + vendor/cakephp/chronos/Dockerfile | 10 - vendor/cakephp/chronos/README.md | 150 - vendor/cakephp/chronos/composer.json | 63 - vendor/cakephp/chronos/docs.Dockerfile | 20 - .../cakephp/chronos/docs/config/__init__.py | 0 vendor/cakephp/chronos/docs/config/all.py | 49 - vendor/cakephp/chronos/docs/en/conf.py | 9 - vendor/cakephp/chronos/docs/en/contents.rst | 7 - vendor/cakephp/chronos/docs/en/index.rst | 321 - vendor/cakephp/chronos/docs/fr/conf.py | 9 - vendor/cakephp/chronos/docs/fr/contents.rst | 7 - vendor/cakephp/chronos/docs/fr/index.rst | 306 - vendor/cakephp/chronos/docs/ja/conf.py | 9 - vendor/cakephp/chronos/docs/ja/contents.rst | 7 - vendor/cakephp/chronos/docs/ja/index.rst | 304 - vendor/cakephp/chronos/docs/pt/conf.py | 9 - vendor/cakephp/chronos/docs/pt/contents.rst | 7 - vendor/cakephp/chronos/docs/pt/index.rst | 285 - vendor/cakephp/chronos/src/Chronos.php | 215 - .../cakephp/chronos/src/ChronosInterface.php | 1403 - .../cakephp/chronos/src/ChronosInterval.php | 550 - vendor/cakephp/chronos/src/Date.php | 142 - .../chronos/src/DifferenceFormatter.php | 107 - .../src/DifferenceFormatterInterface.php | 35 - vendor/cakephp/chronos/src/MutableDate.php | 141 - .../cakephp/chronos/src/MutableDateTime.php | 200 - .../chronos/src/Traits/ComparisonTrait.php | 565 - .../cakephp/chronos/src/Traits/CopyTrait.php | 35 - .../chronos/src/Traits/DifferenceTrait.php | 332 - .../chronos/src/Traits/FactoryTrait.php | 364 - .../chronos/src/Traits/FormattingTrait.php | 267 - .../chronos/src/Traits/FrozenTimeTrait.php | 183 - .../chronos/src/Traits/MagicPropertyTrait.php | 138 - .../chronos/src/Traits/ModifierTrait.php | 1126 - .../src/Traits/RelativeKeywordTrait.php | 85 - .../chronos/src/Traits/TestingAidTrait.php | 60 - .../chronos/src/Traits/TimezoneTrait.php | 57 - vendor/cakephp/chronos/src/Translator.php | 95 - vendor/cakephp/chronos/src/carbon_compat.php | 23 - vendor/composer/ClassLoader.php | 34 + vendor/composer/InstalledVersions.php | 524 +- vendor/composer/autoload_classmap.php | 981 +- vendor/composer/autoload_files.php | 10 +- vendor/composer/autoload_psr4.php | 5 +- vendor/composer/autoload_real.php | 2 +- vendor/composer/autoload_static.php | 1017 +- vendor/composer/installed.json | 1773 +- vendor/composer/installed.php | 524 +- .../cron-expression/CHANGELOG.md | 50 + .../dragonmantank/cron-expression/README.md | 23 +- .../cron-expression/composer.json | 25 +- .../cron-expression/phpstan.neon | 2 + .../src/Cron/AbstractField.php | 153 +- .../src/Cron/CronExpression.php | 271 +- .../src/Cron/DayOfMonthField.php | 72 +- .../src/Cron/DayOfWeekField.php | 74 +- .../cron-expression/src/Cron/FieldFactory.php | 58 +- .../src/Cron/FieldFactoryInterface.php | 8 + .../src/Cron/FieldInterface.php | 21 +- .../cron-expression/src/Cron/HoursField.php | 47 +- .../cron-expression/src/Cron/MinutesField.php | 37 +- .../cron-expression/src/Cron/MonthField.php | 24 +- .../tests/Cron/AbstractFieldTest.php | 139 - .../tests/Cron/CronExpressionTest.php | 589 - .../tests/Cron/DayOfMonthFieldTest.php | 77 - .../tests/Cron/DayOfWeekFieldTest.php | 156 - .../tests/Cron/FieldFactoryTest.php | 43 - .../tests/Cron/HoursFieldTest.php | 99 - .../tests/Cron/MinutesFieldTest.php | 73 - .../tests/Cron/MonthFieldTest.php | 103 - vendor/eveseat/eseye/.styleci.yml | 2 +- vendor/eveseat/eseye/bin/index.php | 8 +- vendor/eveseat/eseye/composer.json | 5 +- vendor/eveseat/eseye/example.php | 2 +- .../eseye/src/Access/AccessInterface.php | 2 +- .../eveseat/eseye/src/Access/CheckAccess.php | 2 +- .../eseye/src/Cache/CacheInterface.php | 2 +- vendor/eveseat/eseye/src/Cache/FileCache.php | 2 +- .../eveseat/eseye/src/Cache/HashesStrings.php | 2 +- .../eseye/src/Cache/MemcachedCache.php | 2 +- vendor/eveseat/eseye/src/Cache/NullCache.php | 2 +- vendor/eveseat/eseye/src/Cache/RedisCache.php | 2 +- .../eseye/src/Checker/Claim/AzpChecker.php | 2 +- .../eseye/src/Checker/Claim/NameChecker.php | 2 +- .../eseye/src/Checker/Claim/OwnerChecker.php | 2 +- .../Checker/Claim/SubEveCharacterChecker.php | 2 +- .../eseye/src/Checker/Header/TypeChecker.php | 2 +- vendor/eveseat/eseye/src/Configuration.php | 2 +- .../src/Containers/AbstractArrayAccess.php | 2 +- .../src/Containers/EsiAuthentication.php | 2 +- .../eseye/src/Containers/EsiConfiguration.php | 2 +- .../eseye/src/Containers/EsiResponse.php | 2 +- vendor/eveseat/eseye/src/Eseye.php | 4 +- .../src/Exceptions/CachePathException.php | 2 +- .../EsiScopeAccessDeniedException.php | 2 +- .../InvalidAuthenticationException.php | 2 +- .../InvalidConfigurationException.php | 2 +- .../InvalidContainerDataException.php | 2 +- .../Exceptions/InvalidEsiSpecException.php | 2 +- .../src/Exceptions/RequestFailedException.php | 2 +- .../Exceptions/UriDataMissingException.php | 2 +- .../eseye/src/Fetchers/FetcherInterface.php | 2 +- .../eseye/src/Fetchers/GuzzleFetcher.php | 2 +- vendor/eveseat/eseye/src/Helpers/helpers.php | 2 +- vendor/eveseat/eseye/src/Log/FileLogger.php | 2 +- vendor/eveseat/eseye/src/Log/LogInterface.php | 2 +- vendor/eveseat/eseye/src/Log/NullLogger.php | 2 +- .../eseye/src/Log/RotatingFileLogger.php | 2 +- .../eseye/src/Traits/ConstructsContainers.php | 2 +- .../eseye/src/Traits/ValidatesContainers.php | 2 +- .../eseye/tests/Access/CheckAccessTest.php | 5 +- .../eseye/tests/Cache/FileCacheTest.php | 5 +- .../eseye/tests/Cache/HashesStringsTest.php | 3 +- .../eseye/tests/Cache/MemcachedCacheTest.php | 52 +- .../eseye/tests/Cache/NullCacheTest.php | 5 +- .../eseye/tests/Cache/RedisCacheTest.php | 16 +- .../eveseat/eseye/tests/ConfigurationTest.php | 3 +- .../Containers/EsiAuthenticationTest.php | 5 +- .../tests/Containers/EsiConfigurationTest.php | 5 +- .../tests/Containers/EsiResponseTest.php | 5 +- vendor/eveseat/eseye/tests/EseyeTest.php | 11 +- .../Exceptions/RequestFailedExceptionTest.php | 5 +- .../tests/Fetchers/GuzzleFetcherTest.php | 5 +- .../eseye/tests/Log/FileLoggerTest.php | 13 +- .../eseye/tests/Log/NullLoggerTest.php | 6 +- .../tests/Log/RotatingFileLoggerTest.php | 13 +- .../eseye/tools/get_endpoints_and_scopes.php | 2 +- .../eveseat/eseye/tools/swagger_download.php | 2 +- .../result-type}/LICENSE | 13 +- .../graham-campbell/result-type/composer.json | 39 + .../result-type/src}/Error.php | 41 +- .../result-type/src/Result.php | 69 + .../result-type/src}/Success.php | 40 +- vendor/guzzlehttp/guzzle/.php_cs | 23 - vendor/guzzlehttp/guzzle/CHANGELOG.md | 156 +- vendor/guzzlehttp/guzzle/Dockerfile | 18 - vendor/guzzlehttp/guzzle/LICENSE | 2 +- vendor/guzzlehttp/guzzle/README.md | 51 +- vendor/guzzlehttp/guzzle/UPGRADING.md | 56 +- vendor/guzzlehttp/guzzle/composer.json | 28 +- .../guzzlehttp/guzzle/src/BodySummarizer.php | 28 + .../guzzle/src/BodySummarizerInterface.php | 13 + vendor/guzzlehttp/guzzle/src/Client.php | 233 +- .../guzzlehttp/guzzle/src/ClientInterface.php | 23 +- vendor/guzzlehttp/guzzle/src/ClientTrait.php | 241 + .../guzzle/src/Cookie/CookieJar.php | 129 +- .../guzzle/src/Cookie/CookieJarInterface.php | 23 +- .../guzzle/src/Cookie/FileCookieJar.php | 46 +- .../guzzle/src/Cookie/SessionCookieJar.php | 35 +- .../guzzle/src/Cookie/SetCookie.php | 175 +- .../src/Exception/BadResponseException.php | 30 +- .../guzzle/src/Exception/ClientException.php | 1 + .../guzzle/src/Exception/ConnectException.php | 39 +- .../guzzle/src/Exception/GuzzleException.php | 22 +- .../guzzle/src/Exception/RequestException.php | 106 +- .../guzzle/src/Exception/SeekException.php | 27 - .../guzzle/src/Exception/ServerException.php | 1 + .../Exception/TooManyRedirectsException.php | 1 + .../src/Exception/TransferException.php | 1 + .../guzzle/src/Handler/CurlFactory.php | 407 +- .../src/Handler/CurlFactoryInterface.php | 8 +- .../guzzle/src/Handler/CurlHandler.php | 22 +- .../guzzle/src/Handler/CurlMultiHandler.php | 134 +- .../guzzle/src/Handler/EasyHandle.php | 80 +- .../guzzle/src/Handler/HeaderProcessor.php | 42 + .../guzzle/src/Handler/MockHandler.php | 140 +- .../guzzlehttp/guzzle/src/Handler/Proxy.php | 40 +- .../guzzle/src/Handler/StreamHandler.php | 398 +- vendor/guzzlehttp/guzzle/src/HandlerStack.php | 138 +- .../guzzle/src/MessageFormatter.php | 85 +- .../guzzle/src/MessageFormatterInterface.php | 18 + vendor/guzzlehttp/guzzle/src/Middleware.php | 116 +- vendor/guzzlehttp/guzzle/src/Pool.php | 63 +- .../guzzle/src/PrepareBodyMiddleware.php | 33 +- .../guzzle/src/RedirectMiddleware.php | 121 +- .../guzzlehttp/guzzle/src/RequestOptions.php | 63 +- .../guzzlehttp/guzzle/src/RetryMiddleware.php | 84 +- .../guzzlehttp/guzzle/src/TransferStats.php | 55 +- vendor/guzzlehttp/guzzle/src/UriTemplate.php | 237 - vendor/guzzlehttp/guzzle/src/Utils.php | 362 +- vendor/guzzlehttp/guzzle/src/functions.php | 275 +- .../guzzle/src/functions_include.php | 2 +- .../vendor-bin/php-cs-fixer/composer.json | 9 + .../guzzle/vendor-bin/phpstan/composer.json | 10 + .../guzzle/vendor-bin/psalm/composer.json | 9 + vendor/laravel/framework/README.md | 6 +- vendor/laravel/framework/composer.json | 65 +- .../Auth/Access/Events/GateEvaluated.php | 51 + .../src/Illuminate/Auth/Access/Gate.php | 49 +- .../src/Illuminate/Auth/AuthManager.php | 25 + .../Illuminate/Auth/AuthServiceProvider.php | 36 +- .../src/Illuminate/Auth/Authenticatable.php | 10 + .../Console/stubs/make/views/layouts/app.stub | 4 +- .../src/Illuminate/Auth/GuardHelpers.php | 2 +- .../Auth/Middleware/EnsureEmailIsVerified.php | 5 +- .../Auth/Notifications/ResetPassword.php | 11 + .../Auth/Notifications/VerifyEmail.php | 35 +- .../Auth/Passwords/PasswordBroker.php | 19 +- .../src/Illuminate/Auth/SessionGuard.php | 132 +- .../src/Illuminate/Auth/composer.json | 20 +- .../Broadcasting/BroadcastEvent.php | 1 + .../Broadcasting/BroadcastManager.php | 63 +- .../Broadcasters/AblyBroadcaster.php | 206 + .../Broadcasting/Broadcasters/Broadcaster.php | 2 +- .../Broadcasters/PusherBroadcaster.php | 71 +- .../Broadcasters/RedisBroadcaster.php | 19 +- .../UsePusherChannelConventions.php | 2 +- .../src/Illuminate/Broadcasting/composer.json | 15 +- .../framework/src/Illuminate/Bus/Batch.php | 466 + .../src/Illuminate/Bus/BatchFactory.php | 58 + .../src/Illuminate/Bus/BatchRepository.php | 92 + .../src/Illuminate/Bus/Batchable.php | 52 + .../src/Illuminate/Bus/BusServiceProvider.php | 21 + .../Bus/DatabaseBatchRepository.php | 347 + .../src/Illuminate/Bus/Dispatcher.php | 85 +- .../Illuminate/Bus/Events/BatchDispatched.php | 26 + .../src/Illuminate/Bus/PendingBatch.php | 256 + .../Bus/PrunableBatchRepository.php | 16 + .../src/Illuminate/Bus/Queueable.php | 55 + .../Illuminate/Bus/UpdatedBatchJobCounts.php | 43 + .../src/Illuminate/Bus/composer.json | 11 +- .../src/Illuminate/Cache/CacheLock.php | 85 + .../src/Illuminate/Cache/CacheManager.php | 79 +- .../Illuminate/Cache/CacheServiceProvider.php | 4 +- .../Illuminate/Cache/Console/ClearCommand.php | 2 +- .../src/Illuminate/Cache/DatabaseLock.php | 10 + .../src/Illuminate/Cache/DatabaseStore.php | 24 +- .../src/Illuminate/Cache/DynamoDbStore.php | 10 + .../src/Illuminate/Cache/FileStore.php | 46 +- .../src/Illuminate/Cache/HasCacheLock.php | 31 + .../framework/src/Illuminate/Cache/Lock.php | 4 +- .../framework/src/Illuminate/Cache/NoLock.php | 46 + .../src/Illuminate/Cache/NullStore.php | 29 +- .../src/Illuminate/Cache/PhpRedisLock.php | 112 + .../src/Illuminate/Cache/RateLimiter.php | 33 + .../Cache/RateLimiting/GlobalLimit.php | 18 + .../Illuminate/Cache/RateLimiting/Limit.php | 132 + .../Cache/RateLimiting/Unlimited.php | 16 + .../src/Illuminate/Cache/RedisLock.php | 10 + .../src/Illuminate/Cache/RedisStore.php | 45 +- .../src/Illuminate/Cache/RedisTaggedCache.php | 9 +- .../src/Illuminate/Cache/Repository.php | 56 +- .../Cache/RetrievesMultipleKeys.php | 8 +- .../src/Illuminate/Cache/TaggedCache.php | 8 +- .../src/Illuminate/Cache/composer.json | 18 +- .../{Support => Collections}/Arr.php | 37 +- .../{Support => Collections}/Collection.php | 170 +- .../{Support => Collections}/Enumerable.php | 107 +- .../HigherOrderCollectionProxy.php | 0 .../HigherOrderWhenProxy.php | 0 .../Collections/ItemNotFoundException.php | 9 + .../src/Illuminate/Collections/LICENSE.md | 21 + .../LazyCollection.php | 181 +- .../MultipleItemsFoundException.php | 9 + .../Traits/EnumeratesValues.php | 108 +- .../src/Illuminate/Collections/composer.json | 41 + .../src/Illuminate/Collections/helpers.php | 186 + .../src/Illuminate/Config/composer.json | 8 +- .../src/Illuminate/Console/Application.php | 3 +- .../Console/BufferedConsoleOutput.php | 41 + .../src/Illuminate/Console/Command.php | 8 +- .../Console/Concerns/CallsCommands.php | 14 +- .../Console/Concerns/InteractsWithIO.php | 46 +- .../ScheduledBackgroundTaskFinished.php | 26 + .../Console/Events/ScheduledTaskFailed.php | 5 +- .../Illuminate/Console/GeneratorCommand.php | 29 +- .../Console/Scheduling/CallbackEvent.php | 7 + .../Console/Scheduling/CommandBuilder.php | 2 +- .../Illuminate/Console/Scheduling/Event.php | 36 +- .../Console/Scheduling/ManagesFrequencies.php | 52 +- .../Console/Scheduling/Schedule.php | 14 + .../Scheduling/ScheduleFinishCommand.php | 8 +- .../Scheduling/ScheduleListCommand.php | 53 + .../Scheduling/ScheduleTestCommand.php | 47 + .../Scheduling/ScheduleWorkCommand.php | 68 + .../src/Illuminate/Console/composer.json | 26 +- .../src/Illuminate/Container/BoundMethod.php | 2 + .../src/Illuminate/Container/Container.php | 116 +- .../Container/ContextualBindingBuilder.php | 14 + .../src/Illuminate/Container/Util.php | 3 + .../src/Illuminate/Container/composer.json | 6 +- .../Contracts/Auth/PasswordBroker.php | 3 +- .../Contracts/Auth/StatefulGuard.php | 2 +- .../Illuminate/Contracts/Bus/Dispatcher.php | 11 + .../Contracts/Bus/QueueingDispatcher.php | 16 + .../src/Illuminate/Contracts/Cache/Lock.php | 2 +- .../Illuminate/Contracts/Console/Kernel.php | 7 + .../Container/CircularDependencyException.php | 11 + .../Container/ContextualBindingBuilder.php | 8 + .../Contracts/Database/Eloquent/Castable.php | 4 +- .../Eloquent/DeviatesCastableAttributes.php | 28 + .../Eloquent/SerializesCastableAttributes.php | 17 + .../Eloquent/SupportsPartialRelations.php | 30 + .../Contracts/Encryption/StringEncrypter.php | 26 + .../Contracts/Events/Dispatcher.php | 6 +- .../Filesystem/LockTimeoutException.php | 10 + .../src/Illuminate/Contracts/Mail/Factory.php | 2 +- .../Contracts/Pagination/CursorPaginator.php | 117 + .../Contracts/Queue/ClearableQueue.php | 14 + .../src/Illuminate/Contracts/Queue/Job.php | 2 +- .../Contracts/Queue/ShouldBeEncrypted.php | 8 + .../Contracts/Queue/ShouldBeUnique.php | 8 + .../Queue/ShouldBeUniqueUntilProcessing.php | 8 + .../Illuminate/Contracts/Session/Session.php | 39 + .../Contracts/Validation/DataAwareRule.php | 14 + .../Validation/UncompromisedVerifier.php | 14 + .../Validation/ValidatorAwareRule.php | 14 + .../src/Illuminate/Contracts/composer.json | 4 +- .../src/Illuminate/Cookie/CookieJar.php | 25 + .../Cookie/Middleware/EncryptCookies.php | 2 +- .../src/Illuminate/Cookie/composer.json | 14 +- .../Database/Concerns/BuildsQueries.php | 157 +- .../Database/Concerns/ExplainsQueries.php | 24 + .../Database/Concerns/ManagesTransactions.php | 42 + .../src/Illuminate/Database/Connection.php | 80 +- .../Database/ConnectionInterface.php | 7 + .../Illuminate/Database/Console/DbCommand.php | 203 + .../Database/Console/DumpCommand.php | 86 + .../Console/Factories/FactoryMakeCommand.php | 47 +- .../Console/Factories/stubs/factory.stub | 30 +- .../Console/Migrations/FreshCommand.php | 12 +- .../Console/Migrations/MigrateCommand.php | 80 +- .../Console/Migrations/MigrateMakeCommand.php | 10 - .../Console/Migrations/RefreshCommand.php | 10 +- .../Console/Migrations/ResetCommand.php | 2 - .../Database/Console/Seeds/SeedCommand.php | 32 +- .../Console/Seeds/SeederMakeCommand.php | 33 +- .../Database/Console/Seeds/stubs/seeder.stub | 2 + .../Database/DBAL/TimestampType.php | 105 + .../Illuminate/Database/DatabaseManager.php | 31 +- .../Database/DatabaseServiceProvider.php | 35 +- .../Database/DatabaseTransactionRecord.php | 73 + .../Database/DatabaseTransactionsManager.php | 96 + .../Database/DetectsLostConnections.php | 5 + .../Illuminate/Database/Eloquent/Builder.php | 260 +- .../Database/Eloquent/Casts/ArrayObject.php | 40 + .../Database/Eloquent/Casts/AsArrayObject.php | 36 + .../Database/Eloquent/Casts/AsCollection.php | 32 + .../Eloquent/Casts/AsEncryptedArrayObject.php | 37 + .../Eloquent/Casts/AsEncryptedCollection.php | 33 + .../Database/Eloquent/Collection.php | 86 +- .../Eloquent/Concerns/GuardsAttributes.php | 10 +- .../Eloquent/Concerns/HasAttributes.php | 249 +- .../Eloquent/Concerns/HasRelationships.php | 4 +- .../Eloquent/Concerns/HasTimestamps.php | 6 +- .../Eloquent/Concerns/HidesAttributes.php | 8 +- .../Concerns/QueriesRelationships.php | 156 +- .../Factories/BelongsToManyRelationship.php | 61 + .../Factories/BelongsToRelationship.php | 80 + .../Database/Eloquent/Factories/Factory.php | 782 + .../Eloquent/Factories/HasFactory.php | 31 + .../Eloquent/Factories/Relationship.php | 62 + .../Database/Eloquent/Factories/Sequence.php | 55 + .../Illuminate/Database/Eloquent/Factory.php | 271 - .../Database/Eloquent/FactoryBuilder.php | 449 - .../Eloquent/InvalidCastException.php | 48 + .../Illuminate/Database/Eloquent/Model.php | 344 +- .../Eloquent/ModelNotFoundException.php | 4 +- .../Database/Eloquent/Relations/BelongsTo.php | 64 +- .../Eloquent/Relations/BelongsToMany.php | 154 +- .../Eloquent/Relations/Concerns/AsPivot.php | 17 +- .../Relations/Concerns/CanBeOneOfMany.php | 302 + .../Concerns/ComparesRelatedModels.php | 77 + .../Concerns/InteractsWithDictionary.php | 29 + .../Concerns/InteractsWithPivotTable.php | 21 +- .../Eloquent/Relations/HasManyThrough.php | 50 +- .../Database/Eloquent/Relations/HasOne.php | 73 +- .../Eloquent/Relations/HasOneOrMany.php | 40 +- .../Eloquent/Relations/HasOneThrough.php | 5 +- .../Database/Eloquent/Relations/MorphOne.php | 73 +- .../Eloquent/Relations/MorphOneOrMany.php | 4 +- .../Eloquent/Relations/MorphPivot.php | 26 +- .../Database/Eloquent/Relations/MorphTo.php | 55 +- .../Eloquent/Relations/MorphToMany.php | 8 +- .../Database/Eloquent/Relations/Relation.php | 56 +- .../Database/Eloquent/SoftDeletes.php | 6 +- .../Database/Eloquent/SoftDeletingScope.php | 2 +- .../Database/Events/DatabaseRefreshed.php | 10 + .../Database/Events/MigrationEvent.php | 2 +- .../Database/Events/SchemaDumped.php | 41 + .../Database/Events/SchemaLoaded.php | 41 + .../LazyLoadingViolationException.php | 39 + .../Database/MigrationServiceProvider.php | 3 +- .../DatabaseMigrationRepository.php | 12 + .../Database/Migrations/MigrationCreator.php | 7 +- .../MigrationRepositoryInterface.php | 9 +- .../Database/Migrations/Migrator.php | 79 +- .../MultipleRecordsFoundException.php | 10 + .../Illuminate/Database/MySqlConnection.php | 31 +- .../PDO/Concerns/ConnectsToDatabase.php | 27 + .../Illuminate/Database/PDO/Connection.php | 182 + .../Illuminate/Database/PDO/MySqlDriver.php | 11 + .../Database/PDO/PostgresDriver.php | 11 + .../Illuminate/Database/PDO/SQLiteDriver.php | 11 + .../Database/PDO/SqlServerConnection.php | 152 + .../Database/PDO/SqlServerDriver.php | 15 + .../Database/PostgresConnection.php | 20 +- .../src/Illuminate/Database/Query/Builder.php | 257 +- .../Database/Query/Grammars/Grammar.php | 28 +- .../Database/Query/Grammars/MySqlGrammar.php | 37 +- .../Query/Grammars/PostgresGrammar.php | 28 +- .../Database/Query/Grammars/SQLiteGrammar.php | 26 +- .../Query/Grammars/SqlServerGrammar.php | 52 +- .../Database/RecordsNotFoundException.php | 10 + .../Illuminate/Database/SQLiteConnection.php | 21 +- .../Illuminate/Database/Schema/Blueprint.php | 170 +- .../Illuminate/Database/Schema/Builder.php | 75 + .../Database/Schema/ColumnDefinition.php | 9 +- .../Database/Schema/ForeignKeyDefinition.php | 10 + .../Database/Schema/Grammars/Grammar.php | 28 + .../Database/Schema/Grammars/MySqlGrammar.php | 90 +- .../Schema/Grammars/PostgresGrammar.php | 70 +- .../Schema/Grammars/SQLiteGrammar.php | 72 +- .../Schema/Grammars/SqlServerGrammar.php | 52 +- .../Database/Schema/MySqlBuilder.php | 26 + .../Database/Schema/MySqlSchemaState.php | 163 + .../Database/Schema/PostgresBuilder.php | 26 + .../Database/Schema/PostgresSchemaState.php | 83 + .../Database/Schema/SQLiteBuilder.php | 26 + .../Database/Schema/SchemaState.php | 122 + .../Database/Schema/SqlServerBuilder.php | 26 + .../Database/Schema/SqliteSchemaState.php | 93 + .../src/Illuminate/Database/Seeder.php | 37 +- .../Database/SqlServerConnection.php | 23 +- .../src/Illuminate/Database/composer.json | 26 +- .../src/Illuminate/Encryption/Encrypter.php | 21 +- .../Encryption/EncryptionServiceProvider.php | 7 +- .../Encryption/MissingAppKeyException.php | 19 + .../src/Illuminate/Encryption/composer.json | 8 +- .../Illuminate/Events/CallQueuedListener.php | 23 +- .../src/Illuminate/Events/Dispatcher.php | 78 +- .../Illuminate/Events/InvokeQueuedClosure.php | 34 + .../src/Illuminate/Events/NullDispatcher.php | 11 +- .../src/Illuminate/Events/QueuedClosure.php | 125 + .../src/Illuminate/Events/composer.json | 18 +- .../src/Illuminate/Events/functions.php | 18 + .../src/Illuminate/Filesystem/Filesystem.php | 86 +- .../Filesystem/FilesystemAdapter.php | 45 +- .../Filesystem/FilesystemManager.php | 23 +- .../Illuminate/Filesystem/LockableFile.php | 194 + .../src/Illuminate/Filesystem/composer.json | 15 +- .../src/Illuminate/Foundation/AliasLoader.php | 2 +- .../src/Illuminate/Foundation/Application.php | 82 +- .../Foundation/Auth/Access/Authorizable.php | 12 + .../Auth/EmailVerificationRequest.php | 66 + .../Bootstrap/LoadConfiguration.php | 2 +- .../Bootstrap/LoadEnvironmentVariables.php | 2 +- .../Foundation/Bus/Dispatchable.php | 16 + .../Foundation/Bus/DispatchesJobs.php | 15 + .../Foundation/Bus/PendingChain.php | 113 +- .../Foundation/Bus/PendingClosureDispatch.php | 21 + .../Foundation/Bus/PendingDispatch.php | 70 +- .../Illuminate/Foundation/ComposerScripts.php | 4 +- .../Foundation/Console/CastMakeCommand.php | 15 +- .../Console/ClearCompiledCommand.php | 4 +- .../Foundation/Console/ClosureCommand.php | 11 + .../Console/ComponentMakeCommand.php | 10 +- .../Foundation/Console/DownCommand.php | 66 +- .../Illuminate/Foundation/Console/Kernel.php | 6 +- .../Foundation/Console/ModelMakeCommand.php | 15 +- .../Console/ObserverMakeCommand.php | 82 +- .../Foundation/Console/PolicyMakeCommand.php | 20 +- .../Foundation/Console/RouteListCommand.php | 19 +- .../Foundation/Console/ServeCommand.php | 82 +- .../Foundation/Console/StorageLinkCommand.php | 45 +- .../Foundation/Console/StubPublishCommand.php | 3 + .../Foundation/Console/TestMakeCommand.php | 15 +- .../Foundation/Console/UpCommand.php | 8 +- .../Console/VendorPublishCommand.php | 7 +- .../Foundation/Console/stubs/cast.stub | 6 +- .../stubs/exception-render-report.stub | 2 +- .../Console/stubs/exception-report.stub | 2 +- .../Foundation/Console/stubs/job.queued.stub | 1 + .../Console/stubs/maintenance-mode.stub | 51 + .../Foundation/Console/stubs/model.stub | 3 +- .../Console/stubs/observer.plain.stub | 4 +- .../Foundation/Console/stubs/observer.stub | 36 +- .../Foundation/Console/stubs/test.stub | 2 +- .../Foundation/Console/stubs/test.unit.stub | 2 +- .../Console/stubs/view-component.stub | 2 +- .../Foundation/Events/Dispatchable.php | 2 + .../Foundation/Events/VendorTagPublished.php | 33 + .../Foundation/Exceptions/Handler.php | 184 +- .../Exceptions/RegisterErrorViewPaths.php | 20 + .../Exceptions/ReportableHandler.php | 76 + .../Foundation/Exceptions/views/503.blade.php | 2 +- .../views/illustrated-layout.blade.php | 4 +- .../Exceptions/views/layout.blade.php | 4 +- .../Exceptions/views/minimal.blade.php | 60 +- .../Exceptions/MaintenanceModeException.php | 3 + .../Foundation/Http/FormRequest.php | 9 +- .../src/Illuminate/Foundation/Http/Kernel.php | 30 +- .../Http/MaintenanceModeBypassCookie.php | 43 + .../Middleware/CheckForMaintenanceMode.php | 82 +- .../Middleware/ConvertEmptyStringsToNull.php | 38 + .../PreventRequestsDuringMaintenance.php | 156 + .../Http/Middleware/TransformsRequest.php | 8 +- .../Http/Middleware/TrimStrings.php | 38 + .../src/Illuminate/Foundation/Inspiring.php | 5 + .../src/Illuminate/Foundation/Mix.php | 4 +- .../Illuminate/Foundation/PackageManifest.php | 6 +- .../Providers/ArtisanServiceProvider.php | 120 +- .../ConsoleSupportServiceProvider.php | 2 +- .../Providers/FoundationServiceProvider.php | 8 +- .../Providers/EventServiceProvider.php | 46 +- .../Providers/RouteServiceProvider.php | 57 +- .../Concerns/InteractsWithAuthentication.php | 14 +- .../Testing/Concerns/InteractsWithConsole.php | 9 +- .../Concerns/InteractsWithDatabase.php | 48 +- .../InteractsWithExceptionHandling.php | 5 +- .../Testing/Concerns/InteractsWithRedis.php | 5 +- .../Testing/Concerns/InteractsWithTime.php | 49 + .../Testing/Concerns/InteractsWithViews.php | 80 + .../Testing/Concerns/MakesHttpRequests.php | 11 +- .../Concerns/MocksApplicationServices.php | 3 + .../Testing/DatabaseTransactions.php | 12 +- .../Foundation/Testing/RefreshDatabase.php | 43 +- .../Foundation/Testing/TestCase.php | 10 + .../Foundation/Testing/Wormhole.php | 157 + .../src/Illuminate/Foundation/helpers.php | 104 +- .../src/Illuminate/Hashing/ArgonHasher.php | 2 +- .../src/Illuminate/Hashing/composer.json | 8 +- .../src/Illuminate/Http/Client/Factory.php | 83 +- .../Illuminate/Http/Client/PendingRequest.php | 219 +- .../src/Illuminate/Http/Client/Pool.php | 86 + .../Http/Client/RequestException.php | 19 +- .../src/Illuminate/Http/Client/Response.php | 70 +- .../Http/Client/ResponseSequence.php | 5 + .../Concerns/InteractsWithContentTypes.php | 36 +- .../Http/Concerns/InteractsWithFlashData.php | 2 +- .../Http/Concerns/InteractsWithInput.php | 31 + .../src/Illuminate/Http/JsonResponse.php | 13 +- .../src/Illuminate/Http/RedirectResponse.php | 30 +- .../framework/src/Illuminate/Http/Request.php | 12 +- .../Http/Resources/CollectsResources.php | 6 +- .../Http/Resources/Json/JsonResource.php | 4 +- .../Resources/Json/ResourceCollection.php | 3 +- .../Illuminate/Http/Resources/MergeValue.php | 2 +- .../src/Illuminate/Http/Response.php | 7 + .../src/Illuminate/Http/ResponseTrait.php | 19 + .../src/Illuminate/Http/Testing/MimeType.php | 2 +- .../src/Illuminate/Http/UploadedFile.php | 2 +- .../src/Illuminate/Http/composer.json | 18 +- .../src/Illuminate/Log/LogManager.php | 10 +- .../src/Illuminate/Log/composer.json | 8 +- .../src/Illuminate/Macroable/LICENSE.md | 21 + .../Traits/Macroable.php | 0 .../src/Illuminate/Macroable/composer.json | 33 + .../src/Illuminate/Mail/MailManager.php | 63 +- .../src/Illuminate/Mail/Mailable.php | 111 +- .../framework/src/Illuminate/Mail/Mailer.php | 6 +- .../src/Illuminate/Mail/Markdown.php | 20 +- .../framework/src/Illuminate/Mail/Message.php | 2 +- .../src/Illuminate/Mail/PendingMail.php | 16 +- .../Illuminate/Mail/SendQueuedMailable.php | 21 +- .../Mail/Transport/MailgunTransport.php | 7 +- .../Mail/Transport/SesTransport.php | 5 +- .../src/Illuminate/Mail/composer.json | 14 +- .../resources/views/html/layout.blade.php | 6 +- .../resources/views/html/themes/default.css | 1 + .../Notifications/AnonymousNotifiable.php | 2 + .../Notifications/ChannelManager.php | 4 +- .../Channels/BroadcastChannel.php | 2 +- .../Notifications/DatabaseNotification.php | 23 + .../Events/BroadcastNotificationCreated.php | 4 + .../HasDatabaseNotifications.php | 4 +- .../Notifications/Messages/MailMessage.php | 50 +- .../Notifications/Messages/SimpleMessage.php | 4 +- .../Notifications/NotificationSender.php | 7 +- .../Notifications/SendQueuedNotifications.php | 22 +- .../Illuminate/Notifications/composer.json | 23 +- .../Pagination/AbstractCursorPaginator.php | 612 + .../Pagination/AbstractPaginator.php | 47 +- .../src/Illuminate/Pagination/Cursor.php | 132 + .../Pagination/CursorPaginationException.php | 10 + .../Illuminate/Pagination/CursorPaginator.php | 160 + .../Pagination/LengthAwarePaginator.php | 31 + .../Pagination/PaginationServiceProvider.php | 22 +- .../Illuminate/Pagination/PaginationState.php | 41 + .../src/Illuminate/Pagination/composer.json | 9 +- .../resources/views/simple-tailwind.blade.php | 4 +- .../resources/views/tailwind.blade.php | 14 +- .../framework/src/Illuminate/Pipeline/Hub.php | 23 + .../src/Illuminate/Pipeline/Pipeline.php | 13 + .../src/Illuminate/Pipeline/composer.json | 8 +- .../src/Illuminate/Queue/BeanstalkdQueue.php | 36 +- .../Illuminate/Queue/CallQueuedClosure.php | 40 +- .../Illuminate/Queue/CallQueuedHandler.php | 130 +- .../Queue/Connectors/BeanstalkdConnector.php | 3 +- .../Queue/Connectors/DatabaseConnector.php | 3 +- .../Queue/Connectors/RedisConnector.php | 3 +- .../Queue/Connectors/SqsConnector.php | 6 +- .../Queue/Console/BatchesTableCommand.php | 102 + .../Illuminate/Queue/Console/ClearCommand.php | 100 + .../Queue/Console/ListFailedCommand.php | 4 +- .../Queue/Console/ListenCommand.php | 18 +- .../Queue/Console/PruneBatchesCommand.php | 56 + .../Queue/Console/RetryBatchCommand.php | 47 + .../Illuminate/Queue/Console/RetryCommand.php | 70 +- .../Illuminate/Queue/Console/WorkCommand.php | 40 +- .../Queue/Console/stubs/batches.stub | 39 + .../Queue/Console/stubs/failed_jobs.stub | 3 +- .../src/Illuminate/Queue/DatabaseQueue.php | 73 +- .../src/Illuminate/Queue/Events/JobQueued.php | 42 + .../Failed/DatabaseUuidFailedJobProvider.php | 130 + .../Failed/DynamoDbFailedJobProvider.php | 7 +- .../src/Illuminate/Queue/Jobs/DatabaseJob.php | 16 +- .../src/Illuminate/Queue/Jobs/Job.php | 22 +- .../src/Illuminate/Queue/Listener.php | 3 +- .../src/Illuminate/Queue/ListenerOptions.php | 7 +- .../src/Illuminate/Queue/LuaScripts.php | 21 +- .../Queue/Middleware/RateLimited.php | 146 + .../Queue/Middleware/RateLimitedWithRedis.php | 103 + .../Queue/Middleware/ThrottlesExceptions.php | 202 + .../ThrottlesExceptionsWithRedis.php | 62 + .../Queue/Middleware/WithoutOverlapping.php | 141 + .../framework/src/Illuminate/Queue/Queue.php | 136 +- .../src/Illuminate/Queue/QueueManager.php | 27 + .../Illuminate/Queue/QueueServiceProvider.php | 40 +- .../src/Illuminate/Queue/RedisQueue.php | 73 +- .../src/Illuminate/Queue/SerializesModels.php | 4 +- .../src/Illuminate/Queue/SqsQueue.php | 54 +- .../src/Illuminate/Queue/SyncQueue.php | 2 +- .../framework/src/Illuminate/Queue/Worker.php | 175 +- .../src/Illuminate/Queue/WorkerOptions.php | 49 +- .../src/Illuminate/Queue/composer.json | 25 +- .../Redis/Connections/PhpRedisConnection.php | 16 +- .../Redis/Connectors/PhpRedisConnector.php | 10 +- .../Redis/Limiters/ConcurrencyLimiter.php | 6 +- .../Limiters/ConcurrencyLimiterBuilder.php | 2 +- .../Redis/Limiters/DurationLimiter.php | 54 + .../Redis/Limiters/DurationLimiterBuilder.php | 4 +- .../src/Illuminate/Redis/RedisManager.php | 15 +- .../src/Illuminate/Redis/composer.json | 10 +- .../Routing/AbstractRouteCollection.php | 9 +- .../Routing/CompiledRouteCollection.php | 6 +- .../Routing/Console/ControllerMakeCommand.php | 16 +- .../Routing/Console/stubs/middleware.stub | 3 +- ...eatesRegularExpressionRouteConstraints.php | 67 + .../Exceptions/UrlGenerationException.php | 22 +- .../Routing/Middleware/SubstituteBindings.php | 13 +- .../Routing/Middleware/ThrottleRequests.php | 129 +- .../Middleware/ThrottleRequestsWithRedis.php | 63 +- .../Routing/Middleware/ValidateSignature.php | 5 +- .../Routing/PendingResourceRegistration.php | 15 +- .../Illuminate/Routing/ResourceRegistrar.php | 12 +- .../src/Illuminate/Routing/Route.php | 65 +- .../src/Illuminate/Routing/RouteAction.php | 12 + .../src/Illuminate/Routing/RouteRegistrar.php | 9 +- .../Routing/RouteSignatureParameters.php | 10 +- .../Illuminate/Routing/RouteUrlGenerator.php | 4 +- .../src/Illuminate/Routing/Router.php | 73 +- .../Routing/RoutingServiceProvider.php | 4 + .../src/Illuminate/Routing/UrlGenerator.php | 21 +- .../src/Illuminate/Routing/ViewController.php | 20 +- .../src/Illuminate/Routing/composer.json | 26 +- .../Session/Console/stubs/database.stub | 6 +- .../Middleware/AuthenticateSession.php | 26 +- .../Session/Middleware/StartSession.php | 13 +- .../Session/SessionServiceProvider.php | 6 +- .../src/Illuminate/Session/Store.php | 21 + .../src/Illuminate/Session/composer.json | 17 +- .../src/Illuminate/Support/Carbon.php | 10 +- .../src/Illuminate/Support/Composer.php | 8 +- .../Support/ConfigurationUrlParser.php | 2 +- .../src/Illuminate/Support/DateFactory.php | 2 +- .../framework/src/Illuminate/Support/Env.php | 17 +- .../src/Illuminate/Support/Facades/App.php | 5 +- .../src/Illuminate/Support/Facades/Auth.php | 3 + .../src/Illuminate/Support/Facades/Blade.php | 1 + .../Illuminate/Support/Facades/Broadcast.php | 3 +- .../src/Illuminate/Support/Facades/Bus.php | 12 +- .../src/Illuminate/Support/Facades/Cache.php | 1 + .../src/Illuminate/Support/Facades/DB.php | 7 + .../src/Illuminate/Support/Facades/Event.php | 6 +- .../src/Illuminate/Support/Facades/File.php | 8 +- .../src/Illuminate/Support/Facades/Http.php | 18 +- .../src/Illuminate/Support/Facades/Lang.php | 3 +- .../src/Illuminate/Support/Facades/Log.php | 2 + .../src/Illuminate/Support/Facades/Mail.php | 9 +- .../Support/Facades/Notification.php | 4 +- .../Support/Facades/ParallelTesting.php | 26 + .../Illuminate/Support/Facades/Password.php | 3 +- .../src/Illuminate/Support/Facades/Queue.php | 20 +- .../Support/Facades/RateLimiter.php | 29 + .../Illuminate/Support/Facades/Redirect.php | 1 + .../src/Illuminate/Support/Facades/Route.php | 20 +- .../src/Illuminate/Support/Facades/Schema.php | 4 + .../Illuminate/Support/Facades/Session.php | 1 + .../Illuminate/Support/Facades/Storage.php | 22 +- .../src/Illuminate/Support/Facades/URL.php | 6 +- .../Illuminate/Support/Facades/Validator.php | 1 + .../src/Illuminate/Support/Facades/View.php | 2 +- .../src/Illuminate/Support/HtmlString.php | 10 + .../src/Illuminate/Support/Manager.php | 45 +- .../src/Illuminate/Support/Optional.php | 3 +- .../src/Illuminate/Support/Pluralizer.php | 4 +- .../Illuminate/Support/ServiceProvider.php | 63 + .../framework/src/Illuminate/Support/Str.php | 87 +- .../src/Illuminate/Support/Stringable.php | 138 +- .../Testing/Fakes/BatchRepositoryFake.php | 142 + .../Support/Testing/Fakes/BusFake.php | 352 +- .../Support/Testing/Fakes/EventFake.php | 54 +- .../Support/Testing/Fakes/MailFake.php | 4 +- .../Testing/Fakes/NotificationFake.php | 2 +- .../Testing/Fakes/PendingBatchFake.php | 39 + .../Testing/Fakes/PendingChainFake.php | 56 + .../Support/Testing/Fakes/PendingMailFake.php | 16 +- .../Support/Testing/Fakes/QueueFake.php | 2 +- .../Support/Traits/ReflectsClosures.php | 3 +- .../src/Illuminate/Support/composer.json | 20 +- .../src/Illuminate/Support/helpers.php | 217 +- .../Testing/AssertableJsonString.php | 386 + .../Testing/Concerns/TestDatabases.php | 179 + .../Testing/Constraints/HasInDatabase.php | 7 +- .../Testing/Fluent/AssertableJson.php | 151 + .../Testing/Fluent/Concerns/Debugging.php | 38 + .../Testing/Fluent/Concerns/Has.php | 186 + .../Testing/Fluent/Concerns/Interaction.php | 67 + .../Testing/Fluent/Concerns/Matching.php | 150 + .../Testing/ParallelConsoleOutput.php | 60 + .../src/Illuminate/Testing/ParallelRunner.php | 155 + .../Illuminate/Testing/ParallelTesting.php | 291 + .../ParallelTestingServiceProvider.php | 38 + .../src/Illuminate/Testing/PendingCommand.php | 85 +- .../src/Illuminate/Testing/TestResponse.php | 248 +- .../src/Illuminate/Testing/TestView.php | 145 + .../src/Illuminate/Testing/composer.json | 22 +- .../src/Illuminate/Translation/FileLoader.php | 16 +- .../src/Illuminate/Translation/Translator.php | 4 +- .../src/Illuminate/Translation/composer.json | 12 +- .../Validation/Concerns/FormatsMessages.php | 10 +- .../Concerns/ReplacesAttributes.php | 54 + .../Concerns/ValidatesAttributes.php | 216 +- .../src/Illuminate/Validation/Factory.php | 23 + .../Validation/NotPwnedVerifier.php | 104 + .../Validation/Rules/DatabaseRule.php | 8 +- .../Illuminate/Validation/Rules/Password.php | 313 + .../Illuminate/Validation/ValidationData.php | 2 +- .../Validation/ValidationRuleParser.php | 36 +- .../Validation/ValidationServiceProvider.php | 16 +- .../src/Illuminate/Validation/Validator.php | 56 +- .../src/Illuminate/Validation/composer.json | 20 +- .../Illuminate/View/AnonymousComponent.php | 9 +- .../View/AppendableAttributeValue.php | 34 + .../View/Compilers/BladeCompiler.php | 60 +- .../Illuminate/View/Compilers/Compiler.php | 13 + .../View/Compilers/ComponentTagCompiler.php | 144 +- .../Compilers/Concerns/CompilesComponents.php | 5 +- .../Concerns/CompilesConditionals.php | 5 +- .../Compilers/Concerns/CompilesInjections.php | 6 +- .../Compilers/Concerns/CompilesLayouts.php | 17 + .../src/Illuminate/View/Component.php | 29 +- .../Illuminate/View/ComponentAttributeBag.php | 137 +- .../View/Concerns/ManagesComponents.php | 28 +- .../View/Concerns/ManagesLayouts.php | 2 +- .../src/Illuminate/View/DynamicComponent.php | 172 + .../View/Engines/CompilerEngine.php | 12 +- .../View/Engines/EngineResolver.php | 11 + .../Illuminate/View/Engines/FileEngine.php | 21 +- .../src/Illuminate/View/Engines/PhpEngine.php | 29 +- .../src/Illuminate/View/FileViewFinder.php | 2 +- .../src/Illuminate/View/ViewException.php | 41 + .../Illuminate/View/ViewServiceProvider.php | 13 +- .../src/Illuminate/View/composer.json | 16 +- vendor/laravel/horizon/README.md | 6 +- vendor/laravel/horizon/composer.json | 18 +- vendor/laravel/horizon/config/horizon.php | 34 +- vendor/laravel/horizon/package-lock.json | 24158 +++++++++++++--- vendor/laravel/horizon/package.json | 24 +- vendor/laravel/horizon/public/app-dark.css | 12 +- vendor/laravel/horizon/public/app.css | 12 +- vendor/laravel/horizon/public/app.js | 2 +- .../laravel/horizon/public/mix-manifest.json | 7 +- vendor/laravel/horizon/resources/js/base.js | 7 + .../resources/js/components/LineChart.vue | 7 +- vendor/laravel/horizon/resources/js/routes.js | 12 + .../resources/js/screens/batches/index.vue | 202 + .../resources/js/screens/batches/preview.vue | 199 + .../resources/js/screens/dashboard.vue | 50 +- .../resources/js/screens/failedJobs/index.vue | 29 + .../resources/js/screens/failedJobs/job.vue | 24 + .../resources/js/screens/monitoring/index.vue | 2 +- .../js/screens/recentJobs/job-row.vue | 7 +- .../resources/js/screens/recentJobs/job.vue | 15 +- .../laravel/horizon/resources/sass/app.scss | 2 +- .../laravel/horizon/resources/sass/base.scss | 4 + .../resources/sass/syntaxhighlight.scss | 48 +- .../horizon/resources/views/layout.blade.php | 18 +- vendor/laravel/horizon/routes/web.php | 5 + vendor/laravel/horizon/src/AutoScaler.php | 47 +- .../horizon/src/Connectors/RedisConnector.php | 3 +- .../horizon/src/Console/ClearCommand.php | 73 + .../src/Console/ContinueSupervisorCommand.php | 52 + .../src/Console/ForgetFailedCommand.php | 39 + .../src/Console/PauseSupervisorCommand.php | 52 + .../horizon/src/Console/SnapshotCommand.php | 2 +- .../horizon/src/Console/SupervisorCommand.php | 27 +- .../horizon/src/Console/TimeoutCommand.php | 8 +- .../horizon/src/Console/WorkCommand.php | 7 +- .../horizon/src/HorizonServiceProvider.php | 146 +- .../Http/Controllers/BatchesController.php | 91 + .../Controllers/CompletedJobsController.php | 4 +- .../Controllers/DashboardStatsController.php | 33 +- .../Http/Controllers/FailedJobsController.php | 2 + .../src/Http/Controllers/HomeController.php | 4 +- .../Http/Controllers/JobMetricsController.php | 6 +- .../Controllers/QueueMetricsController.php | 6 +- vendor/laravel/horizon/src/JobId.php | 40 - vendor/laravel/horizon/src/JobPayload.php | 14 +- .../horizon/src/Jobs/RetryFailedJob.php | 15 +- .../src/Listeners/MonitorWaitTimes.php | 10 +- .../horizon/src/Listeners/TrimFailedJobs.php | 10 +- .../src/Listeners/TrimMonitoredJobs.php | 10 +- .../horizon/src/Listeners/TrimRecentJobs.php | 10 +- vendor/laravel/horizon/src/LuaScripts.php | 42 + .../laravel/horizon/src/MasterSupervisor.php | 6 +- vendor/laravel/horizon/src/ProcessPool.php | 8 +- .../laravel/horizon/src/ProvisioningPlan.php | 29 +- .../horizon/src/QueueCommandString.php | 42 +- vendor/laravel/horizon/src/RedisQueue.php | 63 +- .../src/Repositories/RedisJobRepository.php | 51 +- .../RedisMasterSupervisorRepository.php | 8 +- .../Repositories/RedisMetricsRepository.php | 10 +- .../Repositories/RedisProcessRepository.php | 6 +- .../RedisSupervisorRepository.php | 8 +- .../src/Repositories/RedisTagRepository.php | 4 +- .../Repositories/RedisWorkloadRepository.php | 21 +- vendor/laravel/horizon/src/Supervisor.php | 34 +- .../horizon/src/SupervisorCommandString.php | 5 +- .../laravel/horizon/src/SupervisorOptions.php | 157 +- .../horizon/src/WaitTimeCalculator.php | 59 +- .../horizon/src/WorkerCommandString.php | 4 +- vendor/laravel/horizon/src/WorkerProcess.php | 10 +- vendor/laravel/horizon/webpack.mix.js | 3 +- vendor/laravel/ui/CHANGELOG.md | 125 - vendor/laravel/ui/README.md | 146 +- .../ui/auth-backend/ResetsPasswords.php | 8 +- .../ui/auth-backend/ThrottlesLogins.php | 3 +- vendor/laravel/ui/composer.json | 12 +- .../src/Auth/bootstrap-stubs/layouts/app.stub | 9 +- vendor/laravel/ui/src/Auth/stubs/routes.stub | 2 +- vendor/laravel/ui/src/AuthRouteMethods.php | 66 +- vendor/laravel/ui/src/Presets/Bootstrap.php | 10 +- vendor/laravel/ui/src/Presets/React.php | 6 +- vendor/laravel/ui/src/Presets/Vue.php | 10 +- .../Presets/bootstrap-stubs/webpack.mix.js | 3 +- .../ui/src/Presets/react-stubs/webpack.mix.js | 3 +- .../laravel/ui/src/Presets/vue-stubs/app.js | 2 +- .../ui/src/Presets/vue-stubs/webpack.mix.js | 1 + .../ui/stubs/Auth/RegisterController.stub | 4 +- .../cron-translator/.github/FUNDING.yml | 1 + vendor/lorisleiva/cron-translator/.gitignore | 3 +- .../cron-translator/src/CronExpression.php | 126 + .../cron-translator/src/CronTranslator.php | 46 +- .../cron-translator/src/CronType.php | 21 +- .../cron-translator/src/DaysOfMonthField.php | 63 +- .../cron-translator/src/DaysOfWeekField.php | 46 +- .../lorisleiva/cron-translator/src/Field.php | 67 +- .../cron-translator/src/HoursField.php | 92 +- .../cron-translator/src/MinutesField.php | 21 +- .../cron-translator/src/MonthsField.php | 61 +- .../src/TranslationFileMissingException.php | 13 + .../cron-translator/src/lang/en/days.php | 11 + .../cron-translator/src/lang/en/fields.php | 48 + .../cron-translator/src/lang/en/months.php | 16 + .../cron-translator/src/lang/en/ordinals.php | 12 + .../cron-translator/src/lang/en/times.php | 7 + .../cron-translator/src/lang/fr/days.php | 11 + .../cron-translator/src/lang/fr/fields.php | 48 + .../cron-translator/src/lang/fr/months.php | 16 + .../cron-translator/src/lang/fr/ordinals.php | 6 + .../cron-translator/src/lang/fr/times.php | 7 + .../cron-translator/src/lang/lv/days.php | 11 + .../cron-translator/src/lang/lv/fields.php | 48 + .../cron-translator/src/lang/lv/months.php | 16 + .../cron-translator/src/lang/lv/ordinals.php | 5 + .../cron-translator/src/lang/lv/times.php | 7 + .../tests/CronTranslatorTest.php | 30 + .../cron-translator/tests/TestCase.php | 8 +- .../nesbot/carbon/src/Carbon/Traits/Date.php | 24 + .../carbon/src/Carbon/Traits/Difference.php | 2 +- .../php-parser}/.editorconfig | 11 +- vendor/nikic/php-parser/LICENSE | 29 + vendor/nikic/php-parser/README.md | 225 + vendor/nikic/php-parser/bin/php-parse | 205 + vendor/nikic/php-parser/composer.json | 41 + vendor/nikic/php-parser/grammar/README.md | 30 + .../nikic/php-parser/grammar/parser.template | 106 + vendor/nikic/php-parser/grammar/php5.y | 1026 + vendor/nikic/php-parser/grammar/php7.y | 1152 + vendor/nikic/php-parser/grammar/phpyLang.php | 192 + .../php-parser/grammar/rebuildParsers.php | 81 + .../nikic/php-parser/grammar/tokens.template | 17 + vendor/nikic/php-parser/grammar/tokens.y | 115 + .../php-parser/lib/PhpParser/Builder.php | 13 + .../lib/PhpParser/Builder/ClassConst.php | 103 + .../lib/PhpParser/Builder/Class_.php | 122 + .../lib/PhpParser/Builder/Declaration.php | 43 + .../lib/PhpParser/Builder/FunctionLike.php | 74 + .../lib/PhpParser/Builder/Function_.php | 50 + .../lib/PhpParser/Builder/Interface_.php | 75 + .../lib/PhpParser/Builder/Method.php | 129 + .../lib/PhpParser/Builder/Namespace_.php | 45 + .../lib/PhpParser/Builder/Param.php | 106 + .../lib/PhpParser/Builder/Property.php | 132 + .../lib/PhpParser/Builder/TraitUse.php | 64 + .../PhpParser/Builder/TraitUseAdaptation.php | 148 + .../lib/PhpParser/Builder/Trait_.php | 60 + .../php-parser/lib/PhpParser/Builder/Use_.php | 49 + .../lib/PhpParser/BuilderFactory.php | 360 + .../lib/PhpParser/BuilderHelpers.php | 285 + .../php-parser/lib/PhpParser/Comment.php | 239 + .../php-parser/lib/PhpParser/Comment/Doc.php | 7 + .../ConstExprEvaluationException.php | 6 + .../lib/PhpParser/ConstExprEvaluator.php | 226 + .../nikic/php-parser/lib/PhpParser/Error.php | 180 + .../php-parser/lib/PhpParser/ErrorHandler.php | 13 + .../lib/PhpParser/ErrorHandler/Collecting.php | 46 + .../lib/PhpParser/ErrorHandler/Throwing.php | 18 + .../lib/PhpParser/Internal/DiffElem.php | 27 + .../lib/PhpParser/Internal/Differ.php | 164 + .../Internal/PrintableNewAnonClassNode.php | 61 + .../lib/PhpParser/Internal/TokenStream.php | 281 + .../php-parser/lib/PhpParser/JsonDecoder.php | 103 + .../nikic/php-parser/lib/PhpParser/Lexer.php | 537 + .../lib/PhpParser/Lexer/Emulative.php | 244 + .../Lexer/TokenEmulator/AttributeEmulator.php | 56 + .../CoaleseEqualTokenEmulator.php | 47 + .../Lexer/TokenEmulator/EnumTokenEmulator.php | 31 + .../FlexibleDocStringEmulator.php | 76 + .../Lexer/TokenEmulator/FnTokenEmulator.php | 23 + .../Lexer/TokenEmulator/KeywordEmulator.php | 62 + .../TokenEmulator/MatchTokenEmulator.php | 23 + .../TokenEmulator/NullsafeTokenEmulator.php | 67 + .../NumericLiteralSeparatorEmulator.php | 105 + .../Lexer/TokenEmulator/ReverseEmulator.php | 36 + .../Lexer/TokenEmulator/TokenEmulator.php | 25 + .../php-parser/lib/PhpParser/NameContext.php | 285 + .../nikic/php-parser/lib/PhpParser/Node.php | 151 + .../php-parser/lib/PhpParser/Node/Arg.php | 45 + .../lib/PhpParser/Node/Attribute.php | 34 + .../lib/PhpParser/Node/AttributeGroup.php | 29 + .../php-parser/lib/PhpParser/Node/Const_.php | 37 + .../php-parser/lib/PhpParser/Node/Expr.php | 9 + .../lib/PhpParser/Node/Expr/ArrayDimFetch.php | 34 + .../lib/PhpParser/Node/Expr/ArrayItem.php | 41 + .../lib/PhpParser/Node/Expr/Array_.php | 34 + .../lib/PhpParser/Node/Expr/ArrowFunction.php | 79 + .../lib/PhpParser/Node/Expr/Assign.php | 34 + .../lib/PhpParser/Node/Expr/AssignOp.php | 30 + .../Node/Expr/AssignOp/BitwiseAnd.php | 12 + .../Node/Expr/AssignOp/BitwiseOr.php | 12 + .../Node/Expr/AssignOp/BitwiseXor.php | 12 + .../PhpParser/Node/Expr/AssignOp/Coalesce.php | 12 + .../PhpParser/Node/Expr/AssignOp/Concat.php | 12 + .../lib/PhpParser/Node/Expr/AssignOp/Div.php | 12 + .../PhpParser/Node/Expr/AssignOp/Minus.php | 12 + .../lib/PhpParser/Node/Expr/AssignOp/Mod.php | 12 + .../lib/PhpParser/Node/Expr/AssignOp/Mul.php | 12 + .../lib/PhpParser/Node/Expr/AssignOp/Plus.php | 12 + .../lib/PhpParser/Node/Expr/AssignOp/Pow.php | 12 + .../Node/Expr/AssignOp/ShiftLeft.php | 12 + .../Node/Expr/AssignOp/ShiftRight.php | 12 + .../lib/PhpParser/Node/Expr/AssignRef.php | 34 + .../lib/PhpParser/Node/Expr/BinaryOp.php | 40 + .../Node/Expr/BinaryOp/BitwiseAnd.php | 16 + .../Node/Expr/BinaryOp/BitwiseOr.php | 16 + .../Node/Expr/BinaryOp/BitwiseXor.php | 16 + .../Node/Expr/BinaryOp/BooleanAnd.php | 16 + .../Node/Expr/BinaryOp/BooleanOr.php | 16 + .../PhpParser/Node/Expr/BinaryOp/Coalesce.php | 16 + .../PhpParser/Node/Expr/BinaryOp/Concat.php | 16 + .../lib/PhpParser/Node/Expr/BinaryOp/Div.php | 16 + .../PhpParser/Node/Expr/BinaryOp/Equal.php | 16 + .../PhpParser/Node/Expr/BinaryOp/Greater.php | 16 + .../Node/Expr/BinaryOp/GreaterOrEqual.php | 16 + .../Node/Expr/BinaryOp/Identical.php | 16 + .../Node/Expr/BinaryOp/LogicalAnd.php | 16 + .../Node/Expr/BinaryOp/LogicalOr.php | 16 + .../Node/Expr/BinaryOp/LogicalXor.php | 16 + .../PhpParser/Node/Expr/BinaryOp/Minus.php | 16 + .../lib/PhpParser/Node/Expr/BinaryOp/Mod.php | 16 + .../lib/PhpParser/Node/Expr/BinaryOp/Mul.php | 16 + .../PhpParser/Node/Expr/BinaryOp/NotEqual.php | 16 + .../Node/Expr/BinaryOp/NotIdentical.php | 16 + .../lib/PhpParser/Node/Expr/BinaryOp/Plus.php | 16 + .../lib/PhpParser/Node/Expr/BinaryOp/Pow.php | 16 + .../Node/Expr/BinaryOp/ShiftLeft.php | 16 + .../Node/Expr/BinaryOp/ShiftRight.php | 16 + .../PhpParser/Node/Expr/BinaryOp/Smaller.php | 16 + .../Node/Expr/BinaryOp/SmallerOrEqual.php | 16 + .../Node/Expr/BinaryOp/Spaceship.php | 16 + .../lib/PhpParser/Node/Expr/BitwiseNot.php | 30 + .../lib/PhpParser/Node/Expr/BooleanNot.php | 30 + .../lib/PhpParser/Node/Expr/Cast.php | 26 + .../lib/PhpParser/Node/Expr/Cast/Array_.php | 12 + .../lib/PhpParser/Node/Expr/Cast/Bool_.php | 12 + .../lib/PhpParser/Node/Expr/Cast/Double.php | 17 + .../lib/PhpParser/Node/Expr/Cast/Int_.php | 12 + .../lib/PhpParser/Node/Expr/Cast/Object_.php | 12 + .../lib/PhpParser/Node/Expr/Cast/String_.php | 12 + .../lib/PhpParser/Node/Expr/Cast/Unset_.php | 12 + .../PhpParser/Node/Expr/ClassConstFetch.php | 36 + .../lib/PhpParser/Node/Expr/Clone_.php | 30 + .../lib/PhpParser/Node/Expr/Closure.php | 79 + .../lib/PhpParser/Node/Expr/ClosureUse.php | 34 + .../lib/PhpParser/Node/Expr/ConstFetch.php | 31 + .../lib/PhpParser/Node/Expr/Empty_.php | 30 + .../lib/PhpParser/Node/Expr/Error.php | 31 + .../lib/PhpParser/Node/Expr/ErrorSuppress.php | 30 + .../lib/PhpParser/Node/Expr/Eval_.php | 30 + .../lib/PhpParser/Node/Expr/Exit_.php | 34 + .../lib/PhpParser/Node/Expr/FuncCall.php | 35 + .../lib/PhpParser/Node/Expr/Include_.php | 39 + .../lib/PhpParser/Node/Expr/Instanceof_.php | 35 + .../lib/PhpParser/Node/Expr/Isset_.php | 30 + .../lib/PhpParser/Node/Expr/List_.php | 30 + .../lib/PhpParser/Node/Expr/Match_.php | 31 + .../lib/PhpParser/Node/Expr/MethodCall.php | 40 + .../lib/PhpParser/Node/Expr/New_.php | 35 + .../Node/Expr/NullsafeMethodCall.php | 40 + .../Node/Expr/NullsafePropertyFetch.php | 35 + .../lib/PhpParser/Node/Expr/PostDec.php | 30 + .../lib/PhpParser/Node/Expr/PostInc.php | 30 + .../lib/PhpParser/Node/Expr/PreDec.php | 30 + .../lib/PhpParser/Node/Expr/PreInc.php | 30 + .../lib/PhpParser/Node/Expr/Print_.php | 30 + .../lib/PhpParser/Node/Expr/PropertyFetch.php | 35 + .../lib/PhpParser/Node/Expr/ShellExec.php | 30 + .../lib/PhpParser/Node/Expr/StaticCall.php | 40 + .../Node/Expr/StaticPropertyFetch.php | 36 + .../lib/PhpParser/Node/Expr/Ternary.php | 38 + .../lib/PhpParser/Node/Expr/Throw_.php | 30 + .../lib/PhpParser/Node/Expr/UnaryMinus.php | 30 + .../lib/PhpParser/Node/Expr/UnaryPlus.php | 30 + .../lib/PhpParser/Node/Expr/Variable.php | 30 + .../lib/PhpParser/Node/Expr/YieldFrom.php | 30 + .../lib/PhpParser/Node/Expr/Yield_.php | 34 + .../lib/PhpParser/Node/FunctionLike.php | 43 + .../lib/PhpParser/Node/Identifier.php | 75 + .../lib/PhpParser/Node/MatchArm.php | 31 + .../php-parser/lib/PhpParser/Node/Name.php | 242 + .../PhpParser/Node/Name/FullyQualified.php | 50 + .../lib/PhpParser/Node/Name/Relative.php | 50 + .../lib/PhpParser/Node/NullableType.php | 30 + .../php-parser/lib/PhpParser/Node/Param.php | 60 + .../php-parser/lib/PhpParser/Node/Scalar.php | 7 + .../lib/PhpParser/Node/Scalar/DNumber.php | 70 + .../lib/PhpParser/Node/Scalar/Encapsed.php | 31 + .../Node/Scalar/EncapsedStringPart.php | 30 + .../lib/PhpParser/Node/Scalar/LNumber.php | 73 + .../lib/PhpParser/Node/Scalar/MagicConst.php | 28 + .../Node/Scalar/MagicConst/Class_.php | 16 + .../PhpParser/Node/Scalar/MagicConst/Dir.php | 16 + .../PhpParser/Node/Scalar/MagicConst/File.php | 16 + .../Node/Scalar/MagicConst/Function_.php | 16 + .../PhpParser/Node/Scalar/MagicConst/Line.php | 16 + .../Node/Scalar/MagicConst/Method.php | 16 + .../Node/Scalar/MagicConst/Namespace_.php | 16 + .../Node/Scalar/MagicConst/Trait_.php | 16 + .../lib/PhpParser/Node/Scalar/String_.php | 141 + .../php-parser/lib/PhpParser/Node/Stmt.php | 9 + .../lib/PhpParser/Node/Stmt/Break_.php | 30 + .../lib/PhpParser/Node/Stmt/Case_.php | 34 + .../lib/PhpParser/Node/Stmt/Catch_.php | 41 + .../lib/PhpParser/Node/Stmt/ClassConst.php | 71 + .../lib/PhpParser/Node/Stmt/ClassLike.php | 109 + .../lib/PhpParser/Node/Stmt/ClassMethod.php | 159 + .../lib/PhpParser/Node/Stmt/Class_.php | 107 + .../lib/PhpParser/Node/Stmt/Const_.php | 30 + .../lib/PhpParser/Node/Stmt/Continue_.php | 30 + .../PhpParser/Node/Stmt/DeclareDeclare.php | 34 + .../lib/PhpParser/Node/Stmt/Declare_.php | 34 + .../lib/PhpParser/Node/Stmt/Do_.php | 34 + .../lib/PhpParser/Node/Stmt/Echo_.php | 30 + .../lib/PhpParser/Node/Stmt/ElseIf_.php | 34 + .../lib/PhpParser/Node/Stmt/Else_.php | 30 + .../lib/PhpParser/Node/Stmt/EnumCase.php | 37 + .../lib/PhpParser/Node/Stmt/Enum_.php | 40 + .../lib/PhpParser/Node/Stmt/Expression.php | 33 + .../lib/PhpParser/Node/Stmt/Finally_.php | 30 + .../lib/PhpParser/Node/Stmt/For_.php | 43 + .../lib/PhpParser/Node/Stmt/Foreach_.php | 47 + .../lib/PhpParser/Node/Stmt/Function_.php | 77 + .../lib/PhpParser/Node/Stmt/Global_.php | 30 + .../lib/PhpParser/Node/Stmt/Goto_.php | 31 + .../lib/PhpParser/Node/Stmt/GroupUse.php | 39 + .../lib/PhpParser/Node/Stmt/HaltCompiler.php | 30 + .../lib/PhpParser/Node/Stmt/If_.php | 43 + .../lib/PhpParser/Node/Stmt/InlineHTML.php | 30 + .../lib/PhpParser/Node/Stmt/Interface_.php | 37 + .../lib/PhpParser/Node/Stmt/Label.php | 31 + .../lib/PhpParser/Node/Stmt/Namespace_.php | 38 + .../lib/PhpParser/Node/Stmt/Nop.php | 17 + .../lib/PhpParser/Node/Stmt/Property.php | 83 + .../PhpParser/Node/Stmt/PropertyProperty.php | 34 + .../lib/PhpParser/Node/Stmt/Return_.php | 30 + .../lib/PhpParser/Node/Stmt/StaticVar.php | 37 + .../lib/PhpParser/Node/Stmt/Static_.php | 30 + .../lib/PhpParser/Node/Stmt/Switch_.php | 34 + .../lib/PhpParser/Node/Stmt/Throw_.php | 30 + .../lib/PhpParser/Node/Stmt/TraitUse.php | 34 + .../Node/Stmt/TraitUseAdaptation.php | 13 + .../Node/Stmt/TraitUseAdaptation/Alias.php | 38 + .../Stmt/TraitUseAdaptation/Precedence.php | 34 + .../lib/PhpParser/Node/Stmt/Trait_.php | 32 + .../lib/PhpParser/Node/Stmt/TryCatch.php | 38 + .../lib/PhpParser/Node/Stmt/Unset_.php | 30 + .../lib/PhpParser/Node/Stmt/UseUse.php | 52 + .../lib/PhpParser/Node/Stmt/Use_.php | 47 + .../lib/PhpParser/Node/Stmt/While_.php | 34 + .../lib/PhpParser/Node/UnionType.php | 30 + .../lib/PhpParser/Node/VarLikeIdentifier.php | 17 + .../php-parser/lib/PhpParser/NodeAbstract.php | 178 + .../php-parser/lib/PhpParser/NodeDumper.php | 203 + .../php-parser/lib/PhpParser/NodeFinder.php | 81 + .../lib/PhpParser/NodeTraverser.php | 291 + .../lib/PhpParser/NodeTraverserInterface.php | 29 + .../php-parser/lib/PhpParser/NodeVisitor.php | 72 + .../PhpParser/NodeVisitor/CloningVisitor.php | 20 + .../PhpParser/NodeVisitor/FindingVisitor.php | 48 + .../NodeVisitor/FirstFindingVisitor.php | 50 + .../PhpParser/NodeVisitor/NameResolver.php | 246 + .../NodeVisitor/NodeConnectingVisitor.php | 52 + .../NodeVisitor/ParentConnectingVisitor.php | 41 + .../lib/PhpParser/NodeVisitorAbstract.php | 25 + .../nikic/php-parser/lib/PhpParser/Parser.php | 18 + .../lib/PhpParser/Parser/Multiple.php | 55 + .../php-parser/lib/PhpParser/Parser/Php5.php | 2630 ++ .../php-parser/lib/PhpParser/Parser/Php7.php | 2746 ++ .../lib/PhpParser/Parser/Tokens.php | 145 + .../lib/PhpParser/ParserAbstract.php | 1023 + .../lib/PhpParser/ParserFactory.php | 44 + .../lib/PhpParser/PrettyPrinter/Standard.php | 1096 + .../lib/PhpParser/PrettyPrinterAbstract.php | 1499 + .../nunomaduro/collision/.github/FUNDING.yml | 5 - vendor/nunomaduro/collision/.php_cs | 29 - vendor/nunomaduro/collision/README.md | 22 +- vendor/nunomaduro/collision/composer.json | 32 +- vendor/nunomaduro/collision/phpstan.neon.dist | 19 - vendor/nunomaduro/collision/phpunit.xml.dist | 28 - .../Laravel/CollisionServiceProvider.php | 15 +- .../Adapters/Laravel/Commands/TestCommand.php | 213 +- .../src/Adapters/Laravel/ExceptionHandler.php | 17 +- .../Exceptions/RequirementsException.php | 16 + .../Laravel/IgnitionSolutionsRepository.php | 17 +- .../src/Adapters/Laravel/Inspector.php | 8 +- .../src/Adapters/Phpunit/ConfigureIO.php | 2 + .../src/Adapters/Phpunit/Printer.php | 263 +- .../src/Adapters/Phpunit/PrinterContents.php | 224 - .../collision/src/Adapters/Phpunit/State.php | 44 +- .../collision/src/Adapters/Phpunit/Style.php | 174 +- .../src/Adapters/Phpunit/TestResult.php | 92 +- .../collision/src/Adapters/Phpunit/Timer.php | 9 +- .../collision/src/ArgumentFormatter.php | 19 +- .../nunomaduro/collision/src/ConsoleColor.php | 48 +- .../Phpunit/HasPrintableTestCaseName.php | 9 +- .../Contracts/Adapters/Phpunit/Listener.php | 13 +- .../src/Contracts/ArgumentFormatter.php | 13 +- .../collision/src/Contracts/Handler.php | 13 +- .../collision/src/Contracts/Highlighter.php | 13 +- .../collision/src/Contracts/Provider.php | 13 +- .../src/Contracts/RenderlessEditor.php | 12 + .../src/Contracts/RenderlessTrace.php | 12 + .../src/Contracts/SolutionsRepository.php | 13 +- .../collision/src/Contracts/Writer.php | 6 +- .../src/Exceptions/InvalidStyleException.php | 14 + .../src/Exceptions/ShouldNotHappen.php | 18 +- vendor/nunomaduro/collision/src/Handler.php | 15 +- .../nunomaduro/collision/src/Highlighter.php | 158 +- vendor/nunomaduro/collision/src/Provider.php | 15 +- .../NullSolutionsRepository.php | 15 +- vendor/nunomaduro/collision/src/Writer.php | 56 +- .../phpunit/php-code-coverage/.gitattributes | 3 - .../php-code-coverage/.github/CONTRIBUTING.md | 1 - .../php-code-coverage/.github/FUNDING.yml | 1 - .../.github/ISSUE_TEMPLATE.md | 18 - vendor/phpunit/php-code-coverage/.gitignore | 7 - vendor/phpunit/php-code-coverage/.php_cs.dist | 197 - vendor/phpunit/php-code-coverage/.travis.yml | 60 - vendor/phpunit/php-code-coverage/ChangeLog.md | 235 +- vendor/phpunit/php-code-coverage/LICENSE | 2 +- vendor/phpunit/php-code-coverage/README.md | 38 +- vendor/phpunit/php-code-coverage/build.xml | 30 - .../phpunit/php-code-coverage/composer.json | 29 +- vendor/phpunit/php-code-coverage/phive.xml | 4 - vendor/phpunit/php-code-coverage/phpunit.xml | 21 - .../php-code-coverage/src/CodeCoverage.php | 915 +- .../php-code-coverage/src/CrapIndex.php | 55 + .../php-code-coverage/src/Directory.php | 37 + .../php-code-coverage/src/Driver/Driver.php | 138 +- .../php-code-coverage/src/Driver/PCOV.php | 45 - .../src/Driver/PcovDriver.php | 62 + .../Driver/{PHPDBG.php => PhpdbgDriver.php} | 67 +- .../php-code-coverage/src/Driver/Selector.php | 79 + .../php-code-coverage/src/Driver/Xdebug.php | 123 - .../src/Driver/Xdebug2Driver.php | 128 + .../src/Driver/Xdebug3Driver.php | 119 + ...hAndPathCoverageNotSupportedException.php} | 9 +- ...eadCodeDetectionNotSupportedException.php} | 9 +- .../DirectoryCouldNotBeCreatedException.php | 16 + .../src/Exception/Exception.php | 9 +- .../Exception/InvalidArgumentException.php | 24 +- ...NoCodeCoverageDriverAvailableException.php | 20 + ...hPathCoverageSupportAvailableException.php | 20 + .../src/Exception/ParserException.php | 16 + .../PathExistsButIsNotDirectoryException.php | 22 + .../Exception/PcovNotAvailableException.php | 21 + .../Exception/PhpdbgNotAvailableException.php | 21 + .../src/Exception/ReflectionException.php | 16 + .../ReportAlreadyFinalizedException.php | 20 + ...ticAnalysisCacheNotConfiguredException.php | 16 + .../src/Exception/TestIdMissingException.php | 20 + .../UnintentionallyCoveredCodeException.php | 11 +- .../WriteOperationFailedException.php | 22 + .../Exception/WrongXdebugVersionException.php | 17 + .../Exception/Xdebug2NotEnabledException.php | 21 + .../Exception/Xdebug3NotEnabledException.php | 21 + .../Exception/XdebugNotAvailableException.php | 21 + ...{RuntimeException.php => XmlException.php} | 6 +- .../phpunit/php-code-coverage/src/Filter.php | 150 +- .../src/Node/AbstractNode.php | 303 +- .../php-code-coverage/src/Node/Builder.php | 121 +- .../php-code-coverage/src/Node/Directory.php | 243 +- .../php-code-coverage/src/Node/File.php | 538 +- .../php-code-coverage/src/Node/Iterator.php | 15 +- .../php-code-coverage/src/Percentage.php | 66 + .../src/ProcessedCodeCoverageData.php | 255 + .../src/RawCodeCoverageData.php | 227 + .../php-code-coverage/src/Report/Clover.php | 131 +- .../src/Report/Cobertura.php | 304 + .../php-code-coverage/src/Report/Crap4j.php | 72 +- .../src/Report/Html/Facade.php | 107 +- .../src/Report/Html/Renderer.php | 198 +- .../src/Report/Html/Renderer/Dashboard.php | 103 +- .../src/Report/Html/Renderer/Directory.php | 91 +- .../src/Report/Html/Renderer/File.php | 1136 +- .../Html/Renderer/Template/branches.html.dist | 9 + .../Template/coverage_bar_branch.html.dist | 5 + .../Renderer/Template/css/bootstrap.min.css | 8 +- .../Html/Renderer/Template/css/style.css | 9 +- .../Template/dashboard_branch.html.dist} | 38 +- .../Template/directory_branch.html.dist | 62 + .../Template/directory_item_branch.html.dist | 19 + .../Html/Renderer/Template/file.html.dist | 11 +- .../Renderer/Template/file_branch.html.dist | 67 + .../Template/file_item_branch.html.dist | 20 + .../Renderer/Template/js/bootstrap.min.js | 6 +- .../Html/Renderer/Template/js/jquery.min.js | 4 +- .../Html/Renderer/Template/line.html.dist | 1 + .../Html/Renderer/Template/lines.html.dist | 5 + .../Template/method_item_branch.html.dist | 17 + .../Html/Renderer/Template/paths.html.dist | 9 + .../php-code-coverage/src/Report/PHP.php | 55 +- .../php-code-coverage/src/Report/Text.php | 248 +- .../src/Report/Xml/BuildInformation.php | 27 +- .../src/Report/Xml/Coverage.php | 21 +- .../src/Report/Xml/Directory.php | 5 +- .../src/Report/Xml/Facade.php | 194 +- .../php-code-coverage/src/Report/Xml/File.php | 22 +- .../src/Report/Xml/Method.php | 11 +- .../php-code-coverage/src/Report/Xml/Node.php | 34 +- .../src/Report/Xml/Project.php | 35 +- .../src/Report/Xml/Report.php | 49 +- .../src/Report/Xml/Source.php | 10 +- .../src/Report/Xml/Tests.php | 9 +- .../src/Report/Xml/Totals.php | 36 +- .../php-code-coverage/src/Report/Xml/Unit.php | 33 +- .../src/StaticAnalysis/Cache.php | 90 + .../src/StaticAnalysis/CacheWarmer.php | 38 + .../CachingCoveredFileAnalyser.php | 99 + .../CachingUncoveredFileAnalyser.php | 41 + .../StaticAnalysis/CodeUnitFindingVisitor.php | 293 + .../StaticAnalysis/CoveredFileAnalyser.php | 28 + .../ExecutableLinesFindingVisitor.php | 91 + .../IgnoredLinesFindingVisitor.php | 113 + .../ParsingCoveredFileAnalyser.php | 226 + .../ParsingUncoveredFileAnalyser.php | 51 + .../StaticAnalysis/UncoveredFileAnalyser.php | 18 + vendor/phpunit/php-code-coverage/src/Util.php | 40 - .../phpunit/php-code-coverage/src/Version.php | 6 +- .../php-code-coverage/tests/TestCase.php | 395 - .../tests/_files/BankAccount-clover.xml | 26 - .../tests/_files/BankAccount-crap4j.xml | 59 - .../tests/_files/BankAccount-text.txt | 12 - .../tests/_files/BankAccount.php | 33 - .../tests/_files/BankAccountTest.php | 66 - .../_files/CoverageClassExtendedTest.php | 14 - .../tests/_files/CoverageClassTest.php | 14 - .../CoverageFunctionParenthesesTest.php | 13 - ...erageFunctionParenthesesWhitespaceTest.php | 13 - .../tests/_files/CoverageFunctionTest.php | 13 - .../CoverageMethodOneLineAnnotationTest.php | 12 - .../_files/CoverageMethodParenthesesTest.php | 14 - ...overageMethodParenthesesWhitespaceTest.php | 14 - .../tests/_files/CoverageMethodTest.php | 14 - .../tests/_files/CoverageNoneTest.php | 11 - .../tests/_files/CoverageNotPrivateTest.php | 14 - .../tests/_files/CoverageNotProtectedTest.php | 14 - .../tests/_files/CoverageNotPublicTest.php | 14 - .../tests/_files/CoverageNothingTest.php | 15 - .../tests/_files/CoveragePrivateTest.php | 14 - .../tests/_files/CoverageProtectedTest.php | 14 - .../tests/_files/CoveragePublicTest.php | 14 - .../CoverageTwoDefaultClassAnnotations.php | 17 - .../tests/_files/CoveredClass.php | 36 - .../tests/_files/CoveredFunction.php | 4 - .../php-code-coverage/tests/_files/Crash.php | 2 - .../NamespaceCoverageClassExtendedTest.php | 14 - .../_files/NamespaceCoverageClassTest.php | 14 - ...NamespaceCoverageCoversClassPublicTest.php | 17 - .../NamespaceCoverageCoversClassTest.php | 22 - .../_files/NamespaceCoverageMethodTest.php | 14 - .../NamespaceCoverageNotPrivateTest.php | 14 - .../NamespaceCoverageNotProtectedTest.php | 14 - .../_files/NamespaceCoverageNotPublicTest.php | 14 - .../_files/NamespaceCoveragePrivateTest.php | 14 - .../_files/NamespaceCoverageProtectedTest.php | 14 - .../_files/NamespaceCoveragePublicTest.php | 14 - .../tests/_files/NamespaceCoveredClass.php | 38 - .../_files/NotExistingCoveredElementTest.php | 26 - .../BankAccount.php.html | 249 - .../CoverageForBankAccount/dashboard.html | 287 - .../HTML/CoverageForBankAccount/index.html | 118 - .../dashboard.html | 285 - .../index.html | 118 - ...with_class_and_anonymous_function.php.html | 172 - .../index.html | 108 - .../source_with_ignore.php.html | 196 - .../BankAccount.php.xml | 262 - .../XML/CoverageForBankAccount/index.xml | 33 - .../index.xml | 30 - ..._with_class_and_anonymous_function.php.xml | 161 - .../CoverageForFileWithIgnoredLines/index.xml | 30 - .../source_with_ignore.php.xml | 187 - .../class-with-anonymous-function-clover.xml | 21 - .../class-with-anonymous-function-crap4j.xml | 26 - .../class-with-anonymous-function-text.txt | 12 - .../tests/_files/ignored-lines-clover.xml | 17 - .../tests/_files/ignored-lines-crap4j.xml | 37 - .../tests/_files/ignored-lines-text.txt | 10 - ...urce_with_class_and_anonymous_function.php | 19 - .../tests/_files/source_with_ignore.php | 37 - .../tests/_files/source_with_namespace.php | 20 - .../source_with_oneline_annotations.php | 36 - .../_files/source_with_use_statements.php | 23 - .../tests/_files/source_without_ignore.php | 4 - .../tests/_files/source_without_namespace.php | 18 - .../php-code-coverage/tests/bootstrap.php | 7 - .../tests/tests/BuilderTest.php | 246 - .../tests/tests/CloverTest.php | 48 - .../tests/tests/CodeCoverageTest.php | 359 - .../tests/tests/Crap4jTest.php | 48 - ...nintentionallyCoveredCodeExceptionTest.php | 51 - .../tests/tests/FilterTest.php | 213 - .../tests/tests/HTMLTest.php | 102 - .../tests/tests/TextTest.php | 48 - .../tests/tests/UtilTest.php | 28 - .../php-code-coverage/tests/tests/XmlTest.php | 97 - .../phpunit/php-file-iterator/.gitattributes | 1 - .../php-file-iterator/.github/stale.yml | 40 - vendor/phpunit/php-file-iterator/.gitignore | 5 - vendor/phpunit/php-file-iterator/.php_cs.dist | 168 - vendor/phpunit/php-file-iterator/.travis.yml | 32 - vendor/phpunit/php-file-iterator/ChangeLog.md | 57 +- vendor/phpunit/php-file-iterator/LICENSE | 2 +- .../phpunit/php-file-iterator/composer.json | 14 +- vendor/phpunit/php-file-iterator/phpunit.xml | 21 - .../phpunit/php-file-iterator/src/Facade.php | 43 +- .../phpunit/php-file-iterator/src/Factory.php | 44 +- .../php-file-iterator/src/Iterator.php | 47 +- .../php-file-iterator/tests/FactoryTest.php | 50 - vendor/phpunit/php-invoker/ChangeLog.md | 48 + .../{php-token-stream => php-invoker}/LICENSE | 4 +- .../README.md | 10 +- vendor/phpunit/php-invoker/composer.json | 54 + vendor/phpunit/php-invoker/src/Invoker.php | 69 + .../php-invoker/src/exceptions/Exception.php} | 8 +- ...cessControlExtensionNotLoadedException.php | 16 + .../src/exceptions/TimeoutException.php | 16 + .../phpunit/php-text-template/.gitattributes | 1 - vendor/phpunit/php-text-template/.gitignore | 5 - .../php-text-template/.psalm/baseline.xml | 2 + .../php-text-template/.psalm/config.xml | 16 + vendor/phpunit/php-text-template/ChangeLog.md | 43 + vendor/phpunit/php-text-template/LICENSE | 4 +- vendor/phpunit/php-text-template/README.md | 12 +- .../phpunit/php-text-template/composer.json | 18 +- .../php-text-template/src/Template.php | 94 +- .../src/exceptions/Exception.php | 16 + .../exceptions/InvalidArgumentException.php | 14 + .../src/exceptions/RuntimeException.php | 16 + vendor/phpunit/php-timer/.gitattributes | 1 - vendor/phpunit/php-timer/.github/FUNDING.yml | 1 - vendor/phpunit/php-timer/.github/stale.yml | 40 - vendor/phpunit/php-timer/.gitignore | 5 - vendor/phpunit/php-timer/.php_cs.dist | 197 - vendor/phpunit/php-timer/.psalm/baseline.xml | 2 + vendor/phpunit/php-timer/.psalm/config.xml | 16 + vendor/phpunit/php-timer/.travis.yml | 23 - vendor/phpunit/php-timer/ChangeLog.md | 111 +- vendor/phpunit/php-timer/LICENSE | 2 +- vendor/phpunit/php-timer/README.md | 83 +- vendor/phpunit/php-timer/build.xml | 20 - vendor/phpunit/php-timer/composer.json | 9 +- vendor/phpunit/php-timer/phpunit.xml | 19 - vendor/phpunit/php-timer/src/Duration.php | 109 + .../php-timer/src/ResourceUsageFormatter.php | 73 + vendor/phpunit/php-timer/src/Timer.php | 92 +- .../src/{ => exceptions}/Exception.php | 4 +- .../exceptions/NoActiveTimerException.php} | 8 +- ...nceStartOfRequestNotAvailableException.php | 16 + vendor/phpunit/php-timer/tests/TimerTest.php | 134 - vendor/phpunit/php-token-stream/.gitignore | 7 - vendor/phpunit/php-token-stream/ChangeLog.md | 92 - .../phpunit/php-token-stream/src/Abstract.php | 12 - .../php-token-stream/src/Ampersand.php | 12 - .../phpunit/php-token-stream/src/AndEqual.php | 12 - vendor/phpunit/php-token-stream/src/Array.php | 12 - .../php-token-stream/src/ArrayCast.php | 12 - vendor/phpunit/php-token-stream/src/As.php | 12 - vendor/phpunit/php-token-stream/src/At.php | 12 - .../phpunit/php-token-stream/src/Backtick.php | 12 - .../php-token-stream/src/BadCharacter.php | 12 - .../phpunit/php-token-stream/src/BoolCast.php | 12 - .../php-token-stream/src/BooleanAnd.php | 12 - .../php-token-stream/src/BooleanOr.php | 12 - .../php-token-stream/src/CachingFactory.php | 42 - .../phpunit/php-token-stream/src/Callable.php | 12 - vendor/phpunit/php-token-stream/src/Caret.php | 12 - vendor/phpunit/php-token-stream/src/Case.php | 12 - vendor/phpunit/php-token-stream/src/Catch.php | 12 - .../php-token-stream/src/Character.php | 12 - vendor/phpunit/php-token-stream/src/Class.php | 62 - .../phpunit/php-token-stream/src/ClassC.php | 12 - .../src/ClassNameConstant.php | 12 - vendor/phpunit/php-token-stream/src/Clone.php | 12 - .../php-token-stream/src/CloseBracket.php | 12 - .../php-token-stream/src/CloseCurly.php | 12 - .../php-token-stream/src/CloseSquare.php | 12 - .../phpunit/php-token-stream/src/CloseTag.php | 12 - .../phpunit/php-token-stream/src/Coalesce.php | 12 - .../php-token-stream/src/CoalesceEqual.php | 12 - vendor/phpunit/php-token-stream/src/Colon.php | 12 - vendor/phpunit/php-token-stream/src/Comma.php | 12 - .../phpunit/php-token-stream/src/Comment.php | 12 - .../php-token-stream/src/ConcatEqual.php | 12 - vendor/phpunit/php-token-stream/src/Const.php | 12 - .../src/ConstantEncapsedString.php | 12 - .../phpunit/php-token-stream/src/Continue.php | 12 - .../php-token-stream/src/CurlyOpen.php | 12 - .../phpunit/php-token-stream/src/DNumber.php | 12 - vendor/phpunit/php-token-stream/src/Dec.php | 12 - .../phpunit/php-token-stream/src/Declare.php | 12 - .../phpunit/php-token-stream/src/Default.php | 12 - vendor/phpunit/php-token-stream/src/Dir.php | 12 - vendor/phpunit/php-token-stream/src/Div.php | 12 - .../phpunit/php-token-stream/src/DivEqual.php | 12 - vendor/phpunit/php-token-stream/src/Do.php | 12 - .../php-token-stream/src/DocComment.php | 12 - .../phpunit/php-token-stream/src/Dollar.php | 12 - .../src/DollarOpenCurlyBraces.php | 12 - vendor/phpunit/php-token-stream/src/Dot.php | 12 - .../php-token-stream/src/DoubleArrow.php | 12 - .../php-token-stream/src/DoubleCast.php | 12 - .../php-token-stream/src/DoubleColon.php | 12 - .../php-token-stream/src/DoubleQuotes.php | 12 - vendor/phpunit/php-token-stream/src/Echo.php | 12 - .../phpunit/php-token-stream/src/Ellipsis.php | 12 - vendor/phpunit/php-token-stream/src/Else.php | 12 - .../phpunit/php-token-stream/src/Elseif.php | 12 - vendor/phpunit/php-token-stream/src/Empty.php | 12 - .../src/EncapsedAndWhitespace.php | 12 - .../php-token-stream/src/EndHeredoc.php | 12 - .../php-token-stream/src/Enddeclare.php | 12 - .../phpunit/php-token-stream/src/Endfor.php | 12 - .../php-token-stream/src/Endforeach.php | 12 - vendor/phpunit/php-token-stream/src/Endif.php | 12 - .../php-token-stream/src/Endswitch.php | 12 - .../phpunit/php-token-stream/src/Endwhile.php | 12 - vendor/phpunit/php-token-stream/src/Equal.php | 12 - vendor/phpunit/php-token-stream/src/Eval.php | 12 - .../php-token-stream/src/ExclamationMark.php | 12 - vendor/phpunit/php-token-stream/src/Exit.php | 12 - .../phpunit/php-token-stream/src/Extends.php | 12 - vendor/phpunit/php-token-stream/src/File.php | 12 - vendor/phpunit/php-token-stream/src/Final.php | 12 - .../phpunit/php-token-stream/src/Finally.php | 12 - vendor/phpunit/php-token-stream/src/Fn.php | 12 - vendor/phpunit/php-token-stream/src/For.php | 12 - .../phpunit/php-token-stream/src/Foreach.php | 12 - vendor/phpunit/php-token-stream/src/FuncC.php | 12 - .../phpunit/php-token-stream/src/Function.php | 196 - .../phpunit/php-token-stream/src/Global.php | 12 - vendor/phpunit/php-token-stream/src/Goto.php | 12 - vendor/phpunit/php-token-stream/src/Gt.php | 12 - .../php-token-stream/src/HaltCompiler.php | 12 - vendor/phpunit/php-token-stream/src/If.php | 12 - .../php-token-stream/src/Implements.php | 12 - vendor/phpunit/php-token-stream/src/Inc.php | 12 - .../phpunit/php-token-stream/src/Include.php | 12 - .../php-token-stream/src/IncludeOnce.php | 12 - .../phpunit/php-token-stream/src/Includes.php | 57 - .../php-token-stream/src/InlineHtml.php | 12 - .../php-token-stream/src/Instanceof.php | 12 - .../php-token-stream/src/Insteadof.php | 12 - .../phpunit/php-token-stream/src/IntCast.php | 12 - .../php-token-stream/src/Interface.php | 166 - .../phpunit/php-token-stream/src/IsEqual.php | 12 - .../php-token-stream/src/IsGreaterOrEqual.php | 12 - .../php-token-stream/src/IsIdentical.php | 12 - .../php-token-stream/src/IsNotEqual.php | 12 - .../php-token-stream/src/IsNotIdentical.php | 12 - .../php-token-stream/src/IsSmallerOrEqual.php | 12 - vendor/phpunit/php-token-stream/src/Isset.php | 12 - vendor/phpunit/php-token-stream/src/Line.php | 12 - vendor/phpunit/php-token-stream/src/List.php | 12 - .../phpunit/php-token-stream/src/Lnumber.php | 12 - .../php-token-stream/src/LogicalAnd.php | 12 - .../php-token-stream/src/LogicalOr.php | 12 - .../php-token-stream/src/LogicalXor.php | 12 - vendor/phpunit/php-token-stream/src/Lt.php | 12 - .../phpunit/php-token-stream/src/MethodC.php | 12 - vendor/phpunit/php-token-stream/src/Minus.php | 12 - .../php-token-stream/src/MinusEqual.php | 12 - .../phpunit/php-token-stream/src/ModEqual.php | 12 - .../phpunit/php-token-stream/src/MulEqual.php | 12 - vendor/phpunit/php-token-stream/src/Mult.php | 12 - .../src/NameFullyQualified.php | 12 - .../php-token-stream/src/NameQualified.php | 12 - .../php-token-stream/src/NameRelative.php | 12 - .../php-token-stream/src/Namespace.php | 31 - vendor/phpunit/php-token-stream/src/New.php | 12 - vendor/phpunit/php-token-stream/src/NsC.php | 12 - .../php-token-stream/src/NsSeparator.php | 12 - .../php-token-stream/src/NumString.php | 12 - .../php-token-stream/src/ObjectCast.php | 12 - .../php-token-stream/src/ObjectOperator.php | 12 - .../php-token-stream/src/OpenBracket.php | 12 - .../php-token-stream/src/OpenCurly.php | 12 - .../php-token-stream/src/OpenSquare.php | 12 - .../phpunit/php-token-stream/src/OpenTag.php | 12 - .../php-token-stream/src/OpenTagWithEcho.php | 12 - .../phpunit/php-token-stream/src/OrEqual.php | 12 - .../src/PaamayimNekudotayim.php | 12 - .../phpunit/php-token-stream/src/Percent.php | 12 - vendor/phpunit/php-token-stream/src/Pipe.php | 12 - vendor/phpunit/php-token-stream/src/Plus.php | 12 - .../php-token-stream/src/PlusEqual.php | 12 - vendor/phpunit/php-token-stream/src/Pow.php | 12 - .../phpunit/php-token-stream/src/PowEqual.php | 12 - vendor/phpunit/php-token-stream/src/Print.php | 12 - .../phpunit/php-token-stream/src/Private.php | 12 - .../php-token-stream/src/Protected.php | 12 - .../phpunit/php-token-stream/src/Public.php | 12 - .../php-token-stream/src/QuestionMark.php | 12 - .../phpunit/php-token-stream/src/Require.php | 12 - .../php-token-stream/src/RequireOnce.php | 12 - .../phpunit/php-token-stream/src/Return.php | 12 - .../php-token-stream/src/Semicolon.php | 12 - vendor/phpunit/php-token-stream/src/Sl.php | 12 - .../phpunit/php-token-stream/src/SlEqual.php | 12 - .../php-token-stream/src/Spaceship.php | 12 - vendor/phpunit/php-token-stream/src/Sr.php | 12 - .../phpunit/php-token-stream/src/SrEqual.php | 12 - .../php-token-stream/src/StartHeredoc.php | 12 - .../phpunit/php-token-stream/src/Static.php | 12 - .../phpunit/php-token-stream/src/Stream.php | 658 - .../phpunit/php-token-stream/src/String.php | 12 - .../php-token-stream/src/StringCast.php | 12 - .../php-token-stream/src/StringVarname.php | 12 - .../phpunit/php-token-stream/src/Switch.php | 12 - vendor/phpunit/php-token-stream/src/Throw.php | 12 - vendor/phpunit/php-token-stream/src/Tilde.php | 12 - vendor/phpunit/php-token-stream/src/Token.php | 68 - .../php-token-stream/src/TokenWithScope.php | 107 - .../src/TokenWithScopeAndVisibility.php | 67 - vendor/phpunit/php-token-stream/src/Trait.php | 12 - .../phpunit/php-token-stream/src/TraitC.php | 12 - vendor/phpunit/php-token-stream/src/Try.php | 12 - vendor/phpunit/php-token-stream/src/Unset.php | 12 - .../php-token-stream/src/UnsetCast.php | 12 - vendor/phpunit/php-token-stream/src/Use.php | 12 - .../php-token-stream/src/UseFunction.php | 12 - vendor/phpunit/php-token-stream/src/Util.php | 18 - vendor/phpunit/php-token-stream/src/Var.php | 12 - .../phpunit/php-token-stream/src/Variable.php | 12 - vendor/phpunit/php-token-stream/src/While.php | 12 - .../php-token-stream/src/Whitespace.php | 12 - .../phpunit/php-token-stream/src/XorEqual.php | 12 - vendor/phpunit/php-token-stream/src/Yield.php | 12 - .../php-token-stream/src/YieldFrom.php | 12 - vendor/phpunit/php-token-stream/src/break.php | 12 - vendor/phpunit/phpunit/ChangeLog-9.5.md | 48 + vendor/phpunit/phpunit/README.md | 10 +- vendor/phpunit/phpunit/composer.json | 47 +- vendor/phpunit/phpunit/phpunit | 4 +- vendor/phpunit/phpunit/phpunit.xsd | 137 +- vendor/phpunit/phpunit/schema/8.5.xsd | 317 + vendor/phpunit/phpunit/schema/9.2.xsd | 317 + .../phpunit/phpunit/src/Framework/Assert.php | 1479 +- .../src/Framework/Assert/Functions.php | 1638 +- .../src/Framework/Constraint/ArraySubset.php | 135 - .../src/Framework/Constraint/Attribute.php | 79 - .../Constraint/{ => Boolean}/IsFalse.php | 2 +- .../Constraint/{ => Boolean}/IsTrue.php | 2 +- .../src/Framework/Constraint/Callback.php | 4 +- .../Constraint/{ => Cardinality}/Count.php | 20 +- .../{ => Cardinality}/GreaterThan.php | 3 +- .../Constraint/{ => Cardinality}/IsEmpty.php | 2 +- .../Constraint/{ => Cardinality}/LessThan.php | 3 +- .../Constraint/{ => Cardinality}/SameSize.php | 5 +- .../src/Framework/Constraint/Composite.php | 69 - .../src/Framework/Constraint/Constraint.php | 120 +- .../Constraint/{ => Equality}/IsEqual.php | 14 +- .../Equality/IsEqualCanonicalizing.php | 108 + .../Equality/IsEqualIgnoringCase.php | 108 + .../Constraint/Equality/IsEqualWithDelta.php | 100 + .../Constraint/{ => Exception}/Exception.php | 3 + .../{ => Exception}/ExceptionCode.php | 3 + .../{ => Exception}/ExceptionMessage.php | 3 + .../ExceptionMessageRegularExpression.php | 3 + .../{ => Filesystem}/DirectoryExists.php | 4 +- .../{ => Filesystem}/FileExists.php | 4 +- .../{ => Filesystem}/IsReadable.php | 4 +- .../{ => Filesystem}/IsWritable.php | 4 +- .../src/Framework/Constraint/IsAnything.php | 4 +- .../src/Framework/Constraint/IsIdentical.php | 14 +- .../src/Framework/Constraint/JsonMatches.php | 2 +- .../JsonMatchesErrorMessageProvider.php | 2 +- .../src/Framework/Constraint/LogicalAnd.php | 121 - .../src/Framework/Constraint/LogicalNot.php | 169 - .../src/Framework/Constraint/LogicalOr.php | 118 - .../src/Framework/Constraint/LogicalXor.php | 123 - .../Constraint/{ => Math}/IsFinite.php | 2 +- .../Constraint/{ => Math}/IsInfinite.php | 2 +- .../Framework/Constraint/{ => Math}/IsNan.php | 2 +- .../{ => Object}/ClassHasAttribute.php | 5 +- .../{ => Object}/ClassHasStaticAttribute.php | 5 +- .../Constraint/Object/ObjectEquals.php | 151 + .../{ => Object}/ObjectHasAttribute.php | 5 +- .../Constraint/Operator/BinaryOperator.php | 147 + .../Constraint/Operator/LogicalAnd.php | 51 + .../Constraint/Operator/LogicalNot.php | 135 + .../Constraint/Operator/LogicalOr.php | 51 + .../Constraint/Operator/LogicalXor.php | 62 + .../Constraint/Operator/Operator.php | 55 + .../Constraint/Operator/UnaryOperator.php | 140 + .../Constraint/{ => String}/IsJson.php | 4 +- .../{ => String}/RegularExpression.php | 8 +- .../{ => String}/StringContains.php | 28 +- .../{ => String}/StringEndsWith.php | 3 +- .../StringMatchesFormatDescription.php | 7 +- .../{ => String}/StringStartsWith.php | 3 +- .../{ => Traversable}/ArrayHasKey.php | 7 +- .../TraversableContains.php} | 38 +- .../Traversable/TraversableContainsEqual.php | 40 + .../TraversableContainsIdentical.php | 39 + .../TraversableContainsOnly.php | 10 +- .../Constraint/TraversableContains.php | 120 - .../Constraint/TraversableContainsEqual.php | 88 - .../Constraint/{ => Type}/IsInstanceOf.php | 5 +- .../Constraint/{ => Type}/IsNull.php | 2 +- .../Constraint/{ => Type}/IsType.php | 66 +- .../src/Framework/DataProviderTestSuite.php | 28 +- .../src/Framework/Error/Deprecated.php | 3 + .../phpunit/src/Framework/Error/Error.php | 3 + .../phpunit/src/Framework/Error/Notice.php | 3 + .../phpunit/src/Framework/Error/Warning.php | 3 + .../phpunit/src/Framework/ErrorTestCase.php | 66 + .../ActualValueIsNotAnObjectException.php | 32 + ...hodDoesNotAcceptParameterTypeException.php | 38 + ...dDoesNotDeclareBoolReturnTypeException.php | 37 + ...NotDeclareExactlyOneParameterException.php | 37 + ...odDoesNotDeclareParameterTypeException.php | 37 + .../ComparisonMethodDoesNotExistException.php | 37 + .../Match_.php => Exception/Error.php} | 16 +- .../src/Framework/ExceptionWrapper.php | 4 +- .../Framework/ExecutionOrderDependency.php | 203 + .../phpunit/src/Framework/IncompleteTest.php | 4 +- .../MockObject/Builder/InvocationMocker.php | 82 +- .../MockObject/Builder/InvocationStubber.php | 3 + .../MockObject/Builder/ParametersMatch.php | 12 +- .../MockObject/ConfigurableMethod.php | 2 +- .../CannotUseAddMethodsException.php | 29 + .../CannotUseOnlyMethodsException.php | 29 + .../Exception/ClassAlreadyExistsException.php | 28 + .../Exception/ClassIsFinalException.php | 28 + .../Exception/DuplicateMethodException.php | 32 + .../IncompatibleReturnValueException.php | 16 + .../Exception/InvalidMethodNameException.php | 28 + .../MatchBuilderNotFoundException.php | 28 + .../MatcherAlreadyRegisteredException.php | 28 + .../MethodCannotBeConfiguredException.php | 28 + .../MethodNameAlreadyConfiguredException.php | 21 + .../MethodNameNotConfiguredException.php | 21 + ...odParametersAlreadyConfiguredException.php | 21 + ...ConstructorInvocationRequiredException.php | 21 + .../Exception/ReflectionException.php | 19 + .../ReturnValueNotConfiguredException.php | 27 + .../SoapExtensionNotAvailableException.php | 23 + .../Exception/UnknownClassException.php | 28 + .../Exception/UnknownTraitException.php | 28 + .../Exception/UnknownTypeException.php | 28 + .../src/Framework/MockObject/Generator.php | 365 +- .../MockObject/Generator/mocked_method.tpl | 2 +- .../Generator/mocked_method_void.tpl | 2 +- .../MockObject/Generator/proxied_method.tpl | 2 +- .../Generator/proxied_method_void.tpl | 2 +- .../src/Framework/MockObject/Invocation.php | 33 +- .../MockObject/InvocationHandler.php | 21 +- .../src/Framework/MockObject/Matcher.php | 30 +- .../src/Framework/MockObject/MockBuilder.php | 59 +- .../src/Framework/MockObject/MockClass.php | 8 +- .../src/Framework/MockObject/MockMethod.php | 111 +- .../src/Framework/MockObject/MockObject.php | 2 + .../src/Framework/MockObject/MockTrait.php | 8 +- .../src/Framework/MockObject/MockType.php | 3 + .../MockObject/Rule/ConsecutiveParameters.php | 6 - .../MockObject/Rule/InvokedAtIndex.php | 5 +- .../Framework/MockObject/Rule/MethodName.php | 6 +- .../MockObject/Rule/ParametersRule.php | 3 + .../phpunit/src/Framework/MockObject/Stub.php | 2 + .../phpunit/src/Framework/Reorderable.php | 28 + .../phpunit/src/Framework/SkippedTest.php | 4 +- vendor/phpunit/phpunit/src/Framework/Test.php | 2 +- .../phpunit/src/Framework/TestBuilder.php | 6 +- .../phpunit/src/Framework/TestCase.php | 741 +- .../phpunit/src/Framework/TestFailure.php | 4 +- .../phpunit/src/Framework/TestListener.php | 1 + .../TestListenerDefaultImplementation.php | 1 + .../phpunit/src/Framework/TestResult.php | 229 +- .../phpunit/src/Framework/TestSuite.php | 322 +- .../phpunit/src/Runner/BaseTestRunner.php | 31 +- .../src/Runner/Extension/ExtensionHandler.php | 117 + .../src/Runner/Extension/PharLoader.php | 75 + .../phpunit/src/Runner/Filter/Factory.php | 13 +- .../src/Runner/Filter/NameFilterIterator.php | 3 +- .../Runner/Hook/AfterIncompleteTestHook.php | 3 + .../src/Runner/Hook/AfterLastTestHook.php | 3 + .../src/Runner/Hook/AfterRiskyTestHook.php | 3 + .../src/Runner/Hook/AfterSkippedTestHook.php | 3 + .../Runner/Hook/AfterSuccessfulTestHook.php | 3 + .../src/Runner/Hook/AfterTestErrorHook.php | 3 + .../src/Runner/Hook/AfterTestFailureHook.php | 3 + .../phpunit/src/Runner/Hook/AfterTestHook.php | 3 + .../src/Runner/Hook/AfterTestWarningHook.php | 3 + .../src/Runner/Hook/BeforeFirstTestHook.php | 3 + .../src/Runner/Hook/BeforeTestHook.php | 3 + .../phpunit/phpunit/src/Runner/Hook/Hook.php | 3 + .../phpunit/src/Runner/Hook/TestHook.php | 3 + .../phpunit/src/Runner/PhptTestCase.php | 97 +- .../src/Runner/StandardTestSuiteLoader.php | 139 +- .../phpunit/src/Runner/TestSuiteLoader.php | 6 +- .../phpunit/src/Runner/TestSuiteSorter.php | 119 +- vendor/phpunit/phpunit/src/Runner/Version.php | 14 +- .../src/TextUI/CliArguments/Builder.php | 887 + .../src/TextUI/CliArguments/Configuration.php | 2107 ++ .../src/TextUI/CliArguments/Exception.php | 19 + .../src/TextUI/CliArguments/Mapper.php | 365 + vendor/phpunit/phpunit/src/TextUI/Command.php | 1165 +- .../src/TextUI/DefaultResultPrinter.php | 592 + .../src/TextUI/Exception/Exception.php | 19 + .../TextUI/Exception/ReflectionException.php | 19 + .../src/TextUI/Exception/RuntimeException.php | 17 + .../TestDirectoryNotFoundException.php | 29 + .../Exception/TestFileNotFoundException.php | 29 + vendor/phpunit/phpunit/src/TextUI/Help.php | 35 +- .../phpunit/src/TextUI/ResultPrinter.php | 573 +- .../phpunit/phpunit/src/TextUI/TestRunner.php | 1151 +- .../phpunit/src/TextUI/TestSuiteMapper.php | 103 + .../CodeCoverage/CodeCoverage.php | 362 + .../CodeCoverage/Filter/Directory.php | 65 + .../Filter/DirectoryCollection.php | 57 + .../Filter/DirectoryCollectionIterator.php | 66 + .../CodeCoverage/FilterMapper.php | 45 + .../CodeCoverage/Report/Clover.php | 34 + .../CodeCoverage/Report/Cobertura.php | 34 + .../CodeCoverage/Report/Crap4j.php | 45 + .../CodeCoverage/Report/Html.php | 56 + .../CodeCoverage/Report/Php.php | 34 + .../CodeCoverage/Report/Text.php | 56 + .../CodeCoverage/Report/Xml.php | 34 + .../TextUI/XmlConfiguration/Configuration.php | 151 + .../src/TextUI/XmlConfiguration/Exception.php | 19 + .../XmlConfiguration/Filesystem/Directory.php | 32 + .../Filesystem/DirectoryCollection.php | 62 + .../DirectoryCollectionIterator.php | 66 + .../XmlConfiguration/Filesystem/File.php | 32 + .../Filesystem/FileCollection.php | 62 + .../Filesystem/FileCollectionIterator.php | 66 + .../XmlConfiguration/Generator.php} | 20 +- .../TextUI/XmlConfiguration/Group/Group.php | 32 + .../Group/GroupCollection.php | 69 + .../Group/GroupCollectionIterator.php | 66 + .../TextUI/XmlConfiguration/Group/Groups.php | 53 + .../src/TextUI/XmlConfiguration/Loader.php | 1264 + .../TextUI/XmlConfiguration/Logging/Junit.php | 34 + .../XmlConfiguration/Logging/Logging.php | 146 + .../XmlConfiguration/Logging/TeamCity.php | 34 + .../XmlConfiguration/Logging/TestDox/Html.php | 34 + .../XmlConfiguration/Logging/TestDox/Text.php | 34 + .../XmlConfiguration/Logging/TestDox/Xml.php | 34 + .../TextUI/XmlConfiguration/Logging/Text.php | 34 + .../Migration/MigrationBuilder.php | 73 + .../Migration/MigrationBuilderException.php | 19 + .../Migration/MigrationException.php | 19 + .../Migration/Migrations/ConvertLogTypes.php | 53 + .../Migrations/CoverageCloverToReport.php | 31 + .../Migrations/CoverageCrap4jToReport.php | 33 + .../Migrations/CoverageHtmlToReport.php | 33 + .../Migrations/CoveragePhpToReport.php | 31 + .../Migrations/CoverageTextToReport.php | 33 + .../Migrations/CoverageXmlToReport.php | 31 + .../Migrations/IntroduceCoverageElement.php | 28 + .../Migrations/LogToReportMigration.php | 79 + .../Migration/Migrations/Migration.php | 20 + ...ttributesFromFilterWhitelistToCoverage.php | 51 + .../MoveAttributesFromRootToCoverage.php | 47 + .../MoveWhitelistDirectoriesToCoverage.php | 49 + .../MoveWhitelistExcludesToCoverage.php | 70 + .../Migrations/RemoveCacheTokensAttribute.php | 27 + .../Migrations/RemoveEmptyFilter.php | 54 + .../Migration/Migrations/RemoveLogTypes.php | 37 + .../Migrations/UpdateSchemaLocationTo93.php | 27 + .../XmlConfiguration/Migration/Migrator.php | 57 + .../TextUI/XmlConfiguration/PHP/Constant.php | 43 + .../PHP/ConstantCollection.php | 57 + .../PHP/ConstantCollectionIterator.php | 66 + .../XmlConfiguration/PHP/IniSetting.php | 43 + .../PHP/IniSettingCollection.php | 57 + .../PHP/IniSettingCollectionIterator.php | 66 + .../src/TextUI/XmlConfiguration/PHP/Php.php | 142 + .../XmlConfiguration/PHP/PhpHandler.php | 121 + .../TextUI/XmlConfiguration/PHP/Variable.php | 54 + .../PHP/VariableCollection.php | 57 + .../PHP/VariableCollectionIterator.php | 66 + .../XmlConfiguration/PHPUnit/Extension.php | 71 + .../PHPUnit/ExtensionCollection.php | 50 + .../PHPUnit/ExtensionCollectionIterator.php | 66 + .../XmlConfiguration/PHPUnit/PHPUnit.php | 714 + .../TestSuite/TestDirectory.php | 78 + .../TestSuite/TestDirectoryCollection.php | 62 + .../TestDirectoryCollectionIterator.php | 66 + .../XmlConfiguration/TestSuite/TestFile.php | 56 + .../TestSuite/TestFileCollection.php | 62 + .../TestSuite/TestFileCollectionIterator.php | 66 + .../XmlConfiguration/TestSuite/TestSuite.php | 65 + .../TestSuite/TestSuiteCollection.php | 62 + .../TestSuite/TestSuiteCollectionIterator.php | 66 + .../phpunit/src/Util/Annotation/DocBlock.php | 82 +- vendor/phpunit/phpunit/src/Util/Blacklist.php | 201 +- .../phpunit/src/Util/Configuration.php | 1231 - .../phpunit/phpunit/src/Util/ExcludeList.php | 261 + .../phpunit/phpunit/src/Util/FileLoader.php | 15 +- .../phpunit/phpunit/src/Util/Filesystem.php | 5 +- vendor/phpunit/phpunit/src/Util/Filter.php | 18 +- vendor/phpunit/phpunit/src/Util/Getopt.php | 197 - .../phpunit/phpunit/src/Util/GlobalState.php | 25 +- vendor/phpunit/phpunit/src/Util/Log/JUnit.php | 30 +- .../phpunit/phpunit/src/Util/Log/TeamCity.php | 9 +- .../src/Util/PHP/DefaultPhpProcess.php | 3 + .../src/Util/PHP/Template/PhptTestCase.tpl | 33 +- .../src/Util/PHP/Template/TestCaseClass.tpl | 25 +- .../src/Util/PHP/Template/TestCaseMethod.tpl | 25 +- vendor/phpunit/phpunit/src/Util/Printer.php | 126 +- vendor/phpunit/phpunit/src/Util/Test.php | 304 +- .../src/Util/TestDox/CliTestDoxPrinter.php | 25 +- .../src/Util/TestDox/HtmlResultPrinter.php | 7 +- .../src/Util/TestDox/NamePrettifier.php | 8 +- .../src/Util/TestDox/ResultPrinter.php | 9 +- .../src/Util/TestDox/TestDoxPrinter.php | 12 +- .../src/Util/TestDox/TextResultPrinter.php | 8 +- .../src/Util/TestDox/XmlResultPrinter.php | 12 +- .../src/Util/XdebugFilterScriptGenerator.php | 33 +- vendor/phpunit/phpunit/src/Util/Xml.php | 129 +- .../src/{TextUI => Util/Xml}/Exception.php | 2 +- .../Util/Xml/FailedSchemaDetectionResult.php | 19 + .../phpunit/phpunit/src/Util/Xml/Loader.php | 117 + .../src/Util/Xml/SchemaDetectionResult.php | 31 + .../phpunit/src/Util/Xml/SchemaDetector.php | 39 + .../phpunit/src/Util/Xml/SchemaFinder.php | 53 + .../phpunit/src/Util/Xml/SnapshotNodeList.php | 48 + .../Xml/SuccessfulSchemaDetectionResult.php | 38 + .../phpunit/src/Util/Xml/ValidationResult.php | 69 + .../phpunit/src/Util/Xml/Validator.php | 35 + vendor/psr/http-client/CHANGELOG.md | 23 + vendor/psr/http-client/LICENSE | 19 + vendor/psr/http-client/README.md | 12 + vendor/psr/http-client/composer.json | 27 + .../src/ClientExceptionInterface.php | 10 + .../psr/http-client/src/ClientInterface.php | 20 + .../src/NetworkExceptionInterface.php | 24 + .../src/RequestExceptionInterface.php | 24 + vendor/sebastian/cli-parser/ChangeLog.md | 15 + vendor/sebastian/cli-parser/LICENSE | 33 + vendor/sebastian/cli-parser/README.md | 17 + .../cli-parser}/composer.json | 19 +- vendor/sebastian/cli-parser/infection.json | 12 + vendor/sebastian/cli-parser/src/Parser.php | 204 + .../exceptions/AmbiguousOptionException.php | 26 + .../src/exceptions/Exception.php} | 8 +- .../OptionDoesNotAllowArgumentException.php | 26 + ...RequiredOptionArgumentMissingException.php | 26 + .../src/exceptions/UnknownOptionException.php | 26 + .../code-unit-reverse-lookup/.gitignore | 4 - .../code-unit-reverse-lookup/.php_cs | 67 - .../code-unit-reverse-lookup/.travis.yml | 25 - .../code-unit-reverse-lookup/ChangeLog.md | 29 +- .../code-unit-reverse-lookup/LICENSE | 2 +- .../code-unit-reverse-lookup/README.md | 14 +- .../code-unit-reverse-lookup/build.xml | 22 - .../code-unit-reverse-lookup/composer.json | 14 +- .../code-unit-reverse-lookup/phpunit.xml | 21 - .../code-unit-reverse-lookup/src/Wizard.php | 46 +- .../tests/WizardTest.php | 45 - .../sebastian/code-unit/.psalm/baseline.xml | 23 + vendor/sebastian/code-unit/.psalm/config.xml | 16 + vendor/sebastian/code-unit/ChangeLog.md | 65 + vendor/sebastian/code-unit/LICENSE | 33 + vendor/sebastian/code-unit/README.md | 17 + vendor/sebastian/code-unit/composer.json | 50 + .../code-unit/src/ClassMethodUnit.php | 24 + vendor/sebastian/code-unit/src/ClassUnit.php | 24 + vendor/sebastian/code-unit/src/CodeUnit.php | 445 + .../code-unit/src/CodeUnitCollection.php | 84 + .../src/CodeUnitCollectionIterator.php | 55 + .../sebastian/code-unit/src/FunctionUnit.php | 24 + .../code-unit/src/InterfaceMethodUnit.php | 24 + .../sebastian/code-unit/src/InterfaceUnit.php | 24 + vendor/sebastian/code-unit/src/Mapper.php | 414 + .../code-unit/src/TraitMethodUnit.php | 24 + vendor/sebastian/code-unit/src/TraitUnit.php | 24 + .../src/exceptions/Exception.php} | 8 +- .../exceptions/InvalidCodeUnitException.php | 16 + .../src/exceptions/NoTraitException.php | 16 + .../src/exceptions/ReflectionException.php | 16 + vendor/sebastian/comparator/.github/stale.yml | 40 - vendor/sebastian/comparator/.gitignore | 4 - vendor/sebastian/comparator/.php_cs.dist | 189 - vendor/sebastian/comparator/.travis.yml | 33 - vendor/sebastian/comparator/ChangeLog.md | 52 +- vendor/sebastian/comparator/LICENSE | 2 +- vendor/sebastian/comparator/README.md | 14 +- vendor/sebastian/comparator/build.xml | 21 - vendor/sebastian/comparator/composer.json | 13 +- vendor/sebastian/comparator/phpunit.xml | 21 - .../comparator/src/ArrayComparator.php | 39 +- .../sebastian/comparator/src/Comparator.php | 4 +- .../comparator/src/ComparisonFailure.php | 9 +- .../comparator/src/DOMNodeComparator.php | 17 +- .../comparator/src/DateTimeComparator.php | 37 +- .../comparator/src/DoubleComparator.php | 11 +- .../comparator/src/ExceptionComparator.php | 6 +- vendor/sebastian/comparator/src/Factory.php | 20 +- .../comparator/src/MockObjectComparator.php | 9 +- .../comparator/src/NumericComparator.php | 40 +- .../comparator/src/ObjectComparator.php | 26 +- .../comparator/src/ResourceComparator.php | 8 +- .../comparator/src/ScalarComparator.php | 29 +- .../src/SplObjectStorageComparator.php | 8 +- .../comparator/src/TypeComparator.php | 13 +- .../exceptions/Exception.php} | 6 +- .../src/exceptions}/RuntimeException.php | 4 +- .../comparator/tests/ArrayComparatorTest.php | 161 - .../tests/ComparisonFailureTest.php | 59 - .../tests/DOMNodeComparatorTest.php | 180 - .../tests/DateTimeComparatorTest.php | 213 - .../comparator/tests/DoubleComparatorTest.php | 135 - .../tests/ExceptionComparatorTest.php | 136 - .../comparator/tests/FactoryTest.php | 117 - .../tests/MockObjectComparatorTest.php | 168 - .../tests/NumericComparatorTest.php | 123 - .../comparator/tests/ObjectComparatorTest.php | 150 - .../tests/ResourceComparatorTest.php | 122 - .../comparator/tests/ScalarComparatorTest.php | 164 - .../tests/SplObjectStorageComparatorTest.php | 145 - .../comparator/tests/TypeComparatorTest.php | 107 - .../comparator/tests/_fixture/Author.php | 26 - .../comparator/tests/_fixture/Book.php | 19 - .../tests/_fixture/ClassWithToString.php | 18 - .../comparator/tests/_fixture/SampleClass.php | 29 - .../comparator/tests/_fixture/Struct.php | 23 - .../tests/_fixture/TestClassComparator.php | 14 - .../sebastian/complexity/.psalm/baseline.xml | 2 + vendor/sebastian/complexity/.psalm/config.xml | 16 + vendor/sebastian/complexity/ChangeLog.md | 30 + vendor/sebastian/complexity/LICENSE | 33 + vendor/sebastian/complexity/README.md | 22 + vendor/sebastian/complexity/composer.json | 41 + .../sebastian/complexity/src/Calculator.php | 88 + .../complexity/src/Complexity/Complexity.php | 42 + .../src/Complexity/ComplexityCollection.php | 72 + .../ComplexityCollectionIterator.php | 55 + .../complexity/src/Exception/Exception.php | 16 + .../src/Exception/RuntimeException.php} | 6 +- .../Visitor/ComplexityCalculatingVisitor.php | 109 + ...CyclomaticComplexityCalculatingVisitor.php | 59 + vendor/sebastian/diff/.github/stale.yml | 40 - vendor/sebastian/diff/.gitignore | 6 - vendor/sebastian/diff/.php_cs.dist | 168 - vendor/sebastian/diff/.travis.yml | 26 - vendor/sebastian/diff/ChangeLog.md | 40 +- vendor/sebastian/diff/LICENSE | 2 +- vendor/sebastian/diff/README.md | 15 +- vendor/sebastian/diff/build.xml | 22 - vendor/sebastian/diff/composer.json | 16 +- vendor/sebastian/diff/phpunit.xml | 21 - vendor/sebastian/diff/src/Chunk.php | 1 - vendor/sebastian/diff/src/Diff.php | 3 - vendor/sebastian/diff/src/Differ.php | 125 +- .../src/Exception/ConfigurationException.php | 20 +- .../diff/src/Exception/Exception.php | 5 +- .../Exception/InvalidArgumentException.php | 1 - vendor/sebastian/diff/src/Line.php | 3 +- .../LongestCommonSubsequenceCalculator.php | 6 - ...ientLongestCommonSubsequenceCalculator.php | 35 +- .../src/Output/AbstractChunkOutputBuilder.php | 10 +- .../diff/src/Output/DiffOnlyOutputBuilder.php | 28 +- .../src/Output/DiffOutputBuilderInterface.php | 1 - .../Output/StrictUnifiedDiffOutputBuilder.php | 114 +- .../src/Output/UnifiedDiffOutputBuilder.php | 80 +- vendor/sebastian/diff/src/Parser.php | 38 +- ...ientLongestCommonSubsequenceCalculator.php | 16 +- vendor/sebastian/diff/tests/ChunkTest.php | 73 - vendor/sebastian/diff/tests/DiffTest.php | 55 - vendor/sebastian/diff/tests/DifferTest.php | 444 - .../Exception/ConfigurationExceptionTest.php | 41 - .../InvalidArgumentExceptionTest.php | 33 - vendor/sebastian/diff/tests/LineTest.php | 44 - .../tests/LongestCommonSubsequenceTest.php | 201 - .../MemoryEfficientImplementationTest.php | 22 - .../Output/AbstractChunkOutputBuilderTest.php | 152 - .../Output/DiffOnlyOutputBuilderTest.php | 76 - ...nifiedDiffOutputBuilderIntegrationTest.php | 299 - ...nifiedDiffOutputBuilderIntegrationTest.php | 163 - ...ctUnifiedDiffOutputBuilderDataProvider.php | 189 - .../StrictUnifiedDiffOutputBuilderTest.php | 684 - .../UnifiedDiffOutputBuilderDataProvider.php | 396 - .../Output/UnifiedDiffOutputBuilderTest.php | 90 - vendor/sebastian/diff/tests/ParserTest.php | 170 - .../tests/TimeEfficientImplementationTest.php | 22 - .../sebastian/diff/tests/Utils/FileUtils.php | 31 - .../tests/Utils/UnifiedDiffAssertTrait.php | 277 - .../UnifiedDiffAssertTraitIntegrationTest.php | 129 - .../Utils/UnifiedDiffAssertTraitTest.php | 434 - .../diff/tests/fixtures/.editorconfig | 1 - .../1_a.txt | 1 - .../1_b.txt | 0 .../2_a.txt | 35 - .../2_b.txt | 18 - .../diff/tests/fixtures/out/.editorconfig | 1 - .../diff/tests/fixtures/out/.gitignore | 2 - .../sebastian/diff/tests/fixtures/patch.txt | 9 - .../sebastian/diff/tests/fixtures/patch2.txt | 21 - .../diff/tests/fixtures/serialized_diff.bin | Bin 4143 -> 0 bytes .../sebastian/environment/.github/FUNDING.yml | 1 - vendor/sebastian/environment/.gitignore | 6 - vendor/sebastian/environment/.php_cs.dist | 199 - vendor/sebastian/environment/.travis.yml | 28 - vendor/sebastian/environment/ChangeLog.md | 100 +- vendor/sebastian/environment/LICENSE | 2 +- vendor/sebastian/environment/README.md | 15 +- vendor/sebastian/environment/build.xml | 19 - vendor/sebastian/environment/composer.json | 9 +- vendor/sebastian/environment/phpunit.xml | 20 - vendor/sebastian/environment/src/Console.php | 81 +- .../environment/src/OperatingSystem.php | 13 +- vendor/sebastian/environment/src/Runtime.php | 132 +- .../environment/tests/ConsoleTest.php | 64 - .../environment/tests/OperatingSystemTest.php | 60 - .../environment/tests/RuntimeTest.php | 165 - vendor/sebastian/exporter/.github/FUNDING.yml | 1 - vendor/sebastian/exporter/.gitignore | 5 - vendor/sebastian/exporter/.php_cs.dist | 190 - vendor/sebastian/exporter/.travis.yml | 24 - vendor/sebastian/exporter/ChangeLog.md | 27 +- vendor/sebastian/exporter/LICENSE | 2 +- vendor/sebastian/exporter/README.md | 31 +- vendor/sebastian/exporter/build.xml | 19 - vendor/sebastian/exporter/composer.json | 11 +- vendor/sebastian/exporter/phpunit.xml | 19 - vendor/sebastian/exporter/src/Exporter.php | 114 +- .../sebastian/exporter/tests/ExporterTest.php | 432 - .../sebastian/global-state/.github/stale.yml | 40 - vendor/sebastian/global-state/.gitignore | 6 - vendor/sebastian/global-state/.php_cs.dist | 197 - vendor/sebastian/global-state/.travis.yml | 24 - vendor/sebastian/global-state/ChangeLog.md | 29 +- vendor/sebastian/global-state/LICENSE | 2 +- vendor/sebastian/global-state/README.md | 16 +- vendor/sebastian/global-state/build.xml | 19 - vendor/sebastian/global-state/composer.json | 13 +- vendor/sebastian/global-state/phpunit.xml | 27 - .../global-state/src/CodeExporter.php | 29 +- .../src/{Blacklist.php => ExcludeList.php} | 19 +- .../sebastian/global-state/src/Restorer.php | 41 +- .../sebastian/global-state/src/Snapshot.php | 108 +- .../global-state/src/exceptions/Exception.php | 4 +- .../global-state/tests/BlacklistTest.php | 117 - .../global-state/tests/CodeExporterTest.php | 35 - .../global-state/tests/RestorerTest.php | 68 - .../global-state/tests/SnapshotTest.php | 120 - .../tests/_fixture/BlacklistedImplementor.php | 15 - .../tests/_fixture/SnapshotClass.php | 35 - .../lines-of-code/.psalm/baseline.xml | 2 + .../sebastian/lines-of-code/.psalm/config.xml | 16 + vendor/sebastian/lines-of-code/ChangeLog.md | 34 + vendor/sebastian/lines-of-code/LICENSE | 33 + vendor/sebastian/lines-of-code/README.md | 22 + vendor/sebastian/lines-of-code/composer.json | 42 + .../sebastian/lines-of-code/src/Counter.php | 91 + .../lines-of-code/src/Exception/Exception.php | 16 + .../Exception/IllogicalValuesException.php | 16 + .../src/Exception/NegativeValueException.php | 16 + .../src/Exception/RuntimeException.php} | 7 +- .../lines-of-code/src/LineCountingVisitor.php | 82 + .../lines-of-code/src/LinesOfCode.php | 98 + vendor/sebastian/object-enumerator/.gitignore | 8 - vendor/sebastian/object-enumerator/.php_cs | 67 - .../object-enumerator/.psalm/baseline.xml | 9 + .../object-enumerator/.psalm/config.xml | 16 + .../sebastian/object-enumerator/.travis.yml | 26 - .../sebastian/object-enumerator/ChangeLog.md | 34 +- vendor/sebastian/object-enumerator/LICENSE | 2 +- vendor/sebastian/object-enumerator/README.md | 14 +- vendor/sebastian/object-enumerator/build.xml | 22 - .../sebastian/object-enumerator/composer.json | 18 +- .../sebastian/object-enumerator/phpunit.xml | 24 +- .../object-enumerator/src/Enumerator.php | 9 +- .../object-enumerator/src/Exception.php | 9 +- .../src/InvalidArgumentException.php | 5 +- .../tests/EnumeratorTest.php | 139 - .../tests/_fixture/ExceptionThrower.php | 28 - vendor/sebastian/object-reflector/.gitignore | 4 - vendor/sebastian/object-reflector/.php_cs | 79 - .../object-reflector/.psalm/baseline.xml | 8 + .../object-reflector/.psalm/config.xml | 16 + vendor/sebastian/object-reflector/.travis.yml | 26 - .../sebastian/object-reflector/ChangeLog.md | 44 +- vendor/sebastian/object-reflector/LICENSE | 2 +- vendor/sebastian/object-reflector/README.md | 14 +- vendor/sebastian/object-reflector/build.xml | 22 - .../sebastian/object-reflector/composer.json | 14 +- vendor/sebastian/object-reflector/phpunit.xml | 19 - .../object-reflector/src/Exception.php | 11 +- .../src/InvalidArgumentException.php | 7 +- .../object-reflector/src/ObjectReflector.php | 14 +- .../tests/ObjectReflectorTest.php | 70 - .../tests/_fixture/ChildClass.php | 25 - .../ClassWithIntegerAttributeName.php | 22 - .../tests/_fixture/ParentClass.php | 20 - vendor/sebastian/recursion-context/.gitignore | 3 - .../recursion-context/.psalm/baseline.xml | 8 + .../recursion-context/.psalm/config.xml | 16 + .../sebastian/recursion-context/.travis.yml | 23 - .../sebastian/recursion-context/ChangeLog.md | 33 + vendor/sebastian/recursion-context/LICENSE | 2 +- vendor/sebastian/recursion-context/README.md | 14 +- vendor/sebastian/recursion-context/build.xml | 21 - .../sebastian/recursion-context/composer.json | 14 +- .../sebastian/recursion-context/phpunit.xml | 19 - .../recursion-context/src/Context.php | 85 +- .../recursion-context/src/Exception.php | 9 +- .../src/InvalidArgumentException.php | 5 +- .../recursion-context/tests/ContextTest.php | 142 - .../resource-operations}/.gitattributes | 5 - .../resource-operations/.github/stale.yml | 40 - .../sebastian/resource-operations/.gitignore | 1 + .../resource-operations/.php_cs.dist | 191 - .../resource-operations/ChangeLog.md | 31 +- vendor/sebastian/resource-operations/LICENSE | 2 +- .../sebastian/resource-operations/build.xml | 38 - .../resource-operations/composer.json | 10 +- .../tests/ResourceOperationsTest.php | 26 - vendor/sebastian/type/.gitattributes | 2 - vendor/sebastian/type/.github/FUNDING.yml | 1 - vendor/sebastian/type/.gitignore | 72 - .../inspectionProfiles/Project_Default.xml | 499 - vendor/sebastian/type/.idea/misc.xml | 6 - vendor/sebastian/type/.idea/modules.xml | 8 - .../.idea/php-inspections-ea-ultimate.xml | 20 - vendor/sebastian/type/.idea/php.xml | 42 - vendor/sebastian/type/.idea/type.iml | 40 - vendor/sebastian/type/.idea/vcs.xml | 6 - vendor/sebastian/type/.php_cs.dist | 200 - vendor/sebastian/type/.travis.yml | 53 - vendor/sebastian/type/ChangeLog.md | 67 +- vendor/sebastian/type/LICENSE | 2 +- vendor/sebastian/type/README.md | 3 + vendor/sebastian/type/build.xml | 31 - vendor/sebastian/type/composer.json | 8 +- vendor/sebastian/type/phive.xml | 5 - vendor/sebastian/type/phpunit.xml | 23 - vendor/sebastian/type/psalm.xml | 53 - vendor/sebastian/type/src/CallableType.php | 63 +- .../sebastian/type/src/GenericObjectType.php | 4 +- vendor/sebastian/type/src/IterableType.php | 19 +- vendor/sebastian/type/src/MixedType.php | 33 + vendor/sebastian/type/src/NullType.php | 15 + vendor/sebastian/type/src/ObjectType.php | 11 +- .../sebastian/type/src/ReflectionMapper.php | 96 + vendor/sebastian/type/src/SimpleType.php | 8 +- vendor/sebastian/type/src/StaticType.php | 60 + vendor/sebastian/type/src/Type.php | 27 +- vendor/sebastian/type/src/TypeName.php | 52 +- vendor/sebastian/type/src/UnionType.php | 115 + vendor/sebastian/type/src/UnknownType.php | 15 + vendor/sebastian/type/src/VoidType.php | 4 +- .../type/src/exception/Exception.php | 4 +- .../type/tests/_fixture/ChildClass.php | 14 - .../_fixture/ClassWithCallbackMethods.php | 21 - .../tests/_fixture/ClassWithInvokeMethod.php | 17 - .../type/tests/_fixture/Iterator.php | 33 - .../type/tests/_fixture/ParentClass.php | 17 - .../type/tests/_fixture/callback_function.php | 14 - .../type/tests/unit/CallableTypeTest.php | 150 - .../type/tests/unit/GenericObjectTypeTest.php | 86 - .../type/tests/unit/IterableTypeTest.php | 97 - .../type/tests/unit/NullTypeTest.php | 72 - .../type/tests/unit/ObjectTypeTest.php | 140 - .../type/tests/unit/SimpleTypeTest.php | 162 - .../type/tests/unit/TypeNameTest.php | 59 - vendor/sebastian/type/tests/unit/TypeTest.php | 85 - .../type/tests/unit/UnknownTypeTest.php | 58 - .../type/tests/unit/VoidTypeTest.php | 70 - vendor/sebastian/version/.gitattributes | 3 + vendor/sebastian/version/.gitignore | 1 + vendor/sebastian/version/.php_cs | 66 - vendor/sebastian/version/ChangeLog.md | 25 + vendor/sebastian/version/LICENSE | 2 +- vendor/sebastian/version/composer.json | 12 +- vendor/sebastian/version/src/Version.php | 44 +- .../{.php_cs => .php_cs.dist} | 0 .../laravel-schedule-monitor/CHANGELOG.md | 22 + .../laravel-schedule-monitor/CONTRIBUTING.md | 55 - .../spatie/laravel-schedule-monitor/README.md | 23 +- .../laravel-schedule-monitor/composer.json | 15 +- .../src/Commands/CleanLogCommand.php | 2 +- .../BackgroundCommandListener.php | 20 +- .../src/Jobs/PingOhDearJob.php | 3 +- .../src/Models/MonitoredScheduledTask.php | 33 +- .../src/ScheduleMonitorServiceProvider.php | 8 + .../ScheduledTasks/Tasks/ClosureTask.php | 2 +- .../XPath/Extension/NodeExtension.php | 2 +- .../finder/Comparator/NumberComparator.php | 4 +- vendor/symfony/finder/Gitignore.php | 22 +- ...RegisterControllerArgumentLocatorsPass.php | 2 +- .../EventListener/RouterListener.php | 2 +- vendor/symfony/http-kernel/Kernel.php | 6 +- vendor/symfony/mime/Email.php | 2 +- vendor/symfony/polyfill-ctype/composer.json | 2 +- .../Resources/charset/translit.php | 5 +- vendor/symfony/polyfill-iconv/bootstrap80.php | 4 +- vendor/symfony/polyfill-iconv/composer.json | 2 +- .../polyfill-intl-grapheme/bootstrap80.php | 2 +- .../polyfill-intl-grapheme/composer.json | 2 +- .../Resources/unidata/Regex.php | 22 +- .../symfony/polyfill-intl-idn/bootstrap80.php | 3 - .../symfony/polyfill-intl-idn/composer.json | 2 +- .../polyfill-intl-normalizer/composer.json | 2 +- vendor/symfony/polyfill-mbstring/Mbstring.php | 46 +- .../Resources/unidata/lowerCase.php | 2 +- .../Resources/unidata/upperCase.php | 129 +- .../symfony/polyfill-mbstring/bootstrap.php | 2 +- .../symfony/polyfill-mbstring/bootstrap80.php | 6 +- .../symfony/polyfill-mbstring/composer.json | 2 +- vendor/symfony/polyfill-php72/Php72.php | 2 +- vendor/symfony/polyfill-php72/composer.json | 2 +- vendor/symfony/polyfill-php73/composer.json | 2 +- vendor/symfony/polyfill-php80/composer.json | 2 +- .../routing/Generator/UrlGenerator.php | 2 +- .../translation/Loader/XliffFileLoader.php | 2 +- vendor/symfony/translation/Translator.php | 2 +- vendor/vlucas/phpdotenv/composer.json | 18 +- vendor/vlucas/phpdotenv/src/Dotenv.php | 143 +- .../src/Exception/ExceptionInterface.php | 6 +- .../Exception/InvalidEncodingException.php | 12 + .../src/Exception/InvalidFileException.php | 4 +- .../src/Exception/InvalidPathException.php | 4 +- .../src/Exception/ValidationException.php | 4 +- vendor/vlucas/phpdotenv/src/Loader/Loader.php | 127 +- .../phpdotenv/src/Loader/LoaderInterface.php | 10 +- vendor/vlucas/phpdotenv/src/Loader/Parser.php | 249 - .../vlucas/phpdotenv/src/Loader/Resolver.php | 65 + vendor/vlucas/phpdotenv/src/Parser/Entry.php | 59 + .../phpdotenv/src/Parser/EntryParser.php | 293 + vendor/vlucas/phpdotenv/src/Parser/Lexer.php | 62 + .../src/{Loader => Parser}/Lines.php | 80 +- vendor/vlucas/phpdotenv/src/Parser/Parser.php | 52 + .../phpdotenv/src/Parser/ParserInterface.php | 19 + .../src/{Loader => Parser}/Value.php | 27 +- vendor/vlucas/phpdotenv/src/Regex/Regex.php | 125 - .../src/Repository/AbstractRepository.php | 175 - .../Repository/Adapter/AdapterInterface.php | 15 + .../src/Repository/Adapter/ApacheAdapter.php | 73 +- .../src/Repository/Adapter/ArrayAdapter.php | 89 +- .../Adapter/AvailabilityInterface.php | 13 - .../Repository/Adapter/EnvConstAdapter.php | 99 +- .../src/Repository/Adapter/GuardedWriter.php | 85 + .../Repository/Adapter/ImmutableWriter.php | 110 + .../src/Repository/Adapter/MultiReader.php | 48 + .../src/Repository/Adapter/MultiWriter.php | 64 + .../src/Repository/Adapter/PutenvAdapter.php | 71 +- .../Repository/Adapter/ReaderInterface.php | 10 +- .../Repository/Adapter/ReplacingWriter.php | 104 + .../Repository/Adapter/ServerConstAdapter.php | 99 +- .../Repository/Adapter/WriterInterface.php | 20 +- .../src/Repository/AdapterRepository.php | 76 +- .../src/Repository/RepositoryBuilder.php | 262 +- .../src/Repository/RepositoryInterface.php | 33 +- vendor/vlucas/phpdotenv/src/Result/Result.php | 70 - .../vlucas/phpdotenv/src/Store/File/Paths.php | 21 +- .../phpdotenv/src/Store/File/Reader.php | 49 +- .../vlucas/phpdotenv/src/Store/FileStore.php | 33 +- .../phpdotenv/src/Store/StoreBuilder.php | 83 +- .../phpdotenv/src/Store/StoreInterface.php | 4 +- .../phpdotenv/src/Store/StringStore.php | 4 +- vendor/vlucas/phpdotenv/src/Util/Regex.php | 110 + vendor/vlucas/phpdotenv/src/Util/Str.php | 90 + vendor/vlucas/phpdotenv/src/Validator.php | 132 +- 2333 files changed, 113904 insertions(+), 59058 deletions(-) create mode 100644 database/migrations/2021_05_18_145620_create_schedule_monitor_tables.php create mode 100644 database/migrations/2021_05_18_155240_create_schedule_monitor_tables.php create mode 100644 database/migrations/2021_05_18_160844_create_schedule_monitor_tables.php create mode 100644 database/migrations/2021_05_19_001202_create_schedule_monitor_tables.php create mode 100644 public/alliance_moons.txt create mode 120000 vendor/bin/php-parse delete mode 100644 vendor/cakephp/chronos/Dockerfile delete mode 100644 vendor/cakephp/chronos/README.md delete mode 100644 vendor/cakephp/chronos/composer.json delete mode 100644 vendor/cakephp/chronos/docs.Dockerfile delete mode 100644 vendor/cakephp/chronos/docs/config/__init__.py delete mode 100644 vendor/cakephp/chronos/docs/config/all.py delete mode 100644 vendor/cakephp/chronos/docs/en/conf.py delete mode 100644 vendor/cakephp/chronos/docs/en/contents.rst delete mode 100644 vendor/cakephp/chronos/docs/en/index.rst delete mode 100644 vendor/cakephp/chronos/docs/fr/conf.py delete mode 100644 vendor/cakephp/chronos/docs/fr/contents.rst delete mode 100644 vendor/cakephp/chronos/docs/fr/index.rst delete mode 100644 vendor/cakephp/chronos/docs/ja/conf.py delete mode 100644 vendor/cakephp/chronos/docs/ja/contents.rst delete mode 100644 vendor/cakephp/chronos/docs/ja/index.rst delete mode 100644 vendor/cakephp/chronos/docs/pt/conf.py delete mode 100644 vendor/cakephp/chronos/docs/pt/contents.rst delete mode 100644 vendor/cakephp/chronos/docs/pt/index.rst delete mode 100644 vendor/cakephp/chronos/src/Chronos.php delete mode 100644 vendor/cakephp/chronos/src/ChronosInterface.php delete mode 100644 vendor/cakephp/chronos/src/ChronosInterval.php delete mode 100644 vendor/cakephp/chronos/src/Date.php delete mode 100644 vendor/cakephp/chronos/src/DifferenceFormatter.php delete mode 100644 vendor/cakephp/chronos/src/DifferenceFormatterInterface.php delete mode 100644 vendor/cakephp/chronos/src/MutableDate.php delete mode 100644 vendor/cakephp/chronos/src/MutableDateTime.php delete mode 100644 vendor/cakephp/chronos/src/Traits/ComparisonTrait.php delete mode 100644 vendor/cakephp/chronos/src/Traits/CopyTrait.php delete mode 100644 vendor/cakephp/chronos/src/Traits/DifferenceTrait.php delete mode 100644 vendor/cakephp/chronos/src/Traits/FactoryTrait.php delete mode 100644 vendor/cakephp/chronos/src/Traits/FormattingTrait.php delete mode 100644 vendor/cakephp/chronos/src/Traits/FrozenTimeTrait.php delete mode 100644 vendor/cakephp/chronos/src/Traits/MagicPropertyTrait.php delete mode 100644 vendor/cakephp/chronos/src/Traits/ModifierTrait.php delete mode 100644 vendor/cakephp/chronos/src/Traits/RelativeKeywordTrait.php delete mode 100644 vendor/cakephp/chronos/src/Traits/TestingAidTrait.php delete mode 100644 vendor/cakephp/chronos/src/Traits/TimezoneTrait.php delete mode 100644 vendor/cakephp/chronos/src/Translator.php delete mode 100644 vendor/cakephp/chronos/src/carbon_compat.php create mode 100644 vendor/dragonmantank/cron-expression/phpstan.neon create mode 100644 vendor/dragonmantank/cron-expression/src/Cron/FieldFactoryInterface.php delete mode 100644 vendor/dragonmantank/cron-expression/tests/Cron/AbstractFieldTest.php delete mode 100644 vendor/dragonmantank/cron-expression/tests/Cron/CronExpressionTest.php delete mode 100644 vendor/dragonmantank/cron-expression/tests/Cron/DayOfMonthFieldTest.php delete mode 100644 vendor/dragonmantank/cron-expression/tests/Cron/DayOfWeekFieldTest.php delete mode 100644 vendor/dragonmantank/cron-expression/tests/Cron/FieldFactoryTest.php delete mode 100644 vendor/dragonmantank/cron-expression/tests/Cron/HoursFieldTest.php delete mode 100644 vendor/dragonmantank/cron-expression/tests/Cron/MinutesFieldTest.php delete mode 100644 vendor/dragonmantank/cron-expression/tests/Cron/MonthFieldTest.php rename vendor/{cakephp/chronos => graham-campbell/result-type}/LICENSE (79%) create mode 100644 vendor/graham-campbell/result-type/composer.json rename vendor/{vlucas/phpdotenv/src/Result => graham-campbell/result-type/src}/Error.php (57%) create mode 100644 vendor/graham-campbell/result-type/src/Result.php rename vendor/{vlucas/phpdotenv/src/Result => graham-campbell/result-type/src}/Success.php (59%) delete mode 100644 vendor/guzzlehttp/guzzle/.php_cs delete mode 100644 vendor/guzzlehttp/guzzle/Dockerfile create mode 100644 vendor/guzzlehttp/guzzle/src/BodySummarizer.php create mode 100644 vendor/guzzlehttp/guzzle/src/BodySummarizerInterface.php create mode 100644 vendor/guzzlehttp/guzzle/src/ClientTrait.php delete mode 100644 vendor/guzzlehttp/guzzle/src/Exception/SeekException.php create mode 100644 vendor/guzzlehttp/guzzle/src/Handler/HeaderProcessor.php create mode 100644 vendor/guzzlehttp/guzzle/src/MessageFormatterInterface.php delete mode 100644 vendor/guzzlehttp/guzzle/src/UriTemplate.php create mode 100644 vendor/guzzlehttp/guzzle/vendor-bin/php-cs-fixer/composer.json create mode 100644 vendor/guzzlehttp/guzzle/vendor-bin/phpstan/composer.json create mode 100644 vendor/guzzlehttp/guzzle/vendor-bin/psalm/composer.json create mode 100644 vendor/laravel/framework/src/Illuminate/Auth/Access/Events/GateEvaluated.php create mode 100644 vendor/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/AblyBroadcaster.php create mode 100644 vendor/laravel/framework/src/Illuminate/Bus/Batch.php create mode 100644 vendor/laravel/framework/src/Illuminate/Bus/BatchFactory.php create mode 100644 vendor/laravel/framework/src/Illuminate/Bus/BatchRepository.php create mode 100644 vendor/laravel/framework/src/Illuminate/Bus/Batchable.php create mode 100644 vendor/laravel/framework/src/Illuminate/Bus/DatabaseBatchRepository.php create mode 100644 vendor/laravel/framework/src/Illuminate/Bus/Events/BatchDispatched.php create mode 100644 vendor/laravel/framework/src/Illuminate/Bus/PendingBatch.php create mode 100644 vendor/laravel/framework/src/Illuminate/Bus/PrunableBatchRepository.php create mode 100644 vendor/laravel/framework/src/Illuminate/Bus/UpdatedBatchJobCounts.php create mode 100644 vendor/laravel/framework/src/Illuminate/Cache/CacheLock.php create mode 100644 vendor/laravel/framework/src/Illuminate/Cache/HasCacheLock.php create mode 100644 vendor/laravel/framework/src/Illuminate/Cache/NoLock.php create mode 100644 vendor/laravel/framework/src/Illuminate/Cache/PhpRedisLock.php create mode 100644 vendor/laravel/framework/src/Illuminate/Cache/RateLimiting/GlobalLimit.php create mode 100644 vendor/laravel/framework/src/Illuminate/Cache/RateLimiting/Limit.php create mode 100644 vendor/laravel/framework/src/Illuminate/Cache/RateLimiting/Unlimited.php rename vendor/laravel/framework/src/Illuminate/{Support => Collections}/Arr.php (93%) mode change 100755 => 100644 rename vendor/laravel/framework/src/Illuminate/{Support => Collections}/Collection.php (89%) rename vendor/laravel/framework/src/Illuminate/{Support => Collections}/Enumerable.php (90%) rename vendor/laravel/framework/src/Illuminate/{Support => Collections}/HigherOrderCollectionProxy.php (100%) rename vendor/laravel/framework/src/Illuminate/{Support => Collections}/HigherOrderWhenProxy.php (100%) create mode 100644 vendor/laravel/framework/src/Illuminate/Collections/ItemNotFoundException.php create mode 100644 vendor/laravel/framework/src/Illuminate/Collections/LICENSE.md rename vendor/laravel/framework/src/Illuminate/{Support => Collections}/LazyCollection.php (91%) create mode 100644 vendor/laravel/framework/src/Illuminate/Collections/MultipleItemsFoundException.php rename vendor/laravel/framework/src/Illuminate/{Support => Collections}/Traits/EnumeratesValues.php (91%) create mode 100644 vendor/laravel/framework/src/Illuminate/Collections/composer.json create mode 100644 vendor/laravel/framework/src/Illuminate/Collections/helpers.php create mode 100644 vendor/laravel/framework/src/Illuminate/Console/BufferedConsoleOutput.php create mode 100644 vendor/laravel/framework/src/Illuminate/Console/Events/ScheduledBackgroundTaskFinished.php create mode 100644 vendor/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleListCommand.php create mode 100644 vendor/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleTestCommand.php create mode 100644 vendor/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleWorkCommand.php create mode 100644 vendor/laravel/framework/src/Illuminate/Contracts/Container/CircularDependencyException.php create mode 100644 vendor/laravel/framework/src/Illuminate/Contracts/Database/Eloquent/DeviatesCastableAttributes.php create mode 100644 vendor/laravel/framework/src/Illuminate/Contracts/Database/Eloquent/SerializesCastableAttributes.php create mode 100644 vendor/laravel/framework/src/Illuminate/Contracts/Database/Eloquent/SupportsPartialRelations.php create mode 100644 vendor/laravel/framework/src/Illuminate/Contracts/Encryption/StringEncrypter.php create mode 100644 vendor/laravel/framework/src/Illuminate/Contracts/Filesystem/LockTimeoutException.php create mode 100644 vendor/laravel/framework/src/Illuminate/Contracts/Pagination/CursorPaginator.php create mode 100644 vendor/laravel/framework/src/Illuminate/Contracts/Queue/ClearableQueue.php create mode 100644 vendor/laravel/framework/src/Illuminate/Contracts/Queue/ShouldBeEncrypted.php create mode 100644 vendor/laravel/framework/src/Illuminate/Contracts/Queue/ShouldBeUnique.php create mode 100644 vendor/laravel/framework/src/Illuminate/Contracts/Queue/ShouldBeUniqueUntilProcessing.php create mode 100644 vendor/laravel/framework/src/Illuminate/Contracts/Validation/DataAwareRule.php create mode 100644 vendor/laravel/framework/src/Illuminate/Contracts/Validation/UncompromisedVerifier.php create mode 100644 vendor/laravel/framework/src/Illuminate/Contracts/Validation/ValidatorAwareRule.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Concerns/ExplainsQueries.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Console/DbCommand.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Console/DumpCommand.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/DBAL/TimestampType.php create mode 100755 vendor/laravel/framework/src/Illuminate/Database/DatabaseTransactionRecord.php create mode 100755 vendor/laravel/framework/src/Illuminate/Database/DatabaseTransactionsManager.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Eloquent/Casts/ArrayObject.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsArrayObject.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsCollection.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsEncryptedArrayObject.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsEncryptedCollection.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/BelongsToManyRelationship.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/BelongsToRelationship.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/Factory.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/HasFactory.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/Relationship.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/Sequence.php delete mode 100644 vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factory.php delete mode 100644 vendor/laravel/framework/src/Illuminate/Database/Eloquent/FactoryBuilder.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Eloquent/InvalidCastException.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/CanBeOneOfMany.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/ComparesRelatedModels.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/InteractsWithDictionary.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Events/DatabaseRefreshed.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Events/SchemaDumped.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Events/SchemaLoaded.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/LazyLoadingViolationException.php create mode 100755 vendor/laravel/framework/src/Illuminate/Database/MultipleRecordsFoundException.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/PDO/Concerns/ConnectsToDatabase.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/PDO/Connection.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/PDO/MySqlDriver.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/PDO/PostgresDriver.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/PDO/SQLiteDriver.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/PDO/SqlServerConnection.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/PDO/SqlServerDriver.php create mode 100755 vendor/laravel/framework/src/Illuminate/Database/RecordsNotFoundException.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Schema/MySqlSchemaState.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Schema/PostgresSchemaState.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Schema/SchemaState.php create mode 100644 vendor/laravel/framework/src/Illuminate/Database/Schema/SqliteSchemaState.php create mode 100644 vendor/laravel/framework/src/Illuminate/Encryption/MissingAppKeyException.php create mode 100644 vendor/laravel/framework/src/Illuminate/Events/InvokeQueuedClosure.php create mode 100644 vendor/laravel/framework/src/Illuminate/Events/QueuedClosure.php create mode 100644 vendor/laravel/framework/src/Illuminate/Events/functions.php create mode 100644 vendor/laravel/framework/src/Illuminate/Filesystem/LockableFile.php create mode 100644 vendor/laravel/framework/src/Illuminate/Foundation/Auth/EmailVerificationRequest.php create mode 100644 vendor/laravel/framework/src/Illuminate/Foundation/Bus/PendingClosureDispatch.php create mode 100644 vendor/laravel/framework/src/Illuminate/Foundation/Console/stubs/maintenance-mode.stub create mode 100644 vendor/laravel/framework/src/Illuminate/Foundation/Events/VendorTagPublished.php create mode 100644 vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/RegisterErrorViewPaths.php create mode 100644 vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/ReportableHandler.php create mode 100644 vendor/laravel/framework/src/Illuminate/Foundation/Http/MaintenanceModeBypassCookie.php create mode 100644 vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/PreventRequestsDuringMaintenance.php create mode 100644 vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithTime.php create mode 100644 vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithViews.php create mode 100644 vendor/laravel/framework/src/Illuminate/Foundation/Testing/Wormhole.php create mode 100644 vendor/laravel/framework/src/Illuminate/Http/Client/Pool.php create mode 100644 vendor/laravel/framework/src/Illuminate/Macroable/LICENSE.md rename vendor/laravel/framework/src/Illuminate/{Support => Macroable}/Traits/Macroable.php (100%) create mode 100644 vendor/laravel/framework/src/Illuminate/Macroable/composer.json create mode 100644 vendor/laravel/framework/src/Illuminate/Pagination/AbstractCursorPaginator.php create mode 100644 vendor/laravel/framework/src/Illuminate/Pagination/Cursor.php create mode 100644 vendor/laravel/framework/src/Illuminate/Pagination/CursorPaginationException.php create mode 100644 vendor/laravel/framework/src/Illuminate/Pagination/CursorPaginator.php create mode 100644 vendor/laravel/framework/src/Illuminate/Pagination/PaginationState.php create mode 100644 vendor/laravel/framework/src/Illuminate/Queue/Console/BatchesTableCommand.php create mode 100644 vendor/laravel/framework/src/Illuminate/Queue/Console/ClearCommand.php create mode 100644 vendor/laravel/framework/src/Illuminate/Queue/Console/PruneBatchesCommand.php create mode 100644 vendor/laravel/framework/src/Illuminate/Queue/Console/RetryBatchCommand.php create mode 100644 vendor/laravel/framework/src/Illuminate/Queue/Console/stubs/batches.stub create mode 100644 vendor/laravel/framework/src/Illuminate/Queue/Events/JobQueued.php create mode 100644 vendor/laravel/framework/src/Illuminate/Queue/Failed/DatabaseUuidFailedJobProvider.php create mode 100644 vendor/laravel/framework/src/Illuminate/Queue/Middleware/RateLimited.php create mode 100644 vendor/laravel/framework/src/Illuminate/Queue/Middleware/RateLimitedWithRedis.php create mode 100644 vendor/laravel/framework/src/Illuminate/Queue/Middleware/ThrottlesExceptions.php create mode 100644 vendor/laravel/framework/src/Illuminate/Queue/Middleware/ThrottlesExceptionsWithRedis.php create mode 100644 vendor/laravel/framework/src/Illuminate/Queue/Middleware/WithoutOverlapping.php create mode 100644 vendor/laravel/framework/src/Illuminate/Routing/CreatesRegularExpressionRouteConstraints.php create mode 100644 vendor/laravel/framework/src/Illuminate/Support/Facades/ParallelTesting.php create mode 100644 vendor/laravel/framework/src/Illuminate/Support/Facades/RateLimiter.php create mode 100644 vendor/laravel/framework/src/Illuminate/Support/Testing/Fakes/BatchRepositoryFake.php create mode 100644 vendor/laravel/framework/src/Illuminate/Support/Testing/Fakes/PendingBatchFake.php create mode 100644 vendor/laravel/framework/src/Illuminate/Support/Testing/Fakes/PendingChainFake.php create mode 100644 vendor/laravel/framework/src/Illuminate/Testing/AssertableJsonString.php create mode 100644 vendor/laravel/framework/src/Illuminate/Testing/Concerns/TestDatabases.php create mode 100644 vendor/laravel/framework/src/Illuminate/Testing/Fluent/AssertableJson.php create mode 100644 vendor/laravel/framework/src/Illuminate/Testing/Fluent/Concerns/Debugging.php create mode 100644 vendor/laravel/framework/src/Illuminate/Testing/Fluent/Concerns/Has.php create mode 100644 vendor/laravel/framework/src/Illuminate/Testing/Fluent/Concerns/Interaction.php create mode 100644 vendor/laravel/framework/src/Illuminate/Testing/Fluent/Concerns/Matching.php create mode 100644 vendor/laravel/framework/src/Illuminate/Testing/ParallelConsoleOutput.php create mode 100644 vendor/laravel/framework/src/Illuminate/Testing/ParallelRunner.php create mode 100644 vendor/laravel/framework/src/Illuminate/Testing/ParallelTesting.php create mode 100644 vendor/laravel/framework/src/Illuminate/Testing/ParallelTestingServiceProvider.php create mode 100644 vendor/laravel/framework/src/Illuminate/Testing/TestView.php create mode 100644 vendor/laravel/framework/src/Illuminate/Validation/NotPwnedVerifier.php create mode 100644 vendor/laravel/framework/src/Illuminate/Validation/Rules/Password.php create mode 100644 vendor/laravel/framework/src/Illuminate/View/AppendableAttributeValue.php create mode 100644 vendor/laravel/framework/src/Illuminate/View/DynamicComponent.php create mode 100644 vendor/laravel/framework/src/Illuminate/View/ViewException.php create mode 100644 vendor/laravel/horizon/resources/js/screens/batches/index.vue create mode 100644 vendor/laravel/horizon/resources/js/screens/batches/preview.vue create mode 100644 vendor/laravel/horizon/src/Console/ClearCommand.php create mode 100644 vendor/laravel/horizon/src/Console/ContinueSupervisorCommand.php create mode 100644 vendor/laravel/horizon/src/Console/ForgetFailedCommand.php create mode 100644 vendor/laravel/horizon/src/Console/PauseSupervisorCommand.php create mode 100644 vendor/laravel/horizon/src/Http/Controllers/BatchesController.php delete mode 100644 vendor/laravel/horizon/src/JobId.php delete mode 100644 vendor/laravel/ui/CHANGELOG.md create mode 100644 vendor/lorisleiva/cron-translator/.github/FUNDING.yml create mode 100644 vendor/lorisleiva/cron-translator/src/CronExpression.php create mode 100644 vendor/lorisleiva/cron-translator/src/TranslationFileMissingException.php create mode 100644 vendor/lorisleiva/cron-translator/src/lang/en/days.php create mode 100644 vendor/lorisleiva/cron-translator/src/lang/en/fields.php create mode 100644 vendor/lorisleiva/cron-translator/src/lang/en/months.php create mode 100644 vendor/lorisleiva/cron-translator/src/lang/en/ordinals.php create mode 100644 vendor/lorisleiva/cron-translator/src/lang/en/times.php create mode 100644 vendor/lorisleiva/cron-translator/src/lang/fr/days.php create mode 100644 vendor/lorisleiva/cron-translator/src/lang/fr/fields.php create mode 100644 vendor/lorisleiva/cron-translator/src/lang/fr/months.php create mode 100644 vendor/lorisleiva/cron-translator/src/lang/fr/ordinals.php create mode 100644 vendor/lorisleiva/cron-translator/src/lang/fr/times.php create mode 100644 vendor/lorisleiva/cron-translator/src/lang/lv/days.php create mode 100644 vendor/lorisleiva/cron-translator/src/lang/lv/fields.php create mode 100644 vendor/lorisleiva/cron-translator/src/lang/lv/months.php create mode 100644 vendor/lorisleiva/cron-translator/src/lang/lv/ordinals.php create mode 100644 vendor/lorisleiva/cron-translator/src/lang/lv/times.php rename vendor/{dragonmantank/cron-expression => nikic/php-parser}/.editorconfig (61%) create mode 100644 vendor/nikic/php-parser/LICENSE create mode 100644 vendor/nikic/php-parser/README.md create mode 100755 vendor/nikic/php-parser/bin/php-parse create mode 100644 vendor/nikic/php-parser/composer.json create mode 100644 vendor/nikic/php-parser/grammar/README.md create mode 100644 vendor/nikic/php-parser/grammar/parser.template create mode 100644 vendor/nikic/php-parser/grammar/php5.y create mode 100644 vendor/nikic/php-parser/grammar/php7.y create mode 100644 vendor/nikic/php-parser/grammar/phpyLang.php create mode 100644 vendor/nikic/php-parser/grammar/rebuildParsers.php create mode 100644 vendor/nikic/php-parser/grammar/tokens.template create mode 100644 vendor/nikic/php-parser/grammar/tokens.y create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Builder.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Builder/ClassConst.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Builder/Class_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Builder/Declaration.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Builder/FunctionLike.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Builder/Function_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Builder/Interface_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Builder/Method.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Builder/Namespace_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Builder/Param.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Builder/Property.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Builder/TraitUse.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Builder/TraitUseAdaptation.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Builder/Trait_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Builder/Use_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/BuilderFactory.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/BuilderHelpers.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Comment.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Comment/Doc.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/ConstExprEvaluationException.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/ConstExprEvaluator.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Error.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/ErrorHandler.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/ErrorHandler/Collecting.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/ErrorHandler/Throwing.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Internal/DiffElem.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Internal/Differ.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Internal/PrintableNewAnonClassNode.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Internal/TokenStream.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/JsonDecoder.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Lexer.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Lexer/Emulative.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/AttributeEmulator.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/CoaleseEqualTokenEmulator.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/EnumTokenEmulator.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/FlexibleDocStringEmulator.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/FnTokenEmulator.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/KeywordEmulator.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/MatchTokenEmulator.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/NullsafeTokenEmulator.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/NumericLiteralSeparatorEmulator.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/ReverseEmulator.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/TokenEmulator.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/NameContext.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Arg.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Attribute.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/AttributeGroup.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Const_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/ArrayDimFetch.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/ArrayItem.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Array_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/ArrowFunction.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Assign.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/BitwiseAnd.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/BitwiseOr.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/BitwiseXor.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Coalesce.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Concat.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Div.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Minus.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Mod.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Mul.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Plus.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Pow.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/ShiftLeft.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/ShiftRight.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/AssignRef.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/BitwiseAnd.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/BitwiseOr.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/BitwiseXor.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/BooleanAnd.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/BooleanOr.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Coalesce.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Concat.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Div.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Equal.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Greater.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/GreaterOrEqual.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Identical.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/LogicalAnd.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/LogicalOr.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/LogicalXor.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Minus.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Mod.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Mul.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/NotEqual.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/NotIdentical.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Plus.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Pow.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/ShiftLeft.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/ShiftRight.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Smaller.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/SmallerOrEqual.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Spaceship.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BitwiseNot.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/BooleanNot.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Cast.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Cast/Array_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Cast/Bool_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Cast/Double.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Cast/Int_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Cast/Object_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Cast/String_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Cast/Unset_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/ClassConstFetch.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Clone_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Closure.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/ClosureUse.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/ConstFetch.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Empty_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Error.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/ErrorSuppress.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Eval_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Exit_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/FuncCall.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Include_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Instanceof_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Isset_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/List_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Match_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/MethodCall.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/New_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/NullsafeMethodCall.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/NullsafePropertyFetch.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/PostDec.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/PostInc.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/PreDec.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/PreInc.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Print_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/PropertyFetch.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/ShellExec.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/StaticCall.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/StaticPropertyFetch.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Ternary.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Throw_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/UnaryMinus.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/UnaryPlus.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Variable.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/YieldFrom.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Expr/Yield_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/FunctionLike.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Identifier.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/MatchArm.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Name.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Name/FullyQualified.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Name/Relative.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/NullableType.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Param.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Scalar.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Scalar/DNumber.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Scalar/Encapsed.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Scalar/EncapsedStringPart.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Scalar/LNumber.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/Class_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/Dir.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/File.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/Function_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/Line.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/Method.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/Namespace_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/Trait_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Scalar/String_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Break_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Case_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Catch_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/ClassConst.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/ClassLike.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/ClassMethod.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Class_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Const_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Continue_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/DeclareDeclare.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Declare_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Do_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Echo_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/ElseIf_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Else_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/EnumCase.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Enum_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Expression.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Finally_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/For_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Foreach_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Function_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Global_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Goto_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/GroupUse.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/HaltCompiler.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/If_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/InlineHTML.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Interface_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Label.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Namespace_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Nop.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Property.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/PropertyProperty.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Return_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/StaticVar.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Static_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Switch_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Throw_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/TraitUse.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/TraitUseAdaptation.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/TraitUseAdaptation/Alias.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/TraitUseAdaptation/Precedence.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Trait_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/TryCatch.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Unset_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/UseUse.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/Use_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/Stmt/While_.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/UnionType.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Node/VarLikeIdentifier.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/NodeAbstract.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/NodeDumper.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/NodeFinder.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/NodeTraverser.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/NodeTraverserInterface.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/NodeVisitor.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/NodeVisitor/CloningVisitor.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/NodeVisitor/FindingVisitor.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/NodeVisitor/FirstFindingVisitor.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/NodeVisitor/NameResolver.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/NodeVisitor/NodeConnectingVisitor.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/NodeVisitor/ParentConnectingVisitor.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/NodeVisitorAbstract.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Parser.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Parser/Multiple.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Parser/Php5.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Parser/Php7.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/Parser/Tokens.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/ParserAbstract.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/ParserFactory.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/PrettyPrinter/Standard.php create mode 100644 vendor/nikic/php-parser/lib/PhpParser/PrettyPrinterAbstract.php delete mode 100644 vendor/nunomaduro/collision/.github/FUNDING.yml delete mode 100644 vendor/nunomaduro/collision/.php_cs delete mode 100644 vendor/nunomaduro/collision/phpstan.neon.dist delete mode 100644 vendor/nunomaduro/collision/phpunit.xml.dist create mode 100644 vendor/nunomaduro/collision/src/Adapters/Laravel/Exceptions/RequirementsException.php delete mode 100644 vendor/nunomaduro/collision/src/Adapters/Phpunit/PrinterContents.php create mode 100644 vendor/nunomaduro/collision/src/Contracts/RenderlessEditor.php create mode 100644 vendor/nunomaduro/collision/src/Contracts/RenderlessTrace.php create mode 100644 vendor/nunomaduro/collision/src/Exceptions/InvalidStyleException.php delete mode 100644 vendor/phpunit/php-code-coverage/.gitattributes delete mode 100644 vendor/phpunit/php-code-coverage/.github/CONTRIBUTING.md delete mode 100644 vendor/phpunit/php-code-coverage/.github/FUNDING.yml delete mode 100644 vendor/phpunit/php-code-coverage/.github/ISSUE_TEMPLATE.md delete mode 100644 vendor/phpunit/php-code-coverage/.gitignore delete mode 100644 vendor/phpunit/php-code-coverage/.php_cs.dist delete mode 100644 vendor/phpunit/php-code-coverage/.travis.yml delete mode 100644 vendor/phpunit/php-code-coverage/build.xml delete mode 100644 vendor/phpunit/php-code-coverage/phive.xml delete mode 100644 vendor/phpunit/php-code-coverage/phpunit.xml create mode 100644 vendor/phpunit/php-code-coverage/src/CrapIndex.php create mode 100644 vendor/phpunit/php-code-coverage/src/Directory.php delete mode 100644 vendor/phpunit/php-code-coverage/src/Driver/PCOV.php create mode 100644 vendor/phpunit/php-code-coverage/src/Driver/PcovDriver.php rename vendor/phpunit/php-code-coverage/src/Driver/{PHPDBG.php => PhpdbgDriver.php} (51%) create mode 100644 vendor/phpunit/php-code-coverage/src/Driver/Selector.php delete mode 100644 vendor/phpunit/php-code-coverage/src/Driver/Xdebug.php create mode 100644 vendor/phpunit/php-code-coverage/src/Driver/Xdebug2Driver.php create mode 100644 vendor/phpunit/php-code-coverage/src/Driver/Xdebug3Driver.php rename vendor/phpunit/php-code-coverage/src/Exception/{CoveredCodeNotExecutedException.php => BranchAndPathCoverageNotSupportedException.php} (57%) rename vendor/phpunit/php-code-coverage/src/Exception/{MissingCoversAnnotationException.php => DeadCodeDetectionNotSupportedException.php} (57%) create mode 100644 vendor/phpunit/php-code-coverage/src/Exception/DirectoryCouldNotBeCreatedException.php create mode 100644 vendor/phpunit/php-code-coverage/src/Exception/NoCodeCoverageDriverAvailableException.php create mode 100644 vendor/phpunit/php-code-coverage/src/Exception/NoCodeCoverageDriverWithPathCoverageSupportAvailableException.php create mode 100644 vendor/phpunit/php-code-coverage/src/Exception/ParserException.php create mode 100644 vendor/phpunit/php-code-coverage/src/Exception/PathExistsButIsNotDirectoryException.php create mode 100644 vendor/phpunit/php-code-coverage/src/Exception/PcovNotAvailableException.php create mode 100644 vendor/phpunit/php-code-coverage/src/Exception/PhpdbgNotAvailableException.php create mode 100644 vendor/phpunit/php-code-coverage/src/Exception/ReflectionException.php create mode 100644 vendor/phpunit/php-code-coverage/src/Exception/ReportAlreadyFinalizedException.php create mode 100644 vendor/phpunit/php-code-coverage/src/Exception/StaticAnalysisCacheNotConfiguredException.php create mode 100644 vendor/phpunit/php-code-coverage/src/Exception/TestIdMissingException.php create mode 100644 vendor/phpunit/php-code-coverage/src/Exception/WriteOperationFailedException.php create mode 100644 vendor/phpunit/php-code-coverage/src/Exception/WrongXdebugVersionException.php create mode 100644 vendor/phpunit/php-code-coverage/src/Exception/Xdebug2NotEnabledException.php create mode 100644 vendor/phpunit/php-code-coverage/src/Exception/Xdebug3NotEnabledException.php create mode 100644 vendor/phpunit/php-code-coverage/src/Exception/XdebugNotAvailableException.php rename vendor/phpunit/php-code-coverage/src/Exception/{RuntimeException.php => XmlException.php} (64%) create mode 100644 vendor/phpunit/php-code-coverage/src/Percentage.php create mode 100644 vendor/phpunit/php-code-coverage/src/ProcessedCodeCoverageData.php create mode 100644 vendor/phpunit/php-code-coverage/src/RawCodeCoverageData.php create mode 100644 vendor/phpunit/php-code-coverage/src/Report/Cobertura.php create mode 100644 vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/branches.html.dist create mode 100644 vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/coverage_bar_branch.html.dist rename vendor/phpunit/php-code-coverage/{tests/_files/Report/HTML/CoverageForFileWithIgnoredLines/dashboard.html => src/Report/Html/Renderer/Template/dashboard_branch.html.dist} (81%) create mode 100644 vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/directory_branch.html.dist create mode 100644 vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/directory_item_branch.html.dist create mode 100644 vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/file_branch.html.dist create mode 100644 vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/file_item_branch.html.dist create mode 100644 vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/line.html.dist create mode 100644 vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/lines.html.dist create mode 100644 vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/method_item_branch.html.dist create mode 100644 vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/paths.html.dist create mode 100644 vendor/phpunit/php-code-coverage/src/StaticAnalysis/Cache.php create mode 100644 vendor/phpunit/php-code-coverage/src/StaticAnalysis/CacheWarmer.php create mode 100644 vendor/phpunit/php-code-coverage/src/StaticAnalysis/CachingCoveredFileAnalyser.php create mode 100644 vendor/phpunit/php-code-coverage/src/StaticAnalysis/CachingUncoveredFileAnalyser.php create mode 100644 vendor/phpunit/php-code-coverage/src/StaticAnalysis/CodeUnitFindingVisitor.php create mode 100644 vendor/phpunit/php-code-coverage/src/StaticAnalysis/CoveredFileAnalyser.php create mode 100644 vendor/phpunit/php-code-coverage/src/StaticAnalysis/ExecutableLinesFindingVisitor.php create mode 100644 vendor/phpunit/php-code-coverage/src/StaticAnalysis/IgnoredLinesFindingVisitor.php create mode 100644 vendor/phpunit/php-code-coverage/src/StaticAnalysis/ParsingCoveredFileAnalyser.php create mode 100644 vendor/phpunit/php-code-coverage/src/StaticAnalysis/ParsingUncoveredFileAnalyser.php create mode 100644 vendor/phpunit/php-code-coverage/src/StaticAnalysis/UncoveredFileAnalyser.php delete mode 100644 vendor/phpunit/php-code-coverage/src/Util.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/TestCase.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/BankAccount-clover.xml delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/BankAccount-crap4j.xml delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/BankAccount-text.txt delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/BankAccount.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/BankAccountTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageClassExtendedTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageClassTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageFunctionParenthesesTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageFunctionParenthesesWhitespaceTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageFunctionTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodOneLineAnnotationTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodParenthesesTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodParenthesesWhitespaceTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageNoneTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageNotPrivateTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageNotProtectedTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageNotPublicTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageNothingTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoveragePrivateTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageProtectedTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoveragePublicTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoverageTwoDefaultClassAnnotations.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoveredClass.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/CoveredFunction.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/Crash.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageClassExtendedTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageClassTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageCoversClassPublicTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageCoversClassTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageMethodTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotPrivateTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotProtectedTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotPublicTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveragePrivateTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageProtectedTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveragePublicTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveredClass.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/NotExistingCoveredElementTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForBankAccount/BankAccount.php.html delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForBankAccount/dashboard.html delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForBankAccount/index.html delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForClassWithAnonymousFunction/dashboard.html delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForClassWithAnonymousFunction/index.html delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForClassWithAnonymousFunction/source_with_class_and_anonymous_function.php.html delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForFileWithIgnoredLines/index.html delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForFileWithIgnoredLines/source_with_ignore.php.html delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForBankAccount/BankAccount.php.xml delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForBankAccount/index.xml delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForClassWithAnonymousFunction/index.xml delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForClassWithAnonymousFunction/source_with_class_and_anonymous_function.php.xml delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForFileWithIgnoredLines/index.xml delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForFileWithIgnoredLines/source_with_ignore.php.xml delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/class-with-anonymous-function-clover.xml delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/class-with-anonymous-function-crap4j.xml delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/class-with-anonymous-function-text.txt delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/ignored-lines-clover.xml delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/ignored-lines-crap4j.xml delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/ignored-lines-text.txt delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/source_with_class_and_anonymous_function.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/source_with_ignore.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/source_with_namespace.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/source_with_oneline_annotations.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/source_with_use_statements.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/source_without_ignore.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/_files/source_without_namespace.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/bootstrap.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/tests/BuilderTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/tests/CloverTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/tests/CodeCoverageTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/tests/Crap4jTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/tests/Exception/UnintentionallyCoveredCodeExceptionTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/tests/FilterTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/tests/HTMLTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/tests/TextTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/tests/UtilTest.php delete mode 100644 vendor/phpunit/php-code-coverage/tests/tests/XmlTest.php delete mode 100644 vendor/phpunit/php-file-iterator/.gitattributes delete mode 100644 vendor/phpunit/php-file-iterator/.github/stale.yml delete mode 100644 vendor/phpunit/php-file-iterator/.gitignore delete mode 100644 vendor/phpunit/php-file-iterator/.php_cs.dist delete mode 100644 vendor/phpunit/php-file-iterator/.travis.yml delete mode 100644 vendor/phpunit/php-file-iterator/phpunit.xml delete mode 100644 vendor/phpunit/php-file-iterator/tests/FactoryTest.php create mode 100644 vendor/phpunit/php-invoker/ChangeLog.md rename vendor/phpunit/{php-token-stream => php-invoker}/LICENSE (94%) rename vendor/phpunit/{php-token-stream => php-invoker}/README.md (50%) create mode 100644 vendor/phpunit/php-invoker/composer.json create mode 100644 vendor/phpunit/php-invoker/src/Invoker.php rename vendor/{sebastian/global-state/tests/_fixture/BlacklistedInterface.php => phpunit/php-invoker/src/exceptions/Exception.php} (62%) create mode 100644 vendor/phpunit/php-invoker/src/exceptions/ProcessControlExtensionNotLoadedException.php create mode 100644 vendor/phpunit/php-invoker/src/exceptions/TimeoutException.php delete mode 100644 vendor/phpunit/php-text-template/.gitattributes delete mode 100644 vendor/phpunit/php-text-template/.gitignore create mode 100644 vendor/phpunit/php-text-template/.psalm/baseline.xml create mode 100644 vendor/phpunit/php-text-template/.psalm/config.xml create mode 100644 vendor/phpunit/php-text-template/ChangeLog.md create mode 100644 vendor/phpunit/php-text-template/src/exceptions/Exception.php create mode 100644 vendor/phpunit/php-text-template/src/exceptions/InvalidArgumentException.php create mode 100644 vendor/phpunit/php-text-template/src/exceptions/RuntimeException.php delete mode 100644 vendor/phpunit/php-timer/.gitattributes delete mode 100644 vendor/phpunit/php-timer/.github/FUNDING.yml delete mode 100644 vendor/phpunit/php-timer/.github/stale.yml delete mode 100644 vendor/phpunit/php-timer/.gitignore delete mode 100644 vendor/phpunit/php-timer/.php_cs.dist create mode 100644 vendor/phpunit/php-timer/.psalm/baseline.xml create mode 100644 vendor/phpunit/php-timer/.psalm/config.xml delete mode 100644 vendor/phpunit/php-timer/.travis.yml delete mode 100644 vendor/phpunit/php-timer/build.xml delete mode 100644 vendor/phpunit/php-timer/phpunit.xml create mode 100644 vendor/phpunit/php-timer/src/Duration.php create mode 100644 vendor/phpunit/php-timer/src/ResourceUsageFormatter.php rename vendor/phpunit/php-timer/src/{ => exceptions}/Exception.php (84%) rename vendor/{sebastian/global-state/tests/_fixture/SnapshotDomDocument.php => phpunit/php-timer/src/exceptions/NoActiveTimerException.php} (56%) create mode 100644 vendor/phpunit/php-timer/src/exceptions/TimeSinceStartOfRequestNotAvailableException.php delete mode 100644 vendor/phpunit/php-timer/tests/TimerTest.php delete mode 100644 vendor/phpunit/php-token-stream/.gitignore delete mode 100644 vendor/phpunit/php-token-stream/ChangeLog.md delete mode 100644 vendor/phpunit/php-token-stream/src/Abstract.php delete mode 100644 vendor/phpunit/php-token-stream/src/Ampersand.php delete mode 100644 vendor/phpunit/php-token-stream/src/AndEqual.php delete mode 100644 vendor/phpunit/php-token-stream/src/Array.php delete mode 100644 vendor/phpunit/php-token-stream/src/ArrayCast.php delete mode 100644 vendor/phpunit/php-token-stream/src/As.php delete mode 100644 vendor/phpunit/php-token-stream/src/At.php delete mode 100644 vendor/phpunit/php-token-stream/src/Backtick.php delete mode 100644 vendor/phpunit/php-token-stream/src/BadCharacter.php delete mode 100644 vendor/phpunit/php-token-stream/src/BoolCast.php delete mode 100644 vendor/phpunit/php-token-stream/src/BooleanAnd.php delete mode 100644 vendor/phpunit/php-token-stream/src/BooleanOr.php delete mode 100644 vendor/phpunit/php-token-stream/src/CachingFactory.php delete mode 100644 vendor/phpunit/php-token-stream/src/Callable.php delete mode 100644 vendor/phpunit/php-token-stream/src/Caret.php delete mode 100644 vendor/phpunit/php-token-stream/src/Case.php delete mode 100644 vendor/phpunit/php-token-stream/src/Catch.php delete mode 100644 vendor/phpunit/php-token-stream/src/Character.php delete mode 100644 vendor/phpunit/php-token-stream/src/Class.php delete mode 100644 vendor/phpunit/php-token-stream/src/ClassC.php delete mode 100644 vendor/phpunit/php-token-stream/src/ClassNameConstant.php delete mode 100644 vendor/phpunit/php-token-stream/src/Clone.php delete mode 100644 vendor/phpunit/php-token-stream/src/CloseBracket.php delete mode 100644 vendor/phpunit/php-token-stream/src/CloseCurly.php delete mode 100644 vendor/phpunit/php-token-stream/src/CloseSquare.php delete mode 100644 vendor/phpunit/php-token-stream/src/CloseTag.php delete mode 100644 vendor/phpunit/php-token-stream/src/Coalesce.php delete mode 100644 vendor/phpunit/php-token-stream/src/CoalesceEqual.php delete mode 100644 vendor/phpunit/php-token-stream/src/Colon.php delete mode 100644 vendor/phpunit/php-token-stream/src/Comma.php delete mode 100644 vendor/phpunit/php-token-stream/src/Comment.php delete mode 100644 vendor/phpunit/php-token-stream/src/ConcatEqual.php delete mode 100644 vendor/phpunit/php-token-stream/src/Const.php delete mode 100644 vendor/phpunit/php-token-stream/src/ConstantEncapsedString.php delete mode 100644 vendor/phpunit/php-token-stream/src/Continue.php delete mode 100644 vendor/phpunit/php-token-stream/src/CurlyOpen.php delete mode 100644 vendor/phpunit/php-token-stream/src/DNumber.php delete mode 100644 vendor/phpunit/php-token-stream/src/Dec.php delete mode 100644 vendor/phpunit/php-token-stream/src/Declare.php delete mode 100644 vendor/phpunit/php-token-stream/src/Default.php delete mode 100644 vendor/phpunit/php-token-stream/src/Dir.php delete mode 100644 vendor/phpunit/php-token-stream/src/Div.php delete mode 100644 vendor/phpunit/php-token-stream/src/DivEqual.php delete mode 100644 vendor/phpunit/php-token-stream/src/Do.php delete mode 100644 vendor/phpunit/php-token-stream/src/DocComment.php delete mode 100644 vendor/phpunit/php-token-stream/src/Dollar.php delete mode 100644 vendor/phpunit/php-token-stream/src/DollarOpenCurlyBraces.php delete mode 100644 vendor/phpunit/php-token-stream/src/Dot.php delete mode 100644 vendor/phpunit/php-token-stream/src/DoubleArrow.php delete mode 100644 vendor/phpunit/php-token-stream/src/DoubleCast.php delete mode 100644 vendor/phpunit/php-token-stream/src/DoubleColon.php delete mode 100644 vendor/phpunit/php-token-stream/src/DoubleQuotes.php delete mode 100644 vendor/phpunit/php-token-stream/src/Echo.php delete mode 100644 vendor/phpunit/php-token-stream/src/Ellipsis.php delete mode 100644 vendor/phpunit/php-token-stream/src/Else.php delete mode 100644 vendor/phpunit/php-token-stream/src/Elseif.php delete mode 100644 vendor/phpunit/php-token-stream/src/Empty.php delete mode 100644 vendor/phpunit/php-token-stream/src/EncapsedAndWhitespace.php delete mode 100644 vendor/phpunit/php-token-stream/src/EndHeredoc.php delete mode 100644 vendor/phpunit/php-token-stream/src/Enddeclare.php delete mode 100644 vendor/phpunit/php-token-stream/src/Endfor.php delete mode 100644 vendor/phpunit/php-token-stream/src/Endforeach.php delete mode 100644 vendor/phpunit/php-token-stream/src/Endif.php delete mode 100644 vendor/phpunit/php-token-stream/src/Endswitch.php delete mode 100644 vendor/phpunit/php-token-stream/src/Endwhile.php delete mode 100644 vendor/phpunit/php-token-stream/src/Equal.php delete mode 100644 vendor/phpunit/php-token-stream/src/Eval.php delete mode 100644 vendor/phpunit/php-token-stream/src/ExclamationMark.php delete mode 100644 vendor/phpunit/php-token-stream/src/Exit.php delete mode 100644 vendor/phpunit/php-token-stream/src/Extends.php delete mode 100644 vendor/phpunit/php-token-stream/src/File.php delete mode 100644 vendor/phpunit/php-token-stream/src/Final.php delete mode 100644 vendor/phpunit/php-token-stream/src/Finally.php delete mode 100644 vendor/phpunit/php-token-stream/src/Fn.php delete mode 100644 vendor/phpunit/php-token-stream/src/For.php delete mode 100644 vendor/phpunit/php-token-stream/src/Foreach.php delete mode 100644 vendor/phpunit/php-token-stream/src/FuncC.php delete mode 100644 vendor/phpunit/php-token-stream/src/Function.php delete mode 100644 vendor/phpunit/php-token-stream/src/Global.php delete mode 100644 vendor/phpunit/php-token-stream/src/Goto.php delete mode 100644 vendor/phpunit/php-token-stream/src/Gt.php delete mode 100644 vendor/phpunit/php-token-stream/src/HaltCompiler.php delete mode 100644 vendor/phpunit/php-token-stream/src/If.php delete mode 100644 vendor/phpunit/php-token-stream/src/Implements.php delete mode 100644 vendor/phpunit/php-token-stream/src/Inc.php delete mode 100644 vendor/phpunit/php-token-stream/src/Include.php delete mode 100644 vendor/phpunit/php-token-stream/src/IncludeOnce.php delete mode 100644 vendor/phpunit/php-token-stream/src/Includes.php delete mode 100644 vendor/phpunit/php-token-stream/src/InlineHtml.php delete mode 100644 vendor/phpunit/php-token-stream/src/Instanceof.php delete mode 100644 vendor/phpunit/php-token-stream/src/Insteadof.php delete mode 100644 vendor/phpunit/php-token-stream/src/IntCast.php delete mode 100644 vendor/phpunit/php-token-stream/src/Interface.php delete mode 100644 vendor/phpunit/php-token-stream/src/IsEqual.php delete mode 100644 vendor/phpunit/php-token-stream/src/IsGreaterOrEqual.php delete mode 100644 vendor/phpunit/php-token-stream/src/IsIdentical.php delete mode 100644 vendor/phpunit/php-token-stream/src/IsNotEqual.php delete mode 100644 vendor/phpunit/php-token-stream/src/IsNotIdentical.php delete mode 100644 vendor/phpunit/php-token-stream/src/IsSmallerOrEqual.php delete mode 100644 vendor/phpunit/php-token-stream/src/Isset.php delete mode 100644 vendor/phpunit/php-token-stream/src/Line.php delete mode 100644 vendor/phpunit/php-token-stream/src/List.php delete mode 100644 vendor/phpunit/php-token-stream/src/Lnumber.php delete mode 100644 vendor/phpunit/php-token-stream/src/LogicalAnd.php delete mode 100644 vendor/phpunit/php-token-stream/src/LogicalOr.php delete mode 100644 vendor/phpunit/php-token-stream/src/LogicalXor.php delete mode 100644 vendor/phpunit/php-token-stream/src/Lt.php delete mode 100644 vendor/phpunit/php-token-stream/src/MethodC.php delete mode 100644 vendor/phpunit/php-token-stream/src/Minus.php delete mode 100644 vendor/phpunit/php-token-stream/src/MinusEqual.php delete mode 100644 vendor/phpunit/php-token-stream/src/ModEqual.php delete mode 100644 vendor/phpunit/php-token-stream/src/MulEqual.php delete mode 100644 vendor/phpunit/php-token-stream/src/Mult.php delete mode 100644 vendor/phpunit/php-token-stream/src/NameFullyQualified.php delete mode 100644 vendor/phpunit/php-token-stream/src/NameQualified.php delete mode 100644 vendor/phpunit/php-token-stream/src/NameRelative.php delete mode 100644 vendor/phpunit/php-token-stream/src/Namespace.php delete mode 100644 vendor/phpunit/php-token-stream/src/New.php delete mode 100644 vendor/phpunit/php-token-stream/src/NsC.php delete mode 100644 vendor/phpunit/php-token-stream/src/NsSeparator.php delete mode 100644 vendor/phpunit/php-token-stream/src/NumString.php delete mode 100644 vendor/phpunit/php-token-stream/src/ObjectCast.php delete mode 100644 vendor/phpunit/php-token-stream/src/ObjectOperator.php delete mode 100644 vendor/phpunit/php-token-stream/src/OpenBracket.php delete mode 100644 vendor/phpunit/php-token-stream/src/OpenCurly.php delete mode 100644 vendor/phpunit/php-token-stream/src/OpenSquare.php delete mode 100644 vendor/phpunit/php-token-stream/src/OpenTag.php delete mode 100644 vendor/phpunit/php-token-stream/src/OpenTagWithEcho.php delete mode 100644 vendor/phpunit/php-token-stream/src/OrEqual.php delete mode 100644 vendor/phpunit/php-token-stream/src/PaamayimNekudotayim.php delete mode 100644 vendor/phpunit/php-token-stream/src/Percent.php delete mode 100644 vendor/phpunit/php-token-stream/src/Pipe.php delete mode 100644 vendor/phpunit/php-token-stream/src/Plus.php delete mode 100644 vendor/phpunit/php-token-stream/src/PlusEqual.php delete mode 100644 vendor/phpunit/php-token-stream/src/Pow.php delete mode 100644 vendor/phpunit/php-token-stream/src/PowEqual.php delete mode 100644 vendor/phpunit/php-token-stream/src/Print.php delete mode 100644 vendor/phpunit/php-token-stream/src/Private.php delete mode 100644 vendor/phpunit/php-token-stream/src/Protected.php delete mode 100644 vendor/phpunit/php-token-stream/src/Public.php delete mode 100644 vendor/phpunit/php-token-stream/src/QuestionMark.php delete mode 100644 vendor/phpunit/php-token-stream/src/Require.php delete mode 100644 vendor/phpunit/php-token-stream/src/RequireOnce.php delete mode 100644 vendor/phpunit/php-token-stream/src/Return.php delete mode 100644 vendor/phpunit/php-token-stream/src/Semicolon.php delete mode 100644 vendor/phpunit/php-token-stream/src/Sl.php delete mode 100644 vendor/phpunit/php-token-stream/src/SlEqual.php delete mode 100644 vendor/phpunit/php-token-stream/src/Spaceship.php delete mode 100644 vendor/phpunit/php-token-stream/src/Sr.php delete mode 100644 vendor/phpunit/php-token-stream/src/SrEqual.php delete mode 100644 vendor/phpunit/php-token-stream/src/StartHeredoc.php delete mode 100644 vendor/phpunit/php-token-stream/src/Static.php delete mode 100644 vendor/phpunit/php-token-stream/src/Stream.php delete mode 100644 vendor/phpunit/php-token-stream/src/String.php delete mode 100644 vendor/phpunit/php-token-stream/src/StringCast.php delete mode 100644 vendor/phpunit/php-token-stream/src/StringVarname.php delete mode 100644 vendor/phpunit/php-token-stream/src/Switch.php delete mode 100644 vendor/phpunit/php-token-stream/src/Throw.php delete mode 100644 vendor/phpunit/php-token-stream/src/Tilde.php delete mode 100644 vendor/phpunit/php-token-stream/src/Token.php delete mode 100644 vendor/phpunit/php-token-stream/src/TokenWithScope.php delete mode 100644 vendor/phpunit/php-token-stream/src/TokenWithScopeAndVisibility.php delete mode 100644 vendor/phpunit/php-token-stream/src/Trait.php delete mode 100644 vendor/phpunit/php-token-stream/src/TraitC.php delete mode 100644 vendor/phpunit/php-token-stream/src/Try.php delete mode 100644 vendor/phpunit/php-token-stream/src/Unset.php delete mode 100644 vendor/phpunit/php-token-stream/src/UnsetCast.php delete mode 100644 vendor/phpunit/php-token-stream/src/Use.php delete mode 100644 vendor/phpunit/php-token-stream/src/UseFunction.php delete mode 100644 vendor/phpunit/php-token-stream/src/Util.php delete mode 100644 vendor/phpunit/php-token-stream/src/Var.php delete mode 100644 vendor/phpunit/php-token-stream/src/Variable.php delete mode 100644 vendor/phpunit/php-token-stream/src/While.php delete mode 100644 vendor/phpunit/php-token-stream/src/Whitespace.php delete mode 100644 vendor/phpunit/php-token-stream/src/XorEqual.php delete mode 100644 vendor/phpunit/php-token-stream/src/Yield.php delete mode 100644 vendor/phpunit/php-token-stream/src/YieldFrom.php delete mode 100644 vendor/phpunit/php-token-stream/src/break.php create mode 100644 vendor/phpunit/phpunit/ChangeLog-9.5.md create mode 100644 vendor/phpunit/phpunit/schema/8.5.xsd create mode 100644 vendor/phpunit/phpunit/schema/9.2.xsd delete mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/ArraySubset.php delete mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/Attribute.php rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Boolean}/IsFalse.php (88%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Boolean}/IsTrue.php (88%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Cardinality}/Count.php (84%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Cardinality}/GreaterThan.php (91%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Cardinality}/IsEmpty.php (94%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Cardinality}/LessThan.php (91%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Cardinality}/SameSize.php (69%) delete mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/Composite.php rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Equality}/IsEqual.php (86%) create mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualCanonicalizing.php create mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualIgnoringCase.php create mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualWithDelta.php rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Exception}/Exception.php (94%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Exception}/ExceptionCode.php (93%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Exception}/ExceptionMessage.php (94%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Exception}/ExceptionMessageRegularExpression.php (94%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Filesystem}/DirectoryExists.php (89%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Filesystem}/FileExists.php (90%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Filesystem}/IsReadable.php (89%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Filesystem}/IsWritable.php (89%) delete mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/LogicalAnd.php delete mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/LogicalNot.php delete mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/LogicalOr.php delete mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/LogicalXor.php rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Math}/IsFinite.php (88%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Math}/IsInfinite.php (88%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Math}/IsNan.php (88%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Object}/ClassHasAttribute.php (93%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Object}/ClassHasStaticAttribute.php (90%) create mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/Object/ObjectEquals.php rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Object}/ObjectHasAttribute.php (83%) create mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/Operator/BinaryOperator.php create mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalAnd.php create mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalNot.php create mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalOr.php create mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalXor.php create mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/Operator/Operator.php create mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/Operator/UnaryOperator.php rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => String}/IsJson.php (90%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => String}/RegularExpression.php (78%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => String}/StringContains.php (61%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => String}/StringEndsWith.php (90%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => String}/StringMatchesFormatDescription.php (88%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => String}/StringStartsWith.php (92%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Traversable}/ArrayHasKey.php (88%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{TraversableContainsIdentical.php => Traversable/TraversableContains.php} (60%) create mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContainsEqual.php create mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContainsIdentical.php rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Traversable}/TraversableContainsOnly.php (90%) delete mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/TraversableContains.php delete mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/TraversableContainsEqual.php rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Type}/IsInstanceOf.php (92%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Type}/IsNull.php (88%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Type}/IsType.php (76%) create mode 100644 vendor/phpunit/phpunit/src/Framework/ErrorTestCase.php create mode 100644 vendor/phpunit/phpunit/src/Framework/Exception/ActualValueIsNotAnObjectException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotAcceptParameterTypeException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotDeclareBoolReturnTypeException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotDeclareExactlyOneParameterException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotDeclareParameterTypeException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotExistException.php rename vendor/phpunit/phpunit/src/Framework/{MockObject/Builder/Match_.php => Exception/Error.php} (51%) create mode 100644 vendor/phpunit/phpunit/src/Framework/ExecutionOrderDependency.php create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Exception/CannotUseAddMethodsException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Exception/CannotUseOnlyMethodsException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassAlreadyExistsException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsFinalException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Exception/DuplicateMethodException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Exception/InvalidMethodNameException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MatchBuilderNotFoundException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MatcherAlreadyRegisteredException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MethodCannotBeConfiguredException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MethodNameAlreadyConfiguredException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MethodNameNotConfiguredException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MethodParametersAlreadyConfiguredException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Exception/OriginalConstructorInvocationRequiredException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ReflectionException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ReturnValueNotConfiguredException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Exception/SoapExtensionNotAvailableException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownClassException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownTraitException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownTypeException.php create mode 100644 vendor/phpunit/phpunit/src/Framework/Reorderable.php create mode 100644 vendor/phpunit/phpunit/src/Runner/Extension/ExtensionHandler.php create mode 100644 vendor/phpunit/phpunit/src/Runner/Extension/PharLoader.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/CliArguments/Builder.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/CliArguments/Configuration.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/CliArguments/Exception.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/CliArguments/Mapper.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/DefaultResultPrinter.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/Exception/Exception.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/Exception/ReflectionException.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/Exception/RuntimeException.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/Exception/TestDirectoryNotFoundException.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/Exception/TestFileNotFoundException.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/TestSuiteMapper.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/CodeCoverage.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Filter/Directory.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Filter/DirectoryCollection.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Filter/DirectoryCollectionIterator.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/FilterMapper.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Clover.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Cobertura.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Crap4j.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Html.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Php.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Text.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Xml.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Configuration.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Exception.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/Directory.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/DirectoryCollection.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/DirectoryCollectionIterator.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/File.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/FileCollection.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/FileCollectionIterator.php rename vendor/phpunit/phpunit/src/{Util/ConfigurationGenerator.php => TextUI/XmlConfiguration/Generator.php} (79%) create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/Group.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/GroupCollection.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/GroupCollectionIterator.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/Groups.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Loader.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/Junit.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/Logging.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TeamCity.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TestDox/Html.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TestDox/Text.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TestDox/Xml.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/Text.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/MigrationBuilder.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/MigrationBuilderException.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/MigrationException.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/ConvertLogTypes.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageCloverToReport.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageCrap4jToReport.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageHtmlToReport.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoveragePhpToReport.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageTextToReport.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageXmlToReport.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/IntroduceCoverageElement.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/LogToReportMigration.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/Migration.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveAttributesFromFilterWhitelistToCoverage.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveAttributesFromRootToCoverage.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveWhitelistDirectoriesToCoverage.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveWhitelistExcludesToCoverage.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/RemoveCacheTokensAttribute.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/RemoveEmptyFilter.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/RemoveLogTypes.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/UpdateSchemaLocationTo93.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrator.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/Constant.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/ConstantCollection.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/ConstantCollectionIterator.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/IniSetting.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/IniSettingCollection.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/IniSettingCollectionIterator.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/Php.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/PhpHandler.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/Variable.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/VariableCollection.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/VariableCollectionIterator.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/Extension.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/ExtensionCollection.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/ExtensionCollectionIterator.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/PHPUnit.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestDirectory.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestDirectoryCollection.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestDirectoryCollectionIterator.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestFile.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestFileCollection.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestFileCollectionIterator.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestSuite.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestSuiteCollection.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestSuiteCollectionIterator.php delete mode 100644 vendor/phpunit/phpunit/src/Util/Configuration.php create mode 100644 vendor/phpunit/phpunit/src/Util/ExcludeList.php delete mode 100644 vendor/phpunit/phpunit/src/Util/Getopt.php rename vendor/phpunit/phpunit/src/{TextUI => Util/Xml}/Exception.php (94%) create mode 100644 vendor/phpunit/phpunit/src/Util/Xml/FailedSchemaDetectionResult.php create mode 100644 vendor/phpunit/phpunit/src/Util/Xml/Loader.php create mode 100644 vendor/phpunit/phpunit/src/Util/Xml/SchemaDetectionResult.php create mode 100644 vendor/phpunit/phpunit/src/Util/Xml/SchemaDetector.php create mode 100644 vendor/phpunit/phpunit/src/Util/Xml/SchemaFinder.php create mode 100644 vendor/phpunit/phpunit/src/Util/Xml/SnapshotNodeList.php create mode 100644 vendor/phpunit/phpunit/src/Util/Xml/SuccessfulSchemaDetectionResult.php create mode 100644 vendor/phpunit/phpunit/src/Util/Xml/ValidationResult.php create mode 100644 vendor/phpunit/phpunit/src/Util/Xml/Validator.php create mode 100644 vendor/psr/http-client/CHANGELOG.md create mode 100644 vendor/psr/http-client/LICENSE create mode 100644 vendor/psr/http-client/README.md create mode 100644 vendor/psr/http-client/composer.json create mode 100644 vendor/psr/http-client/src/ClientExceptionInterface.php create mode 100644 vendor/psr/http-client/src/ClientInterface.php create mode 100644 vendor/psr/http-client/src/NetworkExceptionInterface.php create mode 100644 vendor/psr/http-client/src/RequestExceptionInterface.php create mode 100644 vendor/sebastian/cli-parser/ChangeLog.md create mode 100644 vendor/sebastian/cli-parser/LICENSE create mode 100644 vendor/sebastian/cli-parser/README.md rename vendor/{phpunit/php-token-stream => sebastian/cli-parser}/composer.json (53%) create mode 100644 vendor/sebastian/cli-parser/infection.json create mode 100644 vendor/sebastian/cli-parser/src/Parser.php create mode 100644 vendor/sebastian/cli-parser/src/exceptions/AmbiguousOptionException.php rename vendor/sebastian/{global-state/tests/_fixture/SnapshotTrait.php => cli-parser/src/exceptions/Exception.php} (61%) create mode 100644 vendor/sebastian/cli-parser/src/exceptions/OptionDoesNotAllowArgumentException.php create mode 100644 vendor/sebastian/cli-parser/src/exceptions/RequiredOptionArgumentMissingException.php create mode 100644 vendor/sebastian/cli-parser/src/exceptions/UnknownOptionException.php delete mode 100644 vendor/sebastian/code-unit-reverse-lookup/.gitignore delete mode 100644 vendor/sebastian/code-unit-reverse-lookup/.php_cs delete mode 100644 vendor/sebastian/code-unit-reverse-lookup/.travis.yml delete mode 100644 vendor/sebastian/code-unit-reverse-lookup/build.xml delete mode 100644 vendor/sebastian/code-unit-reverse-lookup/phpunit.xml delete mode 100644 vendor/sebastian/code-unit-reverse-lookup/tests/WizardTest.php create mode 100644 vendor/sebastian/code-unit/.psalm/baseline.xml create mode 100644 vendor/sebastian/code-unit/.psalm/config.xml create mode 100644 vendor/sebastian/code-unit/ChangeLog.md create mode 100644 vendor/sebastian/code-unit/LICENSE create mode 100644 vendor/sebastian/code-unit/README.md create mode 100644 vendor/sebastian/code-unit/composer.json create mode 100644 vendor/sebastian/code-unit/src/ClassMethodUnit.php create mode 100644 vendor/sebastian/code-unit/src/ClassUnit.php create mode 100644 vendor/sebastian/code-unit/src/CodeUnit.php create mode 100644 vendor/sebastian/code-unit/src/CodeUnitCollection.php create mode 100644 vendor/sebastian/code-unit/src/CodeUnitCollectionIterator.php create mode 100644 vendor/sebastian/code-unit/src/FunctionUnit.php create mode 100644 vendor/sebastian/code-unit/src/InterfaceMethodUnit.php create mode 100644 vendor/sebastian/code-unit/src/InterfaceUnit.php create mode 100644 vendor/sebastian/code-unit/src/Mapper.php create mode 100644 vendor/sebastian/code-unit/src/TraitMethodUnit.php create mode 100644 vendor/sebastian/code-unit/src/TraitUnit.php rename vendor/sebastian/{global-state/tests/_fixture/SnapshotFunctions.php => code-unit/src/exceptions/Exception.php} (62%) create mode 100644 vendor/sebastian/code-unit/src/exceptions/InvalidCodeUnitException.php create mode 100644 vendor/sebastian/code-unit/src/exceptions/NoTraitException.php create mode 100644 vendor/sebastian/code-unit/src/exceptions/ReflectionException.php delete mode 100644 vendor/sebastian/comparator/.github/stale.yml delete mode 100644 vendor/sebastian/comparator/.gitignore delete mode 100644 vendor/sebastian/comparator/.php_cs.dist delete mode 100644 vendor/sebastian/comparator/.travis.yml delete mode 100644 vendor/sebastian/comparator/build.xml delete mode 100644 vendor/sebastian/comparator/phpunit.xml rename vendor/sebastian/comparator/{tests/_fixture/TestClass.php => src/exceptions/Exception.php} (76%) rename vendor/{phpunit/php-timer/src => sebastian/comparator/src/exceptions}/RuntimeException.php (77%) delete mode 100644 vendor/sebastian/comparator/tests/ArrayComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/ComparisonFailureTest.php delete mode 100644 vendor/sebastian/comparator/tests/DOMNodeComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/DateTimeComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/DoubleComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/ExceptionComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/FactoryTest.php delete mode 100644 vendor/sebastian/comparator/tests/MockObjectComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/NumericComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/ObjectComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/ResourceComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/ScalarComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/SplObjectStorageComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/TypeComparatorTest.php delete mode 100644 vendor/sebastian/comparator/tests/_fixture/Author.php delete mode 100644 vendor/sebastian/comparator/tests/_fixture/Book.php delete mode 100644 vendor/sebastian/comparator/tests/_fixture/ClassWithToString.php delete mode 100644 vendor/sebastian/comparator/tests/_fixture/SampleClass.php delete mode 100644 vendor/sebastian/comparator/tests/_fixture/Struct.php delete mode 100644 vendor/sebastian/comparator/tests/_fixture/TestClassComparator.php create mode 100644 vendor/sebastian/complexity/.psalm/baseline.xml create mode 100644 vendor/sebastian/complexity/.psalm/config.xml create mode 100644 vendor/sebastian/complexity/ChangeLog.md create mode 100644 vendor/sebastian/complexity/LICENSE create mode 100644 vendor/sebastian/complexity/README.md create mode 100644 vendor/sebastian/complexity/composer.json create mode 100644 vendor/sebastian/complexity/src/Calculator.php create mode 100644 vendor/sebastian/complexity/src/Complexity/Complexity.php create mode 100644 vendor/sebastian/complexity/src/Complexity/ComplexityCollection.php create mode 100644 vendor/sebastian/complexity/src/Complexity/ComplexityCollectionIterator.php create mode 100644 vendor/sebastian/complexity/src/Exception/Exception.php rename vendor/sebastian/{global-state/tests/_fixture/BlacklistedChildClass.php => complexity/src/Exception/RuntimeException.php} (58%) create mode 100644 vendor/sebastian/complexity/src/Visitor/ComplexityCalculatingVisitor.php create mode 100644 vendor/sebastian/complexity/src/Visitor/CyclomaticComplexityCalculatingVisitor.php delete mode 100644 vendor/sebastian/diff/.github/stale.yml delete mode 100644 vendor/sebastian/diff/.gitignore delete mode 100644 vendor/sebastian/diff/.php_cs.dist delete mode 100644 vendor/sebastian/diff/.travis.yml delete mode 100644 vendor/sebastian/diff/build.xml delete mode 100644 vendor/sebastian/diff/phpunit.xml delete mode 100644 vendor/sebastian/diff/tests/ChunkTest.php delete mode 100644 vendor/sebastian/diff/tests/DiffTest.php delete mode 100644 vendor/sebastian/diff/tests/DifferTest.php delete mode 100644 vendor/sebastian/diff/tests/Exception/ConfigurationExceptionTest.php delete mode 100644 vendor/sebastian/diff/tests/Exception/InvalidArgumentExceptionTest.php delete mode 100644 vendor/sebastian/diff/tests/LineTest.php delete mode 100644 vendor/sebastian/diff/tests/LongestCommonSubsequenceTest.php delete mode 100644 vendor/sebastian/diff/tests/MemoryEfficientImplementationTest.php delete mode 100644 vendor/sebastian/diff/tests/Output/AbstractChunkOutputBuilderTest.php delete mode 100644 vendor/sebastian/diff/tests/Output/DiffOnlyOutputBuilderTest.php delete mode 100644 vendor/sebastian/diff/tests/Output/Integration/StrictUnifiedDiffOutputBuilderIntegrationTest.php delete mode 100644 vendor/sebastian/diff/tests/Output/Integration/UnifiedDiffOutputBuilderIntegrationTest.php delete mode 100644 vendor/sebastian/diff/tests/Output/StrictUnifiedDiffOutputBuilderDataProvider.php delete mode 100644 vendor/sebastian/diff/tests/Output/StrictUnifiedDiffOutputBuilderTest.php delete mode 100644 vendor/sebastian/diff/tests/Output/UnifiedDiffOutputBuilderDataProvider.php delete mode 100644 vendor/sebastian/diff/tests/Output/UnifiedDiffOutputBuilderTest.php delete mode 100644 vendor/sebastian/diff/tests/ParserTest.php delete mode 100644 vendor/sebastian/diff/tests/TimeEfficientImplementationTest.php delete mode 100644 vendor/sebastian/diff/tests/Utils/FileUtils.php delete mode 100644 vendor/sebastian/diff/tests/Utils/UnifiedDiffAssertTrait.php delete mode 100644 vendor/sebastian/diff/tests/Utils/UnifiedDiffAssertTraitIntegrationTest.php delete mode 100644 vendor/sebastian/diff/tests/Utils/UnifiedDiffAssertTraitTest.php delete mode 100644 vendor/sebastian/diff/tests/fixtures/.editorconfig delete mode 100644 vendor/sebastian/diff/tests/fixtures/UnifiedDiffAssertTraitIntegrationTest/1_a.txt delete mode 100644 vendor/sebastian/diff/tests/fixtures/UnifiedDiffAssertTraitIntegrationTest/1_b.txt delete mode 100644 vendor/sebastian/diff/tests/fixtures/UnifiedDiffAssertTraitIntegrationTest/2_a.txt delete mode 100644 vendor/sebastian/diff/tests/fixtures/UnifiedDiffAssertTraitIntegrationTest/2_b.txt delete mode 100644 vendor/sebastian/diff/tests/fixtures/out/.editorconfig delete mode 100644 vendor/sebastian/diff/tests/fixtures/out/.gitignore delete mode 100644 vendor/sebastian/diff/tests/fixtures/patch.txt delete mode 100644 vendor/sebastian/diff/tests/fixtures/patch2.txt delete mode 100644 vendor/sebastian/diff/tests/fixtures/serialized_diff.bin delete mode 100644 vendor/sebastian/environment/.github/FUNDING.yml delete mode 100644 vendor/sebastian/environment/.gitignore delete mode 100644 vendor/sebastian/environment/.php_cs.dist delete mode 100644 vendor/sebastian/environment/.travis.yml delete mode 100644 vendor/sebastian/environment/build.xml delete mode 100644 vendor/sebastian/environment/phpunit.xml delete mode 100644 vendor/sebastian/environment/tests/ConsoleTest.php delete mode 100644 vendor/sebastian/environment/tests/OperatingSystemTest.php delete mode 100644 vendor/sebastian/environment/tests/RuntimeTest.php delete mode 100644 vendor/sebastian/exporter/.github/FUNDING.yml delete mode 100644 vendor/sebastian/exporter/.gitignore delete mode 100644 vendor/sebastian/exporter/.php_cs.dist delete mode 100644 vendor/sebastian/exporter/.travis.yml delete mode 100644 vendor/sebastian/exporter/build.xml delete mode 100644 vendor/sebastian/exporter/phpunit.xml delete mode 100644 vendor/sebastian/exporter/tests/ExporterTest.php delete mode 100644 vendor/sebastian/global-state/.github/stale.yml delete mode 100644 vendor/sebastian/global-state/.gitignore delete mode 100644 vendor/sebastian/global-state/.php_cs.dist delete mode 100644 vendor/sebastian/global-state/.travis.yml delete mode 100644 vendor/sebastian/global-state/build.xml delete mode 100644 vendor/sebastian/global-state/phpunit.xml rename vendor/sebastian/global-state/src/{Blacklist.php => ExcludeList.php} (84%) delete mode 100644 vendor/sebastian/global-state/tests/BlacklistTest.php delete mode 100644 vendor/sebastian/global-state/tests/CodeExporterTest.php delete mode 100644 vendor/sebastian/global-state/tests/RestorerTest.php delete mode 100644 vendor/sebastian/global-state/tests/SnapshotTest.php delete mode 100644 vendor/sebastian/global-state/tests/_fixture/BlacklistedImplementor.php delete mode 100644 vendor/sebastian/global-state/tests/_fixture/SnapshotClass.php create mode 100644 vendor/sebastian/lines-of-code/.psalm/baseline.xml create mode 100644 vendor/sebastian/lines-of-code/.psalm/config.xml create mode 100644 vendor/sebastian/lines-of-code/ChangeLog.md create mode 100644 vendor/sebastian/lines-of-code/LICENSE create mode 100644 vendor/sebastian/lines-of-code/README.md create mode 100644 vendor/sebastian/lines-of-code/composer.json create mode 100644 vendor/sebastian/lines-of-code/src/Counter.php create mode 100644 vendor/sebastian/lines-of-code/src/Exception/Exception.php create mode 100644 vendor/sebastian/lines-of-code/src/Exception/IllogicalValuesException.php create mode 100644 vendor/sebastian/lines-of-code/src/Exception/NegativeValueException.php rename vendor/sebastian/{global-state/tests/_fixture/BlacklistedClass.php => lines-of-code/src/Exception/RuntimeException.php} (57%) create mode 100644 vendor/sebastian/lines-of-code/src/LineCountingVisitor.php create mode 100644 vendor/sebastian/lines-of-code/src/LinesOfCode.php delete mode 100644 vendor/sebastian/object-enumerator/.gitignore delete mode 100644 vendor/sebastian/object-enumerator/.php_cs create mode 100644 vendor/sebastian/object-enumerator/.psalm/baseline.xml create mode 100644 vendor/sebastian/object-enumerator/.psalm/config.xml delete mode 100644 vendor/sebastian/object-enumerator/.travis.yml delete mode 100644 vendor/sebastian/object-enumerator/build.xml delete mode 100644 vendor/sebastian/object-enumerator/tests/EnumeratorTest.php delete mode 100644 vendor/sebastian/object-enumerator/tests/_fixture/ExceptionThrower.php delete mode 100644 vendor/sebastian/object-reflector/.gitignore delete mode 100644 vendor/sebastian/object-reflector/.php_cs create mode 100644 vendor/sebastian/object-reflector/.psalm/baseline.xml create mode 100644 vendor/sebastian/object-reflector/.psalm/config.xml delete mode 100644 vendor/sebastian/object-reflector/.travis.yml delete mode 100644 vendor/sebastian/object-reflector/build.xml delete mode 100644 vendor/sebastian/object-reflector/phpunit.xml delete mode 100644 vendor/sebastian/object-reflector/tests/ObjectReflectorTest.php delete mode 100644 vendor/sebastian/object-reflector/tests/_fixture/ChildClass.php delete mode 100644 vendor/sebastian/object-reflector/tests/_fixture/ClassWithIntegerAttributeName.php delete mode 100644 vendor/sebastian/object-reflector/tests/_fixture/ParentClass.php delete mode 100644 vendor/sebastian/recursion-context/.gitignore create mode 100644 vendor/sebastian/recursion-context/.psalm/baseline.xml create mode 100644 vendor/sebastian/recursion-context/.psalm/config.xml delete mode 100644 vendor/sebastian/recursion-context/.travis.yml create mode 100644 vendor/sebastian/recursion-context/ChangeLog.md delete mode 100644 vendor/sebastian/recursion-context/build.xml delete mode 100644 vendor/sebastian/recursion-context/phpunit.xml delete mode 100644 vendor/sebastian/recursion-context/tests/ContextTest.php rename vendor/{phpunit/php-token-stream => sebastian/resource-operations}/.gitattributes (53%) delete mode 100644 vendor/sebastian/resource-operations/.github/stale.yml delete mode 100644 vendor/sebastian/resource-operations/.php_cs.dist delete mode 100644 vendor/sebastian/resource-operations/build.xml delete mode 100644 vendor/sebastian/resource-operations/tests/ResourceOperationsTest.php delete mode 100644 vendor/sebastian/type/.gitattributes delete mode 100644 vendor/sebastian/type/.github/FUNDING.yml delete mode 100644 vendor/sebastian/type/.gitignore delete mode 100644 vendor/sebastian/type/.idea/inspectionProfiles/Project_Default.xml delete mode 100644 vendor/sebastian/type/.idea/misc.xml delete mode 100644 vendor/sebastian/type/.idea/modules.xml delete mode 100644 vendor/sebastian/type/.idea/php-inspections-ea-ultimate.xml delete mode 100644 vendor/sebastian/type/.idea/php.xml delete mode 100644 vendor/sebastian/type/.idea/type.iml delete mode 100644 vendor/sebastian/type/.idea/vcs.xml delete mode 100644 vendor/sebastian/type/.php_cs.dist delete mode 100644 vendor/sebastian/type/.travis.yml delete mode 100644 vendor/sebastian/type/build.xml delete mode 100644 vendor/sebastian/type/phive.xml delete mode 100644 vendor/sebastian/type/phpunit.xml delete mode 100644 vendor/sebastian/type/psalm.xml create mode 100644 vendor/sebastian/type/src/MixedType.php create mode 100644 vendor/sebastian/type/src/ReflectionMapper.php create mode 100644 vendor/sebastian/type/src/StaticType.php create mode 100644 vendor/sebastian/type/src/UnionType.php delete mode 100644 vendor/sebastian/type/tests/_fixture/ChildClass.php delete mode 100644 vendor/sebastian/type/tests/_fixture/ClassWithCallbackMethods.php delete mode 100644 vendor/sebastian/type/tests/_fixture/ClassWithInvokeMethod.php delete mode 100644 vendor/sebastian/type/tests/_fixture/Iterator.php delete mode 100644 vendor/sebastian/type/tests/_fixture/ParentClass.php delete mode 100644 vendor/sebastian/type/tests/_fixture/callback_function.php delete mode 100644 vendor/sebastian/type/tests/unit/CallableTypeTest.php delete mode 100644 vendor/sebastian/type/tests/unit/GenericObjectTypeTest.php delete mode 100644 vendor/sebastian/type/tests/unit/IterableTypeTest.php delete mode 100644 vendor/sebastian/type/tests/unit/NullTypeTest.php delete mode 100644 vendor/sebastian/type/tests/unit/ObjectTypeTest.php delete mode 100644 vendor/sebastian/type/tests/unit/SimpleTypeTest.php delete mode 100644 vendor/sebastian/type/tests/unit/TypeNameTest.php delete mode 100644 vendor/sebastian/type/tests/unit/TypeTest.php delete mode 100644 vendor/sebastian/type/tests/unit/UnknownTypeTest.php delete mode 100644 vendor/sebastian/type/tests/unit/VoidTypeTest.php delete mode 100644 vendor/sebastian/version/.php_cs create mode 100644 vendor/sebastian/version/ChangeLog.md rename vendor/spatie/laravel-schedule-monitor/{.php_cs => .php_cs.dist} (100%) delete mode 100644 vendor/spatie/laravel-schedule-monitor/CONTRIBUTING.md create mode 100644 vendor/vlucas/phpdotenv/src/Exception/InvalidEncodingException.php delete mode 100644 vendor/vlucas/phpdotenv/src/Loader/Parser.php create mode 100644 vendor/vlucas/phpdotenv/src/Loader/Resolver.php create mode 100644 vendor/vlucas/phpdotenv/src/Parser/Entry.php create mode 100644 vendor/vlucas/phpdotenv/src/Parser/EntryParser.php create mode 100644 vendor/vlucas/phpdotenv/src/Parser/Lexer.php rename vendor/vlucas/phpdotenv/src/{Loader => Parser}/Lines.php (54%) create mode 100644 vendor/vlucas/phpdotenv/src/Parser/Parser.php create mode 100644 vendor/vlucas/phpdotenv/src/Parser/ParserInterface.php rename vendor/vlucas/phpdotenv/src/{Loader => Parser}/Value.php (67%) delete mode 100644 vendor/vlucas/phpdotenv/src/Regex/Regex.php delete mode 100644 vendor/vlucas/phpdotenv/src/Repository/AbstractRepository.php create mode 100644 vendor/vlucas/phpdotenv/src/Repository/Adapter/AdapterInterface.php delete mode 100644 vendor/vlucas/phpdotenv/src/Repository/Adapter/AvailabilityInterface.php create mode 100644 vendor/vlucas/phpdotenv/src/Repository/Adapter/GuardedWriter.php create mode 100644 vendor/vlucas/phpdotenv/src/Repository/Adapter/ImmutableWriter.php create mode 100644 vendor/vlucas/phpdotenv/src/Repository/Adapter/MultiReader.php create mode 100644 vendor/vlucas/phpdotenv/src/Repository/Adapter/MultiWriter.php create mode 100644 vendor/vlucas/phpdotenv/src/Repository/Adapter/ReplacingWriter.php delete mode 100644 vendor/vlucas/phpdotenv/src/Result/Result.php create mode 100644 vendor/vlucas/phpdotenv/src/Util/Regex.php create mode 100644 vendor/vlucas/phpdotenv/src/Util/Str.php diff --git a/.env b/.env index aee0861fc..e5cb1db7d 100644 --- a/.env +++ b/.env @@ -1,7 +1,7 @@ APP_NAME='W4RP Services' APP_ENV=local APP_KEY=base64:PBOxrGFJAtwj9SDF4F0DZ1J+6MjrJmRiPZJQwRdy3XQ= -APP_DEBUG=true +APP_DEBUG=false APP_URL=https://services.w4rp.space LOG_CHANNEL=daily diff --git a/app/Providers/AppServiceProvider.php b/app/Providers/AppServiceProvider.php index 706c00313..ff0bcec82 100644 --- a/app/Providers/AppServiceProvider.php +++ b/app/Providers/AppServiceProvider.php @@ -4,6 +4,7 @@ namespace App\Providers; use Illuminate\Support\ServiceProvider; use Illuminate\Support\Facades\Schema; +use Illuminate\Pagination\Paginator; class AppServiceProvider extends ServiceProvider { @@ -15,6 +16,7 @@ class AppServiceProvider extends ServiceProvider public function boot() { Schema::defaultStringLength(191); + Paginator::useBootstrap(); } /** diff --git a/composer.json b/composer.json index bc270a22e..2ad182465 100644 --- a/composer.json +++ b/composer.json @@ -5,21 +5,21 @@ "license": "MIT", "type": "project", "require": { - "php": "^7.1.3", + "php": "^7.4.0", "ext-redis": "^5.3", "eveseat/eseye": "^2.3", "fideloper/proxy": "^4.0", - "guzzlehttp/guzzle": "^6.3", + "guzzlehttp/guzzle": "^7.0.1", "khill/lavacharts": "^3.1.14", - "laravel/framework": "^7.0", + "laravel/framework": "^8.0", "laravel/helpers": "^1.4", - "laravel/horizon": "^4.0", + "laravel/horizon": "^5.0", "laravel/socialite": "^5.1", - "laravel/ui": "^2.0", + "laravel/ui": "^3.0", "laravelcollective/html": "^6.0", "socialiteproviders/manager": "^4.0", "spatie/laravel-rate-limited-job-middleware": "^1.5", - "spatie/laravel-schedule-monitor": "2.0.1", + "spatie/laravel-schedule-monitor": "2.3.0", "twbs/bootstrap": "^4.5", "web-token/jwt-easy": "^2.2", "web-token/jwt-signature-algorithm-ecdsa": "^2.2", @@ -31,8 +31,8 @@ "filp/whoops": "^2.0", "fzaninotto/faker": "^1.4", "mockery/mockery": "^1.0", - "phpunit/phpunit": "^8.5", - "nunomaduro/collision": "^4.1" + "phpunit/phpunit": "^9.0", + "nunomaduro/collision": "^5.0" }, "autoload": { "classmap": [ diff --git a/composer.lock b/composer.lock index 39787c997..ffd1b3015 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": "2af08db67aa9de535253cfafeaab5aa3", + "content-hash": "75386022f0b68694d58a623230390564", "packages": [ { "name": "brick/math", @@ -62,65 +62,6 @@ ], "time": "2021-01-20T22:51:39+00:00" }, - { - "name": "cakephp/chronos", - "version": "2.1.2", - "source": { - "type": "git", - "url": "https://github.com/cakephp/chronos.git", - "reference": "1d187c71587c97520c00491f626e0f255144953e" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/cakephp/chronos/zipball/1d187c71587c97520c00491f626e0f255144953e", - "reference": "1d187c71587c97520c00491f626e0f255144953e", - "shasum": "" - }, - "require": { - "php": ">=7.2" - }, - "require-dev": { - "cakephp/cakephp-codesniffer": "^4.0", - "phpunit/phpunit": "^8.0 || ^9.0" - }, - "type": "library", - "autoload": { - "psr-4": { - "Cake\\Chronos\\": "src/" - }, - "files": [ - "src/carbon_compat.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Brian Nesbitt", - "email": "brian@nesbot.com", - "homepage": "http://nesbot.com" - }, - { - "name": "The CakePHP Team", - "homepage": "http://cakephp.org" - } - ], - "description": "A simple API extension for DateTime.", - "homepage": "http://cakephp.org", - "keywords": [ - "date", - "datetime", - "time" - ], - "support": { - "irc": "irc://irc.freenode.org/cakephp", - "issues": "https://github.com/cakephp/chronos/issues", - "source": "https://github.com/cakephp/chronos" - }, - "time": "2021-04-07T01:06:46+00:00" - }, { "name": "doctrine/inflector", "version": "2.0.3", @@ -298,30 +239,32 @@ }, { "name": "dragonmantank/cron-expression", - "version": "v2.3.1", + "version": "v3.1.0", "source": { "type": "git", "url": "https://github.com/dragonmantank/cron-expression.git", - "reference": "65b2d8ee1f10915efb3b55597da3404f096acba2" + "reference": "7a8c6e56ab3ffcc538d05e8155bb42269abf1a0c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/dragonmantank/cron-expression/zipball/65b2d8ee1f10915efb3b55597da3404f096acba2", - "reference": "65b2d8ee1f10915efb3b55597da3404f096acba2", + "url": "https://api.github.com/repos/dragonmantank/cron-expression/zipball/7a8c6e56ab3ffcc538d05e8155bb42269abf1a0c", + "reference": "7a8c6e56ab3ffcc538d05e8155bb42269abf1a0c", "shasum": "" }, "require": { - "php": "^7.0|^8.0" + "php": "^7.2|^8.0", + "webmozart/assert": "^1.7.0" + }, + "replace": { + "mtdowling/cron-expression": "^1.0" }, "require-dev": { - "phpunit/phpunit": "^6.4|^7.0|^8.0|^9.0" + "phpstan/extension-installer": "^1.0", + "phpstan/phpstan": "^0.12", + "phpstan/phpstan-webmozart-assert": "^0.12.7", + "phpunit/phpunit": "^7.0|^8.0|^9.0" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.3-dev" - } - }, "autoload": { "psr-4": { "Cron\\": "src/Cron/" @@ -332,11 +275,6 @@ "MIT" ], "authors": [ - { - "name": "Michael Dowling", - "email": "mtdowling@gmail.com", - "homepage": "https://github.com/mtdowling" - }, { "name": "Chris Tankersley", "email": "chris@ctankersley.com", @@ -350,7 +288,7 @@ ], "support": { "issues": "https://github.com/dragonmantank/cron-expression/issues", - "source": "https://github.com/dragonmantank/cron-expression/tree/v2.3.1" + "source": "https://github.com/dragonmantank/cron-expression/tree/v3.1.0" }, "funding": [ { @@ -358,7 +296,7 @@ "type": "github" } ], - "time": "2020-10-13T00:52:37+00:00" + "time": "2020-11-24T19:55:57+00:00" }, { "name": "egulias/email-validator", @@ -430,16 +368,16 @@ }, { "name": "eveseat/eseye", - "version": "2.3.2", + "version": "2.4.0", "source": { "type": "git", "url": "https://github.com/eveseat/eseye.git", - "reference": "69a0180f1727369614971fe377a1a8b2301c505d" + "reference": "b9d6753ccad9edce2bed6c91142f62eaebe24a8c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/eveseat/eseye/zipball/69a0180f1727369614971fe377a1a8b2301c505d", - "reference": "69a0180f1727369614971fe377a1a8b2301c505d", + "url": "https://api.github.com/repos/eveseat/eseye/zipball/b9d6753ccad9edce2bed6c91142f62eaebe24a8c", + "reference": "b9d6753ccad9edce2bed6c91142f62eaebe24a8c", "shasum": "" }, "require": { @@ -447,7 +385,7 @@ "ext-json": "*", "ext-mbstring": "*", "ext-openssl": "*", - "guzzlehttp/guzzle": "^6.2", + "guzzlehttp/guzzle": "^6.2|^7.0", "monolog/monolog": "^2.0", "nesbot/carbon": "^2.0", "php": ">= 7.2", @@ -459,8 +397,9 @@ }, "require-dev": { "codeclimate/php-test-reporter": "dev-master", + "m6web/redis-mock": "^5.0", "mikey179/vfsstream": "~1", - "phpunit/phpunit": "^5.7" + "phpunit/phpunit": "^8.0|^9.0" }, "bin": [ "bin/tokengenerator" @@ -487,9 +426,9 @@ "description": "A Standalone PHP ESI (EVE Swagger Interface) Client Library", "support": { "issues": "https://github.com/eveseat/eseye/issues", - "source": "https://github.com/eveseat/eseye/tree/2.3.2" + "source": "https://github.com/eveseat/eseye/tree/2.4.0" }, - "time": "2021-04-04T20:29:19+00:00" + "time": "2021-05-19T05:42:25+00:00" }, { "name": "fgrosse/phpasn1", @@ -625,38 +564,111 @@ "time": "2020-10-22T13:48:01+00:00" }, { - "name": "guzzlehttp/guzzle", - "version": "6.5.5", + "name": "graham-campbell/result-type", + "version": "v1.0.1", "source": { "type": "git", - "url": "https://github.com/guzzle/guzzle.git", - "reference": "9d4290de1cfd701f38099ef7e183b64b4b7b0c5e" + "url": "https://github.com/GrahamCampbell/Result-Type.git", + "reference": "7e279d2cd5d7fbb156ce46daada972355cea27bb" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/guzzle/zipball/9d4290de1cfd701f38099ef7e183b64b4b7b0c5e", - "reference": "9d4290de1cfd701f38099ef7e183b64b4b7b0c5e", + "url": "https://api.github.com/repos/GrahamCampbell/Result-Type/zipball/7e279d2cd5d7fbb156ce46daada972355cea27bb", + "reference": "7e279d2cd5d7fbb156ce46daada972355cea27bb", + "shasum": "" + }, + "require": { + "php": "^7.0|^8.0", + "phpoption/phpoption": "^1.7.3" + }, + "require-dev": { + "phpunit/phpunit": "^6.5|^7.5|^8.5|^9.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "autoload": { + "psr-4": { + "GrahamCampbell\\ResultType\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Graham Campbell", + "email": "graham@alt-three.com" + } + ], + "description": "An Implementation Of The Result Type", + "keywords": [ + "Graham Campbell", + "GrahamCampbell", + "Result Type", + "Result-Type", + "result" + ], + "support": { + "issues": "https://github.com/GrahamCampbell/Result-Type/issues", + "source": "https://github.com/GrahamCampbell/Result-Type/tree/v1.0.1" + }, + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/graham-campbell/result-type", + "type": "tidelift" + } + ], + "time": "2020-04-13T13:17:36+00:00" + }, + { + "name": "guzzlehttp/guzzle", + "version": "7.3.0", + "source": { + "type": "git", + "url": "https://github.com/guzzle/guzzle.git", + "reference": "7008573787b430c1c1f650e3722d9bba59967628" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/guzzle/guzzle/zipball/7008573787b430c1c1f650e3722d9bba59967628", + "reference": "7008573787b430c1c1f650e3722d9bba59967628", "shasum": "" }, "require": { "ext-json": "*", - "guzzlehttp/promises": "^1.0", - "guzzlehttp/psr7": "^1.6.1", - "php": ">=5.5", - "symfony/polyfill-intl-idn": "^1.17.0" + "guzzlehttp/promises": "^1.4", + "guzzlehttp/psr7": "^1.7 || ^2.0", + "php": "^7.2.5 || ^8.0", + "psr/http-client": "^1.0" + }, + "provide": { + "psr/http-client-implementation": "1.0" }, "require-dev": { + "bamarni/composer-bin-plugin": "^1.4.1", "ext-curl": "*", - "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.4 || ^7.0", + "php-http/client-integration-tests": "^3.0", + "phpunit/phpunit": "^8.5.5 || ^9.3.5", "psr/log": "^1.1" }, "suggest": { + "ext-curl": "Required for CURL handler support", + "ext-intl": "Required for Internationalized Domain Name (IDN) support", "psr/log": "Required for using the Log middleware" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "6.5-dev" + "dev-master": "7.3-dev" } }, "autoload": { @@ -676,6 +688,11 @@ "name": "Michael Dowling", "email": "mtdowling@gmail.com", "homepage": "https://github.com/mtdowling" + }, + { + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com", + "homepage": "https://sagikazarmark.hu" } ], "description": "Guzzle is a PHP HTTP client library", @@ -686,14 +703,34 @@ "framework", "http", "http client", + "psr-18", + "psr-7", "rest", "web service" ], "support": { "issues": "https://github.com/guzzle/guzzle/issues", - "source": "https://github.com/guzzle/guzzle/tree/6.5" + "source": "https://github.com/guzzle/guzzle/tree/7.3.0" }, - "time": "2020-06-16T21:01:06+00:00" + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://github.com/Nyholm", + "type": "github" + }, + { + "url": "https://github.com/alexeyshockov", + "type": "github" + }, + { + "url": "https://github.com/gmponos", + "type": "github" + } + ], + "time": "2021-03-23T11:33:13+00:00" }, { "name": "guzzlehttp/promises", @@ -901,21 +938,21 @@ }, { "name": "laravel/framework", - "version": "v7.30.4", + "version": "v8.44.0", "source": { "type": "git", "url": "https://github.com/laravel/framework.git", - "reference": "9dd38140dc2924daa1a020a3d7a45f9ceff03df3" + "reference": "7b3b27dc8911ab02a69731af2ba97b5130b2ddb8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/framework/zipball/9dd38140dc2924daa1a020a3d7a45f9ceff03df3", - "reference": "9dd38140dc2924daa1a020a3d7a45f9ceff03df3", + "url": "https://api.github.com/repos/laravel/framework/zipball/7b3b27dc8911ab02a69731af2ba97b5130b2ddb8", + "reference": "7b3b27dc8911ab02a69731af2ba97b5130b2ddb8", "shasum": "" }, "require": { "doctrine/inflector": "^1.4|^2.0", - "dragonmantank/cron-expression": "^2.3.1", + "dragonmantank/cron-expression": "^3.0.2", "egulias/email-validator": "^2.1.10", "ext-json": "*", "ext-mbstring": "*", @@ -925,23 +962,22 @@ "monolog/monolog": "^2.0", "nesbot/carbon": "^2.31", "opis/closure": "^3.6", - "php": "^7.2.5|^8.0", + "php": "^7.3|^8.0", "psr/container": "^1.0", "psr/simple-cache": "^1.0", - "ramsey/uuid": "^3.7|^4.0", + "ramsey/uuid": "^4.0", "swiftmailer/swiftmailer": "^6.0", - "symfony/console": "^5.0", - "symfony/error-handler": "^5.0", - "symfony/finder": "^5.0", - "symfony/http-foundation": "^5.0", - "symfony/http-kernel": "^5.0", - "symfony/mime": "^5.0", - "symfony/polyfill-php73": "^1.17", - "symfony/process": "^5.0", - "symfony/routing": "^5.0", - "symfony/var-dumper": "^5.0", + "symfony/console": "^5.1.4", + "symfony/error-handler": "^5.1.4", + "symfony/finder": "^5.1.4", + "symfony/http-foundation": "^5.1.4", + "symfony/http-kernel": "^5.1.4", + "symfony/mime": "^5.1.4", + "symfony/process": "^5.1.4", + "symfony/routing": "^5.1.4", + "symfony/var-dumper": "^5.1.4", "tijsverkoyen/css-to-inline-styles": "^2.2.2", - "vlucas/phpdotenv": "^4.0", + "vlucas/phpdotenv": "^5.2", "voku/portable-ascii": "^1.4.8" }, "conflict": { @@ -955,6 +991,7 @@ "illuminate/broadcasting": "self.version", "illuminate/bus": "self.version", "illuminate/cache": "self.version", + "illuminate/collections": "self.version", "illuminate/config": "self.version", "illuminate/console": "self.version", "illuminate/container": "self.version", @@ -967,6 +1004,7 @@ "illuminate/hashing": "self.version", "illuminate/http": "self.version", "illuminate/log": "self.version", + "illuminate/macroable": "self.version", "illuminate/mail": "self.version", "illuminate/notifications": "self.version", "illuminate/pagination": "self.version", @@ -983,21 +1021,21 @@ }, "require-dev": { "aws/aws-sdk-php": "^3.155", - "doctrine/dbal": "^2.6", + "doctrine/dbal": "^2.6|^3.0", "filp/whoops": "^2.8", - "guzzlehttp/guzzle": "^6.3.1|^7.0.1", + "guzzlehttp/guzzle": "^6.5.5|^7.0.1", "league/flysystem-cached-adapter": "^1.0", - "mockery/mockery": "~1.3.3|^1.4.2", - "moontoast/math": "^1.1", - "orchestra/testbench-core": "^5.8", + "mockery/mockery": "^1.4.2", + "orchestra/testbench-core": "^6.8", "pda/pheanstalk": "^4.0", - "phpunit/phpunit": "^8.4|^9.3.3", + "phpunit/phpunit": "^8.5.8|^9.3.3", "predis/predis": "^1.1.1", - "symfony/cache": "^5.0" + "symfony/cache": "^5.1.4" }, "suggest": { "aws/aws-sdk-php": "Required to use the SQS queue driver, DynamoDb failed job storage and SES mail driver (^3.155).", - "doctrine/dbal": "Required to rename columns and drop SQLite columns (^2.6).", + "brianium/paratest": "Required to run tests in parallel (^6.0).", + "doctrine/dbal": "Required to rename columns and drop SQLite columns (^2.6|^3.0).", "ext-ftp": "Required to use the Flysystem FTP driver.", "ext-gd": "Required to use Illuminate\\Http\\Testing\\FileFactory::image().", "ext-memcached": "Required to use the memcache cache driver.", @@ -1006,37 +1044,42 @@ "ext-redis": "Required to use the Redis cache and queue drivers (^4.0|^5.0).", "fakerphp/faker": "Required to use the eloquent factory builder (^1.9.1).", "filp/whoops": "Required for friendly error pages in development (^2.8).", - "guzzlehttp/guzzle": "Required to use the HTTP Client, Mailgun mail driver and the ping methods on schedules (^6.3.1|^7.0.1).", + "guzzlehttp/guzzle": "Required to use the HTTP Client, Mailgun mail driver and the ping methods on schedules (^6.5.5|^7.0.1).", "laravel/tinker": "Required to use the tinker console command (^2.0).", "league/flysystem-aws-s3-v3": "Required to use the Flysystem S3 driver (^1.0).", "league/flysystem-cached-adapter": "Required to use the Flysystem cache (^1.0).", "league/flysystem-sftp": "Required to use the Flysystem SFTP driver (^1.0).", - "mockery/mockery": "Required to use mocking (~1.3.3|^1.4.2).", - "moontoast/math": "Required to use ordered UUIDs (^1.1).", + "mockery/mockery": "Required to use mocking (^1.4.2).", "nyholm/psr7": "Required to use PSR-7 bridging features (^1.2).", "pda/pheanstalk": "Required to use the beanstalk queue driver (^4.0).", - "phpunit/phpunit": "Required to use assertions and run tests (^8.4|^9.3.3).", + "phpunit/phpunit": "Required to use assertions and run tests (^8.5.8|^9.3.3).", "predis/predis": "Required to use the predis connector (^1.1.2).", "psr/http-message": "Required to allow Storage::put to accept a StreamInterface (^1.0).", - "pusher/pusher-php-server": "Required to use the Pusher broadcast driver (^4.0).", - "symfony/cache": "Required to PSR-6 cache bridge (^5.0).", - "symfony/filesystem": "Required to create relative storage directory symbolic links (^5.0).", + "pusher/pusher-php-server": "Required to use the Pusher broadcast driver (^4.0|^5.0|^6.0).", + "symfony/cache": "Required to PSR-6 cache bridge (^5.1.4).", + "symfony/filesystem": "Required to enable support for relative symbolic links (^5.1.4).", "symfony/psr-http-message-bridge": "Required to use PSR-7 bridging features (^2.0).", "wildbit/swiftmailer-postmark": "Required to use Postmark mail driver (^3.0)." }, "type": "library", "extra": { "branch-alias": { - "dev-master": "7.x-dev" + "dev-master": "8.x-dev" } }, "autoload": { "files": [ + "src/Illuminate/Collections/helpers.php", + "src/Illuminate/Events/functions.php", "src/Illuminate/Foundation/helpers.php", "src/Illuminate/Support/helpers.php" ], "psr-4": { - "Illuminate\\": "src/Illuminate/" + "Illuminate\\": "src/Illuminate/", + "Illuminate\\Support\\": [ + "src/Illuminate/Macroable/", + "src/Illuminate/Collections/" + ] } }, "notification-url": "https://packagist.org/downloads/", @@ -1059,7 +1102,7 @@ "issues": "https://github.com/laravel/framework/issues", "source": "https://github.com/laravel/framework" }, - "time": "2021-01-21T14:10:48+00:00" + "time": "2021-05-27T16:46:06+00:00" }, { "name": "laravel/helpers", @@ -1119,35 +1162,35 @@ }, { "name": "laravel/horizon", - "version": "v4.3.5", + "version": "v5.7.8", "source": { "type": "git", "url": "https://github.com/laravel/horizon.git", - "reference": "b3fba0daaaaf5e84197b06dd25f3b27bb7301171" + "reference": "2b5628b598c813650458dc7e4afacb500d72ff9a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/horizon/zipball/b3fba0daaaaf5e84197b06dd25f3b27bb7301171", - "reference": "b3fba0daaaaf5e84197b06dd25f3b27bb7301171", + "url": "https://api.github.com/repos/laravel/horizon/zipball/2b5628b598c813650458dc7e4afacb500d72ff9a", + "reference": "2b5628b598c813650458dc7e4afacb500d72ff9a", "shasum": "" }, "require": { - "cakephp/chronos": "^2.0", "ext-json": "*", "ext-pcntl": "*", "ext-posix": "*", - "illuminate/contracts": "^7.0", - "illuminate/queue": "^7.0", - "illuminate/support": "^7.0", - "php": "^7.2", - "ramsey/uuid": "^3.5|^4.0", + "illuminate/contracts": "^8.17", + "illuminate/queue": "^8.17", + "illuminate/support": "^8.17", + "nesbot/carbon": "^2.17", + "php": "^7.3|^8.0", + "ramsey/uuid": "^4.0", "symfony/error-handler": "^5.0", "symfony/process": "^5.0" }, "require-dev": { "mockery/mockery": "^1.0", - "orchestra/testbench": "^5.0", - "phpunit/phpunit": "^8.0", + "orchestra/testbench": "^6.0", + "phpunit/phpunit": "^9.0", "predis/predis": "^1.1" }, "suggest": { @@ -1157,7 +1200,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "4.x-dev" + "dev-master": "5.x-dev" }, "laravel": { "providers": [ @@ -1190,9 +1233,9 @@ ], "support": { "issues": "https://github.com/laravel/horizon/issues", - "source": "https://github.com/laravel/horizon/tree/4.x" + "source": "https://github.com/laravel/horizon/tree/v5.7.8" }, - "time": "2020-09-08T13:19:23+00:00" + "time": "2021-05-27T12:07:58+00:00" }, { "name": "laravel/socialite", @@ -1265,26 +1308,30 @@ }, { "name": "laravel/ui", - "version": "v2.5.0", + "version": "v3.3.0", "source": { "type": "git", "url": "https://github.com/laravel/ui.git", - "reference": "d01a705763c243b07be795e9d1bb47f89260f73d" + "reference": "07d725813350c695c779382cbd6dac0ab8665537" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/ui/zipball/d01a705763c243b07be795e9d1bb47f89260f73d", - "reference": "d01a705763c243b07be795e9d1bb47f89260f73d", + "url": "https://api.github.com/repos/laravel/ui/zipball/07d725813350c695c779382cbd6dac0ab8665537", + "reference": "07d725813350c695c779382cbd6dac0ab8665537", "shasum": "" }, "require": { - "illuminate/console": "^7.0", - "illuminate/filesystem": "^7.0", - "illuminate/support": "^7.0", - "php": "^7.2.5|^8.0" + "illuminate/console": "^8.42", + "illuminate/filesystem": "^8.42", + "illuminate/support": "^8.42", + "illuminate/validation": "^8.42", + "php": "^7.3|^8.0" }, "type": "library", "extra": { + "branch-alias": { + "dev-master": "3.x-dev" + }, "laravel": { "providers": [ "Laravel\\Ui\\UiServiceProvider" @@ -1313,10 +1360,9 @@ "ui" ], "support": { - "issues": "https://github.com/laravel/ui/issues", - "source": "https://github.com/laravel/ui/tree/v2.5.0" + "source": "https://github.com/laravel/ui/tree/v3.3.0" }, - "time": "2020-11-03T19:45:19+00:00" + "time": "2021-05-25T16:45:33+00:00" }, { "name": "laravelcollective/html", @@ -1719,16 +1765,16 @@ }, { "name": "lorisleiva/cron-translator", - "version": "v0.1.1", + "version": "v0.2.0", "source": { "type": "git", "url": "https://github.com/lorisleiva/cron-translator.git", - "reference": "784a6f6255a4b5f45da5d89dc6ec631a14d7b011" + "reference": "764996770558dddc7def8619095391a4ec8048f2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/lorisleiva/cron-translator/zipball/784a6f6255a4b5f45da5d89dc6ec631a14d7b011", - "reference": "784a6f6255a4b5f45da5d89dc6ec631a14d7b011", + "url": "https://api.github.com/repos/lorisleiva/cron-translator/zipball/764996770558dddc7def8619095391a4ec8048f2", + "reference": "764996770558dddc7def8619095391a4ec8048f2", "shasum": "" }, "require-dev": { @@ -1760,9 +1806,15 @@ ], "support": { "issues": "https://github.com/lorisleiva/cron-translator/issues", - "source": "https://github.com/lorisleiva/cron-translator/tree/v0.1.1" + "source": "https://github.com/lorisleiva/cron-translator/tree/v0.2.0" }, - "time": "2020-03-01T14:44:47+00:00" + "funding": [ + { + "url": "https://github.com/lorisleiva", + "type": "github" + } + ], + "time": "2021-01-20T10:55:08+00:00" }, { "name": "monolog/monolog", @@ -1862,16 +1914,16 @@ }, { "name": "nesbot/carbon", - "version": "2.48.0", + "version": "2.48.1", "source": { "type": "git", "url": "https://github.com/briannesbitt/Carbon.git", - "reference": "d3c447f21072766cddec3522f9468a5849a76147" + "reference": "8d1f50f1436fb4b05e7127360483dd9c6e73da16" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/d3c447f21072766cddec3522f9468a5849a76147", - "reference": "d3c447f21072766cddec3522f9468a5849a76147", + "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/8d1f50f1436fb4b05e7127360483dd9c6e73da16", + "reference": "8d1f50f1436fb4b05e7127360483dd9c6e73da16", "shasum": "" }, "require": { @@ -1951,7 +2003,7 @@ "type": "tidelift" } ], - "time": "2021-05-07T10:08:30+00:00" + "time": "2021-05-26T22:08:38+00:00" }, { "name": "opis/closure", @@ -2251,6 +2303,58 @@ }, "time": "2019-01-08T18:20:26+00:00" }, + { + "name": "psr/http-client", + "version": "1.0.1", + "source": { + "type": "git", + "url": "https://github.com/php-fig/http-client.git", + "reference": "2dfb5f6c5eff0e91e20e913f8c5452ed95b86621" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/http-client/zipball/2dfb5f6c5eff0e91e20e913f8c5452ed95b86621", + "reference": "2dfb5f6c5eff0e91e20e913f8c5452ed95b86621", + "shasum": "" + }, + "require": { + "php": "^7.0 || ^8.0", + "psr/http-message": "^1.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Psr\\Http\\Client\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" + } + ], + "description": "Common interface for HTTP clients", + "homepage": "https://github.com/php-fig/http-client", + "keywords": [ + "http", + "http-client", + "psr", + "psr-18" + ], + "support": { + "source": "https://github.com/php-fig/http-client/tree/master" + }, + "time": "2020-06-29T06:28:15+00:00" + }, { "name": "psr/http-message", "version": "1.0.1", @@ -2747,32 +2851,33 @@ }, { "name": "spatie/laravel-schedule-monitor", - "version": "2.0.1", + "version": "2.3.0", "source": { "type": "git", "url": "https://github.com/spatie/laravel-schedule-monitor.git", - "reference": "4ffdaea81b5c27a119b6cbac8f4894657b8fd6d9" + "reference": "cc65f9822d0e0b69043372d6c7d3e8dbd072f85d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/spatie/laravel-schedule-monitor/zipball/4ffdaea81b5c27a119b6cbac8f4894657b8fd6d9", - "reference": "4ffdaea81b5c27a119b6cbac8f4894657b8fd6d9", + "url": "https://api.github.com/repos/spatie/laravel-schedule-monitor/zipball/cc65f9822d0e0b69043372d6c7d3e8dbd072f85d", + "reference": "cc65f9822d0e0b69043372d6c7d3e8dbd072f85d", "shasum": "" }, "require": { - "illuminate/bus": "^7.19|^8.0", - "lorisleiva/cron-translator": "^0.1.1", - "php": "^7.4" + "illuminate/bus": "^8.0", + "lorisleiva/cron-translator": "^0.2.0", + "nesbot/carbon": "^2.41.3", + "php": "^7.4|^8.0" }, "require-dev": { - "friendsofphp/php-cs-fixer": "^2.16", "laravel/legacy-factories": "^1.0.4", + "mockery/mockery": "^1.4", "ohdearapp/ohdear-php-sdk": "^3.0", - "orchestra/testbench": "^5.0|^6.0", - "phpunit/phpunit": "^9.0", + "orchestra/testbench": "^6.8", + "phpunit/phpunit": "^9.3", "spatie/phpunit-snapshot-assertions": "^4.2", "spatie/test-time": "^1.2", - "vimeo/psalm": "^3.11" + "vimeo/psalm": "^4.0" }, "suggest": { "ohdearapp/ohdear-php-sdk": "Needed to sync your schedule with Oh Dear" @@ -2810,7 +2915,7 @@ ], "support": { "issues": "https://github.com/spatie/laravel-schedule-monitor/issues", - "source": "https://github.com/spatie/laravel-schedule-monitor/tree/2.0.1" + "source": "https://github.com/spatie/laravel-schedule-monitor/tree/2.3.0" }, "funding": [ { @@ -2818,7 +2923,7 @@ "type": "github" } ], - "time": "2020-10-06T10:38:45+00:00" + "time": "2021-05-13T11:57:52+00:00" }, { "name": "spomky-labs/base64url", @@ -3059,16 +3164,16 @@ }, { "name": "symfony/css-selector", - "version": "v5.2.7", + "version": "v5.2.9", "source": { "type": "git", "url": "https://github.com/symfony/css-selector.git", - "reference": "59a684f5ac454f066ecbe6daecce6719aed283fb" + "reference": "5d5f97809015102116208b976eb2edb44b689560" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/css-selector/zipball/59a684f5ac454f066ecbe6daecce6719aed283fb", - "reference": "59a684f5ac454f066ecbe6daecce6719aed283fb", + "url": "https://api.github.com/repos/symfony/css-selector/zipball/5d5f97809015102116208b976eb2edb44b689560", + "reference": "5d5f97809015102116208b976eb2edb44b689560", "shasum": "" }, "require": { @@ -3104,7 +3209,7 @@ "description": "Converts CSS selectors to XPath expressions", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/css-selector/tree/v5.3.0-BETA1" + "source": "https://github.com/symfony/css-selector/tree/v5.2.9" }, "funding": [ { @@ -3120,7 +3225,7 @@ "type": "tidelift" } ], - "time": "2021-04-07T16:07:52+00:00" + "time": "2021-05-16T13:07:46+00:00" }, { "name": "symfony/deprecation-contracts", @@ -3424,16 +3529,16 @@ }, { "name": "symfony/finder", - "version": "v5.2.8", + "version": "v5.2.9", "source": { "type": "git", "url": "https://github.com/symfony/finder.git", - "reference": "eccb8be70d7a6a2230d05f6ecede40f3fdd9e252" + "reference": "ccccb9d48ca42757dd12f2ca4bf857a4e217d90d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/finder/zipball/eccb8be70d7a6a2230d05f6ecede40f3fdd9e252", - "reference": "eccb8be70d7a6a2230d05f6ecede40f3fdd9e252", + "url": "https://api.github.com/repos/symfony/finder/zipball/ccccb9d48ca42757dd12f2ca4bf857a4e217d90d", + "reference": "ccccb9d48ca42757dd12f2ca4bf857a4e217d90d", "shasum": "" }, "require": { @@ -3465,7 +3570,7 @@ "description": "Finds files and directories via an intuitive fluent interface", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/finder/tree/v5.2.8" + "source": "https://github.com/symfony/finder/tree/v5.2.9" }, "funding": [ { @@ -3481,7 +3586,7 @@ "type": "tidelift" } ], - "time": "2021-05-10T14:39:23+00:00" + "time": "2021-05-16T13:07:46+00:00" }, { "name": "symfony/http-client-contracts", @@ -3636,16 +3741,16 @@ }, { "name": "symfony/http-kernel", - "version": "v5.2.8", + "version": "v5.2.9", "source": { "type": "git", "url": "https://github.com/symfony/http-kernel.git", - "reference": "c3cb71ee7e2d3eae5fe1001f81780d6a49b37937" + "reference": "eb540ef6870dbf33c92e372cfb869ebf9649e6cb" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-kernel/zipball/c3cb71ee7e2d3eae5fe1001f81780d6a49b37937", - "reference": "c3cb71ee7e2d3eae5fe1001f81780d6a49b37937", + "url": "https://api.github.com/repos/symfony/http-kernel/zipball/eb540ef6870dbf33c92e372cfb869ebf9649e6cb", + "reference": "eb540ef6870dbf33c92e372cfb869ebf9649e6cb", "shasum": "" }, "require": { @@ -3728,7 +3833,7 @@ "description": "Provides a structured process for converting a Request into a Response", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/http-kernel/tree/v5.2.8" + "source": "https://github.com/symfony/http-kernel/tree/v5.2.9" }, "funding": [ { @@ -3744,20 +3849,20 @@ "type": "tidelift" } ], - "time": "2021-05-12T13:27:53+00:00" + "time": "2021-05-19T12:23:45+00:00" }, { "name": "symfony/mime", - "version": "v5.2.7", + "version": "v5.2.9", "source": { "type": "git", "url": "https://github.com/symfony/mime.git", - "reference": "7af452bf51c46f18da00feb32e1ad36db9426515" + "reference": "64258e870f8cc75c3dae986201ea2df58c210b52" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/mime/zipball/7af452bf51c46f18da00feb32e1ad36db9426515", - "reference": "7af452bf51c46f18da00feb32e1ad36db9426515", + "url": "https://api.github.com/repos/symfony/mime/zipball/64258e870f8cc75c3dae986201ea2df58c210b52", + "reference": "64258e870f8cc75c3dae986201ea2df58c210b52", "shasum": "" }, "require": { @@ -3811,7 +3916,7 @@ "mime-type" ], "support": { - "source": "https://github.com/symfony/mime/tree/v5.2.7" + "source": "https://github.com/symfony/mime/tree/v5.2.9" }, "funding": [ { @@ -3827,20 +3932,20 @@ "type": "tidelift" } ], - "time": "2021-04-29T20:47:09+00:00" + "time": "2021-05-16T13:07:46+00:00" }, { "name": "symfony/polyfill-ctype", - "version": "v1.22.1", + "version": "v1.23.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-ctype.git", - "reference": "c6c942b1ac76c82448322025e084cadc56048b4e" + "reference": "46cd95797e9df938fdd2b03693b5fca5e64b01ce" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/c6c942b1ac76c82448322025e084cadc56048b4e", - "reference": "c6c942b1ac76c82448322025e084cadc56048b4e", + "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/46cd95797e9df938fdd2b03693b5fca5e64b01ce", + "reference": "46cd95797e9df938fdd2b03693b5fca5e64b01ce", "shasum": "" }, "require": { @@ -3852,7 +3957,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", @@ -3890,7 +3995,7 @@ "portable" ], "support": { - "source": "https://github.com/symfony/polyfill-ctype/tree/v1.22.1" + "source": "https://github.com/symfony/polyfill-ctype/tree/v1.23.0" }, "funding": [ { @@ -3906,20 +4011,20 @@ "type": "tidelift" } ], - "time": "2021-01-07T16:49:33+00:00" + "time": "2021-02-19T12:13:01+00:00" }, { "name": "symfony/polyfill-iconv", - "version": "v1.22.1", + "version": "v1.23.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-iconv.git", - "reference": "06fb361659649bcfd6a208a0f1fcaf4e827ad342" + "reference": "63b5bb7db83e5673936d6e3b8b3e022ff6474933" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-iconv/zipball/06fb361659649bcfd6a208a0f1fcaf4e827ad342", - "reference": "06fb361659649bcfd6a208a0f1fcaf4e827ad342", + "url": "https://api.github.com/repos/symfony/polyfill-iconv/zipball/63b5bb7db83e5673936d6e3b8b3e022ff6474933", + "reference": "63b5bb7db83e5673936d6e3b8b3e022ff6474933", "shasum": "" }, "require": { @@ -3931,7 +4036,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", @@ -3970,7 +4075,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-iconv/tree/v1.22.1" + "source": "https://github.com/symfony/polyfill-iconv/tree/v1.23.0" }, "funding": [ { @@ -3986,20 +4091,20 @@ "type": "tidelift" } ], - "time": "2021-01-22T09:19:47+00:00" + "time": "2021-05-27T09:27:20+00:00" }, { "name": "symfony/polyfill-intl-grapheme", - "version": "v1.22.1", + "version": "v1.23.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-grapheme.git", - "reference": "5601e09b69f26c1828b13b6bb87cb07cddba3170" + "reference": "24b72c6baa32c746a4d0840147c9715e42bb68ab" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-intl-grapheme/zipball/5601e09b69f26c1828b13b6bb87cb07cddba3170", - "reference": "5601e09b69f26c1828b13b6bb87cb07cddba3170", + "url": "https://api.github.com/repos/symfony/polyfill-intl-grapheme/zipball/24b72c6baa32c746a4d0840147c9715e42bb68ab", + "reference": "24b72c6baa32c746a4d0840147c9715e42bb68ab", "shasum": "" }, "require": { @@ -4011,7 +4116,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", @@ -4051,7 +4156,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-intl-grapheme/tree/v1.22.1" + "source": "https://github.com/symfony/polyfill-intl-grapheme/tree/v1.23.0" }, "funding": [ { @@ -4067,20 +4172,20 @@ "type": "tidelift" } ], - "time": "2021-01-22T09:19:47+00:00" + "time": "2021-05-27T09:17:38+00:00" }, { "name": "symfony/polyfill-intl-idn", - "version": "v1.22.1", + "version": "v1.23.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-idn.git", - "reference": "2d63434d922daf7da8dd863e7907e67ee3031483" + "reference": "65bd267525e82759e7d8c4e8ceea44f398838e65" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-intl-idn/zipball/2d63434d922daf7da8dd863e7907e67ee3031483", - "reference": "2d63434d922daf7da8dd863e7907e67ee3031483", + "url": "https://api.github.com/repos/symfony/polyfill-intl-idn/zipball/65bd267525e82759e7d8c4e8ceea44f398838e65", + "reference": "65bd267525e82759e7d8c4e8ceea44f398838e65", "shasum": "" }, "require": { @@ -4094,7 +4199,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", @@ -4138,7 +4243,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-intl-idn/tree/v1.22.1" + "source": "https://github.com/symfony/polyfill-intl-idn/tree/v1.23.0" }, "funding": [ { @@ -4154,20 +4259,20 @@ "type": "tidelift" } ], - "time": "2021-01-22T09:19:47+00:00" + "time": "2021-05-27T09:27:20+00:00" }, { "name": "symfony/polyfill-intl-normalizer", - "version": "v1.22.1", + "version": "v1.23.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-normalizer.git", - "reference": "43a0283138253ed1d48d352ab6d0bdb3f809f248" + "reference": "8590a5f561694770bdcd3f9b5c69dde6945028e8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-intl-normalizer/zipball/43a0283138253ed1d48d352ab6d0bdb3f809f248", - "reference": "43a0283138253ed1d48d352ab6d0bdb3f809f248", + "url": "https://api.github.com/repos/symfony/polyfill-intl-normalizer/zipball/8590a5f561694770bdcd3f9b5c69dde6945028e8", + "reference": "8590a5f561694770bdcd3f9b5c69dde6945028e8", "shasum": "" }, "require": { @@ -4179,7 +4284,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", @@ -4222,7 +4327,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.22.1" + "source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.23.0" }, "funding": [ { @@ -4238,20 +4343,20 @@ "type": "tidelift" } ], - "time": "2021-01-22T09:19:47+00:00" + "time": "2021-02-19T12:13:01+00:00" }, { "name": "symfony/polyfill-mbstring", - "version": "v1.22.1", + "version": "v1.23.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "5232de97ee3b75b0360528dae24e73db49566ab1" + "reference": "2df51500adbaebdc4c38dea4c89a2e131c45c8a1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/5232de97ee3b75b0360528dae24e73db49566ab1", - "reference": "5232de97ee3b75b0360528dae24e73db49566ab1", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/2df51500adbaebdc4c38dea4c89a2e131c45c8a1", + "reference": "2df51500adbaebdc4c38dea4c89a2e131c45c8a1", "shasum": "" }, "require": { @@ -4263,7 +4368,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", @@ -4302,7 +4407,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.22.1" + "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.23.0" }, "funding": [ { @@ -4318,20 +4423,20 @@ "type": "tidelift" } ], - "time": "2021-01-22T09:19:47+00:00" + "time": "2021-05-27T09:27:20+00:00" }, { "name": "symfony/polyfill-php72", - "version": "v1.22.1", + "version": "v1.23.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php72.git", - "reference": "cc6e6f9b39fe8075b3dabfbaf5b5f645ae1340c9" + "reference": "9a142215a36a3888e30d0a9eeea9766764e96976" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php72/zipball/cc6e6f9b39fe8075b3dabfbaf5b5f645ae1340c9", - "reference": "cc6e6f9b39fe8075b3dabfbaf5b5f645ae1340c9", + "url": "https://api.github.com/repos/symfony/polyfill-php72/zipball/9a142215a36a3888e30d0a9eeea9766764e96976", + "reference": "9a142215a36a3888e30d0a9eeea9766764e96976", "shasum": "" }, "require": { @@ -4340,7 +4445,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", @@ -4378,7 +4483,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php72/tree/v1.22.1" + "source": "https://github.com/symfony/polyfill-php72/tree/v1.23.0" }, "funding": [ { @@ -4394,20 +4499,20 @@ "type": "tidelift" } ], - "time": "2021-01-07T16:49:33+00:00" + "time": "2021-05-27T09:17:38+00:00" }, { "name": "symfony/polyfill-php73", - "version": "v1.22.1", + "version": "v1.23.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php73.git", - "reference": "a678b42e92f86eca04b7fa4c0f6f19d097fb69e2" + "reference": "fba8933c384d6476ab14fb7b8526e5287ca7e010" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php73/zipball/a678b42e92f86eca04b7fa4c0f6f19d097fb69e2", - "reference": "a678b42e92f86eca04b7fa4c0f6f19d097fb69e2", + "url": "https://api.github.com/repos/symfony/polyfill-php73/zipball/fba8933c384d6476ab14fb7b8526e5287ca7e010", + "reference": "fba8933c384d6476ab14fb7b8526e5287ca7e010", "shasum": "" }, "require": { @@ -4416,7 +4521,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", @@ -4457,7 +4562,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php73/tree/v1.22.1" + "source": "https://github.com/symfony/polyfill-php73/tree/v1.23.0" }, "funding": [ { @@ -4473,20 +4578,20 @@ "type": "tidelift" } ], - "time": "2021-01-07T16:49:33+00:00" + "time": "2021-02-19T12:13:01+00:00" }, { "name": "symfony/polyfill-php80", - "version": "v1.22.1", + "version": "v1.23.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php80.git", - "reference": "dc3063ba22c2a1fd2f45ed856374d79114998f91" + "reference": "eca0bf41ed421bed1b57c4958bab16aa86b757d0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/dc3063ba22c2a1fd2f45ed856374d79114998f91", - "reference": "dc3063ba22c2a1fd2f45ed856374d79114998f91", + "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/eca0bf41ed421bed1b57c4958bab16aa86b757d0", + "reference": "eca0bf41ed421bed1b57c4958bab16aa86b757d0", "shasum": "" }, "require": { @@ -4495,7 +4600,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", @@ -4540,7 +4645,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php80/tree/v1.22.1" + "source": "https://github.com/symfony/polyfill-php80/tree/v1.23.0" }, "funding": [ { @@ -4556,7 +4661,7 @@ "type": "tidelift" } ], - "time": "2021-01-07T16:49:33+00:00" + "time": "2021-02-19T12:13:01+00:00" }, { "name": "symfony/process", @@ -4622,16 +4727,16 @@ }, { "name": "symfony/routing", - "version": "v5.2.7", + "version": "v5.2.9", "source": { "type": "git", "url": "https://github.com/symfony/routing.git", - "reference": "3f0cab2e95b5e92226f34c2c1aa969d3fc41f48c" + "reference": "4a7b2bf5e1221be1902b6853743a9bb317f6925e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/routing/zipball/3f0cab2e95b5e92226f34c2c1aa969d3fc41f48c", - "reference": "3f0cab2e95b5e92226f34c2c1aa969d3fc41f48c", + "url": "https://api.github.com/repos/symfony/routing/zipball/4a7b2bf5e1221be1902b6853743a9bb317f6925e", + "reference": "4a7b2bf5e1221be1902b6853743a9bb317f6925e", "shasum": "" }, "require": { @@ -4691,7 +4796,7 @@ "url" ], "support": { - "source": "https://github.com/symfony/routing/tree/v5.2.7" + "source": "https://github.com/symfony/routing/tree/v5.2.9" }, "funding": [ { @@ -4707,7 +4812,7 @@ "type": "tidelift" } ], - "time": "2021-04-11T22:55:21+00:00" + "time": "2021-05-16T13:07:46+00:00" }, { "name": "symfony/service-contracts", @@ -4873,16 +4978,16 @@ }, { "name": "symfony/translation", - "version": "v5.2.8", + "version": "v5.2.9", "source": { "type": "git", "url": "https://github.com/symfony/translation.git", - "reference": "445caa74a5986f1cc9dd91a2975ef68fa7cb2068" + "reference": "61af68dba333e2d376a325a29c2a3f2a605b4876" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/translation/zipball/445caa74a5986f1cc9dd91a2975ef68fa7cb2068", - "reference": "445caa74a5986f1cc9dd91a2975ef68fa7cb2068", + "url": "https://api.github.com/repos/symfony/translation/zipball/61af68dba333e2d376a325a29c2a3f2a605b4876", + "reference": "61af68dba333e2d376a325a29c2a3f2a605b4876", "shasum": "" }, "require": { @@ -4946,7 +5051,7 @@ "description": "Provides tools to internationalize your application", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/translation/tree/v5.2.8" + "source": "https://github.com/symfony/translation/tree/v5.2.9" }, "funding": [ { @@ -4962,7 +5067,7 @@ "type": "tidelift" } ], - "time": "2021-05-07T13:41:16+00:00" + "time": "2021-05-16T13:07:46+00:00" }, { "name": "symfony/translation-contracts", @@ -5246,37 +5351,39 @@ }, { "name": "vlucas/phpdotenv", - "version": "v4.2.0", + "version": "v5.3.0", "source": { "type": "git", "url": "https://github.com/vlucas/phpdotenv.git", - "reference": "da64796370fc4eb03cc277088f6fede9fde88482" + "reference": "b3eac5c7ac896e52deab4a99068e3f4ab12d9e56" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/vlucas/phpdotenv/zipball/da64796370fc4eb03cc277088f6fede9fde88482", - "reference": "da64796370fc4eb03cc277088f6fede9fde88482", + "url": "https://api.github.com/repos/vlucas/phpdotenv/zipball/b3eac5c7ac896e52deab4a99068e3f4ab12d9e56", + "reference": "b3eac5c7ac896e52deab4a99068e3f4ab12d9e56", "shasum": "" }, "require": { - "php": "^5.5.9 || ^7.0 || ^8.0", - "phpoption/phpoption": "^1.7.3", - "symfony/polyfill-ctype": "^1.17" + "ext-pcre": "*", + "graham-campbell/result-type": "^1.0.1", + "php": "^7.1.3 || ^8.0", + "phpoption/phpoption": "^1.7.4", + "symfony/polyfill-ctype": "^1.17", + "symfony/polyfill-mbstring": "^1.17", + "symfony/polyfill-php80": "^1.17" }, "require-dev": { "bamarni/composer-bin-plugin": "^1.4.1", "ext-filter": "*", - "ext-pcre": "*", - "phpunit/phpunit": "^4.8.36 || ^5.7.27 || ^6.5.14 || ^7.5.20" + "phpunit/phpunit": "^7.5.20 || ^8.5.14 || ^9.5.1" }, "suggest": { - "ext-filter": "Required to use the boolean validator.", - "ext-pcre": "Required to use most of the library." + "ext-filter": "Required to use the boolean validator." }, "type": "library", "extra": { "branch-alias": { - "dev-master": "4.1-dev" + "dev-master": "5.3-dev" } }, "autoload": { @@ -5308,7 +5415,7 @@ ], "support": { "issues": "https://github.com/vlucas/phpdotenv/issues", - "source": "https://github.com/vlucas/phpdotenv/tree/v4.2.0" + "source": "https://github.com/vlucas/phpdotenv/tree/v5.3.0" }, "funding": [ { @@ -5320,7 +5427,7 @@ "type": "tidelift" } ], - "time": "2021-01-20T15:11:48+00:00" + "time": "2021-01-20T15:23:13+00:00" }, { "name": "voku/portable-ascii", @@ -5990,6 +6097,64 @@ } ], "time": "2021-01-21T19:18:03+00:00" + }, + { + "name": "webmozart/assert", + "version": "1.10.0", + "source": { + "type": "git", + "url": "https://github.com/webmozarts/assert.git", + "reference": "6964c76c7804814a842473e0c8fd15bab0f18e25" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/webmozarts/assert/zipball/6964c76c7804814a842473e0c8fd15bab0f18e25", + "reference": "6964c76c7804814a842473e0c8fd15bab0f18e25", + "shasum": "" + }, + "require": { + "php": "^7.2 || ^8.0", + "symfony/polyfill-ctype": "^1.8" + }, + "conflict": { + "phpstan/phpstan": "<0.12.20", + "vimeo/psalm": "<4.6.1 || 4.6.2" + }, + "require-dev": { + "phpunit/phpunit": "^8.5.13" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.10-dev" + } + }, + "autoload": { + "psr-4": { + "Webmozart\\Assert\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Bernhard Schussek", + "email": "bschussek@gmail.com" + } + ], + "description": "Assertions to validate method input/output with nice error messages.", + "keywords": [ + "assert", + "check", + "validate" + ], + "support": { + "issues": "https://github.com/webmozarts/assert/issues", + "source": "https://github.com/webmozarts/assert/tree/1.10.0" + }, + "time": "2021-03-09T10:59:23+00:00" } ], "packages-dev": [ @@ -6488,36 +6653,92 @@ "time": "2020-11-13T09:40:50+00:00" }, { - "name": "nunomaduro/collision", - "version": "v4.3.0", + "name": "nikic/php-parser", + "version": "v4.10.5", "source": { "type": "git", - "url": "https://github.com/nunomaduro/collision.git", - "reference": "7c125dc2463f3e144ddc7e05e63077109508c94e" + "url": "https://github.com/nikic/PHP-Parser.git", + "reference": "4432ba399e47c66624bc73c8c0f811e5c109576f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nunomaduro/collision/zipball/7c125dc2463f3e144ddc7e05e63077109508c94e", - "reference": "7c125dc2463f3e144ddc7e05e63077109508c94e", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/4432ba399e47c66624bc73c8c0f811e5c109576f", + "reference": "4432ba399e47c66624bc73c8c0f811e5c109576f", + "shasum": "" + }, + "require": { + "ext-tokenizer": "*", + "php": ">=7.0" + }, + "require-dev": { + "ircmaxell/php-yacc": "^0.0.7", + "phpunit/phpunit": "^6.5 || ^7.0 || ^8.0 || ^9.0" + }, + "bin": [ + "bin/php-parse" + ], + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.9-dev" + } + }, + "autoload": { + "psr-4": { + "PhpParser\\": "lib/PhpParser" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Nikita Popov" + } + ], + "description": "A PHP parser written in PHP", + "keywords": [ + "parser", + "php" + ], + "support": { + "issues": "https://github.com/nikic/PHP-Parser/issues", + "source": "https://github.com/nikic/PHP-Parser/tree/v4.10.5" + }, + "time": "2021-05-03T19:11:20+00:00" + }, + { + "name": "nunomaduro/collision", + "version": "v5.4.0", + "source": { + "type": "git", + "url": "https://github.com/nunomaduro/collision.git", + "reference": "41b7e9999133d5082700d31a1d0977161df8322a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/nunomaduro/collision/zipball/41b7e9999133d5082700d31a1d0977161df8322a", + "reference": "41b7e9999133d5082700d31a1d0977161df8322a", "shasum": "" }, "require": { "facade/ignition-contracts": "^1.0", - "filp/whoops": "^2.4", - "php": "^7.2.5 || ^8.0", + "filp/whoops": "^2.7.2", + "php": "^7.3 || ^8.0", "symfony/console": "^5.0" }, "require-dev": { - "facade/ignition": "^2.0", - "fideloper/proxy": "^4.2", - "friendsofphp/php-cs-fixer": "^2.16", - "fruitcake/laravel-cors": "^1.0", - "laravel/framework": "^7.0", - "laravel/tinker": "^2.0", - "nunomaduro/larastan": "^0.6", - "orchestra/testbench": "^5.0", - "phpstan/phpstan": "^0.12.3", - "phpunit/phpunit": "^8.5.1 || ^9.0" + "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": { @@ -6573,7 +6794,7 @@ "type": "patreon" } ], - "time": "2020-10-29T15:12:23+00:00" + "time": "2021-04-09T13:38:32+00:00" }, { "name": "phar-io/manifest", @@ -6913,40 +7134,44 @@ }, { "name": "phpunit/php-code-coverage", - "version": "7.0.14", + "version": "9.2.6", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "bb7c9a210c72e4709cdde67f8b7362f672f2225c" + "reference": "f6293e1b30a2354e8428e004689671b83871edde" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/bb7c9a210c72e4709cdde67f8b7362f672f2225c", - "reference": "bb7c9a210c72e4709cdde67f8b7362f672f2225c", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/f6293e1b30a2354e8428e004689671b83871edde", + "reference": "f6293e1b30a2354e8428e004689671b83871edde", "shasum": "" }, "require": { "ext-dom": "*", + "ext-libxml": "*", "ext-xmlwriter": "*", - "php": ">=7.2", - "phpunit/php-file-iterator": "^2.0.2", - "phpunit/php-text-template": "^1.2.1", - "phpunit/php-token-stream": "^3.1.1 || ^4.0", - "sebastian/code-unit-reverse-lookup": "^1.0.1", - "sebastian/environment": "^4.2.2", - "sebastian/version": "^2.0.1", - "theseer/tokenizer": "^1.1.3" + "nikic/php-parser": "^4.10.2", + "php": ">=7.3", + "phpunit/php-file-iterator": "^3.0.3", + "phpunit/php-text-template": "^2.0.2", + "sebastian/code-unit-reverse-lookup": "^2.0.2", + "sebastian/complexity": "^2.0", + "sebastian/environment": "^5.1.2", + "sebastian/lines-of-code": "^1.0.3", + "sebastian/version": "^3.0.1", + "theseer/tokenizer": "^1.2.0" }, "require-dev": { - "phpunit/phpunit": "^8.2.2" + "phpunit/phpunit": "^9.3" }, "suggest": { - "ext-xdebug": "^2.7.2" + "ext-pcov": "*", + "ext-xdebug": "*" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "7.0-dev" + "dev-master": "9.2-dev" } }, "autoload": { @@ -6974,7 +7199,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/7.0.14" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.6" }, "funding": [ { @@ -6982,32 +7207,32 @@ "type": "github" } ], - "time": "2020-12-02T13:39:03+00:00" + "time": "2021-03-28T07:26:59+00:00" }, { "name": "phpunit/php-file-iterator", - "version": "2.0.3", + "version": "3.0.5", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "4b49fb70f067272b659ef0174ff9ca40fdaa6357" + "reference": "aa4be8575f26070b100fccb67faabb28f21f66f8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/4b49fb70f067272b659ef0174ff9ca40fdaa6357", - "reference": "4b49fb70f067272b659ef0174ff9ca40fdaa6357", + "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/aa4be8575f26070b100fccb67faabb28f21f66f8", + "reference": "aa4be8575f26070b100fccb67faabb28f21f66f8", "shasum": "" }, "require": { - "php": ">=7.1" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^8.5" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "3.0-dev" } }, "autoload": { @@ -7034,7 +7259,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-file-iterator/issues", - "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/2.0.3" + "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/3.0.5" }, "funding": [ { @@ -7042,26 +7267,97 @@ "type": "github" } ], - "time": "2020-11-30T08:25:21+00:00" + "time": "2020-09-28T05:57:25+00:00" }, { - "name": "phpunit/php-text-template", - "version": "1.2.1", + "name": "phpunit/php-invoker", + "version": "3.1.1", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/php-text-template.git", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686" + "url": "https://github.com/sebastianbergmann/php-invoker.git", + "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/31f8b717e51d9a2afca6c9f046f5d69fc27c8686", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686", + "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/5a10147d0aaf65b58940a0b72f71c9ac0423cc67", + "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=7.3" + }, + "require-dev": { + "ext-pcntl": "*", + "phpunit/phpunit": "^9.3" + }, + "suggest": { + "ext-pcntl": "*" }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.1-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Invoke callables with a timeout", + "homepage": "https://github.com/sebastianbergmann/php-invoker/", + "keywords": [ + "process" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-invoker/issues", + "source": "https://github.com/sebastianbergmann/php-invoker/tree/3.1.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T05:58:55+00:00" + }, + { + "name": "phpunit/php-text-template", + "version": "2.0.4", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-text-template.git", + "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", + "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" + } + }, "autoload": { "classmap": [ "src/" @@ -7085,34 +7381,40 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-text-template/issues", - "source": "https://github.com/sebastianbergmann/php-text-template/tree/1.2.1" + "source": "https://github.com/sebastianbergmann/php-text-template/tree/2.0.4" }, - "time": "2015-06-21T13:50:34+00:00" + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T05:33:50+00:00" }, { "name": "phpunit/php-timer", - "version": "2.1.3", + "version": "5.0.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-timer.git", - "reference": "2454ae1765516d20c4ffe103d85a58a9a3bd5662" + "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/2454ae1765516d20c4ffe103d85a58a9a3bd5662", - "reference": "2454ae1765516d20c4ffe103d85a58a9a3bd5662", + "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", + "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", "shasum": "" }, "require": { - "php": ">=7.1" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^8.5" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.1-dev" + "dev-master": "5.0-dev" } }, "autoload": { @@ -7138,7 +7440,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-timer/issues", - "source": "https://github.com/sebastianbergmann/php-timer/tree/2.1.3" + "source": "https://github.com/sebastianbergmann/php-timer/tree/5.0.3" }, "funding": [ { @@ -7146,80 +7448,20 @@ "type": "github" } ], - "time": "2020-11-30T08:20:02+00:00" - }, - { - "name": "phpunit/php-token-stream", - "version": "4.0.4", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-token-stream.git", - "reference": "a853a0e183b9db7eed023d7933a858fa1c8d25a3" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/a853a0e183b9db7eed023d7933a858fa1c8d25a3", - "reference": "a853a0e183b9db7eed023d7933a858fa1c8d25a3", - "shasum": "" - }, - "require": { - "ext-tokenizer": "*", - "php": "^7.3 || ^8.0" - }, - "require-dev": { - "phpunit/phpunit": "^9.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "4.0-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Wrapper around PHP's tokenizer extension.", - "homepage": "https://github.com/sebastianbergmann/php-token-stream/", - "keywords": [ - "tokenizer" - ], - "support": { - "issues": "https://github.com/sebastianbergmann/php-token-stream/issues", - "source": "https://github.com/sebastianbergmann/php-token-stream/tree/master" - }, - "funding": [ - { - "url": "https://github.com/sebastianbergmann", - "type": "github" - } - ], - "abandoned": true, - "time": "2020-08-04T08:28:15+00:00" + "time": "2020-10-26T13:16:10+00:00" }, { "name": "phpunit/phpunit", - "version": "8.5.15", + "version": "9.5.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "038d4196d8e8cb405cd5e82cedfe413ad6eef9ef" + "reference": "c73c6737305e779771147af66c96ca6a7ed8a741" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/038d4196d8e8cb405cd5e82cedfe413ad6eef9ef", - "reference": "038d4196d8e8cb405cd5e82cedfe413ad6eef9ef", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/c73c6737305e779771147af66c96ca6a7ed8a741", + "reference": "c73c6737305e779771147af66c96ca6a7ed8a741", "shasum": "" }, "require": { @@ -7230,32 +7472,35 @@ "ext-mbstring": "*", "ext-xml": "*", "ext-xmlwriter": "*", - "myclabs/deep-copy": "^1.10.0", + "myclabs/deep-copy": "^1.10.1", "phar-io/manifest": "^2.0.1", "phar-io/version": "^3.0.2", - "php": ">=7.2", - "phpspec/prophecy": "^1.10.3", - "phpunit/php-code-coverage": "^7.0.12", - "phpunit/php-file-iterator": "^2.0.2", - "phpunit/php-text-template": "^1.2.1", - "phpunit/php-timer": "^2.1.2", - "sebastian/comparator": "^3.0.2", - "sebastian/diff": "^3.0.2", - "sebastian/environment": "^4.2.3", - "sebastian/exporter": "^3.1.2", - "sebastian/global-state": "^3.0.0", - "sebastian/object-enumerator": "^3.0.3", - "sebastian/resource-operations": "^2.0.1", - "sebastian/type": "^1.1.3", - "sebastian/version": "^2.0.1" + "php": ">=7.3", + "phpspec/prophecy": "^1.12.1", + "phpunit/php-code-coverage": "^9.2.3", + "phpunit/php-file-iterator": "^3.0.5", + "phpunit/php-invoker": "^3.1.1", + "phpunit/php-text-template": "^2.0.3", + "phpunit/php-timer": "^5.0.2", + "sebastian/cli-parser": "^1.0.1", + "sebastian/code-unit": "^1.0.6", + "sebastian/comparator": "^4.0.5", + "sebastian/diff": "^4.0.3", + "sebastian/environment": "^5.1.3", + "sebastian/exporter": "^4.0.3", + "sebastian/global-state": "^5.0.1", + "sebastian/object-enumerator": "^4.0.3", + "sebastian/resource-operations": "^3.0.3", + "sebastian/type": "^2.3", + "sebastian/version": "^3.0.2" }, "require-dev": { - "ext-pdo": "*" + "ext-pdo": "*", + "phpspec/prophecy-phpunit": "^2.0.1" }, "suggest": { "ext-soap": "*", - "ext-xdebug": "*", - "phpunit/php-invoker": "^2.0.0" + "ext-xdebug": "*" }, "bin": [ "phpunit" @@ -7263,12 +7508,15 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "8.5-dev" + "dev-master": "9.5-dev" } }, "autoload": { "classmap": [ "src/" + ], + "files": [ + "src/Framework/Assert/Functions.php" ] }, "notification-url": "https://packagist.org/downloads/", @@ -7291,7 +7539,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", - "source": "https://github.com/sebastianbergmann/phpunit/tree/8.5.15" + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.4" }, "funding": [ { @@ -7303,32 +7551,144 @@ "type": "github" } ], - "time": "2021-03-17T07:27:54+00:00" + "time": "2021-03-23T07:16:29+00:00" }, { - "name": "sebastian/code-unit-reverse-lookup", - "version": "1.0.2", + "name": "sebastian/cli-parser", + "version": "1.0.1", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", - "reference": "1de8cd5c010cb153fcd68b8d0f64606f523f7619" + "url": "https://github.com/sebastianbergmann/cli-parser.git", + "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/1de8cd5c010cb153fcd68b8d0f64606f523f7619", - "reference": "1de8cd5c010cb153fcd68b8d0f64606f523f7619", + "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/442e7c7e687e42adc03470c7b668bc4b2402c0b2", + "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2", "shasum": "" }, "require": { - "php": ">=5.6" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^8.5" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "1.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library for parsing CLI options", + "homepage": "https://github.com/sebastianbergmann/cli-parser", + "support": { + "issues": "https://github.com/sebastianbergmann/cli-parser/issues", + "source": "https://github.com/sebastianbergmann/cli-parser/tree/1.0.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T06:08:49+00:00" + }, + { + "name": "sebastian/code-unit", + "version": "1.0.8", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/code-unit.git", + "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit/zipball/1fc9f64c0927627ef78ba436c9b17d967e68e120", + "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Collection of value objects that represent the PHP code units", + "homepage": "https://github.com/sebastianbergmann/code-unit", + "support": { + "issues": "https://github.com/sebastianbergmann/code-unit/issues", + "source": "https://github.com/sebastianbergmann/code-unit/tree/1.0.8" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T13:08:54+00:00" + }, + { + "name": "sebastian/code-unit-reverse-lookup", + "version": "2.0.3", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", + "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", + "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" } }, "autoload": { @@ -7350,7 +7710,7 @@ "homepage": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/", "support": { "issues": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/issues", - "source": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/tree/1.0.2" + "source": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/tree/2.0.3" }, "funding": [ { @@ -7358,34 +7718,34 @@ "type": "github" } ], - "time": "2020-11-30T08:15:22+00:00" + "time": "2020-09-28T05:30:19+00:00" }, { "name": "sebastian/comparator", - "version": "3.0.3", + "version": "4.0.6", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "1071dfcef776a57013124ff35e1fc41ccd294758" + "reference": "55f4261989e546dc112258c7a75935a81a7ce382" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/1071dfcef776a57013124ff35e1fc41ccd294758", - "reference": "1071dfcef776a57013124ff35e1fc41ccd294758", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/55f4261989e546dc112258c7a75935a81a7ce382", + "reference": "55f4261989e546dc112258c7a75935a81a7ce382", "shasum": "" }, "require": { - "php": ">=7.1", - "sebastian/diff": "^3.0", - "sebastian/exporter": "^3.1" + "php": ">=7.3", + "sebastian/diff": "^4.0", + "sebastian/exporter": "^4.0" }, "require-dev": { - "phpunit/phpunit": "^8.5" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -7424,7 +7784,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/comparator/issues", - "source": "https://github.com/sebastianbergmann/comparator/tree/3.0.3" + "source": "https://github.com/sebastianbergmann/comparator/tree/4.0.6" }, "funding": [ { @@ -7432,33 +7792,90 @@ "type": "github" } ], - "time": "2020-11-30T08:04:30+00:00" + "time": "2020-10-26T15:49:45+00:00" }, { - "name": "sebastian/diff", - "version": "3.0.3", + "name": "sebastian/complexity", + "version": "2.0.2", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "14f72dd46eaf2f2293cbe79c93cc0bc43161a211" + "url": "https://github.com/sebastianbergmann/complexity.git", + "reference": "739b35e53379900cc9ac327b2147867b8b6efd88" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/14f72dd46eaf2f2293cbe79c93cc0bc43161a211", - "reference": "14f72dd46eaf2f2293cbe79c93cc0bc43161a211", + "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/739b35e53379900cc9ac327b2147867b8b6efd88", + "reference": "739b35e53379900cc9ac327b2147867b8b6efd88", "shasum": "" }, "require": { - "php": ">=7.1" + "nikic/php-parser": "^4.7", + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^7.5 || ^8.0", - "symfony/process": "^2 || ^3.3 || ^4" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "2.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library for calculating the complexity of PHP code units", + "homepage": "https://github.com/sebastianbergmann/complexity", + "support": { + "issues": "https://github.com/sebastianbergmann/complexity/issues", + "source": "https://github.com/sebastianbergmann/complexity/tree/2.0.2" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T15:52:27+00:00" + }, + { + "name": "sebastian/diff", + "version": "4.0.4", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/diff.git", + "reference": "3461e3fccc7cfdfc2720be910d3bd73c69be590d" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/3461e3fccc7cfdfc2720be910d3bd73c69be590d", + "reference": "3461e3fccc7cfdfc2720be910d3bd73c69be590d", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3", + "symfony/process": "^4.2 || ^5" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.0-dev" } }, "autoload": { @@ -7490,7 +7907,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/diff/issues", - "source": "https://github.com/sebastianbergmann/diff/tree/3.0.3" + "source": "https://github.com/sebastianbergmann/diff/tree/4.0.4" }, "funding": [ { @@ -7498,27 +7915,27 @@ "type": "github" } ], - "time": "2020-11-30T07:59:04+00:00" + "time": "2020-10-26T13:10:38+00:00" }, { "name": "sebastian/environment", - "version": "4.2.4", + "version": "5.1.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "d47bbbad83711771f167c72d4e3f25f7fcc1f8b0" + "reference": "388b6ced16caa751030f6a69e588299fa09200ac" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/d47bbbad83711771f167c72d4e3f25f7fcc1f8b0", - "reference": "d47bbbad83711771f167c72d4e3f25f7fcc1f8b0", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/388b6ced16caa751030f6a69e588299fa09200ac", + "reference": "388b6ced16caa751030f6a69e588299fa09200ac", "shasum": "" }, "require": { - "php": ">=7.1" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^7.5" + "phpunit/phpunit": "^9.3" }, "suggest": { "ext-posix": "*" @@ -7526,7 +7943,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "4.2-dev" + "dev-master": "5.1-dev" } }, "autoload": { @@ -7553,7 +7970,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/environment/issues", - "source": "https://github.com/sebastianbergmann/environment/tree/4.2.4" + "source": "https://github.com/sebastianbergmann/environment/tree/5.1.3" }, "funding": [ { @@ -7561,34 +7978,34 @@ "type": "github" } ], - "time": "2020-11-30T07:53:42+00:00" + "time": "2020-09-28T05:52:38+00:00" }, { "name": "sebastian/exporter", - "version": "3.1.3", + "version": "4.0.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "6b853149eab67d4da22291d36f5b0631c0fd856e" + "reference": "d89cc98761b8cb5a1a235a6b703ae50d34080e65" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/6b853149eab67d4da22291d36f5b0631c0fd856e", - "reference": "6b853149eab67d4da22291d36f5b0631c0fd856e", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/d89cc98761b8cb5a1a235a6b703ae50d34080e65", + "reference": "d89cc98761b8cb5a1a235a6b703ae50d34080e65", "shasum": "" }, "require": { - "php": ">=7.0", - "sebastian/recursion-context": "^3.0" + "php": ">=7.3", + "sebastian/recursion-context": "^4.0" }, "require-dev": { "ext-mbstring": "*", - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.1.x-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -7630,7 +8047,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/exporter/issues", - "source": "https://github.com/sebastianbergmann/exporter/tree/3.1.3" + "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.3" }, "funding": [ { @@ -7638,30 +8055,30 @@ "type": "github" } ], - "time": "2020-11-30T07:47:53+00:00" + "time": "2020-09-28T05:24:23+00:00" }, { "name": "sebastian/global-state", - "version": "3.0.1", + "version": "5.0.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "474fb9edb7ab891665d3bfc6317f42a0a150454b" + "reference": "a90ccbddffa067b51f574dea6eb25d5680839455" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/474fb9edb7ab891665d3bfc6317f42a0a150454b", - "reference": "474fb9edb7ab891665d3bfc6317f42a0a150454b", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/a90ccbddffa067b51f574dea6eb25d5680839455", + "reference": "a90ccbddffa067b51f574dea6eb25d5680839455", "shasum": "" }, "require": { - "php": ">=7.2", - "sebastian/object-reflector": "^1.1.1", - "sebastian/recursion-context": "^3.0" + "php": ">=7.3", + "sebastian/object-reflector": "^2.0", + "sebastian/recursion-context": "^4.0" }, "require-dev": { "ext-dom": "*", - "phpunit/phpunit": "^8.0" + "phpunit/phpunit": "^9.3" }, "suggest": { "ext-uopz": "*" @@ -7669,7 +8086,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "5.0-dev" } }, "autoload": { @@ -7694,7 +8111,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/global-state/issues", - "source": "https://github.com/sebastianbergmann/global-state/tree/3.0.1" + "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.2" }, "funding": [ { @@ -7702,34 +8119,91 @@ "type": "github" } ], - "time": "2020-11-30T07:43:24+00:00" + "time": "2020-10-26T15:55:19+00:00" }, { - "name": "sebastian/object-enumerator", - "version": "3.0.4", + "name": "sebastian/lines-of-code", + "version": "1.0.3", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/object-enumerator.git", - "reference": "e67f6d32ebd0c749cf9d1dbd9f226c727043cdf2" + "url": "https://github.com/sebastianbergmann/lines-of-code.git", + "reference": "c1c2e997aa3146983ed888ad08b15470a2e22ecc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/e67f6d32ebd0c749cf9d1dbd9f226c727043cdf2", - "reference": "e67f6d32ebd0c749cf9d1dbd9f226c727043cdf2", + "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/c1c2e997aa3146983ed888ad08b15470a2e22ecc", + "reference": "c1c2e997aa3146983ed888ad08b15470a2e22ecc", "shasum": "" }, "require": { - "php": ">=7.0", - "sebastian/object-reflector": "^1.1.1", - "sebastian/recursion-context": "^3.0" + "nikic/php-parser": "^4.6", + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0.x-dev" + "dev-master": "1.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library for counting the lines of code in PHP source code", + "homepage": "https://github.com/sebastianbergmann/lines-of-code", + "support": { + "issues": "https://github.com/sebastianbergmann/lines-of-code/issues", + "source": "https://github.com/sebastianbergmann/lines-of-code/tree/1.0.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-11-28T06:42:11+00:00" + }, + { + "name": "sebastian/object-enumerator", + "version": "4.0.4", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/object-enumerator.git", + "reference": "5c9eeac41b290a3712d88851518825ad78f45c71" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/5c9eeac41b290a3712d88851518825ad78f45c71", + "reference": "5c9eeac41b290a3712d88851518825ad78f45c71", + "shasum": "" + }, + "require": { + "php": ">=7.3", + "sebastian/object-reflector": "^2.0", + "sebastian/recursion-context": "^4.0" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.0-dev" } }, "autoload": { @@ -7751,7 +8225,7 @@ "homepage": "https://github.com/sebastianbergmann/object-enumerator/", "support": { "issues": "https://github.com/sebastianbergmann/object-enumerator/issues", - "source": "https://github.com/sebastianbergmann/object-enumerator/tree/3.0.4" + "source": "https://github.com/sebastianbergmann/object-enumerator/tree/4.0.4" }, "funding": [ { @@ -7759,32 +8233,32 @@ "type": "github" } ], - "time": "2020-11-30T07:40:27+00:00" + "time": "2020-10-26T13:12:34+00:00" }, { "name": "sebastian/object-reflector", - "version": "1.1.2", + "version": "2.0.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/object-reflector.git", - "reference": "9b8772b9cbd456ab45d4a598d2dd1a1bced6363d" + "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/9b8772b9cbd456ab45d4a598d2dd1a1bced6363d", - "reference": "9b8772b9cbd456ab45d4a598d2dd1a1bced6363d", + "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", + "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", "shasum": "" }, "require": { - "php": ">=7.0" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.1-dev" + "dev-master": "2.0-dev" } }, "autoload": { @@ -7806,7 +8280,7 @@ "homepage": "https://github.com/sebastianbergmann/object-reflector/", "support": { "issues": "https://github.com/sebastianbergmann/object-reflector/issues", - "source": "https://github.com/sebastianbergmann/object-reflector/tree/1.1.2" + "source": "https://github.com/sebastianbergmann/object-reflector/tree/2.0.4" }, "funding": [ { @@ -7814,32 +8288,32 @@ "type": "github" } ], - "time": "2020-11-30T07:37:18+00:00" + "time": "2020-10-26T13:14:26+00:00" }, { "name": "sebastian/recursion-context", - "version": "3.0.1", + "version": "4.0.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/recursion-context.git", - "reference": "367dcba38d6e1977be014dc4b22f47a484dac7fb" + "reference": "cd9d8cf3c5804de4341c283ed787f099f5506172" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/367dcba38d6e1977be014dc4b22f47a484dac7fb", - "reference": "367dcba38d6e1977be014dc4b22f47a484dac7fb", + "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/cd9d8cf3c5804de4341c283ed787f099f5506172", + "reference": "cd9d8cf3c5804de4341c283ed787f099f5506172", "shasum": "" }, "require": { - "php": ">=7.0" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0.x-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -7869,7 +8343,7 @@ "homepage": "http://www.github.com/sebastianbergmann/recursion-context", "support": { "issues": "https://github.com/sebastianbergmann/recursion-context/issues", - "source": "https://github.com/sebastianbergmann/recursion-context/tree/3.0.1" + "source": "https://github.com/sebastianbergmann/recursion-context/tree/4.0.4" }, "funding": [ { @@ -7877,29 +8351,32 @@ "type": "github" } ], - "time": "2020-11-30T07:34:24+00:00" + "time": "2020-10-26T13:17:30+00:00" }, { "name": "sebastian/resource-operations", - "version": "2.0.2", + "version": "3.0.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/resource-operations.git", - "reference": "31d35ca87926450c44eae7e2611d45a7a65ea8b3" + "reference": "0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/31d35ca87926450c44eae7e2611d45a7a65ea8b3", - "reference": "31d35ca87926450c44eae7e2611d45a7a65ea8b3", + "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8", + "reference": "0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8", "shasum": "" }, "require": { - "php": ">=7.1" + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-master": "3.0-dev" } }, "autoload": { @@ -7921,7 +8398,7 @@ "homepage": "https://www.github.com/sebastianbergmann/resource-operations", "support": { "issues": "https://github.com/sebastianbergmann/resource-operations/issues", - "source": "https://github.com/sebastianbergmann/resource-operations/tree/2.0.2" + "source": "https://github.com/sebastianbergmann/resource-operations/tree/3.0.3" }, "funding": [ { @@ -7929,32 +8406,32 @@ "type": "github" } ], - "time": "2020-11-30T07:30:19+00:00" + "time": "2020-09-28T06:45:17+00:00" }, { "name": "sebastian/type", - "version": "1.1.4", + "version": "2.3.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/type.git", - "reference": "0150cfbc4495ed2df3872fb31b26781e4e077eb4" + "reference": "81cd61ab7bbf2de744aba0ea61fae32f721df3d2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/0150cfbc4495ed2df3872fb31b26781e4e077eb4", - "reference": "0150cfbc4495ed2df3872fb31b26781e4e077eb4", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/81cd61ab7bbf2de744aba0ea61fae32f721df3d2", + "reference": "81cd61ab7bbf2de744aba0ea61fae32f721df3d2", "shasum": "" }, "require": { - "php": ">=7.2" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^8.2" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.1-dev" + "dev-master": "2.3-dev" } }, "autoload": { @@ -7977,7 +8454,7 @@ "homepage": "https://github.com/sebastianbergmann/type", "support": { "issues": "https://github.com/sebastianbergmann/type/issues", - "source": "https://github.com/sebastianbergmann/type/tree/1.1.4" + "source": "https://github.com/sebastianbergmann/type/tree/2.3.1" }, "funding": [ { @@ -7985,29 +8462,29 @@ "type": "github" } ], - "time": "2020-11-30T07:25:11+00:00" + "time": "2020-10-26T13:18:59+00:00" }, { "name": "sebastian/version", - "version": "2.0.1", + "version": "3.0.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/version.git", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019" + "reference": "c6c1022351a901512170118436c764e473f6de8c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/99732be0ddb3361e16ad77b68ba41efc8e979019", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019", + "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/c6c1022351a901512170118436c764e473f6de8c", + "reference": "c6c1022351a901512170118436c764e473f6de8c", "shasum": "" }, "require": { - "php": ">=5.6" + "php": ">=7.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "3.0-dev" } }, "autoload": { @@ -8030,9 +8507,15 @@ "homepage": "https://github.com/sebastianbergmann/version", "support": { "issues": "https://github.com/sebastianbergmann/version/issues", - "source": "https://github.com/sebastianbergmann/version/tree/master" + "source": "https://github.com/sebastianbergmann/version/tree/3.0.2" }, - "time": "2016-10-03T07:35:21+00:00" + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T06:39:44+00:00" }, { "name": "theseer/tokenizer", @@ -8083,64 +8566,6 @@ } ], "time": "2020-07-12T23:59:07+00:00" - }, - { - "name": "webmozart/assert", - "version": "1.10.0", - "source": { - "type": "git", - "url": "https://github.com/webmozarts/assert.git", - "reference": "6964c76c7804814a842473e0c8fd15bab0f18e25" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/webmozarts/assert/zipball/6964c76c7804814a842473e0c8fd15bab0f18e25", - "reference": "6964c76c7804814a842473e0c8fd15bab0f18e25", - "shasum": "" - }, - "require": { - "php": "^7.2 || ^8.0", - "symfony/polyfill-ctype": "^1.8" - }, - "conflict": { - "phpstan/phpstan": "<0.12.20", - "vimeo/psalm": "<4.6.1 || 4.6.2" - }, - "require-dev": { - "phpunit/phpunit": "^8.5.13" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.10-dev" - } - }, - "autoload": { - "psr-4": { - "Webmozart\\Assert\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Bernhard Schussek", - "email": "bschussek@gmail.com" - } - ], - "description": "Assertions to validate method input/output with nice error messages.", - "keywords": [ - "assert", - "check", - "validate" - ], - "support": { - "issues": "https://github.com/webmozarts/assert/issues", - "source": "https://github.com/webmozarts/assert/tree/1.10.0" - }, - "time": "2021-03-09T10:59:23+00:00" } ], "aliases": [], @@ -8149,7 +8574,7 @@ "prefer-stable": true, "prefer-lowest": false, "platform": { - "php": "^7.1.3", + "php": "^7.4.0", "ext-redis": "^5.3" }, "platform-dev": [], diff --git a/database/migrations/2021_05_18_145620_create_schedule_monitor_tables.php b/database/migrations/2021_05_18_145620_create_schedule_monitor_tables.php new file mode 100644 index 000000000..4cbe4da13 --- /dev/null +++ b/database/migrations/2021_05_18_145620_create_schedule_monitor_tables.php @@ -0,0 +1,50 @@ +bigIncrements('id'); + + $table->string('name'); + $table->string('type')->nullable(); + $table->string('cron_expression'); + $table->string('timezone')->nullable(); + $table->string('ping_url')->nullable(); + + $table->dateTime('last_started_at')->nullable(); + $table->dateTime('last_finished_at')->nullable(); + $table->dateTime('last_failed_at')->nullable(); + $table->dateTime('last_skipped_at')->nullable(); + + $table->dateTime('registered_on_oh_dear_at')->nullable(); + $table->dateTime('last_pinged_at')->nullable(); + $table->integer('grace_time_in_minutes'); + + $table->timestamps(); + }); + + + Schema::create('monitored_scheduled_task_log_items', function (Blueprint $table) { + $table->bigIncrements('id'); + + $table->unsignedBigInteger('monitored_scheduled_task_id'); + $table + ->foreign('monitored_scheduled_task_id', 'fk_scheduled_task_id') + ->references('id') + ->on('monitored_scheduled_tasks') + ->cascadeOnDelete(); + + $table->string('type'); + + $table->json('meta')->nullable(); + + $table->timestamps(); + }); + } +} diff --git a/database/migrations/2021_05_18_155240_create_schedule_monitor_tables.php b/database/migrations/2021_05_18_155240_create_schedule_monitor_tables.php new file mode 100644 index 000000000..4cbe4da13 --- /dev/null +++ b/database/migrations/2021_05_18_155240_create_schedule_monitor_tables.php @@ -0,0 +1,50 @@ +bigIncrements('id'); + + $table->string('name'); + $table->string('type')->nullable(); + $table->string('cron_expression'); + $table->string('timezone')->nullable(); + $table->string('ping_url')->nullable(); + + $table->dateTime('last_started_at')->nullable(); + $table->dateTime('last_finished_at')->nullable(); + $table->dateTime('last_failed_at')->nullable(); + $table->dateTime('last_skipped_at')->nullable(); + + $table->dateTime('registered_on_oh_dear_at')->nullable(); + $table->dateTime('last_pinged_at')->nullable(); + $table->integer('grace_time_in_minutes'); + + $table->timestamps(); + }); + + + Schema::create('monitored_scheduled_task_log_items', function (Blueprint $table) { + $table->bigIncrements('id'); + + $table->unsignedBigInteger('monitored_scheduled_task_id'); + $table + ->foreign('monitored_scheduled_task_id', 'fk_scheduled_task_id') + ->references('id') + ->on('monitored_scheduled_tasks') + ->cascadeOnDelete(); + + $table->string('type'); + + $table->json('meta')->nullable(); + + $table->timestamps(); + }); + } +} diff --git a/database/migrations/2021_05_18_160844_create_schedule_monitor_tables.php b/database/migrations/2021_05_18_160844_create_schedule_monitor_tables.php new file mode 100644 index 000000000..4cbe4da13 --- /dev/null +++ b/database/migrations/2021_05_18_160844_create_schedule_monitor_tables.php @@ -0,0 +1,50 @@ +bigIncrements('id'); + + $table->string('name'); + $table->string('type')->nullable(); + $table->string('cron_expression'); + $table->string('timezone')->nullable(); + $table->string('ping_url')->nullable(); + + $table->dateTime('last_started_at')->nullable(); + $table->dateTime('last_finished_at')->nullable(); + $table->dateTime('last_failed_at')->nullable(); + $table->dateTime('last_skipped_at')->nullable(); + + $table->dateTime('registered_on_oh_dear_at')->nullable(); + $table->dateTime('last_pinged_at')->nullable(); + $table->integer('grace_time_in_minutes'); + + $table->timestamps(); + }); + + + Schema::create('monitored_scheduled_task_log_items', function (Blueprint $table) { + $table->bigIncrements('id'); + + $table->unsignedBigInteger('monitored_scheduled_task_id'); + $table + ->foreign('monitored_scheduled_task_id', 'fk_scheduled_task_id') + ->references('id') + ->on('monitored_scheduled_tasks') + ->cascadeOnDelete(); + + $table->string('type'); + + $table->json('meta')->nullable(); + + $table->timestamps(); + }); + } +} diff --git a/database/migrations/2021_05_19_001202_create_schedule_monitor_tables.php b/database/migrations/2021_05_19_001202_create_schedule_monitor_tables.php new file mode 100644 index 000000000..4cbe4da13 --- /dev/null +++ b/database/migrations/2021_05_19_001202_create_schedule_monitor_tables.php @@ -0,0 +1,50 @@ +bigIncrements('id'); + + $table->string('name'); + $table->string('type')->nullable(); + $table->string('cron_expression'); + $table->string('timezone')->nullable(); + $table->string('ping_url')->nullable(); + + $table->dateTime('last_started_at')->nullable(); + $table->dateTime('last_finished_at')->nullable(); + $table->dateTime('last_failed_at')->nullable(); + $table->dateTime('last_skipped_at')->nullable(); + + $table->dateTime('registered_on_oh_dear_at')->nullable(); + $table->dateTime('last_pinged_at')->nullable(); + $table->integer('grace_time_in_minutes'); + + $table->timestamps(); + }); + + + Schema::create('monitored_scheduled_task_log_items', function (Blueprint $table) { + $table->bigIncrements('id'); + + $table->unsignedBigInteger('monitored_scheduled_task_id'); + $table + ->foreign('monitored_scheduled_task_id', 'fk_scheduled_task_id') + ->references('id') + ->on('monitored_scheduled_tasks') + ->cascadeOnDelete(); + + $table->string('type'); + + $table->json('meta')->nullable(); + + $table->timestamps(); + }); + } +} diff --git a/public/alliance_moons.txt b/public/alliance_moons.txt new file mode 100644 index 000000000..56cf56184 --- /dev/null +++ b/public/alliance_moons.txt @@ -0,0 +1,1810 @@ +Moon Moon Product Quantity Ore TypeID SolarSystemID PlanetID MoonID +1-NJLK IV - Moon 1 + Bitumens 0.373156934977 45492 30004940 40312881 40312882 + Chromite 0.115136057138 45501 30004940 40312881 40312882 + Cobaltite 0.211707025766 45494 30004940 40312881 40312882 +1-NJLK V - Moon 1 + Bitumens 0.340644866228 45492 30004940 40312883 40312884 + Coesite 0.280998438597 45493 30004940 40312883 40312884 + Sylvite 0.178356692195 45491 30004940 40312883 40312884 +1-NJLK VI - Moon 1 + Bitumens 0.353496819735 45492 30004940 40312885 40312886 + Sylvite 0.267443567514 45491 30004940 40312885 40312886 + Zeolites 0.179059609771 45490 30004940 40312885 40312886 +1-NJLK VI - Moon 2 + Bitumens 0.155514284968 45492 30004940 40312885 40312887 + Sylvite 0.332834869623 45491 30004940 40312885 40312887 + Zeolites 0.311650872231 45490 30004940 40312885 40312887 +1-NJLK VI - Moon 3 + Coesite 0.209472537041 45493 30004940 40312885 40312888 + Sylvite 0.280815303326 45491 30004940 40312885 40312888 + Zeolites 0.309712171555 45490 30004940 40312885 40312888 +1-NJLK VII - Moon 1 + Bitumens 0.207497507334 45492 30004940 40312889 40312891 + Sylvite 0.281042426825 45491 30004940 40312889 40312891 + Zeolites 0.31146004796 45490 30004940 40312889 40312891 +1-NJLK VIII - Moon 1 + Coesite 0.24764290452 45493 30004940 40312892 40312893 + Sylvite 0.197740182281 45491 30004940 40312892 40312893 + Zeolites 0.354616910219 45490 30004940 40312892 40312893 +1-NJLK VIII - Moon 2 + Bitumens 0.336184471846 45492 30004940 40312892 40312894 + Coesite 0.17406372726 45493 30004940 40312892 40312894 + Sylvite 0.289751768112 45491 30004940 40312892 40312894 +1-NJLK VIII - Moon 3 + Coesite 0.312656581402 45493 30004940 40312892 40312895 + Sylvite 0.202986031771 45491 30004940 40312892 40312895 + Zeolites 0.284357398748 45490 30004940 40312892 40312895 +1-NJLK VIII - Moon 4 + Bitumens 0.272471278906 45492 30004940 40312892 40312896 + Coesite 0.323115646839 45493 30004940 40312892 40312896 + Sylvite 0.204413071275 45491 30004940 40312892 40312896 +1-NJLK VIII - Moon 5 + Bitumens 0.308370381594 45492 30004940 40312892 40312897 + Coesite 0.323342144489 45493 30004940 40312892 40312897 + Sylvite 0.168287485838 45491 30004940 40312892 40312897 +1-NJLK VIII - Moon 6 + Cobaltite 0.35601374507 45494 30004940 40312892 40312898 + Coesite 0.423855423927 45493 30004940 40312892 40312898 + Titanite 0.220130816102 45496 30004940 40312892 40312898 +1-NJLK VIII - Moon 7 + Bitumens 0.177507787943 45492 30004940 40312892 40312899 + Coesite 0.333084523678 45493 30004940 40312892 40312899 + Zeolites 0.289407670498 45490 30004940 40312892 40312899 +1-NJLK VIII - Moon 8 + Bitumens 0.287014365196 45492 30004940 40312892 40312900 + Sylvite 0.286856383085 45491 30004940 40312892 40312900 + Zeolites 0.226129248738 45490 30004940 40312892 40312900 +1-NJLK VIII - Moon 9 + Bitumens 0.312971591949 45492 30004940 40312892 40312901 + Coesite 0.18947866559 45493 30004940 40312892 40312901 + Sylvite 0.297549754381 45491 30004940 40312892 40312901 +1-NJLK VIII - Moon 10 + Coesite 0.273313939571 45493 30004940 40312892 40312902 + Sylvite 0.210785746574 45491 30004940 40312892 40312902 + Zeolites 0.315900325775 45490 30004940 40312892 40312902 +1-NJLK VIII - Moon 11 + Bitumens 0.31927138567 45492 30004940 40312892 40312903 + Sylvite 0.262398064137 45491 30004940 40312892 40312903 + Zeolites 0.218330547214 45490 30004940 40312892 40312903 +1-NJLK VIII - Moon 12 + Bitumens 0.335468202829 45492 30004940 40312892 40312904 + Coesite 0.257808417082 45493 30004940 40312892 40312904 + Sylvite 0.206723406911 45491 30004940 40312892 40312904 +1-NJLK VIII - Moon 13 + Bitumens 0.321174681187 45492 30004940 40312892 40312905 + Coesite 0.286406308413 45493 30004940 40312892 40312905 + Zeolites 0.192419022322 45490 30004940 40312892 40312905 +1-NJLK VIII - Moon 14 + Bitumens 0.538958311081 45492 30004940 40312892 40312906 + Sylvite 0.261041671038 45491 30004940 40312892 40312906 +1-NJLK VIII - Moon 15 + Bitumens 0.299552619457 45492 30004940 40312892 40312907 + Coesite 0.304944097996 45493 30004940 40312892 40312907 + Zeolites 0.195503264666 45490 30004940 40312892 40312907 +1-NJLK VIII - Moon 16 + Cinnabar 0.206095308065 45506 30004940 40312892 40312908 + Cobaltite 0.211374998093 45494 30004940 40312892 40312908 + Vanadinite 0.208766669035 45500 30004940 40312892 40312908 + Xenotime 0.373763024807 45510 30004940 40312892 40312908 +1-NJLK VIII - Moon 17 + Bitumens 0.318196177483 45492 30004940 40312892 40312909 + Coesite 0.172990038991 45493 30004940 40312892 40312909 + Sylvite 0.308813810349 45491 30004940 40312892 40312909 +1-NJLK VIII - Moon 18 + Bitumens 0.342485964298 45492 30004940 40312892 40312910 + Sylvite 0.253834933043 45491 30004940 40312892 40312910 + Zeolites 0.203679099679 45490 30004940 40312892 40312910 +1-NJLK VIII - Moon 19 + Bitumens 0.336668550968 45492 30004940 40312892 40312911 + Sylvite 0.463331460953 45491 30004940 40312892 40312911 +1-NJLK VIII - Moon 20 + Sylvite 0.468829005957 45491 30004940 40312892 40312912 + Zeolites 0.331171005964 45490 30004940 40312892 40312912 +1-NJLK VIII - Moon 21 + Sylvite 0.276698052883 45491 30004940 40312892 40312913 + Zeolites 0.523301959038 45490 30004940 40312892 40312913 +1-NJLK IX - Moon 1 + Bitumens 0.288639187813 45492 30004940 40312914 40312915 + Sylvite 0.511360824108 45491 30004940 40312914 40312915 +1-NJLK IX - Moon 2 + Bitumens 0.259114593267 45492 30004940 40312914 40312917 + Coesite 0.540885388851 45493 30004940 40312914 40312917 +1-NJLK IX - Moon 3 + Bitumens 0.45505541563 45492 30004940 40312914 40312918 + Sylvite 0.344944566488 45491 30004940 40312914 40312918 +1-NJLK IX - Moon 4 + Bitumens 0.301768511534 45492 30004940 40312914 40312919 + Sylvite 0.278333634138 45491 30004940 40312914 40312919 + Zeolites 0.219897866249 45490 30004940 40312914 40312919 +1-NJLK IX - Moon 5 + Sylvite 0.449440330267 45491 30004940 40312914 40312920 + Zeolites 0.350559651852 45490 30004940 40312914 40312920 +1-NJLK IX - Moon 6 + Bitumens 0.501978218555 45492 30004940 40312914 40312921 + Sylvite 0.298021763563 45491 30004940 40312914 40312921 +1-NJLK IX - Moon 7 + Bitumens 0.459509551525 45492 30004940 40312914 40312922 + Cobaltite 0.291871994734 45494 30004940 40312914 40312922 + Sylvite 0.248618453741 45491 30004940 40312914 40312922 +1-NJLK IX - Moon 8 + Bitumens 0.494431048632 45492 30004940 40312914 40312923 + Coesite 0.305568963289 45493 30004940 40312914 40312923 +1-NJLK IX - Moon 9 + Chromite 0.310662716627 45501 30004940 40312914 40312924 + Cobaltite 0.0838292613626 45494 30004940 40312914 40312924 + Coesite 0.255572021008 45493 30004940 40312914 40312924 + Zeolites 0.349936008453 45490 30004940 40312914 40312924 +1-NJLK IX - Moon 10 + Sylvite 0.457736939192 45491 30004940 40312914 40312925 + Zeolites 0.342263042927 45490 30004940 40312914 40312925 +1-NJLK IX - Moon 11 + Bitumens 0.360928028822 45492 30004940 40312914 40312926 + Coesite 0.275667816401 45493 30004940 40312914 40312926 + Zeolites 0.163404151797 45490 30004940 40312914 40312926 +1-NJLK IX - Moon 12 + Coesite 0.339015156031 45493 30004940 40312914 40312927 + Zeolites 0.46098485589 45490 30004940 40312914 40312927 +1-NJLK IX - Moon 13 + Bitumens 0.240261301398 45492 30004940 40312914 40312928 + Cobaltite 0.29617536068 45494 30004940 40312914 40312928 + Coesite 0.220139890909 45493 30004940 40312914 40312928 + Zeolites 0.243423432112 45490 30004940 40312914 40312928 +1-NJLK IX - Moon 14 + Bitumens 0.530711352825 45492 30004940 40312914 40312929 + Cobaltite 0.293058812618 45494 30004940 40312914 40312929 + Zeolites 0.176229849458 45490 30004940 40312914 40312929 +1-NJLK IX - Moon 15 + Bitumens 0.330701887608 45492 30004940 40312914 40312930 + Sylvite 0.275337308645 45491 30004940 40312914 40312930 + Zeolites 0.193960800767 45490 30004940 40312914 40312930 +1-NJLK IX - Moon 16 + Bitumens 0.198321461678 45492 30004940 40312914 40312931 + Sylvite 0.303768247366 45491 30004940 40312914 40312931 + Zeolites 0.297910302877 45490 30004940 40312914 40312931 +1-NJLK IX - Moon 17 + Sylvite 0.513546288013 45491 30004940 40312914 40312932 + Zeolites 0.286453723907 45490 30004940 40312914 40312932 +1-NJLK IX - Moon 18 + Bitumens 0.496413141489 45492 30004940 40312914 40312933 + Sylvite 0.303586870432 45491 30004940 40312914 40312933 +1-NJLK X - Moon 1 + Bitumens 0.271350413561 45492 30004940 40312934 40312935 + Sylvite 0.528649568558 45491 30004940 40312934 40312935 +1-NJLK X - Moon 2 + Bitumens 0.482425421476 45492 30004940 40312934 40312936 + Coesite 0.317574590445 45493 30004940 40312934 40312936 +1-NJLK X - Moon 3 + Bitumens 0.19840182364 45492 30004940 40312934 40312938 + Sylvite 0.294444531202 45491 30004940 40312934 40312938 + Zeolites 0.307153642178 45490 30004940 40312934 40312938 +1-NJLK X - Moon 4 + Bitumens 0.423787742853 45492 30004940 40312934 40312940 + Cobaltite 0.172270536423 45494 30004940 40312934 40312940 + Vanadinite 0.103941708803 45500 30004940 40312934 40312940 +1-NJLK X - Moon 5 + Bitumens 0.304451823235 45492 30004940 40312934 40312941 + Coesite 0.289111047983 45493 30004940 40312934 40312941 + Sylvite 0.206437110901 45491 30004940 40312934 40312941 +1-NJLK X - Moon 6 + Coesite 0.314837545156 45493 30004940 40312934 40312942 + Sylvite 0.201664850116 45491 30004940 40312934 40312942 + Zeolites 0.283497601748 45490 30004940 40312934 40312942 +1-NJLK X - Moon 7 + Chromite 0.113092690706 45501 30004940 40312934 40312943 + Cobaltite 0.222729131579 45494 30004940 40312934 40312943 + Coesite 0.364178180695 45493 30004940 40312934 40312943 +1-NJLK X - Moon 8 + Bitumens 0.197297379375 45492 30004940 40312934 40312944 + Cobaltite 0.323786020279 45494 30004940 40312934 40312944 + Sylvite 0.213909730315 45491 30004940 40312934 40312944 + Zeolites 0.265006870031 45490 30004940 40312934 40312944 +1-NJLK X - Moon 9 + Bitumens 0.269895166159 45492 30004940 40312934 40312945 + Cobaltite 0.249456942081 45494 30004940 40312934 40312945 + Coesite 0.211929395795 45493 30004940 40312934 40312945 + Sylvite 0.268718481064 45491 30004940 40312934 40312945 +1-NJLK X - Moon 10 + Bitumens 0.156844988465 45492 30004940 40312934 40312946 + Cobaltite 0.331480532885 45494 30004940 40312934 40312946 + Zeolites 0.511674463749 45490 30004940 40312934 40312946 +1-NJLK X - Moon 11 + Coesite 0.352414488792 45493 30004940 40312934 40312947 + Sylvite 0.160956859589 45491 30004940 40312934 40312947 + Zeolites 0.286628633738 45490 30004940 40312934 40312947 +1-NJLK X - Moon 12 + Cobaltite 0.304776728153 45494 30004940 40312934 40312948 + Coesite 0.227316066623 45493 30004940 40312934 40312948 + Sylvite 0.229808837175 45491 30004940 40312934 40312948 + Zeolites 0.238098368049 45490 30004940 40312934 40312948 +1-NJLK X - Moon 13 + Bitumens 0.306336671114 45492 30004940 40312934 40312949 + Chromite 0.318036645651 45501 30004940 40312934 40312949 + Cobaltite 0.0789173766971 45494 30004940 40312934 40312949 + Otavite 0.296709269285 45498 30004940 40312934 40312949 +1-NJLK X - Moon 14 + Bitumens 0.291146039963 45492 30004940 40312934 40312950 + Coesite 0.18531242013 45493 30004940 40312934 40312950 + Sylvite 0.323541522026 45491 30004940 40312934 40312950 +1-NJLK X - Moon 15 + Bitumens 0.303716480732 45492 30004940 40312934 40312951 + Sylvite 0.321461170912 45491 30004940 40312934 40312951 + Zeolites 0.174822345376 45490 30004940 40312934 40312951 +1-NJLK X - Moon 16 + Coesite 0.214309543371 45493 30004940 40312934 40312953 + Sylvite 0.297597676516 45491 30004940 40312934 40312953 + Zeolites 0.288092762232 45490 30004940 40312934 40312953 +1-NJLK X - Moon 17 + Bitumens 0.488206535578 45492 30004940 40312934 40312954 + Coesite 0.311793476343 45493 30004940 40312934 40312954 +1-NJLK X - Moon 18 + Coesite 0.27209559083 45493 30004940 40312934 40312956 + Sylvite 0.239783674479 45491 30004940 40312934 40312956 + Zeolites 0.28812071681 45490 30004940 40312934 40312956 +1-NJLK X - Moon 19 + Bitumens 0.291893213987 45492 30004940 40312934 40312958 + Coesite 0.211623802781 45493 30004940 40312934 40312958 + Sylvite 0.296482980251 45491 30004940 40312934 40312958 +1-NJLK X - Moon 20 + Coesite 0.483465015888 45493 30004940 40312934 40312960 + Zeolites 0.31653496623 45490 30004940 40312934 40312960 +1-NJLK X - Moon 21 + Bitumens 0.293900370598 45492 30004940 40312934 40312961 + Coesite 0.32032546401 45493 30004940 40312934 40312961 + Zeolites 0.185774192214 45490 30004940 40312934 40312961 +1-NJLK XI - Moon 1 + Bitumens 0.539236485958 45492 30004940 40312962 40312968 + Sylvite 0.260763496161 45491 30004940 40312962 40312968 +1-NJLK XI - Moon 2 + Chromite 0.267760187387 45501 30004940 40312962 40312970 + Loparite 0.444902896881 45512 30004940 40312962 40312970 + Sperrylite 0.287336915731 45499 30004940 40312962 40312970 +1-NJLK XI - Moon 3 + Coesite 0.514502584934 45493 30004940 40312962 40312971 + Zeolites 0.285497397184 45490 30004940 40312962 40312971 +1-NJLK XI - Moon 4 + Bitumens 0.485404908657 45492 30004940 40312962 40312972 + Sylvite 0.314595073462 45491 30004940 40312962 40312972 +1-NJLK XI - Moon 5 + Bitumens 0.327146857977 45492 30004940 40312962 40312974 + Coesite 0.472853153944 45493 30004940 40312962 40312974 +1-NJLK XI - Moon 6 + Bitumens 0.192591965199 45492 30004940 40312962 40312977 + Sylvite 0.275581806898 45491 30004940 40312962 40312977 + Zeolites 0.331826239824 45490 30004940 40312962 40312977 +1-NJLK XI - Moon 7 + Coesite 0.301559954882 45493 30004940 40312962 40312978 + Zeolites 0.498440057039 45490 30004940 40312962 40312978 +1-NJLK XI - Moon 8 + Bitumens 0.244753688574 45492 30004940 40312962 40312979 + Sylvite 0.555246293545 45491 30004940 40312962 40312979 +1-NJLK XI - Moon 9 + Bitumens 0.301867157221 45492 30004940 40312962 40312980 + Coesite 0.211241304874 45493 30004940 40312962 40312980 + Sylvite 0.286891549826 45491 30004940 40312962 40312980 +1-NJLK XI - Moon 10 + Coesite 0.470586031675 45493 30004940 40312962 40312981 + Zeolites 0.329413950443 45490 30004940 40312962 40312981 +1-NJLK XI - Moon 11 + Bitumens 0.318132936954 45492 30004940 40312962 40312982 + Coesite 0.243027508259 45493 30004940 40312962 40312982 + Sylvite 0.238839536905 45491 30004940 40312962 40312982 +1-NJLK XI - Moon 12 + Bitumens 0.307776004076 45492 30004940 40312962 40312983 + Coesite 0.492224007845 45493 30004940 40312962 40312983 +1-NJLK XI - Moon 13 + Bitumens 0.203532397747 45492 30004940 40312962 40312984 + Coesite 0.276101827621 45493 30004940 40312962 40312984 + Zeolites 0.32036575675 45490 30004940 40312962 40312984 +1-NJLK XI - Moon 14 + Bitumens 0.319744497538 45492 30004940 40312962 40312985 + Coesite 0.260303646326 45493 30004940 40312962 40312985 + Sylvite 0.219951853156 45491 30004940 40312962 40312985 +1-NJLK XI - Moon 15 + Bitumens 0.179523989558 45492 30004940 40312962 40312986 + Sylvite 0.281202882528 45491 30004940 40312962 40312986 + Zeolites 0.339273124933 45490 30004940 40312962 40312986 +1-NJLK XI - Moon 16 + Coesite 0.279968112707 45493 30004940 40312962 40312987 + Sylvite 0.205605790019 45491 30004940 40312962 40312987 + Zeolites 0.314426094294 45490 30004940 40312962 40312987 +1-NJLK XI - Moon 17 + Bitumens 0.309696346521 45492 30004940 40312962 40312989 + Coesite 0.490303635597 45493 30004940 40312962 40312989 +1-NJLK XI - Moon 18 + Cobaltite 0.376177638769 45494 30004940 40312962 40312991 + Scheelite 0.252117812634 45497 30004940 40312962 40312991 + Zeolites 0.3717045784 45490 30004940 40312962 40312991 +1-NJLK XI - Moon 19 + Coesite 0.260277956724 45493 30004940 40312962 40312992 + Sylvite 0.20443585515 45491 30004940 40312962 40312992 + Zeolites 0.335286200047 45490 30004940 40312962 40312992 +1-NJLK XI - Moon 20 + Bitumens 0.528651893139 45492 30004940 40312962 40312994 + Sylvite 0.27134808898 45491 30004940 40312962 40312994 +1-NJLK XI - Moon 21 + Coesite 0.281183362007 45493 30004940 40312962 40312995 + Sylvite 0.188196405768 45491 30004940 40312962 40312995 + Zeolites 0.330620259047 45490 30004940 40312962 40312995 +1-NJLK XI - Moon 22 + Coesite 0.256242632866 45493 30004940 40312962 40312996 + Zeolites 0.543757379055 45490 30004940 40312962 40312996 +1-NJLK XI - Moon 23 + Chromite 0.124848745763 45501 30004940 40312962 40312997 + Cobaltite 0.192584693432 45494 30004940 40312962 40312997 + Zeolites 0.382566571236 45490 30004940 40312962 40312997 +1-NJLK XI - Moon 24 + Bitumens 0.245874226093 45492 30004940 40312962 40312998 + Coesite 0.209162771702 45493 30004940 40312962 40312998 + Sylvite 0.344963014126 45491 30004940 40312962 40312998 +1-NJLK XII - Moon 1 + Bitumens 0.307880461216 45492 30004940 40312999 40313002 + Sylvite 0.492119520903 45491 30004940 40312999 40313002 +Y-CWQY III - Moon 1 + Coesite 0.519412100315 45493 30004941 40313007 40313009 + Zeolites 0.280587881804 45490 30004941 40313007 40313009 +Y-CWQY IV - Moon 1 + Bitumens 0.326576411724 45492 30004941 40313010 40313011 + Sylvite 0.240941002965 45491 30004941 40313010 40313011 + Zeolites 0.23248256743 45490 30004941 40313010 40313011 +Y-CWQY IV - Moon 2 + Bitumens 0.242362186313 45492 30004941 40313010 40313012 + Cobaltite 0.330651432276 45494 30004941 40313010 40313012 + Zeolites 0.42698636651 45490 30004941 40313010 40313012 +Y-CWQY V - Moon 1 + Cinnabar 0.238668903708 45506 30004941 40313013 40313014 + Coesite 0.667026758194 45493 30004941 40313013 40313014 + Titanite 0.0943043082952 45496 30004941 40313013 40313014 +Y-CWQY V - Moon 2 + Cobaltite 0.251723051071 45494 30004941 40313013 40313015 + Coesite 0.272978127003 45493 30004941 40313013 40313015 + Sylvite 0.195384964347 45491 30004941 40313013 40313015 + Zeolites 0.27991387248 45490 30004941 40313013 40313015 +Y-CWQY VI - Moon 1 + Cobaltite 0.307254940271 45494 30004941 40313016 40313017 + Coesite 0.499199062586 45493 30004941 40313016 40313017 + Sylvite 0.19354596734 45491 30004941 40313016 40313017 +Y-CWQY VI - Moon 2 + Bitumens 0.170049637556 45492 30004941 40313016 40313018 + Sylvite 0.256698280573 45491 30004941 40313016 40313018 + Zeolites 0.373252093792 45490 30004941 40313016 40313018 +Y-CWQY VI - Moon 3 + Sylvite 0.549866616726 45491 30004941 40313016 40313019 + Zeolites 0.250133395195 45490 30004941 40313016 40313019 +Y-CWQY VI - Moon 4 + Bitumens 0.205557450652 45492 30004941 40313016 40313020 + Sylvite 0.307400614023 45491 30004941 40313016 40313020 + Zeolites 0.287041932344 45490 30004941 40313016 40313020 +Y-CWQY VIII - Moon 1 + Coesite 0.467145115137 45493 30004941 40313024 40313025 + Zeolites 0.332854896784 45490 30004941 40313024 40313025 +Y-CWQY VIII - Moon 2 + Bitumens 0.341041952372 45492 30004941 40313024 40313026 + Coesite 0.269852161407 45493 30004941 40313024 40313026 + Sylvite 0.189105898142 45491 30004941 40313024 40313026 +Y-CWQY IX - Moon 1 + Cobaltite 0.273292243481 45494 30004941 40313027 40313028 + Sylvite 0.508903861046 45491 30004941 40313027 40313028 + Zeolites 0.217803910375 45490 30004941 40313027 40313028 +Y-CWQY IX - Moon 2 + Cobaltite 0.394497841597 45494 30004941 40313027 40313029 + Sylvite 0.237927734852 45491 30004941 40313027 40313029 + Zeolites 0.367574423552 45490 30004941 40313027 40313029 +L5D-ZL I - Moon 1 + Coesite 0.479854106903 45493 30004944 40313183 40313184 + Zeolites 0.320145875216 45490 30004944 40313183 40313184 +L5D-ZL II - Moon 1 + Coesite 0.475568324327 45493 30004944 40313185 40313187 + Zeolites 0.324431657791 45490 30004944 40313185 40313187 +L5D-ZL V - Moon 1 + Bitumens 0.267630428076 45492 30004944 40313190 40313191 + Coesite 0.329001069069 45493 30004944 40313190 40313191 + Sylvite 0.203368514776 45491 30004944 40313190 40313191 +L5D-ZL VI - Moon 1 + Coesite 0.349084347486 45493 30004944 40313192 40313193 + Sylvite 0.200154066086 45491 30004944 40313192 40313193 + Zeolites 0.250761598349 45490 30004944 40313192 40313193 +L5D-ZL VI - Moon 2 + Bitumens 0.184079259634 45492 30004944 40313192 40313194 + Cobaltite 0.382213294506 45494 30004944 40313192 40313194 + Sylvite 0.43370744586 45491 30004944 40313192 40313194 +L5D-ZL VII - Moon 1 + Bitumens 0.43822786212 45492 30004944 40313195 40313196 + Sylvite 0.361772149801 45491 30004944 40313195 40313196 +L5D-ZL VII - Moon 2 + Sylvite 0.344947427511 45491 30004944 40313195 40313197 + Zeolites 0.45505258441 45490 30004944 40313195 40313197 +L5D-ZL VIII - Moon 1 + Coesite 0.176254615188 45493 30004944 40313198 40313200 + Sylvite 0.315019518137 45491 30004944 40313198 40313200 + Zeolites 0.308725893497 45490 30004944 40313198 40313200 +L5D-ZL X - Moon 1 + Bitumens 0.321900099516 45492 30004944 40313202 40313204 + Coesite 0.288824111223 45493 30004944 40313202 40313204 + Sylvite 0.189275786281 45491 30004944 40313202 40313204 +L5D-ZL X - Moon 2 + Bitumens 0.417932242155 45492 30004944 40313202 40313205 + Cobaltite 0.413142412901 45494 30004944 40313202 40313205 + Scheelite 0.168925330043 45497 30004944 40313202 40313205 +EIMJ-M IV - Moon 1 + Cobaltite 0.306840270758 45494 30004946 40313227 40313228 + Coesite 0.289401859045 45493 30004946 40313227 40313228 + Sylvite 0.225376933813 45491 30004946 40313227 40313228 + Zeolites 0.178380951285 45490 30004946 40313227 40313228 +EIMJ-M IV - Moon 2 + Bitumens 0.509943127632 45492 30004946 40313227 40313229 + Sylvite 0.290056884289 45491 30004946 40313227 40313229 +EIMJ-M IV - Moon 3 + Cobaltite 0.163667783141 45494 30004946 40313227 40313230 + Sperrylite 0.0860359668732 45499 30004946 40313227 40313230 + Zeolites 0.450296252966 45490 30004946 40313227 40313230 +EIMJ-M V - Moon 1 + Coesite 0.55715572834 45493 30004946 40313231 40313232 + Zeolites 0.242844283581 45490 30004946 40313231 40313232 +EIMJ-M V - Moon 2 + Coesite 0.196371078491 45493 30004946 40313231 40313233 + Sylvite 0.327709823847 45491 30004946 40313231 40313233 + Zeolites 0.275919079781 45490 30004946 40313231 40313233 +EIMJ-M VI - Moon 1 + Bitumens 0.269130945206 45492 30004946 40313234 40313235 + Coesite 0.34677401185 45493 30004946 40313234 40313235 + Sylvite 0.184095039964 45491 30004946 40313234 40313235 +EIMJ-M VII - Moon 1 + Sylvite 0.284730523825 45491 30004946 40313236 40313238 + Zeolites 0.515269458294 45490 30004946 40313236 40313238 +EIMJ-M VII - Moon 2 + Coesite 0.312918275595 45493 30004946 40313236 40313239 + Zeolites 0.487081736326 45490 30004946 40313236 40313239 +EIMJ-M VII - Moon 3 + Bitumens 0.333451956511 45492 30004946 40313236 40313240 + Coesite 0.46654805541 45493 30004946 40313236 40313240 +EIMJ-M VII - Moon 4 + Bitumens 0.3488098979 45492 30004946 40313236 40313242 + Coesite 0.261835873127 45493 30004946 40313236 40313242 + Zeolites 0.189354240894 45490 30004946 40313236 40313242 +EIMJ-M VII - Moon 5 + Bitumens 0.436491966248 45492 30004946 40313236 40313243 + Cobaltite 0.160897761583 45494 30004946 40313236 40313243 + Vanadinite 0.102610275149 45500 30004946 40313236 40313243 +EIMJ-M VII - Moon 6 + Bitumens 0.173556804657 45492 30004946 40313236 40313244 + Coesite 0.310994505882 45493 30004946 40313236 40313244 + Zeolites 0.315448701382 45490 30004946 40313236 40313244 +EIMJ-M VII - Moon 7 + Bitumens 0.270890682936 45492 30004946 40313236 40313245 + Coesite 0.228972047567 45493 30004946 40313236 40313245 + Sylvite 0.300137281418 45491 30004946 40313236 40313245 +EIMJ-M VII - Moon 8 + Bitumens 0.193770691752 45492 30004946 40313236 40313246 + Coesite 0.288607776165 45493 30004946 40313236 40313246 + Zeolites 0.317621529102 45490 30004946 40313236 40313246 +EIMJ-M VII - Moon 9 + Bitumens 0.287483990192 45492 30004946 40313236 40313247 + Coesite 0.304536789656 45493 30004946 40313236 40313247 + Sylvite 0.207979217172 45491 30004946 40313236 40313247 +EIMJ-M VII - Moon 10 + Bitumens 0.320555955172 45492 30004946 40313236 40313248 + Coesite 0.309422820807 45493 30004946 40313236 40313248 + Zeolites 0.170021206141 45490 30004946 40313236 40313248 +EIMJ-M VII - Moon 11 + Bitumens 0.527453899384 45492 30004946 40313236 40313249 + Coesite 0.272546112537 45493 30004946 40313236 40313249 +EIMJ-M VII - Moon 12 + Bitumens 0.380418360233 45492 30004946 40313236 40313251 + Cobaltite 0.325601667166 45494 30004946 40313236 40313251 + Zeolites 0.293979972601 45490 30004946 40313236 40313251 +EIMJ-M VII - Moon 13 + Cinnabar 0.578454971313 45506 30004946 40313236 40313252 + Sylvite 0.209029227495 45491 30004946 40313236 40313252 + Vanadinite 0.212515816092 45500 30004946 40313236 40313252 +EIMJ-M VIII - Moon 1 + Bitumens 0.278377979994 45492 30004946 40313253 40313254 + Sylvite 0.310847312212 45491 30004946 40313253 40313254 + Zeolites 0.210774704814 45490 30004946 40313253 40313254 +EIMJ-M VIII - Moon 2 + Cobaltite 0.242062792182 45494 30004946 40313253 40313256 + Coesite 0.372955679893 45493 30004946 40313253 40313256 + Otavite 0.0849815383554 45498 30004946 40313253 40313256 +EIMJ-M VIII - Moon 3 + Coesite 0.278117924929 45493 30004946 40313253 40313257 + Zeolites 0.52188205719 45490 30004946 40313253 40313257 +EIMJ-M VIII - Moon 4 + Bitumens 0.253359079361 45492 30004946 40313253 40313258 + Sylvite 0.336935251951 45491 30004946 40313253 40313258 + Zeolites 0.209705665708 45490 30004946 40313253 40313258 +EIMJ-M VIII - Moon 5 + Bitumens 0.50396668911 45492 30004946 40313253 40313259 + Coesite 0.296033293009 45493 30004946 40313253 40313259 +EIMJ-M VIII - Moon 6 + Bitumens 0.272701889277 45492 30004946 40313253 40313260 + Sylvite 0.527298092842 45491 30004946 40313253 40313260 +EIMJ-M VIII - Moon 7 + Bitumens 0.262484014034 45492 30004946 40313253 40313262 + Coesite 0.537515997887 45493 30004946 40313253 40313262 +EIMJ-M VIII - Moon 8 + Bitumens 0.240572720766 45492 30004946 40313253 40313263 + Coesite 0.278667390347 45493 30004946 40313253 40313263 + Zeolites 0.280759900808 45490 30004946 40313253 40313263 +EIMJ-M VIII - Moon 9 + Bitumens 0.317140072584 45492 30004946 40313253 40313264 + Sylvite 0.482859939337 45491 30004946 40313253 40313264 +EIMJ-M VIII - Moon 10 + Bitumens 0.281389474869 45492 30004946 40313253 40313265 + Coesite 0.307269990444 45493 30004946 40313253 40313265 + Zeolites 0.211340516806 45490 30004946 40313253 40313265 +EIMJ-M VIII - Moon 11 + Sylvite 0.34371316433 45491 30004946 40313253 40313266 + Zeolites 0.456286847591 45490 30004946 40313253 40313266 +EIMJ-M VIII - Moon 12 + Coesite 0.489452540874 45493 30004946 40313253 40313267 + Zeolites 0.310547441244 45490 30004946 40313253 40313267 +EIMJ-M VIII - Moon 13 + Coesite 0.556509017944 45493 30004946 40313253 40313268 + Zeolites 0.243491008878 45490 30004946 40313253 40313268 +EIMJ-M VIII - Moon 14 + Bitumens 0.315769165754 45492 30004946 40313253 40313269 + Coesite 0.305633604527 45493 30004946 40313253 40313269 + Sylvite 0.178597226739 45491 30004946 40313253 40313269 +EIMJ-M VIII - Moon 15 + Cobaltite 0.210887879133 45494 30004946 40313253 40313270 + Sylvite 0.412121206522 45491 30004946 40313253 40313270 + Vanadinite 0.0769909247756 45500 30004946 40313253 40313270 +EIMJ-M VIII - Moon 16 + Bitumens 0.316133826971 45492 30004946 40313253 40313271 + Coesite 0.181820601225 45493 30004946 40313253 40313271 + Sylvite 0.302045583725 45491 30004946 40313253 40313271 +EIMJ-M VIII - Moon 17 + Bitumens 0.251807123423 45492 30004946 40313253 40313272 + Coesite 0.320771187544 45493 30004946 40313253 40313272 + Sylvite 0.227421686053 45491 30004946 40313253 40313272 +EIMJ-M VIII - Moon 18 + Bitumens 0.214392706752 45492 30004946 40313253 40313273 + Sylvite 0.301279425621 45491 30004946 40313253 40313273 + Zeolites 0.284327864647 45490 30004946 40313253 40313273 +EIMJ-M VIII - Moon 19 + Bitumens 0.482869714499 45492 30004946 40313253 40313275 + Sylvite 0.31713026762 45491 30004946 40313253 40313275 +EIMJ-M VIII - Moon 20 + Bitumens 0.178977325559 45492 30004946 40313253 40313276 + Coesite 0.26217213273 45493 30004946 40313253 40313276 + Zeolites 0.358850568533 45490 30004946 40313253 40313276 +EIMJ-M VIII - Moon 21 + Bitumens 0.271342396736 45492 30004946 40313253 40313278 + Coesite 0.358377277851 45493 30004946 40313253 40313278 + Zeolites 0.170280337334 45490 30004946 40313253 40313278 +EIMJ-M IX - Moon 1 + Bitumens 0.507670640945 45492 30004946 40313280 40313281 + Sylvite 0.292329341173 45491 30004946 40313280 40313281 +EIMJ-M IX - Moon 2 + Cobaltite 0.373999744654 45494 30004946 40313280 40313282 + Coesite 0.195297539234 45493 30004946 40313280 40313282 + Sylvite 0.215396493673 45491 30004946 40313280 40313282 + Zeolites 0.21530623734 45490 30004946 40313280 40313282 +EIMJ-M IX - Moon 3 + Bitumens 0.325748205185 45492 30004946 40313280 40313283 + Coesite 0.213396847248 45493 30004946 40313280 40313283 + Sylvite 0.260854959488 45491 30004946 40313280 40313283 +EIMJ-M IX - Moon 4 + Bitumens 0.359476566315 45492 30004946 40313280 40313284 + Coesite 0.173908755183 45493 30004946 40313280 40313284 + Sylvite 0.266614675522 45491 30004946 40313280 40313284 +EIMJ-M IX - Moon 5 + Bitumens 0.330997854471 45492 30004946 40313280 40313285 + Sylvite 0.26515609026 45491 30004946 40313280 40313285 + Zeolites 0.203846037388 45490 30004946 40313280 40313285 +VQE-CN III - Moon 1 + Bitumens 0.30584526062 45492 30004943 40313084 40313085 + Coesite 0.317547798157 45493 30004943 40313084 40313085 + Sylvite 0.176606938243 45491 30004943 40313084 40313085 +VQE-CN IV - Moon 1 + Bitumens 0.300087183714 45492 30004943 40313086 40313087 + Coesite 0.499912828207 45493 30004943 40313086 40313087 +VQE-CN V - Moon 1 + Bitumens 0.460723936558 45492 30004943 40313088 40313089 + Cobaltite 0.281190603971 45494 30004943 40313088 40313089 + Sylvite 0.258085459471 45491 30004943 40313088 40313089 +VQE-CN V - Moon 2 + Bitumens 0.551021337509 45492 30004943 40313088 40313090 + Coesite 0.248978659511 45493 30004943 40313088 40313090 +VQE-CN V - Moon 3 + Bitumens 0.273871541023 45492 30004943 40313088 40313091 + Coesite 0.224469825625 45493 30004943 40313088 40313091 + Sylvite 0.301658630371 45491 30004943 40313088 40313091 +VQE-CN V - Moon 4 + Cobaltite 0.0840194001794 45494 30004943 40313088 40313092 + Sylvite 0.314509272575 45491 30004943 40313088 40313092 + Vanadinite 0.277773141861 45500 30004943 40313088 40313092 + Zeolites 0.323698192835 45490 30004943 40313088 40313092 +VQE-CN V - Moon 5 + Chromite 0.312719762325 45501 30004943 40313088 40313093 + Cobaltite 0.0907173529267 45494 30004943 40313088 40313093 + Otavite 0.290553510189 45498 30004943 40313088 40313093 + Sylvite 0.306009352207 45491 30004943 40313088 40313093 +VQE-CN V - Moon 6 + Bitumens 0.555813908577 45492 30004943 40313088 40313094 + Sylvite 0.244186103344 45491 30004943 40313088 40313094 +VQE-CN VI - Moon 1 + Coesite 0.311272144318 45493 30004943 40313095 40313096 + Otavite 0.301386833191 45498 30004943 40313095 40313096 + Zeolites 0.187341019511 45490 30004943 40313095 40313096 +VQE-CN VI - Moon 2 + Bitumens 0.47743216157 45492 30004943 40313095 40313097 + Coesite 0.322567850351 45493 30004943 40313095 40313097 +VQE-CN VI - Moon 3 + Sylvite 0.286644309759 45491 30004943 40313095 40313098 + Zeolites 0.513355672359 45490 30004943 40313095 40313098 +VQE-CN VI - Moon 4 + Bitumens 0.28764089942 45492 30004943 40313095 40313099 + Coesite 0.298097521067 45493 30004943 40313095 40313099 + Sylvite 0.214261591434 45491 30004943 40313095 40313099 +VQE-CN VI - Moon 5 + Bitumens 0.342529863119 45492 30004943 40313095 40313100 + Chromite 0.103530138731 45501 30004943 40313095 40313100 + Cobaltite 0.253940016031 45494 30004943 40313095 40313100 +VQE-CN VI - Moon 6 + Bitumens 0.287563860416 45492 30004943 40313095 40313101 + Sylvite 0.512436151505 45491 30004943 40313095 40313101 +VQE-CN VI - Moon 7 + Bitumens 0.509746849537 45492 30004943 40313095 40313102 + Coesite 0.290253192186 45493 30004943 40313095 40313102 +VQE-CN VI - Moon 8 + Coesite 0.204666867852 45493 30004943 40313095 40313103 + Sylvite 0.295290827751 45491 30004943 40313095 40313103 + Zeolites 0.300042301416 45490 30004943 40313095 40313103 +VQE-CN VI - Moon 9 + Sylvite 0.315510213375 45491 30004943 40313095 40313104 + Zeolites 0.484489798546 45490 30004943 40313095 40313104 +VQE-CN VI - Moon 10 + Bitumens 0.497704476118 45492 30004943 40313095 40313105 + Coesite 0.302295506001 45493 30004943 40313095 40313105 +VQE-CN VI - Moon 11 + Bitumens 0.235828205943 45492 30004943 40313095 40313106 + Coesite 0.295167952776 45493 30004943 40313095 40313106 + Zeolites 0.269003838301 45490 30004943 40313095 40313106 +VQE-CN VI - Moon 12 + Bitumens 0.327305674553 45492 30004943 40313095 40313107 + Coesite 0.472694337368 45493 30004943 40313095 40313107 +VQE-CN VI - Moon 13 + Cobaltite 0.175528496504 45494 30004943 40313095 40313108 + Coesite 0.437464505434 45493 30004943 40313095 40313108 + Vanadinite 0.0870070010424 45500 30004943 40313095 40313108 +VQE-CN VI - Moon 14 + Bitumens 0.257077783346 45492 30004943 40313095 40313109 + Coesite 0.542922198772 45493 30004943 40313095 40313109 +VQE-CN VI - Moon 15 + Sylvite 0.464385867119 45491 30004943 40313095 40313110 + Zeolites 0.335614115 45490 30004943 40313095 40313110 +VQE-CN VI - Moon 16 + Bitumens 0.287200957537 45492 30004943 40313095 40313111 + Coesite 0.331372886896 45493 30004943 40313095 40313111 + Zeolites 0.181426167488 45490 30004943 40313095 40313111 +VQE-CN VI - Moon 17 + Bitumens 0.255167126656 45492 30004943 40313095 40313112 + Coesite 0.323164075613 45493 30004943 40313095 40313112 + Zeolites 0.221668824553 45490 30004943 40313095 40313112 +VQE-CN VI - Moon 18 + Bitumens 0.499083042145 45492 30004943 40313095 40313113 + Sylvite 0.300916969776 45491 30004943 40313095 40313113 +VQE-CN VI - Moon 19 + Coesite 0.534842014313 45493 30004943 40313095 40313114 + Zeolites 0.265157997608 45490 30004943 40313095 40313114 +VQE-CN VI - Moon 20 + Bitumens 0.540020942688 45492 30004943 40313095 40313115 + Coesite 0.259979069233 45493 30004943 40313095 40313115 +VQE-CN VII - Moon 1 + Bitumens 0.271119982004 45492 30004943 40313116 40313118 + Sylvite 0.311071157455 45491 30004943 40313116 40313118 + Zeolites 0.21780885756 45490 30004943 40313116 40313118 +VQE-CN VII - Moon 2 + Bitumens 0.314509093761 45492 30004943 40313116 40313119 + Coesite 0.485490888357 45493 30004943 40313116 40313119 +VQE-CN VII - Moon 3 + Bitumens 0.286313712597 45492 30004943 40313116 40313120 + Coesite 0.344923436642 45493 30004943 40313116 40313120 + Sylvite 0.168762847781 45491 30004943 40313116 40313120 +VQE-CN VII - Moon 4 + Bitumens 0.294199854136 45492 30004943 40313116 40313121 + Coesite 0.224628314376 45493 30004943 40313116 40313121 + Sylvite 0.281171828508 45491 30004943 40313116 40313121 +VQE-CN VII - Moon 5 + Coesite 0.301334887743 45493 30004943 40313116 40313122 + Sylvite 0.21851542592 45491 30004943 40313116 40313122 + Zeolites 0.280149698257 45490 30004943 40313116 40313122 +VQE-CN VII - Moon 6 + Bitumens 0.307311296463 45492 30004943 40313116 40313123 + Coesite 0.233163163066 45493 30004943 40313116 40313123 + Sylvite 0.259525537491 45491 30004943 40313116 40313123 +VQE-CN VII - Moon 7 + Coesite 0.207432866096 45493 30004943 40313116 40313124 + Sylvite 0.269585907459 45491 30004943 40313116 40313124 + Zeolites 0.322981208563 45490 30004943 40313116 40313124 +VQE-CN VII - Moon 8 + Sylvite 0.306528091431 45491 30004943 40313116 40313125 + Zeolites 0.49347192049 45490 30004943 40313116 40313125 +VQE-CN VII - Moon 9 + Sylvite 0.300275713205 45491 30004943 40313116 40313126 + Zeolites 0.499724298716 45490 30004943 40313116 40313126 +VQE-CN VII - Moon 10 + Bitumens 0.2892331779 45492 30004943 40313116 40313127 + Coesite 0.343089282513 45493 30004943 40313116 40313127 + Sylvite 0.167677521706 45491 30004943 40313116 40313127 +VQE-CN VII - Moon 11 + Bitumens 0.251434385777 45492 30004943 40313116 40313128 + Cobaltite 0.324256420135 45494 30004943 40313116 40313128 + Zeolites 0.424309194088 45490 30004943 40313116 40313128 +VQE-CN VII - Moon 12 + Bitumens 0.538992106915 45492 30004943 40313116 40313129 + Coesite 0.261007875204 45493 30004943 40313116 40313129 +VQE-CN VII - Moon 13 + Coesite 0.261747419834 45493 30004943 40313116 40313130 + Zeolites 0.538252592087 45490 30004943 40313116 40313130 +VQE-CN VIII - Moon 1 + Bitumens 0.293272525072 45492 30004943 40313131 40313132 + Coesite 0.506727516651 45493 30004943 40313131 40313132 +VQE-CN VIII - Moon 2 + Bitumens 0.486020535231 45492 30004943 40313131 40313133 + Coesite 0.31397947669 45493 30004943 40313131 40313133 +VQE-CN VIII - Moon 3 + Bitumens 0.327853679657 45492 30004943 40313131 40313135 + Sylvite 0.286692351103 45491 30004943 40313131 40313135 + Zeolites 0.185453981161 45490 30004943 40313131 40313135 +VQE-CN VIII - Moon 4 + Chromite 0.437560200691 45501 30004943 40313131 40313136 + Cinnabar 0.155347034335 45506 30004943 40313131 40313136 + Euxenite 0.108124785125 45495 30004943 40313131 40313136 + Sylvite 0.298967987299 45491 30004943 40313131 40313136 +VQE-CN VIII - Moon 5 + Cobaltite 0.412066608667 45494 30004943 40313131 40313137 + Coesite 0.413621395826 45493 30004943 40313131 40313137 + Scheelite 0.174311980605 45497 30004943 40313131 40313137 +VQE-CN VIII - Moon 6 + Bitumens 0.524543702602 45492 30004943 40313131 40313138 + Sylvite 0.275456339121 45491 30004943 40313131 40313138 +VQE-CN VIII - Moon 7 + Coesite 0.510271430016 45493 30004943 40313131 40313139 + Zeolites 0.289728581905 45490 30004943 40313131 40313139 +VQE-CN VIII - Moon 8 + Sylvite 0.270614475012 45491 30004943 40313131 40313140 + Zeolites 0.529385507107 45490 30004943 40313131 40313140 +VQE-CN VIII - Moon 9 + Bitumens 0.501621186733 45492 30004943 40313131 40313141 + Coesite 0.298378825188 45493 30004943 40313131 40313141 +VQE-CN VIII - Moon 10 + Cobaltite 0.430980145931 45494 30004943 40313131 40313142 + Coesite 0.569019854069 45493 30004943 40313131 40313142 +VQE-CN VIII - Moon 11 + Coesite 0.223632439971 45493 30004943 40313131 40313143 + Sylvite 0.261501789093 45491 30004943 40313131 40313143 + Zeolites 0.314865797758 45490 30004943 40313131 40313143 +VQE-CN VIII - Moon 12 + Bitumens 0.23765476048 45492 30004943 40313131 40313144 + Sylvite 0.291766196489 45491 30004943 40313131 40313144 + Zeolites 0.270579040051 45490 30004943 40313131 40313144 +VQE-CN VIII - Moon 13 + Sylvite 0.288189530373 45491 30004943 40313131 40313145 + Zeolites 0.511810481548 45490 30004943 40313131 40313145 +VQE-CN VIII - Moon 14 + Bitumens 0.256021231413 45492 30004943 40313131 40313146 + Cobaltite 0.0924361273646 45494 30004943 40313131 40313146 + Vanadinite 0.651542663574 45500 30004943 40313131 40313146 +VQE-CN VIII - Moon 15 + Cobaltite 0.395974248648 45494 30004943 40313131 40313148 + Coesite 0.164795577526 45493 30004943 40313131 40313148 + Scheelite 0.214547738433 45497 30004943 40313131 40313148 + Zeolites 0.224682435393 45490 30004943 40313131 40313148 +VQE-CN VIII - Moon 16 + Bitumens 0.332594633102 45492 30004943 40313131 40313149 + Coesite 0.273870766163 45493 30004943 40313131 40313149 + Zeolites 0.193534627557 45490 30004943 40313131 40313149 +VQE-CN VIII - Moon 17 + Bitumens 0.2042504251 45492 30004943 40313131 40313150 + Sylvite 0.290060341358 45491 30004943 40313131 40313150 + Zeolites 0.305689245462 45490 30004943 40313131 40313150 +VQE-CN VIII - Moon 18 + Coesite 0.480359405279 45493 30004943 40313131 40313151 + Zeolites 0.319640576839 45490 30004943 40313131 40313151 +VQE-CN VIII - Moon 19 + Coesite 0.319955796003 45493 30004943 40313131 40313153 + Sylvite 0.208388581872 45491 30004943 40313131 40313153 + Zeolites 0.271655619144 45490 30004943 40313131 40313153 +VQE-CN VIII - Moon 20 + Coesite 0.195589184761 45493 30004943 40313131 40313155 + Sylvite 0.277821272612 45491 30004943 40313131 40313155 + Zeolites 0.326589554548 45490 30004943 40313131 40313155 +VQE-CN IX - Moon 1 + Bitumens 0.253903180361 45492 30004943 40313156 40313158 + Sylvite 0.324165374041 45491 30004943 40313156 40313158 + Zeolites 0.221931442618 45490 30004943 40313156 40313158 +VQE-CN IX - Moon 2 + Coesite 0.55281496048 45493 30004943 40313156 40313159 + Zeolites 0.247185021639 45490 30004943 40313156 40313159 +VQE-CN IX - Moon 3 + Sylvite 0.457492977381 45491 30004943 40313156 40313160 + Zeolites 0.342507004738 45490 30004943 40313156 40313160 +VQE-CN IX - Moon 4 + Bitumens 0.268968552351 45492 30004943 40313156 40313161 + Sylvite 0.531031429768 45491 30004943 40313156 40313161 +VQE-CN IX - Moon 5 + Bitumens 0.297914892435 45492 30004943 40313156 40313162 + Coesite 0.502085089684 45493 30004943 40313156 40313162 +VQE-CN IX - Moon 6 + Coesite 0.236392617226 45493 30004943 40313156 40313163 + Sylvite 0.254581719637 45491 30004943 40313156 40313163 + Zeolites 0.309025675058 45490 30004943 40313156 40313163 +VQE-CN IX - Moon 7 + Coesite 0.531119406223 45493 30004943 40313156 40313164 + Zeolites 0.268880575895 45490 30004943 40313156 40313164 +VQE-CN IX - Moon 8 + Sylvite 0.527620017529 45491 30004943 40313156 40313165 + Zeolites 0.272379994392 45490 30004943 40313156 40313165 +VQE-CN IX - Moon 9 + Bitumens 0.22501654923 45492 30004943 40313156 40313166 + Cobaltite 0.337406873703 45494 30004943 40313156 40313166 + Sylvite 0.244636625051 45491 30004943 40313156 40313166 + Zeolites 0.192939952016 45490 30004943 40313156 40313166 +VQE-CN IX - Moon 10 + Bitumens 0.191749319434 45492 30004943 40313156 40313167 + Cobaltite 0.310140043497 45494 30004943 40313156 40313167 + Sylvite 0.498110622168 45491 30004943 40313156 40313167 +VQE-CN IX - Moon 11 + Bitumens 0.353494912386 45492 30004943 40313156 40313168 + Coesite 0.274683058262 45493 30004943 40313156 40313168 + Zeolites 0.171822026372 45490 30004943 40313156 40313168 +VQE-CN IX - Moon 12 + Coesite 0.520289480686 45493 30004943 40313156 40313169 + Zeolites 0.279710531235 45490 30004943 40313156 40313169 +VQE-CN IX - Moon 13 + Bitumens 0.289719313383 45492 30004943 40313156 40313170 + Sylvite 0.303868323565 45491 30004943 40313156 40313170 + Zeolites 0.206412360072 45490 30004943 40313156 40313170 +VQE-CN IX - Moon 14 + Bitumens 0.455396324396 45492 30004943 40313156 40313171 + Coesite 0.344603687525 45493 30004943 40313156 40313171 +VQE-CN IX - Moon 15 + Chromite 0.327508240938 45501 30004943 40313156 40313172 + Cobaltite 0.109146945179 45494 30004943 40313156 40313172 + Coesite 0.25489076972 45493 30004943 40313156 40313172 + Zeolites 0.308454036713 45490 30004943 40313156 40313172 +VQE-CN IX - Moon 16 + Bitumens 0.18543766439 45492 30004943 40313156 40313173 + Coesite 0.307450354099 45493 30004943 40313156 40313173 + Zeolites 0.307111978531 45490 30004943 40313156 40313173 +VQE-CN IX - Moon 17 + Cobaltite 0.589840948582 45494 30004943 40313156 40313175 + Sylvite 0.209252968431 45491 30004943 40313156 40313175 + Zeolites 0.200906097889 45490 30004943 40313156 40313175 +VQE-CN IX - Moon 18 + Bitumens 0.526346564293 45492 30004943 40313156 40313176 + Coesite 0.273653447628 45493 30004943 40313156 40313176 +VQE-CN IX - Moon 19 + Bitumens 0.17665079236 45492 30004943 40313156 40313177 + Cobaltite 0.37829837203 45494 30004943 40313156 40313177 + Sylvite 0.220871686935 45491 30004943 40313156 40313177 + Titanite 0.224179163575 45496 30004943 40313156 40313177 +VQE-CN IX - Moon 20 + Bitumens 0.497420191765 45492 30004943 40313156 40313179 + Coesite 0.302579790354 45493 30004943 40313156 40313179 +VQE-CN IX - Moon 21 + Bitumens 0.210954964161 45492 30004943 40313156 40313181 + Sylvite 0.306775838137 45491 30004943 40313156 40313181 + Zeolites 0.282269209623 45490 30004943 40313156 40313181 +8KR9-5 III - Moon 1 + Bitumens 0.264161080122 45492 30004942 40313034 40313035 + Coesite 0.220732837915 45493 30004942 40313034 40313035 + Sylvite 0.315106064081 45491 30004942 40313034 40313035 +8KR9-5 IV - Moon 1 + Bitumens 0.287323445082 45492 30004942 40313036 40313037 + Chromite 0.632959127426 45501 30004942 40313036 40313037 + Cobaltite 0.0797174423933 45494 30004942 40313036 40313037 +8KR9-5 IV - Moon 2 + Coesite 0.195785656571 45493 30004942 40313036 40313038 + Sylvite 0.315165668726 45491 30004942 40313036 40313038 + Zeolites 0.289048671722 45490 30004942 40313036 40313038 +8KR9-5 IV - Moon 3 + Cobaltite 0.337994486094 45494 30004942 40313036 40313039 + Sylvite 0.662005484104 45491 30004942 40313036 40313039 +8KR9-5 IV - Moon 4 + Chromite 0.298284500837 45501 30004942 40313036 40313041 + Cobaltite 0.103767365217 45494 30004942 40313036 40313041 + Sperrylite 0.251617074013 45499 30004942 40313036 40313041 + Zeolites 0.346331059933 45490 30004942 40313036 40313041 +8KR9-5 IV - Moon 5 + Bitumens 0.246376797557 45492 30004942 40313036 40313042 + Coesite 0.366808116436 45493 30004942 40313036 40313042 + Sylvite 0.186815068126 45491 30004942 40313036 40313042 +8KR9-5 IV - Moon 6 + Bitumens 0.177813351154 45492 30004942 40313036 40313043 + Coesite 0.369189172983 45493 30004942 40313036 40313043 + Zeolites 0.252997457981 45490 30004942 40313036 40313043 +8KR9-5 IV - Moon 7 + Sylvite 0.490644961596 45491 30004942 40313036 40313044 + Zeolites 0.309355050325 45490 30004942 40313036 40313044 +8KR9-5 IV - Moon 8 + Bitumens 0.522773981094 45492 30004942 40313036 40313045 + Coesite 0.277226001024 45493 30004942 40313036 40313045 +8KR9-5 IV - Moon 9 + Bitumens 0.499468743801 45492 30004942 40313036 40313046 + Sylvite 0.30053126812 45491 30004942 40313036 40313046 +8KR9-5 IV - Moon 10 + Coesite 0.328766584396 45493 30004942 40313036 40313047 + Sylvite 0.191617757082 45491 30004942 40313036 40313047 + Zeolites 0.27961564064 45490 30004942 40313036 40313047 +8KR9-5 IV - Moon 11 + Chromite 0.303729087114 45501 30004942 40313036 40313048 + Cinnabar 0.288353323936 45506 30004942 40313036 40313048 + Sperrylite 0.30791759491 45499 30004942 40313036 40313048 +8KR9-5 IV - Moon 12 + Coesite 0.211737141013 45493 30004942 40313036 40313051 + Sylvite 0.24977594614 45491 30004942 40313036 40313051 + Zeolites 0.338486909866 45490 30004942 40313036 40313051 +8KR9-5 V - Moon 1 + Coesite 0.271100521088 45493 30004942 40313052 40313053 + Sylvite 0.202391445637 45491 30004942 40313052 40313053 + Zeolites 0.326508015394 45490 30004942 40313052 40313053 +8KR9-5 V - Moon 2 + Bitumens 0.304550349712 45492 30004942 40313052 40313054 + Coesite 0.495449662209 45493 30004942 40313052 40313054 +8KR9-5 V - Moon 3 + Bitumens 0.293722242117 45492 30004942 40313052 40313055 + Coesite 0.506277740002 45493 30004942 40313052 40313055 +8KR9-5 V - Moon 4 + Bitumens 0.358221590519 45492 30004942 40313052 40313056 + Coesite 0.441778421402 45493 30004942 40313052 40313056 +8KR9-5 V - Moon 5 + Bitumens 0.175722569227 45492 30004942 40313052 40313057 + Sylvite 0.355686485767 45491 30004942 40313052 40313057 + Zeolites 0.268590956926 45490 30004942 40313052 40313057 +8KR9-5 V - Moon 6 + Bitumens 0.286381214857 45492 30004942 40313052 40313058 + Coesite 0.300224304199 45493 30004942 40313052 40313058 + Sylvite 0.213394477963 45491 30004942 40313052 40313058 +8KR9-5 V - Moon 7 + Coesite 0.272703915834 45493 30004942 40313052 40313059 + Zeolites 0.527296066284 45490 30004942 40313052 40313059 +8KR9-5 V - Moon 8 + Coesite 0.333472549915 45493 30004942 40313052 40313060 + Sylvite 0.187641784549 45491 30004942 40313052 40313060 + Zeolites 0.278885692358 45490 30004942 40313052 40313060 +8KR9-5 V - Moon 9 + Bitumens 0.293629199266 45492 30004942 40313052 40313061 + Sylvite 0.293884038925 45491 30004942 40313052 40313061 + Zeolites 0.212486743927 45490 30004942 40313052 40313061 +8KR9-5 V - Moon 10 + Coesite 0.294266313314 45493 30004942 40313052 40313062 + Sylvite 0.183136388659 45491 30004942 40313052 40313062 + Zeolites 0.322597295046 45490 30004942 40313052 40313062 +8KR9-5 V - Moon 11 + Cobaltite 0.296660035849 45494 30004942 40313052 40313063 + Coesite 0.245786875486 45493 30004942 40313052 40313063 + Zeolites 0.457553088665 45490 30004942 40313052 40313063 +8KR9-5 V - Moon 12 + Sylvite 0.286674439907 45491 30004942 40313052 40313064 + Zeolites 0.513325572014 45490 30004942 40313052 40313064 +8KR9-5 V - Moon 13 + Bitumens 0.223719626665 45492 30004942 40313052 40313065 + Sylvite 0.238358825445 45491 30004942 40313052 40313065 + Zeolites 0.337921559811 45490 30004942 40313052 40313065 +8KR9-5 V - Moon 14 + Bitumens 0.222080469131 45492 30004942 40313052 40313066 + Sylvite 0.285322129726 45491 30004942 40313052 40313066 + Zeolites 0.292597383261 45490 30004942 40313052 40313066 +8KR9-5 V - Moon 15 + Bitumens 0.438294887543 45492 30004942 40313052 40313067 + Cobaltite 0.327079206705 45494 30004942 40313052 40313067 + Zeolites 0.234625920653 45490 30004942 40313052 40313067 +8KR9-5 V - Moon 16 + Coesite 0.288976669312 45493 30004942 40313052 40313068 + Zeolites 0.511023342609 45490 30004942 40313052 40313068 +8KR9-5 V - Moon 17 + Bitumens 0.319982141256 45492 30004942 40313052 40313069 + Sylvite 0.265231788158 45491 30004942 40313052 40313069 + Zeolites 0.214786097407 45490 30004942 40313052 40313069 +8KR9-5 VI - Moon 1 + Coesite 0.357648640871 45493 30004942 40313070 40313072 + Zeolites 0.44235137105 45490 30004942 40313070 40313072 +8KR9-5 VII - Moon 1 + Bitumens 0.488979548216 45492 30004942 40313073 40313075 + Coesite 0.311020433903 45493 30004942 40313073 40313075 +8KR9-5 VII - Moon 2 + Bitumens 0.225705042481 45492 30004942 40313073 40313076 + Cobaltite 0.398057490587 45494 30004942 40313073 40313076 + Sylvite 0.199258804321 45491 30004942 40313073 40313076 + Zeolites 0.17697866261 45490 30004942 40313073 40313076 +G-C8QO I - Moon 1 + Bitumens 0.370161950588 45492 30004945 40313207 40313208 + Coesite 0.429838061333 45493 30004945 40313207 40313208 +G-C8QO III - Moon 1 + Bitumens 0.269327014685 45492 30004945 40313211 40313213 + Coesite 0.530672967434 45493 30004945 40313211 40313213 +G-C8QO IV - Moon 1 + Bitumens 0.323317080736 45492 30004945 40313214 40313215 + Coesite 0.275833696127 45493 30004945 40313214 40313215 + Sylvite 0.200849205256 45491 30004945 40313214 40313215 +G-C8QO IV - Moon 2 + Bitumens 0.503379404545 45492 30004945 40313214 40313216 + Sylvite 0.296620607376 45491 30004945 40313214 40313216 +G-C8QO IV - Moon 3 + Coesite 0.212857395411 45493 30004945 40313214 40313217 + Sylvite 0.297155380249 45491 30004945 40313214 40313217 + Zeolites 0.289987236261 45490 30004945 40313214 40313217 +G-C8QO V - Moon 1 + Bitumens 0.232534274459 45492 30004945 40313218 40313219 + Coesite 0.567465722561 45493 30004945 40313218 40313219 +G-C8QO V - Moon 2 + Bitumens 0.329390406609 45492 30004945 40313218 40313220 + Sylvite 0.47060957551 45491 30004945 40313218 40313220 +G-C8QO V - Moon 3 + Coesite 0.304066926241 45493 30004945 40313218 40313221 + Zeolites 0.49593308568 45490 30004945 40313218 40313221 +VR-YIQ III - Moon 1 + Sylvite 0.50638282299 45491 30004931 40312305 40312306 + Zeolites 0.293617159128 45490 30004931 40312305 40312306 +VR-YIQ III - Moon 2 + Bitumens 0.288179278374 45492 30004931 40312305 40312307 + Coesite 0.294447183609 45493 30004931 40312305 40312307 + Sylvite 0.217373535037 45491 30004931 40312305 40312307 +VR-YIQ III - Moon 3 + Bitumens 0.473933756351 45492 30004931 40312305 40312308 + Coesite 0.326066225767 45493 30004931 40312305 40312308 +VR-YIQ III - Moon 4 + Bitumens 0.446674197912 45492 30004931 40312305 40312309 + Sylvite 0.353325814009 45491 30004931 40312305 40312309 +VR-YIQ IV - Moon 1 + Bitumens 0.218338191509 45492 30004931 40312310 40312311 + Coesite 0.252426713705 45493 30004931 40312310 40312311 + Zeolites 0.329235106707 45490 30004931 40312310 40312311 +VR-YIQ IV - Moon 2 + Bitumens 0.531163334846 45492 30004931 40312310 40312312 + Coesite 0.268836647272 45493 30004931 40312310 40312312 +VR-YIQ IV - Moon 3 + Sylvite 0.473139047623 45491 30004931 40312310 40312313 + Zeolites 0.326860964298 45490 30004931 40312310 40312313 +VR-YIQ IV - Moon 4 + Bitumens 0.308904796839 45492 30004931 40312310 40312314 + Sylvite 0.282218307257 45491 30004931 40312310 40312314 + Zeolites 0.208876907825 45490 30004931 40312310 40312314 +VR-YIQ IV - Moon 5 + Coesite 0.521205127239 45493 30004931 40312310 40312315 + Zeolites 0.278794884682 45490 30004931 40312310 40312315 +VR-YIQ V - Moon 1 + Bitumens 0.346758961678 45492 30004931 40312316 40312319 + Sylvite 0.453241050243 45491 30004931 40312316 40312319 +VR-YIQ VI - Moon 1 + Bitumens 0.455002427101 45492 30004931 40312320 40312321 + Sylvite 0.34499758482 45491 30004931 40312320 40312321 +VR-YIQ VI - Moon 2 + Bitumens 0.323783993721 45492 30004931 40312320 40312323 + Cinnabar 0.200178205967 45506 30004931 40312320 40312323 + Euxenite 0.0869659110904 45495 30004931 40312320 40312323 + Vanadinite 0.389071881771 45500 30004931 40312320 40312323 +VR-YIQ VI - Moon 3 + Bitumens 0.344211995602 45492 30004931 40312320 40312324 + Sylvite 0.455787986517 45491 30004931 40312320 40312324 +VR-YIQ VI - Moon 4 + Bitumens 0.325232893229 45492 30004931 40312320 40312325 + Coesite 0.47476708889 45493 30004931 40312320 40312325 +VR-YIQ VI - Moon 5 + Bitumens 0.288085103035 45492 30004931 40312320 40312326 + Coesite 0.318000227213 45493 30004931 40312320 40312326 + Zeolites 0.193914681673 45490 30004931 40312320 40312326 +VR-YIQ VI - Moon 6 + Bitumens 0.323773801327 45492 30004931 40312320 40312327 + Coesite 0.191603213549 45493 30004931 40312320 40312327 + Sylvite 0.284622997046 45491 30004931 40312320 40312327 +VR-YIQ VI - Moon 7 + Bitumens 0.341933965683 45492 30004931 40312320 40312328 + Sylvite 0.292913377285 45491 30004931 40312320 40312328 + Zeolites 0.165152668953 45490 30004931 40312320 40312328 +VR-YIQ VI - Moon 8 + Bitumens 0.279573410749 45492 30004931 40312320 40312329 + Coesite 0.520426571369 45493 30004931 40312320 40312329 +VR-YIQ VI - Moon 9 + Cobaltite 0.339975118637 45494 30004931 40312320 40312330 + Coesite 0.222661107779 45493 30004931 40312320 40312330 + Sylvite 0.437363773584 45491 30004931 40312320 40312330 +VR-YIQ VI - Moon 10 + Coesite 0.301687896252 45493 30004931 40312320 40312331 + Sylvite 0.227686882019 45491 30004931 40312320 40312331 + Zeolites 0.270625203848 45490 30004931 40312320 40312331 +VR-YIQ VI - Moon 11 + Sylvite 0.482364505529 45491 30004931 40312320 40312332 + Zeolites 0.317635506392 45490 30004931 40312320 40312332 +VR-YIQ VI - Moon 12 + Bitumens 0.492799967527 45492 30004931 40312320 40312333 + Sylvite 0.307200014591 45491 30004931 40312320 40312333 +VR-YIQ VI - Moon 13 + Cobaltite 0.405511647463 45494 30004931 40312320 40312334 + Coesite 0.173067882657 45493 30004931 40312320 40312334 + Euxenite 0.204879358411 45495 30004931 40312320 40312334 + Zeolites 0.21654112637 45490 30004931 40312320 40312334 +VR-YIQ VI - Moon 14 + Bitumens 0.499151080847 45492 30004931 40312320 40312335 + Coesite 0.300848931074 45493 30004931 40312320 40312335 +VR-YIQ VI - Moon 15 + Cobaltite 0.238770529628 45494 30004931 40312320 40312336 + Sylvite 0.269795119762 45491 30004931 40312320 40312336 + Zeolites 0.491434365511 45490 30004931 40312320 40312336 +VR-YIQ VI - Moon 16 + Bitumens 0.262476474047 45492 30004931 40312320 40312337 + Cobaltite 0.328280359507 45494 30004931 40312320 40312337 + Zeolites 0.409243166447 45490 30004931 40312320 40312337 +VR-YIQ VI - Moon 17 + Bitumens 0.265098303556 45492 30004931 40312320 40312338 + Cobaltite 0.30201280117 45494 30004931 40312320 40312338 + Coesite 0.191304579377 45493 30004931 40312320 40312338 + Zeolites 0.241584315896 45490 30004931 40312320 40312338 +VR-YIQ VI - Moon 18 + Coesite 0.543393492699 45493 30004931 40312320 40312340 + Zeolites 0.25660648942 45490 30004931 40312320 40312340 +VR-YIQ VII - Moon 1 + Coesite 0.319840401411 45493 30004931 40312341 40312343 + Sylvite 0.218211948872 45491 30004931 40312341 40312343 + Zeolites 0.261947661638 45490 30004931 40312341 40312343 +VR-YIQ VII - Moon 2 + Coesite 0.567909061909 45493 30004931 40312341 40312344 + Zeolites 0.232090935111 45490 30004931 40312341 40312344 +F-M1FU IV - Moon 1 + Bitumens 0.231906935573 45492 30004929 40312191 40312192 + Coesite 0.255553126335 45493 30004929 40312191 40312192 + Zeolites 0.312539935112 45490 30004929 40312191 40312192 +F-M1FU V - Moon 1 + Bitumens 0.187952727079 45492 30004929 40312193 40312195 + Sylvite 0.312811911106 45491 30004929 40312193 40312195 + Zeolites 0.299235373735 45490 30004929 40312193 40312195 +F-M1FU VI - Moon 1 + Bitumens 0.408662557602 45492 30004929 40312196 40312197 + Cobaltite 0.197054386139 45494 30004929 40312196 40312197 + Sperrylite 0.09428306669 45499 30004929 40312196 40312197 +F-M1FU VI - Moon 2 + Cobaltite 0.200611308217 45494 30004929 40312196 40312201 + Sperrylite 0.081373475492 45499 30004929 40312196 40312201 + Zeolites 0.418015211821 45490 30004929 40312196 40312201 +F-M1FU VI - Moon 3 + Bitumens 0.20771625638 45492 30004929 40312196 40312202 + Cobaltite 0.32578933239 45494 30004929 40312196 40312202 + Sylvite 0.176845520735 45491 30004929 40312196 40312202 + Zeolites 0.289648890495 45490 30004929 40312196 40312202 +F-M1FU VI - Moon 4 + Cobaltite 0.411185353994 45494 30004929 40312196 40312204 + Coesite 0.403967797756 45493 30004929 40312196 40312204 + Euxenite 0.184846833348 45495 30004929 40312196 40312204 +F-M1FU VI - Moon 5 + Bitumens 0.522868931293 45492 30004929 40312196 40312205 + Sylvite 0.277131050825 45491 30004929 40312196 40312205 +F-M1FU VI - Moon 6 + Coesite 0.501849114895 45493 30004929 40312196 40312206 + Zeolites 0.298150897026 45490 30004929 40312196 40312206 +F-M1FU VI - Moon 7 + Bitumens 0.202318534255 45492 30004929 40312196 40312207 + Coesite 0.258730858564 45493 30004929 40312196 40312207 + Zeolites 0.3389506042 45490 30004929 40312196 40312207 +F-M1FU VI - Moon 8 + Cobaltite 0.314062207937 45494 30004929 40312196 40312208 + Coesite 0.251911580563 45493 30004929 40312196 40312208 + Sylvite 0.4340262115 45491 30004929 40312196 40312208 +F-M1FU VI - Moon 9 + Cinnabar 0.21490649879 45506 30004929 40312196 40312210 + Coesite 0.0952559560537 45493 30004929 40312196 40312210 + Sylvite 0.248871877789 45491 30004929 40312196 40312210 + Zeolites 0.440965652466 45490 30004929 40312196 40312210 +F-M1FU VI - Moon 10 + Coesite 0.499473512173 45493 30004929 40312196 40312212 + Zeolites 0.300526499748 45490 30004929 40312196 40312212 +F-M1FU VI - Moon 11 + Bitumens 0.216622129083 45492 30004929 40312196 40312213 + Sylvite 0.30556383729 45491 30004929 40312196 40312213 + Zeolites 0.277814030647 45490 30004929 40312196 40312213 +F-M1FU VI - Moon 12 + Bitumens 0.287740170956 45492 30004929 40312196 40312214 + Cinnabar 0.172970727086 45506 30004929 40312196 40312214 + Otavite 0.446107566357 45498 30004929 40312196 40312214 + Scheelite 0.093181528151 45497 30004929 40312196 40312214 +F-M1FU VI - Moon 13 + Bitumens 0.471726149321 45492 30004929 40312196 40312216 + Sylvite 0.3282738626 45491 30004929 40312196 40312216 +F-M1FU VI - Moon 14 + Bitumens 0.453384429216 45492 30004929 40312196 40312218 + Coesite 0.346615582705 45493 30004929 40312196 40312218 +F-M1FU VII - Moon 1 + Bitumens 0.259269863367 45492 30004929 40312220 40312222 + Sylvite 0.335178226233 45491 30004929 40312220 40312222 + Zeolites 0.20555190742 45490 30004929 40312220 40312222 +F-M1FU VII - Moon 2 + Bitumens 0.199254408479 45492 30004929 40312220 40312223 + Sylvite 0.258073657751 45491 30004929 40312220 40312223 + Zeolites 0.342671900988 45490 30004929 40312220 40312223 +F-M1FU VII - Moon 3 + Coesite 0.546441376209 45493 30004929 40312220 40312224 + Zeolites 0.253558635712 45490 30004929 40312220 40312224 +F-M1FU VII - Moon 4 + Coesite 0.264872640371 45493 30004929 40312220 40312225 + Sylvite 0.206555530429 45491 30004929 40312220 40312225 + Zeolites 0.32857182622 45490 30004929 40312220 40312225 +F-M1FU VII - Moon 5 + Bitumens 0.279523789883 45492 30004929 40312220 40312226 + Coesite 0.322294682264 45493 30004929 40312220 40312226 + Zeolites 0.198181524873 45490 30004929 40312220 40312226 +F-M1FU VIII - Moon 1 + Sylvite 0.263294309378 45491 30004929 40312227 40312228 + Zeolites 0.536705732346 45490 30004929 40312227 40312228 +F-M1FU VIII - Moon 2 + Bitumens 0.294870853424 45492 30004929 40312227 40312229 + Coesite 0.323671489954 45493 30004929 40312227 40312229 + Sylvite 0.181457638741 45491 30004929 40312227 40312229 +F-M1FU VIII - Moon 3 + Cobaltite 0.427956432104 45494 30004929 40312227 40312230 + Sylvite 0.168861955404 45491 30004929 40312227 40312230 + Zeolites 0.403181642294 45490 30004929 40312227 40312230 +F-M1FU VIII - Moon 4 + Bitumens 0.463182061911 45492 30004929 40312227 40312231 + Sylvite 0.33681795001 45491 30004929 40312227 40312231 +F-M1FU VIII - Moon 5 + Coesite 0.238779425621 45493 30004929 40312227 40312234 + Sylvite 0.306274414062 45491 30004929 40312227 40312234 + Zeolites 0.254946172237 45490 30004929 40312227 40312234 +F-M1FU VIII - Moon 6 + Cobaltite 0.408796399832 45494 30004929 40312227 40312235 + Euxenite 0.172864094377 45495 30004929 40312227 40312235 + Zeolites 0.418339490891 45490 30004929 40312227 40312235 +F-M1FU VIII - Moon 7 + Bitumens 0.255580574274 45492 30004929 40312227 40312237 + Coesite 0.199068233371 45493 30004929 40312227 40312237 + Sylvite 0.345351189375 45491 30004929 40312227 40312237 +F-M1FU VIII - Moon 8 + Bitumens 0.184401750565 45492 30004929 40312227 40312239 + Coesite 0.33576336503 45493 30004929 40312227 40312239 + Zeolites 0.279834896326 45490 30004929 40312227 40312239 +F-M1FU VIII - Moon 9 + Bitumens 0.467099398375 45492 30004929 40312227 40312240 + Coesite 0.332900583744 45493 30004929 40312227 40312240 +F-M1FU VIII - Moon 10 + Sylvite 0.478438109159 45491 30004929 40312227 40312242 + Zeolites 0.321561902761 45490 30004929 40312227 40312242 +F-M1FU VIII - Moon 11 + Bitumens 0.284627437592 45492 30004929 40312227 40312244 + Coesite 0.319137871265 45493 30004929 40312227 40312244 + Sylvite 0.196234717965 45491 30004929 40312227 40312244 +F-M1FU VIII - Moon 12 + Sylvite 0.488487452269 45491 30004929 40312227 40312246 + Zeolites 0.31151252985 45490 30004929 40312227 40312246 +F-M1FU VIII - Moon 13 + Coesite 0.49275675416 45493 30004929 40312227 40312248 + Zeolites 0.307243227959 45490 30004929 40312227 40312248 +F-M1FU IX - Moon 1 + Bitumens 0.335473001003 45492 30004929 40312249 40312250 + Coesite 0.289584755898 45493 30004929 40312249 40312250 + Sylvite 0.174942240119 45491 30004929 40312249 40312250 +F-M1FU IX - Moon 2 + Bitumens 0.321173340082 45492 30004929 40312249 40312251 + Sylvite 0.278120160103 45491 30004929 40312249 40312251 + Zeolites 0.200706481934 45490 30004929 40312249 40312251 +F-M1FU IX - Moon 3 + Bitumens 0.228590071201 45492 30004929 40312249 40312252 + Sylvite 0.273675382137 45491 30004929 40312249 40312252 + Zeolites 0.297734558582 45490 30004929 40312249 40312252 +F-M1FU IX - Moon 4 + Bitumens 0.313772916794 45492 30004929 40312249 40312254 + Sylvite 0.486227095127 45491 30004929 40312249 40312254 +F-M1FU IX - Moon 5 + Bitumens 0.295798331499 45492 30004929 40312249 40312256 + Coesite 0.50420165062 45493 30004929 40312249 40312256 +F-M1FU X - Moon 1 + Coesite 0.309585511684 45493 30004929 40312257 40312259 + Sylvite 0.227467373013 45491 30004929 40312257 40312259 + Zeolites 0.262947112322 45490 30004929 40312257 40312259 +F-M1FU X - Moon 2 + Sylvite 0.494994729757 45491 30004929 40312257 40312260 + Zeolites 0.305005282164 45490 30004929 40312257 40312260 +F-M1FU X - Moon 3 + Sylvite 0.450358390808 45491 30004929 40312257 40312261 + Zeolites 0.349641591311 45490 30004929 40312257 40312261 +F-M1FU X - Moon 4 + Bitumens 0.449903637171 45492 30004929 40312257 40312262 + Cobaltite 0.310088127851 45494 30004929 40312257 40312262 + Zeolites 0.240008234978 45490 30004929 40312257 40312262 +L-YMYU III - Moon 1 + Bitumens 0.314729452133 45492 30004927 40312156 40312157 + Sylvite 0.485270559788 45491 30004927 40312156 40312157 +L-YMYU IV - Moon 1 + Coesite 0.5797945261 45493 30004927 40312158 40312160 + Vanadinite 0.4202054739 45500 30004927 40312158 40312160 +L-YMYU V - Moon 1 + Bitumens 0.218070402741 45492 30004927 40312161 40312162 + Coesite 0.26191970706 45493 30004927 40312161 40312162 + Zeolites 0.320009887218 45490 30004927 40312161 40312162 +L-YMYU VI - Moon 1 + Bitumens 0.191684246063 45492 30004927 40312163 40312164 + Cobaltite 0.278078913689 45494 30004927 40312163 40312164 + Sylvite 0.530236840248 45491 30004927 40312163 40312164 +L-YMYU VII - Moon 1 + Bitumens 0.328966736794 45492 30004927 40312166 40312167 + Coesite 0.471033275127 45493 30004927 40312166 40312167 +L-YMYU VII - Moon 2 + Bitumens 0.444776535034 45492 30004927 40312166 40312168 + Coesite 0.355223476887 45493 30004927 40312166 40312168 +L-YMYU VIII - Moon 1 + Bitumens 0.291235595942 45492 30004927 40312169 40312171 + Cobaltite 0.110509827733 45494 30004927 40312169 40312171 + Sylvite 0.341663688421 45491 30004927 40312169 40312171 + Vanadinite 0.256590902805 45500 30004927 40312169 40312171 +L-YMYU VIII - Moon 2 + Bitumens 0.298214137554 45492 30004927 40312169 40312172 + Sylvite 0.501785874367 45491 30004927 40312169 40312172 +L-YMYU VIII - Moon 3 + Bitumens 0.263291567564 45492 30004927 40312169 40312173 + Cobaltite 0.252018034458 45494 30004927 40312169 40312173 + Coesite 0.258104771376 45493 30004927 40312169 40312173 + Zeolites 0.226585641503 45490 30004927 40312169 40312173 +L-YMYU VIII - Moon 4 + Bitumens 0.184101954103 45492 30004927 40312169 40312174 + Sylvite 0.285483390093 45491 30004927 40312169 40312174 + Zeolites 0.330414682627 45490 30004927 40312169 40312174 +L-YMYU VIII - Moon 5 + Coesite 0.321904331446 45493 30004927 40312169 40312175 + Sylvite 0.170464724302 45491 30004927 40312169 40312175 + Zeolites 0.307630956173 45490 30004927 40312169 40312175 +L-YMYU IX - Moon 1 + Bitumens 0.337040275335 45492 30004927 40312176 40312179 + Coesite 0.279847353697 45493 30004927 40312176 40312179 + Sylvite 0.183112353086 45491 30004927 40312176 40312179 +XZ-SKZ IV - Moon 1 + Bitumens 0.196031242609 45492 30004932 40312351 40312352 + Cobaltite 0.269838631153 45494 30004932 40312351 40312352 + Zeolites 0.53413015604 45490 30004932 40312351 40312352 +XZ-SKZ V - Moon 1 + Coesite 0.315239757299 45493 30004932 40312353 40312354 + Sylvite 0.185023069382 45491 30004932 40312353 40312354 + Zeolites 0.29973718524 45490 30004932 40312353 40312354 +XZ-SKZ VI - Moon 1 + Sylvite 0.509704470634 45491 30004932 40312356 40312357 + Zeolites 0.290295511484 45490 30004932 40312356 40312357 +XZ-SKZ VI - Moon 2 + Bitumens 0.234228342772 45492 30004932 40312356 40312358 + Cobaltite 0.265436828136 45494 30004932 40312356 40312358 + Coesite 0.50033479929 45493 30004932 40312356 40312358 +XZ-SKZ VI - Moon 3 + Sylvite 0.241353690624 45491 30004932 40312356 40312359 + Zeolites 0.558646321297 45490 30004932 40312356 40312359 +XZ-SKZ VI - Moon 4 + Bitumens 0.261391460896 45492 30004932 40312356 40312360 + Sylvite 0.538608551025 45491 30004932 40312356 40312360 +XZ-SKZ VI - Moon 5 + Cobaltite 0.291808187962 45494 30004932 40312356 40312361 + Sylvite 0.194481432438 45491 30004932 40312356 40312361 + Zeolites 0.513710379601 45490 30004932 40312356 40312361 +XZ-SKZ VI - Moon 6 + Cobaltite 0.187752559781 45494 30004932 40312356 40312362 + Otavite 0.102119550109 45498 30004932 40312356 40312362 + Sylvite 0.410127878189 45491 30004932 40312356 40312362 +XZ-SKZ VII - Moon 1 + Bitumens 0.441039443016 45492 30004932 40312363 40312365 + Cobaltite 0.389254838228 45494 30004932 40312363 40312365 + Zeolites 0.169705748558 45490 30004932 40312363 40312365 +XZ-SKZ VII - Moon 2 + Bitumens 0.300394117832 45492 30004932 40312363 40312366 + Cobaltite 0.279190540314 45494 30004932 40312363 40312366 + Zeolites 0.420415341854 45490 30004932 40312363 40312366 +XZ-SKZ VII - Moon 3 + Coesite 0.271349459887 45493 30004932 40312363 40312367 + Zeolites 0.528650522232 45490 30004932 40312363 40312367 +XZ-SKZ VII - Moon 4 + Bitumens 0.174939915538 45492 30004932 40312363 40312368 + Sylvite 0.340378671885 45491 30004932 40312363 40312368 + Zeolites 0.284681409597 45490 30004932 40312363 40312368 +XZ-SKZ VII - Moon 5 + Bitumens 0.460183978081 45492 30004932 40312363 40312369 + Coesite 0.33981603384 45493 30004932 40312363 40312369 +XZ-SKZ VII - Moon 6 + Coesite 0.296514421701 45493 30004932 40312363 40312370 + Zeolites 0.503485560417 45490 30004932 40312363 40312370 +XZ-SKZ VII - Moon 7 + Bitumens 0.308865129948 45492 30004932 40312363 40312371 + Coesite 0.491134852171 45493 30004932 40312363 40312371 +XZ-SKZ VII - Moon 8 + Bitumens 0.223740056157 45492 30004932 40312363 40312372 + Sylvite 0.276253819466 45491 30004932 40312363 40312372 + Zeolites 0.300006121397 45490 30004932 40312363 40312372 +XZ-SKZ VII - Moon 9 + Coesite 0.225437983871 45493 30004932 40312363 40312373 + Sylvite 0.312716960907 45491 30004932 40312363 40312373 + Zeolites 0.261845052242 45490 30004932 40312363 40312373 +XZ-SKZ VII - Moon 10 + Bitumens 0.183460518718 45492 30004932 40312363 40312374 + Coesite 0.311120569706 45493 30004932 40312363 40312374 + Zeolites 0.305418908596 45490 30004932 40312363 40312374 +XZ-SKZ VII - Moon 11 + Coesite 0.530951559544 45493 30004932 40312363 40312375 + Zeolites 0.269048452377 45490 30004932 40312363 40312375 +XZ-SKZ VII - Moon 12 + Bitumens 0.343605577946 45492 30004932 40312363 40312376 + Sylvite 0.277191728354 45491 30004932 40312363 40312376 + Zeolites 0.179202705622 45490 30004932 40312363 40312376 +XZ-SKZ VII - Moon 13 + Bitumens 0.330246686935 45492 30004932 40312363 40312377 + Coesite 0.168315812945 45493 30004932 40312363 40312377 + Sylvite 0.301437497139 45491 30004932 40312363 40312377 +XZ-SKZ VII - Moon 14 + Coesite 0.179698109627 45493 30004932 40312363 40312378 + Sylvite 0.32124081254 45491 30004932 40312363 40312378 + Zeolites 0.299061089754 45490 30004932 40312363 40312378 +XZ-SKZ VII - Moon 15 + Bitumens 0.261191666126 45492 30004932 40312363 40312379 + Sylvite 0.313823223114 45491 30004932 40312363 40312379 + Zeolites 0.22498510778 45490 30004932 40312363 40312379 +XZ-SKZ VII - Moon 16 + Coesite 0.305033653975 45493 30004932 40312363 40312380 + Sylvite 0.211457028985 45491 30004932 40312363 40312380 + Zeolites 0.28350931406 45490 30004932 40312363 40312380 +XZ-SKZ VII - Moon 17 + Sylvite 0.484344184399 45491 30004932 40312363 40312381 + Zeolites 0.315655827522 45490 30004932 40312363 40312381 +XZ-SKZ VIII - Moon 1 + Bitumens 0.22927545011 45492 30004932 40312382 40312383 + Otavite 0.379921793938 45498 30004932 40312382 40312383 + Sylvite 0.171287164092 45491 30004932 40312382 40312383 + Zeolites 0.21951559186 45490 30004932 40312382 40312383 +XZ-SKZ VIII - Moon 2 + Bitumens 0.332048565149 45492 30004932 40312382 40312384 + Sylvite 0.274126201868 45491 30004932 40312382 40312384 + Zeolites 0.193825230002 45490 30004932 40312382 40312384 +XZ-SKZ VIII - Moon 3 + Bitumens 0.190398767591 45492 30004932 40312382 40312385 + Coesite 0.298218876123 45493 30004932 40312382 40312385 + Zeolites 0.311382353306 45490 30004932 40312382 40312385 +XZ-SKZ VIII - Moon 4 + Bitumens 0.558701395988 45492 30004932 40312382 40312386 + Coesite 0.241298615932 45493 30004932 40312382 40312386 +XZ-SKZ VIII - Moon 5 + Bitumens 0.286838680506 45492 30004932 40312382 40312387 + Coesite 0.295662075281 45493 30004932 40312382 40312387 + Sylvite 0.217499271035 45491 30004932 40312382 40312387 +XZ-SKZ VIII - Moon 6 + Bitumens 0.300592899323 45492 30004932 40312382 40312388 + Coesite 0.499407112598 45493 30004932 40312382 40312388 +XZ-SKZ VIII - Moon 7 + Sylvite 0.473748803139 45491 30004932 40312382 40312389 + Zeolites 0.326251208782 45490 30004932 40312382 40312389 +XZ-SKZ VIII - Moon 8 + Bitumens 0.492540836334 45492 30004932 40312382 40312390 + Sylvite 0.307459175587 45491 30004932 40312382 40312390 +XZ-SKZ VIII - Moon 9 + Bitumens 0.289745599031 45492 30004932 40312382 40312391 + Coesite 0.305500239134 45493 30004932 40312382 40312391 + Zeolites 0.204754158854 45490 30004932 40312382 40312391 +XZ-SKZ VIII - Moon 10 + Cobaltite 0.593750059605 45494 30004932 40312382 40312392 + Sylvite 0.406249970198 45491 30004932 40312382 40312392 +XZ-SKZ VIII - Moon 11 + Coesite 0.508572280407 45493 30004932 40312382 40312393 + Zeolites 0.291427701712 45490 30004932 40312382 40312393 +XZ-SKZ VIII - Moon 12 + Bitumens 0.51405185461 45492 30004932 40312382 40312394 + Sylvite 0.28594815731 45491 30004932 40312382 40312394 +XZ-SKZ VIII - Moon 13 + Bitumens 0.486865282059 45492 30004932 40312382 40312395 + Coesite 0.31313470006 45493 30004932 40312382 40312395 +XZ-SKZ VIII - Moon 14 + Bitumens 0.325369536877 45492 30004932 40312382 40312396 + Coesite 0.474630475044 45493 30004932 40312382 40312396 +XZ-SKZ VIII - Moon 15 + Cobaltite 0.210623398423 45494 30004932 40312382 40312397 + Sylvite 0.396143257618 45491 30004932 40312382 40312397 + Vanadinite 0.0932333469391 45500 30004932 40312382 40312397 +XZ-SKZ VIII - Moon 16 + Coesite 0.29126393795 45493 30004932 40312382 40312398 + Zeolites 0.508736073971 45490 30004932 40312382 40312398 +XZ-SKZ VIII - Moon 17 + Sylvite 0.535859167576 45491 30004932 40312382 40312399 + Zeolites 0.264140844345 45490 30004932 40312382 40312399 +XZ-SKZ VIII - Moon 18 + Coesite 0.201838508248 45493 30004932 40312382 40312400 + Sylvite 0.344958513975 45491 30004932 40312382 40312400 + Zeolites 0.253202974796 45490 30004932 40312382 40312400 +XZ-SKZ VIII - Moon 19 + Bitumens 0.302465319633 45492 30004932 40312382 40312402 + Coesite 0.322160631418 45493 30004932 40312382 40312402 + Sylvite 0.175374045968 45491 30004932 40312382 40312402 +XZ-SKZ VIII - Moon 20 + Bitumens 0.504654228687 45492 30004932 40312382 40312403 + Coesite 0.295345813036 45493 30004932 40312382 40312403 +XZ-SKZ VIII - Moon 21 + Bitumens 0.185712918639 45492 30004932 40312382 40312405 + Sylvite 0.280033111572 45491 30004932 40312382 40312405 + Zeolites 0.334253966808 45490 30004932 40312382 40312405 +XZ-SKZ IX - Moon 1 + Bitumens 0.286024868488 45492 30004932 40312406 40312407 + Coesite 0.331477701664 45493 30004932 40312406 40312407 + Sylvite 0.182497441769 45491 30004932 40312406 40312407 +XZ-SKZ IX - Moon 2 + Bitumens 0.349000394344 45492 30004932 40312406 40312408 + Coesite 0.18145494163 45493 30004932 40312406 40312408 + Sylvite 0.269544631243 45491 30004932 40312406 40312408 +XZ-SKZ IX - Moon 3 + Cobaltite 0.162078812718 45494 30004932 40312406 40312409 + Coesite 0.434208840132 45493 30004932 40312406 40312409 + Sperrylite 0.103712365031 45499 30004932 40312406 40312409 +XZ-SKZ IX - Moon 4 + Bitumens 0.518410265446 45492 30004932 40312406 40312410 + Coesite 0.281589746475 45493 30004932 40312406 40312410 +XZ-SKZ X - Moon 1 + Bitumens 0.291751414537 45492 30004932 40312411 40312412 + Coesite 0.334726810455 45493 30004932 40312411 40312412 + Sylvite 0.173521757126 45491 30004932 40312411 40312412 +XZ-SKZ X - Moon 2 + Bitumens 0.305741101503 45492 30004932 40312411 40312413 + Coesite 0.323115944862 45493 30004932 40312411 40312413 + Sylvite 0.171142950654 45491 30004932 40312411 40312413 +0-NTIS II - Moon 1 + Coesite 0.274116307497 45493 30004930 40312265 40312267 + Sylvite 0.190580114722 45491 30004930 40312265 40312267 + Zeolites 0.3353035748 45490 30004930 40312265 40312267 +0-NTIS IV - Moon 1 + Bitumens 0.302026063204 45492 30004930 40312269 40312270 + Coesite 0.235730692744 45493 30004930 40312269 40312270 + Sylvite 0.262243270874 45491 30004930 40312269 40312270 +0-NTIS V - Moon 1 + Bitumens 0.471643686295 45492 30004930 40312271 40312272 + Coesite 0.328356325626 45493 30004930 40312271 40312272 +0-NTIS VI - Moon 1 + Bitumens 0.282591044903 45492 30004930 40312273 40312274 + Sylvite 0.517408967018 45491 30004930 40312273 40312274 +0-NTIS VI - Moon 2 + Bitumens 0.301532149315 45492 30004930 40312273 40312275 + Coesite 0.21114090085 45493 30004930 40312273 40312275 + Sylvite 0.287326931953 45491 30004930 40312273 40312275 +0-NTIS VII - Moon 1 + Bitumens 0.478066265583 45492 30004930 40312276 40312277 + Sylvite 0.321933746338 45491 30004930 40312276 40312277 +0-NTIS VII - Moon 2 + Bitumens 0.291759520769 45492 30004930 40312276 40312278 + Sylvite 0.508240461349 45491 30004930 40312276 40312278 +0-NTIS VII - Moon 3 + Bitumens 0.270672857761 45492 30004930 40312276 40312279 + Sylvite 0.347713321447 45491 30004930 40312276 40312279 + Zeolites 0.181613817811 45490 30004930 40312276 40312279 +0-NTIS VII - Moon 4 + Sylvite 0.501650035381 45491 30004930 40312276 40312280 + Zeolites 0.298350006342 45490 30004930 40312276 40312280 +0-NTIS VII - Moon 5 + Coesite 0.5351344347 45493 30004930 40312276 40312281 + Zeolites 0.264865547419 45490 30004930 40312276 40312281 +0-NTIS VII - Moon 6 + Coesite 0.34298953414 45493 30004930 40312276 40312282 + Sylvite 0.197879523039 45491 30004930 40312276 40312282 + Zeolites 0.25913092494 45490 30004930 40312276 40312282 +0-NTIS VII - Moon 7 + Bitumens 0.31568133831 45492 30004930 40312276 40312283 + Coesite 0.304195553064 45493 30004930 40312276 40312283 + Zeolites 0.180123090744 45490 30004930 40312276 40312283 +0-NTIS VII - Moon 8 + Bitumens 0.247330144048 45492 30004930 40312276 40312284 + Sylvite 0.289140254259 45491 30004930 40312276 40312284 + Zeolites 0.263529598713 45490 30004930 40312276 40312284 +0-NTIS VII - Moon 9 + Bitumens 0.413204550743 45492 30004930 40312276 40312285 + Cobaltite 0.208304464817 45494 30004930 40312276 40312285 + Vanadinite 0.0784909874201 45500 30004930 40312276 40312285 +0-NTIS VII - Moon 10 + Sylvite 0.455803126097 45491 30004930 40312276 40312286 + Zeolites 0.344196885824 45490 30004930 40312276 40312286 +0-NTIS VII - Moon 11 + Bitumens 0.319943726063 45492 30004930 40312276 40312287 + Sylvite 0.480056285858 45491 30004930 40312276 40312287 +0-NTIS VII - Moon 12 + Bitumens 0.330816864967 45492 30004930 40312276 40312288 + Coesite 0.175563395023 45493 30004930 40312276 40312288 + Sylvite 0.29361975193 45491 30004930 40312276 40312288 +0-NTIS VII - Moon 13 + Coesite 0.197370097041 45493 30004930 40312276 40312289 + Sylvite 0.277871668339 45491 30004930 40312276 40312289 + Zeolites 0.324758261442 45490 30004930 40312276 40312289 +0-NTIS VII - Moon 14 + Coesite 0.289183497429 45493 30004930 40312276 40312291 + Sylvite 0.194981098175 45491 30004930 40312276 40312291 + Zeolites 0.315835416317 45490 30004930 40312276 40312291 +0-NTIS VII - Moon 15 + Cobaltite 0.173084795475 45494 30004930 40312276 40312292 + Sylvite 0.426726013422 45491 30004930 40312276 40312292 + Vanadinite 0.100189194083 45500 30004930 40312276 40312292 +0-NTIS VII - Moon 16 + Sylvite 0.277830570936 45491 30004930 40312276 40312293 + Zeolites 0.522169411182 45490 30004930 40312276 40312293 +0-NTIS VII - Moon 17 + Bitumens 0.180798977613 45492 30004930 40312276 40312294 + Cobaltite 0.395866185427 45494 30004930 40312276 40312294 + Coesite 0.190165400505 45493 30004930 40312276 40312294 + Titanite 0.233169436455 45496 30004930 40312276 40312294 +0-NTIS VII - Moon 18 + Bitumens 0.213177844882 45492 30004930 40312276 40312295 + Cobaltite 0.353643894196 45494 30004930 40312276 40312295 + Coesite 0.202164560556 45493 30004930 40312276 40312295 + Sylvite 0.231013700366 45491 30004930 40312276 40312295 +0-NTIS VII - Moon 19 + Coesite 0.474470168352 45493 30004930 40312276 40312296 + Zeolites 0.325529813766 45490 30004930 40312276 40312296 +0-NTIS VIII - Moon 1 + Bitumens 0.46665430069 45492 30004930 40312297 40312298 + Coesite 0.333345711231 45493 30004930 40312297 40312298 +0-NTIS VIII - Moon 2 + Coesite 0.231945887208 45493 30004930 40312297 40312300 + Sylvite 0.273130476475 45491 30004930 40312297 40312300 + Zeolites 0.294923633337 45490 30004930 40312297 40312300 +I6M-9U II - Moon 1 + Bitumens 0.310708701611 45492 30004933 40312418 40312419 + Coesite 0.48929131031 45493 30004933 40312418 40312419 +I6M-9U III - Moon 1 + Bitumens 0.282557100058 45492 30004933 40312420 40312421 + Coesite 0.517442882061 45493 30004933 40312420 40312421 +I6M-9U IV - Moon 1 + Bitumens 0.182421088219 45492 30004933 40312422 40312424 + Coesite 0.332538425922 45493 30004933 40312422 40312424 + Zeolites 0.28504049778 45490 30004933 40312422 40312424 +I6M-9U VI - Moon 1 + Bitumens 0.300586491823 45492 30004933 40312426 40312427 + Coesite 0.316275775433 45493 30004933 40312426 40312427 + Sylvite 0.183137744665 45491 30004933 40312426 40312427 +I6M-9U VI - Moon 2 + Sylvite 0.36022952199 45491 30004933 40312426 40312428 + Zeolites 0.439770460129 45490 30004933 40312426 40312428 +I6M-9U VI - Moon 3 + Bitumens 0.558000981808 45492 30004933 40312426 40312430 + Sylvite 0.241999015212 45491 30004933 40312426 40312430 +I6M-9U VI - Moon 4 + Bitumens 0.203951850533 45492 30004933 40312426 40312432 + Sylvite 0.284587860107 45491 30004933 40312426 40312432 + Zeolites 0.311460286379 45490 30004933 40312426 40312432 +I6M-9U VI - Moon 5 + Bitumens 0.259933650494 45492 30004933 40312426 40312433 + Coesite 0.203963816166 45493 30004933 40312426 40312433 + Sylvite 0.336102515459 45491 30004933 40312426 40312433 +I6M-9U VI - Moon 6 + Coesite 0.274847626686 45493 30004933 40312426 40312434 + Sylvite 0.242314070463 45491 30004933 40312426 40312434 + Zeolites 0.282838314772 45490 30004933 40312426 40312434 +I6M-9U VI - Moon 7 + Bitumens 0.287618309259 45492 30004933 40312426 40312435 + Coesite 0.300314903259 45493 30004933 40312426 40312435 + Zeolites 0.212066799402 45490 30004933 40312426 40312435 +I6M-9U VI - Moon 8 + Bitumens 0.322282642126 45492 30004933 40312426 40312436 + Coesite 0.280043542385 45493 30004933 40312426 40312436 + Zeolites 0.197673812509 45490 30004933 40312426 40312436 +I6M-9U VI - Moon 9 + Bitumens 0.262956917286 45492 30004933 40312426 40312437 + Sylvite 0.354604274035 45491 30004933 40312426 40312437 + Zeolites 0.182438790798 45490 30004933 40312426 40312437 +I6M-9U VI - Moon 10 + Bitumens 0.542999148369 45492 30004933 40312426 40312438 + Coesite 0.25700083375 45493 30004933 40312426 40312438 +I6M-9U VI - Moon 11 + Bitumens 0.255656480789 45492 30004933 40312426 40312439 + Sylvite 0.544343531132 45491 30004933 40312426 40312439 +I6M-9U VI - Moon 12 + Bitumens 0.286555498838 45492 30004933 40312426 40312440 + Coesite 0.51344448328 45493 30004933 40312426 40312440 +I6M-9U VI - Moon 13 + Bitumens 0.508349776268 45492 30004933 40312426 40312441 + Coesite 0.291650265455 45493 30004933 40312426 40312441 +I6M-9U VI - Moon 14 + Sylvite 0.480567932129 45491 30004933 40312426 40312442 + Zeolites 0.319432079792 45490 30004933 40312426 40312442 +I6M-9U VI - Moon 15 + Sylvite 0.471734672785 45491 30004933 40312426 40312443 + Zeolites 0.328265309334 45490 30004933 40312426 40312443 +I6M-9U VI - Moon 16 + Bitumens 0.272940337658 45492 30004933 40312426 40312444 + Sylvite 0.527059674263 45491 30004933 40312426 40312444 +I6M-9U VI - Moon 17 + Coesite 0.299357324839 45493 30004933 40312426 40312445 + Sylvite 0.182358846068 45491 30004933 40312426 40312445 + Zeolites 0.318283826113 45490 30004933 40312426 40312445 +I6M-9U VI - Moon 18 + Bitumens 0.197065204382 45492 30004933 40312426 40312446 + Cobaltite 0.284012168646 45494 30004933 40312426 40312446 + Coesite 0.274518311024 45493 30004933 40312426 40312446 + Sylvite 0.24440433085 45491 30004933 40312426 40312446 +I6M-9U VI - Moon 19 + Sylvite 0.492273777723 45491 30004933 40312426 40312447 + Zeolites 0.307726234198 45490 30004933 40312426 40312447 +I6M-9U VI - Moon 20 + Bitumens 0.293147861958 45492 30004933 40312426 40312448 + Coesite 0.296043992043 45493 30004933 40312426 40312448 + Zeolites 0.210808172822 45490 30004933 40312426 40312448 +I6M-9U VII - Moon 1 + Bitumens 0.461015105247 45492 30004933 40312449 40312450 + Sylvite 0.338984906673 45491 30004933 40312449 40312450 +I6M-9U VII - Moon 2 + Bitumens 0.291702151299 45492 30004933 40312449 40312451 + Sylvite 0.297842979431 45491 30004933 40312449 40312451 + Zeolites 0.210454896092 45490 30004933 40312449 40312451 +I6M-9U VII - Moon 3 + Coesite 0.528091669083 45493 30004933 40312449 40312452 + Zeolites 0.271908372641 45490 30004933 40312449 40312452 +I6M-9U VII - Moon 4 + Sylvite 0.340775817633 45491 30004933 40312449 40312453 + Zeolites 0.459224194288 45490 30004933 40312449 40312453 +I6M-9U VII - Moon 5 + Sylvite 0.531679213047 45491 30004933 40312449 40312454 + Zeolites 0.268320798874 45490 30004933 40312449 40312454 +I6M-9U VII - Moon 6 + Sylvite 0.561823964119 45491 30004933 40312449 40312455 + Zeolites 0.238176018 45490 30004933 40312449 40312455 +I6M-9U VII - Moon 7 + Coesite 0.192071139812 45493 30004933 40312449 40312456 + Sylvite 0.258129835129 45491 30004933 40312449 40312456 + Zeolites 0.34979903698 45490 30004933 40312449 40312456 +I6M-9U VII - Moon 8 + Bitumens 0.232748419046 45492 30004933 40312449 40312457 + Cobaltite 0.369366496801 45494 30004933 40312449 40312457 + Coesite 0.192948043346 45493 30004933 40312449 40312457 + Zeolites 0.204937040806 45490 30004933 40312449 40312457 +I6M-9U VII - Moon 9 + Bitumens 0.274578362703 45492 30004933 40312449 40312458 + Sylvite 0.334945648909 45491 30004933 40312449 40312458 + Zeolites 0.190475985408 45490 30004933 40312449 40312458 +I6M-9U VII - Moon 10 + Bitumens 0.173574194312 45492 30004933 40312449 40312459 + Sylvite 0.271907269955 45491 30004933 40312449 40312459 + Zeolites 0.354518532753 45490 30004933 40312449 40312459 +I6M-9U VII - Moon 11 + Cobaltite 0.267862796783 45494 30004933 40312449 40312460 + Sylvite 0.209306418896 45491 30004933 40312449 40312460 + Zeolites 0.522830784321 45490 30004933 40312449 40312460 +I6M-9U VII - Moon 12 + Coesite 0.477320879698 45493 30004933 40312449 40312461 + Zeolites 0.322679102421 45490 30004933 40312449 40312461 +I6M-9U VII - Moon 13 + Bitumens 0.492783844471 45492 30004933 40312449 40312462 + Coesite 0.30721616745 45493 30004933 40312449 40312462 +I6M-9U VII - Moon 14 + Bitumens 0.517531573772 45492 30004933 40312449 40312463 + Coesite 0.282468438148 45493 30004933 40312449 40312463 +I6M-9U VII - Moon 15 + Bitumens 0.294936805964 45492 30004933 40312449 40312464 + Coesite 0.323596715927 45493 30004933 40312449 40312464 + Sylvite 0.18146649003 45491 30004933 40312449 40312464 +I6M-9U VII - Moon 16 + Cobaltite 0.331257611513 45494 30004933 40312449 40312465 + Coesite 0.233592525125 45493 30004933 40312449 40312465 + Sylvite 0.435149848461 45491 30004933 40312449 40312465 +I6M-9U VII - Moon 17 + Cobaltite 0.312784314156 45494 30004933 40312449 40312466 + Coesite 0.200858354568 45493 30004933 40312449 40312466 + Zeolites 0.486357331276 45490 30004933 40312449 40312466 +I6M-9U VII - Moon 18 + Bitumens 0.278323143721 45492 30004933 40312449 40312467 + Coesite 0.521676838398 45493 30004933 40312449 40312467 +I6M-9U VII - Moon 19 + Coesite 0.200318723917 45493 30004933 40312449 40312468 + Sylvite 0.31170040369 45491 30004933 40312449 40312468 + Zeolites 0.287980854511 45490 30004933 40312449 40312468 +I6M-9U VII - Moon 20 + Bitumens 0.302821069956 45492 30004933 40312449 40312469 + Coesite 0.322486788034 45493 30004933 40312449 40312469 + Sylvite 0.174692153931 45491 30004933 40312449 40312469 +I6M-9U VII - Moon 21 + Bitumens 0.251974344254 45492 30004933 40312449 40312470 + Sylvite 0.333345204592 45491 30004933 40312449 40312470 + Zeolites 0.214680463076 45490 30004933 40312449 40312470 +I6M-9U VIII - Moon 1 + Sylvite 0.326006114483 45491 30004933 40312471 40312472 + Zeolites 0.473993867636 45490 30004933 40312471 40312472 +I6M-9U VIII - Moon 2 + Bitumens 0.20606893301 45492 30004933 40312471 40312473 + Sylvite 0.311038762331 45491 30004933 40312471 40312473 + Zeolites 0.282892286777 45490 30004933 40312471 40312473 +I6M-9U VIII - Moon 3 + Bitumens 0.189429342747 45492 30004933 40312471 40312474 + Sylvite 0.316842734814 45491 30004933 40312471 40312474 + Zeolites 0.293727904558 45490 30004933 40312471 40312474 +I6M-9U VIII - Moon 4 + Bitumens 0.310227096081 45492 30004933 40312471 40312475 + Coesite 0.263755530119 45493 30004933 40312471 40312475 + Zeolites 0.226017385721 45490 30004933 40312471 40312475 +I6M-9U VIII - Moon 5 + Coesite 0.287107646465 45493 30004933 40312471 40312476 + Sylvite 0.202536776662 45491 30004933 40312471 40312476 + Zeolites 0.310355603695 45490 30004933 40312471 40312476 +I6M-9U VIII - Moon 6 + Bitumens 0.547905266285 45492 30004933 40312471 40312477 + Sylvite 0.252094715834 45491 30004933 40312471 40312477 diff --git a/public/index.php b/public/index.php index 4584cbcd6..9246d02f4 100644 --- a/public/index.php +++ b/public/index.php @@ -8,6 +8,9 @@ */ define('LARAVEL_START', microtime(true)); +if(file_exists(__DIR__.'/../storage/framework/maintenance.php')) { + require __DIR__.'/../storage/framework/maintenance.php'; +} /* |-------------------------------------------------------------------------- diff --git a/vendor/bin/php-parse b/vendor/bin/php-parse new file mode 120000 index 000000000..062d66a3e --- /dev/null +++ b/vendor/bin/php-parse @@ -0,0 +1 @@ +../nikic/php-parser/bin/php-parse \ No newline at end of file diff --git a/vendor/cakephp/chronos/Dockerfile b/vendor/cakephp/chronos/Dockerfile deleted file mode 100644 index 0d8356e6c..000000000 --- a/vendor/cakephp/chronos/Dockerfile +++ /dev/null @@ -1,10 +0,0 @@ -# Basic docker based environment -# Necessary to trick dokku into building the documentation -# using dockerfile instead of herokuish -FROM php:7.3 - -WORKDIR /code - -VOLUME ["/code"] - -CMD [ '/bin/bash' ] diff --git a/vendor/cakephp/chronos/README.md b/vendor/cakephp/chronos/README.md deleted file mode 100644 index 8d3b430ca..000000000 --- a/vendor/cakephp/chronos/README.md +++ /dev/null @@ -1,150 +0,0 @@ -# CakePHP Chronos - -[![Build Status](https://img.shields.io/travis/com/cakephp/chronos/master?style=flat-square)](https://travis-ci.com/cakephp/chronos) -[![Latest Stable Version](https://img.shields.io/github/v/release/cakephp/chronos?sort=semver&style=flat-square)](https://packagist.org/packages/cakephp/chronos) -[![Total Downloads](https://img.shields.io/packagist/dt/cakephp/chronos?style=flat-square)](https://packagist.org/packages/cakephp/chronos/stats) -[![Code Coverage](https://img.shields.io/coveralls/cakephp/chronos/master.svg?style=flat-square)](https://coveralls.io/r/cakephp/chronos?branch=master) -[![Software License](https://img.shields.io/badge/license-MIT-brightgreen.svg?style=flat-square)](LICENSE) - -Chronos aims to be a drop-in replacement for `nesbot/carbon`. It focuses on providing -immutable date/datetime objects. Immutable objects help ensure that datetime objects -aren't accidentally modified keeping data more predictable. - -# Installation - -Installing with composer: - -``` -$ composer require cakephp/chronos -``` - -You can then use Chronos: - -```php -modify('+2 hours'); - -// This will keep modifications -$date = new Chronos('2015-10-21 16:29:00'); -$date = $date->modify('+2 hours'); -``` - -## Getting Mutable Objects - -In the case that you need a mutable instance you can get one: - -```php -$time = new Chronos('2015-10-21 16:29:00'); -$mutable = $time->toMutable(); - -$date = new Date('2015-10-21'); -$mutable = $date->toMutable(); -``` - -## Converting Mutable Objects into Immutable ones. - -If you have a mutable object and want an immutable variant you can do the following: - -```php -$time = new MutableDateTime('2015-10-21 16:29:00'); -$fixed = $time->toImmutable(); - -$date = new MutableDate('2015-10-21'); -$fixed = $date->toImmutable(); -``` - -# Calendar Dates - -PHP only offers datetime objects as part of the native extensions. Chronos adds -a number of conveniences to the traditional DateTime object and introduces -a `Date` object. `Date` instances offer compatibility with the -`ChronosInterface`, but have their time frozen to `00:00:00` and the timezone -set to the server default timezone. This makes them ideal when working with -calendar dates as the time components will always match. - -```php -use Cake\Chronos\Date; - -$today = new Date(); -echo $today; -// Outputs '2015-10-21' - -echo $today->modify('+3 hours'); -// Outputs '2015-10-21' -``` - -Like instances of `Chronos`, `Date` objects are also *immutable*. The -`MutableDate` class provides a mutable variant of `Date`. - -# Documentation - -A more descriptive documentation can be found at [book.cakephp.org/chronos/2/en/](https://book.cakephp.org/chronos/2/en/). - -# API Documentation - -API documentation can be found on [api.cakephp.org/chronos](https://api.cakephp.org/chronos). diff --git a/vendor/cakephp/chronos/composer.json b/vendor/cakephp/chronos/composer.json deleted file mode 100644 index a54ca7d53..000000000 --- a/vendor/cakephp/chronos/composer.json +++ /dev/null @@ -1,63 +0,0 @@ -{ - "name": "cakephp/chronos", - "type": "library", - "description": "A simple API extension for DateTime.", - "keywords": [ - "date", - "time", - "DateTime" - ], - "homepage": "http://cakephp.org", - "license": "MIT", - "authors": [ - { - "name": "Brian Nesbitt", - "email": "brian@nesbot.com", - "homepage": "http://nesbot.com" - }, - { - "name": "The CakePHP Team", - "homepage": "http://cakephp.org" - } - ], - "support": { - "issues": "https://github.com/cakephp/chronos/issues", - "irc": "irc://irc.freenode.org/cakephp", - "source": "https://github.com/cakephp/chronos" - }, - "require": { - "php": ">=7.2" - }, - "require-dev": { - "phpunit/phpunit": "^8.0 || ^9.0", - "cakephp/cakephp-codesniffer": "^4.0" - }, - "autoload": { - "psr-4": { - "Cake\\Chronos\\": "src/" - }, - "files": [ - "src/carbon_compat.php" - ] - }, - "autoload-dev": { - "psr-4": { - "Cake\\Chronos\\Test\\": "tests/" - } - }, - "scripts": { - "check": [ - "@test", - "@cs-check", - "@phpstan" - ], - "cs-check": "phpcs --colors --parallel=16 -p src/ tests/", - "cs-fix": "phpcbf --colors --parallel=16 -p src/ tests/", - "phpstan": "phpstan.phar analyse", - "stan": [ - "@phpstan" - ], - "stan-setup": "cp composer.json composer.backup && composer require --dev phpstan/phpstan:^0.12.54 && mv composer.backup composer.json", - "test": "phpunit" - } -} diff --git a/vendor/cakephp/chronos/docs.Dockerfile b/vendor/cakephp/chronos/docs.Dockerfile deleted file mode 100644 index 3c6a7f509..000000000 --- a/vendor/cakephp/chronos/docs.Dockerfile +++ /dev/null @@ -1,20 +0,0 @@ -# Generate the HTML output. -FROM markstory/cakephp-docs-builder as builder - -RUN pip install git+https://github.com/sphinx-contrib/video.git@master - -COPY docs /data/docs - -# build docs with sphinx -RUN cd /data/docs-builder && \ - make website LANGS="en fr ja pt" SOURCE=/data/docs DEST=/data/website - -# Build a small nginx container with just the static site in it. -FROM nginx:1.15-alpine - -COPY --from=builder /data/website /data/website -COPY --from=builder /data/docs-builder/nginx.conf /etc/nginx/conf.d/default.conf - -# Move docs into place. -RUN cp -R /data/website/html/* /usr/share/nginx/html \ - && rm -rf /data/website diff --git a/vendor/cakephp/chronos/docs/config/__init__.py b/vendor/cakephp/chronos/docs/config/__init__.py deleted file mode 100644 index e69de29bb..000000000 diff --git a/vendor/cakephp/chronos/docs/config/all.py b/vendor/cakephp/chronos/docs/config/all.py deleted file mode 100644 index 4e6a657c6..000000000 --- a/vendor/cakephp/chronos/docs/config/all.py +++ /dev/null @@ -1,49 +0,0 @@ -# Global configuration information used across all the -# translations of documentation. -# -# Import the base theme configuration -from cakephpsphinx.config.all import * - -# The version info for the project you're documenting, acts as replacement for -# |version| and |release|, also used in various other places throughout the -# built documents. -# - -# The full version, including alpha/beta/rc tags. -release = '2.x' - -# The search index version. -search_version = 'chronos-2' - -# The marketing display name for the book. -version_name = '' - -# Project name shown in the black header bar -project = 'Chronos' - -# Other versions that display in the version picker menu. -version_list = [ - {'name': '1.x', 'number': '/chronos/1', 'title': '1.x'}, - {'name': '2.x', 'number': '/chronos/2', 'title': '2.x', 'current': True}, -] - -# Languages available. -languages = ['en', 'fr', 'ja', 'pt'] - -# The GitHub branch name for this version of the docs -# for edit links to point at. -branch = '2.x' - -# Current version being built -version = '2.x' - -# Language in use for this directory. -language = 'en' - -show_root_link = True - -repository = 'cakephp/chronos' - -source_path = 'docs/' - -hide_page_contents = ('search', '404', 'contents') diff --git a/vendor/cakephp/chronos/docs/en/conf.py b/vendor/cakephp/chronos/docs/en/conf.py deleted file mode 100644 index f638bda22..000000000 --- a/vendor/cakephp/chronos/docs/en/conf.py +++ /dev/null @@ -1,9 +0,0 @@ -import sys, os - -# Append the top level directory of the docs, so we can import from the config dir. -sys.path.insert(0, os.path.abspath('..')) - -# Pull in all the configuration options defined in the global config file.. -from config.all import * - -language = 'en' diff --git a/vendor/cakephp/chronos/docs/en/contents.rst b/vendor/cakephp/chronos/docs/en/contents.rst deleted file mode 100644 index 10625a2c6..000000000 --- a/vendor/cakephp/chronos/docs/en/contents.rst +++ /dev/null @@ -1,7 +0,0 @@ -.. toctree:: - :maxdepth: 2 - :caption: CakePHP Chronos - - /index - - API \ No newline at end of file diff --git a/vendor/cakephp/chronos/docs/en/index.rst b/vendor/cakephp/chronos/docs/en/index.rst deleted file mode 100644 index dabb9b267..000000000 --- a/vendor/cakephp/chronos/docs/en/index.rst +++ /dev/null @@ -1,321 +0,0 @@ -Chronos -####### - -Chronos provides a zero-dependency collection of extensions to the ``DateTime`` -object. In addition to convenience methods, Chronos provides: - -* ``Date`` objects for representing calendar dates. -* Immutable date and datetime objects. -* A pluggable translation system. Only English translations are included in the - library. However, ``cakephp/i18n`` can be used for full language support. - -Installation ------------- - -To install Chronos, you should use ``composer``. From your -application's ROOT directory (where composer.json file is located) run the -following:: - - php composer.phar require "cakephp/chronos:^2.0" - -Overview --------- - -Chronos provides a number of extensions to the DateTime objects provided by PHP. -Chronos provides 5 classes that cover mutable and immutable date/time variants -and extensions to ``DateInterval``. - -* ``Cake\Chronos\Chronos`` is an immutable *date and time* object. -* ``Cake\Chronos\Date`` is a immutable *date* object. -* ``Cake\Chronos\MutableDateTime`` is a mutable *date and time* object. -* ``Cake\Chronos\MutableDate`` is a mutable *date* object. -* ``Cake\Chronos\ChronosInterval`` is an extension to the ``DateInterval`` - object. - -Lastly, if you want to typehint against Chronos-provided date/time objects you -should use ``Cake\Chronos\ChronosInterface``. All of the date and time objects -implement this interface. - -Creating Instances ------------------- - -There are many ways to get an instance of Chronos or Date. There are a number of -factory methods that work with different argument sets:: - - use Cake\Chronos\Chronos; - - $now = Chronos::now(); - $today = Chronos::today(); - $yesterday = Chronos::yesterday(); - $tomorrow = Chronos::tomorrow(); - - // Parse relative expressions - $date = Chronos::parse('+2 days, +3 hours'); - - // Date and time integer values. - $date = Chronos::create(2015, 12, 25, 4, 32, 58); - - // Date or time integer values. - $date = Chronos::createFromDate(2015, 12, 25); - $date = Chronos::createFromTime(11, 45, 10); - - // Parse formatted values. - $date = Chronos::createFromFormat('m/d/Y', '06/15/2015'); - -Working with Immutable Objects ------------------------------- - -If you've used PHP's ``DateTime`` objects, you're comfortable with *mutable* -objects. Chronos offers mutable objects, but it also provides *immutable* -objects. Immutable objects create copies of objects each time an object is -modified. Because modifier methods around datetimes are not always transparent, -data can be modified accidentally or without the developer knowing. -Immutable objects prevent accidental changes to -data, and make code free of order-based dependency issues. Immutability -does mean that you will need to remember to replace variables when using -modifiers:: - - // This code doesn't work with immutable objects - $time->addDay(1); - doSomething($time); - return $time; - - // This works like you'd expect - $time = $time->addDay(1); - $time = doSomething($time); - return $time; - -By capturing the return value of each modification your code will work as -expected. If you ever have an immutable object, and want to create a mutable -one, you can use ``toMutable()``:: - - $inplace = $time->toMutable(); - -Date Objects ------------- - -PHP only provides a single DateTime object. Representing calendar dates can be -a bit awkward with this class as it includes timezones, and time components that -don't really belong in the concept of a 'day'. Chronos provides a ``Date`` -object that allows you to represent dates. The time and timezone for these -objects is always fixed to ``00:00:00 UTC`` and all formatting/difference -methods operate at the day resolution:: - - use Cake\Chronos\Date; - - $today = Date::today(); - - // Changes to the time/timezone are ignored. - $today->modify('+1 hours'); - - // Outputs '2015-12-20' - echo $today; - -Although ``Date`` uses a fixed time zone internally, you can specify which -time zone to use for current time such as ``now()`` or ``today()``:: - - use Cake\Chronos\Date: - - // Takes the current date from Asia/Tokyo time zone - $today = Date::today('Asia/Tokyo'); - -Modifier Methods ----------------- - -Chronos objects provide modifier methods that let you modify the value in -a granular way:: - - // Set components of the datetime value. - $halloween = Chronos::create() - ->year(2015) - ->month(10) - ->day(31) - ->hour(20) - ->minute(30); - -You can also modify parts of the datetime relatively:: - - $future = Chronos::create() - ->addYear(1) - ->subMonth(2) - ->addDays(15) - ->addHours(20) - ->subMinutes(2); - -It is also possible to make big jumps to defined points in time:: - - $time = Chronos::create(); - $time->startOfDay(); - $time->endOfDay(); - $time->startOfMonth(); - $time->endOfMonth(); - $time->startOfYear(); - $time->endOfYear(); - $time->startOfWeek(); - $time->endOfWeek(); - -Or jump to specific days of the week:: - - $time->next(ChronosInterface::TUESDAY); - $time->previous(ChronosInterface::MONDAY); - -When modifying dates/times across :abbr:`DST (Daylight Savings Time)` transitions -your operations may gain/lose an additional hours resulting in hour values that -don't add up. You can avoid these issues by first changing your timezone to -``UTC``, modifying the time:: - - // Additional hour gained. - $time = new Chronos('2014-03-30 00:00:00', 'Europe/London'); - debug($time->modify('+24 hours')); // 2014-03-31 01:00:00 - - // First switch to UTC, and modify - $time = $time->setTimezone('UTC') - ->modify('+24 hours'); - -Once you are done modifying the time you can add the original timezone to get -the localized time. - -Comparison Methods ------------------- - -Once you have 2 instances of Chronos date/time objects you can compare them in -a variety of ways:: - - // Full suite of comparators exist - // ne, gt, lt, lte. - $first->eq($second); - $first->gte($second); - - // See if the current object is between two others. - $now->between($start, $end); - - // Find which argument is closest or farthest. - $now->closest($june, $november); - $now->farthest($june, $november); - -You can also inquire about where a given value falls on the calendar:: - - $now->isToday(); - $now->isYesterday(); - $now->isFuture(); - $now->isPast(); - - // Check the day of the week - $now->isWeekend(); - - // All other weekday methods exist too. - $now->isMonday(); - -You can also find out if a value was within a relative time period:: - - $time->wasWithinLast('3 days'); - $time->isWithinNext('3 hours'); - -Generating Differences ----------------------- - -In addition to comparing datetimes, calculating differences or deltas between -two values is a common task:: - - // Get a DateInterval representing the difference - $first->diff($second); - - // Get difference as a count of specific units. - $first->diffInHours($second); - $first->diffInDays($second); - $first->diffInWeeks($second); - $first->diffInYears($second); - -You can generate human readable differences suitable for use in a feed or -timeline:: - - // Difference from now. - echo $date->diffForHumans(); - - // Difference from another point in time. - echo $date->diffForHumans($other); // 1 hour ago; - -Formatting Strings ------------------- - -Chronos provides a number of methods for displaying our outputting datetime -objects:: - - // Uses the format controlled by setToStringFormat() - echo $date; - - // Different standard formats - echo $time->toAtomString(); // 1975-12-25T14:15:16-05:00 - echo $time->toCookieString(); // Thursday, 25-Dec-1975 14:15:16 EST - echo $time->toIso8601String(); // 1975-12-25T14:15:16-05:00 - echo $time->toRfc822String(); // Thu, 25 Dec 75 14:15:16 -0500 - echo $time->toRfc850String(); // Thursday, 25-Dec-75 14:15:16 EST - echo $time->toRfc1036String(); // Thu, 25 Dec 75 14:15:16 -0500 - echo $time->toRfc1123String(); // Thu, 25 Dec 1975 14:15:16 -0500 - echo $time->toRfc2822String(); // Thu, 25 Dec 1975 14:15:16 -0500 - echo $time->toRfc3339String(); // 1975-12-25T14:15:16-05:00 - echo $time->toRssString(); // Thu, 25 Dec 1975 14:15:16 -0500 - echo $time->toW3cString(); // 1975-12-25T14:15:16-05:00 - - // Get the quarter/week - echo $time->toQuarter(); // 4 - echo $time->toWeek(); // 52 - - // Generic formatting - echo $time->toTimeString(); // 14:15:16 - echo $time->toDateString(); // 1975-12-25 - echo $time->toDateTimeString(); // 1975-12-25 14:15:16 - echo $time->toFormattedDateString(); // Dec 25, 1975 - echo $time->toDayDateTimeString(); // Thu, Dec 25, 1975 2:15 PM - -Extracting Date Components --------------------------- - -Getting parts of a date object can be done by directly accessing properties:: - - $time = new Chronos('2015-12-31 23:59:58.123'); - $time->year; // 2015 - $time->month; // 12 - $time->day; // 31 - $time->hour // 23 - $time->minute // 59 - $time->second // 58 - $time->micro // 123 - -Other properties that can be accessed are: - -- timezone -- timezoneName -- dayOfWeek -- dayOfMonth -- dayOfYear -- daysInMonth -- timestamp -- quarter - -Testing Aids ------------- - -When writing unit tests, it is helpful to fixate the current time. Chronos lets -you fix the current time for each class. As part of your test suite's bootstrap -process you can include the following:: - - Chronos::setTestNow(Chronos::now()); - MutableDateTime::setTestNow(MutableDateTime::now()); - Date::setTestNow(Date::now()); - MutableDate::setTestNow(MutableDate::now()); - -This will fix the current time of all objects to be the point at which the test -suite started. - -For example, if you fixate the ``Chronos`` to some moment in the past, any new -instance of ``Chronos`` created with ``now`` or a relative time string, will be -returned relative to the fixated time:: - - Chronos::setTestNow(new Chronos('1975-12-25 00:00:00')); - - $time = new Chronos(); // 1975-12-25 00:00:00 - $time = new Chronos('1 hour ago'); // 1975-12-24 23:00:00 - -To reset the fixation, simply call ``setTestNow()`` again with no parameter or -with ``null`` as a parameter. diff --git a/vendor/cakephp/chronos/docs/fr/conf.py b/vendor/cakephp/chronos/docs/fr/conf.py deleted file mode 100644 index b02032efa..000000000 --- a/vendor/cakephp/chronos/docs/fr/conf.py +++ /dev/null @@ -1,9 +0,0 @@ -import sys, os - -# Append the top level directory of the docs, so we can import from the config dir. -sys.path.insert(0, os.path.abspath('..')) - -# Pull in all the configuration options defined in the global config file.. -from config.all import * - -language = 'fr' diff --git a/vendor/cakephp/chronos/docs/fr/contents.rst b/vendor/cakephp/chronos/docs/fr/contents.rst deleted file mode 100644 index 10625a2c6..000000000 --- a/vendor/cakephp/chronos/docs/fr/contents.rst +++ /dev/null @@ -1,7 +0,0 @@ -.. toctree:: - :maxdepth: 2 - :caption: CakePHP Chronos - - /index - - API \ No newline at end of file diff --git a/vendor/cakephp/chronos/docs/fr/index.rst b/vendor/cakephp/chronos/docs/fr/index.rst deleted file mode 100644 index f313d8b97..000000000 --- a/vendor/cakephp/chronos/docs/fr/index.rst +++ /dev/null @@ -1,306 +0,0 @@ -Chronos -####### - -Chronos fournit une collection d'extensions sans aucune dépendance pour l'objet -``DateTime``. En plus de méthodes pratiques, Chronos fournit: - -* Des objets ``Date`` pour représenter les dates du calendrier. -* Des objets immutables pour les dates et les datetimes. -* Un système de traduction intégrable. Seules les traductions anglaises sont - inclues dans la librairie. Cependant, ``cakephp/i18n`` peut être utilisé - pour un support complet d'autres langues. - -Installation ------------- - -Pour installer Chronos, vous devez utiliser ``composer``. A partir du répertoire -ROOT de votre application (où le fichier composer.json se trouve) exécutez ce -qui suit:: - - php composer.phar require cakephp/chronos "@stable" - -Vue d'Ensemble --------------- - -Chronos fournit un certain nombre d'extensions pour les objets DateTime fournis -par PHP. Chronos fournit 5 classes qui gèrent les variantes mutables et -immutables de date/time et les extensions de ``DateInterval``. - -* ``Cake\Chronos\Chronos`` est un objet de *date et time* immutable. -* ``Cake\Chronos\Date`` est un objet de *date* immutable. -* ``Cake\Chronos\MutableDateTime`` est un objet de *date et time* mutable. -* ``Cake\Chronos\MutableDate`` est un objet de *date* mutable. -* ``Cake\Chronos\ChronosInterval`` est une extension pour l'objet - ``DateInterval``. - -Enfin si vous voulez typer selon les objets date/time fournis par Chronos, -vous devez utiliser ``Cake\Chronos\ChronosInterface``. Tous les objets date et -time implémentent cette interface. - -Créer des Instances -------------------- - -Il y a plusieurs façons d'obtenir une instance de Chronos ou de Date. Il y a -un certain nombre de méthodes factory qui fonctionnent avec des ensembles -ayant des arguments différents:: - - use Cake\Chronos\Chronos; - - $now = Chronos::now(); - $today = Chronos::today(); - $yesterday = Chronos::yesterday(); - $tomorrow = Chronos::tomorrow(); - - // Parse les expressions relatives - $date = Chronos::parse('+2 days, +3 hours'); - - // Les valeurs d'entier de Date et time. - $date = Chronos::create(2015, 12, 25, 4, 32, 58); - - // Les valeurs d'entier pour Date ou time. - $date = Chronos::createFromDate(2015, 12, 25); - $date = Chronos::createFromTime(11, 45, 10); - - // Parse les valeurs formatées. - $date = Chronos::createFromFormat('m/d/Y', '06/15/2015'); - -Travailler avec les Objets Immutables -------------------------------------- - -Si vous avez utilisé les objets ``DateTime`` de PHP, vous êtes à l'aise avec -les objets *mutable*. Chronos offre des objets mutables, mais elle fournit -également des objets *immutables*. Les objets Immutables créent des copies des -objets à chaque fois qu'un objet est modifié. Puisque les méthodes de -modification autour des datetimes ne sont pas toujours transparentes, les -données peuvent être modifiées accidentellement ou sans que le développeur ne -le sache. Les objets immutables évitent les changements accidentels des -données et permettent de s'affranchir de tout problème lié à l'ordre d'appel -des fonctions ou des dépendances. L'immutabilité signifie que vous devez vous -souvenir de remplacer les variables quand vous utilisez les modificateurs:: - - // Ce code ne fonctionne pas avec les objets immutables - $time->addDay(1); - doSomething($time); - return $time; - - // Ceci fonctionne comme vous le souhaitez - $time = $time->addDay(1); - $time = doSomething($time); - return $time; - -En capturant la valeur de retour pour chaque modification, votre code -fonctionnera comme souhaité. Si vous avez déjà créé un objet immutable, et que -vous souhaitez un objet mutable, vous pouvez utiliser ``toMutable()``:: - - $inplace = $time->toMutable(); - -Objets Date ------------ - -PHP fournit seulement un unique objet DateTime. Représenter les dates de -calendrier peut être un peu gênant avec cette classe puisqu'elle inclut les -timezones, et les composants de time qui n'appartiennent pas vraiment -dans le concept d'un 'jour'. Chronos fournit un objet ``Date`` qui vous permet -de représenter les dates. Les time et timezone pour ces objets sont toujours -fixés à ``00:00:00 UTC`` et toutes les méthodes de formatage/différence -fonctionnent au niveau du jour:: - - use Cake\Chronos\Date; - - $today = Date::today(); - - // Changements selon le time/timezone sont ignorés. - $today->modify('+1 hours'); - - // Affiche '2015-12-20' - echo $today; - -Méthodes de Modification ------------------------- - -Les objets Chronos fournissent des méthodes de modification qui vous laissent -modifier la valeur d'une façon assez précise:: - - // Définit les composants de la valeur du datetime. - $halloween = Chronos::create() - ->year(2015) - ->month(10) - ->day(31) - ->hour(20) - ->minute(30); - -Vous pouvez aussi modifier les parties de la date de façon relative:: - - $future = Chronos::create() - ->addYear(1) - ->subMonth(2) - ->addDays(15) - ->addHours(20) - ->subMinutes(2); - -Il est également possible de faire des sauts vers des points définis dans le -temps:: - - $time = Chronos::create(); - $time->startOfDay(); - $time->endOfDay(); - $time->startOfMonth(); - $time->endOfMonth(); - $time->startOfYear(); - $time->endOfYear(); - $time->startOfWeek(); - $time->endOfWeek(); - -Ou de sauter à un jour spécifique de la semaine:: - - $time->next(ChronosInterface::TUESDAY); - $time->previous(ChronosInterface::MONDAY); - -Méthodes de Comparaison ------------------------ - -Une fois que vous avez 2 instances d'objets date/time de Chronos, vous pouvez -les comparer de plusieurs façons:: - - // Suite complète de comparateurs existante - // ne, gt, lt, lte. - $first->eq($second); - $first->gte($second); - - // Regardez si l'objet courant est entre deux autres. - $now->between($start, $end); - - // Trouver l'argument le plus proche ou le plus éloigné. - $now->closest($june, $november); - $now->farthest($june, $november); - -Vous pouvez aussi vous renseigner sur le moment où une valeur donnée tombe dans -le calendrier:: - - $now->isToday(); - $now->isYesterday(); - $now->isFuture(); - $now->isPast(); - - // Vérifie le jour de la semaine - $now->isWeekend(); - - // Toutes les autres méthodes des jours de la semaine existent aussi. - $now->isMonday(); - -Vous pouvez aussi trouver si une valeur était dans une période de temps relative:: - - $time->wasWithinLast('3 days'); - $time->isWithinNext('3 hours'); - -Générer des Différences ------------------------ - -En plus de comparer les datetimes, calculer les différences ou les deltas entre -des valeurs est une tâche courante:: - - // Récupère un DateInterval représentant la différence - $first->diff($second); - - // Récupère la différence en tant que nombre d'unités spécifiques. - $first->diffInHours($second); - $first->diffInDays($second); - $first->diffInWeeks($second); - $first->diffInYears($second); - -Vous pouvez générer des différences lisibles qui peuvent vous servir pour -l'utilisation d'un feed ou d'une timeline:: - - // Différence à partir de maintenant. - echo $date->diffForHumans(); - - // Différence à partir d'un autre point du temps. - echo $date->diffForHumans($other); // 1 hour ago; - -Formater les Chaînes --------------------- - -Chronos fournit un certain nombre de méthodes pour afficher nos sorties d'objets -datetime:: - - // Utilise le format contrôlé par setToStringFormat() - echo $date; - - // Différents formats standards - echo $time->toAtomString(); // 1975-12-25T14:15:16-05:00 - echo $time->toCookieString(); // Thursday, 25-Dec-1975 14:15:16 EST - echo $time->toIso8601String(); // 1975-12-25T14:15:16-05:00 - echo $time->toRfc822String(); // Thu, 25 Dec 75 14:15:16 -0500 - echo $time->toRfc850String(); // Thursday, 25-Dec-75 14:15:16 EST - echo $time->toRfc1036String(); // Thu, 25 Dec 75 14:15:16 -0500 - echo $time->toRfc1123String(); // Thu, 25 Dec 1975 14:15:16 -0500 - echo $time->toRfc2822String(); // Thu, 25 Dec 1975 14:15:16 -0500 - echo $time->toRfc3339String(); // 1975-12-25T14:15:16-05:00 - echo $time->toRssString(); // Thu, 25 Dec 1975 14:15:16 -0500 - echo $time->toW3cString(); // 1975-12-25T14:15:16-05:00 - - // Récupère le trimestre - echo $time->toQuarter(); // 4; - // Récupère la semaine - echo $time->toWeek(); // 52; - - // Formatage générique - echo $time->toTimeString(); // 14:15:16 - echo $time->toDateString(); // 1975-12-25 - echo $time->toDateTimeString(); // 1975-12-25 14:15:16 - echo $time->toFormattedDateString(); // Dec 25, 1975 - echo $time->toDayDateTimeString(); // Thu, Dec 25, 1975 2:15 PM - -Extraire des Fragments de Date ------------------------------- - -Il est possible de récupérer des parties d'un objet date en accédant directement -à ses propriétés:: - - $time = new Chronos('2015-12-31 23:59:58'); - $time->year; // 2015 - $time->month; // 12 - $time->day; // 31 - $time->hour // 23 - $time->minute // 59 - $time->second // 58 - -Les autres propriétés accessibles sont: - -- timezone -- timezoneName -- micro -- dayOfWeek -- dayOfMonth -- dayOfYear -- daysInMonth -- timestamp -- quarter - -Aides aux Tests ---------------- - -Quand vous écrivez des tests unitaires, il peut être utile de fixer le *time* -courant. Chronos vous permet de fixer le time courant pour chaque classe. -Pour l'intégrer dans votre processus de démarrage (bootstrap) de suite de tests, -vous pouvez inclure ce qui suit:: - - Chronos::setTestNow(Chronos::now()); - MutableDateTime::setTestNow(MutableDateTime::now()); - Date::setTestNow(Date::now()); - MutableDate::setTestNow(MutableDate::now()); - -Ceci va fixer le time courant de tous les objets selon le moment où la suite de -tests a démarré. - -Par exemple, si vous fixez le ``Chronos`` à un moment du passé, chaque nouvelle -instance de ``Chronos`` créée avec ``now`` ou une chaine de temps relative, sera -retournée relativement à la date fixée:: - - Chronos::setTestNow(new Chronos('1975-12-25 00:00:00')); - - $time = new Chronos(); // 1975-12-25 00:00:00 - $time = new Chronos('1 hour ago'); // 1975-12-24 23:00:00 - -Pour réinitialiser la "fixation" du temps, appelez simplement ``setTestNow()`` -sans paramètre ou avec ``null`` comme paramètre. diff --git a/vendor/cakephp/chronos/docs/ja/conf.py b/vendor/cakephp/chronos/docs/ja/conf.py deleted file mode 100644 index 5871da648..000000000 --- a/vendor/cakephp/chronos/docs/ja/conf.py +++ /dev/null @@ -1,9 +0,0 @@ -import sys, os - -# Append the top level directory of the docs, so we can import from the config dir. -sys.path.insert(0, os.path.abspath('..')) - -# Pull in all the configuration options defined in the global config file.. -from config.all import * - -language = 'ja' diff --git a/vendor/cakephp/chronos/docs/ja/contents.rst b/vendor/cakephp/chronos/docs/ja/contents.rst deleted file mode 100644 index 10625a2c6..000000000 --- a/vendor/cakephp/chronos/docs/ja/contents.rst +++ /dev/null @@ -1,7 +0,0 @@ -.. toctree:: - :maxdepth: 2 - :caption: CakePHP Chronos - - /index - - API \ No newline at end of file diff --git a/vendor/cakephp/chronos/docs/ja/index.rst b/vendor/cakephp/chronos/docs/ja/index.rst deleted file mode 100644 index 9e1db71d0..000000000 --- a/vendor/cakephp/chronos/docs/ja/index.rst +++ /dev/null @@ -1,304 +0,0 @@ -Chronos -####### - -Chronos (クロノス) は、 ``DateTime`` オブジェクトへの拡張の依存関係の無いコレクションを提供します。 -便利なメソッドに加えて、Chronos は以下を提供します。 - -* カレンダー日付のための ``Date`` オブジェクト -* イミュータブルな日付と日時オブジェクト -* プラグインのような翻訳システム。ライブラリーは英語のみの翻訳を含んでいます。 - しかし、全ての言語サポートのために、 ``cakephp/i18n`` を使うことができます。 - -インストール ------------- - -Chronos をインストールするためには、 ``composer`` を利用することができます。 -アプリケーションの ROOT ディレクトリー(composer.json ファイルのある場所) -で以下のように実行します。 :: - - php composer.phar require cakephp/chronos "@stable" - -概要 ----- - -Chronos は PHP が提供する DateTime オブジェクトのいくつかの拡張を提供します。 -Chronos は ``DateInterval`` の拡張機能および、ミュータブル(変更可能)と -イミュータブル(変更不可)な 日付/時刻 の派生系をカバーする5つのクラスを提供します。 - -* ``Cake\Chronos\Chronos`` はイミュータブルな *日付と時刻* オブジェクト。 -* ``Cake\Chronos\Date`` はイミュータブルな *日付* オブジェクト。 -* ``Cake\Chronos\MutableDateTime`` はミュータブルな *日付と時刻* オブジェクト。 -* ``Cake\Chronos\MutableDate`` はミュータブルな *日付* オブジェクト。 -* ``Cake\Chronos\ChronosInterval`` は ``DateInterval`` の拡張機能。 - -最後に、もしあなたが Chronos が提供する 日付/時刻 のオブジェクトに対して型宣言を行ないたい場合、 -``Cake\Chronos\ChronosInterface`` を使用することができます。 -全ての日付と時間のオブジェクトはこのインターフェイスを実装しています。 - -インスタンスの作成 ------------------- - -Chronos または Date のインスタンスを取得するためには、多くの方法があります。 -異なる引数セットで動作する多くのファクトリーメソッドがあります。 :: - - use Cake\Chronos\Chronos; - - $now = Chronos::now(); - $today = Chronos::today(); - $yesterday = Chronos::yesterday(); - $tomorrow = Chronos::tomorrow(); - - // 相対式のパース - $date = Chronos::parse('+2 days, +3 hours'); - - // 日付と時間の整数値 - $date = Chronos::create(2015, 12, 25, 4, 32, 58); - - // 日付または時間の整数値 - $date = Chronos::createFromDate(2015, 12, 25); - $date = Chronos::createFromTime(11, 45, 10); - - // 整形した値にパース - $date = Chronos::createFromFormat('m/d/Y', '06/15/2015'); - -イミュータブルオブジェクトの動作 --------------------------------- - -もしあなたが、PHP の ``DateTime`` オブジェクトを使用したことがあるなら、 -*ミュータブル* オブジェクトは簡単に使用できます。 -Chronos はミュータブルオブジェクトを提供しますが、これは *イミュータブル* オブジェクトにもなります。 -イミュータブルオブジェクトはオブジェクトが変更されるたびにオブジェクトのコピーを作ります。 -なぜなら、日時周りの変更メソッドは必ずしも透明でないため、データが誤って、 -または開発者が知らない内に変更してしまうからです。 -イミュータブルオブジェクトはデータが誤って変更されることを防止し、 -順序ベースの依存関係の問題の無いコードを作ります。 -不変性は、変更時に忘れずに変数を置き換える必要があることを意味しています。 :: - - // このコードはイミュータブルオブジェクトでは動作しません - $time->addDay(1); - doSomething($time); - return $time - - // このコードは期待通りに動作します - $time = $time->addDay(1); - $time = doSomething($time); - return $time - -各修正の戻り値をキャプチャーすることによって、コードは期待通りに動作します。 -イミュータブルオブジェクトを持っていて、ミュータブルオブジェクトを作りたい場合、 -``toMutable()`` が使用できます。 :: - - $inplace = $time->toMutable(); - -日付オブジェクト ------------------- - -PHP は単純な DateTime オブジェクトだけを提供します。このクラスのカレンダー日付の表現で、 -タイムゾーンおよび、本当に「日」の概念に属していないタイムコンポーネントを含むと、 -少し厄介な可能性があります。 -Chronos は日時表現のための ``Date`` オブジェクトを提供します。 -これらのオブジェクトの時間とタイムゾーンは常に ``00:00:00 UTC`` に固定されており、 -全ての書式/差分のメソッドは一日単位で動作します。 :: - - use Cake\Chronos\Date; - - $today = Date::today(); - - // 時間/タイムゾーンの変更は無視されます - $today->modify('+1 hours'); - - // 出力 '2015-12-20' - echo $today; - -変更メソッド ------------- - -Chronos オブジェクトは細やかに値を変更できるメソッドを提供します。 :: - - // 日時の値のコンポーネントを設定 - $halloween = Chronos::create() - ->year(2015) - ->month(10) - ->day(31) - ->hour(20) - ->minute(30); - -また、日時の部分を相対的に変更することもできます。 :: - - $future = Chronos::create() - ->addYear(1) - ->subMonth(2) - ->addDays(15) - ->addHours(20) - ->subMinutes(2); - -また、ある時間の中で、定義された時点に飛ぶことも可能です。 :: - - $time = Chronos::create(); - $time->startOfDay(); - $time->endOfDay(); - $time->startOfMonth(); - $time->endOfMonth(); - $time->startOfYear(); - $time->endOfYear(); - $time->startOfWeek(); - $time->endOfWeek(); - -また、1週間中の特定の日にも飛べます。 :: - - $time->next(ChronosInterface::TUESDAY); - $time->previous(ChronosInterface::MONDAY); - -:abbr:`DST (夏時間)` の遷移の前後で日付/時間を変更すると、 -あなたの操作で時間が増減するかもしれませんが、その結果、意図しない時間の値になります。 -これらの問題を回避するには、最初にタイムゾーンを ``UTC`` に変更し、時間を変更します。 :: - - // 余分な時間が追加されました - $time = new Chronos('2014-03-30 00:00:00', 'Europe/London'); - debug($time->modify('+24 hours')); // 2014-03-31 01:00:00 - - // 最初に UTC に切り替え、そして更新 - $time = $time->setTimezone('UTC') - ->modify('+24 hours'); - -時間を変更すると、元のタイムゾーンを追加してローカライズされた時間を取得することができます。 - -比較メソッド ------------- - -Chronos の日付/時間オブジェクトの2つのインスタンスを様々な方法で比較することができます。 :: - - // 比較のフルセットが存在します - // ne, gt, lt, lte. - $first->eq($second); - $first->gte($second); - - // カレントオブジェクトが2つのオブジェクトの間にあるかどうかを確認します。 - $now->between($start, $end); - - // どちらの引数が最も近い (closest) か、または最も遠い (farthest) かを見つけます。 - $now->closest($june, $november); - $now->farthest($june, $november); - -また、与えられた値のカレンダーに当たる場所について問い合わせできます。 :: - - $now->isToday(); - $now->isYesterday(); - $now->isFuture(); - $now->isPast(); - - // 曜日をチェック - $now->isWeekend(); - - // 他の曜日のメソッドも全て存在します。 - $now->isMonday(); - -また、値が相対的な期間内にあったかどうかを見つけることができます。 :: - - $time->wasWithinLast('3 days'); - $time->isWithinNext('3 hours'); - -差の生成 --------- - -日時比較に加えて、2つの値の差や変化の計算は一般的なタスクです。 :: - - // 差をあらわす DateInterval を取得 - $first->diff($second); - - // 特定の単位での差を取得 - $first->diffInHours($second); - $first->diffInDays($second); - $first->diffInWeeks($second); - $first->diffInYears($second); - -フィードやタイムラインで使用するのに適した、人が読める形式の差を生成することができます。 :: - - // 現在からの差 - echo $date->diffForHumans(); - - // 別の時点からの差 - echo $date->diffForHumans($other); // 1時間前; - -フォーマットの設定 ------------------- - -Chronos は、出力した日時オブジェクトを表示するための多くのメソッドを提供します。 :: - - // setToStringFormat() が制御するフォーマットを使用します - echo $date; - - // 別の標準フォーマット - echo $time->toAtomString(); // 1975-12-25T14:15:16-05:00 - echo $time->toCookieString(); // Thursday, 25-Dec-1975 14:15:16 EST - echo $time->toIso8601String(); // 1975-12-25T14:15:16-05:00 - echo $time->toRfc822String(); // Thu, 25 Dec 75 14:15:16 -0500 - echo $time->toRfc850String(); // Thursday, 25-Dec-75 14:15:16 EST - echo $time->toRfc1036String(); // Thu, 25 Dec 75 14:15:16 -0500 - echo $time->toRfc1123String(); // Thu, 25 Dec 1975 14:15:16 -0500 - echo $time->toRfc2822String(); // Thu, 25 Dec 1975 14:15:16 -0500 - echo $time->toRfc3339String(); // 1975-12-25T14:15:16-05:00 - echo $time->toRssString(); // Thu, 25 Dec 1975 14:15:16 -0500 - echo $time->toW3cString(); // 1975-12-25T14:15:16-05:00 - - // クォーター/週数を取得 - echo $time->toQuarter(); // 4; - echo $time->toWeek(); // 52 - - // 一般的なフォーマット - echo $time->toTimeString(); // 14:15:16 - echo $time->toDateString(); // 1975-12-25 - echo $time->toDateTimeString(); // 1975-12-25 14:15:16 - echo $time->toFormattedDateString(); // Dec 25, 1975 - echo $time->toDayDateTimeString(); // Thu, Dec 25, 1975 2:15 PM - -日付要素の抽出 --------------- - -日付オブジェクトのプロパティーに直接アクセスして要素を取得することができます。 :: - - $time = new Chronos('2015-12-31 23:59:58'); - $time->year; // 2015 - $time->month; // 12 - $time->day; // 31 - $time->hour // 23 - $time->minute // 59 - $time->second // 58 - -以下のプロパティーにもアクセスできます。 : - -- timezone -- timezoneName -- micro -- dayOfWeek -- dayOfMonth -- dayOfYear -- daysInMonth -- timestamp -- quarter - -テストの支援 ------------- - -単体テストを書いている時、現在時刻を固定すると便利です。Chronos は、 -各クラスの現在時刻を修正することができます。 -テストスイートの bootstrap 処理に以下を含めることができます。 :: - - Chronos::setTestNow(Chronos::now()); - MutableDateTime::setTestNow(MutableDateTime::now()); - Date::setTestNow(Date::now()); - MutableDate::setTestNow(MutableDate::now()); - -これでテストスイートが開始された時点で全てのオブジェクトの現在時刻を修正します。 - -例えば、 ``Chronos`` を過去のある瞬間に固定した場合、新たな ``Chronos`` -のインスタンスが生成する ``now`` または相対時刻の文字列は、 -固定された時刻の相対を返却します。 :: - - Chronos::setTestNow(new Chronos('1975-12-25 00:00:00')); - - $time = new Chronos(); // 1975-12-25 00:00:00 - $time = new Chronos('1 hour ago'); // 1975-12-24 23:00:00 - -固定をリセットするには、 ``setTestNow()`` をパラメーター無し、または ``null`` を設定して -再び呼び出してください。 diff --git a/vendor/cakephp/chronos/docs/pt/conf.py b/vendor/cakephp/chronos/docs/pt/conf.py deleted file mode 100644 index 9e22cb017..000000000 --- a/vendor/cakephp/chronos/docs/pt/conf.py +++ /dev/null @@ -1,9 +0,0 @@ -import sys, os - -# Append the top level directory of the docs, so we can import from the config dir. -sys.path.insert(0, os.path.abspath('..')) - -# Pull in all the configuration options defined in the global config file.. -from config.all import * - -language = 'pt' diff --git a/vendor/cakephp/chronos/docs/pt/contents.rst b/vendor/cakephp/chronos/docs/pt/contents.rst deleted file mode 100644 index 10625a2c6..000000000 --- a/vendor/cakephp/chronos/docs/pt/contents.rst +++ /dev/null @@ -1,7 +0,0 @@ -.. toctree:: - :maxdepth: 2 - :caption: CakePHP Chronos - - /index - - API \ No newline at end of file diff --git a/vendor/cakephp/chronos/docs/pt/index.rst b/vendor/cakephp/chronos/docs/pt/index.rst deleted file mode 100644 index d4a90af83..000000000 --- a/vendor/cakephp/chronos/docs/pt/index.rst +++ /dev/null @@ -1,285 +0,0 @@ -Chronos -####### - -O Chronos oferece uma coleção independente de extensões para lidar com o objeto -``DateTime``. Além de métodos de conveniência, o Chronos oferece: - -* Objetos ``Date`` para representar datas de calendário. -* Objetos *date* e *datetime* imutáveis. -* Um sistema de tradução acoplável. Apenas traduções em inglês estão incluídas - na biblioteca. Todavia, ``cakephp/i18n`` pode ser usado para suporte completo - a idiomas. - -Instalação ----------- - -Para instalar o Chronos, você deve usar o ``composer``. A partir do diretório -*ROOT* de sua aplicação (local onde o arquivo composer.json está localizado) -execute o seguinte comando:: - - php composer.phar require cakephp/chronos "@stable" - -Visão geral ------------ - -Chronos oferece extensões para lidar com objetos *DateTime* do PHP. 5 classes -cobrem variantes de data/hora mutáveis e imutáveis e uma extensão do objeto -``DateInterval``. - -* ``Cake\Chronos\Chronos`` é um objeto *date & time* imutável. -* ``Cake\Chronos\Date`` é um objeto *date* imutável. -* ``Cake\Chronos\MutableDateTime`` é um objeto *date and time* mutável. -* ``Cake\Chronos\MutableDate`` é um objeto *date* mutável. -* ``Cake\Chronos\ChronosInterval`` é uma extensão do objeto ``DateInterval``. - -Por último, se você quiser usar o *typehint* em objetos do Chronos, será preciso -usar a interface ``Cake\Chronos\ChronosInterface``. Todos os objetos de data e -hora implementam essa interface. - -Criando instâncias ------------------- - -Existem várias maneiras de criar instâncias do Chronos ou mesmo, do objeto Date. -Um número considerável de métodos padrão que funcionam com conjuntos diferentes -de argumentos:: - - use Cake\Chronos\Chronos; - - $now = Chronos::now(); - $today = Chronos::today(); - $yesterday = Chronos::yesterday(); - $tomorrow = Chronos::tomorrow(); - - // Interpreta expressões relativas. - $date = Chronos::parse('+2 days, +3 hours'); - - // Valores inteiros de Date e Time. - $date = Chronos::create(2015, 12, 25, 4, 32, 58); - - // Valores inteiros de Date ou Time. - $date = Chronos::createFromDate(2015, 12, 25); - $date = Chronos::createFromTime(11, 45, 10); - - // Interpreta valores formatados. - $date = Chronos::createFromFormat('m/d/Y', '06/15/2015'); - -Trabalhando com objetos imutáveis ---------------------------------- - -Se você é familiarizado com os objetos ``DateTime`` do PHP, você se sentirá -confortável com objetos *mutáveis*. Além de objetos mutáveis o Chronos também -oferece objetos imutáveis que por sua vez criam cópias de objetos toda vez que -um objeto é modificado. Devido ao fato de que metodos modificadores relativos -a data e hora nem sempre serem transparentes, informações podem ser modificadas -acidentalmente ou sem que o desenvolvedor saiba. Objetos imutáveis previnem -essas alterações acidentais nos dados. Imutabilidade significa que você deverá -lembrar de substituir variáveis usando modificadores:: - - // Esse código não funciona com objetos imutáveis - $time->addDay(1); - doSomething($time); - return $time; - - // Esse funciona como o esperado - $time = $time->addDay(1); - $time = doSomething($time); - return $time; - -Ao capturar o valor de retorno de cada modificação, seu código funcionará como o -esperado. Se você tem um objeto imutável e quer criar um mutável a partir do -mesmo, use ``toMutable()``:: - - $inplace = $time->toMutable(); - -Objetos Date ------------- - -O PHP disponibiliza um único objeto DateTime. Representar datas de calendário -pode ser um pouco desconfortável por essa classe, uma vez que ela inclui -*timezones* e componentes de hora que realmente não se encaixam no conceito de -'dia'. O Chronos oferece um objeto ``Date`` para representar datas. A hora e a -zona desse objeto é sempre fixado em ``00:00:00 UTC`` e todos os métodos de -formatação/diferença operam sob a resolução de dia:: - - use Cake\Chronos\Date; - - $today = Date::today(); - - // Mudanças na hora/timezone são ignoradas - $today->modify('+1 hours'); - - // Exibe '2016-08-15' - echo $today; - -Métodos modificadores ---------------------- - -Objetos Chronos disponibilizam métodos que permitem a modificação de valores de -forma granular:: - - // Define componentes do valor datetime - $halloween = Chronos::create() - ->year(2015) - ->month(10) - ->day(31) - ->hour(20) - ->minute(30); - -Você também pode modificar partes da data relativamente:: - - $future = Chronos::create() - ->addYear(1) - ->subMonth(2) - ->addDays(15) - ->addHours(20) - ->subMinutes(2); - -Também é possível realizar grandes saltos para períodos definidos no tempo:: - - $time = Chronos::create(); - $time->startOfDay(); - $time->startOfMonth(); - $time->endOfMonth(); - $time->endOfYear(); - $time->startOfWeek(); - $time->endOfWeek(); - -Ou ainda para dias específicos da semana:: - - $time->next(ChronosInterface::TUESDAY); - $time->previous(ChronosInterface::MONDAY); - -Métodos de comparação ---------------------- - -Uma vez que você possui 2 instâncias de objetos data/hora do Chronos, é possível -compará-los de várias maneiras:: - - // Coleção completa de comparadores - // ne, gt, lt, lte. - $first->eq($second); - $first->gte($second); - - // Veja se o objeto atual está entre outros - $now->between($start, $end); - - // Encontre qual argumento está mais perto ou mais longe - $now->closest($june, $november); - $now->farthest($june, $november); - -Você também pode arguir sobre quando um determinado valor cai no calendário:: - - $now->isToday(); - $now->isYesterday(); - $now->isFuture(); - $now->isPast(); - - // Verifica se o dia é no final de semana - $now->isWeekend(); - - // Todos os métodos para outros dias da semana existem também - $now->isMonday(); - -Você também pode verificar se um determinado valor está dentro de um período de -tempo relativo:: - - $time->wasWithinLast('3 days'); - $time->isWithinNext('3 hours'); - -Gerando diferenças ------------------- - -Em adição à comparação de *datetimes*, calcular diferenças ou deltas entre -valores é uma tarefa simples:: - - // Recebe um DateInterval representando a diferença - $first->diff($second); - - // Recebe a diferença como um contador de unidades específicas - $first->diffInHours($second); - $first->diffInDays($second); - $first->diffInWeeks($second); - $first->diffInYears($second); - -Você pode gerar diferenças de fácil leitura para humanos para usar em um *feed* -ou *timeline*:: - - // Diferença em relação ao momento atual - echo $date->diffForHumans(); - - // Diferença em relação a outro período no tempo - echo $date->diffForHumans($other); // 1 hora atrás; - -Formatando strings ------------------- - -O Chronos disponibiliza métodos para exibir nossos objetos *datetime*:: - - // Usa o formato controlado por setToStringFormat() - echo $date; - - // Diferentes padrões de formato - echo $time->toAtomString(); // 1975-12-25T14:15:16-05:00 - echo $time->toCookieString(); // Thursday, 25-Dec-1975 14:15:16 EST - echo $time->toIso8601String(); // 1975-12-25T14:15:16-05:00 - echo $time->toRfc822String(); // Thu, 25 Dec 75 14:15:16 -0500 - echo $time->toRfc850String(); // Thursday, 25-Dec-75 14:15:16 EST - echo $time->toRfc1036String(); // Thu, 25 Dec 75 14:15:16 -0500 - echo $time->toRfc1123String(); // Thu, 25 Dec 1975 14:15:16 -0500 - echo $time->toRfc2822String(); // Thu, 25 Dec 1975 14:15:16 -0500 - echo $time->toRfc3339String(); // 1975-12-25T14:15:16-05:00 - echo $time->toRssString(); // Thu, 25 Dec 1975 14:15:16 -0500 - echo $time->toW3cString(); // 1975-12-25T14:15:16-05:00 - - // Recebe o trimestre - echo $time->toQuarter(); // 4; - -Extraindo componentes de data ------------------------------ - -Podemos receber partes de um objeto *date* acessando propriedades:: - - $time = new Chronos('2015-12-31 23:59:58'); - $time->year; // 2015 - $time->month; // 12 - $time->day; // 31 - $time->hour // 23 - $time->minute // 59 - $time->second // 58 - -Outras propriedades que podem ser acessadas são: - -- timezone -- timezoneName -- micro -- dayOfWeek -- dayOfMonth -- dayOfYear -- daysInMonth -- timestamp -- quarter - -Auxílio para testes -------------------- - -Ao escrever testes unitários, fixar a hora atual é bastante útil. O Chronos -lhe permite fixar a hora atual para cada classe. Como parte das suas ferramentas -de testes, você pode incluir o seguinte:: - - Chronos::setTestNow(Chronos::now()); - MutableDateTime::setTestNow(MutableDateTime::now()); - Date::setTestNow(Date::now()); - MutableDate::setTestNow(MutableDate::now()); - -Isso irá corrigir a hora atual de todos os objetos para o momento em que o -processo de testes foi iniciado. - -Por exemplo, se você fixar o ``Chronos`` em algum momento no passado, qualquer -nova instância do ``Chronos`` criada com ``now`` ou uma *string* de tempo -relativa, teremos um retorno referente ao tempo fixado:: - - Chronos::setTestNow(new Chronos('1975-12-25 00:00:00')); - - $time = new Chronos(); // 1975-12-25 00:00:00 - $time = new Chronos('1 hour ago'); // 1975-12-24 23:00:00 - diff --git a/vendor/cakephp/chronos/src/Chronos.php b/vendor/cakephp/chronos/src/Chronos.php deleted file mode 100644 index f8ddf7384..000000000 --- a/vendor/cakephp/chronos/src/Chronos.php +++ /dev/null @@ -1,215 +0,0 @@ - - * @link http://cakephp.org CakePHP(tm) Project - * @license http://www.opensource.org/licenses/mit-license.php MIT License - */ -namespace Cake\Chronos; - -use DateTimeImmutable; -use DateTimeZone; - -/** - * An Immutable extension on the native DateTime object. - * - * Adds a number of convenience APIs methods and the ability - * to easily convert into a mutable object. - * - * @property-read int $year - * @property-read int $yearIso - * @property-read int $month - * @property-read int $day - * @property-read int $hour - * @property-read int $minute - * @property-read int $second - * @property-read int $micro - * @property-read int $microsecond - * @property-read int $timestamp seconds since the Unix Epoch - * @property-read \DateTimeZone $timezone the current timezone - * @property-read \DateTimeZone $tz alias of timezone - * @property-read int $dayOfWeek 1 (for Monday) through 7 (for Sunday) - * @property-read int $dayOfYear 0 through 365 - * @property-read int $weekOfMonth 1 through 5 - * @property-read int $weekOfYear ISO-8601 week number of year, weeks starting on Monday - * @property-read int $daysInMonth number of days in the given month - * @property-read int $age does a diffInYears() with default parameters - * @property-read int $quarter the quarter of this instance, 1 - 4 - * @property-read int $offset the timezone offset in seconds from UTC - * @property-read int $offsetHours the timezone offset in hours from UTC - * @property-read bool $dst daylight savings time indicator, true if DST, false otherwise - * @property-read bool $local checks if the timezone is local, true if local, false otherwise - * @property-read bool $utc checks if the timezone is UTC, true if UTC, false otherwise - * @property-read string $timezoneName - * @property-read string $tzName - */ -class Chronos extends DateTimeImmutable implements ChronosInterface -{ - use Traits\ComparisonTrait; - use Traits\DifferenceTrait; - use Traits\FactoryTrait; - use Traits\FormattingTrait; - use Traits\MagicPropertyTrait; - use Traits\ModifierTrait; - use Traits\RelativeKeywordTrait; - use Traits\TimezoneTrait; - - /** - * A test ChronosInterface instance to be returned when now instances are created - * - * There is a single test now for all date/time classes provided by Chronos. - * This aims to emulate stubbing out 'now' which is a single global fact. - * - * @var \Cake\Chronos\ChronosInterface|null - */ - protected static $testNow; - - /** - * Format to use for __toString method when type juggling occurs. - * - * @var string - */ - protected static $toStringFormat = ChronosInterface::DEFAULT_TO_STRING_FORMAT; - - /** - * Create a new Chronos instance. - * - * Please see the testing aids section (specifically static::setTestNow()) - * for more on the possibility of this constructor returning a test instance. - * - * @param \DateTimeInterface|string|int|null $time Fixed or relative time - * @param \DateTimeZone|string|null $tz The timezone for the instance - */ - public function __construct($time = 'now', $tz = null) - { - if (is_int($time)) { - parent::__construct('@' . $time); - - return; - } - - if ($tz !== null) { - $tz = $tz instanceof DateTimeZone ? $tz : new DateTimeZone($tz); - } - - if ($time instanceof \DateTimeInterface) { - $time = $time->format('Y-m-d H:i:s.u'); - } - - static::$_lastErrors = []; - $testNow = static::getTestNow(); - if ($testNow === null) { - parent::__construct($time ?? 'now', $tz); - - return; - } - - $relative = static::hasRelativeKeywords($time); - if (!empty($time) && $time !== 'now' && !$relative) { - parent::__construct($time, $tz); - - return; - } - - $testNow = clone $testNow; - $relativetime = static::isTimeExpression($time); - if (!$relativetime && $tz !== $testNow->getTimezone()) { - $testNow = $testNow->setTimezone($tz ?? date_default_timezone_get()); - } - - if ($relative) { - $testNow = $testNow->modify($time); - } - - $time = $testNow->format('Y-m-d H:i:s.u'); - parent::__construct($time, $tz); - } - - /** - * Create a new mutable instance from current immutable instance. - * - * @return \Cake\Chronos\MutableDateTime - */ - public function toMutable(): MutableDateTime - { - return MutableDateTime::instance($this); - } - - /** - * Get a copy of the instance - * - * @return static - */ - public function copy(): ChronosInterface - { - return clone $this; - } - - /** - * Set a ChronosInterface instance (real or mock) to be returned when a "now" - * instance is created. The provided instance will be returned - * specifically under the following conditions: - * - A call to the static now() method, ex. ChronosInterface::now() - * - When a null (or blank string) is passed to the constructor or parse(), ex. new Chronos(null) - * - When the string "now" is passed to the constructor or parse(), ex. new Chronos('now') - * - When a string containing the desired time is passed to ChronosInterface::parse() - * - * Note the timezone parameter was left out of the examples above and - * has no affect as the mock value will be returned regardless of its value. - * - * To clear the test instance call this method using the default - * parameter of null. - * - * @param \Cake\Chronos\ChronosInterface|string|null $testNow The instance to use for all future instances. - * @return void - */ - public static function setTestNow($testNow = null): void - { - static::$testNow = is_string($testNow) ? static::parse($testNow) : $testNow; - } - - /** - * Get the ChronosInterface instance (real or mock) to be returned when a "now" - * instance is created. - * - * @return \Cake\Chronos\ChronosInterface|null The current instance used for testing - */ - public static function getTestNow(): ?ChronosInterface - { - return static::$testNow; - } - - /** - * Determine if there is a valid test instance set. A valid test instance - * is anything that is not null. - * - * @return bool True if there is a test instance, otherwise false - */ - public static function hasTestNow(): bool - { - return static::$testNow !== null; - } - - /** - * Return properties for debugging. - * - * @return array - */ - public function __debugInfo(): array - { - $properties = [ - 'hasFixedNow' => static::hasTestNow(), - 'time' => $this->format('Y-m-d H:i:s.u'), - 'timezone' => $this->getTimezone()->getName(), - ]; - - return $properties; - } -} diff --git a/vendor/cakephp/chronos/src/ChronosInterface.php b/vendor/cakephp/chronos/src/ChronosInterface.php deleted file mode 100644 index f074b4c15..000000000 --- a/vendor/cakephp/chronos/src/ChronosInterface.php +++ /dev/null @@ -1,1403 +0,0 @@ - - * @link http://cakephp.org CakePHP(tm) Project - * @license http://www.opensource.org/licenses/mit-license.php MIT License - */ -namespace Cake\Chronos; - -use DateTimeInterface; - -/** - * An extension to the DateTimeInterface for a friendlier API - * - * @method \Cake\Chronos\ChronosInterface modify(string $relative) - */ -interface ChronosInterface extends DateTimeInterface -{ - /** - * @var int - */ - public const MONDAY = 1; - /** - * @var int - */ - public const TUESDAY = 2; - /** - * @var int - */ - public const WEDNESDAY = 3; - /** - * @var int - */ - public const THURSDAY = 4; - /** - * @var int - */ - public const FRIDAY = 5; - /** - * @var int - */ - public const SATURDAY = 6; - /** - * @var int - */ - public const SUNDAY = 7; - - /** - * @var int - */ - public const YEARS_PER_CENTURY = 100; - /** - * @var int - */ - public const YEARS_PER_DECADE = 10; - /** - * @var int - */ - public const MONTHS_PER_YEAR = 12; - /** - * @var int - */ - public const MONTHS_PER_QUARTER = 3; - /** - * @var int - */ - public const WEEKS_PER_YEAR = 52; - /** - * @var int - */ - public const DAYS_PER_WEEK = 7; - /** - * @var int - */ - public const HOURS_PER_DAY = 24; - /** - * @var int - */ - public const MINUTES_PER_HOUR = 60; - /** - * @var int - */ - public const SECONDS_PER_MINUTE = 60; - - /** - * Default format to use for __toString method when type juggling occurs. - * - * @var string - */ - public const DEFAULT_TO_STRING_FORMAT = 'Y-m-d H:i:s'; - - /** - * Get a ChronosInterface instance for the current date and time - * - * @param \DateTimeZone|string|null $tz The DateTimeZone object or timezone name. - * @return static - */ - public static function now($tz): self; - - /** - * Get a copy of the instance - * - * @return static - */ - public function copy(): self; - - /** - * Set the instance's year - * - * @param int $value The year value. - * @return static - */ - public function year(int $value): self; - - /** - * Set the instance's month - * - * @param int $value The month value. - * @return static - */ - public function month(int $value): self; - - /** - * Set the instance's day - * - * @param int $value The day value. - * @return static - */ - public function day(int $value): self; - - /** - * Set the instance's hour - * - * @param int $value The hour value. - * @return static - */ - public function hour(int $value): self; - - /** - * Set the instance's minute - * - * @param int $value The minute value. - * @return static - */ - public function minute(int $value): self; - - /** - * Set the instance's second - * - * @param int $value The seconds value. - * @return static - */ - public function second(int $value): self; - - /** - * Set the date and time all together - * - * @param int $year The year to set. - * @param int $month The month to set. - * @param int $day The day to set. - * @param int $hour The hour to set. - * @param int $minute The minute to set. - * @param int $second The second to set. - * @return static - */ - public function setDateTime(int $year, int $month, int $day, int $hour, int $minute, int $second = 0): self; - - /** - * Set the time by time string - * - * @param string $time Time as string. - * @return static - */ - public function setTimeFromTimeString(string $time): self; - - /** - * Set the instance's timestamp - * - * @param int $value The timestamp value to set. - * @return static - */ - public function timestamp(int $value): self; - - /** - * Alias for setTimezone() - * - * @param \DateTimeZone|string $value The DateTimeZone object or timezone name to use. - * @return static - */ - public function timezone($value); - - /** - * Alias for setTimezone() - * - * @param \DateTimeZone|string $value The DateTimeZone object or timezone name to use. - * @return static - */ - public function tz($value); - - /** - * Set the instance's timezone from a string or object - * - * @param \DateTimeZone|string $value The DateTimeZone object or timezone name to use. - * @return static - */ - public function setTimezone($value); - - /** - * Format the instance as date - * - * @return string - */ - public function toDateString(): string; - - /** - * Format the instance as a readable date - * - * @return string - */ - public function toFormattedDateString(): string; - - /** - * Format the instance as time - * - * @return string - */ - public function toTimeString(): string; - - /** - * Format the instance as date and time - * - * @return string - */ - public function toDateTimeString(): string; - - /** - * Format the instance with day, date and time - * - * @return string - */ - public function toDayDateTimeString(): string; - - /** - * Format the instance as ATOM - * - * @return string - */ - public function toAtomString(): string; - - /** - * Format the instance as COOKIE - * - * @return string - */ - public function toCookieString(): string; - - /** - * Format the instance as ISO8601 - * - * @return string - */ - public function toIso8601String(): string; - - /** - * Format the instance as RFC822 - * - * @return string - */ - public function toRfc822String(): string; - - /** - * Format the instance as RFC850 - * - * @return string - */ - public function toRfc850String(): string; - - /** - * Format the instance as RFC1036 - * - * @return string - */ - public function toRfc1036String(): string; - - /** - * Format the instance as RFC1123 - * - * @return string - */ - public function toRfc1123String(): string; - - /** - * Format the instance as RFC2822 - * - * @return string - */ - public function toRfc2822String(): string; - - /** - * Format the instance as RFC3339 - * - * @return string - */ - public function toRfc3339String(): string; - - /** - * Format the instance as RSS - * - * @return string - */ - public function toRssString(): string; - - /** - * Format the instance as W3C - * - * @return string - */ - public function toW3cString(): string; - - /** - * Determines if the instance is equal to another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - * @see equals - */ - public function eq(ChronosInterface $dt): bool; - - /** - * Determines if the instance is equal to another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - */ - public function equals(ChronosInterface $dt); - - /** - * Determines if the instance is not equal to another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - * @see notEquals - */ - public function ne(ChronosInterface $dt): bool; - - /** - * Determines if the instance is not equal to another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - */ - public function notEquals(ChronosInterface $dt); - - /** - * Determines if the instance is greater (after) than another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - * @see greaterThan - */ - public function gt(ChronosInterface $dt): bool; - - /** - * Determines if the instance is greater (after) than another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - */ - public function greaterThan(ChronosInterface $dt); - - /** - * Determines if the instance is greater (after) than or equal to another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - * @see greaterThanOrEquals - */ - public function gte(ChronosInterface $dt): bool; - - /** - * Determines if the instance is greater (after) than or equal to another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - */ - public function greaterThanOrEquals(ChronosInterface $dt); - - /** - * Determines if the instance is less (before) than another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - * @see lessThan - */ - public function lt(ChronosInterface $dt): bool; - - /** - * Determines if the instance is less (before) than another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - */ - public function lessThan(ChronosInterface $dt); - - /** - * Determines if the instance is less (before) or equal to another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - * @see lessThanOrEquals - */ - public function lte(ChronosInterface $dt): bool; - - /** - * Determines if the instance is less (before) or equal to another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - */ - public function lessThanOrEquals(ChronosInterface $dt); - - /** - * Determines if the instance is between two others - * - * @param \Cake\Chronos\ChronosInterface $dt1 The instance to compare with. - * @param \Cake\Chronos\ChronosInterface $dt2 The instance to compare with. - * @param bool $equal Indicates if a > and < comparison should be used or <= or >= - * @return bool - */ - public function between(ChronosInterface $dt1, ChronosInterface $dt2, bool $equal = true): bool; - - /** - * Get the closest date from the instance. - * - * @param \Cake\Chronos\ChronosInterface $dt1 The instance to compare with. - * @param \Cake\Chronos\ChronosInterface $dt2 The instance to compare with. - * @return static - */ - public function closest(ChronosInterface $dt1, ChronosInterface $dt2): self; - - /** - * Get the farthest date from the instance. - * - * @param \Cake\Chronos\ChronosInterface $dt1 The instance to compare with. - * @param \Cake\Chronos\ChronosInterface $dt2 The instance to compare with. - * @return static - */ - public function farthest(ChronosInterface $dt1, ChronosInterface $dt2): self; - - /** - * Get the minimum instance between a given instance (default now) and the current instance. - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to compare with. - * @return static - */ - public function min(?ChronosInterface $dt = null): self; - - /** - * Get the maximum instance between a given instance (default now) and the current instance. - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to compare with. - * @return static - */ - public function max(?ChronosInterface $dt = null): self; - - /** - * Determines if the instance is a weekday - * - * @return bool - */ - public function isWeekday(): bool; - - /** - * Determines if the instance is a weekend day - * - * @return bool - */ - public function isWeekend(): bool; - - /** - * Determines if the instance is yesterday - * - * @return bool - */ - public function isYesterday(): bool; - - /** - * Determines if the instance is today - * - * @return bool - */ - public function isToday(): bool; - - /** - * Determines if the instance is tomorrow - * - * @return bool - */ - public function isTomorrow(): bool; - - /** - * Determines if the instance is in the future, ie. greater (after) than now - * - * @return bool - */ - public function isFuture(): bool; - - /** - * Determines if the instance is in the past, ie. less (before) than now - * - * @return bool - */ - public function isPast(): bool; - - /** - * Determines if the instance is a leap year - * - * @return bool - */ - public function isLeapYear(): bool; - - /** - * Checks if the passed in date is the same day as the instance current day. - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to check against. - * @return bool - */ - public function isSameDay(ChronosInterface $dt): bool; - - /** - * Checks if this day is a Sunday. - * - * @return bool - */ - public function isSunday(): bool; - - /** - * Checks if this day is a Monday. - * - * @return bool - */ - public function isMonday(): bool; - - /** - * Checks if this day is a Tuesday. - * - * @return bool - */ - public function isTuesday(): bool; - - /** - * Checks if this day is a Wednesday. - * - * @return bool - */ - public function isWednesday(): bool; - - /** - * Checks if this day is a Thursday. - * - * @return bool - */ - public function isThursday(): bool; - - /** - * Checks if this day is a Friday. - * - * @return bool - */ - public function isFriday(): bool; - - /** - * Checks if this day is a Saturday. - * - * @return bool - */ - public function isSaturday(): bool; - - /** - * Returns true if this object represents a date within the current week - * - * @return bool - */ - public function isThisWeek(): bool; - - /** - * Returns true if this object represents a date within the current month - * - * @return bool - */ - public function isThisMonth(): bool; - - /** - * Returns true if this object represents a date within the current year - * - * @return bool - */ - public function isThisYear(): bool; - - /** - * Add years to the instance. Positive $value travel forward while - * negative $value travel into the past. - * - * If the new date does not exist, the last day of the month is used - * instead instead of overflowing into the next month. - * - * ### Example: - * - * ``` - * (new Chronos('2015-01-03'))->addYears(1); // Results in 2016-01-03 - * - * (new Chronos('2012-02-29'))->addYears(1); // Results in 2013-02-28 - * ``` - * - * @param int $value The number of years to add. - * @return static - */ - public function addYears(int $value): self; - - /** - * Add a year to the instance - * - * Has the same behavior as `addYears()`. - * - * @param int $value The number of years to add. - * @return static - */ - public function addYear(int $value = 1): self; - - /** - * Remove years from the instance. - * - * Has the same behavior as `addYears()`. - * - * @param int $value The number of years to remove. - * @return static - */ - public function subYears(int $value): self; - - /** - * Remove a year from the instance. - * - * Has the same behavior as `addYears()`. - * - * @param int $value The number of years to remove. - * @return static - */ - public function subYear(int $value = 1): self; - - /** - * Add years with overflowing to the instance. Positive $value - * travels forward while negative $value travels into the past. - * - * If the new date does not exist, the days overflow into the next month. - * - * ### Example: - * - * ``` - * (new Chronos('2012-02-29'))->addYearsWithOverflow(1); // Results in 2013-03-01 - * ``` - * - * @param int $value The number of years to add. - * @return static - */ - public function addYearsWithOverflow(int $value): self; - - /** - * Add a year with overflow to the instance - * - * Has the same behavior as `addYearsWithOverflow()`. - * - * @param int $value The number of years to add. - * @return static - */ - public function addYearWithOverflow(int $value = 1): self; - - /** - * Remove years with overflow from the instance - * - * Has the same behavior as `addYearsWithOverflow()`. - * - * @param int $value The number of years to remove. - * @return static - */ - public function subYearsWithOverflow(int $value): self; - - /** - * Remove a year with overflow from the instance - * - * Has the same behavior as `addYearsWithOverflow()`. - * - * @param int $value The number of years to remove. - * @return static - */ - public function subYearWithOverflow(int $value = 1): self; - - /** - * Add months to the instance. Positive $value travels forward while - * negative $value travels into the past. - * - * If the new date does not exist, the last day of the month is used - * instead instead of overflowing into the next month. - * - * ### Example: - * - * ``` - * (new Chronos('2015-01-03'))->addMonths(1); // Results in 2015-02-03 - * - * (new Chronos('2015-01-31'))->addMonths(1); // Results in 2015-02-28 - * ``` - * - * @param int $value The number of months to add. - * @return static - */ - public function addMonths(int $value): self; - - /** - * Add a month to the instance. - * - * Has the same behavior as `addMonths()`. - * - * @param int $value The number of months to add. - * @return static - */ - public function addMonth(int $value = 1): self; - - /** - * Remove a month from the instance - * - * Has the same behavior as `addMonths()`. - * - * @param int $value The number of months to remove. - * @return static - */ - public function subMonth(int $value = 1): self; - - /** - * Remove months from the instance. - * - * Has the same behavior as `addMonths()`. - * - * @param int $value The number of months to remove. - * @return static - */ - public function subMonths(int $value): self; - - /** - * Add months with overflowing to the instance. Positive $value - * travels forward while negative $value travels into the past. - * - * If the new date does not exist, the days overflow into the next month. - * - * ### Example: - * - * ``` - * (new Chronos('2012-01-30'))->addMonthsWithOverflow(1); // Results in 2013-03-01 - * ``` - * - * @param int $value The number of months to add. - * @return static - */ - public function addMonthsWithOverflow(int $value): self; - - /** - * Add a month with overflow to the instance. - * - * Has the same behavior as `addMonthsWithOverflow()`. - * - * @param int $value The number of months to add. - * @return static - */ - public function addMonthWithOverflow(int $value = 1): self; - - /** - * Remove months with overflow from the instance. - * - * Has the same behavior as `addMonthsWithOverflow()`. - * - * @param int $value The number of months to remove. - * @return static - */ - public function subMonthsWithOverflow(int $value): self; - - /** - * Remove a month with overflow from the instance. - * - * Has the same behavior as `addMonthsWithOverflow()`. - * - * @param int $value The number of months to remove. - * @return static - */ - public function subMonthWithOverflow(int $value = 1): self; - - /** - * Add days to the instance. Positive $value travels forward while - * negative $value travels into the past. - * - * @param int $value The number of days to add. - * @return static - */ - public function addDays(int $value): self; - - /** - * Add a day to the instance - * - * @param int $value The number of days to add. - * @return static - */ - public function addDay(int $value = 1): self; - - /** - * Remove days from the instance - * - * @param int $value The number of days to remove. - * @return static - */ - public function subDays(int $value): self; - - /** - * Remove a day from the instance - * - * @param int $value The number of days to remove. - * @return static - */ - public function subDay(int $value = 1): self; - - /** - * Add weekdays to the instance. Positive $value travels forward while - * negative $value travels into the past. - * - * @param int $value The number of weekdays to add. - * @return static - */ - public function addWeekdays(int $value): self; - - /** - * Add a weekday to the instance - * - * @param int $value The number of weekdays to add. - * @return static - */ - public function addWeekday(int $value = 1): self; - - /** - * Remove a weekday from the instance - * - * @param int $value The number of weekdays to remove. - * @return static - */ - public function subWeekday(int $value = 1): self; - - /** - * Remove weekdays from the instance - * - * @param int $value The number of weekdays to remove. - * @return static - */ - public function subWeekdays(int $value): self; - - /** - * Add weeks to the instance. Positive $value travels forward while - * negative $value travels into the past. - * - * @param int $value The number of weeks to add. - * @return static - */ - public function addWeeks(int $value): self; - - /** - * Add a week to the instance - * - * @param int $value The number of weeks to add. - * @return static - */ - public function addWeek(int $value = 1): self; - - /** - * Remove a week from the instance - * - * @param int $value The number of weeks to remove. - * @return static - */ - public function subWeek(int $value = 1): self; - - /** - * Remove weeks to the instance - * - * @param int $value The number of weeks to remove. - * @return static - */ - public function subWeeks(int $value): self; - - /** - * Add hours to the instance. Positive $value travels forward while - * negative $value travels into the past. - * - * @param int $value The number of hours to add. - * @return static - */ - public function addHours(int $value): self; - - /** - * Add an hour to the instance - * - * @param int $value The number of hours to add. - * @return static - */ - public function addHour(int $value = 1): self; - - /** - * Remove an hour from the instance - * - * @param int $value The number of hours to remove. - * @return static - */ - public function subHour(int $value = 1): self; - - /** - * Remove hours from the instance - * - * @param int $value The number of hours to remove. - * @return static - */ - public function subHours(int $value): self; - - /** - * Add minutes to the instance. Positive $value travels forward while - * negative $value travels into the past. - * - * @param int $value The number of minutes to add. - * @return static - */ - public function addMinutes(int $value): self; - - /** - * Add a minute to the instance - * - * @param int $value The number of minutes to add. - * @return static - */ - public function addMinute(int $value = 1): self; - - /** - * Remove a minute from the instance - * - * @param int $value The number of minutes to remove. - * @return static - */ - public function subMinute(int $value = 1): self; - - /** - * Remove minutes from the instance - * - * @param int $value The number of minutes to remove. - * @return static - */ - public function subMinutes(int $value): self; - - /** - * Add seconds to the instance. Positive $value travels forward while - * negative $value travels into the past. - * - * @param int $value The number of seconds to add. - * @return static - */ - public function addSeconds(int $value): self; - - /** - * Add a second to the instance - * - * @param int $value The number of seconds to add. - * @return static - */ - public function addSecond(int $value = 1): self; - - /** - * Remove a second from the instance - * - * @param int $value The number of seconds to remove. - * @return static - */ - public function subSecond(int $value = 1): self; - - /** - * Remove seconds from the instance - * - * @param int $value The number of seconds to remove. - * @return static - */ - public function subSeconds(int $value): self; - - /** - * Get the difference in a human readable format in the current locale. - * - * When comparing a value in the past to default now: - * 1 hour ago - * 5 months ago - * - * When comparing a value in the future to default now: - * 1 hour from now - * 5 months from now - * - * When comparing a value in the past to another value: - * 1 hour before - * 5 months before - * - * When comparing a value in the future to another value: - * 1 hour after - * 5 months after - * - * @param \Cake\Chronos\ChronosInterface|null $other The datetime to compare with. - * @param bool $absolute Removes time difference modifiers ago, after, etc - * @return string - */ - public function diffForHumans(?ChronosInterface $other = null, bool $absolute = false): string; - - /** - * Get the difference in years - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInYears(?ChronosInterface $dt = null, bool $abs = true): int; - - /** - * Get the difference in months - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInMonths(?ChronosInterface $dt = null, bool $abs = true): int; - - /** - * Get the difference in weeks - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInWeeks(?ChronosInterface $dt = null, bool $abs = true): int; - - /** - * Get the difference in days - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInDays(?ChronosInterface $dt = null, bool $abs = true): int; - - /** - * Get the difference in days using a filter callable - * - * @param callable $callback The callback to use for filtering. - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInDaysFiltered(callable $callback, ?ChronosInterface $dt = null, bool $abs = true): int; - - /** - * Get the difference in hours using a filter callable - * - * @param callable $callback The callback to use for filtering. - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInHoursFiltered(callable $callback, ?ChronosInterface $dt = null, bool $abs = true): int; - - /** - * Get the difference by the given interval using a filter callable - * - * @param \Cake\Chronos\ChronosInterval $ci An interval to traverse by - * @param callable $callback The callback to use for filtering. - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffFiltered( - ChronosInterval $ci, - callable $callback, - ?ChronosInterface $dt = null, - bool $abs = true - ): int; - - /** - * Get the difference in weekdays - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInWeekdays(?ChronosInterface $dt = null, bool $abs = true): int; - - /** - * Get the difference in weekend days using a filter - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInWeekendDays(?ChronosInterface $dt = null, bool $abs = true): int; - - /** - * Get the difference in hours - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInHours(?ChronosInterface $dt = null, bool $abs = true): int; - - /** - * Get the difference in minutes - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInMinutes(?ChronosInterface $dt = null, bool $abs = true): int; - - /** - * Get the difference in seconds - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInSeconds(?ChronosInterface $dt = null, bool $abs = true): int; - - /** - * The number of seconds since midnight. - * - * @return int - */ - public function secondsSinceMidnight(): int; - - /** - * The number of seconds until 23:59:59. - * - * @return int - */ - public function secondsUntilEndOfDay(): int; - - /** - * Resets the time to 00:00:00 - * - * @return static - */ - public function startOfDay(): self; - - /** - * Resets the time to 23:59:59 - * - * @return static - */ - public function endOfDay(): self; - - /** - * Resets the date to the first day of the month and the time to 00:00:00 - * - * @return static - */ - public function startOfMonth(): self; - - /** - * Resets the date to end of the month and time to 23:59:59 - * - * @return static - */ - public function endOfMonth(): self; - - /** - * Resets the date to the first day of the year and the time to 00:00:00 - * - * @return static - */ - public function startOfYear(): self; - - /** - * Resets the date to end of the year and time to 23:59:59 - * - * @return static - */ - public function endOfYear(): self; - - /** - * Resets the date to the first day of the decade and the time to 00:00:00 - * - * @return static - */ - public function startOfDecade(): self; - - /** - * Resets the date to end of the decade and time to 23:59:59 - * - * @return static - */ - public function endOfDecade(): self; - - /** - * Resets the date to the first day of the century and the time to 00:00:00 - * - * @return static - */ - public function startOfCentury(): self; - - /** - * Resets the date to end of the century and time to 23:59:59 - * - * @return static - */ - public function endOfCentury(): self; - - /** - * Resets the date to the first day of week (defined in $weekStartsAt) and the time to 00:00:00 - * - * @return static - */ - public function startOfWeek(): self; - - /** - * Resets the date to end of week (defined in $weekEndsAt) and time to 23:59:59 - * - * @return static - */ - public function endOfWeek(): self; - - /** - * Modify to the next occurrence of a given day of the week. - * If no dayOfWeek is provided, modify to the next occurrence - * of the current day of the week. Use the supplied consts - * to indicate the desired dayOfWeek, ex. static::MONDAY. - * - * @param int|null $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function next(?int $dayOfWeek = null); - - /** - * Modify to the previous occurrence of a given day of the week. - * If no dayOfWeek is provided, modify to the previous occurrence - * of the current day of the week. Use the supplied consts - * to indicate the desired dayOfWeek, ex. static::MONDAY. - * - * @param int|null $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function previous(?int $dayOfWeek = null); - - /** - * Modify to the first occurrence of a given day of the week - * in the current month. If no dayOfWeek is provided, modify to the - * first day of the current month. Use the supplied consts - * to indicate the desired dayOfWeek, ex. static::MONDAY. - * - * @param int|null $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function firstOfMonth(?int $dayOfWeek = null); - - /** - * Modify to the last occurrence of a given day of the week - * in the current month. If no dayOfWeek is provided, modify to the - * last day of the current month. Use the supplied consts - * to indicate the desired dayOfWeek, ex. static::MONDAY. - * - * @param int|null $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function lastOfMonth(?int $dayOfWeek = null); - - /** - * Modify to the given occurrence of a given day of the week - * in the current month. If the calculated occurrence is outside the scope - * of the current month, then return false and no modifications are made. - * Use the supplied consts to indicate the desired dayOfWeek, ex. static::MONDAY. - * - * @param int $nth The offset to use. - * @param int $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function nthOfMonth(int $nth, int $dayOfWeek); - - /** - * Modify to the first occurrence of a given day of the week - * in the current quarter. If no dayOfWeek is provided, modify to the - * first day of the current quarter. Use the supplied consts - * to indicate the desired dayOfWeek, ex. static::MONDAY. - * - * @param int|null $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function firstOfQuarter(?int $dayOfWeek = null); - - /** - * Modify to the last occurrence of a given day of the week - * in the current quarter. If no dayOfWeek is provided, modify to the - * last day of the current quarter. Use the supplied consts - * to indicate the desired dayOfWeek, ex. static::MONDAY. - * - * @param int|null $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function lastOfQuarter(?int $dayOfWeek = null); - - /** - * Modify to the given occurrence of a given day of the week - * in the current quarter. If the calculated occurrence is outside the scope - * of the current quarter, then return false and no modifications are made. - * Use the supplied consts to indicate the desired dayOfWeek, ex. static::MONDAY. - * - * @param int $nth The offset to use. - * @param int $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function nthOfQuarter(int $nth, int $dayOfWeek); - - /** - * Modify to the first occurrence of a given day of the week - * in the current year. If no dayOfWeek is provided, modify to the - * first day of the current year. Use the supplied consts - * to indicate the desired dayOfWeek, ex. static::MONDAY. - * - * @param int|null $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function firstOfYear(?int $dayOfWeek = null); - - /** - * Modify to the last occurrence of a given day of the week - * in the current year. If no dayOfWeek is provided, modify to the - * last day of the current year. Use the supplied consts - * to indicate the desired dayOfWeek, ex. static::MONDAY. - * - * @param int|null $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function lastOfYear(?int $dayOfWeek = null); - - /** - * Modify to the given occurrence of a given day of the week - * in the current year. If the calculated occurrence is outside the scope - * of the current year, then return false and no modifications are made. - * Use the supplied consts to indicate the desired dayOfWeek, ex. static::MONDAY. - * - * @param int $nth The offset to use. - * @param int $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function nthOfYear(int $nth, int $dayOfWeek); - - /** - * Modify the current instance to the average of a given instance (default now) and the current instance. - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return static - */ - public function average(?ChronosInterface $dt = null): self; - - /** - * Check if its the birthday. Compares the date/month values of the two dates. - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - */ - public function isBirthday(ChronosInterface $dt): bool; - - /** - * Returns true this instance happened within the specified interval - * - * @param string|int $timeInterval the numeric value with space then time type. - * Example of valid types: 6 hours, 2 days, 1 minute. - * @return bool - */ - public function wasWithinLast($timeInterval): bool; - - /** - * Returns true this instance will happen within the specified interval - * - * @param string|int $timeInterval the numeric value with space then time type. - * Example of valid types: 6 hours, 2 days, 1 minute. - * @return bool - */ - public function isWithinNext($timeInterval): bool; - - /** - * Check if instance of ChronosInterface is mutable. - * - * @return bool - */ - public function isMutable(): bool; -} diff --git a/vendor/cakephp/chronos/src/ChronosInterval.php b/vendor/cakephp/chronos/src/ChronosInterval.php deleted file mode 100644 index 4f4464326..000000000 --- a/vendor/cakephp/chronos/src/ChronosInterval.php +++ /dev/null @@ -1,550 +0,0 @@ - - * @link http://cakephp.org CakePHP(tm) Project - * @license http://www.opensource.org/licenses/mit-license.php MIT License - */ -namespace Cake\Chronos; - -use BadMethodCallException; -use DateInterval; -use InvalidArgumentException; - -/** - * A simple API extension for DateInterval. - * The implementation provides helpers to handle weeks but only days are saved. - * Weeks are calculated based on the total days of the current instance. - * - * @property int $years Total years of the current interval. - * @property int $months Total months of the current interval. - * @property int $weeks Total weeks of the current interval calculated from the days. - * @property int $dayz Total days of the current interval (weeks * 7 + days). - * @property int $hours Total hours of the current interval. - * @property int $minutes Total minutes of the current interval. - * @property int $seconds Total seconds of the current interval. - * @property int $microseconds Total microseconds of the current interval. - * @property-read int $dayzExcludeWeeks Total days remaining in the final week of the current instance (days % 7). - * @property-read int $daysExcludeWeeks alias of dayzExcludeWeeks - * @method static \Cake\Chronos\ChronosInterval years($years = 1) Create instance specifying a number of years. - * @method static \Cake\Chronos\ChronosInterval year($years = 1) Alias for years - * @method static \Cake\Chronos\ChronosInterval months($months = 1) Create instance specifying a number of months. - * @method static \Cake\Chronos\ChronosInterval month($months = 1) Alias for months - * @method static \Cake\Chronos\ChronosInterval weeks($weeks = 1) Create instance specifying a number of weeks. - * @method static \Cake\Chronos\ChronosInterval week($weeks = 1) Alias for weeks - * @method static \Cake\Chronos\ChronosInterval days($days = 1) Create instance specifying a number of days. - * @method static \Cake\Chronos\ChronosInterval dayz($days = 1) Alias for days - * @method static \Cake\Chronos\ChronosInterval day($days = 1) Alias for days - * @method static \Cake\Chronos\ChronosInterval hours($hours = 1) Create instance specifying a number of hours. - * @method static \Cake\Chronos\ChronosInterval hour($hours = 1) Alias for hours - * @method static \Cake\Chronos\ChronosInterval minutes($minutes = 1) Create instance specifying a number of minutes. - * @method static \Cake\Chronos\ChronosInterval minute($minutes = 1) Alias for minutes - * @method static \Cake\Chronos\ChronosInterval seconds($seconds = 1) Create instance specifying a number of seconds. - * @method static \Cake\Chronos\ChronosInterval second($seconds = 1) Alias for seconds - * @method static \Cake\Chronos\ChronosInterval microseconds($microseconds = 1) Create instance specifying a number of microseconds. - * @method static \Cake\Chronos\ChronosInterval microsecond($microseconds = 1) Alias for microseconds - */ -class ChronosInterval extends DateInterval -{ - /** - * @var string - */ - public const PERIOD_PREFIX = 'P'; - /** - * @var string - */ - public const PERIOD_YEARS = 'Y'; - /** - * @var string - */ - public const PERIOD_MONTHS = 'M'; - /** - * @var string - */ - public const PERIOD_DAYS = 'D'; - /** - * @var string - */ - public const PERIOD_TIME_PREFIX = 'T'; - /** - * @var string - */ - public const PERIOD_HOURS = 'H'; - /** - * @var string - */ - public const PERIOD_MINUTES = 'M'; - /** - * @var string - */ - public const PERIOD_SECONDS = 'S'; - - /** - * Determine if the interval was created via DateTime:diff() or not. - * - * @param \DateInterval $interval The interval to check. - * @return bool - */ - protected static function wasCreatedFromDiff(DateInterval $interval): bool - { - return $interval->days !== false; - } - - /** - * Create a new ChronosInterval instance. - * - * @param int|null $years The year to use. - * @param int|null $months The month to use. - * @param int|null $weeks The week to use. - * @param int|null $days The day to use. - * @param int|null $hours The hours to use. - * @param int|null $minutes The minutes to use. - * @param int|null $seconds The seconds to use. - * @param int|null $microseconds The microseconds to use. - */ - public function __construct( - ?int $years = 1, - ?int $months = null, - ?int $weeks = null, - ?int $days = null, - ?int $hours = null, - ?int $minutes = null, - ?int $seconds = null, - ?int $microseconds = null - ) { - $spec = static::PERIOD_PREFIX; - - $spec .= $years > 0 ? $years . static::PERIOD_YEARS : ''; - $spec .= $months > 0 ? $months . static::PERIOD_MONTHS : ''; - - $specDays = 0; - $specDays += $weeks > 0 ? $weeks * ChronosInterface::DAYS_PER_WEEK : 0; - $specDays += $days > 0 ? $days : 0; - - $spec .= $specDays > 0 ? $specDays . static::PERIOD_DAYS : ''; - - if ($spec === static::PERIOD_PREFIX) { - $spec .= '0' . static::PERIOD_YEARS; - } - - if ($hours > 0 || $minutes > 0 || $seconds > 0) { - $spec .= static::PERIOD_TIME_PREFIX; - $spec .= $hours > 0 ? $hours . static::PERIOD_HOURS : ''; - $spec .= $minutes > 0 ? $minutes . static::PERIOD_MINUTES : ''; - $spec .= $seconds > 0 ? $seconds . static::PERIOD_SECONDS : ''; - } - - parent::__construct($spec); - - if ($microseconds > 0) { - $this->f = $microseconds / 1000000; - } - } - - /** - * Create a new ChronosInterval instance from specific values. - * This is an alias for the constructor that allows better fluent - * syntax as it allows you to do ChronosInterval::create(1)->fn() rather than - * (new ChronosInterval(1))->fn(). - * - * @param int|null $years The year to use. - * @param int|null $months The month to use. - * @param int|null $weeks The week to use. - * @param int|null $days The day to use. - * @param int|null $hours The hours to use. - * @param int|null $minutes The minutes to use. - * @param int|null $seconds The seconds to use. - * @param int|null $microseconds The microseconds to use. - * @return static - */ - public static function create( - ?int $years = 1, - ?int $months = null, - ?int $weeks = null, - ?int $days = null, - ?int $hours = null, - ?int $minutes = null, - ?int $seconds = null, - ?int $microseconds = null - ): self { - return new static($years, $months, $weeks, $days, $hours, $minutes, $seconds, $microseconds); - } - - /** - * Provide static helpers to create instances. Allows: - * - * ``` - * ChronosInterval::years(3) - * // or - * ChronosInterval::month(1); - * ``` - * - * Note: This is done using the magic method to allow static and instance methods to - * have the same names. - * - * @param string $name The property to configure. Accepts singular and plural forms. - * @param array $args Contains the value to use. - * @return static - */ - public static function __callStatic(string $name, array $args): self - { - $arg = count($args) === 0 ? 1 : $args[0]; - - switch ($name) { - case 'years': - case 'year': - return new static($arg); - - case 'months': - case 'month': - return new static(null, $arg); - - case 'weeks': - case 'week': - return new static(null, null, $arg); - - case 'days': - case 'dayz': - case 'day': - return new static(null, null, null, $arg); - - case 'hours': - case 'hour': - return new static(null, null, null, null, $arg); - - case 'minutes': - case 'minute': - return new static(null, null, null, null, null, $arg); - - case 'seconds': - case 'second': - return new static(null, null, null, null, null, null, $arg); - - case 'microseconds': - case 'microsecond': - return new static(null, null, null, null, null, null, null, $arg); - } - - throw new BadMethodCallException(sprintf('Cannot create interval with `%s` units', $name)); - } - - /** - * Create a ChronosInterval instance from a DateInterval one. Can not instance - * DateInterval objects created from DateTime::diff() as you can't externally - * set the $days field. - * - * @param \DateInterval $di The DateInterval instance to copy. - * @throws \InvalidArgumentException - * @return static - */ - public static function instance(DateInterval $di): self - { - if (static::wasCreatedFromDiff($di)) { - throw new InvalidArgumentException( - 'Can not instance a DateInterval object created from DateTime::diff().' - ); - } - - $instance = new static($di->y, $di->m, 0, $di->d, $di->h, $di->i, $di->s); - $instance->f = $di->f; - $instance->invert = $di->invert; - $instance->days = $di->days; - - return $instance; - } - - /** - * Get a part of the ChronosInterval object - * - * @param string $name The property to read. - * @throws \InvalidArgumentException - * @return int - */ - public function __get(string $name) - { - switch ($name) { - case 'years': - return $this->y; - - case 'months': - return $this->m; - - case 'dayz': - return $this->d; - - case 'hours': - return $this->h; - - case 'minutes': - return $this->i; - - case 'seconds': - return $this->s; - - case 'microseconds': - return (int)($this->f * 1000000); - - case 'weeks': - return (int)floor($this->d / ChronosInterface::DAYS_PER_WEEK); - - case 'daysExcludeWeeks': - case 'dayzExcludeWeeks': - return $this->dayz % ChronosInterface::DAYS_PER_WEEK; - - default: - throw new InvalidArgumentException(sprintf("Unknown getter '%s'", $name)); - } - } - - /** - * Set a part of the ChronosInterval object - * - * @param string $name The property to augment. - * @param int $val The value to change. - * @return void - * @throws \InvalidArgumentException - */ - public function __set(string $name, $val): void - { - switch ($name) { - case 'years': - $this->y = $val; - break; - - case 'months': - $this->m = $val; - break; - - case 'weeks': - $val = $val * ChronosInterface::DAYS_PER_WEEK; - $this->d = $val; - break; - - case 'dayz': - $this->d = $val; - break; - - case 'hours': - $this->h = $val; - break; - - case 'minutes': - $this->i = $val; - break; - - case 'seconds': - $this->s = $val; - break; - - case 'microseconds': - $this->f = $val / 1000000; - break; - - case 'invert': - $this->invert = $val; - break; - } - } - - /** - * Allow setting of weeks and days to be cumulative. - * - * @param int $weeks Number of weeks to set - * @param int $days Number of days to set - * @return $this - */ - public function weeksAndDays(int $weeks, int $days) - { - $this->dayz = ($weeks * ChronosInterface::DAYS_PER_WEEK) + $days; - - return $this; - } - - /** - * Allow fluent calls on the setters... ChronosInterval::years(3)->months(5)->day(). - * - * Note: This is done using the magic method to allow static and instance methods to - * have the same names. - * - * @param string $name The property name to augment. Accepts plural forms in addition - * to singular ones. - * @param array $args The value to set. - * @return $this - */ - public function __call(string $name, array $args) - { - $arg = count($args) === 0 ? 1 : $args[0]; - - switch ($name) { - case 'years': - case 'year': - $this->years = $arg; - break; - - case 'months': - case 'month': - $this->months = $arg; - break; - - case 'weeks': - case 'week': - $this->dayz = $arg * ChronosInterface::DAYS_PER_WEEK; - break; - - case 'days': - case 'dayz': - case 'day': - $this->dayz = $arg; - break; - - case 'hours': - case 'hour': - $this->hours = $arg; - break; - - case 'minutes': - case 'minute': - $this->minutes = $arg; - break; - - case 'seconds': - case 'second': - $this->seconds = $arg; - break; - - case 'microseconds': - case 'microsecond': - $this->microseconds = $arg; - break; - } - - return $this; - } - - /** - * Add the passed interval to the current instance - * - * @param \DateInterval $interval The interval to add. - * @return $this - */ - public function add(DateInterval $interval) - { - $sign = $interval->invert === 1 ? -1 : 1; - - if (static::wasCreatedFromDiff($interval)) { - $this->dayz = $this->dayz + ($interval->days * $sign); - } else { - $this->years = $this->years + ($interval->y * $sign); - $this->months = $this->months + ($interval->m * $sign); - $this->dayz = $this->dayz + ($interval->d * $sign); - $this->hours = $this->hours + ($interval->h * $sign); - $this->minutes = $this->minutes + ($interval->i * $sign); - $this->seconds = $this->seconds + ($interval->s * $sign); - $this->microseconds = $this->microseconds + (int)($interval->f * 1000000 * $sign); - } - - return $this; - } - - /** - * Returns the ISO 8601 interval string. - * - * @return string Interval as string representation - */ - public function __toString(): string - { - // equivalence - $oneMinuteInSeconds = 60; - $oneHourInSeconds = $oneMinuteInSeconds * 60; - $oneDayInSeconds = $oneHourInSeconds * 24; - $oneMonthInDays = 365 / 12; - $oneMonthInSeconds = $oneDayInSeconds * $oneMonthInDays; - $oneYearInSeconds = 12 * $oneMonthInSeconds; - - // convert - $ySecs = $this->y * $oneYearInSeconds; - $mSecs = $this->m * $oneMonthInSeconds; - $dSecs = $this->d * $oneDayInSeconds; - $hSecs = $this->h * $oneHourInSeconds; - $iSecs = $this->i * $oneMinuteInSeconds; - $sSecs = $this->s; - - $totalSecs = $ySecs + $mSecs + $dSecs + $hSecs + $iSecs + $sSecs; - - $y = null; - $m = null; - $d = null; - $h = null; - $i = null; - - // years - if ($totalSecs >= $oneYearInSeconds) { - $y = floor($totalSecs / $oneYearInSeconds); - $totalSecs = $totalSecs - $y * $oneYearInSeconds; - } - - // months - if ($totalSecs >= $oneMonthInSeconds) { - $m = floor($totalSecs / $oneMonthInSeconds); - $totalSecs = $totalSecs - $m * $oneMonthInSeconds; - } - - // days - if ($totalSecs >= $oneDayInSeconds) { - $d = floor($totalSecs / $oneDayInSeconds); - $totalSecs = $totalSecs - $d * $oneDayInSeconds; - } - - // hours - if ($totalSecs >= $oneHourInSeconds) { - $h = floor($totalSecs / $oneHourInSeconds); - $totalSecs = $totalSecs - $h * $oneHourInSeconds; - } - - // minutes - if ($totalSecs >= $oneMinuteInSeconds) { - $i = floor($totalSecs / $oneMinuteInSeconds); - $totalSecs = $totalSecs - $i * $oneMinuteInSeconds; - } - - $s = $totalSecs; - - $date = array_filter([ - static::PERIOD_YEARS => $y, - static::PERIOD_MONTHS => $m, - static::PERIOD_DAYS => $d, - ]); - - $time = array_filter([ - static::PERIOD_HOURS => $h, - static::PERIOD_MINUTES => $i, - static::PERIOD_SECONDS => $s, - ]); - - $specString = static::PERIOD_PREFIX; - - foreach ($date as $key => $value) { - $specString .= $value . $key; - } - - if (count($time) > 0) { - $specString .= static::PERIOD_TIME_PREFIX; - foreach ($time as $key => $value) { - $specString .= $value . $key; - } - } - - if ($specString === static::PERIOD_PREFIX) { - return 'PT0S'; - } - - return $this->invert === 1 ? '-' . $specString : $specString; - } -} diff --git a/vendor/cakephp/chronos/src/Date.php b/vendor/cakephp/chronos/src/Date.php deleted file mode 100644 index 67b44a24e..000000000 --- a/vendor/cakephp/chronos/src/Date.php +++ /dev/null @@ -1,142 +0,0 @@ -stripTime($time, $tz); - parent::__construct($time); - - return; - } - - $testNow = clone $testNow; - if ($tz !== $testNow->getTimezone()) { - $testNow = $testNow->setTimezone($tz ?? date_default_timezone_get()); - } - if (!empty($time)) { - $testNow = $testNow->modify($time); - } - - $time = $testNow->format('Y-m-d 00:00:00'); - parent::__construct($time); - } - - /** - * Create a new mutable instance from current immutable instance. - * - * @return \Cake\Chronos\MutableDate - */ - public function toMutable(): MutableDate - { - return MutableDate::instance($this); - } - - /** - * Return properties for debugging. - * - * @return array - */ - public function __debugInfo(): array - { - $properties = [ - 'hasFixedNow' => static::hasTestNow(), - 'date' => $this->format('Y-m-d'), - ]; - - return $properties; - } -} diff --git a/vendor/cakephp/chronos/src/DifferenceFormatter.php b/vendor/cakephp/chronos/src/DifferenceFormatter.php deleted file mode 100644 index d1a47cd29..000000000 --- a/vendor/cakephp/chronos/src/DifferenceFormatter.php +++ /dev/null @@ -1,107 +0,0 @@ - - * @link http://cakephp.org CakePHP(tm) Project - * @license http://www.opensource.org/licenses/mit-license.php MIT License - */ -namespace Cake\Chronos; - -/** - * Handles formatting differences in text. - * - * Provides a swappable component for other libraries to leverage. - * when localizing or customizing the difference output. - */ -class DifferenceFormatter implements DifferenceFormatterInterface -{ - /** - * The text translator object - * - * @var \Cake\Chronos\Translator - */ - protected $translate; - - /** - * Constructor. - * - * @param \Cake\Chronos\Translator|null $translate The text translator object. - */ - public function __construct(?Translator $translate = null) - { - $this->translate = $translate ?: new Translator(); - } - - /** - * Get the difference in a human readable format. - * - * @param \Cake\Chronos\ChronosInterface $date The datetime to start with. - * @param \Cake\Chronos\ChronosInterface|null $other The datetime to compare against. - * @param bool $absolute removes time difference modifiers ago, after, etc - * @return string The difference between the two days in a human readable format - * @see \Cake\Chronos\ChronosInterface::diffForHumans - */ - public function diffForHumans( - ChronosInterface $date, - ?ChronosInterface $other = null, - bool $absolute = false - ): string { - $isNow = $other === null; - if ($isNow) { - $other = $date->now($date->tz); - } - $diffInterval = $date->diff($other); - - switch (true) { - case $diffInterval->y > 0: - $unit = 'year'; - $count = $diffInterval->y; - break; - case $diffInterval->m > 0: - $unit = 'month'; - $count = $diffInterval->m; - break; - case $diffInterval->d > 0: - $unit = 'day'; - $count = $diffInterval->d; - if ($count >= ChronosInterface::DAYS_PER_WEEK) { - $unit = 'week'; - $count = (int)($count / ChronosInterface::DAYS_PER_WEEK); - } - break; - case $diffInterval->h > 0: - $unit = 'hour'; - $count = $diffInterval->h; - break; - case $diffInterval->i > 0: - $unit = 'minute'; - $count = $diffInterval->i; - break; - default: - $count = $diffInterval->s; - $unit = 'second'; - break; - } - $time = $this->translate->plural($unit, $count, ['count' => $count]); - if ($absolute) { - return $time; - } - $isFuture = $diffInterval->invert === 1; - $transId = $isNow ? ($isFuture ? 'from_now' : 'ago') : ($isFuture ? 'after' : 'before'); - - // Some langs have special pluralization for past and future tense. - $tryKeyExists = $unit . '_' . $transId; - if ($this->translate->exists($tryKeyExists)) { - $time = $this->translate->plural($tryKeyExists, $count, ['count' => $count]); - } - - return $this->translate->singular($transId, ['time' => $time]); - } -} diff --git a/vendor/cakephp/chronos/src/DifferenceFormatterInterface.php b/vendor/cakephp/chronos/src/DifferenceFormatterInterface.php deleted file mode 100644 index e94892604..000000000 --- a/vendor/cakephp/chronos/src/DifferenceFormatterInterface.php +++ /dev/null @@ -1,35 +0,0 @@ -stripTime($time, $tz); - parent::__construct($time); - - return; - } - - $testNow = clone $testNow; - if ($tz !== $testNow->getTimezone()) { - $testNow = $testNow->setTimezone($tz ?? date_default_timezone_get()); - } - if (!empty($time)) { - $testNow = $testNow->modify($time); - } - - $time = $testNow->format('Y-m-d 00:00:00'); - parent::__construct($time); - } - - /** - * Create a new immutable instance from current mutable instance. - * - * @return \Cake\Chronos\Date - */ - public function toImmutable(): Date - { - return Date::instance($this); - } - - /** - * Return properties for debugging. - * - * @return array - */ - public function __debugInfo(): array - { - $properties = [ - 'hasFixedNow' => static::hasTestNow(), - 'date' => $this->format('Y-m-d'), - ]; - - return $properties; - } -} diff --git a/vendor/cakephp/chronos/src/MutableDateTime.php b/vendor/cakephp/chronos/src/MutableDateTime.php deleted file mode 100644 index a01865734..000000000 --- a/vendor/cakephp/chronos/src/MutableDateTime.php +++ /dev/null @@ -1,200 +0,0 @@ - - * @link http://cakephp.org CakePHP(tm) Project - * @license http://www.opensource.org/licenses/mit-license.php MIT License - */ -namespace Cake\Chronos; - -use DateTime; -use DateTimeZone; -use InvalidArgumentException; - -/** - * A mutable datetime instance that implements the ChronosInterface. - * - * This object can be mutated in place using any setter method, - * or __set(). - * - * @property-read int $year - * @property-read int $yearIso - * @property-read int $month - * @property-read int $day - * @property-read int $hour - * @property-read int $minute - * @property-read int $second - * @property-read int $micro - * @property-read int $microsecond - * @property-read int $timestamp seconds since the Unix Epoch - * @property-read \DateTimeZone|string $timezone the current timezone - * @property-read \DateTimeZone|string $tz alias of timezone - * @property-read int $dayOfWeek 1 (for Monday) through 7 (for Sunday) - * @property-read int $dayOfYear 0 through 365 - * @property-read int $weekOfMonth 1 through 5 - * @property-read int $weekOfYear ISO-8601 week number of year, weeks starting on Monday - * @property-read int $daysInMonth number of days in the given month - * @property-read int $age does a diffInYears() with default parameters - * @property-read int $quarter the quarter of this instance, 1 - 4 - * @property-read int $offset the timezone offset in seconds from UTC - * @property-read int $offsetHours the timezone offset in hours from UTC - * @property-read bool $dst daylight savings time indicator, true if DST, false otherwise - * @property-read bool $local checks if the timezone is local, true if local, false otherwise - * @property-read bool $utc checks if the timezone is UTC, true if UTC, false otherwise - * @property-read string $timezoneName - * @property-read string $tzName - */ -class MutableDateTime extends DateTime implements ChronosInterface -{ - use Traits\ComparisonTrait; - use Traits\DifferenceTrait; - use Traits\FactoryTrait; - use Traits\FormattingTrait; - use Traits\MagicPropertyTrait; - use Traits\ModifierTrait; - use Traits\RelativeKeywordTrait; - use Traits\TestingAidTrait; - use Traits\TimezoneTrait; - - /** - * Format to use for __toString method when type juggling occurs. - * - * @var string - */ - protected static $toStringFormat = ChronosInterface::DEFAULT_TO_STRING_FORMAT; - - /** - * Create a new MutableDateTime instance. - * - * Please see the testing aids section (specifically static::setTestNow()) - * for more on the possibility of this constructor returning a test instance. - * - * @param \DateTimeInterface|string|int|null $time Fixed or relative time - * @param \DateTimeZone|string|null $tz The timezone for the instance - */ - public function __construct($time = 'now', $tz = null) - { - if (is_int($time)) { - parent::__construct('@' . $time); - - return; - } - - if ($tz !== null) { - $tz = $tz instanceof DateTimeZone ? $tz : new DateTimeZone($tz); - } - - if ($time instanceof \DateTimeInterface) { - $time = $time->format('Y-m-d H:i:s.u'); - } - - $testNow = Chronos::getTestNow(); - if ($testNow === null) { - parent::__construct($time ?? 'now', $tz); - - return; - } - - $relative = static::hasRelativeKeywords($time); - if (!empty($time) && $time !== 'now' && !$relative) { - parent::__construct($time, $tz); - - return; - } - - $testNow = clone $testNow; - $relativetime = static::isTimeExpression($time); - if (!$relativetime && $tz !== $testNow->getTimezone()) { - $testNow = $testNow->setTimezone($tz ?? date_default_timezone_get()); - } - - if ($relative) { - $testNow = $testNow->modify($time); - } - - $time = $testNow->format('Y-m-d H:i:s.u'); - parent::__construct($time, $tz); - } - - /** - * Create a new immutable instance from current mutable instance. - * - * @return \Cake\Chronos\Chronos - */ - public function toImmutable(): Chronos - { - return Chronos::instance($this); - } - - /** - * Set a part of the ChronosInterface object - * - * @param string $name The property to set. - * @param string|int|\DateTimeZone $value The value to set. - * @throws \InvalidArgumentException - * @return void - */ - public function __set(string $name, $value): void - { - switch ($name) { - case 'year': - $this->year($value); - break; - - case 'month': - $this->month($value); - break; - - case 'day': - $this->day($value); - break; - - case 'hour': - $this->hour($value); - break; - - case 'minute': - $this->minute($value); - break; - - case 'second': - $this->second($value); - break; - - case 'timestamp': - $this->timestamp($value); - break; - - case 'timezone': - case 'tz': - $this->timezone($value); - break; - - default: - throw new InvalidArgumentException(sprintf("Unknown setter '%s'", $name)); - } - } - - /** - * Return properties for debugging. - * - * @return array - */ - public function __debugInfo(): array - { - $properties = [ - 'hasFixedNow' => static::hasTestNow(), - 'time' => $this->format('Y-m-d H:i:s.u'), - 'timezone' => $this->getTimezone()->getName(), - ]; - - return $properties; - } -} diff --git a/vendor/cakephp/chronos/src/Traits/ComparisonTrait.php b/vendor/cakephp/chronos/src/Traits/ComparisonTrait.php deleted file mode 100644 index 5f076d540..000000000 --- a/vendor/cakephp/chronos/src/Traits/ComparisonTrait.php +++ /dev/null @@ -1,565 +0,0 @@ - - * @link http://cakephp.org CakePHP(tm) Project - * @license http://www.opensource.org/licenses/mit-license.php MIT License - */ -namespace Cake\Chronos\Traits; - -use Cake\Chronos\ChronosInterface; -use DateTime; - -/** - * Provides various comparison operator methods for datetime objects. - */ -trait ComparisonTrait -{ - use CopyTrait; - - /** - * Days of weekend - * - * @var array - */ - protected static $weekendDays = [ChronosInterface::SATURDAY, ChronosInterface::SUNDAY]; - - /** - * Get weekend days - * - * @return array - */ - public static function getWeekendDays(): array - { - return static::$weekendDays; - } - - /** - * Set weekend days - * - * @param array $days Which days are 'weekends'. - * @return void - */ - public static function setWeekendDays(array $days): void - { - static::$weekendDays = $days; - } - - /** - * Determines if the instance is equal to another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - */ - public function eq(ChronosInterface $dt): bool - { - return $this == $dt; - } - - /** - * Determines if the instance is equal to another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - */ - public function equals(ChronosInterface $dt) - { - return $this->eq($dt); - } - - /** - * Determines if the instance is not equal to another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - */ - public function ne(ChronosInterface $dt): bool - { - return !$this->eq($dt); - } - - /** - * Determines if the instance is not equal to another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - */ - public function notEquals(ChronosInterface $dt) - { - return $this->ne($dt); - } - - /** - * Determines if the instance is greater (after) than another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - */ - public function gt(ChronosInterface $dt): bool - { - return $this > $dt; - } - - /** - * Determines if the instance is greater (after) than another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - */ - public function greaterThan(ChronosInterface $dt) - { - return $this->gt($dt); - } - - /** - * Determines if the instance is greater (after) than or equal to another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - */ - public function gte(ChronosInterface $dt): bool - { - return $this >= $dt; - } - - /** - * Determines if the instance is greater (after) than or equal to another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - */ - public function greaterThanOrEquals(ChronosInterface $dt) - { - return $this->gte($dt); - } - - /** - * Determines if the instance is less (before) than another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - */ - public function lt(ChronosInterface $dt): bool - { - return $this < $dt; - } - - /** - * Determines if the instance is less (before) than another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - */ - public function lessThan(ChronosInterface $dt) - { - return $this->lt($dt); - } - - /** - * Determines if the instance is less (before) or equal to another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - */ - public function lte(ChronosInterface $dt): bool - { - return $this <= $dt; - } - - /** - * Determines if the instance is less (before) or equal to another - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to compare with. - * @return bool - */ - public function lessThanOrEquals(ChronosInterface $dt) - { - return $this->lte($dt); - } - - /** - * Determines if the instance is between two others - * - * @param \Cake\Chronos\ChronosInterface $dt1 The instance to compare with. - * @param \Cake\Chronos\ChronosInterface $dt2 The instance to compare with. - * @param bool $equal Indicates if a > and < comparison should be used or <= or >= - * @return bool - */ - public function between(ChronosInterface $dt1, ChronosInterface $dt2, bool $equal = true): bool - { - if ($dt1->gt($dt2)) { - $temp = $dt1; - $dt1 = $dt2; - $dt2 = $temp; - } - - if ($equal) { - return $this->gte($dt1) && $this->lte($dt2); - } - - return $this->gt($dt1) && $this->lt($dt2); - } - - /** - * Get the closest date from the instance. - * - * @param \Cake\Chronos\ChronosInterface $dt1 The instance to compare with. - * @param \Cake\Chronos\ChronosInterface $dt2 The instance to compare with. - * @return \Cake\Chronos\ChronosInterface - */ - public function closest(ChronosInterface $dt1, ChronosInterface $dt2): ChronosInterface - { - return $this->diffInSeconds($dt1) < $this->diffInSeconds($dt2) ? $dt1 : $dt2; - } - - /** - * Get the farthest date from the instance. - * - * @param \Cake\Chronos\ChronosInterface $dt1 The instance to compare with. - * @param \Cake\Chronos\ChronosInterface $dt2 The instance to compare with. - * @return \Cake\Chronos\ChronosInterface - */ - public function farthest(ChronosInterface $dt1, ChronosInterface $dt2): ChronosInterface - { - return $this->diffInSeconds($dt1) > $this->diffInSeconds($dt2) ? $dt1 : $dt2; - } - - /** - * Get the minimum instance between a given instance (default now) and the current instance. - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to compare with. - * @return \Cake\Chronos\ChronosInterface - */ - public function min(?ChronosInterface $dt = null): ChronosInterface - { - $dt = $dt ?? static::now($this->tz); - - return $this->lt($dt) ? $this : $dt; - } - - /** - * Get the maximum instance between a given instance (default now) and the current instance. - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to compare with. - * @return \Cake\Chronos\ChronosInterface - */ - public function max(?ChronosInterface $dt = null): ChronosInterface - { - $dt = $dt ?? static::now($this->tz); - - return $this->gt($dt) ? $this : $dt; - } - - /** - * Determines if the instance is a weekday - * - * @return bool - */ - public function isWeekday(): bool - { - return !$this->isWeekend(); - } - - /** - * Determines if the instance is a weekend day - * - * @return bool - */ - public function isWeekend(): bool - { - return in_array($this->dayOfWeek, self::$weekendDays, true); - } - - /** - * Determines if the instance is yesterday - * - * @return bool - */ - public function isYesterday(): bool - { - return $this->toDateString() === static::yesterday($this->tz)->toDateString(); - } - - /** - * Determines if the instance is today - * - * @return bool - */ - public function isToday(): bool - { - return $this->toDateString() === static::now($this->tz)->toDateString(); - } - - /** - * Determines if the instance is tomorrow - * - * @return bool - */ - public function isTomorrow(): bool - { - return $this->toDateString() === static::tomorrow($this->tz)->toDateString(); - } - - /** - * Determines if the instance is within the next week - * - * @return bool - */ - public function isNextWeek(): bool - { - return $this->format('W o') === static::now($this->tz)->addWeek()->format('W o'); - } - - /** - * Determines if the instance is within the last week - * - * @return bool - */ - public function isLastWeek(): bool - { - return $this->format('W o') === static::now($this->tz)->subWeek()->format('W o'); - } - - /** - * Determines if the instance is within the next month - * - * @return bool - */ - public function isNextMonth(): bool - { - return $this->format('m Y') === static::now($this->tz)->addMonth()->format('m Y'); - } - - /** - * Determines if the instance is within the last month - * - * @return bool - */ - public function isLastMonth(): bool - { - return $this->format('m Y') === static::now($this->tz)->subMonth()->format('m Y'); - } - - /** - * Determines if the instance is within the next year - * - * @return bool - */ - public function isNextYear(): bool - { - return $this->year === static::now($this->tz)->addYear()->year; - } - - /** - * Determines if the instance is within the last year - * - * @return bool - */ - public function isLastYear(): bool - { - return $this->year === static::now($this->tz)->subYear()->year; - } - - /** - * Determines if the instance is in the future, ie. greater (after) than now - * - * @return bool - */ - public function isFuture(): bool - { - return $this->gt(static::now($this->tz)); - } - - /** - * Determines if the instance is in the past, ie. less (before) than now - * - * @return bool - */ - public function isPast(): bool - { - return $this->lt(static::now($this->tz)); - } - - /** - * Determines if the instance is a leap year - * - * @return bool - */ - public function isLeapYear(): bool - { - return $this->format('L') === '1'; - } - - /** - * Checks if the passed in date is the same day as the instance current day. - * - * @param \Cake\Chronos\ChronosInterface $dt The instance to check against. - * @return bool - */ - public function isSameDay(ChronosInterface $dt): bool - { - return $this->toDateString() === $dt->toDateString(); - } - - /** - * Checks if this day is a Sunday. - * - * @return bool - */ - public function isSunday(): bool - { - return $this->dayOfWeek === ChronosInterface::SUNDAY; - } - - /** - * Checks if this day is a Monday. - * - * @return bool - */ - public function isMonday(): bool - { - return $this->dayOfWeek === ChronosInterface::MONDAY; - } - - /** - * Checks if this day is a Tuesday. - * - * @return bool - */ - public function isTuesday(): bool - { - return $this->dayOfWeek === ChronosInterface::TUESDAY; - } - - /** - * Checks if this day is a Wednesday. - * - * @return bool - */ - public function isWednesday(): bool - { - return $this->dayOfWeek === ChronosInterface::WEDNESDAY; - } - - /** - * Checks if this day is a Thursday. - * - * @return bool - */ - public function isThursday(): bool - { - return $this->dayOfWeek === ChronosInterface::THURSDAY; - } - - /** - * Checks if this day is a Friday. - * - * @return bool - */ - public function isFriday(): bool - { - return $this->dayOfWeek === ChronosInterface::FRIDAY; - } - - /** - * Checks if this day is a Saturday. - * - * @return bool - */ - public function isSaturday(): bool - { - return $this->dayOfWeek === ChronosInterface::SATURDAY; - } - - /** - * Returns true if this object represents a date within the current week - * - * @return bool - */ - public function isThisWeek(): bool - { - return static::now($this->getTimezone())->format('W o') === $this->format('W o'); - } - - /** - * Returns true if this object represents a date within the current month - * - * @return bool - */ - public function isThisMonth(): bool - { - return static::now($this->getTimezone())->format('m Y') === $this->format('m Y'); - } - - /** - * Returns true if this object represents a date within the current year - * - * @return bool - */ - public function isThisYear(): bool - { - return static::now($this->getTimezone())->format('Y') === $this->format('Y'); - } - - /** - * Check if its the birthday. Compares the date/month values of the two dates. - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to compare with or null to use current day. - * @return bool - */ - public function isBirthday(?ChronosInterface $dt = null): bool - { - $dt = $dt ?? static::now($this->tz); - - return $this->format('md') === $dt->format('md'); - } - - /** - * Returns true this instance happened within the specified interval - * - * @param string|int $timeInterval the numeric value with space then time type. - * Example of valid types: 6 hours, 2 days, 1 minute. - * @return bool - */ - public function wasWithinLast($timeInterval): bool - { - $now = new static(); - $interval = $now->copy()->modify('-' . $timeInterval); - $thisTime = $this->format('U'); - - return $thisTime >= $interval->format('U') && $thisTime <= $now->format('U'); - } - - /** - * Returns true this instance will happen within the specified interval - * - * @param string|int $timeInterval the numeric value with space then time type. - * Example of valid types: 6 hours, 2 days, 1 minute. - * @return bool - */ - public function isWithinNext($timeInterval): bool - { - $now = new static(); - $interval = $now->copy()->modify('+' . $timeInterval); - $thisTime = $this->format('U'); - - return $thisTime <= $interval->format('U') && $thisTime >= $now->format('U'); - } - - /** - * Check if instance of ChronosInterface is mutable. - * - * @return bool - */ - public function isMutable(): bool - { - return $this instanceof DateTime; - } -} diff --git a/vendor/cakephp/chronos/src/Traits/CopyTrait.php b/vendor/cakephp/chronos/src/Traits/CopyTrait.php deleted file mode 100644 index 1bd8ede42..000000000 --- a/vendor/cakephp/chronos/src/Traits/CopyTrait.php +++ /dev/null @@ -1,35 +0,0 @@ - - * @link http://cakephp.org CakePHP(tm) Project - * @license http://www.opensource.org/licenses/mit-license.php MIT License - */ -namespace Cake\Chronos\Traits; - -use Cake\Chronos\ChronosInterface; - -/** - * Provides methods for copying datetime objects. - * - * Expects that implementing classes provide a static `instance()` method. - */ -trait CopyTrait -{ - /** - * Get a copy of the instance - * - * @return static - */ - public function copy(): ChronosInterface - { - return static::instance($this); - } -} diff --git a/vendor/cakephp/chronos/src/Traits/DifferenceTrait.php b/vendor/cakephp/chronos/src/Traits/DifferenceTrait.php deleted file mode 100644 index e3f997988..000000000 --- a/vendor/cakephp/chronos/src/Traits/DifferenceTrait.php +++ /dev/null @@ -1,332 +0,0 @@ - - * @link http://cakephp.org CakePHP(tm) Project - * @license http://www.opensource.org/licenses/mit-license.php MIT License - */ -namespace Cake\Chronos\Traits; - -use Cake\Chronos\ChronosInterface; -use Cake\Chronos\ChronosInterval; -use Cake\Chronos\DifferenceFormatter; -use Cake\Chronos\DifferenceFormatterInterface; -use DatePeriod; -use DateTimeInterface; -use DateTimeZone; - -/** - * Provides methods for getting differences between datetime objects. - * - * Expects that the implementing class implements: - * - * - static::now() - * - static::instance() - * - copy() - */ -trait DifferenceTrait -{ - /** - * Instance of the diff formatting object. - * - * @var \Cake\Chronos\DifferenceFormatterInterface - */ - protected static $diffFormatter; - - /** - * Get the difference in years - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInYears(?ChronosInterface $dt = null, bool $abs = true): int - { - $diff = $this->diff($dt ?? static::now($this->tz), $abs); - - return $diff->invert ? -$diff->y : $diff->y; - } - - /** - * Get the difference in months - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInMonths(?ChronosInterface $dt = null, bool $abs = true): int - { - $diff = $this->diff($dt ?? static::now($this->tz), $abs); - $months = $diff->y * ChronosInterface::MONTHS_PER_YEAR + $diff->m; - - return $diff->invert ? -$months : $months; - } - - /** - * Get the difference in months ignoring the timezone. This means the months are calculated - * in the specified timezone without converting to UTC first. This prevents the day from changing - * which can change the month. - * - * For example, if comparing `2019-06-01 Asia/Tokyo` and `2019-10-01 Asia/Tokyo`, - * the result would be 4 months instead of 3 when using normal `DateTime::diff()`. - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInMonthsIgnoreTimezone(?ChronosInterface $dt = null, bool $abs = true): int - { - $utcTz = new DateTimeZone('UTC'); - $source = new static($this->format('Y-m-d H:i:s.u'), $utcTz); - - $dt = $dt ?? static::now($this->tz); - $dt = new static($dt->format('Y-m-d H:i:s.u'), $utcTz); - - return $source->diffInMonths($dt, $abs); - } - - /** - * Get the difference in weeks - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInWeeks(?ChronosInterface $dt = null, bool $abs = true): int - { - return (int)($this->diffInDays($dt, $abs) / ChronosInterface::DAYS_PER_WEEK); - } - - /** - * Get the difference in days - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInDays(?ChronosInterface $dt = null, bool $abs = true): int - { - $diff = $this->diff($dt ?? static::now($this->tz), $abs); - - return $diff->invert ? -$diff->days : $diff->days; - } - - /** - * Get the difference in days using a filter callable - * - * @param callable $callback The callback to use for filtering. - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInDaysFiltered(callable $callback, ?ChronosInterface $dt = null, bool $abs = true): int - { - return $this->diffFiltered(ChronosInterval::day(), $callback, $dt, $abs); - } - - /** - * Get the difference in hours using a filter callable - * - * @param callable $callback The callback to use for filtering. - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInHoursFiltered(callable $callback, ?ChronosInterface $dt = null, bool $abs = true): int - { - return $this->diffFiltered(ChronosInterval::hour(), $callback, $dt, $abs); - } - - /** - * Get the difference by the given interval using a filter callable - * - * @param \Cake\Chronos\ChronosInterval $ci An interval to traverse by - * @param callable $callback The callback to use for filtering. - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffFiltered( - ChronosInterval $ci, - callable $callback, - ?ChronosInterface $dt = null, - bool $abs = true - ): int { - $start = $this; - $end = $dt ?? static::now($this->tz); - $inverse = false; - - if ($end < $start) { - $start = $end; - $end = $this; - $inverse = true; - } - - $period = new DatePeriod($start, $ci, $end); - $vals = array_filter(iterator_to_array($period), function (DateTimeInterface $date) use ($callback) { - return $callback(static::instance($date)); - }); - - $diff = count($vals); - - return $inverse && !$abs ? -$diff : $diff; - } - - /** - * Get the difference in weekdays - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInWeekdays(?ChronosInterface $dt = null, bool $abs = true): int - { - return $this->diffInDaysFiltered(function (ChronosInterface $date) { - return $date->isWeekday(); - }, $dt, $abs); - } - - /** - * Get the difference in weekend days using a filter - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInWeekendDays(?ChronosInterface $dt = null, bool $abs = true): int - { - return $this->diffInDaysFiltered(function (ChronosInterface $date) { - return $date->isWeekend(); - }, $dt, $abs); - } - - /** - * Get the difference in hours - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInHours(?ChronosInterface $dt = null, bool $abs = true): int - { - return (int)( - $this->diffInSeconds($dt, $abs) - / ChronosInterface::SECONDS_PER_MINUTE - / ChronosInterface::MINUTES_PER_HOUR - ); - } - - /** - * Get the difference in minutes - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInMinutes(?ChronosInterface $dt = null, bool $abs = true): int - { - return (int)($this->diffInSeconds($dt, $abs) / ChronosInterface::SECONDS_PER_MINUTE); - } - - /** - * Get the difference in seconds - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to difference from. - * @param bool $abs Get the absolute of the difference - * @return int - */ - public function diffInSeconds(?ChronosInterface $dt = null, bool $abs = true): int - { - $dt = $dt ?? static::now($this->tz); - $value = $dt->getTimestamp() - $this->getTimestamp(); - - return $abs ? abs($value) : $value; - } - - /** - * The number of seconds since midnight. - * - * @return int - */ - public function secondsSinceMidnight(): int - { - return $this->diffInSeconds($this->copy()->startOfDay()); - } - - /** - * The number of seconds until 23:59:59. - * - * @return int - */ - public function secondsUntilEndOfDay(): int - { - return $this->diffInSeconds($this->copy()->endOfDay()); - } - - /** - * Convenience method for getting the remaining time from a given time. - * - * @param \DateTime|\DateTimeImmutable $datetime The date to get the remaining time from. - * @return \DateInterval|bool The DateInterval object representing the difference between the two dates or FALSE on failure. - */ - public static function fromNow($datetime) - { - $timeNow = new static(); - - return $timeNow->diff($datetime); - } - - /** - * Get the difference in a human readable format. - * - * When comparing a value in the past to default now: - * 1 hour ago - * 5 months ago - * - * When comparing a value in the future to default now: - * 1 hour from now - * 5 months from now - * - * When comparing a value in the past to another value: - * 1 hour before - * 5 months before - * - * When comparing a value in the future to another value: - * 1 hour after - * 5 months after - * - * @param \Cake\Chronos\ChronosInterface|null $other The datetime to compare with. - * @param bool $absolute removes time difference modifiers ago, after, etc - * @return string - */ - public function diffForHumans(?ChronosInterface $other = null, bool $absolute = false): string - { - return static::diffFormatter()->diffForHumans($this, $other, $absolute); - } - - /** - * Get the difference formatter instance or overwrite the current one. - * - * @param \Cake\Chronos\DifferenceFormatterInterface|null $formatter The formatter instance when setting. - * @return \Cake\Chronos\DifferenceFormatterInterface The formatter instance. - */ - public static function diffFormatter(?DifferenceFormatterInterface $formatter = null): DifferenceFormatterInterface - { - if ($formatter === null) { - if (static::$diffFormatter === null) { - static::$diffFormatter = new DifferenceFormatter(); - } - - return static::$diffFormatter; - } - - return static::$diffFormatter = $formatter; - } -} diff --git a/vendor/cakephp/chronos/src/Traits/FactoryTrait.php b/vendor/cakephp/chronos/src/Traits/FactoryTrait.php deleted file mode 100644 index 3b5fff54b..000000000 --- a/vendor/cakephp/chronos/src/Traits/FactoryTrait.php +++ /dev/null @@ -1,364 +0,0 @@ - - * @link http://cakephp.org CakePHP(tm) Project - * @license http://www.opensource.org/licenses/mit-license.php MIT License - */ -namespace Cake\Chronos\Traits; - -use Cake\Chronos\ChronosInterface; -use DateTimeInterface; -use DateTimeZone; -use InvalidArgumentException; - -/** - * Provides a number of datetime related factory methods. - */ -trait FactoryTrait -{ - /** - * Holds the last error generated by createFromFormat - * - * @var array - */ - protected static $_lastErrors = []; - - /** - * Create a ChronosInterface instance from a DateTimeInterface one - * - * @param \DateTimeInterface $dt The datetime instance to convert. - * @return static - */ - public static function instance(DateTimeInterface $dt): ChronosInterface - { - if ($dt instanceof static) { - return clone $dt; - } - - return new static($dt->format('Y-m-d H:i:s.u'), $dt->getTimezone()); - } - - /** - * Create a ChronosInterface instance from a string. This is an alias for the - * constructor that allows better fluent syntax as it allows you to do - * ChronosInterface::parse('Monday next week')->fn() rather than - * (new Chronos('Monday next week'))->fn() - * - * @param \DateTimeInterface|string|int $time The strtotime compatible string to parse - * @param \DateTimeZone|string|null $tz The DateTimeZone object or timezone name. - * @return static - */ - public static function parse($time = 'now', $tz = null): ChronosInterface - { - return new static($time, $tz); - } - - /** - * Get a ChronosInterface instance for the current date and time - * - * @param \DateTimeZone|string|null $tz The DateTimeZone object or timezone name. - * @return static - */ - public static function now($tz = null): ChronosInterface - { - return new static('now', $tz); - } - - /** - * Create a ChronosInterface instance for today - * - * @param \DateTimeZone|string|null $tz The timezone to use. - * @return static - */ - public static function today($tz = null): ChronosInterface - { - return new static('midnight', $tz); - } - - /** - * Create a ChronosInterface instance for tomorrow - * - * @param \DateTimeZone|string|null $tz The DateTimeZone object or timezone name the new instance should use. - * @return static - */ - public static function tomorrow($tz = null): ChronosInterface - { - return new static('tomorrow, midnight', $tz); - } - - /** - * Create a ChronosInterface instance for yesterday - * - * @param \DateTimeZone|string|null $tz The DateTimeZone object or timezone name the new instance should use. - * @return static - */ - public static function yesterday($tz = null): ChronosInterface - { - return new static('yesterday, midnight', $tz); - } - - /** - * Create a ChronosInterface instance for the greatest supported date. - * - * @return \Cake\Chronos\ChronosInterface - */ - public static function maxValue(): ChronosInterface - { - return static::createFromTimestampUTC(PHP_INT_MAX); - } - - /** - * Create a ChronosInterface instance for the lowest supported date. - * - * @return \Cake\Chronos\ChronosInterface - */ - public static function minValue(): ChronosInterface - { - $max = PHP_INT_SIZE === 4 ? PHP_INT_MAX : PHP_INT_MAX / 10; - - return static::createFromTimestampUTC(~$max); - } - - /** - * Create a new ChronosInterface instance from a specific date and time. - * - * If any of $year, $month or $day are set to null their now() values - * will be used. - * - * If $hour is null it will be set to its now() value and the default values - * for $minute, $second and $microsecond will be their now() values. - * If $hour is not null then the default values for $minute, $second - * and $microsecond will be 0. - * - * @param int|null $year The year to create an instance with. - * @param int|null $month The month to create an instance with. - * @param int|null $day The day to create an instance with. - * @param int|null $hour The hour to create an instance with. - * @param int|null $minute The minute to create an instance with. - * @param int|null $second The second to create an instance with. - * @param int|null $microsecond The microsecond to create an instance with. - * @param \DateTimeZone|string|null $tz The DateTimeZone object or timezone name the new instance should use. - * @return static - */ - public static function create( - ?int $year = null, - ?int $month = null, - ?int $day = null, - ?int $hour = null, - ?int $minute = null, - ?int $second = null, - ?int $microsecond = null, - $tz = null - ): ChronosInterface { - $now = static::now(); - $year = $year ?? (int)$now->format('Y'); - $month = $month ?? $now->format('m'); - $day = $day ?? $now->format('d'); - - if ($hour === null) { - $hour = $now->format('H'); - $minute = $minute ?? $now->format('i'); - $second = $second ?? $now->format('s'); - $microsecond = $microsecond ?? $now->format('u'); - } else { - $minute = $minute ?? 0; - $second = $second ?? 0; - $microsecond = $microsecond ?? 0; - } - - $instance = static::createFromFormat( - 'Y-m-d H:i:s.u', - sprintf('%s-%s-%s %s:%02s:%02s.%06s', 0, $month, $day, $hour, $minute, $second, $microsecond), - $tz - ); - - return $instance->addYears($year); - } - - /** - * Create a ChronosInterface instance from just a date. The time portion is set to now. - * - * @param int|null $year The year to create an instance with. - * @param int|null $month The month to create an instance with. - * @param int|null $day The day to create an instance with. - * @param \DateTimeZone|string|null $tz The DateTimeZone object or timezone name the new instance should use. - * @return static - */ - public static function createFromDate( - ?int $year = null, - ?int $month = null, - ?int $day = null, - $tz = null - ): ChronosInterface { - return static::create($year, $month, $day, null, null, null, null, $tz); - } - - /** - * Create a ChronosInterface instance from just a time. The date portion is set to today. - * - * @param int|null $hour The hour to create an instance with. - * @param int|null $minute The minute to create an instance with. - * @param int|null $second The second to create an instance with. - * @param int|null $microsecond The microsecond to create an instance with. - * @param \DateTimeZone|string|null $tz The DateTimeZone object or timezone name the new instance should use. - * @return static - */ - public static function createFromTime( - ?int $hour = null, - ?int $minute = null, - ?int $second = null, - ?int $microsecond = null, - $tz = null - ): ChronosInterface { - return static::create(null, null, null, $hour, $minute, $second, $microsecond, $tz); - } - - /** - * Create a ChronosInterface instance from a specific format - * - * @param string $format The date() compatible format string. - * @param string $time The formatted date string to interpret. - * @param \DateTimeZone|string|null $tz The DateTimeZone object or timezone name the new instance should use. - * @return static - * @throws \InvalidArgumentException - */ - public static function createFromFormat($format, $time, $tz = null): ChronosInterface - { - if ($tz !== null) { - $dt = parent::createFromFormat($format, $time, static::safeCreateDateTimeZone($tz)); - } else { - $dt = parent::createFromFormat($format, $time); - } - - $errors = parent::getLastErrors(); - if (!$dt) { - throw new InvalidArgumentException(implode(PHP_EOL, $errors['errors'])); - } - - $dt = new static($dt->format('Y-m-d H:i:s.u'), $dt->getTimezone()); - static::$_lastErrors = $errors; - - return $dt; - } - - /** - * Creates a ChronosInterface instance from an array of date and time values. - * - * The 'year', 'month' and 'day' values must all be set for a date. The time - * values all default to 0. - * - * The 'timezone' value can be any format supported by `\DateTimeZone`. - * - * Allowed values: - * - year - * - month - * - day - * - hour - * - minute - * - second - * - microsecond - * - meridian ('am' or 'pm') - * - timezone - * - * @param (int|string)[] $values Array of date and time values. - * @return static - */ - public static function createFromArray(array $values): ChronosInterface - { - $values += ['hour' => 0, 'minute' => 0, 'second' => 0, 'microsecond' => 0, 'timezone' => null]; - - $formatted = ''; - if ( - isset($values['year'], $values['month'], $values['day']) && - ( - is_numeric($values['year']) && - is_numeric($values['month']) && - is_numeric($values['day']) - ) - ) { - $formatted .= sprintf('%04d-%02d-%02d ', $values['year'], $values['month'], $values['day']); - } - - if (isset($values['meridian']) && (int)$values['hour'] === 12) { - $values['hour'] = 0; - } - if (isset($values['meridian'])) { - $values['hour'] = strtolower($values['meridian']) === 'am' ? $values['hour'] : $values['hour'] + 12; - } - $formatted .= sprintf( - '%02d:%02d:%02d.%06d', - $values['hour'], - $values['minute'], - $values['second'], - $values['microsecond'] - ); - - return static::parse($formatted, $values['timezone']); - } - - /** - * Create a ChronosInterface instance from a timestamp - * - * @param int $timestamp The timestamp to create an instance from. - * @param \DateTimeZone|string|null $tz The DateTimeZone object or timezone name the new instance should use. - * @return static - */ - public static function createFromTimestamp(int $timestamp, $tz = null): ChronosInterface - { - return static::now($tz)->setTimestamp($timestamp); - } - - /** - * Create a ChronosInterface instance from an UTC timestamp - * - * @param int $timestamp The UTC timestamp to create an instance from. - * @return static - */ - public static function createFromTimestampUTC(int $timestamp): ChronosInterface - { - return new static($timestamp); - } - - /** - * Creates a DateTimeZone from a string or a DateTimeZone - * - * @param \DateTimeZone|string|null $object The value to convert. - * @return \DateTimeZone - * @throws \InvalidArgumentException - */ - protected static function safeCreateDateTimeZone($object): DateTimeZone - { - if ($object === null) { - return new DateTimeZone(date_default_timezone_get()); - } - - if ($object instanceof DateTimeZone) { - return $object; - } - - return new DateTimeZone($object); - } - - /** - * Returns any errors or warnings that were found during the parsing - * of the last object created by this class. - * - * @return array - */ - public static function getLastErrors(): array - { - if (empty(static::$_lastErrors)) { - return parent::getLastErrors(); - } - - return static::$_lastErrors; - } -} diff --git a/vendor/cakephp/chronos/src/Traits/FormattingTrait.php b/vendor/cakephp/chronos/src/Traits/FormattingTrait.php deleted file mode 100644 index 61e3ba393..000000000 --- a/vendor/cakephp/chronos/src/Traits/FormattingTrait.php +++ /dev/null @@ -1,267 +0,0 @@ - - * @link http://cakephp.org CakePHP(tm) Project - * @license http://www.opensource.org/licenses/mit-license.php MIT License - */ -namespace Cake\Chronos\Traits; - -use Cake\Chronos\ChronosInterface; -use DateTime; - -/** - * Provides string formatting methods for datetime instances. - * - * Expects implementing classes to define static::$toStringFormat - */ -trait FormattingTrait -{ - /** - * Reset the format used to the default when type juggling a ChronosInterface instance to a string - * - * @return void - */ - public static function resetToStringFormat(): void - { - static::setToStringFormat(ChronosInterface::DEFAULT_TO_STRING_FORMAT); - } - - /** - * Set the default format used when type juggling a ChronosInterface instance to a string - * - * @param string $format The format to use in future __toString() calls. - * @return void - */ - public static function setToStringFormat($format): void - { - static::$toStringFormat = $format; - } - - /** - * Format the instance as a string using the set format - * - * @return string - */ - public function __toString(): string - { - return $this->format(static::$toStringFormat); - } - - /** - * Format the instance as date - * - * @return string - */ - public function toDateString(): string - { - return $this->format('Y-m-d'); - } - - /** - * Format the instance as a readable date - * - * @return string - */ - public function toFormattedDateString(): string - { - return $this->format('M j, Y'); - } - - /** - * Format the instance as time - * - * @return string - */ - public function toTimeString(): string - { - return $this->format('H:i:s'); - } - - /** - * Format the instance as date and time - * - * @return string - */ - public function toDateTimeString(): string - { - return $this->format('Y-m-d H:i:s'); - } - - /** - * Format the instance with day, date and time - * - * @return string - */ - public function toDayDateTimeString(): string - { - return $this->format('D, M j, Y g:i A'); - } - - /** - * Format the instance as ATOM - * - * @return string - */ - public function toAtomString(): string - { - return $this->format(DateTime::ATOM); - } - - /** - * Format the instance as COOKIE - * - * @return string - */ - public function toCookieString(): string - { - return $this->format(DateTime::COOKIE); - } - - /** - * Format the instance as ISO8601 - * - * @return string - */ - public function toIso8601String(): string - { - return $this->format(DateTime::ATOM); - } - - /** - * Format the instance as RFC822 - * - * @return string - * @link https://tools.ietf.org/html/rfc822 - */ - public function toRfc822String(): string - { - return $this->format(DateTime::RFC822); - } - - /** - * Format the instance as RFC850 - * - * @return string - * @link https://tools.ietf.org/html/rfc850 - */ - public function toRfc850String(): string - { - return $this->format(DateTime::RFC850); - } - - /** - * Format the instance as RFC1036 - * - * @return string - * @link https://tools.ietf.org/html/rfc1036 - */ - public function toRfc1036String(): string - { - return $this->format(DateTime::RFC1036); - } - - /** - * Format the instance as RFC1123 - * - * @return string - * @link https://tools.ietf.org/html/rfc1123 - */ - public function toRfc1123String(): string - { - return $this->format(DateTime::RFC1123); - } - - /** - * Format the instance as RFC2822 - * - * @return string - * @link https://tools.ietf.org/html/rfc2822 - */ - public function toRfc2822String(): string - { - return $this->format(DateTime::RFC2822); - } - - /** - * Format the instance as RFC3339 - * - * @return string - * @link https://tools.ietf.org/html/rfc3339 - */ - public function toRfc3339String(): string - { - return $this->format(DateTime::RFC3339); - } - - /** - * Format the instance as RSS - * - * @return string - */ - public function toRssString(): string - { - return $this->format(DateTime::RSS); - } - - /** - * Format the instance as W3C - * - * @return string - */ - public function toW3cString(): string - { - return $this->format(DateTime::W3C); - } - - /** - * Returns a UNIX timestamp. - * - * @return string UNIX timestamp - */ - public function toUnixString(): string - { - return $this->format('U'); - } - - /** - * Returns the quarter - * - * @param bool $range Range. - * @return int|array 1, 2, 3, or 4 quarter of year or array if $range true - */ - public function toQuarter(bool $range = false) - { - $quarter = (int)ceil($this->format('m') / 3); - if ($range === false) { - return $quarter; - } - - $year = $this->format('Y'); - switch ($quarter) { - case 1: - return [$year . '-01-01', $year . '-03-31']; - case 2: - return [$year . '-04-01', $year . '-06-30']; - case 3: - return [$year . '-07-01', $year . '-09-30']; - default: - return [$year . '-10-01', $year . '-12-31']; - } - } - - /** - * @inheritDoc - */ - public function toWeek(): int - { - return (int)$this->format('W'); - } -} diff --git a/vendor/cakephp/chronos/src/Traits/FrozenTimeTrait.php b/vendor/cakephp/chronos/src/Traits/FrozenTimeTrait.php deleted file mode 100644 index 1b3204118..000000000 --- a/vendor/cakephp/chronos/src/Traits/FrozenTimeTrait.php +++ /dev/null @@ -1,183 +0,0 @@ -format('Y-m-d 00:00:00'); - } - - /** - * Remove time components from strtotime relative strings. - * - * @param string $time The input expression - * @return string The output expression with no time modifiers. - */ - protected function stripRelativeTime(string $time): string - { - return preg_replace('/([-+]\s*\d+\s(?:minutes|seconds|hours|microseconds))/', '', $time); - } - - /** - * Modify the time on the Date. - * - * This method ignores all inputs and forces all inputs to 0. - * - * @param int $hours The hours to set (ignored) - * @param int $minutes The minutes to set (ignored) - * @param int $seconds The seconds to set (ignored) - * @param int $microseconds The microseconds to set (ignored) - * @return static A modified Date instance. - */ - public function setTime($hours, $minutes, $seconds = null, $microseconds = null): ChronosInterface - { - return parent::setTime(0, 0, 0, 0); - } - - /** - * Add an Interval to a Date - * - * Any changes to the time will be ignored and reset to 00:00:00 - * - * @param \DateInterval $interval The interval to modify this date by. - * @return static A modified Date instance - */ - public function add($interval): ChronosInterface - { - return parent::add($interval)->setTime(0, 0, 0); - } - - /** - * Subtract an Interval from a Date. - * - * Any changes to the time will be ignored and reset to 00:00:00 - * - * @param \DateInterval $interval The interval to modify this date by. - * @return static A modified Date instance - */ - public function sub($interval): ChronosInterface - { - return parent::sub($interval)->setTime(0, 0, 0); - } - - /** - * No-op method. - * - * Timezones have no effect on calendar dates. - * - * @param \DateTimeZone|string $value The DateTimeZone object or timezone name to use. - * @return $this - */ - public function timezone($value) - { - return $this; - } - - /** - * No-op method. - * - * Timezones have no effect on calendar dates. - * - * @param \DateTimeZone|string $value The DateTimeZone object or timezone name to use. - * @return $this - */ - public function tz($value) - { - return $this; - } - - /** - * No-op method. - * - * Timezones have no effect on calendar dates. - * - * @param \DateTimeZone|string $value The DateTimeZone object or timezone name to use. - * @return $this - */ - public function setTimezone($value) - { - return $this; - } - - /** - * Set the timestamp value and get a new object back. - * - * This method will discard the time aspects of the timestamp - * and only apply the date portions - * - * @param int $value The timestamp value to set. - * @return static - */ - public function setTimestamp($value): ChronosInterface - { - return parent::setTimestamp($value)->setTime(0, 0, 0); - } - - /** - * Overloaded to ignore time changes. - * - * Changing any aspect of the time will be ignored, and the resulting object - * will have its time frozen to 00:00:00. - * - * @param string $relative The relative change to make. - * @return static A new date with the applied date changes. - */ - public function modify($relative): ChronosInterface - { - if (preg_match('/hour|minute|second/', $relative)) { - return $this; - } - $new = parent::modify($relative); - if ($new->format('H:i:s') !== '00:00:00') { - return $new->setTime(0, 0, 0); - } - - return $new; - } -} diff --git a/vendor/cakephp/chronos/src/Traits/MagicPropertyTrait.php b/vendor/cakephp/chronos/src/Traits/MagicPropertyTrait.php deleted file mode 100644 index 7c01449a2..000000000 --- a/vendor/cakephp/chronos/src/Traits/MagicPropertyTrait.php +++ /dev/null @@ -1,138 +0,0 @@ - - * @link http://cakephp.org CakePHP(tm) Project - * @license http://www.opensource.org/licenses/mit-license.php MIT License - */ -namespace Cake\Chronos\Traits; - -use Cake\Chronos\ChronosInterface; -use InvalidArgumentException; - -/** - * Provides the magic methods that allow read access - * to magic properties. - * - * @property-read int $year - * @property-read int $yearIso - * @property-read int $month - * @property-read int $day - * @property-read int $hour - * @property-read int $minute - * @property-read int $second - * @property-read int $micro - * @property-read int $dayOfWeek - * @property-read int $dayOfYear - * @property-read int $weekOfYear - * @property-read int $daysInMonth - * @property-read int $timestamp - * @property-read int $weekOfMonth - * @property-read int $age - * @property-read int $quarter - * @property-read int $offset - * @property-read int $offsetHours - * @property-read bool $dst - * @property-read bool $local - * @property-read bool $utc - * @property-read \DateTimeZone $timezone - * @property-read \DateTimeZone $tz - * @property-read string $timezoneName - * @property-read string $tzName - * @property-read string $dayOfWeekName - */ -trait MagicPropertyTrait -{ - /** - * Get a part of the ChronosInterface object - * - * @param string $name The property name to read. - * @return string|int|bool|\DateTimeZone The property value. - * @throws \InvalidArgumentException - */ - public function __get(string $name) - { - static $formats = [ - 'year' => 'Y', - 'yearIso' => 'o', - 'month' => 'n', - 'day' => 'j', - 'hour' => 'G', - 'minute' => 'i', - 'second' => 's', - 'micro' => 'u', - 'microsecond' => 'u', - 'dayOfWeek' => 'N', - 'dayOfYear' => 'z', - 'weekOfYear' => 'W', - 'daysInMonth' => 't', - 'timestamp' => 'U', - ]; - - switch (true) { - case isset($formats[$name]): - return (int)$this->format($formats[$name]); - - case $name === 'dayOfWeekName': - return $this->format('l'); - - case $name === 'weekOfMonth': - return (int)ceil($this->day / ChronosInterface::DAYS_PER_WEEK); - - case $name === 'age': - return $this->diffInYears(); - - case $name === 'quarter': - return (int)ceil($this->month / 3); - - case $name === 'offset': - return $this->getOffset(); - - case $name === 'offsetHours': - return $this->getOffset() / ChronosInterface::SECONDS_PER_MINUTE / ChronosInterface::MINUTES_PER_HOUR; - - case $name === 'dst': - return $this->format('I') === '1'; - - case $name === 'local': - return $this->offset === $this->copy()->setTimezone(date_default_timezone_get())->offset; - - case $name === 'utc': - return $this->offset === 0; - - case $name === 'timezone' || $name === 'tz': - return $this->getTimezone(); - - case $name === 'timezoneName' || $name === 'tzName': - return $this->getTimezone()->getName(); - - default: - throw new InvalidArgumentException(sprintf("Unknown getter '%s'", $name)); - } - } - - /** - * Check if an attribute exists on the object - * - * @param string $name The property name to check. - * @return bool Whether or not the property exists. - */ - public function __isset(string $name): bool - { - try { - $this->__get($name); - } catch (InvalidArgumentException $e) { - return false; - } - - return true; - } -} diff --git a/vendor/cakephp/chronos/src/Traits/ModifierTrait.php b/vendor/cakephp/chronos/src/Traits/ModifierTrait.php deleted file mode 100644 index e53169d80..000000000 --- a/vendor/cakephp/chronos/src/Traits/ModifierTrait.php +++ /dev/null @@ -1,1126 +0,0 @@ - - * @link http://cakephp.org CakePHP(tm) Project - * @license http://www.opensource.org/licenses/mit-license.php MIT License - */ -namespace Cake\Chronos\Traits; - -use Cake\Chronos\ChronosInterface; - -/** - * Provides a suite of modifier methods. - * - * These methods let you modify the various aspects - * of a DateTime with a series of fluent methods. - * - * This trait expects that the implementing class - * also implements a copy() method. This method can be obtained - * using the CopyTrait. - */ -trait ModifierTrait -{ - /** - * Names of days of the week. - * - * @var array - */ - protected static $days = [ - ChronosInterface::MONDAY => 'Monday', - ChronosInterface::TUESDAY => 'Tuesday', - ChronosInterface::WEDNESDAY => 'Wednesday', - ChronosInterface::THURSDAY => 'Thursday', - ChronosInterface::FRIDAY => 'Friday', - ChronosInterface::SATURDAY => 'Saturday', - ChronosInterface::SUNDAY => 'Sunday', - ]; - - /** - * First day of week - * - * @var int - */ - protected static $weekStartsAt = ChronosInterface::MONDAY; - - /** - * Last day of week - * - * @var int - */ - protected static $weekEndsAt = ChronosInterface::SUNDAY; - - /** - * Get the first day of week - * - * @return int - */ - public static function getWeekStartsAt(): int - { - return static::$weekStartsAt; - } - - /** - * Set the first day of week - * - * @param int $day The day the week starts with. - * @return void - */ - public static function setWeekStartsAt(int $day): void - { - static::$weekStartsAt = $day; - } - - /** - * Get the last day of week - * - * @return int - */ - public static function getWeekEndsAt(): int - { - return static::$weekEndsAt; - } - - /** - * Set the last day of week - * - * @param int $day The day the week ends with. - * @return void - */ - public static function setWeekEndsAt(int $day): void - { - static::$weekEndsAt = $day; - } - - /** - * Set the date to a different date. - * - * Workaround for a PHP bug related to the first day of a month - * - * @param int $year The year to set. - * @param int $month The month to set. - * @param int $day The day to set. - * @return static - */ - public function setDate($year, $month, $day): ChronosInterface - { - return $this->modify('+0 day')->setDateParent($year, $month, $day); - } - - /** - * Just calling to parent setDate - * It used in overwritten setDate - * - * @param int $year The year to set. - * @param int $month The month to set. - * @param int $day The day to set. - * @return static - */ - private function setDateParent(int $year, int $month, int $day): ChronosInterface - { - return parent::setDate($year, $month, $day); - } - - /** - * Set the date and time all together - * - * @param int $year The year to set. - * @param int $month The month to set. - * @param int $day The day to set. - * @param int $hour The hour to set. - * @param int $minute The minute to set. - * @param int $second The second to set. - * @return static - */ - public function setDateTime( - int $year, - int $month, - int $day, - int $hour, - int $minute, - int $second = 0 - ): ChronosInterface { - return $this->setDate($year, $month, $day)->setTime($hour, $minute, $second); - } - - /** - * Set the time by time string - * - * @param string $time Time as string. - * @return static - */ - public function setTimeFromTimeString(string $time): ChronosInterface - { - $time = explode(':', $time); - $hour = $time[0]; - $minute = $time[1] ?? 0; - $second = $time[2] ?? 0; - - return $this->setTime((int)$hour, (int)$minute, (int)$second); - } - - /** - * Set the instance's timestamp - * - * @param int $value The timestamp value to set. - * @return static - */ - public function timestamp(int $value): ChronosInterface - { - return $this->setTimestamp($value); - } - - /** - * Set the instance's year - * - * @param int $value The year value. - * @return static - */ - public function year(int $value): ChronosInterface - { - return $this->setDate($value, $this->month, $this->day); - } - - /** - * Set the instance's month - * - * @param int $value The month value. - * @return static - */ - public function month(int $value): ChronosInterface - { - return $this->setDate($this->year, $value, $this->day); - } - - /** - * Set the instance's day - * - * @param int $value The day value. - * @return static - */ - public function day(int $value): ChronosInterface - { - return $this->setDate($this->year, $this->month, $value); - } - - /** - * Set the instance's hour - * - * @param int $value The hour value. - * @return static - */ - public function hour(int $value): ChronosInterface - { - return $this->setTime($value, $this->minute, $this->second); - } - - /** - * Set the instance's minute - * - * @param int $value The minute value. - * @return static - */ - public function minute(int $value): ChronosInterface - { - return $this->setTime($this->hour, $value, $this->second); - } - - /** - * Set the instance's second - * - * @param int $value The seconds value. - * @return static - */ - public function second(int $value): ChronosInterface - { - return $this->setTime($this->hour, $this->minute, $value); - } - - /** - * Add years to the instance. Positive $value travel forward while - * negative $value travel into the past. - * - * If the new date does not exist, the last day of the month is used - * instead instead of overflowing into the next month. - * - * ### Example: - * - * ``` - * (new Chronos('2015-01-03'))->addYears(1); // Results in 2016-01-03 - * - * (new Chronos('2012-02-29'))->addYears(1); // Results in 2013-02-28 - * ``` - * - * @param int $value The number of years to add. - * @return static - */ - public function addYears(int $value): ChronosInterface - { - $month = $this->month; - $date = $this->modify($value . ' year'); - - if ($date->month !== $month) { - return $date->modify('last day of previous month'); - } - - return $date; - } - - /** - * Add a year to the instance. - * - * Has the same behavior as `addYears()`. - * - * @param int $value The number of years to add. - * @return static - */ - public function addYear(int $value = 1): ChronosInterface - { - return $this->addYears($value); - } - - /** - * Remove years from the instance. - * - * Has the same behavior as `addYears()`. - * - * @param int $value The number of years to remove. - * @return static - */ - public function subYears(int $value): ChronosInterface - { - return $this->addYears(-1 * $value); - } - - /** - * Remove a year from the instance - * - * Has the same behavior as `addYears()`. - * - * @param int $value The number of years to remove. - * @return static - */ - public function subYear(int $value = 1): ChronosInterface - { - return $this->subYears($value); - } - - /** - * Add years with overflowing to the instance. Positive $value - * travels forward while negative $value travels into the past. - * - * If the new date does not exist, the days overflow into the next month. - * - * ### Example: - * - * ``` - * (new Chronos('2012-02-29'))->addYearsWithOverflow(1); // Results in 2013-03-01 - * ``` - * - * @param int $value The number of years to add. - * @return static - */ - public function addYearsWithOverflow(int $value): ChronosInterface - { - return $this->modify($value . ' year'); - } - - /** - * Add a year with overflow to the instance. - * - * Has the same behavior as `addYearsWithOverflow()`. - * - * @param int $value The number of years to add. - * @return static - */ - public function addYearWithOverflow(int $value = 1): ChronosInterface - { - return $this->addYearsWithOverflow($value); - } - - /** - * Remove years with overflow from the instance - * - * Has the same behavior as `addYeasrWithOverflow()`. - * - * @param int $value The number of years to remove. - * @return static - */ - public function subYearsWithOverflow(int $value): ChronosInterface - { - return $this->addYearsWithOverflow(-1 * $value); - } - - /** - * Remove a year with overflow from the instance. - * - * Has the same behavior as `addYearsWithOverflow()`. - * - * @param int $value The number of years to remove. - * @return static - */ - public function subYearWithOverflow(int $value = 1): ChronosInterface - { - return $this->subYearsWithOverflow($value); - } - - /** - * Add months to the instance. Positive $value travels forward while - * negative $value travels into the past. - * - * When adding or subtracting months, if the resulting time is a date - * that does not exist, the result of this operation will always be the - * last day of the intended month. - * - * ### Example: - * - * ``` - * (new Chronos('2015-01-03'))->addMonths(1); // Results in 2015-02-03 - * - * (new Chronos('2015-01-31'))->addMonths(1); // Results in 2015-02-28 - * ``` - * - * @param int $value The number of months to add. - * @return static - */ - public function addMonths(int $value): ChronosInterface - { - $day = $this->day; - $date = $this->modify($value . ' month'); - - if ($date->day !== $day) { - return $date->modify('last day of previous month'); - } - - return $date; - } - - /** - * Add a month to the instance - * - * Has the same behavior as `addMonths()`. - * - * @param int $value The number of months to add. - * @return static - */ - public function addMonth(int $value = 1): ChronosInterface - { - return $this->addMonths($value); - } - - /** - * Remove a month from the instance - * - * Has the same behavior as `addMonths()`. - * - * @param int $value The number of months to remove. - * @return static - */ - public function subMonth(int $value = 1): ChronosInterface - { - return $this->subMonths($value); - } - - /** - * Remove months from the instance - * - * Has the same behavior as `addMonths()`. - * - * @param int $value The number of months to remove. - * @return static - */ - public function subMonths(int $value): ChronosInterface - { - return $this->addMonths(-1 * $value); - } - - /** - * Add months with overflowing to the instance. Positive $value - * travels forward while negative $value travels into the past. - * - * If the new date does not exist, the days overflow into the next month. - * - * ### Example: - * - * ``` - * (new Chronos('2012-01-30'))->addMonthsWithOverflow(1); // Results in 2013-03-01 - * ``` - * - * @param int $value The number of months to add. - * @return static - */ - public function addMonthsWithOverflow(int $value): ChronosInterface - { - return $this->modify($value . ' month'); - } - - /** - * Add a month with overflow to the instance. - * - * Has the same behavior as `addMonthsWithOverflow()`. - * - * @param int $value The number of months to add. - * @return static - */ - public function addMonthWithOverflow(int $value = 1): ChronosInterface - { - return $this->modify($value . ' month'); - } - - /** - * Remove months with overflow from the instance. - * - * Has the same behavior as `addMonthsWithOverflow()`. - * - * @param int $value The number of months to remove. - * @return static - */ - public function subMonthsWithOverflow(int $value): ChronosInterface - { - return $this->addMonthsWithOverflow(-1 * $value); - } - - /** - * Remove a month with overflow from the instance. - * - * Has the same behavior as `addMonthsWithOverflow()`. - * - * @param int $value The number of months to remove. - * @return static - */ - public function subMonthWithOverflow(int $value = 1): ChronosInterface - { - return $this->subMonthsWithOverflow($value); - } - - /** - * Add days to the instance. Positive $value travels forward while - * negative $value travels into the past. - * - * @param int $value The number of days to add. - * @return static - */ - public function addDays(int $value): ChronosInterface - { - return $this->modify("$value day"); - } - - /** - * Add a day to the instance - * - * @param int $value The number of days to add. - * @return static - */ - public function addDay(int $value = 1): ChronosInterface - { - return $this->modify("$value day"); - } - - /** - * Remove a day from the instance - * - * @param int $value The number of days to remove. - * @return static - */ - public function subDay(int $value = 1): ChronosInterface - { - return $this->modify("-$value day"); - } - - /** - * Remove days from the instance - * - * @param int $value The number of days to remove. - * @return static - */ - public function subDays(int $value): ChronosInterface - { - return $this->modify("-$value day"); - } - - /** - * Add weekdays to the instance. Positive $value travels forward while - * negative $value travels into the past. - * - * @param int $value The number of weekdays to add. - * @return static - */ - public function addWeekdays(int $value): ChronosInterface - { - return $this->modify((int)$value . ' weekdays ' . $this->format('H:i:s')); - } - - /** - * Add a weekday to the instance - * - * @param int $value The number of weekdays to add. - * @return static - */ - public function addWeekday(int $value = 1): ChronosInterface - { - return $this->addWeekdays($value); - } - - /** - * Remove weekdays from the instance - * - * @param int $value The number of weekdays to remove. - * @return static - */ - public function subWeekdays(int $value): ChronosInterface - { - return $this->modify("$value weekdays ago, " . $this->format('H:i:s')); - } - - /** - * Remove a weekday from the instance - * - * @param int $value The number of weekdays to remove. - * @return static - */ - public function subWeekday(int $value = 1): ChronosInterface - { - return $this->subWeekdays($value); - } - - /** - * Add weeks to the instance. Positive $value travels forward while - * negative $value travels into the past. - * - * @param int $value The number of weeks to add. - * @return static - */ - public function addWeeks(int $value): ChronosInterface - { - return $this->modify("$value week"); - } - - /** - * Add a week to the instance - * - * @param int $value The number of weeks to add. - * @return static - */ - public function addWeek(int $value = 1): ChronosInterface - { - return $this->modify("$value week"); - } - - /** - * Remove a week from the instance - * - * @param int $value The number of weeks to remove. - * @return static - */ - public function subWeek(int $value = 1): ChronosInterface - { - return $this->modify("-$value week"); - } - - /** - * Remove weeks to the instance - * - * @param int $value The number of weeks to remove. - * @return static - */ - public function subWeeks(int $value): ChronosInterface - { - return $this->modify("-$value week"); - } - - /** - * Add hours to the instance. Positive $value travels forward while - * negative $value travels into the past. - * - * @param int $value The number of hours to add. - * @return static - */ - public function addHours(int $value): ChronosInterface - { - return $this->modify("$value hour"); - } - - /** - * Add an hour to the instance - * - * @param int $value The number of hours to add. - * @return static - */ - public function addHour(int $value = 1): ChronosInterface - { - return $this->modify("$value hour"); - } - - /** - * Remove an hour from the instance - * - * @param int $value The number of hours to remove. - * @return static - */ - public function subHour(int $value = 1): ChronosInterface - { - return $this->modify("-$value hour"); - } - - /** - * Remove hours from the instance - * - * @param int $value The number of hours to remove. - * @return static - */ - public function subHours(int $value): ChronosInterface - { - return $this->modify("-$value hour"); - } - - /** - * Add minutes to the instance. Positive $value travels forward while - * negative $value travels into the past. - * - * @param int $value The number of minutes to add. - * @return static - */ - public function addMinutes(int $value): ChronosInterface - { - return $this->modify("$value minute"); - } - - /** - * Add a minute to the instance - * - * @param int $value The number of minutes to add. - * @return static - */ - public function addMinute(int $value = 1): ChronosInterface - { - return $this->modify("$value minute"); - } - - /** - * Remove a minute from the instance - * - * @param int $value The number of minutes to remove. - * @return static - */ - public function subMinute(int $value = 1): ChronosInterface - { - return $this->modify("-$value minute"); - } - - /** - * Remove minutes from the instance - * - * @param int $value The number of minutes to remove. - * @return static - */ - public function subMinutes(int $value): ChronosInterface - { - return $this->modify("-$value minute"); - } - - /** - * Add seconds to the instance. Positive $value travels forward while - * negative $value travels into the past. - * - * @param int $value The number of seconds to add. - * @return static - */ - public function addSeconds(int $value): ChronosInterface - { - return $this->modify("$value second"); - } - - /** - * Add a second to the instance - * - * @param int $value The number of seconds to add. - * @return static - */ - public function addSecond(int $value = 1): ChronosInterface - { - return $this->modify("$value second"); - } - - /** - * Remove a second from the instance - * - * @param int $value The number of seconds to remove. - * @return static - */ - public function subSecond(int $value = 1): ChronosInterface - { - return $this->modify("-$value second"); - } - - /** - * Remove seconds from the instance - * - * @param int $value The number of seconds to remove. - * @return static - */ - public function subSeconds(int $value): ChronosInterface - { - return $this->modify("-$value second"); - } - - /** - * Resets the time to 00:00:00 - * - * @return static - */ - public function startOfDay(): ChronosInterface - { - return $this->modify('midnight'); - } - - /** - * Resets the time to 23:59:59 - * - * @return static - */ - public function endOfDay(): ChronosInterface - { - return $this->modify('23:59:59'); - } - - /** - * Resets the date to the first day of the month and the time to 00:00:00 - * - * @return static - */ - public function startOfMonth(): ChronosInterface - { - return $this->modify('first day of this month midnight'); - } - - /** - * Resets the date to end of the month and time to 23:59:59 - * - * @return static - */ - public function endOfMonth(): ChronosInterface - { - return $this->modify('last day of this month, 23:59:59'); - } - - /** - * Resets the date to the first day of the year and the time to 00:00:00 - * - * @return static - */ - public function startOfYear(): ChronosInterface - { - return $this->modify('first day of january midnight'); - } - - /** - * Resets the date to end of the year and time to 23:59:59 - * - * @return static - */ - public function endOfYear(): ChronosInterface - { - return $this->modify('last day of december, 23:59:59'); - } - - /** - * Resets the date to the first day of the decade and the time to 00:00:00 - * - * @return static - */ - public function startOfDecade(): ChronosInterface - { - $year = $this->year - $this->year % ChronosInterface::YEARS_PER_DECADE; - - return $this->modify("first day of january $year, midnight"); - } - - /** - * Resets the date to end of the decade and time to 23:59:59 - * - * @return static - */ - public function endOfDecade(): ChronosInterface - { - $year = $this->year - $this->year % ChronosInterface::YEARS_PER_DECADE + ChronosInterface::YEARS_PER_DECADE - 1; - - return $this->modify("last day of december $year, 23:59:59"); - } - - /** - * Resets the date to the first day of the century and the time to 00:00:00 - * - * @return static - */ - public function startOfCentury(): ChronosInterface - { - $year = $this->startOfYear() - ->year($this->year - 1 - ($this->year - 1) % ChronosInterface::YEARS_PER_CENTURY + 1) - ->year; - - return $this->modify("first day of january $year, midnight"); - } - - /** - * Resets the date to end of the century and time to 23:59:59 - * - * @return static - */ - public function endOfCentury(): ChronosInterface - { - $y = $this->year - 1 - - ($this->year - 1) - % ChronosInterface::YEARS_PER_CENTURY - + ChronosInterface::YEARS_PER_CENTURY; - - $year = $this->endOfYear() - ->year($y) - ->year; - - return $this->modify("last day of december $year, 23:59:59"); - } - - /** - * Resets the date to the first day of week (defined in $weekStartsAt) and the time to 00:00:00 - * - * @return static - */ - public function startOfWeek(): ChronosInterface - { - $dt = $this; - if ($dt->dayOfWeek !== static::$weekStartsAt) { - $dt = $dt->previous(static::$weekStartsAt); - } - - return $dt->startOfDay(); - } - - /** - * Resets the date to end of week (defined in $weekEndsAt) and time to 23:59:59 - * - * @return static - */ - public function endOfWeek(): ChronosInterface - { - $dt = $this; - if ($dt->dayOfWeek !== static::$weekEndsAt) { - $dt = $dt->next(static::$weekEndsAt); - } - - return $dt->endOfDay(); - } - - /** - * Modify to the next occurrence of a given day of the week. - * If no dayOfWeek is provided, modify to the next occurrence - * of the current day of the week. Use the supplied consts - * to indicate the desired dayOfWeek, ex. ChronosInterface::MONDAY. - * - * @param int|null $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function next(?int $dayOfWeek = null) - { - if ($dayOfWeek === null) { - $dayOfWeek = $this->dayOfWeek; - } - - $day = static::$days[$dayOfWeek]; - - return $this->modify("next $day, midnight"); - } - - /** - * Modify to the previous occurrence of a given day of the week. - * If no dayOfWeek is provided, modify to the previous occurrence - * of the current day of the week. Use the supplied consts - * to indicate the desired dayOfWeek, ex. ChronosInterface::MONDAY. - * - * @param int|null $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function previous(?int $dayOfWeek = null) - { - if ($dayOfWeek === null) { - $dayOfWeek = $this->dayOfWeek; - } - - $day = static::$days[$dayOfWeek]; - - return $this->modify("last $day, midnight"); - } - - /** - * Modify to the first occurrence of a given day of the week - * in the current month. If no dayOfWeek is provided, modify to the - * first day of the current month. Use the supplied consts - * to indicate the desired dayOfWeek, ex. ChronosInterface::MONDAY. - * - * @param int|null $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function firstOfMonth(?int $dayOfWeek = null) - { - $day = $dayOfWeek === null ? 'day' : static::$days[$dayOfWeek]; - - return $this->modify("first $day of this month, midnight"); - } - - /** - * Modify to the last occurrence of a given day of the week - * in the current month. If no dayOfWeek is provided, modify to the - * last day of the current month. Use the supplied consts - * to indicate the desired dayOfWeek, ex. ChronosInterface::MONDAY. - * - * @param int|null $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function lastOfMonth(?int $dayOfWeek = null) - { - $day = $dayOfWeek === null ? 'day' : static::$days[$dayOfWeek]; - - return $this->modify("last $day of this month, midnight"); - } - - /** - * Modify to the given occurrence of a given day of the week - * in the current month. If the calculated occurrence is outside the scope - * of the current month, then return false and no modifications are made. - * Use the supplied consts to indicate the desired dayOfWeek, ex. ChronosInterface::MONDAY. - * - * @param int $nth The offset to use. - * @param int $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function nthOfMonth(int $nth, int $dayOfWeek) - { - $dt = $this->copy()->firstOfMonth(); - $check = $dt->format('Y-m'); - $dt = $dt->modify("+$nth " . static::$days[$dayOfWeek]); - - return $dt->format('Y-m') === $check ? $dt : false; - } - - /** - * Modify to the first occurrence of a given day of the week - * in the current quarter. If no dayOfWeek is provided, modify to the - * first day of the current quarter. Use the supplied consts - * to indicate the desired dayOfWeek, ex. ChronosInterface::MONDAY. - * - * @param int|null $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function firstOfQuarter(?int $dayOfWeek = null) - { - return $this - ->day(1) - ->month($this->quarter * ChronosInterface::MONTHS_PER_QUARTER - 2) - ->firstOfMonth($dayOfWeek); - } - - /** - * Modify to the last occurrence of a given day of the week - * in the current quarter. If no dayOfWeek is provided, modify to the - * last day of the current quarter. Use the supplied consts - * to indicate the desired dayOfWeek, ex. ChronosInterface::MONDAY. - * - * @param int|null $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function lastOfQuarter(?int $dayOfWeek = null) - { - return $this - ->day(1) - ->month($this->quarter * ChronosInterface::MONTHS_PER_QUARTER) - ->lastOfMonth($dayOfWeek); - } - - /** - * Modify to the given occurrence of a given day of the week - * in the current quarter. If the calculated occurrence is outside the scope - * of the current quarter, then return false and no modifications are made. - * Use the supplied consts to indicate the desired dayOfWeek, ex. ChronosInterface::MONDAY. - * - * @param int $nth The offset to use. - * @param int $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function nthOfQuarter(int $nth, int $dayOfWeek) - { - $dt = $this->copy()->day(1)->month($this->quarter * ChronosInterface::MONTHS_PER_QUARTER); - $lastMonth = $dt->month; - $year = $dt->year; - $dt = $dt->firstOfQuarter()->modify("+$nth" . static::$days[$dayOfWeek]); - - return $lastMonth < $dt->month || $year !== $dt->year ? false : $dt; - } - - /** - * Modify to the first occurrence of a given day of the week - * in the current year. If no dayOfWeek is provided, modify to the - * first day of the current year. Use the supplied consts - * to indicate the desired dayOfWeek, ex. ChronosInterface::MONDAY. - * - * @param int|null $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function firstOfYear(?int $dayOfWeek = null) - { - $day = $dayOfWeek === null ? 'day' : static::$days[$dayOfWeek]; - - return $this->modify("first $day of january, midnight"); - } - - /** - * Modify to the last occurrence of a given day of the week - * in the current year. If no dayOfWeek is provided, modify to the - * last day of the current year. Use the supplied consts - * to indicate the desired dayOfWeek, ex. ChronosInterface::MONDAY. - * - * @param int|null $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function lastOfYear(?int $dayOfWeek = null) - { - $day = $dayOfWeek === null ? 'day' : static::$days[$dayOfWeek]; - - return $this->modify("last $day of december, midnight"); - } - - /** - * Modify to the given occurrence of a given day of the week - * in the current year. If the calculated occurrence is outside the scope - * of the current year, then return false and no modifications are made. - * Use the supplied consts to indicate the desired dayOfWeek, ex. ChronosInterface::MONDAY. - * - * @param int $nth The offset to use. - * @param int $dayOfWeek The day of the week to move to. - * @return mixed - */ - public function nthOfYear(int $nth, int $dayOfWeek) - { - $dt = $this->copy()->firstOfYear()->modify("+$nth " . static::$days[$dayOfWeek]); - - return $this->year === $dt->year ? $dt : false; - } - - /** - * Modify the current instance to the average of a given instance (default now) and the current instance. - * - * @param \Cake\Chronos\ChronosInterface|null $dt The instance to compare with. - * @return static - */ - public function average(?ChronosInterface $dt = null): ChronosInterface - { - $dt = $dt ?? static::now($this->tz); - - return $this->addSeconds((int)($this->diffInSeconds($dt, false) / 2)); - } -} diff --git a/vendor/cakephp/chronos/src/Traits/RelativeKeywordTrait.php b/vendor/cakephp/chronos/src/Traits/RelativeKeywordTrait.php deleted file mode 100644 index c98e92796..000000000 --- a/vendor/cakephp/chronos/src/Traits/RelativeKeywordTrait.php +++ /dev/null @@ -1,85 +0,0 @@ - - * @link http://cakephp.org CakePHP(tm) Project - * @license http://www.opensource.org/licenses/mit-license.php MIT License - */ -namespace Cake\Chronos\Traits; - -/** - * Provides methods for testing if strings contain relative keywords. - */ -trait RelativeKeywordTrait -{ - /** - * Regex for relative period. - * - * @var string - */ - protected static $relativePattern = '/this|next|last|tomorrow|yesterday|midnight|today|[+-]|first|last|ago/i'; - - /** - * Determine if there is just a time in the time string - * - * @param string $time The time string to check. - * @return bool true if there is a keyword, otherwise false - */ - private static function isTimeExpression($time) - { - // Just a time - if (is_string($time) && preg_match('/^[0-2]?[0-9]:[0-5][0-9](?::[0-5][0-9](?:\.[0-9]{1,6})?)?$/', $time)) { - return true; - } - - return false; - } - - /** - * Determine if there is a relative keyword in the time string, this is to - * create dates relative to now for test instances. e.g.: next tuesday - * - * @param string|null $time The time string to check. - * @return bool true if there is a keyword, otherwise false - */ - public static function hasRelativeKeywords(?string $time): bool - { - if (self::isTimeExpression($time)) { - return true; - } - // skip common format with a '-' in it - if ($time && preg_match('/[0-9]{4}-[0-9]{1,2}-[0-9]{1,2}/', $time) !== 1) { - return preg_match(static::$relativePattern, $time) > 0; - } - - return false; - } - - /** - * Determines if there is no fixed date in the time string. - * - * @param \DateTimeInterface|string|null $time The time string to check - * @return bool true if doesn't contain a fixed date - */ - private static function isRelativeOnly($time): bool - { - if ($time === null) { - return true; - } - - if (!is_string($time)) { - return false; - } - - // must not contain fixed date before relative keywords or time expression - return preg_match('/[0-9]{4}-[0-9]{1,2}-[0-9]{1,2}/', $time) !== 1; - } -} diff --git a/vendor/cakephp/chronos/src/Traits/TestingAidTrait.php b/vendor/cakephp/chronos/src/Traits/TestingAidTrait.php deleted file mode 100644 index ab2fef877..000000000 --- a/vendor/cakephp/chronos/src/Traits/TestingAidTrait.php +++ /dev/null @@ -1,60 +0,0 @@ - - * @link http://cakephp.org CakePHP(tm) Project - * @license http://www.opensource.org/licenses/mit-license.php MIT License - */ -namespace Cake\Chronos\Traits; - -use Cake\Chronos\Chronos; -use Cake\Chronos\ChronosInterface; - -/** - * Provides methods for setting a 'test' now. This lets you - * retrieve pre-determined times with now(). - */ -trait TestingAidTrait -{ - /** - * Set the test now used by Date and Time classes provided by Chronos - * - * @see \Cake\Chronos\Chronos::setTestNow() - * @param \Cake\Chronos\ChronosInterface|string|null $testNow The instance to use for all future instances. - * @return void - */ - public static function setTestNow($testNow = null): void - { - Chronos::setTestNow($testNow); - } - - /** - * Get the test instance stored in Chronos - * - * @see \Cake\Chronos\Chronos::getTestNow() - * @return \Cake\Chronos\ChronosInterface|null the current instance used for testing or null. - */ - public static function getTestNow(): ?ChronosInterface - { - return Chronos::getTestNow(); - } - - /** - * Get whether or not Chronos has a test instance set. - * - * @see \Cake\Chronos\Chronos::hasTestNow() - * @return bool True if there is a test instance, otherwise false - */ - public static function hasTestNow(): bool - { - return Chronos::hasTestNow(); - } -} diff --git a/vendor/cakephp/chronos/src/Traits/TimezoneTrait.php b/vendor/cakephp/chronos/src/Traits/TimezoneTrait.php deleted file mode 100644 index 633ef1343..000000000 --- a/vendor/cakephp/chronos/src/Traits/TimezoneTrait.php +++ /dev/null @@ -1,57 +0,0 @@ - - * @link http://cakephp.org CakePHP(tm) Project - * @license http://www.opensource.org/licenses/mit-license.php MIT License - */ -namespace Cake\Chronos\Traits; - -use Cake\Chronos\ChronosInterface; - -/** - * Methods for modifying/reading timezone data. - */ -trait TimezoneTrait -{ - /** - * Alias for setTimezone() - * - * @param \DateTimeZone|string $value The DateTimeZone object or timezone name to use. - * @return static - */ - public function timezone($value): ChronosInterface - { - return $this->setTimezone($value); - } - - /** - * Alias for setTimezone() - * - * @param \DateTimeZone|string $value The DateTimeZone object or timezone name to use. - * @return static - */ - public function tz($value): ChronosInterface - { - return $this->setTimezone($value); - } - - /** - * Set the instance's timezone from a string or object - * - * @param \DateTimeZone|string $value The DateTimeZone object or timezone name to use. - * @return static - */ - public function setTimezone($value): ChronosInterface - { - return parent::setTimezone(static::safeCreateDateTimeZone($value)); - } -} diff --git a/vendor/cakephp/chronos/src/Translator.php b/vendor/cakephp/chronos/src/Translator.php deleted file mode 100644 index 382bfd484..000000000 --- a/vendor/cakephp/chronos/src/Translator.php +++ /dev/null @@ -1,95 +0,0 @@ - '1 year', - 'year_plural' => '{count} years', - 'month' => '1 month', - 'month_plural' => '{count} months', - 'week' => '1 week', - 'week_plural' => '{count} weeks', - 'day' => '1 day', - 'day_plural' => '{count} days', - 'hour' => '1 hour', - 'hour_plural' => '{count} hours', - 'minute' => '1 minute', - 'minute_plural' => '{count} minutes', - 'second' => '1 second', - 'second_plural' => '{count} seconds', - 'ago' => '{time} ago', - 'from_now' => '{time} from now', - 'after' => '{time} after', - 'before' => '{time} before', - ]; - - /** - * Check if a translation key exists. - * - * @param string $key The key to check. - * @return bool Whether or not the key exists. - */ - public function exists(string $key): bool - { - return isset(static::$strings[$key]); - } - - /** - * Get a plural message. - * - * @param string $key The key to use. - * @param int $count The number of items in the translation. - * @param array $vars Additional context variables. - * @return string The translated message or ''. - */ - public function plural(string $key, int $count, array $vars = []): string - { - if ($count === 1) { - return $this->singular($key, $vars); - } - - return $this->singular($key . '_plural', ['count' => $count] + $vars); - } - - /** - * Get a singular message. - * - * @param string $key The key to use. - * @param array $vars Additional context variables. - * @return string The translated message or ''. - */ - public function singular(string $key, array $vars = []): string - { - if (isset(static::$strings[$key])) { - $varKeys = array_keys($vars); - foreach ($varKeys as $i => $k) { - $varKeys[$i] = '{' . $k . '}'; - } - - return str_replace($varKeys, $vars, static::$strings[$key]); - } - - return ''; - } -} diff --git a/vendor/cakephp/chronos/src/carbon_compat.php b/vendor/cakephp/chronos/src/carbon_compat.php deleted file mode 100644 index 0d8eff724..000000000 --- a/vendor/cakephp/chronos/src/carbon_compat.php +++ /dev/null @@ -1,23 +0,0 @@ - - * @link http://cakephp.org CakePHP(tm) Project - * @license http://www.opensource.org/licenses/mit-license.php MIT License - */ - -// Check if the interface alias exists and don't redeclare it in case we are in -// a preloaded context. -if (!\class_exists('Carbon\Carbon') && !\interface_exists('Carbon\CarbonInterface', false)) { - // Create class aliases for Carbon so applications - // can upgrade more easily. - class_alias('Cake\Chronos\Chronos', 'Carbon\MutableDateTime'); - class_alias('Cake\Chronos\ChronosInterface', 'Carbon\CarbonInterface'); -} diff --git a/vendor/composer/ClassLoader.php b/vendor/composer/ClassLoader.php index 1a58957d2..247294d66 100644 --- a/vendor/composer/ClassLoader.php +++ b/vendor/composer/ClassLoader.php @@ -42,6 +42,8 @@ namespace Composer\Autoload; */ class ClassLoader { + private $vendorDir; + // PSR-4 private $prefixLengthsPsr4 = array(); private $prefixDirsPsr4 = array(); @@ -57,6 +59,13 @@ class ClassLoader private $missingClasses = array(); private $apcuPrefix; + private static $registeredLoaders = array(); + + public function __construct($vendorDir = null) + { + $this->vendorDir = $vendorDir; + } + public function getPrefixes() { if (!empty($this->prefixesPsr0)) { @@ -300,6 +309,17 @@ class ClassLoader public function register($prepend = false) { spl_autoload_register(array($this, 'loadClass'), true, $prepend); + + if (null === $this->vendorDir) { + return; + } + + if ($prepend) { + self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; + } else { + unset(self::$registeredLoaders[$this->vendorDir]); + self::$registeredLoaders[$this->vendorDir] = $this; + } } /** @@ -308,6 +328,10 @@ class ClassLoader public function unregister() { spl_autoload_unregister(array($this, 'loadClass')); + + if (null !== $this->vendorDir) { + unset(self::$registeredLoaders[$this->vendorDir]); + } } /** @@ -367,6 +391,16 @@ class ClassLoader return $file; } + /** + * Returns the currently registered loaders indexed by their corresponding vendor directories. + * + * @return self[] + */ + public static function getRegisteredLoaders() + { + return self::$registeredLoaders; + } + private function findFileWithExtension($class, $ext) { // PSR-4 lookup diff --git a/vendor/composer/InstalledVersions.php b/vendor/composer/InstalledVersions.php index db8e1c6d9..645aea514 100644 --- a/vendor/composer/InstalledVersions.php +++ b/vendor/composer/InstalledVersions.php @@ -30,7 +30,7 @@ private static $installed = array ( 'aliases' => array ( ), - 'reference' => 'e248cd036c7757b009d90b73fcd77176cbb45e76', + 'reference' => '41b78a0599d303bea0254a30f8ebc3c778e3e34e', 'name' => 'laravel/laravel', ), 'versions' => @@ -53,15 +53,6 @@ private static $installed = array ( ), 'reference' => 'dff976c2f3487d42c1db75a3b180e2b9f0e72ce0', ), - 'cakephp/chronos' => - array ( - 'pretty_version' => '2.1.2', - 'version' => '2.1.2.0', - 'aliases' => - array ( - ), - 'reference' => '1d187c71587c97520c00491f626e0f255144953e', - ), 'cordoval/hamcrest-php' => array ( 'replaced' => @@ -105,12 +96,12 @@ private static $installed = array ( ), 'dragonmantank/cron-expression' => array ( - 'pretty_version' => 'v2.3.1', - 'version' => '2.3.1.0', + 'pretty_version' => 'v3.1.0', + 'version' => '3.1.0.0', 'aliases' => array ( ), - 'reference' => '65b2d8ee1f10915efb3b55597da3404f096acba2', + 'reference' => '7a8c6e56ab3ffcc538d05e8155bb42269abf1a0c', ), 'egulias/email-validator' => array ( @@ -123,12 +114,12 @@ private static $installed = array ( ), 'eveseat/eseye' => array ( - 'pretty_version' => '2.3.2', - 'version' => '2.3.2.0', + 'pretty_version' => '2.4.0', + 'version' => '2.4.0.0', 'aliases' => array ( ), - 'reference' => '69a0180f1727369614971fe377a1a8b2301c505d', + 'reference' => 'b9d6753ccad9edce2bed6c91142f62eaebe24a8c', ), 'facade/ignition-contracts' => array ( @@ -175,14 +166,23 @@ private static $installed = array ( ), 'reference' => '848d8125239d7dbf8ab25cb7f054f1a630e68c2e', ), - 'guzzlehttp/guzzle' => + 'graham-campbell/result-type' => array ( - 'pretty_version' => '6.5.5', - 'version' => '6.5.5.0', + 'pretty_version' => 'v1.0.1', + 'version' => '1.0.1.0', 'aliases' => array ( ), - 'reference' => '9d4290de1cfd701f38099ef7e183b64b4b7b0c5e', + 'reference' => '7e279d2cd5d7fbb156ce46daada972355cea27bb', + ), + 'guzzlehttp/guzzle' => + array ( + 'pretty_version' => '7.3.0', + 'version' => '7.3.0.0', + 'aliases' => + array ( + ), + 'reference' => '7008573787b430c1c1f650e3722d9bba59967628', ), 'guzzlehttp/promises' => array ( @@ -215,203 +215,217 @@ private static $installed = array ( array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/broadcasting' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/bus' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/cache' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', + ), + ), + 'illuminate/collections' => + array ( + 'replaced' => + array ( + 0 => 'v8.44.0', ), ), 'illuminate/config' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/console' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/container' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/contracts' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/cookie' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/database' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/encryption' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/events' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/filesystem' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/hashing' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/http' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/log' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', + ), + ), + 'illuminate/macroable' => + array ( + 'replaced' => + array ( + 0 => 'v8.44.0', ), ), 'illuminate/mail' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/notifications' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/pagination' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/pipeline' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/queue' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/redis' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/routing' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/session' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/support' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/testing' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/translation' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/validation' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/view' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'khill/lavacharts' => @@ -432,12 +446,12 @@ private static $installed = array ( ), 'laravel/framework' => array ( - 'pretty_version' => 'v7.30.4', - 'version' => '7.30.4.0', + 'pretty_version' => 'v8.44.0', + 'version' => '8.44.0.0', 'aliases' => array ( ), - 'reference' => '9dd38140dc2924daa1a020a3d7a45f9ceff03df3', + 'reference' => '7b3b27dc8911ab02a69731af2ba97b5130b2ddb8', ), 'laravel/helpers' => array ( @@ -450,12 +464,12 @@ private static $installed = array ( ), 'laravel/horizon' => array ( - 'pretty_version' => 'v4.3.5', - 'version' => '4.3.5.0', + 'pretty_version' => 'v5.7.8', + 'version' => '5.7.8.0', 'aliases' => array ( ), - 'reference' => 'b3fba0daaaaf5e84197b06dd25f3b27bb7301171', + 'reference' => '2b5628b598c813650458dc7e4afacb500d72ff9a', ), 'laravel/laravel' => array ( @@ -464,7 +478,7 @@ private static $installed = array ( 'aliases' => array ( ), - 'reference' => 'e248cd036c7757b009d90b73fcd77176cbb45e76', + 'reference' => '41b78a0599d303bea0254a30f8ebc3c778e3e34e', ), 'laravel/socialite' => array ( @@ -477,12 +491,12 @@ private static $installed = array ( ), 'laravel/ui' => array ( - 'pretty_version' => 'v2.5.0', - 'version' => '2.5.0.0', + 'pretty_version' => 'v3.3.0', + 'version' => '3.3.0.0', 'aliases' => array ( ), - 'reference' => 'd01a705763c243b07be795e9d1bb47f89260f73d', + 'reference' => '07d725813350c695c779382cbd6dac0ab8665537', ), 'laravelcollective/html' => array ( @@ -531,12 +545,12 @@ private static $installed = array ( ), 'lorisleiva/cron-translator' => array ( - 'pretty_version' => 'v0.1.1', - 'version' => '0.1.1.0', + 'pretty_version' => 'v0.2.0', + 'version' => '0.2.0.0', 'aliases' => array ( ), - 'reference' => '784a6f6255a4b5f45da5d89dc6ec631a14d7b011', + 'reference' => '764996770558dddc7def8619095391a4ec8048f2', ), 'mockery/mockery' => array ( @@ -556,6 +570,13 @@ private static $installed = array ( ), 'reference' => '1cb1cde8e8dd0f70cc0fe51354a59acad9302084', ), + 'mtdowling/cron-expression' => + array ( + 'replaced' => + array ( + 0 => '^1.0', + ), + ), 'myclabs/deep-copy' => array ( 'pretty_version' => '1.10.2', @@ -571,21 +592,30 @@ private static $installed = array ( ), 'nesbot/carbon' => array ( - 'pretty_version' => '2.48.0', - 'version' => '2.48.0.0', + 'pretty_version' => '2.48.1', + 'version' => '2.48.1.0', 'aliases' => array ( ), - 'reference' => 'd3c447f21072766cddec3522f9468a5849a76147', + 'reference' => '8d1f50f1436fb4b05e7127360483dd9c6e73da16', + ), + 'nikic/php-parser' => + array ( + 'pretty_version' => 'v4.10.5', + 'version' => '4.10.5.0', + 'aliases' => + array ( + ), + 'reference' => '4432ba399e47c66624bc73c8c0f811e5c109576f', ), 'nunomaduro/collision' => array ( - 'pretty_version' => 'v4.3.0', - 'version' => '4.3.0.0', + 'pretty_version' => 'v5.4.0', + 'version' => '5.4.0.0', 'aliases' => array ( ), - 'reference' => '7c125dc2463f3e144ddc7e05e63077109508c94e', + 'reference' => '41b7e9999133d5082700d31a1d0977161df8322a', ), 'opis/closure' => array ( @@ -661,57 +691,57 @@ private static $installed = array ( ), 'phpunit/php-code-coverage' => array ( - 'pretty_version' => '7.0.14', - 'version' => '7.0.14.0', + 'pretty_version' => '9.2.6', + 'version' => '9.2.6.0', 'aliases' => array ( ), - 'reference' => 'bb7c9a210c72e4709cdde67f8b7362f672f2225c', + 'reference' => 'f6293e1b30a2354e8428e004689671b83871edde', ), 'phpunit/php-file-iterator' => array ( - 'pretty_version' => '2.0.3', - 'version' => '2.0.3.0', + 'pretty_version' => '3.0.5', + 'version' => '3.0.5.0', 'aliases' => array ( ), - 'reference' => '4b49fb70f067272b659ef0174ff9ca40fdaa6357', + 'reference' => 'aa4be8575f26070b100fccb67faabb28f21f66f8', + ), + 'phpunit/php-invoker' => + array ( + 'pretty_version' => '3.1.1', + 'version' => '3.1.1.0', + 'aliases' => + array ( + ), + 'reference' => '5a10147d0aaf65b58940a0b72f71c9ac0423cc67', ), 'phpunit/php-text-template' => array ( - 'pretty_version' => '1.2.1', - 'version' => '1.2.1.0', + 'pretty_version' => '2.0.4', + 'version' => '2.0.4.0', 'aliases' => array ( ), - 'reference' => '31f8b717e51d9a2afca6c9f046f5d69fc27c8686', + 'reference' => '5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28', ), 'phpunit/php-timer' => array ( - 'pretty_version' => '2.1.3', - 'version' => '2.1.3.0', + 'pretty_version' => '5.0.3', + 'version' => '5.0.3.0', 'aliases' => array ( ), - 'reference' => '2454ae1765516d20c4ffe103d85a58a9a3bd5662', - ), - 'phpunit/php-token-stream' => - array ( - 'pretty_version' => '4.0.4', - 'version' => '4.0.4.0', - 'aliases' => - array ( - ), - 'reference' => 'a853a0e183b9db7eed023d7933a858fa1c8d25a3', + 'reference' => '5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2', ), 'phpunit/phpunit' => array ( - 'pretty_version' => '8.5.15', - 'version' => '8.5.15.0', + 'pretty_version' => '9.5.4', + 'version' => '9.5.4.0', 'aliases' => array ( ), - 'reference' => '038d4196d8e8cb405cd5e82cedfe413ad6eef9ef', + 'reference' => 'c73c6737305e779771147af66c96ca6a7ed8a741', ), 'predis/predis' => array ( @@ -754,6 +784,22 @@ private static $installed = array ( 0 => '1.0', ), ), + 'psr/http-client' => + array ( + 'pretty_version' => '1.0.1', + 'version' => '1.0.1.0', + 'aliases' => + array ( + ), + 'reference' => '2dfb5f6c5eff0e91e20e913f8c5452ed95b86621', + ), + 'psr/http-client-implementation' => + array ( + 'provided' => + array ( + 0 => '1.0', + ), + ), 'psr/http-message' => array ( 'pretty_version' => '1.0.1', @@ -830,113 +876,149 @@ private static $installed = array ( 0 => '4.1.1', ), ), - 'sebastian/code-unit-reverse-lookup' => + 'sebastian/cli-parser' => array ( - 'pretty_version' => '1.0.2', - 'version' => '1.0.2.0', + 'pretty_version' => '1.0.1', + 'version' => '1.0.1.0', 'aliases' => array ( ), - 'reference' => '1de8cd5c010cb153fcd68b8d0f64606f523f7619', + 'reference' => '442e7c7e687e42adc03470c7b668bc4b2402c0b2', + ), + 'sebastian/code-unit' => + array ( + 'pretty_version' => '1.0.8', + 'version' => '1.0.8.0', + 'aliases' => + array ( + ), + 'reference' => '1fc9f64c0927627ef78ba436c9b17d967e68e120', + ), + 'sebastian/code-unit-reverse-lookup' => + array ( + 'pretty_version' => '2.0.3', + 'version' => '2.0.3.0', + 'aliases' => + array ( + ), + 'reference' => 'ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5', ), 'sebastian/comparator' => array ( - 'pretty_version' => '3.0.3', - 'version' => '3.0.3.0', + 'pretty_version' => '4.0.6', + 'version' => '4.0.6.0', 'aliases' => array ( ), - 'reference' => '1071dfcef776a57013124ff35e1fc41ccd294758', + 'reference' => '55f4261989e546dc112258c7a75935a81a7ce382', ), - 'sebastian/diff' => - array ( - 'pretty_version' => '3.0.3', - 'version' => '3.0.3.0', - 'aliases' => - array ( - ), - 'reference' => '14f72dd46eaf2f2293cbe79c93cc0bc43161a211', - ), - 'sebastian/environment' => - array ( - 'pretty_version' => '4.2.4', - 'version' => '4.2.4.0', - 'aliases' => - array ( - ), - 'reference' => 'd47bbbad83711771f167c72d4e3f25f7fcc1f8b0', - ), - 'sebastian/exporter' => - array ( - 'pretty_version' => '3.1.3', - 'version' => '3.1.3.0', - 'aliases' => - array ( - ), - 'reference' => '6b853149eab67d4da22291d36f5b0631c0fd856e', - ), - 'sebastian/global-state' => - array ( - 'pretty_version' => '3.0.1', - 'version' => '3.0.1.0', - 'aliases' => - array ( - ), - 'reference' => '474fb9edb7ab891665d3bfc6317f42a0a150454b', - ), - 'sebastian/object-enumerator' => - array ( - 'pretty_version' => '3.0.4', - 'version' => '3.0.4.0', - 'aliases' => - array ( - ), - 'reference' => 'e67f6d32ebd0c749cf9d1dbd9f226c727043cdf2', - ), - 'sebastian/object-reflector' => - array ( - 'pretty_version' => '1.1.2', - 'version' => '1.1.2.0', - 'aliases' => - array ( - ), - 'reference' => '9b8772b9cbd456ab45d4a598d2dd1a1bced6363d', - ), - 'sebastian/recursion-context' => - array ( - 'pretty_version' => '3.0.1', - 'version' => '3.0.1.0', - 'aliases' => - array ( - ), - 'reference' => '367dcba38d6e1977be014dc4b22f47a484dac7fb', - ), - 'sebastian/resource-operations' => + 'sebastian/complexity' => array ( 'pretty_version' => '2.0.2', 'version' => '2.0.2.0', 'aliases' => array ( ), - 'reference' => '31d35ca87926450c44eae7e2611d45a7a65ea8b3', + 'reference' => '739b35e53379900cc9ac327b2147867b8b6efd88', + ), + 'sebastian/diff' => + array ( + 'pretty_version' => '4.0.4', + 'version' => '4.0.4.0', + 'aliases' => + array ( + ), + 'reference' => '3461e3fccc7cfdfc2720be910d3bd73c69be590d', + ), + 'sebastian/environment' => + array ( + 'pretty_version' => '5.1.3', + 'version' => '5.1.3.0', + 'aliases' => + array ( + ), + 'reference' => '388b6ced16caa751030f6a69e588299fa09200ac', + ), + 'sebastian/exporter' => + array ( + 'pretty_version' => '4.0.3', + 'version' => '4.0.3.0', + 'aliases' => + array ( + ), + 'reference' => 'd89cc98761b8cb5a1a235a6b703ae50d34080e65', + ), + 'sebastian/global-state' => + array ( + 'pretty_version' => '5.0.2', + 'version' => '5.0.2.0', + 'aliases' => + array ( + ), + 'reference' => 'a90ccbddffa067b51f574dea6eb25d5680839455', + ), + 'sebastian/lines-of-code' => + array ( + 'pretty_version' => '1.0.3', + 'version' => '1.0.3.0', + 'aliases' => + array ( + ), + 'reference' => 'c1c2e997aa3146983ed888ad08b15470a2e22ecc', + ), + 'sebastian/object-enumerator' => + array ( + 'pretty_version' => '4.0.4', + 'version' => '4.0.4.0', + 'aliases' => + array ( + ), + 'reference' => '5c9eeac41b290a3712d88851518825ad78f45c71', + ), + 'sebastian/object-reflector' => + array ( + 'pretty_version' => '2.0.4', + 'version' => '2.0.4.0', + 'aliases' => + array ( + ), + 'reference' => 'b4f479ebdbf63ac605d183ece17d8d7fe49c15c7', + ), + 'sebastian/recursion-context' => + array ( + 'pretty_version' => '4.0.4', + 'version' => '4.0.4.0', + 'aliases' => + array ( + ), + 'reference' => 'cd9d8cf3c5804de4341c283ed787f099f5506172', + ), + 'sebastian/resource-operations' => + array ( + 'pretty_version' => '3.0.3', + 'version' => '3.0.3.0', + 'aliases' => + array ( + ), + 'reference' => '0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8', ), 'sebastian/type' => array ( - 'pretty_version' => '1.1.4', - 'version' => '1.1.4.0', + 'pretty_version' => '2.3.1', + 'version' => '2.3.1.0', 'aliases' => array ( ), - 'reference' => '0150cfbc4495ed2df3872fb31b26781e4e077eb4', + 'reference' => '81cd61ab7bbf2de744aba0ea61fae32f721df3d2', ), 'sebastian/version' => array ( - 'pretty_version' => '2.0.1', - 'version' => '2.0.1.0', + 'pretty_version' => '3.0.2', + 'version' => '3.0.2.0', 'aliases' => array ( ), - 'reference' => '99732be0ddb3361e16ad77b68ba41efc8e979019', + 'reference' => 'c6c1022351a901512170118436c764e473f6de8c', ), 'socialiteproviders/manager' => array ( @@ -958,12 +1040,12 @@ private static $installed = array ( ), 'spatie/laravel-schedule-monitor' => array ( - 'pretty_version' => '2.0.1', - 'version' => '2.0.1.0', + 'pretty_version' => '2.3.0', + 'version' => '2.3.0.0', 'aliases' => array ( ), - 'reference' => '4ffdaea81b5c27a119b6cbac8f4894657b8fd6d9', + 'reference' => 'cc65f9822d0e0b69043372d6c7d3e8dbd072f85d', ), 'spomky-labs/base64url' => array ( @@ -994,12 +1076,12 @@ private static $installed = array ( ), 'symfony/css-selector' => array ( - 'pretty_version' => 'v5.2.7', - 'version' => '5.2.7.0', + 'pretty_version' => 'v5.2.9', + 'version' => '5.2.9.0', 'aliases' => array ( ), - 'reference' => '59a684f5ac454f066ecbe6daecce6719aed283fb', + 'reference' => '5d5f97809015102116208b976eb2edb44b689560', ), 'symfony/deprecation-contracts' => array ( @@ -1046,12 +1128,12 @@ private static $installed = array ( ), 'symfony/finder' => array ( - 'pretty_version' => 'v5.2.8', - 'version' => '5.2.8.0', + 'pretty_version' => 'v5.2.9', + 'version' => '5.2.9.0', 'aliases' => array ( ), - 'reference' => 'eccb8be70d7a6a2230d05f6ecede40f3fdd9e252', + 'reference' => 'ccccb9d48ca42757dd12f2ca4bf857a4e217d90d', ), 'symfony/http-client-contracts' => array ( @@ -1073,102 +1155,102 @@ private static $installed = array ( ), 'symfony/http-kernel' => array ( - 'pretty_version' => 'v5.2.8', - 'version' => '5.2.8.0', + 'pretty_version' => 'v5.2.9', + 'version' => '5.2.9.0', 'aliases' => array ( ), - 'reference' => 'c3cb71ee7e2d3eae5fe1001f81780d6a49b37937', + 'reference' => 'eb540ef6870dbf33c92e372cfb869ebf9649e6cb', ), 'symfony/mime' => array ( - 'pretty_version' => 'v5.2.7', - 'version' => '5.2.7.0', + 'pretty_version' => 'v5.2.9', + 'version' => '5.2.9.0', 'aliases' => array ( ), - 'reference' => '7af452bf51c46f18da00feb32e1ad36db9426515', + 'reference' => '64258e870f8cc75c3dae986201ea2df58c210b52', ), 'symfony/polyfill-ctype' => array ( - 'pretty_version' => 'v1.22.1', - 'version' => '1.22.1.0', + 'pretty_version' => 'v1.23.0', + 'version' => '1.23.0.0', 'aliases' => array ( ), - 'reference' => 'c6c942b1ac76c82448322025e084cadc56048b4e', + 'reference' => '46cd95797e9df938fdd2b03693b5fca5e64b01ce', ), 'symfony/polyfill-iconv' => array ( - 'pretty_version' => 'v1.22.1', - 'version' => '1.22.1.0', + 'pretty_version' => 'v1.23.0', + 'version' => '1.23.0.0', 'aliases' => array ( ), - 'reference' => '06fb361659649bcfd6a208a0f1fcaf4e827ad342', + 'reference' => '63b5bb7db83e5673936d6e3b8b3e022ff6474933', ), 'symfony/polyfill-intl-grapheme' => array ( - 'pretty_version' => 'v1.22.1', - 'version' => '1.22.1.0', + 'pretty_version' => 'v1.23.0', + 'version' => '1.23.0.0', 'aliases' => array ( ), - 'reference' => '5601e09b69f26c1828b13b6bb87cb07cddba3170', + 'reference' => '24b72c6baa32c746a4d0840147c9715e42bb68ab', ), 'symfony/polyfill-intl-idn' => array ( - 'pretty_version' => 'v1.22.1', - 'version' => '1.22.1.0', + 'pretty_version' => 'v1.23.0', + 'version' => '1.23.0.0', 'aliases' => array ( ), - 'reference' => '2d63434d922daf7da8dd863e7907e67ee3031483', + 'reference' => '65bd267525e82759e7d8c4e8ceea44f398838e65', ), 'symfony/polyfill-intl-normalizer' => array ( - 'pretty_version' => 'v1.22.1', - 'version' => '1.22.1.0', + 'pretty_version' => 'v1.23.0', + 'version' => '1.23.0.0', 'aliases' => array ( ), - 'reference' => '43a0283138253ed1d48d352ab6d0bdb3f809f248', + 'reference' => '8590a5f561694770bdcd3f9b5c69dde6945028e8', ), 'symfony/polyfill-mbstring' => array ( - 'pretty_version' => 'v1.22.1', - 'version' => '1.22.1.0', + 'pretty_version' => 'v1.23.0', + 'version' => '1.23.0.0', 'aliases' => array ( ), - 'reference' => '5232de97ee3b75b0360528dae24e73db49566ab1', + 'reference' => '2df51500adbaebdc4c38dea4c89a2e131c45c8a1', ), 'symfony/polyfill-php72' => array ( - 'pretty_version' => 'v1.22.1', - 'version' => '1.22.1.0', + 'pretty_version' => 'v1.23.0', + 'version' => '1.23.0.0', 'aliases' => array ( ), - 'reference' => 'cc6e6f9b39fe8075b3dabfbaf5b5f645ae1340c9', + 'reference' => '9a142215a36a3888e30d0a9eeea9766764e96976', ), 'symfony/polyfill-php73' => array ( - 'pretty_version' => 'v1.22.1', - 'version' => '1.22.1.0', + 'pretty_version' => 'v1.23.0', + 'version' => '1.23.0.0', 'aliases' => array ( ), - 'reference' => 'a678b42e92f86eca04b7fa4c0f6f19d097fb69e2', + 'reference' => 'fba8933c384d6476ab14fb7b8526e5287ca7e010', ), 'symfony/polyfill-php80' => array ( - 'pretty_version' => 'v1.22.1', - 'version' => '1.22.1.0', + 'pretty_version' => 'v1.23.0', + 'version' => '1.23.0.0', 'aliases' => array ( ), - 'reference' => 'dc3063ba22c2a1fd2f45ed856374d79114998f91', + 'reference' => 'eca0bf41ed421bed1b57c4958bab16aa86b757d0', ), 'symfony/process' => array ( @@ -1181,12 +1263,12 @@ private static $installed = array ( ), 'symfony/routing' => array ( - 'pretty_version' => 'v5.2.7', - 'version' => '5.2.7.0', + 'pretty_version' => 'v5.2.9', + 'version' => '5.2.9.0', 'aliases' => array ( ), - 'reference' => '3f0cab2e95b5e92226f34c2c1aa969d3fc41f48c', + 'reference' => '4a7b2bf5e1221be1902b6853743a9bb317f6925e', ), 'symfony/service-contracts' => array ( @@ -1208,12 +1290,12 @@ private static $installed = array ( ), 'symfony/translation' => array ( - 'pretty_version' => 'v5.2.8', - 'version' => '5.2.8.0', + 'pretty_version' => 'v5.2.9', + 'version' => '5.2.9.0', 'aliases' => array ( ), - 'reference' => '445caa74a5986f1cc9dd91a2975ef68fa7cb2068', + 'reference' => '61af68dba333e2d376a325a29c2a3f2a605b4876', ), 'symfony/translation-contracts' => array ( @@ -1276,12 +1358,12 @@ private static $installed = array ( ), 'vlucas/phpdotenv' => array ( - 'pretty_version' => 'v4.2.0', - 'version' => '4.2.0.0', + 'pretty_version' => 'v5.3.0', + 'version' => '5.3.0.0', 'aliases' => array ( ), - 'reference' => 'da64796370fc4eb03cc277088f6fede9fde88482', + 'reference' => 'b3eac5c7ac896e52deab4a99068e3f4ab12d9e56', ), 'voku/portable-ascii' => array ( diff --git a/vendor/composer/autoload_classmap.php b/vendor/composer/autoload_classmap.php index be1af7f0d..394e5eeef 100644 --- a/vendor/composer/autoload_classmap.php +++ b/vendor/composer/autoload_classmap.php @@ -13,6 +13,7 @@ return array( 'App\\Console\\Commands\\Data\\PurgeUsers' => $baseDir . '/app/Console/Commands/Data/PurgeUsers.php', 'App\\Console\\Commands\\Data\\Test' => $baseDir . '/app/Console/Commands/Data/Test.php', 'App\\Console\\Commands\\Eve\\ItemPricesUpdateCommand' => $baseDir . '/app/Console/Commands/Eve/ItemPricesUpdateCommand.php', + 'App\\Console\\Commands\\Files\\ImportAllianceMoons' => $baseDir . '/app/Console/Commands/Files/ImportAllianceMoons.php', 'App\\Console\\Commands\\Files\\MoonFormatter' => $baseDir . '/app/Console/Commands/Files/MoonFormatter.php', 'App\\Console\\Commands\\Files\\UpdateItemCompositionFromSDECommand' => $baseDir . '/app/Console/Commands/Files/UpdateItemCompositionFromSDECommand.php', 'App\\Console\\Commands\\Finances\\UpdateAllianceWalletJournal' => $baseDir . '/app/Console/Commands/Finances/UpdateAllianceWalletJournal.php', @@ -100,12 +101,15 @@ return array( 'App\\Models\\Lookups\\CharacterLookup' => $baseDir . '/app/Models/Lookups/CharacterLookup.php', 'App\\Models\\Lookups\\CorporationLookup' => $baseDir . '/app/Models/Lookups/CorporationLookup.php', 'App\\Models\\Lookups\\ItemLookup' => $baseDir . '/app/Models/Lookups/ItemLookup.php', + 'App\\Models\\Lookups\\MoonLookup' => $baseDir . '/app/Models/Lookups/MoonLookup.php', 'App\\Models\\Lookups\\SolarSystem' => $baseDir . '/app/Models/Lookups/SolarSystem.php', 'App\\Models\\Mail\\SentMail' => $baseDir . '/app/Models/Mail/SentMail.php', 'App\\Models\\MiningTax\\Invoice' => $baseDir . '/app/Models/MiningTax/Invoice.php', 'App\\Models\\MiningTax\\Ledger' => $baseDir . '/app/Models/MiningTax/Ledger.php', 'App\\Models\\MiningTax\\Observer' => $baseDir . '/app/Models/MiningTax/Observer.php', 'App\\Models\\MiningTax\\Payment' => $baseDir . '/app/Models/MiningTax/Payment.php', + 'App\\Models\\MoonRental\\AllianceMoon' => $baseDir . '/app/Models/MoonRental/AllianceMoon.php', + 'App\\Models\\MoonRental\\AllianceMoonRental' => $baseDir . '/app/Models/MoonRental/AllianceMoonRental.php', 'App\\Models\\Moon\\Config' => $baseDir . '/app/Models/Moon/Config.php', 'App\\Models\\Moon\\ItemComposition' => $baseDir . '/app/Models/Moon/ItemComposition.php', 'App\\Models\\Moon\\MineralPrice' => $baseDir . '/app/Models/Moon/MineralPrice.php', @@ -162,26 +166,6 @@ return array( 'Brick\\Math\\Internal\\Calculator\\GmpCalculator' => $vendorDir . '/brick/math/src/Internal/Calculator/GmpCalculator.php', 'Brick\\Math\\Internal\\Calculator\\NativeCalculator' => $vendorDir . '/brick/math/src/Internal/Calculator/NativeCalculator.php', 'Brick\\Math\\RoundingMode' => $vendorDir . '/brick/math/src/RoundingMode.php', - 'Cake\\Chronos\\Chronos' => $vendorDir . '/cakephp/chronos/src/Chronos.php', - 'Cake\\Chronos\\ChronosInterface' => $vendorDir . '/cakephp/chronos/src/ChronosInterface.php', - 'Cake\\Chronos\\ChronosInterval' => $vendorDir . '/cakephp/chronos/src/ChronosInterval.php', - 'Cake\\Chronos\\Date' => $vendorDir . '/cakephp/chronos/src/Date.php', - 'Cake\\Chronos\\DifferenceFormatter' => $vendorDir . '/cakephp/chronos/src/DifferenceFormatter.php', - 'Cake\\Chronos\\DifferenceFormatterInterface' => $vendorDir . '/cakephp/chronos/src/DifferenceFormatterInterface.php', - 'Cake\\Chronos\\MutableDate' => $vendorDir . '/cakephp/chronos/src/MutableDate.php', - 'Cake\\Chronos\\MutableDateTime' => $vendorDir . '/cakephp/chronos/src/MutableDateTime.php', - 'Cake\\Chronos\\Traits\\ComparisonTrait' => $vendorDir . '/cakephp/chronos/src/Traits/ComparisonTrait.php', - 'Cake\\Chronos\\Traits\\CopyTrait' => $vendorDir . '/cakephp/chronos/src/Traits/CopyTrait.php', - 'Cake\\Chronos\\Traits\\DifferenceTrait' => $vendorDir . '/cakephp/chronos/src/Traits/DifferenceTrait.php', - 'Cake\\Chronos\\Traits\\FactoryTrait' => $vendorDir . '/cakephp/chronos/src/Traits/FactoryTrait.php', - 'Cake\\Chronos\\Traits\\FormattingTrait' => $vendorDir . '/cakephp/chronos/src/Traits/FormattingTrait.php', - 'Cake\\Chronos\\Traits\\FrozenTimeTrait' => $vendorDir . '/cakephp/chronos/src/Traits/FrozenTimeTrait.php', - 'Cake\\Chronos\\Traits\\MagicPropertyTrait' => $vendorDir . '/cakephp/chronos/src/Traits/MagicPropertyTrait.php', - 'Cake\\Chronos\\Traits\\ModifierTrait' => $vendorDir . '/cakephp/chronos/src/Traits/ModifierTrait.php', - 'Cake\\Chronos\\Traits\\RelativeKeywordTrait' => $vendorDir . '/cakephp/chronos/src/Traits/RelativeKeywordTrait.php', - 'Cake\\Chronos\\Traits\\TestingAidTrait' => $vendorDir . '/cakephp/chronos/src/Traits/TestingAidTrait.php', - 'Cake\\Chronos\\Traits\\TimezoneTrait' => $vendorDir . '/cakephp/chronos/src/Traits/TimezoneTrait.php', - 'Cake\\Chronos\\Translator' => $vendorDir . '/cakephp/chronos/src/Translator.php', 'Carbon\\Carbon' => $vendorDir . '/nesbot/carbon/src/Carbon/Carbon.php', 'Carbon\\CarbonConverterInterface' => $vendorDir . '/nesbot/carbon/src/Carbon/CarbonConverterInterface.php', 'Carbon\\CarbonImmutable' => $vendorDir . '/nesbot/carbon/src/Carbon/CarbonImmutable.php', @@ -269,6 +253,7 @@ return array( 'Cron\\DayOfMonthField' => $vendorDir . '/dragonmantank/cron-expression/src/Cron/DayOfMonthField.php', 'Cron\\DayOfWeekField' => $vendorDir . '/dragonmantank/cron-expression/src/Cron/DayOfWeekField.php', 'Cron\\FieldFactory' => $vendorDir . '/dragonmantank/cron-expression/src/Cron/FieldFactory.php', + 'Cron\\FieldFactoryInterface' => $vendorDir . '/dragonmantank/cron-expression/src/Cron/FieldFactoryInterface.php', 'Cron\\FieldInterface' => $vendorDir . '/dragonmantank/cron-expression/src/Cron/FieldInterface.php', 'Cron\\HoursField' => $vendorDir . '/dragonmantank/cron-expression/src/Cron/HoursField.php', 'Cron\\MinutesField' => $vendorDir . '/dragonmantank/cron-expression/src/Cron/MinutesField.php', @@ -347,36 +332,44 @@ return array( 'Doctrine\\Instantiator\\InstantiatorInterface' => $vendorDir . '/doctrine/instantiator/src/Doctrine/Instantiator/InstantiatorInterface.php', 'Dotenv\\Dotenv' => $vendorDir . '/vlucas/phpdotenv/src/Dotenv.php', 'Dotenv\\Exception\\ExceptionInterface' => $vendorDir . '/vlucas/phpdotenv/src/Exception/ExceptionInterface.php', + 'Dotenv\\Exception\\InvalidEncodingException' => $vendorDir . '/vlucas/phpdotenv/src/Exception/InvalidEncodingException.php', 'Dotenv\\Exception\\InvalidFileException' => $vendorDir . '/vlucas/phpdotenv/src/Exception/InvalidFileException.php', 'Dotenv\\Exception\\InvalidPathException' => $vendorDir . '/vlucas/phpdotenv/src/Exception/InvalidPathException.php', 'Dotenv\\Exception\\ValidationException' => $vendorDir . '/vlucas/phpdotenv/src/Exception/ValidationException.php', - 'Dotenv\\Loader\\Lines' => $vendorDir . '/vlucas/phpdotenv/src/Loader/Lines.php', 'Dotenv\\Loader\\Loader' => $vendorDir . '/vlucas/phpdotenv/src/Loader/Loader.php', 'Dotenv\\Loader\\LoaderInterface' => $vendorDir . '/vlucas/phpdotenv/src/Loader/LoaderInterface.php', - 'Dotenv\\Loader\\Parser' => $vendorDir . '/vlucas/phpdotenv/src/Loader/Parser.php', - 'Dotenv\\Loader\\Value' => $vendorDir . '/vlucas/phpdotenv/src/Loader/Value.php', - 'Dotenv\\Regex\\Regex' => $vendorDir . '/vlucas/phpdotenv/src/Regex/Regex.php', - 'Dotenv\\Repository\\AbstractRepository' => $vendorDir . '/vlucas/phpdotenv/src/Repository/AbstractRepository.php', + 'Dotenv\\Loader\\Resolver' => $vendorDir . '/vlucas/phpdotenv/src/Loader/Resolver.php', + 'Dotenv\\Parser\\Entry' => $vendorDir . '/vlucas/phpdotenv/src/Parser/Entry.php', + 'Dotenv\\Parser\\EntryParser' => $vendorDir . '/vlucas/phpdotenv/src/Parser/EntryParser.php', + 'Dotenv\\Parser\\Lexer' => $vendorDir . '/vlucas/phpdotenv/src/Parser/Lexer.php', + 'Dotenv\\Parser\\Lines' => $vendorDir . '/vlucas/phpdotenv/src/Parser/Lines.php', + 'Dotenv\\Parser\\Parser' => $vendorDir . '/vlucas/phpdotenv/src/Parser/Parser.php', + 'Dotenv\\Parser\\ParserInterface' => $vendorDir . '/vlucas/phpdotenv/src/Parser/ParserInterface.php', + 'Dotenv\\Parser\\Value' => $vendorDir . '/vlucas/phpdotenv/src/Parser/Value.php', 'Dotenv\\Repository\\AdapterRepository' => $vendorDir . '/vlucas/phpdotenv/src/Repository/AdapterRepository.php', + 'Dotenv\\Repository\\Adapter\\AdapterInterface' => $vendorDir . '/vlucas/phpdotenv/src/Repository/Adapter/AdapterInterface.php', 'Dotenv\\Repository\\Adapter\\ApacheAdapter' => $vendorDir . '/vlucas/phpdotenv/src/Repository/Adapter/ApacheAdapter.php', 'Dotenv\\Repository\\Adapter\\ArrayAdapter' => $vendorDir . '/vlucas/phpdotenv/src/Repository/Adapter/ArrayAdapter.php', - 'Dotenv\\Repository\\Adapter\\AvailabilityInterface' => $vendorDir . '/vlucas/phpdotenv/src/Repository/Adapter/AvailabilityInterface.php', 'Dotenv\\Repository\\Adapter\\EnvConstAdapter' => $vendorDir . '/vlucas/phpdotenv/src/Repository/Adapter/EnvConstAdapter.php', + 'Dotenv\\Repository\\Adapter\\GuardedWriter' => $vendorDir . '/vlucas/phpdotenv/src/Repository/Adapter/GuardedWriter.php', + 'Dotenv\\Repository\\Adapter\\ImmutableWriter' => $vendorDir . '/vlucas/phpdotenv/src/Repository/Adapter/ImmutableWriter.php', + 'Dotenv\\Repository\\Adapter\\MultiReader' => $vendorDir . '/vlucas/phpdotenv/src/Repository/Adapter/MultiReader.php', + 'Dotenv\\Repository\\Adapter\\MultiWriter' => $vendorDir . '/vlucas/phpdotenv/src/Repository/Adapter/MultiWriter.php', 'Dotenv\\Repository\\Adapter\\PutenvAdapter' => $vendorDir . '/vlucas/phpdotenv/src/Repository/Adapter/PutenvAdapter.php', 'Dotenv\\Repository\\Adapter\\ReaderInterface' => $vendorDir . '/vlucas/phpdotenv/src/Repository/Adapter/ReaderInterface.php', + 'Dotenv\\Repository\\Adapter\\ReplacingWriter' => $vendorDir . '/vlucas/phpdotenv/src/Repository/Adapter/ReplacingWriter.php', 'Dotenv\\Repository\\Adapter\\ServerConstAdapter' => $vendorDir . '/vlucas/phpdotenv/src/Repository/Adapter/ServerConstAdapter.php', 'Dotenv\\Repository\\Adapter\\WriterInterface' => $vendorDir . '/vlucas/phpdotenv/src/Repository/Adapter/WriterInterface.php', 'Dotenv\\Repository\\RepositoryBuilder' => $vendorDir . '/vlucas/phpdotenv/src/Repository/RepositoryBuilder.php', 'Dotenv\\Repository\\RepositoryInterface' => $vendorDir . '/vlucas/phpdotenv/src/Repository/RepositoryInterface.php', - 'Dotenv\\Result\\Error' => $vendorDir . '/vlucas/phpdotenv/src/Result/Error.php', - 'Dotenv\\Result\\Result' => $vendorDir . '/vlucas/phpdotenv/src/Result/Result.php', - 'Dotenv\\Result\\Success' => $vendorDir . '/vlucas/phpdotenv/src/Result/Success.php', 'Dotenv\\Store\\FileStore' => $vendorDir . '/vlucas/phpdotenv/src/Store/FileStore.php', 'Dotenv\\Store\\File\\Paths' => $vendorDir . '/vlucas/phpdotenv/src/Store/File/Paths.php', 'Dotenv\\Store\\File\\Reader' => $vendorDir . '/vlucas/phpdotenv/src/Store/File/Reader.php', 'Dotenv\\Store\\StoreBuilder' => $vendorDir . '/vlucas/phpdotenv/src/Store/StoreBuilder.php', 'Dotenv\\Store\\StoreInterface' => $vendorDir . '/vlucas/phpdotenv/src/Store/StoreInterface.php', 'Dotenv\\Store\\StringStore' => $vendorDir . '/vlucas/phpdotenv/src/Store/StringStore.php', + 'Dotenv\\Util\\Regex' => $vendorDir . '/vlucas/phpdotenv/src/Util/Regex.php', + 'Dotenv\\Util\\Str' => $vendorDir . '/vlucas/phpdotenv/src/Util/Str.php', 'Dotenv\\Validator' => $vendorDir . '/vlucas/phpdotenv/src/Validator.php', 'Egulias\\EmailValidator\\EmailLexer' => $vendorDir . '/egulias/email-validator/src/EmailLexer.php', 'Egulias\\EmailValidator\\EmailParser' => $vendorDir . '/egulias/email-validator/src/EmailParser.php', @@ -957,8 +950,14 @@ return array( 'Faker\\ValidGenerator' => $vendorDir . '/fzaninotto/faker/src/Faker/ValidGenerator.php', 'Fideloper\\Proxy\\TrustProxies' => $vendorDir . '/fideloper/proxy/src/TrustProxies.php', 'Fideloper\\Proxy\\TrustedProxyServiceProvider' => $vendorDir . '/fideloper/proxy/src/TrustedProxyServiceProvider.php', + 'GrahamCampbell\\ResultType\\Error' => $vendorDir . '/graham-campbell/result-type/src/Error.php', + 'GrahamCampbell\\ResultType\\Result' => $vendorDir . '/graham-campbell/result-type/src/Result.php', + 'GrahamCampbell\\ResultType\\Success' => $vendorDir . '/graham-campbell/result-type/src/Success.php', + 'GuzzleHttp\\BodySummarizer' => $vendorDir . '/guzzlehttp/guzzle/src/BodySummarizer.php', + 'GuzzleHttp\\BodySummarizerInterface' => $vendorDir . '/guzzlehttp/guzzle/src/BodySummarizerInterface.php', 'GuzzleHttp\\Client' => $vendorDir . '/guzzlehttp/guzzle/src/Client.php', 'GuzzleHttp\\ClientInterface' => $vendorDir . '/guzzlehttp/guzzle/src/ClientInterface.php', + 'GuzzleHttp\\ClientTrait' => $vendorDir . '/guzzlehttp/guzzle/src/ClientTrait.php', 'GuzzleHttp\\Cookie\\CookieJar' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/CookieJar.php', 'GuzzleHttp\\Cookie\\CookieJarInterface' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/CookieJarInterface.php', 'GuzzleHttp\\Cookie\\FileCookieJar' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php', @@ -970,7 +969,6 @@ return array( 'GuzzleHttp\\Exception\\GuzzleException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/GuzzleException.php', 'GuzzleHttp\\Exception\\InvalidArgumentException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/InvalidArgumentException.php', 'GuzzleHttp\\Exception\\RequestException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/RequestException.php', - 'GuzzleHttp\\Exception\\SeekException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/SeekException.php', 'GuzzleHttp\\Exception\\ServerException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/ServerException.php', 'GuzzleHttp\\Exception\\TooManyRedirectsException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/TooManyRedirectsException.php', 'GuzzleHttp\\Exception\\TransferException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/TransferException.php', @@ -980,10 +978,12 @@ return array( 'GuzzleHttp\\Handler\\CurlHandler' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/CurlHandler.php', 'GuzzleHttp\\Handler\\CurlMultiHandler' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php', 'GuzzleHttp\\Handler\\EasyHandle' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/EasyHandle.php', + 'GuzzleHttp\\Handler\\HeaderProcessor' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/HeaderProcessor.php', 'GuzzleHttp\\Handler\\MockHandler' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/MockHandler.php', 'GuzzleHttp\\Handler\\Proxy' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/Proxy.php', 'GuzzleHttp\\Handler\\StreamHandler' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/StreamHandler.php', 'GuzzleHttp\\MessageFormatter' => $vendorDir . '/guzzlehttp/guzzle/src/MessageFormatter.php', + 'GuzzleHttp\\MessageFormatterInterface' => $vendorDir . '/guzzlehttp/guzzle/src/MessageFormatterInterface.php', 'GuzzleHttp\\Middleware' => $vendorDir . '/guzzlehttp/guzzle/src/Middleware.php', 'GuzzleHttp\\Pool' => $vendorDir . '/guzzlehttp/guzzle/src/Pool.php', 'GuzzleHttp\\PrepareBodyMiddleware' => $vendorDir . '/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php', @@ -1035,7 +1035,6 @@ return array( 'GuzzleHttp\\RequestOptions' => $vendorDir . '/guzzlehttp/guzzle/src/RequestOptions.php', 'GuzzleHttp\\RetryMiddleware' => $vendorDir . '/guzzlehttp/guzzle/src/RetryMiddleware.php', 'GuzzleHttp\\TransferStats' => $vendorDir . '/guzzlehttp/guzzle/src/TransferStats.php', - 'GuzzleHttp\\UriTemplate' => $vendorDir . '/guzzlehttp/guzzle/src/UriTemplate.php', 'GuzzleHttp\\Utils' => $vendorDir . '/guzzlehttp/guzzle/src/Utils.php', 'Hamcrest\\Arrays\\IsArray' => $vendorDir . '/hamcrest/hamcrest-php/hamcrest/Hamcrest/Arrays/IsArray.php', 'Hamcrest\\Arrays\\IsArrayContaining' => $vendorDir . '/hamcrest/hamcrest-php/hamcrest/Hamcrest/Arrays/IsArrayContaining.php', @@ -1106,6 +1105,7 @@ return array( 'Hamcrest\\Util' => $vendorDir . '/hamcrest/hamcrest-php/hamcrest/Hamcrest/Util.php', 'Hamcrest\\Xml\\HasXPath' => $vendorDir . '/hamcrest/hamcrest-php/hamcrest/Hamcrest/Xml/HasXPath.php', 'Illuminate\\Auth\\Access\\AuthorizationException' => $vendorDir . '/laravel/framework/src/Illuminate/Auth/Access/AuthorizationException.php', + 'Illuminate\\Auth\\Access\\Events\\GateEvaluated' => $vendorDir . '/laravel/framework/src/Illuminate/Auth/Access/Events/GateEvaluated.php', 'Illuminate\\Auth\\Access\\Gate' => $vendorDir . '/laravel/framework/src/Illuminate/Auth/Access/Gate.php', 'Illuminate\\Auth\\Access\\HandlesAuthorization' => $vendorDir . '/laravel/framework/src/Illuminate/Auth/Access/HandlesAuthorization.php', 'Illuminate\\Auth\\Access\\Response' => $vendorDir . '/laravel/framework/src/Illuminate/Auth/Access/Response.php', @@ -1155,6 +1155,7 @@ return array( 'Illuminate\\Broadcasting\\BroadcastException' => $vendorDir . '/laravel/framework/src/Illuminate/Broadcasting/BroadcastException.php', 'Illuminate\\Broadcasting\\BroadcastManager' => $vendorDir . '/laravel/framework/src/Illuminate/Broadcasting/BroadcastManager.php', 'Illuminate\\Broadcasting\\BroadcastServiceProvider' => $vendorDir . '/laravel/framework/src/Illuminate/Broadcasting/BroadcastServiceProvider.php', + 'Illuminate\\Broadcasting\\Broadcasters\\AblyBroadcaster' => $vendorDir . '/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/AblyBroadcaster.php', 'Illuminate\\Broadcasting\\Broadcasters\\Broadcaster' => $vendorDir . '/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/Broadcaster.php', 'Illuminate\\Broadcasting\\Broadcasters\\LogBroadcaster' => $vendorDir . '/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/LogBroadcaster.php', 'Illuminate\\Broadcasting\\Broadcasters\\NullBroadcaster' => $vendorDir . '/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/NullBroadcaster.php', @@ -1167,13 +1168,23 @@ return array( 'Illuminate\\Broadcasting\\PendingBroadcast' => $vendorDir . '/laravel/framework/src/Illuminate/Broadcasting/PendingBroadcast.php', 'Illuminate\\Broadcasting\\PresenceChannel' => $vendorDir . '/laravel/framework/src/Illuminate/Broadcasting/PresenceChannel.php', 'Illuminate\\Broadcasting\\PrivateChannel' => $vendorDir . '/laravel/framework/src/Illuminate/Broadcasting/PrivateChannel.php', + 'Illuminate\\Bus\\Batch' => $vendorDir . '/laravel/framework/src/Illuminate/Bus/Batch.php', + 'Illuminate\\Bus\\BatchFactory' => $vendorDir . '/laravel/framework/src/Illuminate/Bus/BatchFactory.php', + 'Illuminate\\Bus\\BatchRepository' => $vendorDir . '/laravel/framework/src/Illuminate/Bus/BatchRepository.php', + 'Illuminate\\Bus\\Batchable' => $vendorDir . '/laravel/framework/src/Illuminate/Bus/Batchable.php', 'Illuminate\\Bus\\BusServiceProvider' => $vendorDir . '/laravel/framework/src/Illuminate/Bus/BusServiceProvider.php', + 'Illuminate\\Bus\\DatabaseBatchRepository' => $vendorDir . '/laravel/framework/src/Illuminate/Bus/DatabaseBatchRepository.php', 'Illuminate\\Bus\\Dispatcher' => $vendorDir . '/laravel/framework/src/Illuminate/Bus/Dispatcher.php', + 'Illuminate\\Bus\\Events\\BatchDispatched' => $vendorDir . '/laravel/framework/src/Illuminate/Bus/Events/BatchDispatched.php', + 'Illuminate\\Bus\\PendingBatch' => $vendorDir . '/laravel/framework/src/Illuminate/Bus/PendingBatch.php', + 'Illuminate\\Bus\\PrunableBatchRepository' => $vendorDir . '/laravel/framework/src/Illuminate/Bus/PrunableBatchRepository.php', 'Illuminate\\Bus\\Queueable' => $vendorDir . '/laravel/framework/src/Illuminate/Bus/Queueable.php', + 'Illuminate\\Bus\\UpdatedBatchJobCounts' => $vendorDir . '/laravel/framework/src/Illuminate/Bus/UpdatedBatchJobCounts.php', 'Illuminate\\Cache\\ApcStore' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/ApcStore.php', 'Illuminate\\Cache\\ApcWrapper' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/ApcWrapper.php', 'Illuminate\\Cache\\ArrayLock' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/ArrayLock.php', 'Illuminate\\Cache\\ArrayStore' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/ArrayStore.php', + 'Illuminate\\Cache\\CacheLock' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/CacheLock.php', 'Illuminate\\Cache\\CacheManager' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/CacheManager.php', 'Illuminate\\Cache\\CacheServiceProvider' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/CacheServiceProvider.php', 'Illuminate\\Cache\\Console\\CacheTableCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/Console/CacheTableCommand.php', @@ -1189,13 +1200,19 @@ return array( 'Illuminate\\Cache\\Events\\KeyForgotten' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/Events/KeyForgotten.php', 'Illuminate\\Cache\\Events\\KeyWritten' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/Events/KeyWritten.php', 'Illuminate\\Cache\\FileStore' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/FileStore.php', + 'Illuminate\\Cache\\HasCacheLock' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/HasCacheLock.php', 'Illuminate\\Cache\\Lock' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/Lock.php', 'Illuminate\\Cache\\LuaScripts' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/LuaScripts.php', 'Illuminate\\Cache\\MemcachedConnector' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/MemcachedConnector.php', 'Illuminate\\Cache\\MemcachedLock' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/MemcachedLock.php', 'Illuminate\\Cache\\MemcachedStore' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/MemcachedStore.php', + 'Illuminate\\Cache\\NoLock' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/NoLock.php', 'Illuminate\\Cache\\NullStore' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/NullStore.php', + 'Illuminate\\Cache\\PhpRedisLock' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/PhpRedisLock.php', 'Illuminate\\Cache\\RateLimiter' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/RateLimiter.php', + 'Illuminate\\Cache\\RateLimiting\\GlobalLimit' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/RateLimiting/GlobalLimit.php', + 'Illuminate\\Cache\\RateLimiting\\Limit' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/RateLimiting/Limit.php', + 'Illuminate\\Cache\\RateLimiting\\Unlimited' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/RateLimiting/Unlimited.php', 'Illuminate\\Cache\\RedisLock' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/RedisLock.php', 'Illuminate\\Cache\\RedisStore' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/RedisStore.php', 'Illuminate\\Cache\\RedisTaggedCache' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/RedisTaggedCache.php', @@ -1204,8 +1221,11 @@ return array( 'Illuminate\\Cache\\TagSet' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/TagSet.php', 'Illuminate\\Cache\\TaggableStore' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/TaggableStore.php', 'Illuminate\\Cache\\TaggedCache' => $vendorDir . '/laravel/framework/src/Illuminate/Cache/TaggedCache.php', + 'Illuminate\\Collections\\ItemNotFoundException' => $vendorDir . '/laravel/framework/src/Illuminate/Collections/ItemNotFoundException.php', + 'Illuminate\\Collections\\MultipleItemsFoundException' => $vendorDir . '/laravel/framework/src/Illuminate/Collections/MultipleItemsFoundException.php', 'Illuminate\\Config\\Repository' => $vendorDir . '/laravel/framework/src/Illuminate/Config/Repository.php', 'Illuminate\\Console\\Application' => $vendorDir . '/laravel/framework/src/Illuminate/Console/Application.php', + 'Illuminate\\Console\\BufferedConsoleOutput' => $vendorDir . '/laravel/framework/src/Illuminate/Console/BufferedConsoleOutput.php', 'Illuminate\\Console\\Command' => $vendorDir . '/laravel/framework/src/Illuminate/Console/Command.php', 'Illuminate\\Console\\Concerns\\CallsCommands' => $vendorDir . '/laravel/framework/src/Illuminate/Console/Concerns/CallsCommands.php', 'Illuminate\\Console\\Concerns\\HasParameters' => $vendorDir . '/laravel/framework/src/Illuminate/Console/Concerns/HasParameters.php', @@ -1214,6 +1234,7 @@ return array( 'Illuminate\\Console\\Events\\ArtisanStarting' => $vendorDir . '/laravel/framework/src/Illuminate/Console/Events/ArtisanStarting.php', 'Illuminate\\Console\\Events\\CommandFinished' => $vendorDir . '/laravel/framework/src/Illuminate/Console/Events/CommandFinished.php', 'Illuminate\\Console\\Events\\CommandStarting' => $vendorDir . '/laravel/framework/src/Illuminate/Console/Events/CommandStarting.php', + 'Illuminate\\Console\\Events\\ScheduledBackgroundTaskFinished' => $vendorDir . '/laravel/framework/src/Illuminate/Console/Events/ScheduledBackgroundTaskFinished.php', 'Illuminate\\Console\\Events\\ScheduledTaskFailed' => $vendorDir . '/laravel/framework/src/Illuminate/Console/Events/ScheduledTaskFailed.php', 'Illuminate\\Console\\Events\\ScheduledTaskFinished' => $vendorDir . '/laravel/framework/src/Illuminate/Console/Events/ScheduledTaskFinished.php', 'Illuminate\\Console\\Events\\ScheduledTaskSkipped' => $vendorDir . '/laravel/framework/src/Illuminate/Console/Events/ScheduledTaskSkipped.php', @@ -1231,7 +1252,10 @@ return array( 'Illuminate\\Console\\Scheduling\\ManagesFrequencies' => $vendorDir . '/laravel/framework/src/Illuminate/Console/Scheduling/ManagesFrequencies.php', 'Illuminate\\Console\\Scheduling\\Schedule' => $vendorDir . '/laravel/framework/src/Illuminate/Console/Scheduling/Schedule.php', 'Illuminate\\Console\\Scheduling\\ScheduleFinishCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleFinishCommand.php', + 'Illuminate\\Console\\Scheduling\\ScheduleListCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleListCommand.php', 'Illuminate\\Console\\Scheduling\\ScheduleRunCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleRunCommand.php', + 'Illuminate\\Console\\Scheduling\\ScheduleTestCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleTestCommand.php', + 'Illuminate\\Console\\Scheduling\\ScheduleWorkCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleWorkCommand.php', 'Illuminate\\Console\\Scheduling\\SchedulingMutex' => $vendorDir . '/laravel/framework/src/Illuminate/Console/Scheduling/SchedulingMutex.php', 'Illuminate\\Container\\BoundMethod' => $vendorDir . '/laravel/framework/src/Illuminate/Container/BoundMethod.php', 'Illuminate\\Container\\Container' => $vendorDir . '/laravel/framework/src/Illuminate/Container/Container.php', @@ -1268,6 +1292,7 @@ return array( 'Illuminate\\Contracts\\Console\\Application' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Console/Application.php', 'Illuminate\\Contracts\\Console\\Kernel' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Console/Kernel.php', 'Illuminate\\Contracts\\Container\\BindingResolutionException' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Container/BindingResolutionException.php', + 'Illuminate\\Contracts\\Container\\CircularDependencyException' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Container/CircularDependencyException.php', 'Illuminate\\Contracts\\Container\\Container' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Container/Container.php', 'Illuminate\\Contracts\\Container\\ContextualBindingBuilder' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Container/ContextualBindingBuilder.php', 'Illuminate\\Contracts\\Cookie\\Factory' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Cookie/Factory.php', @@ -1275,18 +1300,23 @@ return array( 'Illuminate\\Contracts\\Database\\Eloquent\\Castable' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Database/Eloquent/Castable.php', 'Illuminate\\Contracts\\Database\\Eloquent\\CastsAttributes' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Database/Eloquent/CastsAttributes.php', 'Illuminate\\Contracts\\Database\\Eloquent\\CastsInboundAttributes' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Database/Eloquent/CastsInboundAttributes.php', + 'Illuminate\\Contracts\\Database\\Eloquent\\DeviatesCastableAttributes' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Database/Eloquent/DeviatesCastableAttributes.php', + 'Illuminate\\Contracts\\Database\\Eloquent\\SerializesCastableAttributes' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Database/Eloquent/SerializesCastableAttributes.php', + 'Illuminate\\Contracts\\Database\\Eloquent\\SupportsPartialRelations' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Database/Eloquent/SupportsPartialRelations.php', 'Illuminate\\Contracts\\Database\\Events\\MigrationEvent' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Database/Events/MigrationEvent.php', 'Illuminate\\Contracts\\Database\\ModelIdentifier' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Database/ModelIdentifier.php', 'Illuminate\\Contracts\\Debug\\ExceptionHandler' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Debug/ExceptionHandler.php', 'Illuminate\\Contracts\\Encryption\\DecryptException' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Encryption/DecryptException.php', 'Illuminate\\Contracts\\Encryption\\EncryptException' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Encryption/EncryptException.php', 'Illuminate\\Contracts\\Encryption\\Encrypter' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Encryption/Encrypter.php', + 'Illuminate\\Contracts\\Encryption\\StringEncrypter' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Encryption/StringEncrypter.php', 'Illuminate\\Contracts\\Events\\Dispatcher' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Events/Dispatcher.php', 'Illuminate\\Contracts\\Filesystem\\Cloud' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Filesystem/Cloud.php', 'Illuminate\\Contracts\\Filesystem\\Factory' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Filesystem/Factory.php', 'Illuminate\\Contracts\\Filesystem\\FileExistsException' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Filesystem/FileExistsException.php', 'Illuminate\\Contracts\\Filesystem\\FileNotFoundException' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Filesystem/FileNotFoundException.php', 'Illuminate\\Contracts\\Filesystem\\Filesystem' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Filesystem/Filesystem.php', + 'Illuminate\\Contracts\\Filesystem\\LockTimeoutException' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Filesystem/LockTimeoutException.php', 'Illuminate\\Contracts\\Foundation\\Application' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Foundation/Application.php', 'Illuminate\\Contracts\\Foundation\\CachesConfiguration' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Foundation/CachesConfiguration.php', 'Illuminate\\Contracts\\Foundation\\CachesRoutes' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Foundation/CachesRoutes.php', @@ -1298,10 +1328,12 @@ return array( 'Illuminate\\Contracts\\Mail\\Mailer' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Mail/Mailer.php', 'Illuminate\\Contracts\\Notifications\\Dispatcher' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Notifications/Dispatcher.php', 'Illuminate\\Contracts\\Notifications\\Factory' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Notifications/Factory.php', + 'Illuminate\\Contracts\\Pagination\\CursorPaginator' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Pagination/CursorPaginator.php', 'Illuminate\\Contracts\\Pagination\\LengthAwarePaginator' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Pagination/LengthAwarePaginator.php', 'Illuminate\\Contracts\\Pagination\\Paginator' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Pagination/Paginator.php', 'Illuminate\\Contracts\\Pipeline\\Hub' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Pipeline/Hub.php', 'Illuminate\\Contracts\\Pipeline\\Pipeline' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Pipeline/Pipeline.php', + 'Illuminate\\Contracts\\Queue\\ClearableQueue' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Queue/ClearableQueue.php', 'Illuminate\\Contracts\\Queue\\EntityNotFoundException' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Queue/EntityNotFoundException.php', 'Illuminate\\Contracts\\Queue\\EntityResolver' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Queue/EntityResolver.php', 'Illuminate\\Contracts\\Queue\\Factory' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Queue/Factory.php', @@ -1310,6 +1342,9 @@ return array( 'Illuminate\\Contracts\\Queue\\Queue' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Queue/Queue.php', 'Illuminate\\Contracts\\Queue\\QueueableCollection' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Queue/QueueableCollection.php', 'Illuminate\\Contracts\\Queue\\QueueableEntity' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Queue/QueueableEntity.php', + 'Illuminate\\Contracts\\Queue\\ShouldBeEncrypted' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Queue/ShouldBeEncrypted.php', + 'Illuminate\\Contracts\\Queue\\ShouldBeUnique' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Queue/ShouldBeUnique.php', + 'Illuminate\\Contracts\\Queue\\ShouldBeUniqueUntilProcessing' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Queue/ShouldBeUniqueUntilProcessing.php', 'Illuminate\\Contracts\\Queue\\ShouldQueue' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Queue/ShouldQueue.php', 'Illuminate\\Contracts\\Redis\\Connection' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Redis/Connection.php', 'Illuminate\\Contracts\\Redis\\Connector' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Redis/Connector.php', @@ -1333,11 +1368,14 @@ return array( 'Illuminate\\Contracts\\Translation\\HasLocalePreference' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Translation/HasLocalePreference.php', 'Illuminate\\Contracts\\Translation\\Loader' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Translation/Loader.php', 'Illuminate\\Contracts\\Translation\\Translator' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Translation/Translator.php', + 'Illuminate\\Contracts\\Validation\\DataAwareRule' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Validation/DataAwareRule.php', 'Illuminate\\Contracts\\Validation\\Factory' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Validation/Factory.php', 'Illuminate\\Contracts\\Validation\\ImplicitRule' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Validation/ImplicitRule.php', 'Illuminate\\Contracts\\Validation\\Rule' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Validation/Rule.php', + 'Illuminate\\Contracts\\Validation\\UncompromisedVerifier' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Validation/UncompromisedVerifier.php', 'Illuminate\\Contracts\\Validation\\ValidatesWhenResolved' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Validation/ValidatesWhenResolved.php', 'Illuminate\\Contracts\\Validation\\Validator' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Validation/Validator.php', + 'Illuminate\\Contracts\\Validation\\ValidatorAwareRule' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/Validation/ValidatorAwareRule.php', 'Illuminate\\Contracts\\View\\Engine' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/View/Engine.php', 'Illuminate\\Contracts\\View\\Factory' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/View/Factory.php', 'Illuminate\\Contracts\\View\\View' => $vendorDir . '/laravel/framework/src/Illuminate/Contracts/View/View.php', @@ -1348,6 +1386,7 @@ return array( 'Illuminate\\Cookie\\Middleware\\EncryptCookies' => $vendorDir . '/laravel/framework/src/Illuminate/Cookie/Middleware/EncryptCookies.php', 'Illuminate\\Database\\Capsule\\Manager' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Capsule/Manager.php', 'Illuminate\\Database\\Concerns\\BuildsQueries' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Concerns/BuildsQueries.php', + 'Illuminate\\Database\\Concerns\\ExplainsQueries' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Concerns/ExplainsQueries.php', 'Illuminate\\Database\\Concerns\\ManagesTransactions' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Concerns/ManagesTransactions.php', 'Illuminate\\Database\\ConfigurationUrlParser' => $vendorDir . '/laravel/framework/src/Illuminate/Database/ConfigurationUrlParser.php', 'Illuminate\\Database\\Connection' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Connection.php', @@ -1361,6 +1400,8 @@ return array( 'Illuminate\\Database\\Connectors\\PostgresConnector' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Connectors/PostgresConnector.php', 'Illuminate\\Database\\Connectors\\SQLiteConnector' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Connectors/SQLiteConnector.php', 'Illuminate\\Database\\Connectors\\SqlServerConnector' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Connectors/SqlServerConnector.php', + 'Illuminate\\Database\\Console\\DbCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Console/DbCommand.php', + 'Illuminate\\Database\\Console\\DumpCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Console/DumpCommand.php', 'Illuminate\\Database\\Console\\Factories\\FactoryMakeCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Console/Factories/FactoryMakeCommand.php', 'Illuminate\\Database\\Console\\Migrations\\BaseCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Console/Migrations/BaseCommand.php', 'Illuminate\\Database\\Console\\Migrations\\FreshCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Console/Migrations/FreshCommand.php', @@ -1375,11 +1416,19 @@ return array( 'Illuminate\\Database\\Console\\Seeds\\SeedCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Console/Seeds/SeedCommand.php', 'Illuminate\\Database\\Console\\Seeds\\SeederMakeCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Console/Seeds/SeederMakeCommand.php', 'Illuminate\\Database\\Console\\WipeCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Console/WipeCommand.php', + 'Illuminate\\Database\\DBAL\\TimestampType' => $vendorDir . '/laravel/framework/src/Illuminate/Database/DBAL/TimestampType.php', 'Illuminate\\Database\\DatabaseManager' => $vendorDir . '/laravel/framework/src/Illuminate/Database/DatabaseManager.php', 'Illuminate\\Database\\DatabaseServiceProvider' => $vendorDir . '/laravel/framework/src/Illuminate/Database/DatabaseServiceProvider.php', + 'Illuminate\\Database\\DatabaseTransactionRecord' => $vendorDir . '/laravel/framework/src/Illuminate/Database/DatabaseTransactionRecord.php', + 'Illuminate\\Database\\DatabaseTransactionsManager' => $vendorDir . '/laravel/framework/src/Illuminate/Database/DatabaseTransactionsManager.php', 'Illuminate\\Database\\DetectsConcurrencyErrors' => $vendorDir . '/laravel/framework/src/Illuminate/Database/DetectsConcurrencyErrors.php', 'Illuminate\\Database\\DetectsLostConnections' => $vendorDir . '/laravel/framework/src/Illuminate/Database/DetectsLostConnections.php', 'Illuminate\\Database\\Eloquent\\Builder' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Builder.php', + 'Illuminate\\Database\\Eloquent\\Casts\\ArrayObject' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Casts/ArrayObject.php', + 'Illuminate\\Database\\Eloquent\\Casts\\AsArrayObject' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsArrayObject.php', + 'Illuminate\\Database\\Eloquent\\Casts\\AsCollection' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsCollection.php', + 'Illuminate\\Database\\Eloquent\\Casts\\AsEncryptedArrayObject' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsEncryptedArrayObject.php', + 'Illuminate\\Database\\Eloquent\\Casts\\AsEncryptedCollection' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsEncryptedCollection.php', 'Illuminate\\Database\\Eloquent\\Collection' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Collection.php', 'Illuminate\\Database\\Eloquent\\Concerns\\GuardsAttributes' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/GuardsAttributes.php', 'Illuminate\\Database\\Eloquent\\Concerns\\HasAttributes' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HasAttributes.php', @@ -1389,9 +1438,14 @@ return array( 'Illuminate\\Database\\Eloquent\\Concerns\\HasTimestamps' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HasTimestamps.php', 'Illuminate\\Database\\Eloquent\\Concerns\\HidesAttributes' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HidesAttributes.php', 'Illuminate\\Database\\Eloquent\\Concerns\\QueriesRelationships' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/QueriesRelationships.php', - 'Illuminate\\Database\\Eloquent\\Factory' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Factory.php', - 'Illuminate\\Database\\Eloquent\\FactoryBuilder' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/FactoryBuilder.php', + 'Illuminate\\Database\\Eloquent\\Factories\\BelongsToManyRelationship' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Factories/BelongsToManyRelationship.php', + 'Illuminate\\Database\\Eloquent\\Factories\\BelongsToRelationship' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Factories/BelongsToRelationship.php', + 'Illuminate\\Database\\Eloquent\\Factories\\Factory' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Factories/Factory.php', + 'Illuminate\\Database\\Eloquent\\Factories\\HasFactory' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Factories/HasFactory.php', + 'Illuminate\\Database\\Eloquent\\Factories\\Relationship' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Factories/Relationship.php', + 'Illuminate\\Database\\Eloquent\\Factories\\Sequence' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Factories/Sequence.php', 'Illuminate\\Database\\Eloquent\\HigherOrderBuilderProxy' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/HigherOrderBuilderProxy.php', + 'Illuminate\\Database\\Eloquent\\InvalidCastException' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/InvalidCastException.php', 'Illuminate\\Database\\Eloquent\\JsonEncodingException' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/JsonEncodingException.php', 'Illuminate\\Database\\Eloquent\\MassAssignmentException' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/MassAssignmentException.php', 'Illuminate\\Database\\Eloquent\\Model' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Model.php', @@ -1401,6 +1455,9 @@ return array( 'Illuminate\\Database\\Eloquent\\Relations\\BelongsTo' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Relations/BelongsTo.php', 'Illuminate\\Database\\Eloquent\\Relations\\BelongsToMany' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Relations/BelongsToMany.php', 'Illuminate\\Database\\Eloquent\\Relations\\Concerns\\AsPivot' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/AsPivot.php', + 'Illuminate\\Database\\Eloquent\\Relations\\Concerns\\CanBeOneOfMany' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/CanBeOneOfMany.php', + 'Illuminate\\Database\\Eloquent\\Relations\\Concerns\\ComparesRelatedModels' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/ComparesRelatedModels.php', + 'Illuminate\\Database\\Eloquent\\Relations\\Concerns\\InteractsWithDictionary' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/InteractsWithDictionary.php', 'Illuminate\\Database\\Eloquent\\Relations\\Concerns\\InteractsWithPivotTable' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/InteractsWithPivotTable.php', 'Illuminate\\Database\\Eloquent\\Relations\\Concerns\\SupportsDefaultModels' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/SupportsDefaultModels.php', 'Illuminate\\Database\\Eloquent\\Relations\\HasMany' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/Relations/HasMany.php', @@ -1420,6 +1477,7 @@ return array( 'Illuminate\\Database\\Eloquent\\SoftDeletes' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/SoftDeletes.php', 'Illuminate\\Database\\Eloquent\\SoftDeletingScope' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Eloquent/SoftDeletingScope.php', 'Illuminate\\Database\\Events\\ConnectionEvent' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Events/ConnectionEvent.php', + 'Illuminate\\Database\\Events\\DatabaseRefreshed' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Events/DatabaseRefreshed.php', 'Illuminate\\Database\\Events\\MigrationEnded' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Events/MigrationEnded.php', 'Illuminate\\Database\\Events\\MigrationEvent' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Events/MigrationEvent.php', 'Illuminate\\Database\\Events\\MigrationStarted' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Events/MigrationStarted.php', @@ -1427,18 +1485,29 @@ return array( 'Illuminate\\Database\\Events\\MigrationsStarted' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Events/MigrationsStarted.php', 'Illuminate\\Database\\Events\\NoPendingMigrations' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Events/NoPendingMigrations.php', 'Illuminate\\Database\\Events\\QueryExecuted' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Events/QueryExecuted.php', + 'Illuminate\\Database\\Events\\SchemaDumped' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Events/SchemaDumped.php', + 'Illuminate\\Database\\Events\\SchemaLoaded' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Events/SchemaLoaded.php', 'Illuminate\\Database\\Events\\StatementPrepared' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Events/StatementPrepared.php', 'Illuminate\\Database\\Events\\TransactionBeginning' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Events/TransactionBeginning.php', 'Illuminate\\Database\\Events\\TransactionCommitted' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Events/TransactionCommitted.php', 'Illuminate\\Database\\Events\\TransactionRolledBack' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Events/TransactionRolledBack.php', 'Illuminate\\Database\\Grammar' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Grammar.php', + 'Illuminate\\Database\\LazyLoadingViolationException' => $vendorDir . '/laravel/framework/src/Illuminate/Database/LazyLoadingViolationException.php', 'Illuminate\\Database\\MigrationServiceProvider' => $vendorDir . '/laravel/framework/src/Illuminate/Database/MigrationServiceProvider.php', 'Illuminate\\Database\\Migrations\\DatabaseMigrationRepository' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Migrations/DatabaseMigrationRepository.php', 'Illuminate\\Database\\Migrations\\Migration' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Migrations/Migration.php', 'Illuminate\\Database\\Migrations\\MigrationCreator' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Migrations/MigrationCreator.php', 'Illuminate\\Database\\Migrations\\MigrationRepositoryInterface' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Migrations/MigrationRepositoryInterface.php', 'Illuminate\\Database\\Migrations\\Migrator' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Migrations/Migrator.php', + 'Illuminate\\Database\\MultipleRecordsFoundException' => $vendorDir . '/laravel/framework/src/Illuminate/Database/MultipleRecordsFoundException.php', 'Illuminate\\Database\\MySqlConnection' => $vendorDir . '/laravel/framework/src/Illuminate/Database/MySqlConnection.php', + 'Illuminate\\Database\\PDO\\Concerns\\ConnectsToDatabase' => $vendorDir . '/laravel/framework/src/Illuminate/Database/PDO/Concerns/ConnectsToDatabase.php', + 'Illuminate\\Database\\PDO\\Connection' => $vendorDir . '/laravel/framework/src/Illuminate/Database/PDO/Connection.php', + 'Illuminate\\Database\\PDO\\MySqlDriver' => $vendorDir . '/laravel/framework/src/Illuminate/Database/PDO/MySqlDriver.php', + 'Illuminate\\Database\\PDO\\PostgresDriver' => $vendorDir . '/laravel/framework/src/Illuminate/Database/PDO/PostgresDriver.php', + 'Illuminate\\Database\\PDO\\SQLiteDriver' => $vendorDir . '/laravel/framework/src/Illuminate/Database/PDO/SQLiteDriver.php', + 'Illuminate\\Database\\PDO\\SqlServerConnection' => $vendorDir . '/laravel/framework/src/Illuminate/Database/PDO/SqlServerConnection.php', + 'Illuminate\\Database\\PDO\\SqlServerDriver' => $vendorDir . '/laravel/framework/src/Illuminate/Database/PDO/SqlServerDriver.php', 'Illuminate\\Database\\PostgresConnection' => $vendorDir . '/laravel/framework/src/Illuminate/Database/PostgresConnection.php', 'Illuminate\\Database\\QueryException' => $vendorDir . '/laravel/framework/src/Illuminate/Database/QueryException.php', 'Illuminate\\Database\\Query\\Builder' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Query/Builder.php', @@ -1454,6 +1523,7 @@ return array( 'Illuminate\\Database\\Query\\Processors\\Processor' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Query/Processors/Processor.php', 'Illuminate\\Database\\Query\\Processors\\SQLiteProcessor' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Query/Processors/SQLiteProcessor.php', 'Illuminate\\Database\\Query\\Processors\\SqlServerProcessor' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Query/Processors/SqlServerProcessor.php', + 'Illuminate\\Database\\RecordsNotFoundException' => $vendorDir . '/laravel/framework/src/Illuminate/Database/RecordsNotFoundException.php', 'Illuminate\\Database\\SQLiteConnection' => $vendorDir . '/laravel/framework/src/Illuminate/Database/SQLiteConnection.php', 'Illuminate\\Database\\Schema\\Blueprint' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Schema/Blueprint.php', 'Illuminate\\Database\\Schema\\Builder' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Schema/Builder.php', @@ -1468,28 +1538,37 @@ return array( 'Illuminate\\Database\\Schema\\Grammars\\SQLiteGrammar' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Schema/Grammars/SQLiteGrammar.php', 'Illuminate\\Database\\Schema\\Grammars\\SqlServerGrammar' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Schema/Grammars/SqlServerGrammar.php', 'Illuminate\\Database\\Schema\\MySqlBuilder' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Schema/MySqlBuilder.php', + 'Illuminate\\Database\\Schema\\MySqlSchemaState' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Schema/MySqlSchemaState.php', 'Illuminate\\Database\\Schema\\PostgresBuilder' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Schema/PostgresBuilder.php', + 'Illuminate\\Database\\Schema\\PostgresSchemaState' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Schema/PostgresSchemaState.php', 'Illuminate\\Database\\Schema\\SQLiteBuilder' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Schema/SQLiteBuilder.php', + 'Illuminate\\Database\\Schema\\SchemaState' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Schema/SchemaState.php', 'Illuminate\\Database\\Schema\\SqlServerBuilder' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Schema/SqlServerBuilder.php', + 'Illuminate\\Database\\Schema\\SqliteSchemaState' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Schema/SqliteSchemaState.php', 'Illuminate\\Database\\Seeder' => $vendorDir . '/laravel/framework/src/Illuminate/Database/Seeder.php', 'Illuminate\\Database\\SqlServerConnection' => $vendorDir . '/laravel/framework/src/Illuminate/Database/SqlServerConnection.php', 'Illuminate\\Encryption\\Encrypter' => $vendorDir . '/laravel/framework/src/Illuminate/Encryption/Encrypter.php', 'Illuminate\\Encryption\\EncryptionServiceProvider' => $vendorDir . '/laravel/framework/src/Illuminate/Encryption/EncryptionServiceProvider.php', + 'Illuminate\\Encryption\\MissingAppKeyException' => $vendorDir . '/laravel/framework/src/Illuminate/Encryption/MissingAppKeyException.php', 'Illuminate\\Events\\CallQueuedListener' => $vendorDir . '/laravel/framework/src/Illuminate/Events/CallQueuedListener.php', 'Illuminate\\Events\\Dispatcher' => $vendorDir . '/laravel/framework/src/Illuminate/Events/Dispatcher.php', 'Illuminate\\Events\\EventServiceProvider' => $vendorDir . '/laravel/framework/src/Illuminate/Events/EventServiceProvider.php', + 'Illuminate\\Events\\InvokeQueuedClosure' => $vendorDir . '/laravel/framework/src/Illuminate/Events/InvokeQueuedClosure.php', 'Illuminate\\Events\\NullDispatcher' => $vendorDir . '/laravel/framework/src/Illuminate/Events/NullDispatcher.php', + 'Illuminate\\Events\\QueuedClosure' => $vendorDir . '/laravel/framework/src/Illuminate/Events/QueuedClosure.php', 'Illuminate\\Filesystem\\Cache' => $vendorDir . '/laravel/framework/src/Illuminate/Filesystem/Cache.php', 'Illuminate\\Filesystem\\Filesystem' => $vendorDir . '/laravel/framework/src/Illuminate/Filesystem/Filesystem.php', 'Illuminate\\Filesystem\\FilesystemAdapter' => $vendorDir . '/laravel/framework/src/Illuminate/Filesystem/FilesystemAdapter.php', 'Illuminate\\Filesystem\\FilesystemManager' => $vendorDir . '/laravel/framework/src/Illuminate/Filesystem/FilesystemManager.php', 'Illuminate\\Filesystem\\FilesystemServiceProvider' => $vendorDir . '/laravel/framework/src/Illuminate/Filesystem/FilesystemServiceProvider.php', + 'Illuminate\\Filesystem\\LockableFile' => $vendorDir . '/laravel/framework/src/Illuminate/Filesystem/LockableFile.php', 'Illuminate\\Foundation\\AliasLoader' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/AliasLoader.php', 'Illuminate\\Foundation\\Application' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Application.php', 'Illuminate\\Foundation\\Auth\\Access\\Authorizable' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Auth/Access/Authorizable.php', 'Illuminate\\Foundation\\Auth\\Access\\AuthorizesRequests' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Auth/Access/AuthorizesRequests.php', 'Illuminate\\Foundation\\Auth\\AuthenticatesUsers' => $vendorDir . '/laravel/ui/auth-backend/AuthenticatesUsers.php', 'Illuminate\\Foundation\\Auth\\ConfirmsPasswords' => $vendorDir . '/laravel/ui/auth-backend/ConfirmsPasswords.php', + 'Illuminate\\Foundation\\Auth\\EmailVerificationRequest' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Auth/EmailVerificationRequest.php', 'Illuminate\\Foundation\\Auth\\RedirectsUsers' => $vendorDir . '/laravel/ui/auth-backend/RedirectsUsers.php', 'Illuminate\\Foundation\\Auth\\RegistersUsers' => $vendorDir . '/laravel/ui/auth-backend/RegistersUsers.php', 'Illuminate\\Foundation\\Auth\\ResetsPasswords' => $vendorDir . '/laravel/ui/auth-backend/ResetsPasswords.php', @@ -1507,6 +1586,7 @@ return array( 'Illuminate\\Foundation\\Bus\\Dispatchable' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Bus/Dispatchable.php', 'Illuminate\\Foundation\\Bus\\DispatchesJobs' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Bus/DispatchesJobs.php', 'Illuminate\\Foundation\\Bus\\PendingChain' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Bus/PendingChain.php', + 'Illuminate\\Foundation\\Bus\\PendingClosureDispatch' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Bus/PendingClosureDispatch.php', 'Illuminate\\Foundation\\Bus\\PendingDispatch' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Bus/PendingDispatch.php', 'Illuminate\\Foundation\\ComposerScripts' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/ComposerScripts.php', 'Illuminate\\Foundation\\Console\\CastMakeCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Console/CastMakeCommand.php', @@ -1557,14 +1637,19 @@ return array( 'Illuminate\\Foundation\\Events\\DiscoverEvents' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Events/DiscoverEvents.php', 'Illuminate\\Foundation\\Events\\Dispatchable' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Events/Dispatchable.php', 'Illuminate\\Foundation\\Events\\LocaleUpdated' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Events/LocaleUpdated.php', + 'Illuminate\\Foundation\\Events\\VendorTagPublished' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Events/VendorTagPublished.php', 'Illuminate\\Foundation\\Exceptions\\Handler' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Exceptions/Handler.php', + 'Illuminate\\Foundation\\Exceptions\\RegisterErrorViewPaths' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Exceptions/RegisterErrorViewPaths.php', + 'Illuminate\\Foundation\\Exceptions\\ReportableHandler' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Exceptions/ReportableHandler.php', 'Illuminate\\Foundation\\Exceptions\\WhoopsHandler' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Exceptions/WhoopsHandler.php', 'Illuminate\\Foundation\\Http\\Events\\RequestHandled' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Http/Events/RequestHandled.php', 'Illuminate\\Foundation\\Http\\Exceptions\\MaintenanceModeException' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Http/Exceptions/MaintenanceModeException.php', 'Illuminate\\Foundation\\Http\\FormRequest' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Http/FormRequest.php', 'Illuminate\\Foundation\\Http\\Kernel' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php', + 'Illuminate\\Foundation\\Http\\MaintenanceModeBypassCookie' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Http/MaintenanceModeBypassCookie.php', 'Illuminate\\Foundation\\Http\\Middleware\\CheckForMaintenanceMode' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Http/Middleware/CheckForMaintenanceMode.php', 'Illuminate\\Foundation\\Http\\Middleware\\ConvertEmptyStringsToNull' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ConvertEmptyStringsToNull.php', + 'Illuminate\\Foundation\\Http\\Middleware\\PreventRequestsDuringMaintenance' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Http/Middleware/PreventRequestsDuringMaintenance.php', 'Illuminate\\Foundation\\Http\\Middleware\\TransformsRequest' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php', 'Illuminate\\Foundation\\Http\\Middleware\\TrimStrings' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TrimStrings.php', 'Illuminate\\Foundation\\Http\\Middleware\\ValidatePostSize' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ValidatePostSize.php', @@ -1588,6 +1673,8 @@ return array( 'Illuminate\\Foundation\\Testing\\Concerns\\InteractsWithExceptionHandling' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithExceptionHandling.php', 'Illuminate\\Foundation\\Testing\\Concerns\\InteractsWithRedis' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithRedis.php', 'Illuminate\\Foundation\\Testing\\Concerns\\InteractsWithSession' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithSession.php', + 'Illuminate\\Foundation\\Testing\\Concerns\\InteractsWithTime' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithTime.php', + 'Illuminate\\Foundation\\Testing\\Concerns\\InteractsWithViews' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithViews.php', 'Illuminate\\Foundation\\Testing\\Concerns\\MakesHttpRequests' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/MakesHttpRequests.php', 'Illuminate\\Foundation\\Testing\\Concerns\\MocksApplicationServices' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/MocksApplicationServices.php', 'Illuminate\\Foundation\\Testing\\DatabaseMigrations' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Testing/DatabaseMigrations.php', @@ -1598,6 +1685,7 @@ return array( 'Illuminate\\Foundation\\Testing\\WithFaker' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Testing/WithFaker.php', 'Illuminate\\Foundation\\Testing\\WithoutEvents' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Testing/WithoutEvents.php', 'Illuminate\\Foundation\\Testing\\WithoutMiddleware' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Testing/WithoutMiddleware.php', + 'Illuminate\\Foundation\\Testing\\Wormhole' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Testing/Wormhole.php', 'Illuminate\\Foundation\\Validation\\ValidatesRequests' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/Validation/ValidatesRequests.php', 'Illuminate\\Hashing\\AbstractHasher' => $vendorDir . '/laravel/framework/src/Illuminate/Hashing/AbstractHasher.php', 'Illuminate\\Hashing\\Argon2IdHasher' => $vendorDir . '/laravel/framework/src/Illuminate/Hashing/Argon2IdHasher.php', @@ -1609,6 +1697,7 @@ return array( 'Illuminate\\Http\\Client\\Factory' => $vendorDir . '/laravel/framework/src/Illuminate/Http/Client/Factory.php', 'Illuminate\\Http\\Client\\HttpClientException' => $vendorDir . '/laravel/framework/src/Illuminate/Http/Client/HttpClientException.php', 'Illuminate\\Http\\Client\\PendingRequest' => $vendorDir . '/laravel/framework/src/Illuminate/Http/Client/PendingRequest.php', + 'Illuminate\\Http\\Client\\Pool' => $vendorDir . '/laravel/framework/src/Illuminate/Http/Client/Pool.php', 'Illuminate\\Http\\Client\\Request' => $vendorDir . '/laravel/framework/src/Illuminate/Http/Client/Request.php', 'Illuminate\\Http\\Client\\RequestException' => $vendorDir . '/laravel/framework/src/Illuminate/Http/Client/RequestException.php', 'Illuminate\\Http\\Client\\Response' => $vendorDir . '/laravel/framework/src/Illuminate/Http/Client/Response.php', @@ -1689,9 +1778,14 @@ return array( 'Illuminate\\Notifications\\NotificationServiceProvider' => $vendorDir . '/laravel/framework/src/Illuminate/Notifications/NotificationServiceProvider.php', 'Illuminate\\Notifications\\RoutesNotifications' => $vendorDir . '/laravel/framework/src/Illuminate/Notifications/RoutesNotifications.php', 'Illuminate\\Notifications\\SendQueuedNotifications' => $vendorDir . '/laravel/framework/src/Illuminate/Notifications/SendQueuedNotifications.php', + 'Illuminate\\Pagination\\AbstractCursorPaginator' => $vendorDir . '/laravel/framework/src/Illuminate/Pagination/AbstractCursorPaginator.php', 'Illuminate\\Pagination\\AbstractPaginator' => $vendorDir . '/laravel/framework/src/Illuminate/Pagination/AbstractPaginator.php', + 'Illuminate\\Pagination\\Cursor' => $vendorDir . '/laravel/framework/src/Illuminate/Pagination/Cursor.php', + 'Illuminate\\Pagination\\CursorPaginationException' => $vendorDir . '/laravel/framework/src/Illuminate/Pagination/CursorPaginationException.php', + 'Illuminate\\Pagination\\CursorPaginator' => $vendorDir . '/laravel/framework/src/Illuminate/Pagination/CursorPaginator.php', 'Illuminate\\Pagination\\LengthAwarePaginator' => $vendorDir . '/laravel/framework/src/Illuminate/Pagination/LengthAwarePaginator.php', 'Illuminate\\Pagination\\PaginationServiceProvider' => $vendorDir . '/laravel/framework/src/Illuminate/Pagination/PaginationServiceProvider.php', + 'Illuminate\\Pagination\\PaginationState' => $vendorDir . '/laravel/framework/src/Illuminate/Pagination/PaginationState.php', 'Illuminate\\Pagination\\Paginator' => $vendorDir . '/laravel/framework/src/Illuminate/Pagination/Paginator.php', 'Illuminate\\Pagination\\UrlWindow' => $vendorDir . '/laravel/framework/src/Illuminate/Pagination/UrlWindow.php', 'Illuminate\\Pipeline\\Hub' => $vendorDir . '/laravel/framework/src/Illuminate/Pipeline/Hub.php', @@ -1708,12 +1802,16 @@ return array( 'Illuminate\\Queue\\Connectors\\RedisConnector' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Connectors/RedisConnector.php', 'Illuminate\\Queue\\Connectors\\SqsConnector' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Connectors/SqsConnector.php', 'Illuminate\\Queue\\Connectors\\SyncConnector' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Connectors/SyncConnector.php', + 'Illuminate\\Queue\\Console\\BatchesTableCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Console/BatchesTableCommand.php', + 'Illuminate\\Queue\\Console\\ClearCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Console/ClearCommand.php', 'Illuminate\\Queue\\Console\\FailedTableCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Console/FailedTableCommand.php', 'Illuminate\\Queue\\Console\\FlushFailedCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Console/FlushFailedCommand.php', 'Illuminate\\Queue\\Console\\ForgetFailedCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Console/ForgetFailedCommand.php', 'Illuminate\\Queue\\Console\\ListFailedCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Console/ListFailedCommand.php', 'Illuminate\\Queue\\Console\\ListenCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Console/ListenCommand.php', + 'Illuminate\\Queue\\Console\\PruneBatchesCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Console/PruneBatchesCommand.php', 'Illuminate\\Queue\\Console\\RestartCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Console/RestartCommand.php', + 'Illuminate\\Queue\\Console\\RetryBatchCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Console/RetryBatchCommand.php', 'Illuminate\\Queue\\Console\\RetryCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Console/RetryCommand.php', 'Illuminate\\Queue\\Console\\TableCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Console/TableCommand.php', 'Illuminate\\Queue\\Console\\WorkCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Console/WorkCommand.php', @@ -1722,9 +1820,11 @@ return array( 'Illuminate\\Queue\\Events\\JobFailed' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Events/JobFailed.php', 'Illuminate\\Queue\\Events\\JobProcessed' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Events/JobProcessed.php', 'Illuminate\\Queue\\Events\\JobProcessing' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Events/JobProcessing.php', + 'Illuminate\\Queue\\Events\\JobQueued' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Events/JobQueued.php', 'Illuminate\\Queue\\Events\\Looping' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Events/Looping.php', 'Illuminate\\Queue\\Events\\WorkerStopping' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Events/WorkerStopping.php', 'Illuminate\\Queue\\Failed\\DatabaseFailedJobProvider' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Failed/DatabaseFailedJobProvider.php', + 'Illuminate\\Queue\\Failed\\DatabaseUuidFailedJobProvider' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Failed/DatabaseUuidFailedJobProvider.php', 'Illuminate\\Queue\\Failed\\DynamoDbFailedJobProvider' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Failed/DynamoDbFailedJobProvider.php', 'Illuminate\\Queue\\Failed\\FailedJobProviderInterface' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Failed/FailedJobProviderInterface.php', 'Illuminate\\Queue\\Failed\\NullFailedJobProvider' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Failed/NullFailedJobProvider.php', @@ -1743,6 +1843,11 @@ return array( 'Illuminate\\Queue\\LuaScripts' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/LuaScripts.php', 'Illuminate\\Queue\\ManuallyFailedException' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/ManuallyFailedException.php', 'Illuminate\\Queue\\MaxAttemptsExceededException' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/MaxAttemptsExceededException.php', + 'Illuminate\\Queue\\Middleware\\RateLimited' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Middleware/RateLimited.php', + 'Illuminate\\Queue\\Middleware\\RateLimitedWithRedis' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Middleware/RateLimitedWithRedis.php', + 'Illuminate\\Queue\\Middleware\\ThrottlesExceptions' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Middleware/ThrottlesExceptions.php', + 'Illuminate\\Queue\\Middleware\\ThrottlesExceptionsWithRedis' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Middleware/ThrottlesExceptionsWithRedis.php', + 'Illuminate\\Queue\\Middleware\\WithoutOverlapping' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Middleware/WithoutOverlapping.php', 'Illuminate\\Queue\\NullQueue' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/NullQueue.php', 'Illuminate\\Queue\\Queue' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/Queue.php', 'Illuminate\\Queue\\QueueManager' => $vendorDir . '/laravel/framework/src/Illuminate/Queue/QueueManager.php', @@ -1777,6 +1882,7 @@ return array( 'Illuminate\\Routing\\Controller' => $vendorDir . '/laravel/framework/src/Illuminate/Routing/Controller.php', 'Illuminate\\Routing\\ControllerDispatcher' => $vendorDir . '/laravel/framework/src/Illuminate/Routing/ControllerDispatcher.php', 'Illuminate\\Routing\\ControllerMiddlewareOptions' => $vendorDir . '/laravel/framework/src/Illuminate/Routing/ControllerMiddlewareOptions.php', + 'Illuminate\\Routing\\CreatesRegularExpressionRouteConstraints' => $vendorDir . '/laravel/framework/src/Illuminate/Routing/CreatesRegularExpressionRouteConstraints.php', 'Illuminate\\Routing\\Events\\RouteMatched' => $vendorDir . '/laravel/framework/src/Illuminate/Routing/Events/RouteMatched.php', 'Illuminate\\Routing\\Exceptions\\InvalidSignatureException' => $vendorDir . '/laravel/framework/src/Illuminate/Routing/Exceptions/InvalidSignatureException.php', 'Illuminate\\Routing\\Exceptions\\UrlGenerationException' => $vendorDir . '/laravel/framework/src/Illuminate/Routing/Exceptions/UrlGenerationException.php', @@ -1831,13 +1937,13 @@ return array( 'Illuminate\\Session\\Store' => $vendorDir . '/laravel/framework/src/Illuminate/Session/Store.php', 'Illuminate\\Session\\TokenMismatchException' => $vendorDir . '/laravel/framework/src/Illuminate/Session/TokenMismatchException.php', 'Illuminate\\Support\\AggregateServiceProvider' => $vendorDir . '/laravel/framework/src/Illuminate/Support/AggregateServiceProvider.php', - 'Illuminate\\Support\\Arr' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Arr.php', + 'Illuminate\\Support\\Arr' => $vendorDir . '/laravel/framework/src/Illuminate/Collections/Arr.php', 'Illuminate\\Support\\Carbon' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Carbon.php', - 'Illuminate\\Support\\Collection' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Collection.php', + 'Illuminate\\Support\\Collection' => $vendorDir . '/laravel/framework/src/Illuminate/Collections/Collection.php', 'Illuminate\\Support\\Composer' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Composer.php', 'Illuminate\\Support\\ConfigurationUrlParser' => $vendorDir . '/laravel/framework/src/Illuminate/Support/ConfigurationUrlParser.php', 'Illuminate\\Support\\DateFactory' => $vendorDir . '/laravel/framework/src/Illuminate/Support/DateFactory.php', - 'Illuminate\\Support\\Enumerable' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Enumerable.php', + 'Illuminate\\Support\\Enumerable' => $vendorDir . '/laravel/framework/src/Illuminate/Collections/Enumerable.php', 'Illuminate\\Support\\Env' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Env.php', 'Illuminate\\Support\\Facades\\App' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Facades/App.php', 'Illuminate\\Support\\Facades\\Artisan' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Facades/Artisan.php', @@ -1861,8 +1967,10 @@ return array( 'Illuminate\\Support\\Facades\\Log' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Facades/Log.php', 'Illuminate\\Support\\Facades\\Mail' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Facades/Mail.php', 'Illuminate\\Support\\Facades\\Notification' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Facades/Notification.php', + 'Illuminate\\Support\\Facades\\ParallelTesting' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Facades/ParallelTesting.php', 'Illuminate\\Support\\Facades\\Password' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Facades/Password.php', 'Illuminate\\Support\\Facades\\Queue' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Facades/Queue.php', + 'Illuminate\\Support\\Facades\\RateLimiter' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Facades/RateLimiter.php', 'Illuminate\\Support\\Facades\\Redirect' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Facades/Redirect.php', 'Illuminate\\Support\\Facades\\Redis' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Facades/Redis.php', 'Illuminate\\Support\\Facades\\Request' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Facades/Request.php', @@ -1875,12 +1983,12 @@ return array( 'Illuminate\\Support\\Facades\\Validator' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Facades/Validator.php', 'Illuminate\\Support\\Facades\\View' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Facades/View.php', 'Illuminate\\Support\\Fluent' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Fluent.php', - 'Illuminate\\Support\\HigherOrderCollectionProxy' => $vendorDir . '/laravel/framework/src/Illuminate/Support/HigherOrderCollectionProxy.php', + 'Illuminate\\Support\\HigherOrderCollectionProxy' => $vendorDir . '/laravel/framework/src/Illuminate/Collections/HigherOrderCollectionProxy.php', 'Illuminate\\Support\\HigherOrderTapProxy' => $vendorDir . '/laravel/framework/src/Illuminate/Support/HigherOrderTapProxy.php', - 'Illuminate\\Support\\HigherOrderWhenProxy' => $vendorDir . '/laravel/framework/src/Illuminate/Support/HigherOrderWhenProxy.php', + 'Illuminate\\Support\\HigherOrderWhenProxy' => $vendorDir . '/laravel/framework/src/Illuminate/Collections/HigherOrderWhenProxy.php', 'Illuminate\\Support\\HtmlString' => $vendorDir . '/laravel/framework/src/Illuminate/Support/HtmlString.php', 'Illuminate\\Support\\InteractsWithTime' => $vendorDir . '/laravel/framework/src/Illuminate/Support/InteractsWithTime.php', - 'Illuminate\\Support\\LazyCollection' => $vendorDir . '/laravel/framework/src/Illuminate/Support/LazyCollection.php', + 'Illuminate\\Support\\LazyCollection' => $vendorDir . '/laravel/framework/src/Illuminate/Collections/LazyCollection.php', 'Illuminate\\Support\\Manager' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Manager.php', 'Illuminate\\Support\\MessageBag' => $vendorDir . '/laravel/framework/src/Illuminate/Support/MessageBag.php', 'Illuminate\\Support\\NamespacedItemResolver' => $vendorDir . '/laravel/framework/src/Illuminate/Support/NamespacedItemResolver.php', @@ -1891,28 +1999,43 @@ return array( 'Illuminate\\Support\\ServiceProvider' => $vendorDir . '/laravel/framework/src/Illuminate/Support/ServiceProvider.php', 'Illuminate\\Support\\Str' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Str.php', 'Illuminate\\Support\\Stringable' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Stringable.php', + 'Illuminate\\Support\\Testing\\Fakes\\BatchRepositoryFake' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Testing/Fakes/BatchRepositoryFake.php', 'Illuminate\\Support\\Testing\\Fakes\\BusFake' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Testing/Fakes/BusFake.php', 'Illuminate\\Support\\Testing\\Fakes\\EventFake' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Testing/Fakes/EventFake.php', 'Illuminate\\Support\\Testing\\Fakes\\MailFake' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Testing/Fakes/MailFake.php', 'Illuminate\\Support\\Testing\\Fakes\\NotificationFake' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Testing/Fakes/NotificationFake.php', + 'Illuminate\\Support\\Testing\\Fakes\\PendingBatchFake' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Testing/Fakes/PendingBatchFake.php', + 'Illuminate\\Support\\Testing\\Fakes\\PendingChainFake' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Testing/Fakes/PendingChainFake.php', 'Illuminate\\Support\\Testing\\Fakes\\PendingMailFake' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Testing/Fakes/PendingMailFake.php', 'Illuminate\\Support\\Testing\\Fakes\\QueueFake' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Testing/Fakes/QueueFake.php', 'Illuminate\\Support\\Traits\\CapsuleManagerTrait' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Traits/CapsuleManagerTrait.php', - 'Illuminate\\Support\\Traits\\EnumeratesValues' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Traits/EnumeratesValues.php', + 'Illuminate\\Support\\Traits\\EnumeratesValues' => $vendorDir . '/laravel/framework/src/Illuminate/Collections/Traits/EnumeratesValues.php', 'Illuminate\\Support\\Traits\\ForwardsCalls' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Traits/ForwardsCalls.php', 'Illuminate\\Support\\Traits\\Localizable' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Traits/Localizable.php', - 'Illuminate\\Support\\Traits\\Macroable' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Traits/Macroable.php', + 'Illuminate\\Support\\Traits\\Macroable' => $vendorDir . '/laravel/framework/src/Illuminate/Macroable/Traits/Macroable.php', 'Illuminate\\Support\\Traits\\ReflectsClosures' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Traits/ReflectsClosures.php', 'Illuminate\\Support\\Traits\\Tappable' => $vendorDir . '/laravel/framework/src/Illuminate/Support/Traits/Tappable.php', 'Illuminate\\Support\\ViewErrorBag' => $vendorDir . '/laravel/framework/src/Illuminate/Support/ViewErrorBag.php', 'Illuminate\\Testing\\Assert' => $vendorDir . '/laravel/framework/src/Illuminate/Testing/Assert.php', + 'Illuminate\\Testing\\AssertableJsonString' => $vendorDir . '/laravel/framework/src/Illuminate/Testing/AssertableJsonString.php', + 'Illuminate\\Testing\\Concerns\\TestDatabases' => $vendorDir . '/laravel/framework/src/Illuminate/Testing/Concerns/TestDatabases.php', 'Illuminate\\Testing\\Constraints\\ArraySubset' => $vendorDir . '/laravel/framework/src/Illuminate/Testing/Constraints/ArraySubset.php', 'Illuminate\\Testing\\Constraints\\CountInDatabase' => $vendorDir . '/laravel/framework/src/Illuminate/Testing/Constraints/CountInDatabase.php', 'Illuminate\\Testing\\Constraints\\HasInDatabase' => $vendorDir . '/laravel/framework/src/Illuminate/Testing/Constraints/HasInDatabase.php', 'Illuminate\\Testing\\Constraints\\SeeInOrder' => $vendorDir . '/laravel/framework/src/Illuminate/Testing/Constraints/SeeInOrder.php', 'Illuminate\\Testing\\Constraints\\SoftDeletedInDatabase' => $vendorDir . '/laravel/framework/src/Illuminate/Testing/Constraints/SoftDeletedInDatabase.php', + 'Illuminate\\Testing\\Fluent\\AssertableJson' => $vendorDir . '/laravel/framework/src/Illuminate/Testing/Fluent/AssertableJson.php', + 'Illuminate\\Testing\\Fluent\\Concerns\\Debugging' => $vendorDir . '/laravel/framework/src/Illuminate/Testing/Fluent/Concerns/Debugging.php', + 'Illuminate\\Testing\\Fluent\\Concerns\\Has' => $vendorDir . '/laravel/framework/src/Illuminate/Testing/Fluent/Concerns/Has.php', + 'Illuminate\\Testing\\Fluent\\Concerns\\Interaction' => $vendorDir . '/laravel/framework/src/Illuminate/Testing/Fluent/Concerns/Interaction.php', + 'Illuminate\\Testing\\Fluent\\Concerns\\Matching' => $vendorDir . '/laravel/framework/src/Illuminate/Testing/Fluent/Concerns/Matching.php', + 'Illuminate\\Testing\\ParallelConsoleOutput' => $vendorDir . '/laravel/framework/src/Illuminate/Testing/ParallelConsoleOutput.php', + 'Illuminate\\Testing\\ParallelRunner' => $vendorDir . '/laravel/framework/src/Illuminate/Testing/ParallelRunner.php', + 'Illuminate\\Testing\\ParallelTesting' => $vendorDir . '/laravel/framework/src/Illuminate/Testing/ParallelTesting.php', + 'Illuminate\\Testing\\ParallelTestingServiceProvider' => $vendorDir . '/laravel/framework/src/Illuminate/Testing/ParallelTestingServiceProvider.php', 'Illuminate\\Testing\\PendingCommand' => $vendorDir . '/laravel/framework/src/Illuminate/Testing/PendingCommand.php', 'Illuminate\\Testing\\TestResponse' => $vendorDir . '/laravel/framework/src/Illuminate/Testing/TestResponse.php', + 'Illuminate\\Testing\\TestView' => $vendorDir . '/laravel/framework/src/Illuminate/Testing/TestView.php', 'Illuminate\\Translation\\ArrayLoader' => $vendorDir . '/laravel/framework/src/Illuminate/Translation/ArrayLoader.php', 'Illuminate\\Translation\\FileLoader' => $vendorDir . '/laravel/framework/src/Illuminate/Translation/FileLoader.php', 'Illuminate\\Translation\\MessageSelector' => $vendorDir . '/laravel/framework/src/Illuminate/Translation/MessageSelector.php', @@ -1926,6 +2049,7 @@ return array( 'Illuminate\\Validation\\DatabasePresenceVerifier' => $vendorDir . '/laravel/framework/src/Illuminate/Validation/DatabasePresenceVerifier.php', 'Illuminate\\Validation\\DatabasePresenceVerifierInterface' => $vendorDir . '/laravel/framework/src/Illuminate/Validation/DatabasePresenceVerifierInterface.php', 'Illuminate\\Validation\\Factory' => $vendorDir . '/laravel/framework/src/Illuminate/Validation/Factory.php', + 'Illuminate\\Validation\\NotPwnedVerifier' => $vendorDir . '/laravel/framework/src/Illuminate/Validation/NotPwnedVerifier.php', 'Illuminate\\Validation\\PresenceVerifierInterface' => $vendorDir . '/laravel/framework/src/Illuminate/Validation/PresenceVerifierInterface.php', 'Illuminate\\Validation\\Rule' => $vendorDir . '/laravel/framework/src/Illuminate/Validation/Rule.php', 'Illuminate\\Validation\\Rules\\DatabaseRule' => $vendorDir . '/laravel/framework/src/Illuminate/Validation/Rules/DatabaseRule.php', @@ -1933,6 +2057,7 @@ return array( 'Illuminate\\Validation\\Rules\\Exists' => $vendorDir . '/laravel/framework/src/Illuminate/Validation/Rules/Exists.php', 'Illuminate\\Validation\\Rules\\In' => $vendorDir . '/laravel/framework/src/Illuminate/Validation/Rules/In.php', 'Illuminate\\Validation\\Rules\\NotIn' => $vendorDir . '/laravel/framework/src/Illuminate/Validation/Rules/NotIn.php', + 'Illuminate\\Validation\\Rules\\Password' => $vendorDir . '/laravel/framework/src/Illuminate/Validation/Rules/Password.php', 'Illuminate\\Validation\\Rules\\RequiredIf' => $vendorDir . '/laravel/framework/src/Illuminate/Validation/Rules/RequiredIf.php', 'Illuminate\\Validation\\Rules\\Unique' => $vendorDir . '/laravel/framework/src/Illuminate/Validation/Rules/Unique.php', 'Illuminate\\Validation\\UnauthorizedException' => $vendorDir . '/laravel/framework/src/Illuminate/Validation/UnauthorizedException.php', @@ -1943,6 +2068,7 @@ return array( 'Illuminate\\Validation\\ValidationServiceProvider' => $vendorDir . '/laravel/framework/src/Illuminate/Validation/ValidationServiceProvider.php', 'Illuminate\\Validation\\Validator' => $vendorDir . '/laravel/framework/src/Illuminate/Validation/Validator.php', 'Illuminate\\View\\AnonymousComponent' => $vendorDir . '/laravel/framework/src/Illuminate/View/AnonymousComponent.php', + 'Illuminate\\View\\AppendableAttributeValue' => $vendorDir . '/laravel/framework/src/Illuminate/View/AppendableAttributeValue.php', 'Illuminate\\View\\Compilers\\BladeCompiler' => $vendorDir . '/laravel/framework/src/Illuminate/View/Compilers/BladeCompiler.php', 'Illuminate\\View\\Compilers\\Compiler' => $vendorDir . '/laravel/framework/src/Illuminate/View/Compilers/Compiler.php', 'Illuminate\\View\\Compilers\\CompilerInterface' => $vendorDir . '/laravel/framework/src/Illuminate/View/Compilers/CompilerInterface.php', @@ -1970,6 +2096,7 @@ return array( 'Illuminate\\View\\Concerns\\ManagesLoops' => $vendorDir . '/laravel/framework/src/Illuminate/View/Concerns/ManagesLoops.php', 'Illuminate\\View\\Concerns\\ManagesStacks' => $vendorDir . '/laravel/framework/src/Illuminate/View/Concerns/ManagesStacks.php', 'Illuminate\\View\\Concerns\\ManagesTranslations' => $vendorDir . '/laravel/framework/src/Illuminate/View/Concerns/ManagesTranslations.php', + 'Illuminate\\View\\DynamicComponent' => $vendorDir . '/laravel/framework/src/Illuminate/View/DynamicComponent.php', 'Illuminate\\View\\Engines\\CompilerEngine' => $vendorDir . '/laravel/framework/src/Illuminate/View/Engines/CompilerEngine.php', 'Illuminate\\View\\Engines\\Engine' => $vendorDir . '/laravel/framework/src/Illuminate/View/Engines/Engine.php', 'Illuminate\\View\\Engines\\EngineResolver' => $vendorDir . '/laravel/framework/src/Illuminate/View/Engines/EngineResolver.php', @@ -1980,6 +2107,7 @@ return array( 'Illuminate\\View\\InvokableComponentVariable' => $vendorDir . '/laravel/framework/src/Illuminate/View/InvokableComponentVariable.php', 'Illuminate\\View\\Middleware\\ShareErrorsFromSession' => $vendorDir . '/laravel/framework/src/Illuminate/View/Middleware/ShareErrorsFromSession.php', 'Illuminate\\View\\View' => $vendorDir . '/laravel/framework/src/Illuminate/View/View.php', + 'Illuminate\\View\\ViewException' => $vendorDir . '/laravel/framework/src/Illuminate/View/ViewException.php', 'Illuminate\\View\\ViewFinderInterface' => $vendorDir . '/laravel/framework/src/Illuminate/View/ViewFinderInterface.php', 'Illuminate\\View\\ViewName' => $vendorDir . '/laravel/framework/src/Illuminate/View/ViewName.php', 'Illuminate\\View\\ViewServiceProvider' => $vendorDir . '/laravel/framework/src/Illuminate/View/ViewServiceProvider.php', @@ -2231,11 +2359,15 @@ return array( 'Laravel\\Horizon\\AutoScaler' => $vendorDir . '/laravel/horizon/src/AutoScaler.php', 'Laravel\\Horizon\\BackgroundProcess' => $vendorDir . '/laravel/horizon/src/BackgroundProcess.php', 'Laravel\\Horizon\\Connectors\\RedisConnector' => $vendorDir . '/laravel/horizon/src/Connectors/RedisConnector.php', + 'Laravel\\Horizon\\Console\\ClearCommand' => $vendorDir . '/laravel/horizon/src/Console/ClearCommand.php', 'Laravel\\Horizon\\Console\\ContinueCommand' => $vendorDir . '/laravel/horizon/src/Console/ContinueCommand.php', + 'Laravel\\Horizon\\Console\\ContinueSupervisorCommand' => $vendorDir . '/laravel/horizon/src/Console/ContinueSupervisorCommand.php', + 'Laravel\\Horizon\\Console\\ForgetFailedCommand' => $vendorDir . '/laravel/horizon/src/Console/ForgetFailedCommand.php', 'Laravel\\Horizon\\Console\\HorizonCommand' => $vendorDir . '/laravel/horizon/src/Console/HorizonCommand.php', 'Laravel\\Horizon\\Console\\InstallCommand' => $vendorDir . '/laravel/horizon/src/Console/InstallCommand.php', 'Laravel\\Horizon\\Console\\ListCommand' => $vendorDir . '/laravel/horizon/src/Console/ListCommand.php', 'Laravel\\Horizon\\Console\\PauseCommand' => $vendorDir . '/laravel/horizon/src/Console/PauseCommand.php', + 'Laravel\\Horizon\\Console\\PauseSupervisorCommand' => $vendorDir . '/laravel/horizon/src/Console/PauseSupervisorCommand.php', 'Laravel\\Horizon\\Console\\PublishCommand' => $vendorDir . '/laravel/horizon/src/Console/PublishCommand.php', 'Laravel\\Horizon\\Console\\PurgeCommand' => $vendorDir . '/laravel/horizon/src/Console/PurgeCommand.php', 'Laravel\\Horizon\\Console\\SnapshotCommand' => $vendorDir . '/laravel/horizon/src/Console/SnapshotCommand.php', @@ -2276,6 +2408,7 @@ return array( 'Laravel\\Horizon\\Horizon' => $vendorDir . '/laravel/horizon/src/Horizon.php', 'Laravel\\Horizon\\HorizonApplicationServiceProvider' => $vendorDir . '/laravel/horizon/src/HorizonApplicationServiceProvider.php', 'Laravel\\Horizon\\HorizonServiceProvider' => $vendorDir . '/laravel/horizon/src/HorizonServiceProvider.php', + 'Laravel\\Horizon\\Http\\Controllers\\BatchesController' => $vendorDir . '/laravel/horizon/src/Http/Controllers/BatchesController.php', 'Laravel\\Horizon\\Http\\Controllers\\CompletedJobsController' => $vendorDir . '/laravel/horizon/src/Http/Controllers/CompletedJobsController.php', 'Laravel\\Horizon\\Http\\Controllers\\Controller' => $vendorDir . '/laravel/horizon/src/Http/Controllers/Controller.php', 'Laravel\\Horizon\\Http\\Controllers\\DashboardStatsController' => $vendorDir . '/laravel/horizon/src/Http/Controllers/DashboardStatsController.php', @@ -2290,7 +2423,6 @@ return array( 'Laravel\\Horizon\\Http\\Controllers\\RetryController' => $vendorDir . '/laravel/horizon/src/Http/Controllers/RetryController.php', 'Laravel\\Horizon\\Http\\Controllers\\WorkloadController' => $vendorDir . '/laravel/horizon/src/Http/Controllers/WorkloadController.php', 'Laravel\\Horizon\\Http\\Middleware\\Authenticate' => $vendorDir . '/laravel/horizon/src/Http/Middleware/Authenticate.php', - 'Laravel\\Horizon\\JobId' => $vendorDir . '/laravel/horizon/src/JobId.php', 'Laravel\\Horizon\\JobPayload' => $vendorDir . '/laravel/horizon/src/JobPayload.php', 'Laravel\\Horizon\\Jobs\\MonitorTag' => $vendorDir . '/laravel/horizon/src/Jobs/MonitorTag.php', 'Laravel\\Horizon\\Jobs\\RetryFailedJob' => $vendorDir . '/laravel/horizon/src/Jobs/RetryFailedJob.php', @@ -2673,6 +2805,7 @@ return array( 'League\\OAuth1\\Client\\Signature\\RsaSha1Signature' => $vendorDir . '/league/oauth1-client/src/Signature/RsaSha1Signature.php', 'League\\OAuth1\\Client\\Signature\\Signature' => $vendorDir . '/league/oauth1-client/src/Signature/Signature.php', 'League\\OAuth1\\Client\\Signature\\SignatureInterface' => $vendorDir . '/league/oauth1-client/src/Signature/SignatureInterface.php', + 'Lorisleiva\\CronTranslator\\CronExpression' => $vendorDir . '/lorisleiva/cron-translator/src/CronExpression.php', 'Lorisleiva\\CronTranslator\\CronParsingException' => $vendorDir . '/lorisleiva/cron-translator/src/CronParsingException.php', 'Lorisleiva\\CronTranslator\\CronTranslator' => $vendorDir . '/lorisleiva/cron-translator/src/CronTranslator.php', 'Lorisleiva\\CronTranslator\\CronType' => $vendorDir . '/lorisleiva/cron-translator/src/CronType.php', @@ -2682,6 +2815,7 @@ return array( 'Lorisleiva\\CronTranslator\\HoursField' => $vendorDir . '/lorisleiva/cron-translator/src/HoursField.php', 'Lorisleiva\\CronTranslator\\MinutesField' => $vendorDir . '/lorisleiva/cron-translator/src/MinutesField.php', 'Lorisleiva\\CronTranslator\\MonthsField' => $vendorDir . '/lorisleiva/cron-translator/src/MonthsField.php', + 'Lorisleiva\\CronTranslator\\TranslationFileMissingException' => $vendorDir . '/lorisleiva/cron-translator/src/TranslationFileMissingException.php', 'Mockery' => $vendorDir . '/mockery/mockery/library/Mockery.php', 'Mockery\\Adapter\\Phpunit\\MockeryPHPUnitIntegration' => $vendorDir . '/mockery/mockery/library/Mockery/Adapter/Phpunit/MockeryPHPUnitIntegration.php', 'Mockery\\Adapter\\Phpunit\\MockeryPHPUnitIntegrationAssertPostConditions' => $vendorDir . '/mockery/mockery/library/Mockery/Adapter/Phpunit/MockeryPHPUnitIntegrationAssertPostConditions.php', @@ -2886,11 +3020,11 @@ return array( 'NunoMaduro\\Collision\\Adapters\\Laravel\\CollisionServiceProvider' => $vendorDir . '/nunomaduro/collision/src/Adapters/Laravel/CollisionServiceProvider.php', 'NunoMaduro\\Collision\\Adapters\\Laravel\\Commands\\TestCommand' => $vendorDir . '/nunomaduro/collision/src/Adapters/Laravel/Commands/TestCommand.php', 'NunoMaduro\\Collision\\Adapters\\Laravel\\ExceptionHandler' => $vendorDir . '/nunomaduro/collision/src/Adapters/Laravel/ExceptionHandler.php', + 'NunoMaduro\\Collision\\Adapters\\Laravel\\Exceptions\\RequirementsException' => $vendorDir . '/nunomaduro/collision/src/Adapters/Laravel/Exceptions/RequirementsException.php', 'NunoMaduro\\Collision\\Adapters\\Laravel\\IgnitionSolutionsRepository' => $vendorDir . '/nunomaduro/collision/src/Adapters/Laravel/IgnitionSolutionsRepository.php', 'NunoMaduro\\Collision\\Adapters\\Laravel\\Inspector' => $vendorDir . '/nunomaduro/collision/src/Adapters/Laravel/Inspector.php', 'NunoMaduro\\Collision\\Adapters\\Phpunit\\ConfigureIO' => $vendorDir . '/nunomaduro/collision/src/Adapters/Phpunit/ConfigureIO.php', 'NunoMaduro\\Collision\\Adapters\\Phpunit\\Printer' => $vendorDir . '/nunomaduro/collision/src/Adapters/Phpunit/Printer.php', - 'NunoMaduro\\Collision\\Adapters\\Phpunit\\PrinterContents' => $vendorDir . '/nunomaduro/collision/src/Adapters/Phpunit/PrinterContents.php', 'NunoMaduro\\Collision\\Adapters\\Phpunit\\State' => $vendorDir . '/nunomaduro/collision/src/Adapters/Phpunit/State.php', 'NunoMaduro\\Collision\\Adapters\\Phpunit\\Style' => $vendorDir . '/nunomaduro/collision/src/Adapters/Phpunit/Style.php', 'NunoMaduro\\Collision\\Adapters\\Phpunit\\TestResult' => $vendorDir . '/nunomaduro/collision/src/Adapters/Phpunit/TestResult.php', @@ -2903,8 +3037,11 @@ return array( 'NunoMaduro\\Collision\\Contracts\\Handler' => $vendorDir . '/nunomaduro/collision/src/Contracts/Handler.php', 'NunoMaduro\\Collision\\Contracts\\Highlighter' => $vendorDir . '/nunomaduro/collision/src/Contracts/Highlighter.php', 'NunoMaduro\\Collision\\Contracts\\Provider' => $vendorDir . '/nunomaduro/collision/src/Contracts/Provider.php', + 'NunoMaduro\\Collision\\Contracts\\RenderlessEditor' => $vendorDir . '/nunomaduro/collision/src/Contracts/RenderlessEditor.php', + 'NunoMaduro\\Collision\\Contracts\\RenderlessTrace' => $vendorDir . '/nunomaduro/collision/src/Contracts/RenderlessTrace.php', 'NunoMaduro\\Collision\\Contracts\\SolutionsRepository' => $vendorDir . '/nunomaduro/collision/src/Contracts/SolutionsRepository.php', 'NunoMaduro\\Collision\\Contracts\\Writer' => $vendorDir . '/nunomaduro/collision/src/Contracts/Writer.php', + 'NunoMaduro\\Collision\\Exceptions\\InvalidStyleException' => $vendorDir . '/nunomaduro/collision/src/Exceptions/InvalidStyleException.php', 'NunoMaduro\\Collision\\Exceptions\\ShouldNotHappen' => $vendorDir . '/nunomaduro/collision/src/Exceptions/ShouldNotHappen.php', 'NunoMaduro\\Collision\\Handler' => $vendorDir . '/nunomaduro/collision/src/Handler.php', 'NunoMaduro\\Collision\\Highlighter' => $vendorDir . '/nunomaduro/collision/src/Highlighter.php', @@ -2923,66 +3060,79 @@ return array( 'Opis\\Closure\\SerializableClosure' => $vendorDir . '/opis/closure/src/SerializableClosure.php', 'OrePricesSeeder' => $baseDir . '/database/seeds/OrePricesSeeder.php', 'PHPUnit\\Exception' => $vendorDir . '/phpunit/phpunit/src/Exception.php', + 'PHPUnit\\Framework\\ActualValueIsNotAnObjectException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/ActualValueIsNotAnObjectException.php', 'PHPUnit\\Framework\\Assert' => $vendorDir . '/phpunit/phpunit/src/Framework/Assert.php', 'PHPUnit\\Framework\\AssertionFailedError' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/AssertionFailedError.php', 'PHPUnit\\Framework\\CodeCoverageException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/CodeCoverageException.php', - 'PHPUnit\\Framework\\Constraint\\ArrayHasKey' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/ArrayHasKey.php', - 'PHPUnit\\Framework\\Constraint\\ArraySubset' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/ArraySubset.php', - 'PHPUnit\\Framework\\Constraint\\Attribute' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Attribute.php', + 'PHPUnit\\Framework\\ComparisonMethodDoesNotAcceptParameterTypeException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotAcceptParameterTypeException.php', + 'PHPUnit\\Framework\\ComparisonMethodDoesNotDeclareBoolReturnTypeException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotDeclareBoolReturnTypeException.php', + 'PHPUnit\\Framework\\ComparisonMethodDoesNotDeclareExactlyOneParameterException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotDeclareExactlyOneParameterException.php', + 'PHPUnit\\Framework\\ComparisonMethodDoesNotDeclareParameterTypeException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotDeclareParameterTypeException.php', + 'PHPUnit\\Framework\\ComparisonMethodDoesNotExistException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotExistException.php', + 'PHPUnit\\Framework\\Constraint\\ArrayHasKey' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Traversable/ArrayHasKey.php', + 'PHPUnit\\Framework\\Constraint\\BinaryOperator' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Operator/BinaryOperator.php', 'PHPUnit\\Framework\\Constraint\\Callback' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Callback.php', - 'PHPUnit\\Framework\\Constraint\\ClassHasAttribute' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/ClassHasAttribute.php', - 'PHPUnit\\Framework\\Constraint\\ClassHasStaticAttribute' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/ClassHasStaticAttribute.php', - 'PHPUnit\\Framework\\Constraint\\Composite' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Composite.php', + 'PHPUnit\\Framework\\Constraint\\ClassHasAttribute' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Object/ClassHasAttribute.php', + 'PHPUnit\\Framework\\Constraint\\ClassHasStaticAttribute' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Object/ClassHasStaticAttribute.php', 'PHPUnit\\Framework\\Constraint\\Constraint' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Constraint.php', - 'PHPUnit\\Framework\\Constraint\\Count' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Count.php', - 'PHPUnit\\Framework\\Constraint\\DirectoryExists' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/DirectoryExists.php', - 'PHPUnit\\Framework\\Constraint\\Exception' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Exception.php', - 'PHPUnit\\Framework\\Constraint\\ExceptionCode' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/ExceptionCode.php', - 'PHPUnit\\Framework\\Constraint\\ExceptionMessage' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/ExceptionMessage.php', - 'PHPUnit\\Framework\\Constraint\\ExceptionMessageRegularExpression' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/ExceptionMessageRegularExpression.php', - 'PHPUnit\\Framework\\Constraint\\FileExists' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/FileExists.php', - 'PHPUnit\\Framework\\Constraint\\GreaterThan' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/GreaterThan.php', + 'PHPUnit\\Framework\\Constraint\\Count' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Cardinality/Count.php', + 'PHPUnit\\Framework\\Constraint\\DirectoryExists' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Filesystem/DirectoryExists.php', + 'PHPUnit\\Framework\\Constraint\\Exception' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Exception/Exception.php', + 'PHPUnit\\Framework\\Constraint\\ExceptionCode' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionCode.php', + 'PHPUnit\\Framework\\Constraint\\ExceptionMessage' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionMessage.php', + 'PHPUnit\\Framework\\Constraint\\ExceptionMessageRegularExpression' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionMessageRegularExpression.php', + 'PHPUnit\\Framework\\Constraint\\FileExists' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Filesystem/FileExists.php', + 'PHPUnit\\Framework\\Constraint\\GreaterThan' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Cardinality/GreaterThan.php', 'PHPUnit\\Framework\\Constraint\\IsAnything' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsAnything.php', - 'PHPUnit\\Framework\\Constraint\\IsEmpty' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsEmpty.php', - 'PHPUnit\\Framework\\Constraint\\IsEqual' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsEqual.php', - 'PHPUnit\\Framework\\Constraint\\IsFalse' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsFalse.php', - 'PHPUnit\\Framework\\Constraint\\IsFinite' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsFinite.php', + 'PHPUnit\\Framework\\Constraint\\IsEmpty' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Cardinality/IsEmpty.php', + 'PHPUnit\\Framework\\Constraint\\IsEqual' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqual.php', + 'PHPUnit\\Framework\\Constraint\\IsEqualCanonicalizing' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualCanonicalizing.php', + 'PHPUnit\\Framework\\Constraint\\IsEqualIgnoringCase' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualIgnoringCase.php', + 'PHPUnit\\Framework\\Constraint\\IsEqualWithDelta' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualWithDelta.php', + 'PHPUnit\\Framework\\Constraint\\IsFalse' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Boolean/IsFalse.php', + 'PHPUnit\\Framework\\Constraint\\IsFinite' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Math/IsFinite.php', 'PHPUnit\\Framework\\Constraint\\IsIdentical' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsIdentical.php', - 'PHPUnit\\Framework\\Constraint\\IsInfinite' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsInfinite.php', - 'PHPUnit\\Framework\\Constraint\\IsInstanceOf' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsInstanceOf.php', - 'PHPUnit\\Framework\\Constraint\\IsJson' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsJson.php', - 'PHPUnit\\Framework\\Constraint\\IsNan' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsNan.php', - 'PHPUnit\\Framework\\Constraint\\IsNull' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsNull.php', - 'PHPUnit\\Framework\\Constraint\\IsReadable' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsReadable.php', - 'PHPUnit\\Framework\\Constraint\\IsTrue' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsTrue.php', - 'PHPUnit\\Framework\\Constraint\\IsType' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsType.php', - 'PHPUnit\\Framework\\Constraint\\IsWritable' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsWritable.php', + 'PHPUnit\\Framework\\Constraint\\IsInfinite' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Math/IsInfinite.php', + 'PHPUnit\\Framework\\Constraint\\IsInstanceOf' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Type/IsInstanceOf.php', + 'PHPUnit\\Framework\\Constraint\\IsJson' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/String/IsJson.php', + 'PHPUnit\\Framework\\Constraint\\IsNan' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Math/IsNan.php', + 'PHPUnit\\Framework\\Constraint\\IsNull' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Type/IsNull.php', + 'PHPUnit\\Framework\\Constraint\\IsReadable' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Filesystem/IsReadable.php', + 'PHPUnit\\Framework\\Constraint\\IsTrue' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Boolean/IsTrue.php', + 'PHPUnit\\Framework\\Constraint\\IsType' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Type/IsType.php', + 'PHPUnit\\Framework\\Constraint\\IsWritable' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Filesystem/IsWritable.php', 'PHPUnit\\Framework\\Constraint\\JsonMatches' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/JsonMatches.php', 'PHPUnit\\Framework\\Constraint\\JsonMatchesErrorMessageProvider' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/JsonMatchesErrorMessageProvider.php', - 'PHPUnit\\Framework\\Constraint\\LessThan' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/LessThan.php', - 'PHPUnit\\Framework\\Constraint\\LogicalAnd' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/LogicalAnd.php', - 'PHPUnit\\Framework\\Constraint\\LogicalNot' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/LogicalNot.php', - 'PHPUnit\\Framework\\Constraint\\LogicalOr' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/LogicalOr.php', - 'PHPUnit\\Framework\\Constraint\\LogicalXor' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/LogicalXor.php', - 'PHPUnit\\Framework\\Constraint\\ObjectHasAttribute' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/ObjectHasAttribute.php', - 'PHPUnit\\Framework\\Constraint\\RegularExpression' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/RegularExpression.php', - 'PHPUnit\\Framework\\Constraint\\SameSize' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/SameSize.php', - 'PHPUnit\\Framework\\Constraint\\StringContains' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/StringContains.php', - 'PHPUnit\\Framework\\Constraint\\StringEndsWith' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/StringEndsWith.php', - 'PHPUnit\\Framework\\Constraint\\StringMatchesFormatDescription' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/StringMatchesFormatDescription.php', - 'PHPUnit\\Framework\\Constraint\\StringStartsWith' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/StringStartsWith.php', - 'PHPUnit\\Framework\\Constraint\\TraversableContains' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/TraversableContains.php', - 'PHPUnit\\Framework\\Constraint\\TraversableContainsEqual' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/TraversableContainsEqual.php', - 'PHPUnit\\Framework\\Constraint\\TraversableContainsIdentical' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/TraversableContainsIdentical.php', - 'PHPUnit\\Framework\\Constraint\\TraversableContainsOnly' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/TraversableContainsOnly.php', + 'PHPUnit\\Framework\\Constraint\\LessThan' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Cardinality/LessThan.php', + 'PHPUnit\\Framework\\Constraint\\LogicalAnd' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalAnd.php', + 'PHPUnit\\Framework\\Constraint\\LogicalNot' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalNot.php', + 'PHPUnit\\Framework\\Constraint\\LogicalOr' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalOr.php', + 'PHPUnit\\Framework\\Constraint\\LogicalXor' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalXor.php', + 'PHPUnit\\Framework\\Constraint\\ObjectEquals' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Object/ObjectEquals.php', + 'PHPUnit\\Framework\\Constraint\\ObjectHasAttribute' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Object/ObjectHasAttribute.php', + 'PHPUnit\\Framework\\Constraint\\Operator' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Operator/Operator.php', + 'PHPUnit\\Framework\\Constraint\\RegularExpression' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/String/RegularExpression.php', + 'PHPUnit\\Framework\\Constraint\\SameSize' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Cardinality/SameSize.php', + 'PHPUnit\\Framework\\Constraint\\StringContains' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/String/StringContains.php', + 'PHPUnit\\Framework\\Constraint\\StringEndsWith' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/String/StringEndsWith.php', + 'PHPUnit\\Framework\\Constraint\\StringMatchesFormatDescription' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/String/StringMatchesFormatDescription.php', + 'PHPUnit\\Framework\\Constraint\\StringStartsWith' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/String/StringStartsWith.php', + 'PHPUnit\\Framework\\Constraint\\TraversableContains' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContains.php', + 'PHPUnit\\Framework\\Constraint\\TraversableContainsEqual' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContainsEqual.php', + 'PHPUnit\\Framework\\Constraint\\TraversableContainsIdentical' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContainsIdentical.php', + 'PHPUnit\\Framework\\Constraint\\TraversableContainsOnly' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContainsOnly.php', + 'PHPUnit\\Framework\\Constraint\\UnaryOperator' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Operator/UnaryOperator.php', 'PHPUnit\\Framework\\CoveredCodeNotExecutedException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/CoveredCodeNotExecutedException.php', 'PHPUnit\\Framework\\DataProviderTestSuite' => $vendorDir . '/phpunit/phpunit/src/Framework/DataProviderTestSuite.php', + 'PHPUnit\\Framework\\Error' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/Error.php', + 'PHPUnit\\Framework\\ErrorTestCase' => $vendorDir . '/phpunit/phpunit/src/Framework/ErrorTestCase.php', 'PHPUnit\\Framework\\Error\\Deprecated' => $vendorDir . '/phpunit/phpunit/src/Framework/Error/Deprecated.php', 'PHPUnit\\Framework\\Error\\Error' => $vendorDir . '/phpunit/phpunit/src/Framework/Error/Error.php', 'PHPUnit\\Framework\\Error\\Notice' => $vendorDir . '/phpunit/phpunit/src/Framework/Error/Notice.php', 'PHPUnit\\Framework\\Error\\Warning' => $vendorDir . '/phpunit/phpunit/src/Framework/Error/Warning.php', 'PHPUnit\\Framework\\Exception' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/Exception.php', 'PHPUnit\\Framework\\ExceptionWrapper' => $vendorDir . '/phpunit/phpunit/src/Framework/ExceptionWrapper.php', + 'PHPUnit\\Framework\\ExecutionOrderDependency' => $vendorDir . '/phpunit/phpunit/src/Framework/ExecutionOrderDependency.php', 'PHPUnit\\Framework\\ExpectationFailedException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/ExpectationFailedException.php', 'PHPUnit\\Framework\\IncompleteTest' => $vendorDir . '/phpunit/phpunit/src/Framework/IncompleteTest.php', 'PHPUnit\\Framework\\IncompleteTestCase' => $vendorDir . '/phpunit/phpunit/src/Framework/IncompleteTestCase.php', @@ -2997,20 +3147,31 @@ return array( 'PHPUnit\\Framework\\MockObject\\Builder\\Identity' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Builder/Identity.php', 'PHPUnit\\Framework\\MockObject\\Builder\\InvocationMocker' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Builder/InvocationMocker.php', 'PHPUnit\\Framework\\MockObject\\Builder\\InvocationStubber' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Builder/InvocationStubber.php', - 'PHPUnit\\Framework\\MockObject\\Builder\\Match_' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Builder/Match_.php', 'PHPUnit\\Framework\\MockObject\\Builder\\MethodNameMatch' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Builder/MethodNameMatch.php', 'PHPUnit\\Framework\\MockObject\\Builder\\ParametersMatch' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Builder/ParametersMatch.php', 'PHPUnit\\Framework\\MockObject\\Builder\\Stub' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Builder/Stub.php', + 'PHPUnit\\Framework\\MockObject\\CannotUseAddMethodsException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/CannotUseAddMethodsException.php', + 'PHPUnit\\Framework\\MockObject\\CannotUseOnlyMethodsException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/CannotUseOnlyMethodsException.php', + 'PHPUnit\\Framework\\MockObject\\ClassAlreadyExistsException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/ClassAlreadyExistsException.php', + 'PHPUnit\\Framework\\MockObject\\ClassIsFinalException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsFinalException.php', 'PHPUnit\\Framework\\MockObject\\ConfigurableMethod' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/ConfigurableMethod.php', 'PHPUnit\\Framework\\MockObject\\ConfigurableMethodsAlreadyInitializedException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/ConfigurableMethodsAlreadyInitializedException.php', + 'PHPUnit\\Framework\\MockObject\\DuplicateMethodException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/DuplicateMethodException.php', 'PHPUnit\\Framework\\MockObject\\Exception' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/Exception.php', 'PHPUnit\\Framework\\MockObject\\Generator' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator.php', 'PHPUnit\\Framework\\MockObject\\IncompatibleReturnValueException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/IncompatibleReturnValueException.php', + 'PHPUnit\\Framework\\MockObject\\InvalidMethodNameException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/InvalidMethodNameException.php', 'PHPUnit\\Framework\\MockObject\\Invocation' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Invocation.php', 'PHPUnit\\Framework\\MockObject\\InvocationHandler' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/InvocationHandler.php', + 'PHPUnit\\Framework\\MockObject\\MatchBuilderNotFoundException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/MatchBuilderNotFoundException.php', 'PHPUnit\\Framework\\MockObject\\Matcher' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Matcher.php', + 'PHPUnit\\Framework\\MockObject\\MatcherAlreadyRegisteredException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/MatcherAlreadyRegisteredException.php', 'PHPUnit\\Framework\\MockObject\\Method' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Api/Method.php', + 'PHPUnit\\Framework\\MockObject\\MethodCannotBeConfiguredException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/MethodCannotBeConfiguredException.php', + 'PHPUnit\\Framework\\MockObject\\MethodNameAlreadyConfiguredException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/MethodNameAlreadyConfiguredException.php', 'PHPUnit\\Framework\\MockObject\\MethodNameConstraint' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/MethodNameConstraint.php', + 'PHPUnit\\Framework\\MockObject\\MethodNameNotConfiguredException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/MethodNameNotConfiguredException.php', + 'PHPUnit\\Framework\\MockObject\\MethodParametersAlreadyConfiguredException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/MethodParametersAlreadyConfiguredException.php', 'PHPUnit\\Framework\\MockObject\\MockBuilder' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/MockBuilder.php', 'PHPUnit\\Framework\\MockObject\\MockClass' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/MockClass.php', 'PHPUnit\\Framework\\MockObject\\MockMethod' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/MockMethod.php', @@ -3019,6 +3180,9 @@ return array( 'PHPUnit\\Framework\\MockObject\\MockTrait' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/MockTrait.php', 'PHPUnit\\Framework\\MockObject\\MockType' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/MockType.php', 'PHPUnit\\Framework\\MockObject\\MockedCloneMethod' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Api/MockedCloneMethod.php', + 'PHPUnit\\Framework\\MockObject\\OriginalConstructorInvocationRequiredException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/OriginalConstructorInvocationRequiredException.php', + 'PHPUnit\\Framework\\MockObject\\ReflectionException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/ReflectionException.php', + 'PHPUnit\\Framework\\MockObject\\ReturnValueNotConfiguredException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/ReturnValueNotConfiguredException.php', 'PHPUnit\\Framework\\MockObject\\Rule\\AnyInvokedCount' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Rule/AnyInvokedCount.php', 'PHPUnit\\Framework\\MockObject\\Rule\\AnyParameters' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Rule/AnyParameters.php', 'PHPUnit\\Framework\\MockObject\\Rule\\ConsecutiveParameters' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Rule/ConsecutiveParameters.php', @@ -3032,6 +3196,7 @@ return array( 'PHPUnit\\Framework\\MockObject\\Rule\\Parameters' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Rule/Parameters.php', 'PHPUnit\\Framework\\MockObject\\Rule\\ParametersRule' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Rule/ParametersRule.php', 'PHPUnit\\Framework\\MockObject\\RuntimeException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/RuntimeException.php', + 'PHPUnit\\Framework\\MockObject\\SoapExtensionNotAvailableException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/SoapExtensionNotAvailableException.php', 'PHPUnit\\Framework\\MockObject\\Stub' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Stub.php', 'PHPUnit\\Framework\\MockObject\\Stub\\ConsecutiveCalls' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Stub/ConsecutiveCalls.php', 'PHPUnit\\Framework\\MockObject\\Stub\\Exception' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Stub/Exception.php', @@ -3042,11 +3207,15 @@ return array( 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnStub' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnStub.php', 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnValueMap' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnValueMap.php', 'PHPUnit\\Framework\\MockObject\\Stub\\Stub' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Stub/Stub.php', + 'PHPUnit\\Framework\\MockObject\\UnknownClassException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownClassException.php', + 'PHPUnit\\Framework\\MockObject\\UnknownTraitException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownTraitException.php', + 'PHPUnit\\Framework\\MockObject\\UnknownTypeException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownTypeException.php', 'PHPUnit\\Framework\\MockObject\\UnmockedCloneMethod' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Api/UnmockedCloneMethod.php', 'PHPUnit\\Framework\\MockObject\\Verifiable' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Verifiable.php', 'PHPUnit\\Framework\\NoChildTestSuiteException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/NoChildTestSuiteException.php', 'PHPUnit\\Framework\\OutputError' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/OutputError.php', 'PHPUnit\\Framework\\PHPTAssertionFailedError' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/PHPTAssertionFailedError.php', + 'PHPUnit\\Framework\\Reorderable' => $vendorDir . '/phpunit/phpunit/src/Framework/Reorderable.php', 'PHPUnit\\Framework\\RiskyTestError' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/RiskyTestError.php', 'PHPUnit\\Framework\\SelfDescribing' => $vendorDir . '/phpunit/phpunit/src/Framework/SelfDescribing.php', 'PHPUnit\\Framework\\SkippedTest' => $vendorDir . '/phpunit/phpunit/src/Framework/SkippedTest.php', @@ -3081,6 +3250,8 @@ return array( 'PHPUnit\\Runner\\BeforeTestHook' => $vendorDir . '/phpunit/phpunit/src/Runner/Hook/BeforeTestHook.php', 'PHPUnit\\Runner\\DefaultTestResultCache' => $vendorDir . '/phpunit/phpunit/src/Runner/DefaultTestResultCache.php', 'PHPUnit\\Runner\\Exception' => $vendorDir . '/phpunit/phpunit/src/Runner/Exception.php', + 'PHPUnit\\Runner\\Extension\\ExtensionHandler' => $vendorDir . '/phpunit/phpunit/src/Runner/Extension/ExtensionHandler.php', + 'PHPUnit\\Runner\\Extension\\PharLoader' => $vendorDir . '/phpunit/phpunit/src/Runner/Extension/PharLoader.php', 'PHPUnit\\Runner\\Filter\\ExcludeGroupFilterIterator' => $vendorDir . '/phpunit/phpunit/src/Runner/Filter/ExcludeGroupFilterIterator.php', 'PHPUnit\\Runner\\Filter\\Factory' => $vendorDir . '/phpunit/phpunit/src/Runner/Filter/Factory.php', 'PHPUnit\\Runner\\Filter\\GroupFilterIterator' => $vendorDir . '/phpunit/phpunit/src/Runner/Filter/GroupFilterIterator.php', @@ -3097,23 +3268,110 @@ return array( 'PHPUnit\\Runner\\TestSuiteLoader' => $vendorDir . '/phpunit/phpunit/src/Runner/TestSuiteLoader.php', 'PHPUnit\\Runner\\TestSuiteSorter' => $vendorDir . '/phpunit/phpunit/src/Runner/TestSuiteSorter.php', 'PHPUnit\\Runner\\Version' => $vendorDir . '/phpunit/phpunit/src/Runner/Version.php', + 'PHPUnit\\TextUI\\CliArguments\\Builder' => $vendorDir . '/phpunit/phpunit/src/TextUI/CliArguments/Builder.php', + 'PHPUnit\\TextUI\\CliArguments\\Configuration' => $vendorDir . '/phpunit/phpunit/src/TextUI/CliArguments/Configuration.php', + 'PHPUnit\\TextUI\\CliArguments\\Exception' => $vendorDir . '/phpunit/phpunit/src/TextUI/CliArguments/Exception.php', + 'PHPUnit\\TextUI\\CliArguments\\Mapper' => $vendorDir . '/phpunit/phpunit/src/TextUI/CliArguments/Mapper.php', 'PHPUnit\\TextUI\\Command' => $vendorDir . '/phpunit/phpunit/src/TextUI/Command.php', - 'PHPUnit\\TextUI\\Exception' => $vendorDir . '/phpunit/phpunit/src/TextUI/Exception.php', + 'PHPUnit\\TextUI\\DefaultResultPrinter' => $vendorDir . '/phpunit/phpunit/src/TextUI/DefaultResultPrinter.php', + 'PHPUnit\\TextUI\\Exception' => $vendorDir . '/phpunit/phpunit/src/TextUI/Exception/Exception.php', 'PHPUnit\\TextUI\\Help' => $vendorDir . '/phpunit/phpunit/src/TextUI/Help.php', + 'PHPUnit\\TextUI\\ReflectionException' => $vendorDir . '/phpunit/phpunit/src/TextUI/Exception/ReflectionException.php', 'PHPUnit\\TextUI\\ResultPrinter' => $vendorDir . '/phpunit/phpunit/src/TextUI/ResultPrinter.php', + 'PHPUnit\\TextUI\\RuntimeException' => $vendorDir . '/phpunit/phpunit/src/TextUI/Exception/RuntimeException.php', + 'PHPUnit\\TextUI\\TestDirectoryNotFoundException' => $vendorDir . '/phpunit/phpunit/src/TextUI/Exception/TestDirectoryNotFoundException.php', + 'PHPUnit\\TextUI\\TestFileNotFoundException' => $vendorDir . '/phpunit/phpunit/src/TextUI/Exception/TestFileNotFoundException.php', 'PHPUnit\\TextUI\\TestRunner' => $vendorDir . '/phpunit/phpunit/src/TextUI/TestRunner.php', + 'PHPUnit\\TextUI\\TestSuiteMapper' => $vendorDir . '/phpunit/phpunit/src/TextUI/TestSuiteMapper.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\CodeCoverage' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/CodeCoverage.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\FilterMapper' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/FilterMapper.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Filter\\Directory' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Filter/Directory.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Filter\\DirectoryCollection' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Filter/DirectoryCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Filter\\DirectoryCollectionIterator' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Filter/DirectoryCollectionIterator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Report\\Clover' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Clover.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Report\\Cobertura' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Cobertura.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Report\\Crap4j' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Crap4j.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Report\\Html' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Html.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Report\\Php' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Php.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Report\\Text' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Text.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Report\\Xml' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Xml.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Configuration' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Configuration.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Constant' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/Constant.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\ConstantCollection' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/ConstantCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\ConstantCollectionIterator' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/ConstantCollectionIterator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\ConvertLogTypes' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/ConvertLogTypes.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CoverageCloverToReport' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageCloverToReport.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CoverageCrap4jToReport' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageCrap4jToReport.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CoverageHtmlToReport' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageHtmlToReport.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CoveragePhpToReport' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoveragePhpToReport.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CoverageTextToReport' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageTextToReport.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CoverageXmlToReport' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageXmlToReport.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Directory' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/Directory.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\DirectoryCollection' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/DirectoryCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\DirectoryCollectionIterator' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/DirectoryCollectionIterator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Exception' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Exception.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Extension' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/Extension.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\ExtensionCollection' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/ExtensionCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\ExtensionCollectionIterator' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/ExtensionCollectionIterator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\File' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/File.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\FileCollection' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/FileCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\FileCollectionIterator' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/FileCollectionIterator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Generator' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Generator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Group' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/Group.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\GroupCollection' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/GroupCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\GroupCollectionIterator' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/GroupCollectionIterator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Groups' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/Groups.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\IniSetting' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/IniSetting.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\IniSettingCollection' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/IniSettingCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\IniSettingCollectionIterator' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/IniSettingCollectionIterator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\IntroduceCoverageElement' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/IntroduceCoverageElement.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Loader' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Loader.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\LogToReportMigration' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/LogToReportMigration.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Logging\\Junit' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/Junit.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Logging\\Logging' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/Logging.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Logging\\TeamCity' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TeamCity.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Logging\\TestDox\\Html' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TestDox/Html.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Logging\\TestDox\\Text' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TestDox/Text.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Logging\\TestDox\\Xml' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TestDox/Xml.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Logging\\Text' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/Text.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Migration' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/Migration.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\MigrationBuilder' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/MigrationBuilder.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\MigrationBuilderException' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/MigrationBuilderException.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\MigrationException' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/MigrationException.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Migrator' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\MoveAttributesFromFilterWhitelistToCoverage' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveAttributesFromFilterWhitelistToCoverage.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\MoveAttributesFromRootToCoverage' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveAttributesFromRootToCoverage.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\MoveWhitelistDirectoriesToCoverage' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveWhitelistDirectoriesToCoverage.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\MoveWhitelistExcludesToCoverage' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveWhitelistExcludesToCoverage.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\PHPUnit' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/PHPUnit.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Php' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/Php.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\PhpHandler' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/PhpHandler.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\RemoveCacheTokensAttribute' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/RemoveCacheTokensAttribute.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\RemoveEmptyFilter' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/RemoveEmptyFilter.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\RemoveLogTypes' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/RemoveLogTypes.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\TestDirectory' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestDirectory.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\TestDirectoryCollection' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestDirectoryCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\TestDirectoryCollectionIterator' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestDirectoryCollectionIterator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\TestFile' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestFile.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\TestFileCollection' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestFileCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\TestFileCollectionIterator' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestFileCollectionIterator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\TestSuite' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestSuite.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\TestSuiteCollection' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestSuiteCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\TestSuiteCollectionIterator' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestSuiteCollectionIterator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\UpdateSchemaLocationTo93' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/UpdateSchemaLocationTo93.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Variable' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/Variable.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\VariableCollection' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/VariableCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\VariableCollectionIterator' => $vendorDir . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/VariableCollectionIterator.php', 'PHPUnit\\Util\\Annotation\\DocBlock' => $vendorDir . '/phpunit/phpunit/src/Util/Annotation/DocBlock.php', 'PHPUnit\\Util\\Annotation\\Registry' => $vendorDir . '/phpunit/phpunit/src/Util/Annotation/Registry.php', 'PHPUnit\\Util\\Blacklist' => $vendorDir . '/phpunit/phpunit/src/Util/Blacklist.php', 'PHPUnit\\Util\\Color' => $vendorDir . '/phpunit/phpunit/src/Util/Color.php', - 'PHPUnit\\Util\\Configuration' => $vendorDir . '/phpunit/phpunit/src/Util/Configuration.php', - 'PHPUnit\\Util\\ConfigurationGenerator' => $vendorDir . '/phpunit/phpunit/src/Util/ConfigurationGenerator.php', 'PHPUnit\\Util\\ErrorHandler' => $vendorDir . '/phpunit/phpunit/src/Util/ErrorHandler.php', 'PHPUnit\\Util\\Exception' => $vendorDir . '/phpunit/phpunit/src/Util/Exception.php', + 'PHPUnit\\Util\\ExcludeList' => $vendorDir . '/phpunit/phpunit/src/Util/ExcludeList.php', 'PHPUnit\\Util\\FileLoader' => $vendorDir . '/phpunit/phpunit/src/Util/FileLoader.php', 'PHPUnit\\Util\\Filesystem' => $vendorDir . '/phpunit/phpunit/src/Util/Filesystem.php', 'PHPUnit\\Util\\Filter' => $vendorDir . '/phpunit/phpunit/src/Util/Filter.php', - 'PHPUnit\\Util\\Getopt' => $vendorDir . '/phpunit/phpunit/src/Util/Getopt.php', 'PHPUnit\\Util\\GlobalState' => $vendorDir . '/phpunit/phpunit/src/Util/GlobalState.php', 'PHPUnit\\Util\\InvalidDataSetException' => $vendorDir . '/phpunit/phpunit/src/Util/InvalidDataSetException.php', 'PHPUnit\\Util\\Json' => $vendorDir . '/phpunit/phpunit/src/Util/Json.php', @@ -3138,184 +3396,16 @@ return array( 'PHPUnit\\Util\\XdebugFilterScriptGenerator' => $vendorDir . '/phpunit/phpunit/src/Util/XdebugFilterScriptGenerator.php', 'PHPUnit\\Util\\Xml' => $vendorDir . '/phpunit/phpunit/src/Util/Xml.php', 'PHPUnit\\Util\\XmlTestListRenderer' => $vendorDir . '/phpunit/phpunit/src/Util/XmlTestListRenderer.php', - 'PHP_Token' => $vendorDir . '/phpunit/php-token-stream/src/Token.php', - 'PHP_TokenWithScope' => $vendorDir . '/phpunit/php-token-stream/src/TokenWithScope.php', - 'PHP_TokenWithScopeAndVisibility' => $vendorDir . '/phpunit/php-token-stream/src/TokenWithScopeAndVisibility.php', - 'PHP_Token_ABSTRACT' => $vendorDir . '/phpunit/php-token-stream/src/Abstract.php', - 'PHP_Token_AMPERSAND' => $vendorDir . '/phpunit/php-token-stream/src/Ampersand.php', - 'PHP_Token_AND_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/AndEqual.php', - 'PHP_Token_ARRAY' => $vendorDir . '/phpunit/php-token-stream/src/Array.php', - 'PHP_Token_ARRAY_CAST' => $vendorDir . '/phpunit/php-token-stream/src/ArrayCast.php', - 'PHP_Token_AS' => $vendorDir . '/phpunit/php-token-stream/src/As.php', - 'PHP_Token_AT' => $vendorDir . '/phpunit/php-token-stream/src/At.php', - 'PHP_Token_BACKTICK' => $vendorDir . '/phpunit/php-token-stream/src/Backtick.php', - 'PHP_Token_BAD_CHARACTER' => $vendorDir . '/phpunit/php-token-stream/src/BadCharacter.php', - 'PHP_Token_BOOLEAN_AND' => $vendorDir . '/phpunit/php-token-stream/src/BooleanAnd.php', - 'PHP_Token_BOOLEAN_OR' => $vendorDir . '/phpunit/php-token-stream/src/BooleanOr.php', - 'PHP_Token_BOOL_CAST' => $vendorDir . '/phpunit/php-token-stream/src/BoolCast.php', - 'PHP_Token_BREAK' => $vendorDir . '/phpunit/php-token-stream/src/break.php', - 'PHP_Token_CALLABLE' => $vendorDir . '/phpunit/php-token-stream/src/Callable.php', - 'PHP_Token_CARET' => $vendorDir . '/phpunit/php-token-stream/src/Caret.php', - 'PHP_Token_CASE' => $vendorDir . '/phpunit/php-token-stream/src/Case.php', - 'PHP_Token_CATCH' => $vendorDir . '/phpunit/php-token-stream/src/Catch.php', - 'PHP_Token_CHARACTER' => $vendorDir . '/phpunit/php-token-stream/src/Character.php', - 'PHP_Token_CLASS' => $vendorDir . '/phpunit/php-token-stream/src/Class.php', - 'PHP_Token_CLASS_C' => $vendorDir . '/phpunit/php-token-stream/src/ClassC.php', - 'PHP_Token_CLASS_NAME_CONSTANT' => $vendorDir . '/phpunit/php-token-stream/src/ClassNameConstant.php', - 'PHP_Token_CLONE' => $vendorDir . '/phpunit/php-token-stream/src/Clone.php', - 'PHP_Token_CLOSE_BRACKET' => $vendorDir . '/phpunit/php-token-stream/src/CloseBracket.php', - 'PHP_Token_CLOSE_CURLY' => $vendorDir . '/phpunit/php-token-stream/src/CloseCurly.php', - 'PHP_Token_CLOSE_SQUARE' => $vendorDir . '/phpunit/php-token-stream/src/CloseSquare.php', - 'PHP_Token_CLOSE_TAG' => $vendorDir . '/phpunit/php-token-stream/src/CloseTag.php', - 'PHP_Token_COALESCE' => $vendorDir . '/phpunit/php-token-stream/src/Coalesce.php', - 'PHP_Token_COALESCE_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/CoalesceEqual.php', - 'PHP_Token_COLON' => $vendorDir . '/phpunit/php-token-stream/src/Colon.php', - 'PHP_Token_COMMA' => $vendorDir . '/phpunit/php-token-stream/src/Comma.php', - 'PHP_Token_COMMENT' => $vendorDir . '/phpunit/php-token-stream/src/Comment.php', - 'PHP_Token_CONCAT_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/ConcatEqual.php', - 'PHP_Token_CONST' => $vendorDir . '/phpunit/php-token-stream/src/Const.php', - 'PHP_Token_CONSTANT_ENCAPSED_STRING' => $vendorDir . '/phpunit/php-token-stream/src/ConstantEncapsedString.php', - 'PHP_Token_CONTINUE' => $vendorDir . '/phpunit/php-token-stream/src/Continue.php', - 'PHP_Token_CURLY_OPEN' => $vendorDir . '/phpunit/php-token-stream/src/CurlyOpen.php', - 'PHP_Token_DEC' => $vendorDir . '/phpunit/php-token-stream/src/Dec.php', - 'PHP_Token_DECLARE' => $vendorDir . '/phpunit/php-token-stream/src/Declare.php', - 'PHP_Token_DEFAULT' => $vendorDir . '/phpunit/php-token-stream/src/Default.php', - 'PHP_Token_DIR' => $vendorDir . '/phpunit/php-token-stream/src/Dir.php', - 'PHP_Token_DIV' => $vendorDir . '/phpunit/php-token-stream/src/Div.php', - 'PHP_Token_DIV_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/DivEqual.php', - 'PHP_Token_DNUMBER' => $vendorDir . '/phpunit/php-token-stream/src/DNumber.php', - 'PHP_Token_DO' => $vendorDir . '/phpunit/php-token-stream/src/Do.php', - 'PHP_Token_DOC_COMMENT' => $vendorDir . '/phpunit/php-token-stream/src/DocComment.php', - 'PHP_Token_DOLLAR' => $vendorDir . '/phpunit/php-token-stream/src/Dollar.php', - 'PHP_Token_DOLLAR_OPEN_CURLY_BRACES' => $vendorDir . '/phpunit/php-token-stream/src/DollarOpenCurlyBraces.php', - 'PHP_Token_DOT' => $vendorDir . '/phpunit/php-token-stream/src/Dot.php', - 'PHP_Token_DOUBLE_ARROW' => $vendorDir . '/phpunit/php-token-stream/src/DoubleArrow.php', - 'PHP_Token_DOUBLE_CAST' => $vendorDir . '/phpunit/php-token-stream/src/DoubleCast.php', - 'PHP_Token_DOUBLE_COLON' => $vendorDir . '/phpunit/php-token-stream/src/DoubleColon.php', - 'PHP_Token_DOUBLE_QUOTES' => $vendorDir . '/phpunit/php-token-stream/src/DoubleQuotes.php', - 'PHP_Token_ECHO' => $vendorDir . '/phpunit/php-token-stream/src/Echo.php', - 'PHP_Token_ELLIPSIS' => $vendorDir . '/phpunit/php-token-stream/src/Ellipsis.php', - 'PHP_Token_ELSE' => $vendorDir . '/phpunit/php-token-stream/src/Else.php', - 'PHP_Token_ELSEIF' => $vendorDir . '/phpunit/php-token-stream/src/Elseif.php', - 'PHP_Token_EMPTY' => $vendorDir . '/phpunit/php-token-stream/src/Empty.php', - 'PHP_Token_ENCAPSED_AND_WHITESPACE' => $vendorDir . '/phpunit/php-token-stream/src/EncapsedAndWhitespace.php', - 'PHP_Token_ENDDECLARE' => $vendorDir . '/phpunit/php-token-stream/src/Enddeclare.php', - 'PHP_Token_ENDFOR' => $vendorDir . '/phpunit/php-token-stream/src/Endfor.php', - 'PHP_Token_ENDFOREACH' => $vendorDir . '/phpunit/php-token-stream/src/Endforeach.php', - 'PHP_Token_ENDIF' => $vendorDir . '/phpunit/php-token-stream/src/Endif.php', - 'PHP_Token_ENDSWITCH' => $vendorDir . '/phpunit/php-token-stream/src/Endswitch.php', - 'PHP_Token_ENDWHILE' => $vendorDir . '/phpunit/php-token-stream/src/Endwhile.php', - 'PHP_Token_END_HEREDOC' => $vendorDir . '/phpunit/php-token-stream/src/EndHeredoc.php', - 'PHP_Token_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/Equal.php', - 'PHP_Token_EVAL' => $vendorDir . '/phpunit/php-token-stream/src/Eval.php', - 'PHP_Token_EXCLAMATION_MARK' => $vendorDir . '/phpunit/php-token-stream/src/ExclamationMark.php', - 'PHP_Token_EXIT' => $vendorDir . '/phpunit/php-token-stream/src/Exit.php', - 'PHP_Token_EXTENDS' => $vendorDir . '/phpunit/php-token-stream/src/Extends.php', - 'PHP_Token_FILE' => $vendorDir . '/phpunit/php-token-stream/src/File.php', - 'PHP_Token_FINAL' => $vendorDir . '/phpunit/php-token-stream/src/Final.php', - 'PHP_Token_FINALLY' => $vendorDir . '/phpunit/php-token-stream/src/Finally.php', - 'PHP_Token_FN' => $vendorDir . '/phpunit/php-token-stream/src/Fn.php', - 'PHP_Token_FOR' => $vendorDir . '/phpunit/php-token-stream/src/For.php', - 'PHP_Token_FOREACH' => $vendorDir . '/phpunit/php-token-stream/src/Foreach.php', - 'PHP_Token_FUNCTION' => $vendorDir . '/phpunit/php-token-stream/src/Function.php', - 'PHP_Token_FUNC_C' => $vendorDir . '/phpunit/php-token-stream/src/FuncC.php', - 'PHP_Token_GLOBAL' => $vendorDir . '/phpunit/php-token-stream/src/Global.php', - 'PHP_Token_GOTO' => $vendorDir . '/phpunit/php-token-stream/src/Goto.php', - 'PHP_Token_GT' => $vendorDir . '/phpunit/php-token-stream/src/Gt.php', - 'PHP_Token_HALT_COMPILER' => $vendorDir . '/phpunit/php-token-stream/src/HaltCompiler.php', - 'PHP_Token_IF' => $vendorDir . '/phpunit/php-token-stream/src/If.php', - 'PHP_Token_IMPLEMENTS' => $vendorDir . '/phpunit/php-token-stream/src/Implements.php', - 'PHP_Token_INC' => $vendorDir . '/phpunit/php-token-stream/src/Inc.php', - 'PHP_Token_INCLUDE' => $vendorDir . '/phpunit/php-token-stream/src/Include.php', - 'PHP_Token_INCLUDE_ONCE' => $vendorDir . '/phpunit/php-token-stream/src/IncludeOnce.php', - 'PHP_Token_INLINE_HTML' => $vendorDir . '/phpunit/php-token-stream/src/InlineHtml.php', - 'PHP_Token_INSTANCEOF' => $vendorDir . '/phpunit/php-token-stream/src/Instanceof.php', - 'PHP_Token_INSTEADOF' => $vendorDir . '/phpunit/php-token-stream/src/Insteadof.php', - 'PHP_Token_INTERFACE' => $vendorDir . '/phpunit/php-token-stream/src/Interface.php', - 'PHP_Token_INT_CAST' => $vendorDir . '/phpunit/php-token-stream/src/IntCast.php', - 'PHP_Token_ISSET' => $vendorDir . '/phpunit/php-token-stream/src/Isset.php', - 'PHP_Token_IS_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/IsEqual.php', - 'PHP_Token_IS_GREATER_OR_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/IsGreaterOrEqual.php', - 'PHP_Token_IS_IDENTICAL' => $vendorDir . '/phpunit/php-token-stream/src/IsIdentical.php', - 'PHP_Token_IS_NOT_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/IsNotEqual.php', - 'PHP_Token_IS_NOT_IDENTICAL' => $vendorDir . '/phpunit/php-token-stream/src/IsNotIdentical.php', - 'PHP_Token_IS_SMALLER_OR_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/IsSmallerOrEqual.php', - 'PHP_Token_Includes' => $vendorDir . '/phpunit/php-token-stream/src/Includes.php', - 'PHP_Token_LINE' => $vendorDir . '/phpunit/php-token-stream/src/Line.php', - 'PHP_Token_LIST' => $vendorDir . '/phpunit/php-token-stream/src/List.php', - 'PHP_Token_LNUMBER' => $vendorDir . '/phpunit/php-token-stream/src/Lnumber.php', - 'PHP_Token_LOGICAL_AND' => $vendorDir . '/phpunit/php-token-stream/src/LogicalAnd.php', - 'PHP_Token_LOGICAL_OR' => $vendorDir . '/phpunit/php-token-stream/src/LogicalOr.php', - 'PHP_Token_LOGICAL_XOR' => $vendorDir . '/phpunit/php-token-stream/src/LogicalXor.php', - 'PHP_Token_LT' => $vendorDir . '/phpunit/php-token-stream/src/Lt.php', - 'PHP_Token_METHOD_C' => $vendorDir . '/phpunit/php-token-stream/src/MethodC.php', - 'PHP_Token_MINUS' => $vendorDir . '/phpunit/php-token-stream/src/Minus.php', - 'PHP_Token_MINUS_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/MinusEqual.php', - 'PHP_Token_MOD_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/ModEqual.php', - 'PHP_Token_MULT' => $vendorDir . '/phpunit/php-token-stream/src/Mult.php', - 'PHP_Token_MUL_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/MulEqual.php', - 'PHP_Token_NAMESPACE' => $vendorDir . '/phpunit/php-token-stream/src/Namespace.php', - 'PHP_Token_NAME_FULLY_QUALIFIED' => $vendorDir . '/phpunit/php-token-stream/src/NameFullyQualified.php', - 'PHP_Token_NAME_QUALIFIED' => $vendorDir . '/phpunit/php-token-stream/src/NameQualified.php', - 'PHP_Token_NAME_RELATIVE' => $vendorDir . '/phpunit/php-token-stream/src/NameRelative.php', - 'PHP_Token_NEW' => $vendorDir . '/phpunit/php-token-stream/src/New.php', - 'PHP_Token_NS_C' => $vendorDir . '/phpunit/php-token-stream/src/NsC.php', - 'PHP_Token_NS_SEPARATOR' => $vendorDir . '/phpunit/php-token-stream/src/NsSeparator.php', - 'PHP_Token_NUM_STRING' => $vendorDir . '/phpunit/php-token-stream/src/NumString.php', - 'PHP_Token_OBJECT_CAST' => $vendorDir . '/phpunit/php-token-stream/src/ObjectCast.php', - 'PHP_Token_OBJECT_OPERATOR' => $vendorDir . '/phpunit/php-token-stream/src/ObjectOperator.php', - 'PHP_Token_OPEN_BRACKET' => $vendorDir . '/phpunit/php-token-stream/src/OpenBracket.php', - 'PHP_Token_OPEN_CURLY' => $vendorDir . '/phpunit/php-token-stream/src/OpenCurly.php', - 'PHP_Token_OPEN_SQUARE' => $vendorDir . '/phpunit/php-token-stream/src/OpenSquare.php', - 'PHP_Token_OPEN_TAG' => $vendorDir . '/phpunit/php-token-stream/src/OpenTag.php', - 'PHP_Token_OPEN_TAG_WITH_ECHO' => $vendorDir . '/phpunit/php-token-stream/src/OpenTagWithEcho.php', - 'PHP_Token_OR_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/OrEqual.php', - 'PHP_Token_PAAMAYIM_NEKUDOTAYIM' => $vendorDir . '/phpunit/php-token-stream/src/PaamayimNekudotayim.php', - 'PHP_Token_PERCENT' => $vendorDir . '/phpunit/php-token-stream/src/Percent.php', - 'PHP_Token_PIPE' => $vendorDir . '/phpunit/php-token-stream/src/Pipe.php', - 'PHP_Token_PLUS' => $vendorDir . '/phpunit/php-token-stream/src/Plus.php', - 'PHP_Token_PLUS_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/PlusEqual.php', - 'PHP_Token_POW' => $vendorDir . '/phpunit/php-token-stream/src/Pow.php', - 'PHP_Token_POW_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/PowEqual.php', - 'PHP_Token_PRINT' => $vendorDir . '/phpunit/php-token-stream/src/Print.php', - 'PHP_Token_PRIVATE' => $vendorDir . '/phpunit/php-token-stream/src/Private.php', - 'PHP_Token_PROTECTED' => $vendorDir . '/phpunit/php-token-stream/src/Protected.php', - 'PHP_Token_PUBLIC' => $vendorDir . '/phpunit/php-token-stream/src/Public.php', - 'PHP_Token_QUESTION_MARK' => $vendorDir . '/phpunit/php-token-stream/src/QuestionMark.php', - 'PHP_Token_REQUIRE' => $vendorDir . '/phpunit/php-token-stream/src/Require.php', - 'PHP_Token_REQUIRE_ONCE' => $vendorDir . '/phpunit/php-token-stream/src/RequireOnce.php', - 'PHP_Token_RETURN' => $vendorDir . '/phpunit/php-token-stream/src/Return.php', - 'PHP_Token_SEMICOLON' => $vendorDir . '/phpunit/php-token-stream/src/Semicolon.php', - 'PHP_Token_SL' => $vendorDir . '/phpunit/php-token-stream/src/Sl.php', - 'PHP_Token_SL_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/SlEqual.php', - 'PHP_Token_SPACESHIP' => $vendorDir . '/phpunit/php-token-stream/src/Spaceship.php', - 'PHP_Token_SR' => $vendorDir . '/phpunit/php-token-stream/src/Sr.php', - 'PHP_Token_SR_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/SrEqual.php', - 'PHP_Token_START_HEREDOC' => $vendorDir . '/phpunit/php-token-stream/src/StartHeredoc.php', - 'PHP_Token_STATIC' => $vendorDir . '/phpunit/php-token-stream/src/Static.php', - 'PHP_Token_STRING' => $vendorDir . '/phpunit/php-token-stream/src/String.php', - 'PHP_Token_STRING_CAST' => $vendorDir . '/phpunit/php-token-stream/src/StringCast.php', - 'PHP_Token_STRING_VARNAME' => $vendorDir . '/phpunit/php-token-stream/src/StringVarname.php', - 'PHP_Token_SWITCH' => $vendorDir . '/phpunit/php-token-stream/src/Switch.php', - 'PHP_Token_Stream' => $vendorDir . '/phpunit/php-token-stream/src/Stream.php', - 'PHP_Token_Stream_CachingFactory' => $vendorDir . '/phpunit/php-token-stream/src/CachingFactory.php', - 'PHP_Token_THROW' => $vendorDir . '/phpunit/php-token-stream/src/Throw.php', - 'PHP_Token_TILDE' => $vendorDir . '/phpunit/php-token-stream/src/Tilde.php', - 'PHP_Token_TRAIT' => $vendorDir . '/phpunit/php-token-stream/src/Trait.php', - 'PHP_Token_TRAIT_C' => $vendorDir . '/phpunit/php-token-stream/src/TraitC.php', - 'PHP_Token_TRY' => $vendorDir . '/phpunit/php-token-stream/src/Try.php', - 'PHP_Token_UNSET' => $vendorDir . '/phpunit/php-token-stream/src/Unset.php', - 'PHP_Token_UNSET_CAST' => $vendorDir . '/phpunit/php-token-stream/src/UnsetCast.php', - 'PHP_Token_USE' => $vendorDir . '/phpunit/php-token-stream/src/Use.php', - 'PHP_Token_USE_FUNCTION' => $vendorDir . '/phpunit/php-token-stream/src/UseFunction.php', - 'PHP_Token_Util' => $vendorDir . '/phpunit/php-token-stream/src/Util.php', - 'PHP_Token_VAR' => $vendorDir . '/phpunit/php-token-stream/src/Var.php', - 'PHP_Token_VARIABLE' => $vendorDir . '/phpunit/php-token-stream/src/Variable.php', - 'PHP_Token_WHILE' => $vendorDir . '/phpunit/php-token-stream/src/While.php', - 'PHP_Token_WHITESPACE' => $vendorDir . '/phpunit/php-token-stream/src/Whitespace.php', - 'PHP_Token_XOR_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/XorEqual.php', - 'PHP_Token_YIELD' => $vendorDir . '/phpunit/php-token-stream/src/Yield.php', - 'PHP_Token_YIELD_FROM' => $vendorDir . '/phpunit/php-token-stream/src/YieldFrom.php', + 'PHPUnit\\Util\\Xml\\Exception' => $vendorDir . '/phpunit/phpunit/src/Util/Xml/Exception.php', + 'PHPUnit\\Util\\Xml\\FailedSchemaDetectionResult' => $vendorDir . '/phpunit/phpunit/src/Util/Xml/FailedSchemaDetectionResult.php', + 'PHPUnit\\Util\\Xml\\Loader' => $vendorDir . '/phpunit/phpunit/src/Util/Xml/Loader.php', + 'PHPUnit\\Util\\Xml\\SchemaDetectionResult' => $vendorDir . '/phpunit/phpunit/src/Util/Xml/SchemaDetectionResult.php', + 'PHPUnit\\Util\\Xml\\SchemaDetector' => $vendorDir . '/phpunit/phpunit/src/Util/Xml/SchemaDetector.php', + 'PHPUnit\\Util\\Xml\\SchemaFinder' => $vendorDir . '/phpunit/phpunit/src/Util/Xml/SchemaFinder.php', + 'PHPUnit\\Util\\Xml\\SnapshotNodeList' => $vendorDir . '/phpunit/phpunit/src/Util/Xml/SnapshotNodeList.php', + 'PHPUnit\\Util\\Xml\\SuccessfulSchemaDetectionResult' => $vendorDir . '/phpunit/phpunit/src/Util/Xml/SuccessfulSchemaDetectionResult.php', + 'PHPUnit\\Util\\Xml\\ValidationResult' => $vendorDir . '/phpunit/phpunit/src/Util/Xml/ValidationResult.php', + 'PHPUnit\\Util\\Xml\\Validator' => $vendorDir . '/phpunit/phpunit/src/Util/Xml/Validator.php', 'PharIo\\Manifest\\Application' => $vendorDir . '/phar-io/manifest/src/values/Application.php', 'PharIo\\Manifest\\ApplicationName' => $vendorDir . '/phar-io/manifest/src/values/ApplicationName.php', 'PharIo\\Manifest\\Author' => $vendorDir . '/phar-io/manifest/src/values/Author.php', @@ -3389,6 +3479,247 @@ return array( 'PhpOption\\None' => $vendorDir . '/phpoption/phpoption/src/PhpOption/None.php', 'PhpOption\\Option' => $vendorDir . '/phpoption/phpoption/src/PhpOption/Option.php', 'PhpOption\\Some' => $vendorDir . '/phpoption/phpoption/src/PhpOption/Some.php', + 'PhpParser\\Builder' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Builder.php', + 'PhpParser\\BuilderFactory' => $vendorDir . '/nikic/php-parser/lib/PhpParser/BuilderFactory.php', + 'PhpParser\\BuilderHelpers' => $vendorDir . '/nikic/php-parser/lib/PhpParser/BuilderHelpers.php', + 'PhpParser\\Builder\\ClassConst' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Builder/ClassConst.php', + 'PhpParser\\Builder\\Class_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Builder/Class_.php', + 'PhpParser\\Builder\\Declaration' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Builder/Declaration.php', + 'PhpParser\\Builder\\FunctionLike' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Builder/FunctionLike.php', + 'PhpParser\\Builder\\Function_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Builder/Function_.php', + 'PhpParser\\Builder\\Interface_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Builder/Interface_.php', + 'PhpParser\\Builder\\Method' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Builder/Method.php', + 'PhpParser\\Builder\\Namespace_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Builder/Namespace_.php', + 'PhpParser\\Builder\\Param' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Builder/Param.php', + 'PhpParser\\Builder\\Property' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Builder/Property.php', + 'PhpParser\\Builder\\TraitUse' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Builder/TraitUse.php', + 'PhpParser\\Builder\\TraitUseAdaptation' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Builder/TraitUseAdaptation.php', + 'PhpParser\\Builder\\Trait_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Builder/Trait_.php', + 'PhpParser\\Builder\\Use_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Builder/Use_.php', + 'PhpParser\\Comment' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Comment.php', + 'PhpParser\\Comment\\Doc' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Comment/Doc.php', + 'PhpParser\\ConstExprEvaluationException' => $vendorDir . '/nikic/php-parser/lib/PhpParser/ConstExprEvaluationException.php', + 'PhpParser\\ConstExprEvaluator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/ConstExprEvaluator.php', + 'PhpParser\\Error' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Error.php', + 'PhpParser\\ErrorHandler' => $vendorDir . '/nikic/php-parser/lib/PhpParser/ErrorHandler.php', + 'PhpParser\\ErrorHandler\\Collecting' => $vendorDir . '/nikic/php-parser/lib/PhpParser/ErrorHandler/Collecting.php', + 'PhpParser\\ErrorHandler\\Throwing' => $vendorDir . '/nikic/php-parser/lib/PhpParser/ErrorHandler/Throwing.php', + 'PhpParser\\Internal\\DiffElem' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Internal/DiffElem.php', + 'PhpParser\\Internal\\Differ' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Internal/Differ.php', + 'PhpParser\\Internal\\PrintableNewAnonClassNode' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Internal/PrintableNewAnonClassNode.php', + 'PhpParser\\Internal\\TokenStream' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Internal/TokenStream.php', + 'PhpParser\\JsonDecoder' => $vendorDir . '/nikic/php-parser/lib/PhpParser/JsonDecoder.php', + 'PhpParser\\Lexer' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer.php', + 'PhpParser\\Lexer\\Emulative' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/Emulative.php', + 'PhpParser\\Lexer\\TokenEmulator\\AttributeEmulator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/AttributeEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\CoaleseEqualTokenEmulator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/CoaleseEqualTokenEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\EnumTokenEmulator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/EnumTokenEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\FlexibleDocStringEmulator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/FlexibleDocStringEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\FnTokenEmulator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/FnTokenEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\KeywordEmulator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/KeywordEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\MatchTokenEmulator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/MatchTokenEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\NullsafeTokenEmulator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/NullsafeTokenEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\NumericLiteralSeparatorEmulator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/NumericLiteralSeparatorEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\ReverseEmulator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/ReverseEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\TokenEmulator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/TokenEmulator.php', + 'PhpParser\\NameContext' => $vendorDir . '/nikic/php-parser/lib/PhpParser/NameContext.php', + 'PhpParser\\Node' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node.php', + 'PhpParser\\NodeAbstract' => $vendorDir . '/nikic/php-parser/lib/PhpParser/NodeAbstract.php', + 'PhpParser\\NodeDumper' => $vendorDir . '/nikic/php-parser/lib/PhpParser/NodeDumper.php', + 'PhpParser\\NodeFinder' => $vendorDir . '/nikic/php-parser/lib/PhpParser/NodeFinder.php', + 'PhpParser\\NodeTraverser' => $vendorDir . '/nikic/php-parser/lib/PhpParser/NodeTraverser.php', + 'PhpParser\\NodeTraverserInterface' => $vendorDir . '/nikic/php-parser/lib/PhpParser/NodeTraverserInterface.php', + 'PhpParser\\NodeVisitor' => $vendorDir . '/nikic/php-parser/lib/PhpParser/NodeVisitor.php', + 'PhpParser\\NodeVisitorAbstract' => $vendorDir . '/nikic/php-parser/lib/PhpParser/NodeVisitorAbstract.php', + 'PhpParser\\NodeVisitor\\CloningVisitor' => $vendorDir . '/nikic/php-parser/lib/PhpParser/NodeVisitor/CloningVisitor.php', + 'PhpParser\\NodeVisitor\\FindingVisitor' => $vendorDir . '/nikic/php-parser/lib/PhpParser/NodeVisitor/FindingVisitor.php', + 'PhpParser\\NodeVisitor\\FirstFindingVisitor' => $vendorDir . '/nikic/php-parser/lib/PhpParser/NodeVisitor/FirstFindingVisitor.php', + 'PhpParser\\NodeVisitor\\NameResolver' => $vendorDir . '/nikic/php-parser/lib/PhpParser/NodeVisitor/NameResolver.php', + 'PhpParser\\NodeVisitor\\NodeConnectingVisitor' => $vendorDir . '/nikic/php-parser/lib/PhpParser/NodeVisitor/NodeConnectingVisitor.php', + 'PhpParser\\NodeVisitor\\ParentConnectingVisitor' => $vendorDir . '/nikic/php-parser/lib/PhpParser/NodeVisitor/ParentConnectingVisitor.php', + 'PhpParser\\Node\\Arg' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Arg.php', + 'PhpParser\\Node\\Attribute' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Attribute.php', + 'PhpParser\\Node\\AttributeGroup' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/AttributeGroup.php', + 'PhpParser\\Node\\Const_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Const_.php', + 'PhpParser\\Node\\Expr' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr.php', + 'PhpParser\\Node\\Expr\\ArrayDimFetch' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/ArrayDimFetch.php', + 'PhpParser\\Node\\Expr\\ArrayItem' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/ArrayItem.php', + 'PhpParser\\Node\\Expr\\Array_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Array_.php', + 'PhpParser\\Node\\Expr\\ArrowFunction' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/ArrowFunction.php', + 'PhpParser\\Node\\Expr\\Assign' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Assign.php', + 'PhpParser\\Node\\Expr\\AssignOp' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp.php', + 'PhpParser\\Node\\Expr\\AssignOp\\BitwiseAnd' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/BitwiseAnd.php', + 'PhpParser\\Node\\Expr\\AssignOp\\BitwiseOr' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/BitwiseOr.php', + 'PhpParser\\Node\\Expr\\AssignOp\\BitwiseXor' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/BitwiseXor.php', + 'PhpParser\\Node\\Expr\\AssignOp\\Coalesce' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Coalesce.php', + 'PhpParser\\Node\\Expr\\AssignOp\\Concat' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Concat.php', + 'PhpParser\\Node\\Expr\\AssignOp\\Div' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Div.php', + 'PhpParser\\Node\\Expr\\AssignOp\\Minus' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Minus.php', + 'PhpParser\\Node\\Expr\\AssignOp\\Mod' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Mod.php', + 'PhpParser\\Node\\Expr\\AssignOp\\Mul' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Mul.php', + 'PhpParser\\Node\\Expr\\AssignOp\\Plus' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Plus.php', + 'PhpParser\\Node\\Expr\\AssignOp\\Pow' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Pow.php', + 'PhpParser\\Node\\Expr\\AssignOp\\ShiftLeft' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/ShiftLeft.php', + 'PhpParser\\Node\\Expr\\AssignOp\\ShiftRight' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/ShiftRight.php', + 'PhpParser\\Node\\Expr\\AssignRef' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignRef.php', + 'PhpParser\\Node\\Expr\\BinaryOp' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\BitwiseAnd' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/BitwiseAnd.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\BitwiseOr' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/BitwiseOr.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\BitwiseXor' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/BitwiseXor.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\BooleanAnd' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/BooleanAnd.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\BooleanOr' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/BooleanOr.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Coalesce' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Coalesce.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Concat' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Concat.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Div' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Div.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Equal' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Equal.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Greater' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Greater.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\GreaterOrEqual' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/GreaterOrEqual.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Identical' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Identical.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\LogicalAnd' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/LogicalAnd.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\LogicalOr' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/LogicalOr.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\LogicalXor' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/LogicalXor.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Minus' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Minus.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Mod' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Mod.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Mul' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Mul.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\NotEqual' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/NotEqual.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\NotIdentical' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/NotIdentical.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Plus' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Plus.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Pow' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Pow.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\ShiftLeft' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/ShiftLeft.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\ShiftRight' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/ShiftRight.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Smaller' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Smaller.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\SmallerOrEqual' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/SmallerOrEqual.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Spaceship' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Spaceship.php', + 'PhpParser\\Node\\Expr\\BitwiseNot' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BitwiseNot.php', + 'PhpParser\\Node\\Expr\\BooleanNot' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/BooleanNot.php', + 'PhpParser\\Node\\Expr\\Cast' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Cast.php', + 'PhpParser\\Node\\Expr\\Cast\\Array_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Cast/Array_.php', + 'PhpParser\\Node\\Expr\\Cast\\Bool_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Cast/Bool_.php', + 'PhpParser\\Node\\Expr\\Cast\\Double' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Cast/Double.php', + 'PhpParser\\Node\\Expr\\Cast\\Int_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Cast/Int_.php', + 'PhpParser\\Node\\Expr\\Cast\\Object_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Cast/Object_.php', + 'PhpParser\\Node\\Expr\\Cast\\String_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Cast/String_.php', + 'PhpParser\\Node\\Expr\\Cast\\Unset_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Cast/Unset_.php', + 'PhpParser\\Node\\Expr\\ClassConstFetch' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/ClassConstFetch.php', + 'PhpParser\\Node\\Expr\\Clone_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Clone_.php', + 'PhpParser\\Node\\Expr\\Closure' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Closure.php', + 'PhpParser\\Node\\Expr\\ClosureUse' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/ClosureUse.php', + 'PhpParser\\Node\\Expr\\ConstFetch' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/ConstFetch.php', + 'PhpParser\\Node\\Expr\\Empty_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Empty_.php', + 'PhpParser\\Node\\Expr\\Error' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Error.php', + 'PhpParser\\Node\\Expr\\ErrorSuppress' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/ErrorSuppress.php', + 'PhpParser\\Node\\Expr\\Eval_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Eval_.php', + 'PhpParser\\Node\\Expr\\Exit_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Exit_.php', + 'PhpParser\\Node\\Expr\\FuncCall' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/FuncCall.php', + 'PhpParser\\Node\\Expr\\Include_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Include_.php', + 'PhpParser\\Node\\Expr\\Instanceof_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Instanceof_.php', + 'PhpParser\\Node\\Expr\\Isset_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Isset_.php', + 'PhpParser\\Node\\Expr\\List_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/List_.php', + 'PhpParser\\Node\\Expr\\Match_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Match_.php', + 'PhpParser\\Node\\Expr\\MethodCall' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/MethodCall.php', + 'PhpParser\\Node\\Expr\\New_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/New_.php', + 'PhpParser\\Node\\Expr\\NullsafeMethodCall' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/NullsafeMethodCall.php', + 'PhpParser\\Node\\Expr\\NullsafePropertyFetch' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/NullsafePropertyFetch.php', + 'PhpParser\\Node\\Expr\\PostDec' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/PostDec.php', + 'PhpParser\\Node\\Expr\\PostInc' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/PostInc.php', + 'PhpParser\\Node\\Expr\\PreDec' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/PreDec.php', + 'PhpParser\\Node\\Expr\\PreInc' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/PreInc.php', + 'PhpParser\\Node\\Expr\\Print_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Print_.php', + 'PhpParser\\Node\\Expr\\PropertyFetch' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/PropertyFetch.php', + 'PhpParser\\Node\\Expr\\ShellExec' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/ShellExec.php', + 'PhpParser\\Node\\Expr\\StaticCall' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/StaticCall.php', + 'PhpParser\\Node\\Expr\\StaticPropertyFetch' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/StaticPropertyFetch.php', + 'PhpParser\\Node\\Expr\\Ternary' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Ternary.php', + 'PhpParser\\Node\\Expr\\Throw_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Throw_.php', + 'PhpParser\\Node\\Expr\\UnaryMinus' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/UnaryMinus.php', + 'PhpParser\\Node\\Expr\\UnaryPlus' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/UnaryPlus.php', + 'PhpParser\\Node\\Expr\\Variable' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Variable.php', + 'PhpParser\\Node\\Expr\\YieldFrom' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/YieldFrom.php', + 'PhpParser\\Node\\Expr\\Yield_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Yield_.php', + 'PhpParser\\Node\\FunctionLike' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/FunctionLike.php', + 'PhpParser\\Node\\Identifier' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Identifier.php', + 'PhpParser\\Node\\MatchArm' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/MatchArm.php', + 'PhpParser\\Node\\Name' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Name.php', + 'PhpParser\\Node\\Name\\FullyQualified' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Name/FullyQualified.php', + 'PhpParser\\Node\\Name\\Relative' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Name/Relative.php', + 'PhpParser\\Node\\NullableType' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/NullableType.php', + 'PhpParser\\Node\\Param' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Param.php', + 'PhpParser\\Node\\Scalar' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Scalar.php', + 'PhpParser\\Node\\Scalar\\DNumber' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Scalar/DNumber.php', + 'PhpParser\\Node\\Scalar\\Encapsed' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Scalar/Encapsed.php', + 'PhpParser\\Node\\Scalar\\EncapsedStringPart' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Scalar/EncapsedStringPart.php', + 'PhpParser\\Node\\Scalar\\LNumber' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Scalar/LNumber.php', + 'PhpParser\\Node\\Scalar\\MagicConst' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst.php', + 'PhpParser\\Node\\Scalar\\MagicConst\\Class_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/Class_.php', + 'PhpParser\\Node\\Scalar\\MagicConst\\Dir' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/Dir.php', + 'PhpParser\\Node\\Scalar\\MagicConst\\File' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/File.php', + 'PhpParser\\Node\\Scalar\\MagicConst\\Function_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/Function_.php', + 'PhpParser\\Node\\Scalar\\MagicConst\\Line' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/Line.php', + 'PhpParser\\Node\\Scalar\\MagicConst\\Method' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/Method.php', + 'PhpParser\\Node\\Scalar\\MagicConst\\Namespace_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/Namespace_.php', + 'PhpParser\\Node\\Scalar\\MagicConst\\Trait_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/Trait_.php', + 'PhpParser\\Node\\Scalar\\String_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Scalar/String_.php', + 'PhpParser\\Node\\Stmt' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt.php', + 'PhpParser\\Node\\Stmt\\Break_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Break_.php', + 'PhpParser\\Node\\Stmt\\Case_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Case_.php', + 'PhpParser\\Node\\Stmt\\Catch_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Catch_.php', + 'PhpParser\\Node\\Stmt\\ClassConst' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/ClassConst.php', + 'PhpParser\\Node\\Stmt\\ClassLike' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/ClassLike.php', + 'PhpParser\\Node\\Stmt\\ClassMethod' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/ClassMethod.php', + 'PhpParser\\Node\\Stmt\\Class_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Class_.php', + 'PhpParser\\Node\\Stmt\\Const_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Const_.php', + 'PhpParser\\Node\\Stmt\\Continue_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Continue_.php', + 'PhpParser\\Node\\Stmt\\DeclareDeclare' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/DeclareDeclare.php', + 'PhpParser\\Node\\Stmt\\Declare_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Declare_.php', + 'PhpParser\\Node\\Stmt\\Do_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Do_.php', + 'PhpParser\\Node\\Stmt\\Echo_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Echo_.php', + 'PhpParser\\Node\\Stmt\\ElseIf_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/ElseIf_.php', + 'PhpParser\\Node\\Stmt\\Else_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Else_.php', + 'PhpParser\\Node\\Stmt\\EnumCase' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/EnumCase.php', + 'PhpParser\\Node\\Stmt\\Enum_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Enum_.php', + 'PhpParser\\Node\\Stmt\\Expression' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Expression.php', + 'PhpParser\\Node\\Stmt\\Finally_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Finally_.php', + 'PhpParser\\Node\\Stmt\\For_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/For_.php', + 'PhpParser\\Node\\Stmt\\Foreach_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Foreach_.php', + 'PhpParser\\Node\\Stmt\\Function_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Function_.php', + 'PhpParser\\Node\\Stmt\\Global_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Global_.php', + 'PhpParser\\Node\\Stmt\\Goto_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Goto_.php', + 'PhpParser\\Node\\Stmt\\GroupUse' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/GroupUse.php', + 'PhpParser\\Node\\Stmt\\HaltCompiler' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/HaltCompiler.php', + 'PhpParser\\Node\\Stmt\\If_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/If_.php', + 'PhpParser\\Node\\Stmt\\InlineHTML' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/InlineHTML.php', + 'PhpParser\\Node\\Stmt\\Interface_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Interface_.php', + 'PhpParser\\Node\\Stmt\\Label' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Label.php', + 'PhpParser\\Node\\Stmt\\Namespace_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Namespace_.php', + 'PhpParser\\Node\\Stmt\\Nop' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Nop.php', + 'PhpParser\\Node\\Stmt\\Property' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Property.php', + 'PhpParser\\Node\\Stmt\\PropertyProperty' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/PropertyProperty.php', + 'PhpParser\\Node\\Stmt\\Return_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Return_.php', + 'PhpParser\\Node\\Stmt\\StaticVar' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/StaticVar.php', + 'PhpParser\\Node\\Stmt\\Static_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Static_.php', + 'PhpParser\\Node\\Stmt\\Switch_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Switch_.php', + 'PhpParser\\Node\\Stmt\\Throw_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Throw_.php', + 'PhpParser\\Node\\Stmt\\TraitUse' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/TraitUse.php', + 'PhpParser\\Node\\Stmt\\TraitUseAdaptation' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/TraitUseAdaptation.php', + 'PhpParser\\Node\\Stmt\\TraitUseAdaptation\\Alias' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/TraitUseAdaptation/Alias.php', + 'PhpParser\\Node\\Stmt\\TraitUseAdaptation\\Precedence' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/TraitUseAdaptation/Precedence.php', + 'PhpParser\\Node\\Stmt\\Trait_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Trait_.php', + 'PhpParser\\Node\\Stmt\\TryCatch' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/TryCatch.php', + 'PhpParser\\Node\\Stmt\\Unset_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Unset_.php', + 'PhpParser\\Node\\Stmt\\UseUse' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/UseUse.php', + 'PhpParser\\Node\\Stmt\\Use_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Use_.php', + 'PhpParser\\Node\\Stmt\\While_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Stmt/While_.php', + 'PhpParser\\Node\\UnionType' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/UnionType.php', + 'PhpParser\\Node\\VarLikeIdentifier' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/VarLikeIdentifier.php', + 'PhpParser\\Parser' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Parser.php', + 'PhpParser\\ParserAbstract' => $vendorDir . '/nikic/php-parser/lib/PhpParser/ParserAbstract.php', + 'PhpParser\\ParserFactory' => $vendorDir . '/nikic/php-parser/lib/PhpParser/ParserFactory.php', + 'PhpParser\\Parser\\Multiple' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Parser/Multiple.php', + 'PhpParser\\Parser\\Php5' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Parser/Php5.php', + 'PhpParser\\Parser\\Php7' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Parser/Php7.php', + 'PhpParser\\Parser\\Tokens' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Parser/Tokens.php', + 'PhpParser\\PrettyPrinterAbstract' => $vendorDir . '/nikic/php-parser/lib/PhpParser/PrettyPrinterAbstract.php', + 'PhpParser\\PrettyPrinter\\Standard' => $vendorDir . '/nikic/php-parser/lib/PhpParser/PrettyPrinter/Standard.php', 'Predis\\Autoloader' => $vendorDir . '/predis/predis/src/Autoloader.php', 'Predis\\Client' => $vendorDir . '/predis/predis/src/Client.php', 'Predis\\ClientContextInterface' => $vendorDir . '/predis/predis/src/ClientContextInterface.php', @@ -3760,6 +4091,10 @@ return array( 'Psr\\EventDispatcher\\EventDispatcherInterface' => $vendorDir . '/psr/event-dispatcher/src/EventDispatcherInterface.php', 'Psr\\EventDispatcher\\ListenerProviderInterface' => $vendorDir . '/psr/event-dispatcher/src/ListenerProviderInterface.php', 'Psr\\EventDispatcher\\StoppableEventInterface' => $vendorDir . '/psr/event-dispatcher/src/StoppableEventInterface.php', + 'Psr\\Http\\Client\\ClientExceptionInterface' => $vendorDir . '/psr/http-client/src/ClientExceptionInterface.php', + 'Psr\\Http\\Client\\ClientInterface' => $vendorDir . '/psr/http-client/src/ClientInterface.php', + 'Psr\\Http\\Client\\NetworkExceptionInterface' => $vendorDir . '/psr/http-client/src/NetworkExceptionInterface.php', + 'Psr\\Http\\Client\\RequestExceptionInterface' => $vendorDir . '/psr/http-client/src/RequestExceptionInterface.php', 'Psr\\Http\\Message\\MessageInterface' => $vendorDir . '/psr/http-message/src/MessageInterface.php', 'Psr\\Http\\Message\\RequestInterface' => $vendorDir . '/psr/http-message/src/RequestInterface.php', 'Psr\\Http\\Message\\ResponseInterface' => $vendorDir . '/psr/http-message/src/ResponseInterface.php', @@ -3948,22 +4283,50 @@ return array( 'Seat\\Eseye\\Log\\RotatingFileLogger' => $vendorDir . '/eveseat/eseye/src/Log/RotatingFileLogger.php', 'Seat\\Eseye\\Traits\\ConstructsContainers' => $vendorDir . '/eveseat/eseye/src/Traits/ConstructsContainers.php', 'Seat\\Eseye\\Traits\\ValidatesContainers' => $vendorDir . '/eveseat/eseye/src/Traits/ValidatesContainers.php', + 'SebastianBergmann\\CliParser\\AmbiguousOptionException' => $vendorDir . '/sebastian/cli-parser/src/exceptions/AmbiguousOptionException.php', + 'SebastianBergmann\\CliParser\\Exception' => $vendorDir . '/sebastian/cli-parser/src/exceptions/Exception.php', + 'SebastianBergmann\\CliParser\\OptionDoesNotAllowArgumentException' => $vendorDir . '/sebastian/cli-parser/src/exceptions/OptionDoesNotAllowArgumentException.php', + 'SebastianBergmann\\CliParser\\Parser' => $vendorDir . '/sebastian/cli-parser/src/Parser.php', + 'SebastianBergmann\\CliParser\\RequiredOptionArgumentMissingException' => $vendorDir . '/sebastian/cli-parser/src/exceptions/RequiredOptionArgumentMissingException.php', + 'SebastianBergmann\\CliParser\\UnknownOptionException' => $vendorDir . '/sebastian/cli-parser/src/exceptions/UnknownOptionException.php', + 'SebastianBergmann\\CodeCoverage\\BranchAndPathCoverageNotSupportedException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/BranchAndPathCoverageNotSupportedException.php', 'SebastianBergmann\\CodeCoverage\\CodeCoverage' => $vendorDir . '/phpunit/php-code-coverage/src/CodeCoverage.php', - 'SebastianBergmann\\CodeCoverage\\CoveredCodeNotExecutedException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/CoveredCodeNotExecutedException.php', + 'SebastianBergmann\\CodeCoverage\\CrapIndex' => $vendorDir . '/phpunit/php-code-coverage/src/CrapIndex.php', + 'SebastianBergmann\\CodeCoverage\\DeadCodeDetectionNotSupportedException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/DeadCodeDetectionNotSupportedException.php', + 'SebastianBergmann\\CodeCoverage\\Directory' => $vendorDir . '/phpunit/php-code-coverage/src/Directory.php', + 'SebastianBergmann\\CodeCoverage\\DirectoryCouldNotBeCreatedException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/DirectoryCouldNotBeCreatedException.php', 'SebastianBergmann\\CodeCoverage\\Driver\\Driver' => $vendorDir . '/phpunit/php-code-coverage/src/Driver/Driver.php', - 'SebastianBergmann\\CodeCoverage\\Driver\\PCOV' => $vendorDir . '/phpunit/php-code-coverage/src/Driver/PCOV.php', - 'SebastianBergmann\\CodeCoverage\\Driver\\PHPDBG' => $vendorDir . '/phpunit/php-code-coverage/src/Driver/PHPDBG.php', - 'SebastianBergmann\\CodeCoverage\\Driver\\Xdebug' => $vendorDir . '/phpunit/php-code-coverage/src/Driver/Xdebug.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\PathExistsButIsNotDirectoryException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/PathExistsButIsNotDirectoryException.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\PcovDriver' => $vendorDir . '/phpunit/php-code-coverage/src/Driver/PcovDriver.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\PcovNotAvailableException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/PcovNotAvailableException.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\PhpdbgDriver' => $vendorDir . '/phpunit/php-code-coverage/src/Driver/PhpdbgDriver.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\PhpdbgNotAvailableException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/PhpdbgNotAvailableException.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\Selector' => $vendorDir . '/phpunit/php-code-coverage/src/Driver/Selector.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\WriteOperationFailedException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/WriteOperationFailedException.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\WrongXdebugVersionException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/WrongXdebugVersionException.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\Xdebug2Driver' => $vendorDir . '/phpunit/php-code-coverage/src/Driver/Xdebug2Driver.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\Xdebug2NotEnabledException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/Xdebug2NotEnabledException.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\Xdebug3Driver' => $vendorDir . '/phpunit/php-code-coverage/src/Driver/Xdebug3Driver.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\Xdebug3NotEnabledException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/Xdebug3NotEnabledException.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\XdebugNotAvailableException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/XdebugNotAvailableException.php', 'SebastianBergmann\\CodeCoverage\\Exception' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/Exception.php', 'SebastianBergmann\\CodeCoverage\\Filter' => $vendorDir . '/phpunit/php-code-coverage/src/Filter.php', 'SebastianBergmann\\CodeCoverage\\InvalidArgumentException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/InvalidArgumentException.php', - 'SebastianBergmann\\CodeCoverage\\MissingCoversAnnotationException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/MissingCoversAnnotationException.php', + 'SebastianBergmann\\CodeCoverage\\NoCodeCoverageDriverAvailableException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/NoCodeCoverageDriverAvailableException.php', + 'SebastianBergmann\\CodeCoverage\\NoCodeCoverageDriverWithPathCoverageSupportAvailableException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/NoCodeCoverageDriverWithPathCoverageSupportAvailableException.php', 'SebastianBergmann\\CodeCoverage\\Node\\AbstractNode' => $vendorDir . '/phpunit/php-code-coverage/src/Node/AbstractNode.php', 'SebastianBergmann\\CodeCoverage\\Node\\Builder' => $vendorDir . '/phpunit/php-code-coverage/src/Node/Builder.php', 'SebastianBergmann\\CodeCoverage\\Node\\Directory' => $vendorDir . '/phpunit/php-code-coverage/src/Node/Directory.php', 'SebastianBergmann\\CodeCoverage\\Node\\File' => $vendorDir . '/phpunit/php-code-coverage/src/Node/File.php', 'SebastianBergmann\\CodeCoverage\\Node\\Iterator' => $vendorDir . '/phpunit/php-code-coverage/src/Node/Iterator.php', + 'SebastianBergmann\\CodeCoverage\\ParserException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/ParserException.php', + 'SebastianBergmann\\CodeCoverage\\Percentage' => $vendorDir . '/phpunit/php-code-coverage/src/Percentage.php', + 'SebastianBergmann\\CodeCoverage\\ProcessedCodeCoverageData' => $vendorDir . '/phpunit/php-code-coverage/src/ProcessedCodeCoverageData.php', + 'SebastianBergmann\\CodeCoverage\\RawCodeCoverageData' => $vendorDir . '/phpunit/php-code-coverage/src/RawCodeCoverageData.php', + 'SebastianBergmann\\CodeCoverage\\ReflectionException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/ReflectionException.php', + 'SebastianBergmann\\CodeCoverage\\ReportAlreadyFinalizedException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/ReportAlreadyFinalizedException.php', 'SebastianBergmann\\CodeCoverage\\Report\\Clover' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Clover.php', + 'SebastianBergmann\\CodeCoverage\\Report\\Cobertura' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Cobertura.php', 'SebastianBergmann\\CodeCoverage\\Report\\Crap4j' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Crap4j.php', 'SebastianBergmann\\CodeCoverage\\Report\\Html\\Dashboard' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Html/Renderer/Dashboard.php', 'SebastianBergmann\\CodeCoverage\\Report\\Html\\Directory' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Html/Renderer/Directory.php', @@ -3985,26 +4348,63 @@ return array( 'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Tests' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Xml/Tests.php', 'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Totals' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Xml/Totals.php', 'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Unit' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Xml/Unit.php', - 'SebastianBergmann\\CodeCoverage\\RuntimeException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/RuntimeException.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysisCacheNotConfiguredException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/StaticAnalysisCacheNotConfiguredException.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\Cache' => $vendorDir . '/phpunit/php-code-coverage/src/StaticAnalysis/Cache.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\CacheWarmer' => $vendorDir . '/phpunit/php-code-coverage/src/StaticAnalysis/CacheWarmer.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\CachingCoveredFileAnalyser' => $vendorDir . '/phpunit/php-code-coverage/src/StaticAnalysis/CachingCoveredFileAnalyser.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\CachingUncoveredFileAnalyser' => $vendorDir . '/phpunit/php-code-coverage/src/StaticAnalysis/CachingUncoveredFileAnalyser.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\CodeUnitFindingVisitor' => $vendorDir . '/phpunit/php-code-coverage/src/StaticAnalysis/CodeUnitFindingVisitor.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\CoveredFileAnalyser' => $vendorDir . '/phpunit/php-code-coverage/src/StaticAnalysis/CoveredFileAnalyser.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\ExecutableLinesFindingVisitor' => $vendorDir . '/phpunit/php-code-coverage/src/StaticAnalysis/ExecutableLinesFindingVisitor.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\IgnoredLinesFindingVisitor' => $vendorDir . '/phpunit/php-code-coverage/src/StaticAnalysis/IgnoredLinesFindingVisitor.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\ParsingCoveredFileAnalyser' => $vendorDir . '/phpunit/php-code-coverage/src/StaticAnalysis/ParsingCoveredFileAnalyser.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\ParsingUncoveredFileAnalyser' => $vendorDir . '/phpunit/php-code-coverage/src/StaticAnalysis/ParsingUncoveredFileAnalyser.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\UncoveredFileAnalyser' => $vendorDir . '/phpunit/php-code-coverage/src/StaticAnalysis/UncoveredFileAnalyser.php', + 'SebastianBergmann\\CodeCoverage\\TestIdMissingException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/TestIdMissingException.php', 'SebastianBergmann\\CodeCoverage\\UnintentionallyCoveredCodeException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/UnintentionallyCoveredCodeException.php', - 'SebastianBergmann\\CodeCoverage\\Util' => $vendorDir . '/phpunit/php-code-coverage/src/Util.php', 'SebastianBergmann\\CodeCoverage\\Version' => $vendorDir . '/phpunit/php-code-coverage/src/Version.php', + 'SebastianBergmann\\CodeCoverage\\XmlException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/XmlException.php', 'SebastianBergmann\\CodeUnitReverseLookup\\Wizard' => $vendorDir . '/sebastian/code-unit-reverse-lookup/src/Wizard.php', + 'SebastianBergmann\\CodeUnit\\ClassMethodUnit' => $vendorDir . '/sebastian/code-unit/src/ClassMethodUnit.php', + 'SebastianBergmann\\CodeUnit\\ClassUnit' => $vendorDir . '/sebastian/code-unit/src/ClassUnit.php', + 'SebastianBergmann\\CodeUnit\\CodeUnit' => $vendorDir . '/sebastian/code-unit/src/CodeUnit.php', + 'SebastianBergmann\\CodeUnit\\CodeUnitCollection' => $vendorDir . '/sebastian/code-unit/src/CodeUnitCollection.php', + 'SebastianBergmann\\CodeUnit\\CodeUnitCollectionIterator' => $vendorDir . '/sebastian/code-unit/src/CodeUnitCollectionIterator.php', + 'SebastianBergmann\\CodeUnit\\Exception' => $vendorDir . '/sebastian/code-unit/src/exceptions/Exception.php', + 'SebastianBergmann\\CodeUnit\\FunctionUnit' => $vendorDir . '/sebastian/code-unit/src/FunctionUnit.php', + 'SebastianBergmann\\CodeUnit\\InterfaceMethodUnit' => $vendorDir . '/sebastian/code-unit/src/InterfaceMethodUnit.php', + 'SebastianBergmann\\CodeUnit\\InterfaceUnit' => $vendorDir . '/sebastian/code-unit/src/InterfaceUnit.php', + 'SebastianBergmann\\CodeUnit\\InvalidCodeUnitException' => $vendorDir . '/sebastian/code-unit/src/exceptions/InvalidCodeUnitException.php', + 'SebastianBergmann\\CodeUnit\\Mapper' => $vendorDir . '/sebastian/code-unit/src/Mapper.php', + 'SebastianBergmann\\CodeUnit\\NoTraitException' => $vendorDir . '/sebastian/code-unit/src/exceptions/NoTraitException.php', + 'SebastianBergmann\\CodeUnit\\ReflectionException' => $vendorDir . '/sebastian/code-unit/src/exceptions/ReflectionException.php', + 'SebastianBergmann\\CodeUnit\\TraitMethodUnit' => $vendorDir . '/sebastian/code-unit/src/TraitMethodUnit.php', + 'SebastianBergmann\\CodeUnit\\TraitUnit' => $vendorDir . '/sebastian/code-unit/src/TraitUnit.php', 'SebastianBergmann\\Comparator\\ArrayComparator' => $vendorDir . '/sebastian/comparator/src/ArrayComparator.php', 'SebastianBergmann\\Comparator\\Comparator' => $vendorDir . '/sebastian/comparator/src/Comparator.php', 'SebastianBergmann\\Comparator\\ComparisonFailure' => $vendorDir . '/sebastian/comparator/src/ComparisonFailure.php', 'SebastianBergmann\\Comparator\\DOMNodeComparator' => $vendorDir . '/sebastian/comparator/src/DOMNodeComparator.php', 'SebastianBergmann\\Comparator\\DateTimeComparator' => $vendorDir . '/sebastian/comparator/src/DateTimeComparator.php', 'SebastianBergmann\\Comparator\\DoubleComparator' => $vendorDir . '/sebastian/comparator/src/DoubleComparator.php', + 'SebastianBergmann\\Comparator\\Exception' => $vendorDir . '/sebastian/comparator/src/exceptions/Exception.php', 'SebastianBergmann\\Comparator\\ExceptionComparator' => $vendorDir . '/sebastian/comparator/src/ExceptionComparator.php', 'SebastianBergmann\\Comparator\\Factory' => $vendorDir . '/sebastian/comparator/src/Factory.php', 'SebastianBergmann\\Comparator\\MockObjectComparator' => $vendorDir . '/sebastian/comparator/src/MockObjectComparator.php', 'SebastianBergmann\\Comparator\\NumericComparator' => $vendorDir . '/sebastian/comparator/src/NumericComparator.php', 'SebastianBergmann\\Comparator\\ObjectComparator' => $vendorDir . '/sebastian/comparator/src/ObjectComparator.php', 'SebastianBergmann\\Comparator\\ResourceComparator' => $vendorDir . '/sebastian/comparator/src/ResourceComparator.php', + 'SebastianBergmann\\Comparator\\RuntimeException' => $vendorDir . '/sebastian/comparator/src/exceptions/RuntimeException.php', 'SebastianBergmann\\Comparator\\ScalarComparator' => $vendorDir . '/sebastian/comparator/src/ScalarComparator.php', 'SebastianBergmann\\Comparator\\SplObjectStorageComparator' => $vendorDir . '/sebastian/comparator/src/SplObjectStorageComparator.php', 'SebastianBergmann\\Comparator\\TypeComparator' => $vendorDir . '/sebastian/comparator/src/TypeComparator.php', + 'SebastianBergmann\\Complexity\\Calculator' => $vendorDir . '/sebastian/complexity/src/Calculator.php', + 'SebastianBergmann\\Complexity\\Complexity' => $vendorDir . '/sebastian/complexity/src/Complexity/Complexity.php', + 'SebastianBergmann\\Complexity\\ComplexityCalculatingVisitor' => $vendorDir . '/sebastian/complexity/src/Visitor/ComplexityCalculatingVisitor.php', + 'SebastianBergmann\\Complexity\\ComplexityCollection' => $vendorDir . '/sebastian/complexity/src/Complexity/ComplexityCollection.php', + 'SebastianBergmann\\Complexity\\ComplexityCollectionIterator' => $vendorDir . '/sebastian/complexity/src/Complexity/ComplexityCollectionIterator.php', + 'SebastianBergmann\\Complexity\\CyclomaticComplexityCalculatingVisitor' => $vendorDir . '/sebastian/complexity/src/Visitor/CyclomaticComplexityCalculatingVisitor.php', + 'SebastianBergmann\\Complexity\\Exception' => $vendorDir . '/sebastian/complexity/src/Exception/Exception.php', + 'SebastianBergmann\\Complexity\\RuntimeException' => $vendorDir . '/sebastian/complexity/src/Exception/RuntimeException.php', 'SebastianBergmann\\Diff\\Chunk' => $vendorDir . '/sebastian/diff/src/Chunk.php', 'SebastianBergmann\\Diff\\ConfigurationException' => $vendorDir . '/sebastian/diff/src/Exception/ConfigurationException.php', 'SebastianBergmann\\Diff\\Diff' => $vendorDir . '/sebastian/diff/src/Diff.php', @@ -4028,12 +4428,23 @@ return array( 'SebastianBergmann\\FileIterator\\Facade' => $vendorDir . '/phpunit/php-file-iterator/src/Facade.php', 'SebastianBergmann\\FileIterator\\Factory' => $vendorDir . '/phpunit/php-file-iterator/src/Factory.php', 'SebastianBergmann\\FileIterator\\Iterator' => $vendorDir . '/phpunit/php-file-iterator/src/Iterator.php', - 'SebastianBergmann\\GlobalState\\Blacklist' => $vendorDir . '/sebastian/global-state/src/Blacklist.php', 'SebastianBergmann\\GlobalState\\CodeExporter' => $vendorDir . '/sebastian/global-state/src/CodeExporter.php', 'SebastianBergmann\\GlobalState\\Exception' => $vendorDir . '/sebastian/global-state/src/exceptions/Exception.php', + 'SebastianBergmann\\GlobalState\\ExcludeList' => $vendorDir . '/sebastian/global-state/src/ExcludeList.php', 'SebastianBergmann\\GlobalState\\Restorer' => $vendorDir . '/sebastian/global-state/src/Restorer.php', 'SebastianBergmann\\GlobalState\\RuntimeException' => $vendorDir . '/sebastian/global-state/src/exceptions/RuntimeException.php', 'SebastianBergmann\\GlobalState\\Snapshot' => $vendorDir . '/sebastian/global-state/src/Snapshot.php', + 'SebastianBergmann\\Invoker\\Exception' => $vendorDir . '/phpunit/php-invoker/src/exceptions/Exception.php', + 'SebastianBergmann\\Invoker\\Invoker' => $vendorDir . '/phpunit/php-invoker/src/Invoker.php', + 'SebastianBergmann\\Invoker\\ProcessControlExtensionNotLoadedException' => $vendorDir . '/phpunit/php-invoker/src/exceptions/ProcessControlExtensionNotLoadedException.php', + 'SebastianBergmann\\Invoker\\TimeoutException' => $vendorDir . '/phpunit/php-invoker/src/exceptions/TimeoutException.php', + 'SebastianBergmann\\LinesOfCode\\Counter' => $vendorDir . '/sebastian/lines-of-code/src/Counter.php', + 'SebastianBergmann\\LinesOfCode\\Exception' => $vendorDir . '/sebastian/lines-of-code/src/Exception/Exception.php', + 'SebastianBergmann\\LinesOfCode\\IllogicalValuesException' => $vendorDir . '/sebastian/lines-of-code/src/Exception/IllogicalValuesException.php', + 'SebastianBergmann\\LinesOfCode\\LineCountingVisitor' => $vendorDir . '/sebastian/lines-of-code/src/LineCountingVisitor.php', + 'SebastianBergmann\\LinesOfCode\\LinesOfCode' => $vendorDir . '/sebastian/lines-of-code/src/LinesOfCode.php', + 'SebastianBergmann\\LinesOfCode\\NegativeValueException' => $vendorDir . '/sebastian/lines-of-code/src/Exception/NegativeValueException.php', + 'SebastianBergmann\\LinesOfCode\\RuntimeException' => $vendorDir . '/sebastian/lines-of-code/src/Exception/RuntimeException.php', 'SebastianBergmann\\ObjectEnumerator\\Enumerator' => $vendorDir . '/sebastian/object-enumerator/src/Enumerator.php', 'SebastianBergmann\\ObjectEnumerator\\Exception' => $vendorDir . '/sebastian/object-enumerator/src/Exception.php', 'SebastianBergmann\\ObjectEnumerator\\InvalidArgumentException' => $vendorDir . '/sebastian/object-enumerator/src/InvalidArgumentException.php', @@ -4044,19 +4455,30 @@ return array( 'SebastianBergmann\\RecursionContext\\Exception' => $vendorDir . '/sebastian/recursion-context/src/Exception.php', 'SebastianBergmann\\RecursionContext\\InvalidArgumentException' => $vendorDir . '/sebastian/recursion-context/src/InvalidArgumentException.php', 'SebastianBergmann\\ResourceOperations\\ResourceOperations' => $vendorDir . '/sebastian/resource-operations/src/ResourceOperations.php', - 'SebastianBergmann\\Timer\\Exception' => $vendorDir . '/phpunit/php-timer/src/Exception.php', - 'SebastianBergmann\\Timer\\RuntimeException' => $vendorDir . '/phpunit/php-timer/src/RuntimeException.php', + 'SebastianBergmann\\Template\\Exception' => $vendorDir . '/phpunit/php-text-template/src/exceptions/Exception.php', + 'SebastianBergmann\\Template\\InvalidArgumentException' => $vendorDir . '/phpunit/php-text-template/src/exceptions/InvalidArgumentException.php', + 'SebastianBergmann\\Template\\RuntimeException' => $vendorDir . '/phpunit/php-text-template/src/exceptions/RuntimeException.php', + 'SebastianBergmann\\Template\\Template' => $vendorDir . '/phpunit/php-text-template/src/Template.php', + 'SebastianBergmann\\Timer\\Duration' => $vendorDir . '/phpunit/php-timer/src/Duration.php', + 'SebastianBergmann\\Timer\\Exception' => $vendorDir . '/phpunit/php-timer/src/exceptions/Exception.php', + 'SebastianBergmann\\Timer\\NoActiveTimerException' => $vendorDir . '/phpunit/php-timer/src/exceptions/NoActiveTimerException.php', + 'SebastianBergmann\\Timer\\ResourceUsageFormatter' => $vendorDir . '/phpunit/php-timer/src/ResourceUsageFormatter.php', + 'SebastianBergmann\\Timer\\TimeSinceStartOfRequestNotAvailableException' => $vendorDir . '/phpunit/php-timer/src/exceptions/TimeSinceStartOfRequestNotAvailableException.php', 'SebastianBergmann\\Timer\\Timer' => $vendorDir . '/phpunit/php-timer/src/Timer.php', 'SebastianBergmann\\Type\\CallableType' => $vendorDir . '/sebastian/type/src/CallableType.php', 'SebastianBergmann\\Type\\Exception' => $vendorDir . '/sebastian/type/src/exception/Exception.php', 'SebastianBergmann\\Type\\GenericObjectType' => $vendorDir . '/sebastian/type/src/GenericObjectType.php', 'SebastianBergmann\\Type\\IterableType' => $vendorDir . '/sebastian/type/src/IterableType.php', + 'SebastianBergmann\\Type\\MixedType' => $vendorDir . '/sebastian/type/src/MixedType.php', 'SebastianBergmann\\Type\\NullType' => $vendorDir . '/sebastian/type/src/NullType.php', 'SebastianBergmann\\Type\\ObjectType' => $vendorDir . '/sebastian/type/src/ObjectType.php', + 'SebastianBergmann\\Type\\ReflectionMapper' => $vendorDir . '/sebastian/type/src/ReflectionMapper.php', 'SebastianBergmann\\Type\\RuntimeException' => $vendorDir . '/sebastian/type/src/exception/RuntimeException.php', 'SebastianBergmann\\Type\\SimpleType' => $vendorDir . '/sebastian/type/src/SimpleType.php', + 'SebastianBergmann\\Type\\StaticType' => $vendorDir . '/sebastian/type/src/StaticType.php', 'SebastianBergmann\\Type\\Type' => $vendorDir . '/sebastian/type/src/Type.php', 'SebastianBergmann\\Type\\TypeName' => $vendorDir . '/sebastian/type/src/TypeName.php', + 'SebastianBergmann\\Type\\UnionType' => $vendorDir . '/sebastian/type/src/UnionType.php', 'SebastianBergmann\\Type\\UnknownType' => $vendorDir . '/sebastian/type/src/UnknownType.php', 'SebastianBergmann\\Type\\VoidType' => $vendorDir . '/sebastian/type/src/VoidType.php', 'SebastianBergmann\\Version' => $vendorDir . '/sebastian/version/src/Version.php', @@ -4848,7 +5270,6 @@ return array( 'Tests\\Feature\\ExampleTest' => $baseDir . '/tests/Feature/ExampleTest.php', 'Tests\\TestCase' => $baseDir . '/tests/TestCase.php', 'Tests\\Unit\\ExampleTest' => $baseDir . '/tests/Unit/ExampleTest.php', - 'Text_Template' => $vendorDir . '/phpunit/php-text-template/src/Template.php', 'TheSeer\\Tokenizer\\Exception' => $vendorDir . '/theseer/tokenizer/src/Exception.php', 'TheSeer\\Tokenizer\\NamespaceUri' => $vendorDir . '/theseer/tokenizer/src/NamespaceUri.php', 'TheSeer\\Tokenizer\\NamespaceUriException' => $vendorDir . '/theseer/tokenizer/src/NamespaceUriException.php', diff --git a/vendor/composer/autoload_files.php b/vendor/composer/autoload_files.php index a43fbbd7b..44064acdb 100644 --- a/vendor/composer/autoload_files.php +++ b/vendor/composer/autoload_files.php @@ -6,6 +6,7 @@ $vendorDir = dirname(dirname(__FILE__)); $baseDir = dirname($vendorDir); return array( + 'ec07570ca5a812141189b1fa81503674' => $vendorDir . '/phpunit/phpunit/src/Framework/Assert/Functions.php', 'a4a119a56e50fbb293281d9a48007e0e' => $vendorDir . '/symfony/polyfill-php80/bootstrap.php', '6e3fae29631ef280660b3cdad06f25a8' => $vendorDir . '/symfony/deprecation-contracts/function.php', '0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => $vendorDir . '/symfony/polyfill-mbstring/bootstrap.php', @@ -18,18 +19,19 @@ return array( '7b11c4dc42b3b3023073cb14e519683c' => $vendorDir . '/ralouphie/getallheaders/src/getallheaders.php', 'c964ee0ededf28c96ebd9db5099ef910' => $vendorDir . '/guzzlehttp/promises/src/functions_include.php', 'a0edc8309cc5e1d60e3047b5df6b7052' => $vendorDir . '/guzzlehttp/psr7/src/functions_include.php', + 'a1105708a18b76903365ca1c4aa61b02' => $vendorDir . '/symfony/translation/Resources/functions.php', '37a3dc5111fe8f707ab4c132ef1dbc62' => $vendorDir . '/guzzlehttp/guzzle/src/functions_include.php', 'def43f6c87e4f8dfd0c9e1b1bab14fe8' => $vendorDir . '/symfony/polyfill-iconv/bootstrap.php', '2c102faa651ef8ea5874edb585946bce' => $vendorDir . '/swiftmailer/swiftmailer/lib/swift_required.php', - 'a1105708a18b76903365ca1c4aa61b02' => $vendorDir . '/symfony/translation/Resources/functions.php', 'e39a8b23c42d4e1452234d762b03835a' => $vendorDir . '/ramsey/uuid/src/functions.php', '538ca81a9a966a6716601ecf48f4eaef' => $vendorDir . '/opis/closure/functions.php', '8825ede83f2f289127722d4e842cf7e8' => $vendorDir . '/symfony/polyfill-intl-grapheme/bootstrap.php', - '34122c0574b76bf21c9a8db62b5b9cf3' => $vendorDir . '/cakephp/chronos/src/carbon_compat.php', - 'f0906e6318348a765ffb6eb24e0d0938' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/helpers.php', - '58571171fd5812e6e447dce228f52f4d' => $vendorDir . '/laravel/framework/src/Illuminate/Support/helpers.php', '6124b4c8570aa390c21fafd04a26c69f' => $vendorDir . '/myclabs/deep-copy/src/DeepCopy/deep_copy.php', 'b6b991a57620e2fb6b2f66f03fe9ddc2' => $vendorDir . '/symfony/string/Resources/functions.php', + '265b4faa2b3a9766332744949e83bf97' => $vendorDir . '/laravel/framework/src/Illuminate/Collections/helpers.php', + 'c7a3c339e7e14b60e06a2d7fcce9476b' => $vendorDir . '/laravel/framework/src/Illuminate/Events/functions.php', + 'f0906e6318348a765ffb6eb24e0d0938' => $vendorDir . '/laravel/framework/src/Illuminate/Foundation/helpers.php', + '58571171fd5812e6e447dce228f52f4d' => $vendorDir . '/laravel/framework/src/Illuminate/Support/helpers.php', '0d8253363903f0ac7b0978dcde4e28a0' => $vendorDir . '/beyondcode/laravel-dump-server/helpers.php', '664e151c91315b3715336cbec9a6600a' => $vendorDir . '/eveseat/eseye/src/Helpers/helpers.php', '17d016dc52a631c1e74d2eb8fdd57342' => $vendorDir . '/laravel/helpers/src/helpers.php', diff --git a/vendor/composer/autoload_psr4.php b/vendor/composer/autoload_psr4.php index 8e154cd8a..aceb0f8db 100644 --- a/vendor/composer/autoload_psr4.php +++ b/vendor/composer/autoload_psr4.php @@ -47,10 +47,12 @@ return array( 'Psr\\SimpleCache\\' => array($vendorDir . '/psr/simple-cache/src'), 'Psr\\Log\\' => array($vendorDir . '/psr/log/Psr/Log'), 'Psr\\Http\\Message\\' => array($vendorDir . '/psr/http-message/src'), + 'Psr\\Http\\Client\\' => array($vendorDir . '/psr/http-client/src'), 'Psr\\EventDispatcher\\' => array($vendorDir . '/psr/event-dispatcher/src'), 'Psr\\Container\\' => array($vendorDir . '/psr/container/src'), 'Prophecy\\' => array($vendorDir . '/phpspec/prophecy/src/Prophecy'), 'Predis\\' => array($vendorDir . '/predis/predis/src'), + 'PhpParser\\' => array($vendorDir . '/nikic/php-parser/lib/PhpParser'), 'PhpOption\\' => array($vendorDir . '/phpoption/phpoption/src/PhpOption'), 'Opis\\Closure\\' => array($vendorDir . '/opis/closure/src'), 'NunoMaduro\\Collision\\' => array($vendorDir . '/nunomaduro/collision/src'), @@ -70,11 +72,13 @@ return array( 'Jose\\Component\\Encryption\\' => array($vendorDir . '/web-token/jwt-encryption'), 'Jose\\Component\\Core\\' => array($vendorDir . '/web-token/jwt-core'), 'Jose\\Component\\Checker\\' => array($vendorDir . '/web-token/jwt-checker'), + 'Illuminate\\Support\\' => array($vendorDir . '/laravel/framework/src/Illuminate/Macroable', $vendorDir . '/laravel/framework/src/Illuminate/Collections'), 'Illuminate\\Foundation\\Auth\\' => array($vendorDir . '/laravel/ui/auth-backend'), 'Illuminate\\' => array($vendorDir . '/laravel/framework/src/Illuminate'), 'GuzzleHttp\\Psr7\\' => array($vendorDir . '/guzzlehttp/psr7/src'), 'GuzzleHttp\\Promise\\' => array($vendorDir . '/guzzlehttp/promises/src'), 'GuzzleHttp\\' => array($vendorDir . '/guzzlehttp/guzzle/src'), + 'GrahamCampbell\\ResultType\\' => array($vendorDir . '/graham-campbell/result-type/src'), 'Fideloper\\Proxy\\' => array($vendorDir . '/fideloper/proxy/src'), 'Faker\\' => array($vendorDir . '/fzaninotto/faker/src/Faker'), 'Facade\\IgnitionContracts\\' => array($vendorDir . '/facade/ignition-contracts/src'), @@ -88,7 +92,6 @@ return array( 'Cron\\' => array($vendorDir . '/dragonmantank/cron-expression/src/Cron'), 'Collective\\Html\\' => array($vendorDir . '/laravelcollective/html/src'), 'Carbon\\' => array($vendorDir . '/nesbot/carbon/src/Carbon'), - 'Cake\\Chronos\\' => array($vendorDir . '/cakephp/chronos/src'), 'Brick\\Math\\' => array($vendorDir . '/brick/math/src'), 'BeyondCode\\DumpServer\\' => array($vendorDir . '/beyondcode/laravel-dump-server/src'), 'Base64Url\\' => array($vendorDir . '/spomky-labs/base64url/src'), diff --git a/vendor/composer/autoload_real.php b/vendor/composer/autoload_real.php index 788ec4b8c..c5da339b2 100644 --- a/vendor/composer/autoload_real.php +++ b/vendor/composer/autoload_real.php @@ -25,7 +25,7 @@ class ComposerAutoloaderInitc3f953f8a7291d41a76e1664339777c9 require __DIR__ . '/platform_check.php'; spl_autoload_register(array('ComposerAutoloaderInitc3f953f8a7291d41a76e1664339777c9', 'loadClassLoader'), true, true); - self::$loader = $loader = new \Composer\Autoload\ClassLoader(); + self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(\dirname(__FILE__))); spl_autoload_unregister(array('ComposerAutoloaderInitc3f953f8a7291d41a76e1664339777c9', 'loadClassLoader')); $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded()); diff --git a/vendor/composer/autoload_static.php b/vendor/composer/autoload_static.php index c6825e79a..c24207bef 100644 --- a/vendor/composer/autoload_static.php +++ b/vendor/composer/autoload_static.php @@ -7,6 +7,7 @@ namespace Composer\Autoload; class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 { public static $files = array ( + 'ec07570ca5a812141189b1fa81503674' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Assert/Functions.php', 'a4a119a56e50fbb293281d9a48007e0e' => __DIR__ . '/..' . '/symfony/polyfill-php80/bootstrap.php', '6e3fae29631ef280660b3cdad06f25a8' => __DIR__ . '/..' . '/symfony/deprecation-contracts/function.php', '0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => __DIR__ . '/..' . '/symfony/polyfill-mbstring/bootstrap.php', @@ -19,18 +20,19 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 '7b11c4dc42b3b3023073cb14e519683c' => __DIR__ . '/..' . '/ralouphie/getallheaders/src/getallheaders.php', 'c964ee0ededf28c96ebd9db5099ef910' => __DIR__ . '/..' . '/guzzlehttp/promises/src/functions_include.php', 'a0edc8309cc5e1d60e3047b5df6b7052' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/functions_include.php', + 'a1105708a18b76903365ca1c4aa61b02' => __DIR__ . '/..' . '/symfony/translation/Resources/functions.php', '37a3dc5111fe8f707ab4c132ef1dbc62' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/functions_include.php', 'def43f6c87e4f8dfd0c9e1b1bab14fe8' => __DIR__ . '/..' . '/symfony/polyfill-iconv/bootstrap.php', '2c102faa651ef8ea5874edb585946bce' => __DIR__ . '/..' . '/swiftmailer/swiftmailer/lib/swift_required.php', - 'a1105708a18b76903365ca1c4aa61b02' => __DIR__ . '/..' . '/symfony/translation/Resources/functions.php', 'e39a8b23c42d4e1452234d762b03835a' => __DIR__ . '/..' . '/ramsey/uuid/src/functions.php', '538ca81a9a966a6716601ecf48f4eaef' => __DIR__ . '/..' . '/opis/closure/functions.php', '8825ede83f2f289127722d4e842cf7e8' => __DIR__ . '/..' . '/symfony/polyfill-intl-grapheme/bootstrap.php', - '34122c0574b76bf21c9a8db62b5b9cf3' => __DIR__ . '/..' . '/cakephp/chronos/src/carbon_compat.php', - 'f0906e6318348a765ffb6eb24e0d0938' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/helpers.php', - '58571171fd5812e6e447dce228f52f4d' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/helpers.php', '6124b4c8570aa390c21fafd04a26c69f' => __DIR__ . '/..' . '/myclabs/deep-copy/src/DeepCopy/deep_copy.php', 'b6b991a57620e2fb6b2f66f03fe9ddc2' => __DIR__ . '/..' . '/symfony/string/Resources/functions.php', + '265b4faa2b3a9766332744949e83bf97' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Collections/helpers.php', + 'c7a3c339e7e14b60e06a2d7fcce9476b' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Events/functions.php', + 'f0906e6318348a765ffb6eb24e0d0938' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/helpers.php', + '58571171fd5812e6e447dce228f52f4d' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/helpers.php', '0d8253363903f0ac7b0978dcde4e28a0' => __DIR__ . '/..' . '/beyondcode/laravel-dump-server/helpers.php', '664e151c91315b3715336cbec9a6600a' => __DIR__ . '/..' . '/eveseat/eseye/src/Helpers/helpers.php', '17d016dc52a631c1e74d2eb8fdd57342' => __DIR__ . '/..' . '/laravel/helpers/src/helpers.php', @@ -99,10 +101,12 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Psr\\SimpleCache\\' => 16, 'Psr\\Log\\' => 8, 'Psr\\Http\\Message\\' => 17, + 'Psr\\Http\\Client\\' => 16, 'Psr\\EventDispatcher\\' => 20, 'Psr\\Container\\' => 14, 'Prophecy\\' => 9, 'Predis\\' => 7, + 'PhpParser\\' => 10, 'PhpOption\\' => 10, ), 'O' => @@ -143,6 +147,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 ), 'I' => array ( + 'Illuminate\\Support\\' => 19, 'Illuminate\\Foundation\\Auth\\' => 27, 'Illuminate\\' => 11, ), @@ -151,6 +156,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'GuzzleHttp\\Psr7\\' => 16, 'GuzzleHttp\\Promise\\' => 19, 'GuzzleHttp\\' => 11, + 'GrahamCampbell\\ResultType\\' => 26, ), 'F' => array ( @@ -176,7 +182,6 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Cron\\' => 5, 'Collective\\Html\\' => 16, 'Carbon\\' => 7, - 'Cake\\Chronos\\' => 13, ), 'B' => array ( @@ -357,6 +362,10 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 array ( 0 => __DIR__ . '/..' . '/psr/http-message/src', ), + 'Psr\\Http\\Client\\' => + array ( + 0 => __DIR__ . '/..' . '/psr/http-client/src', + ), 'Psr\\EventDispatcher\\' => array ( 0 => __DIR__ . '/..' . '/psr/event-dispatcher/src', @@ -373,6 +382,10 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 array ( 0 => __DIR__ . '/..' . '/predis/predis/src', ), + 'PhpParser\\' => + array ( + 0 => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser', + ), 'PhpOption\\' => array ( 0 => __DIR__ . '/..' . '/phpoption/phpoption/src/PhpOption', @@ -451,6 +464,11 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 array ( 0 => __DIR__ . '/..' . '/web-token/jwt-checker', ), + 'Illuminate\\Support\\' => + array ( + 0 => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Macroable', + 1 => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Collections', + ), 'Illuminate\\Foundation\\Auth\\' => array ( 0 => __DIR__ . '/..' . '/laravel/ui/auth-backend', @@ -471,6 +489,10 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 array ( 0 => __DIR__ . '/..' . '/guzzlehttp/guzzle/src', ), + 'GrahamCampbell\\ResultType\\' => + array ( + 0 => __DIR__ . '/..' . '/graham-campbell/result-type/src', + ), 'Fideloper\\Proxy\\' => array ( 0 => __DIR__ . '/..' . '/fideloper/proxy/src', @@ -523,10 +545,6 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 array ( 0 => __DIR__ . '/..' . '/nesbot/carbon/src/Carbon', ), - 'Cake\\Chronos\\' => - array ( - 0 => __DIR__ . '/..' . '/cakephp/chronos/src', - ), 'Brick\\Math\\' => array ( 0 => __DIR__ . '/..' . '/brick/math/src', @@ -563,6 +581,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'App\\Console\\Commands\\Data\\PurgeUsers' => __DIR__ . '/../..' . '/app/Console/Commands/Data/PurgeUsers.php', 'App\\Console\\Commands\\Data\\Test' => __DIR__ . '/../..' . '/app/Console/Commands/Data/Test.php', 'App\\Console\\Commands\\Eve\\ItemPricesUpdateCommand' => __DIR__ . '/../..' . '/app/Console/Commands/Eve/ItemPricesUpdateCommand.php', + 'App\\Console\\Commands\\Files\\ImportAllianceMoons' => __DIR__ . '/../..' . '/app/Console/Commands/Files/ImportAllianceMoons.php', 'App\\Console\\Commands\\Files\\MoonFormatter' => __DIR__ . '/../..' . '/app/Console/Commands/Files/MoonFormatter.php', 'App\\Console\\Commands\\Files\\UpdateItemCompositionFromSDECommand' => __DIR__ . '/../..' . '/app/Console/Commands/Files/UpdateItemCompositionFromSDECommand.php', 'App\\Console\\Commands\\Finances\\UpdateAllianceWalletJournal' => __DIR__ . '/../..' . '/app/Console/Commands/Finances/UpdateAllianceWalletJournal.php', @@ -650,12 +669,15 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'App\\Models\\Lookups\\CharacterLookup' => __DIR__ . '/../..' . '/app/Models/Lookups/CharacterLookup.php', 'App\\Models\\Lookups\\CorporationLookup' => __DIR__ . '/../..' . '/app/Models/Lookups/CorporationLookup.php', 'App\\Models\\Lookups\\ItemLookup' => __DIR__ . '/../..' . '/app/Models/Lookups/ItemLookup.php', + 'App\\Models\\Lookups\\MoonLookup' => __DIR__ . '/../..' . '/app/Models/Lookups/MoonLookup.php', 'App\\Models\\Lookups\\SolarSystem' => __DIR__ . '/../..' . '/app/Models/Lookups/SolarSystem.php', 'App\\Models\\Mail\\SentMail' => __DIR__ . '/../..' . '/app/Models/Mail/SentMail.php', 'App\\Models\\MiningTax\\Invoice' => __DIR__ . '/../..' . '/app/Models/MiningTax/Invoice.php', 'App\\Models\\MiningTax\\Ledger' => __DIR__ . '/../..' . '/app/Models/MiningTax/Ledger.php', 'App\\Models\\MiningTax\\Observer' => __DIR__ . '/../..' . '/app/Models/MiningTax/Observer.php', 'App\\Models\\MiningTax\\Payment' => __DIR__ . '/../..' . '/app/Models/MiningTax/Payment.php', + 'App\\Models\\MoonRental\\AllianceMoon' => __DIR__ . '/../..' . '/app/Models/MoonRental/AllianceMoon.php', + 'App\\Models\\MoonRental\\AllianceMoonRental' => __DIR__ . '/../..' . '/app/Models/MoonRental/AllianceMoonRental.php', 'App\\Models\\Moon\\Config' => __DIR__ . '/../..' . '/app/Models/Moon/Config.php', 'App\\Models\\Moon\\ItemComposition' => __DIR__ . '/../..' . '/app/Models/Moon/ItemComposition.php', 'App\\Models\\Moon\\MineralPrice' => __DIR__ . '/../..' . '/app/Models/Moon/MineralPrice.php', @@ -712,26 +734,6 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Brick\\Math\\Internal\\Calculator\\GmpCalculator' => __DIR__ . '/..' . '/brick/math/src/Internal/Calculator/GmpCalculator.php', 'Brick\\Math\\Internal\\Calculator\\NativeCalculator' => __DIR__ . '/..' . '/brick/math/src/Internal/Calculator/NativeCalculator.php', 'Brick\\Math\\RoundingMode' => __DIR__ . '/..' . '/brick/math/src/RoundingMode.php', - 'Cake\\Chronos\\Chronos' => __DIR__ . '/..' . '/cakephp/chronos/src/Chronos.php', - 'Cake\\Chronos\\ChronosInterface' => __DIR__ . '/..' . '/cakephp/chronos/src/ChronosInterface.php', - 'Cake\\Chronos\\ChronosInterval' => __DIR__ . '/..' . '/cakephp/chronos/src/ChronosInterval.php', - 'Cake\\Chronos\\Date' => __DIR__ . '/..' . '/cakephp/chronos/src/Date.php', - 'Cake\\Chronos\\DifferenceFormatter' => __DIR__ . '/..' . '/cakephp/chronos/src/DifferenceFormatter.php', - 'Cake\\Chronos\\DifferenceFormatterInterface' => __DIR__ . '/..' . '/cakephp/chronos/src/DifferenceFormatterInterface.php', - 'Cake\\Chronos\\MutableDate' => __DIR__ . '/..' . '/cakephp/chronos/src/MutableDate.php', - 'Cake\\Chronos\\MutableDateTime' => __DIR__ . '/..' . '/cakephp/chronos/src/MutableDateTime.php', - 'Cake\\Chronos\\Traits\\ComparisonTrait' => __DIR__ . '/..' . '/cakephp/chronos/src/Traits/ComparisonTrait.php', - 'Cake\\Chronos\\Traits\\CopyTrait' => __DIR__ . '/..' . '/cakephp/chronos/src/Traits/CopyTrait.php', - 'Cake\\Chronos\\Traits\\DifferenceTrait' => __DIR__ . '/..' . '/cakephp/chronos/src/Traits/DifferenceTrait.php', - 'Cake\\Chronos\\Traits\\FactoryTrait' => __DIR__ . '/..' . '/cakephp/chronos/src/Traits/FactoryTrait.php', - 'Cake\\Chronos\\Traits\\FormattingTrait' => __DIR__ . '/..' . '/cakephp/chronos/src/Traits/FormattingTrait.php', - 'Cake\\Chronos\\Traits\\FrozenTimeTrait' => __DIR__ . '/..' . '/cakephp/chronos/src/Traits/FrozenTimeTrait.php', - 'Cake\\Chronos\\Traits\\MagicPropertyTrait' => __DIR__ . '/..' . '/cakephp/chronos/src/Traits/MagicPropertyTrait.php', - 'Cake\\Chronos\\Traits\\ModifierTrait' => __DIR__ . '/..' . '/cakephp/chronos/src/Traits/ModifierTrait.php', - 'Cake\\Chronos\\Traits\\RelativeKeywordTrait' => __DIR__ . '/..' . '/cakephp/chronos/src/Traits/RelativeKeywordTrait.php', - 'Cake\\Chronos\\Traits\\TestingAidTrait' => __DIR__ . '/..' . '/cakephp/chronos/src/Traits/TestingAidTrait.php', - 'Cake\\Chronos\\Traits\\TimezoneTrait' => __DIR__ . '/..' . '/cakephp/chronos/src/Traits/TimezoneTrait.php', - 'Cake\\Chronos\\Translator' => __DIR__ . '/..' . '/cakephp/chronos/src/Translator.php', 'Carbon\\Carbon' => __DIR__ . '/..' . '/nesbot/carbon/src/Carbon/Carbon.php', 'Carbon\\CarbonConverterInterface' => __DIR__ . '/..' . '/nesbot/carbon/src/Carbon/CarbonConverterInterface.php', 'Carbon\\CarbonImmutable' => __DIR__ . '/..' . '/nesbot/carbon/src/Carbon/CarbonImmutable.php', @@ -819,6 +821,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Cron\\DayOfMonthField' => __DIR__ . '/..' . '/dragonmantank/cron-expression/src/Cron/DayOfMonthField.php', 'Cron\\DayOfWeekField' => __DIR__ . '/..' . '/dragonmantank/cron-expression/src/Cron/DayOfWeekField.php', 'Cron\\FieldFactory' => __DIR__ . '/..' . '/dragonmantank/cron-expression/src/Cron/FieldFactory.php', + 'Cron\\FieldFactoryInterface' => __DIR__ . '/..' . '/dragonmantank/cron-expression/src/Cron/FieldFactoryInterface.php', 'Cron\\FieldInterface' => __DIR__ . '/..' . '/dragonmantank/cron-expression/src/Cron/FieldInterface.php', 'Cron\\HoursField' => __DIR__ . '/..' . '/dragonmantank/cron-expression/src/Cron/HoursField.php', 'Cron\\MinutesField' => __DIR__ . '/..' . '/dragonmantank/cron-expression/src/Cron/MinutesField.php', @@ -897,36 +900,44 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Doctrine\\Instantiator\\InstantiatorInterface' => __DIR__ . '/..' . '/doctrine/instantiator/src/Doctrine/Instantiator/InstantiatorInterface.php', 'Dotenv\\Dotenv' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Dotenv.php', 'Dotenv\\Exception\\ExceptionInterface' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Exception/ExceptionInterface.php', + 'Dotenv\\Exception\\InvalidEncodingException' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Exception/InvalidEncodingException.php', 'Dotenv\\Exception\\InvalidFileException' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Exception/InvalidFileException.php', 'Dotenv\\Exception\\InvalidPathException' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Exception/InvalidPathException.php', 'Dotenv\\Exception\\ValidationException' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Exception/ValidationException.php', - 'Dotenv\\Loader\\Lines' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Loader/Lines.php', 'Dotenv\\Loader\\Loader' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Loader/Loader.php', 'Dotenv\\Loader\\LoaderInterface' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Loader/LoaderInterface.php', - 'Dotenv\\Loader\\Parser' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Loader/Parser.php', - 'Dotenv\\Loader\\Value' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Loader/Value.php', - 'Dotenv\\Regex\\Regex' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Regex/Regex.php', - 'Dotenv\\Repository\\AbstractRepository' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Repository/AbstractRepository.php', + 'Dotenv\\Loader\\Resolver' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Loader/Resolver.php', + 'Dotenv\\Parser\\Entry' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Parser/Entry.php', + 'Dotenv\\Parser\\EntryParser' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Parser/EntryParser.php', + 'Dotenv\\Parser\\Lexer' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Parser/Lexer.php', + 'Dotenv\\Parser\\Lines' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Parser/Lines.php', + 'Dotenv\\Parser\\Parser' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Parser/Parser.php', + 'Dotenv\\Parser\\ParserInterface' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Parser/ParserInterface.php', + 'Dotenv\\Parser\\Value' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Parser/Value.php', 'Dotenv\\Repository\\AdapterRepository' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Repository/AdapterRepository.php', + 'Dotenv\\Repository\\Adapter\\AdapterInterface' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Repository/Adapter/AdapterInterface.php', 'Dotenv\\Repository\\Adapter\\ApacheAdapter' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Repository/Adapter/ApacheAdapter.php', 'Dotenv\\Repository\\Adapter\\ArrayAdapter' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Repository/Adapter/ArrayAdapter.php', - 'Dotenv\\Repository\\Adapter\\AvailabilityInterface' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Repository/Adapter/AvailabilityInterface.php', 'Dotenv\\Repository\\Adapter\\EnvConstAdapter' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Repository/Adapter/EnvConstAdapter.php', + 'Dotenv\\Repository\\Adapter\\GuardedWriter' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Repository/Adapter/GuardedWriter.php', + 'Dotenv\\Repository\\Adapter\\ImmutableWriter' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Repository/Adapter/ImmutableWriter.php', + 'Dotenv\\Repository\\Adapter\\MultiReader' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Repository/Adapter/MultiReader.php', + 'Dotenv\\Repository\\Adapter\\MultiWriter' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Repository/Adapter/MultiWriter.php', 'Dotenv\\Repository\\Adapter\\PutenvAdapter' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Repository/Adapter/PutenvAdapter.php', 'Dotenv\\Repository\\Adapter\\ReaderInterface' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Repository/Adapter/ReaderInterface.php', + 'Dotenv\\Repository\\Adapter\\ReplacingWriter' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Repository/Adapter/ReplacingWriter.php', 'Dotenv\\Repository\\Adapter\\ServerConstAdapter' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Repository/Adapter/ServerConstAdapter.php', 'Dotenv\\Repository\\Adapter\\WriterInterface' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Repository/Adapter/WriterInterface.php', 'Dotenv\\Repository\\RepositoryBuilder' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Repository/RepositoryBuilder.php', 'Dotenv\\Repository\\RepositoryInterface' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Repository/RepositoryInterface.php', - 'Dotenv\\Result\\Error' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Result/Error.php', - 'Dotenv\\Result\\Result' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Result/Result.php', - 'Dotenv\\Result\\Success' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Result/Success.php', 'Dotenv\\Store\\FileStore' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Store/FileStore.php', 'Dotenv\\Store\\File\\Paths' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Store/File/Paths.php', 'Dotenv\\Store\\File\\Reader' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Store/File/Reader.php', 'Dotenv\\Store\\StoreBuilder' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Store/StoreBuilder.php', 'Dotenv\\Store\\StoreInterface' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Store/StoreInterface.php', 'Dotenv\\Store\\StringStore' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Store/StringStore.php', + 'Dotenv\\Util\\Regex' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Util/Regex.php', + 'Dotenv\\Util\\Str' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Util/Str.php', 'Dotenv\\Validator' => __DIR__ . '/..' . '/vlucas/phpdotenv/src/Validator.php', 'Egulias\\EmailValidator\\EmailLexer' => __DIR__ . '/..' . '/egulias/email-validator/src/EmailLexer.php', 'Egulias\\EmailValidator\\EmailParser' => __DIR__ . '/..' . '/egulias/email-validator/src/EmailParser.php', @@ -1507,8 +1518,14 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Faker\\ValidGenerator' => __DIR__ . '/..' . '/fzaninotto/faker/src/Faker/ValidGenerator.php', 'Fideloper\\Proxy\\TrustProxies' => __DIR__ . '/..' . '/fideloper/proxy/src/TrustProxies.php', 'Fideloper\\Proxy\\TrustedProxyServiceProvider' => __DIR__ . '/..' . '/fideloper/proxy/src/TrustedProxyServiceProvider.php', + 'GrahamCampbell\\ResultType\\Error' => __DIR__ . '/..' . '/graham-campbell/result-type/src/Error.php', + 'GrahamCampbell\\ResultType\\Result' => __DIR__ . '/..' . '/graham-campbell/result-type/src/Result.php', + 'GrahamCampbell\\ResultType\\Success' => __DIR__ . '/..' . '/graham-campbell/result-type/src/Success.php', + 'GuzzleHttp\\BodySummarizer' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/BodySummarizer.php', + 'GuzzleHttp\\BodySummarizerInterface' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/BodySummarizerInterface.php', 'GuzzleHttp\\Client' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Client.php', 'GuzzleHttp\\ClientInterface' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/ClientInterface.php', + 'GuzzleHttp\\ClientTrait' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/ClientTrait.php', 'GuzzleHttp\\Cookie\\CookieJar' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/CookieJar.php', 'GuzzleHttp\\Cookie\\CookieJarInterface' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/CookieJarInterface.php', 'GuzzleHttp\\Cookie\\FileCookieJar' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php', @@ -1520,7 +1537,6 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'GuzzleHttp\\Exception\\GuzzleException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/GuzzleException.php', 'GuzzleHttp\\Exception\\InvalidArgumentException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/InvalidArgumentException.php', 'GuzzleHttp\\Exception\\RequestException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/RequestException.php', - 'GuzzleHttp\\Exception\\SeekException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/SeekException.php', 'GuzzleHttp\\Exception\\ServerException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/ServerException.php', 'GuzzleHttp\\Exception\\TooManyRedirectsException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/TooManyRedirectsException.php', 'GuzzleHttp\\Exception\\TransferException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/TransferException.php', @@ -1530,10 +1546,12 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'GuzzleHttp\\Handler\\CurlHandler' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/CurlHandler.php', 'GuzzleHttp\\Handler\\CurlMultiHandler' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php', 'GuzzleHttp\\Handler\\EasyHandle' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/EasyHandle.php', + 'GuzzleHttp\\Handler\\HeaderProcessor' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/HeaderProcessor.php', 'GuzzleHttp\\Handler\\MockHandler' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/MockHandler.php', 'GuzzleHttp\\Handler\\Proxy' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/Proxy.php', 'GuzzleHttp\\Handler\\StreamHandler' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/StreamHandler.php', 'GuzzleHttp\\MessageFormatter' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/MessageFormatter.php', + 'GuzzleHttp\\MessageFormatterInterface' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/MessageFormatterInterface.php', 'GuzzleHttp\\Middleware' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Middleware.php', 'GuzzleHttp\\Pool' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Pool.php', 'GuzzleHttp\\PrepareBodyMiddleware' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php', @@ -1585,7 +1603,6 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'GuzzleHttp\\RequestOptions' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/RequestOptions.php', 'GuzzleHttp\\RetryMiddleware' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/RetryMiddleware.php', 'GuzzleHttp\\TransferStats' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/TransferStats.php', - 'GuzzleHttp\\UriTemplate' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/UriTemplate.php', 'GuzzleHttp\\Utils' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Utils.php', 'Hamcrest\\Arrays\\IsArray' => __DIR__ . '/..' . '/hamcrest/hamcrest-php/hamcrest/Hamcrest/Arrays/IsArray.php', 'Hamcrest\\Arrays\\IsArrayContaining' => __DIR__ . '/..' . '/hamcrest/hamcrest-php/hamcrest/Hamcrest/Arrays/IsArrayContaining.php', @@ -1656,6 +1673,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Hamcrest\\Util' => __DIR__ . '/..' . '/hamcrest/hamcrest-php/hamcrest/Hamcrest/Util.php', 'Hamcrest\\Xml\\HasXPath' => __DIR__ . '/..' . '/hamcrest/hamcrest-php/hamcrest/Hamcrest/Xml/HasXPath.php', 'Illuminate\\Auth\\Access\\AuthorizationException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Auth/Access/AuthorizationException.php', + 'Illuminate\\Auth\\Access\\Events\\GateEvaluated' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Auth/Access/Events/GateEvaluated.php', 'Illuminate\\Auth\\Access\\Gate' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Auth/Access/Gate.php', 'Illuminate\\Auth\\Access\\HandlesAuthorization' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Auth/Access/HandlesAuthorization.php', 'Illuminate\\Auth\\Access\\Response' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Auth/Access/Response.php', @@ -1705,6 +1723,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Broadcasting\\BroadcastException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Broadcasting/BroadcastException.php', 'Illuminate\\Broadcasting\\BroadcastManager' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Broadcasting/BroadcastManager.php', 'Illuminate\\Broadcasting\\BroadcastServiceProvider' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Broadcasting/BroadcastServiceProvider.php', + 'Illuminate\\Broadcasting\\Broadcasters\\AblyBroadcaster' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/AblyBroadcaster.php', 'Illuminate\\Broadcasting\\Broadcasters\\Broadcaster' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/Broadcaster.php', 'Illuminate\\Broadcasting\\Broadcasters\\LogBroadcaster' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/LogBroadcaster.php', 'Illuminate\\Broadcasting\\Broadcasters\\NullBroadcaster' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/NullBroadcaster.php', @@ -1717,13 +1736,23 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Broadcasting\\PendingBroadcast' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Broadcasting/PendingBroadcast.php', 'Illuminate\\Broadcasting\\PresenceChannel' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Broadcasting/PresenceChannel.php', 'Illuminate\\Broadcasting\\PrivateChannel' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Broadcasting/PrivateChannel.php', + 'Illuminate\\Bus\\Batch' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Bus/Batch.php', + 'Illuminate\\Bus\\BatchFactory' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Bus/BatchFactory.php', + 'Illuminate\\Bus\\BatchRepository' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Bus/BatchRepository.php', + 'Illuminate\\Bus\\Batchable' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Bus/Batchable.php', 'Illuminate\\Bus\\BusServiceProvider' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Bus/BusServiceProvider.php', + 'Illuminate\\Bus\\DatabaseBatchRepository' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Bus/DatabaseBatchRepository.php', 'Illuminate\\Bus\\Dispatcher' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Bus/Dispatcher.php', + 'Illuminate\\Bus\\Events\\BatchDispatched' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Bus/Events/BatchDispatched.php', + 'Illuminate\\Bus\\PendingBatch' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Bus/PendingBatch.php', + 'Illuminate\\Bus\\PrunableBatchRepository' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Bus/PrunableBatchRepository.php', 'Illuminate\\Bus\\Queueable' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Bus/Queueable.php', + 'Illuminate\\Bus\\UpdatedBatchJobCounts' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Bus/UpdatedBatchJobCounts.php', 'Illuminate\\Cache\\ApcStore' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/ApcStore.php', 'Illuminate\\Cache\\ApcWrapper' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/ApcWrapper.php', 'Illuminate\\Cache\\ArrayLock' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/ArrayLock.php', 'Illuminate\\Cache\\ArrayStore' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/ArrayStore.php', + 'Illuminate\\Cache\\CacheLock' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/CacheLock.php', 'Illuminate\\Cache\\CacheManager' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/CacheManager.php', 'Illuminate\\Cache\\CacheServiceProvider' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/CacheServiceProvider.php', 'Illuminate\\Cache\\Console\\CacheTableCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/Console/CacheTableCommand.php', @@ -1739,13 +1768,19 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Cache\\Events\\KeyForgotten' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/Events/KeyForgotten.php', 'Illuminate\\Cache\\Events\\KeyWritten' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/Events/KeyWritten.php', 'Illuminate\\Cache\\FileStore' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/FileStore.php', + 'Illuminate\\Cache\\HasCacheLock' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/HasCacheLock.php', 'Illuminate\\Cache\\Lock' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/Lock.php', 'Illuminate\\Cache\\LuaScripts' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/LuaScripts.php', 'Illuminate\\Cache\\MemcachedConnector' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/MemcachedConnector.php', 'Illuminate\\Cache\\MemcachedLock' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/MemcachedLock.php', 'Illuminate\\Cache\\MemcachedStore' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/MemcachedStore.php', + 'Illuminate\\Cache\\NoLock' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/NoLock.php', 'Illuminate\\Cache\\NullStore' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/NullStore.php', + 'Illuminate\\Cache\\PhpRedisLock' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/PhpRedisLock.php', 'Illuminate\\Cache\\RateLimiter' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/RateLimiter.php', + 'Illuminate\\Cache\\RateLimiting\\GlobalLimit' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/RateLimiting/GlobalLimit.php', + 'Illuminate\\Cache\\RateLimiting\\Limit' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/RateLimiting/Limit.php', + 'Illuminate\\Cache\\RateLimiting\\Unlimited' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/RateLimiting/Unlimited.php', 'Illuminate\\Cache\\RedisLock' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/RedisLock.php', 'Illuminate\\Cache\\RedisStore' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/RedisStore.php', 'Illuminate\\Cache\\RedisTaggedCache' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/RedisTaggedCache.php', @@ -1754,8 +1789,11 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Cache\\TagSet' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/TagSet.php', 'Illuminate\\Cache\\TaggableStore' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/TaggableStore.php', 'Illuminate\\Cache\\TaggedCache' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cache/TaggedCache.php', + 'Illuminate\\Collections\\ItemNotFoundException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Collections/ItemNotFoundException.php', + 'Illuminate\\Collections\\MultipleItemsFoundException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Collections/MultipleItemsFoundException.php', 'Illuminate\\Config\\Repository' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Config/Repository.php', 'Illuminate\\Console\\Application' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Console/Application.php', + 'Illuminate\\Console\\BufferedConsoleOutput' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Console/BufferedConsoleOutput.php', 'Illuminate\\Console\\Command' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Console/Command.php', 'Illuminate\\Console\\Concerns\\CallsCommands' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Console/Concerns/CallsCommands.php', 'Illuminate\\Console\\Concerns\\HasParameters' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Console/Concerns/HasParameters.php', @@ -1764,6 +1802,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Console\\Events\\ArtisanStarting' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Console/Events/ArtisanStarting.php', 'Illuminate\\Console\\Events\\CommandFinished' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Console/Events/CommandFinished.php', 'Illuminate\\Console\\Events\\CommandStarting' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Console/Events/CommandStarting.php', + 'Illuminate\\Console\\Events\\ScheduledBackgroundTaskFinished' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Console/Events/ScheduledBackgroundTaskFinished.php', 'Illuminate\\Console\\Events\\ScheduledTaskFailed' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Console/Events/ScheduledTaskFailed.php', 'Illuminate\\Console\\Events\\ScheduledTaskFinished' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Console/Events/ScheduledTaskFinished.php', 'Illuminate\\Console\\Events\\ScheduledTaskSkipped' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Console/Events/ScheduledTaskSkipped.php', @@ -1781,7 +1820,10 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Console\\Scheduling\\ManagesFrequencies' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Console/Scheduling/ManagesFrequencies.php', 'Illuminate\\Console\\Scheduling\\Schedule' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Console/Scheduling/Schedule.php', 'Illuminate\\Console\\Scheduling\\ScheduleFinishCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleFinishCommand.php', + 'Illuminate\\Console\\Scheduling\\ScheduleListCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleListCommand.php', 'Illuminate\\Console\\Scheduling\\ScheduleRunCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleRunCommand.php', + 'Illuminate\\Console\\Scheduling\\ScheduleTestCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleTestCommand.php', + 'Illuminate\\Console\\Scheduling\\ScheduleWorkCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleWorkCommand.php', 'Illuminate\\Console\\Scheduling\\SchedulingMutex' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Console/Scheduling/SchedulingMutex.php', 'Illuminate\\Container\\BoundMethod' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Container/BoundMethod.php', 'Illuminate\\Container\\Container' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Container/Container.php', @@ -1818,6 +1860,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Contracts\\Console\\Application' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Console/Application.php', 'Illuminate\\Contracts\\Console\\Kernel' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Console/Kernel.php', 'Illuminate\\Contracts\\Container\\BindingResolutionException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Container/BindingResolutionException.php', + 'Illuminate\\Contracts\\Container\\CircularDependencyException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Container/CircularDependencyException.php', 'Illuminate\\Contracts\\Container\\Container' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Container/Container.php', 'Illuminate\\Contracts\\Container\\ContextualBindingBuilder' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Container/ContextualBindingBuilder.php', 'Illuminate\\Contracts\\Cookie\\Factory' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Cookie/Factory.php', @@ -1825,18 +1868,23 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Contracts\\Database\\Eloquent\\Castable' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Database/Eloquent/Castable.php', 'Illuminate\\Contracts\\Database\\Eloquent\\CastsAttributes' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Database/Eloquent/CastsAttributes.php', 'Illuminate\\Contracts\\Database\\Eloquent\\CastsInboundAttributes' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Database/Eloquent/CastsInboundAttributes.php', + 'Illuminate\\Contracts\\Database\\Eloquent\\DeviatesCastableAttributes' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Database/Eloquent/DeviatesCastableAttributes.php', + 'Illuminate\\Contracts\\Database\\Eloquent\\SerializesCastableAttributes' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Database/Eloquent/SerializesCastableAttributes.php', + 'Illuminate\\Contracts\\Database\\Eloquent\\SupportsPartialRelations' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Database/Eloquent/SupportsPartialRelations.php', 'Illuminate\\Contracts\\Database\\Events\\MigrationEvent' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Database/Events/MigrationEvent.php', 'Illuminate\\Contracts\\Database\\ModelIdentifier' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Database/ModelIdentifier.php', 'Illuminate\\Contracts\\Debug\\ExceptionHandler' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Debug/ExceptionHandler.php', 'Illuminate\\Contracts\\Encryption\\DecryptException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Encryption/DecryptException.php', 'Illuminate\\Contracts\\Encryption\\EncryptException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Encryption/EncryptException.php', 'Illuminate\\Contracts\\Encryption\\Encrypter' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Encryption/Encrypter.php', + 'Illuminate\\Contracts\\Encryption\\StringEncrypter' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Encryption/StringEncrypter.php', 'Illuminate\\Contracts\\Events\\Dispatcher' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Events/Dispatcher.php', 'Illuminate\\Contracts\\Filesystem\\Cloud' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Filesystem/Cloud.php', 'Illuminate\\Contracts\\Filesystem\\Factory' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Filesystem/Factory.php', 'Illuminate\\Contracts\\Filesystem\\FileExistsException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Filesystem/FileExistsException.php', 'Illuminate\\Contracts\\Filesystem\\FileNotFoundException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Filesystem/FileNotFoundException.php', 'Illuminate\\Contracts\\Filesystem\\Filesystem' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Filesystem/Filesystem.php', + 'Illuminate\\Contracts\\Filesystem\\LockTimeoutException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Filesystem/LockTimeoutException.php', 'Illuminate\\Contracts\\Foundation\\Application' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Foundation/Application.php', 'Illuminate\\Contracts\\Foundation\\CachesConfiguration' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Foundation/CachesConfiguration.php', 'Illuminate\\Contracts\\Foundation\\CachesRoutes' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Foundation/CachesRoutes.php', @@ -1848,10 +1896,12 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Contracts\\Mail\\Mailer' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Mail/Mailer.php', 'Illuminate\\Contracts\\Notifications\\Dispatcher' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Notifications/Dispatcher.php', 'Illuminate\\Contracts\\Notifications\\Factory' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Notifications/Factory.php', + 'Illuminate\\Contracts\\Pagination\\CursorPaginator' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Pagination/CursorPaginator.php', 'Illuminate\\Contracts\\Pagination\\LengthAwarePaginator' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Pagination/LengthAwarePaginator.php', 'Illuminate\\Contracts\\Pagination\\Paginator' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Pagination/Paginator.php', 'Illuminate\\Contracts\\Pipeline\\Hub' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Pipeline/Hub.php', 'Illuminate\\Contracts\\Pipeline\\Pipeline' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Pipeline/Pipeline.php', + 'Illuminate\\Contracts\\Queue\\ClearableQueue' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Queue/ClearableQueue.php', 'Illuminate\\Contracts\\Queue\\EntityNotFoundException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Queue/EntityNotFoundException.php', 'Illuminate\\Contracts\\Queue\\EntityResolver' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Queue/EntityResolver.php', 'Illuminate\\Contracts\\Queue\\Factory' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Queue/Factory.php', @@ -1860,6 +1910,9 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Contracts\\Queue\\Queue' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Queue/Queue.php', 'Illuminate\\Contracts\\Queue\\QueueableCollection' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Queue/QueueableCollection.php', 'Illuminate\\Contracts\\Queue\\QueueableEntity' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Queue/QueueableEntity.php', + 'Illuminate\\Contracts\\Queue\\ShouldBeEncrypted' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Queue/ShouldBeEncrypted.php', + 'Illuminate\\Contracts\\Queue\\ShouldBeUnique' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Queue/ShouldBeUnique.php', + 'Illuminate\\Contracts\\Queue\\ShouldBeUniqueUntilProcessing' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Queue/ShouldBeUniqueUntilProcessing.php', 'Illuminate\\Contracts\\Queue\\ShouldQueue' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Queue/ShouldQueue.php', 'Illuminate\\Contracts\\Redis\\Connection' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Redis/Connection.php', 'Illuminate\\Contracts\\Redis\\Connector' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Redis/Connector.php', @@ -1883,11 +1936,14 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Contracts\\Translation\\HasLocalePreference' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Translation/HasLocalePreference.php', 'Illuminate\\Contracts\\Translation\\Loader' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Translation/Loader.php', 'Illuminate\\Contracts\\Translation\\Translator' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Translation/Translator.php', + 'Illuminate\\Contracts\\Validation\\DataAwareRule' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Validation/DataAwareRule.php', 'Illuminate\\Contracts\\Validation\\Factory' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Validation/Factory.php', 'Illuminate\\Contracts\\Validation\\ImplicitRule' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Validation/ImplicitRule.php', 'Illuminate\\Contracts\\Validation\\Rule' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Validation/Rule.php', + 'Illuminate\\Contracts\\Validation\\UncompromisedVerifier' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Validation/UncompromisedVerifier.php', 'Illuminate\\Contracts\\Validation\\ValidatesWhenResolved' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Validation/ValidatesWhenResolved.php', 'Illuminate\\Contracts\\Validation\\Validator' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Validation/Validator.php', + 'Illuminate\\Contracts\\Validation\\ValidatorAwareRule' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/Validation/ValidatorAwareRule.php', 'Illuminate\\Contracts\\View\\Engine' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/View/Engine.php', 'Illuminate\\Contracts\\View\\Factory' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/View/Factory.php', 'Illuminate\\Contracts\\View\\View' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Contracts/View/View.php', @@ -1898,6 +1954,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Cookie\\Middleware\\EncryptCookies' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Cookie/Middleware/EncryptCookies.php', 'Illuminate\\Database\\Capsule\\Manager' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Capsule/Manager.php', 'Illuminate\\Database\\Concerns\\BuildsQueries' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Concerns/BuildsQueries.php', + 'Illuminate\\Database\\Concerns\\ExplainsQueries' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Concerns/ExplainsQueries.php', 'Illuminate\\Database\\Concerns\\ManagesTransactions' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Concerns/ManagesTransactions.php', 'Illuminate\\Database\\ConfigurationUrlParser' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/ConfigurationUrlParser.php', 'Illuminate\\Database\\Connection' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Connection.php', @@ -1911,6 +1968,8 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Database\\Connectors\\PostgresConnector' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Connectors/PostgresConnector.php', 'Illuminate\\Database\\Connectors\\SQLiteConnector' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Connectors/SQLiteConnector.php', 'Illuminate\\Database\\Connectors\\SqlServerConnector' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Connectors/SqlServerConnector.php', + 'Illuminate\\Database\\Console\\DbCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Console/DbCommand.php', + 'Illuminate\\Database\\Console\\DumpCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Console/DumpCommand.php', 'Illuminate\\Database\\Console\\Factories\\FactoryMakeCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Console/Factories/FactoryMakeCommand.php', 'Illuminate\\Database\\Console\\Migrations\\BaseCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Console/Migrations/BaseCommand.php', 'Illuminate\\Database\\Console\\Migrations\\FreshCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Console/Migrations/FreshCommand.php', @@ -1925,11 +1984,19 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Database\\Console\\Seeds\\SeedCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Console/Seeds/SeedCommand.php', 'Illuminate\\Database\\Console\\Seeds\\SeederMakeCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Console/Seeds/SeederMakeCommand.php', 'Illuminate\\Database\\Console\\WipeCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Console/WipeCommand.php', + 'Illuminate\\Database\\DBAL\\TimestampType' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/DBAL/TimestampType.php', 'Illuminate\\Database\\DatabaseManager' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/DatabaseManager.php', 'Illuminate\\Database\\DatabaseServiceProvider' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/DatabaseServiceProvider.php', + 'Illuminate\\Database\\DatabaseTransactionRecord' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/DatabaseTransactionRecord.php', + 'Illuminate\\Database\\DatabaseTransactionsManager' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/DatabaseTransactionsManager.php', 'Illuminate\\Database\\DetectsConcurrencyErrors' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/DetectsConcurrencyErrors.php', 'Illuminate\\Database\\DetectsLostConnections' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/DetectsLostConnections.php', 'Illuminate\\Database\\Eloquent\\Builder' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Builder.php', + 'Illuminate\\Database\\Eloquent\\Casts\\ArrayObject' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Casts/ArrayObject.php', + 'Illuminate\\Database\\Eloquent\\Casts\\AsArrayObject' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsArrayObject.php', + 'Illuminate\\Database\\Eloquent\\Casts\\AsCollection' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsCollection.php', + 'Illuminate\\Database\\Eloquent\\Casts\\AsEncryptedArrayObject' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsEncryptedArrayObject.php', + 'Illuminate\\Database\\Eloquent\\Casts\\AsEncryptedCollection' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsEncryptedCollection.php', 'Illuminate\\Database\\Eloquent\\Collection' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Collection.php', 'Illuminate\\Database\\Eloquent\\Concerns\\GuardsAttributes' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/GuardsAttributes.php', 'Illuminate\\Database\\Eloquent\\Concerns\\HasAttributes' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HasAttributes.php', @@ -1939,9 +2006,14 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Database\\Eloquent\\Concerns\\HasTimestamps' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HasTimestamps.php', 'Illuminate\\Database\\Eloquent\\Concerns\\HidesAttributes' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HidesAttributes.php', 'Illuminate\\Database\\Eloquent\\Concerns\\QueriesRelationships' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/QueriesRelationships.php', - 'Illuminate\\Database\\Eloquent\\Factory' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Factory.php', - 'Illuminate\\Database\\Eloquent\\FactoryBuilder' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/FactoryBuilder.php', + 'Illuminate\\Database\\Eloquent\\Factories\\BelongsToManyRelationship' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Factories/BelongsToManyRelationship.php', + 'Illuminate\\Database\\Eloquent\\Factories\\BelongsToRelationship' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Factories/BelongsToRelationship.php', + 'Illuminate\\Database\\Eloquent\\Factories\\Factory' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Factories/Factory.php', + 'Illuminate\\Database\\Eloquent\\Factories\\HasFactory' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Factories/HasFactory.php', + 'Illuminate\\Database\\Eloquent\\Factories\\Relationship' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Factories/Relationship.php', + 'Illuminate\\Database\\Eloquent\\Factories\\Sequence' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Factories/Sequence.php', 'Illuminate\\Database\\Eloquent\\HigherOrderBuilderProxy' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/HigherOrderBuilderProxy.php', + 'Illuminate\\Database\\Eloquent\\InvalidCastException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/InvalidCastException.php', 'Illuminate\\Database\\Eloquent\\JsonEncodingException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/JsonEncodingException.php', 'Illuminate\\Database\\Eloquent\\MassAssignmentException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/MassAssignmentException.php', 'Illuminate\\Database\\Eloquent\\Model' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Model.php', @@ -1951,6 +2023,9 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Database\\Eloquent\\Relations\\BelongsTo' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Relations/BelongsTo.php', 'Illuminate\\Database\\Eloquent\\Relations\\BelongsToMany' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Relations/BelongsToMany.php', 'Illuminate\\Database\\Eloquent\\Relations\\Concerns\\AsPivot' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/AsPivot.php', + 'Illuminate\\Database\\Eloquent\\Relations\\Concerns\\CanBeOneOfMany' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/CanBeOneOfMany.php', + 'Illuminate\\Database\\Eloquent\\Relations\\Concerns\\ComparesRelatedModels' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/ComparesRelatedModels.php', + 'Illuminate\\Database\\Eloquent\\Relations\\Concerns\\InteractsWithDictionary' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/InteractsWithDictionary.php', 'Illuminate\\Database\\Eloquent\\Relations\\Concerns\\InteractsWithPivotTable' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/InteractsWithPivotTable.php', 'Illuminate\\Database\\Eloquent\\Relations\\Concerns\\SupportsDefaultModels' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/SupportsDefaultModels.php', 'Illuminate\\Database\\Eloquent\\Relations\\HasMany' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/Relations/HasMany.php', @@ -1970,6 +2045,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Database\\Eloquent\\SoftDeletes' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/SoftDeletes.php', 'Illuminate\\Database\\Eloquent\\SoftDeletingScope' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Eloquent/SoftDeletingScope.php', 'Illuminate\\Database\\Events\\ConnectionEvent' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Events/ConnectionEvent.php', + 'Illuminate\\Database\\Events\\DatabaseRefreshed' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Events/DatabaseRefreshed.php', 'Illuminate\\Database\\Events\\MigrationEnded' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Events/MigrationEnded.php', 'Illuminate\\Database\\Events\\MigrationEvent' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Events/MigrationEvent.php', 'Illuminate\\Database\\Events\\MigrationStarted' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Events/MigrationStarted.php', @@ -1977,18 +2053,29 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Database\\Events\\MigrationsStarted' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Events/MigrationsStarted.php', 'Illuminate\\Database\\Events\\NoPendingMigrations' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Events/NoPendingMigrations.php', 'Illuminate\\Database\\Events\\QueryExecuted' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Events/QueryExecuted.php', + 'Illuminate\\Database\\Events\\SchemaDumped' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Events/SchemaDumped.php', + 'Illuminate\\Database\\Events\\SchemaLoaded' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Events/SchemaLoaded.php', 'Illuminate\\Database\\Events\\StatementPrepared' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Events/StatementPrepared.php', 'Illuminate\\Database\\Events\\TransactionBeginning' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Events/TransactionBeginning.php', 'Illuminate\\Database\\Events\\TransactionCommitted' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Events/TransactionCommitted.php', 'Illuminate\\Database\\Events\\TransactionRolledBack' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Events/TransactionRolledBack.php', 'Illuminate\\Database\\Grammar' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Grammar.php', + 'Illuminate\\Database\\LazyLoadingViolationException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/LazyLoadingViolationException.php', 'Illuminate\\Database\\MigrationServiceProvider' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/MigrationServiceProvider.php', 'Illuminate\\Database\\Migrations\\DatabaseMigrationRepository' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Migrations/DatabaseMigrationRepository.php', 'Illuminate\\Database\\Migrations\\Migration' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Migrations/Migration.php', 'Illuminate\\Database\\Migrations\\MigrationCreator' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Migrations/MigrationCreator.php', 'Illuminate\\Database\\Migrations\\MigrationRepositoryInterface' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Migrations/MigrationRepositoryInterface.php', 'Illuminate\\Database\\Migrations\\Migrator' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Migrations/Migrator.php', + 'Illuminate\\Database\\MultipleRecordsFoundException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/MultipleRecordsFoundException.php', 'Illuminate\\Database\\MySqlConnection' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/MySqlConnection.php', + 'Illuminate\\Database\\PDO\\Concerns\\ConnectsToDatabase' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/PDO/Concerns/ConnectsToDatabase.php', + 'Illuminate\\Database\\PDO\\Connection' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/PDO/Connection.php', + 'Illuminate\\Database\\PDO\\MySqlDriver' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/PDO/MySqlDriver.php', + 'Illuminate\\Database\\PDO\\PostgresDriver' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/PDO/PostgresDriver.php', + 'Illuminate\\Database\\PDO\\SQLiteDriver' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/PDO/SQLiteDriver.php', + 'Illuminate\\Database\\PDO\\SqlServerConnection' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/PDO/SqlServerConnection.php', + 'Illuminate\\Database\\PDO\\SqlServerDriver' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/PDO/SqlServerDriver.php', 'Illuminate\\Database\\PostgresConnection' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/PostgresConnection.php', 'Illuminate\\Database\\QueryException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/QueryException.php', 'Illuminate\\Database\\Query\\Builder' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Query/Builder.php', @@ -2004,6 +2091,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Database\\Query\\Processors\\Processor' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Query/Processors/Processor.php', 'Illuminate\\Database\\Query\\Processors\\SQLiteProcessor' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Query/Processors/SQLiteProcessor.php', 'Illuminate\\Database\\Query\\Processors\\SqlServerProcessor' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Query/Processors/SqlServerProcessor.php', + 'Illuminate\\Database\\RecordsNotFoundException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/RecordsNotFoundException.php', 'Illuminate\\Database\\SQLiteConnection' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/SQLiteConnection.php', 'Illuminate\\Database\\Schema\\Blueprint' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Schema/Blueprint.php', 'Illuminate\\Database\\Schema\\Builder' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Schema/Builder.php', @@ -2018,28 +2106,37 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Database\\Schema\\Grammars\\SQLiteGrammar' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Schema/Grammars/SQLiteGrammar.php', 'Illuminate\\Database\\Schema\\Grammars\\SqlServerGrammar' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Schema/Grammars/SqlServerGrammar.php', 'Illuminate\\Database\\Schema\\MySqlBuilder' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Schema/MySqlBuilder.php', + 'Illuminate\\Database\\Schema\\MySqlSchemaState' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Schema/MySqlSchemaState.php', 'Illuminate\\Database\\Schema\\PostgresBuilder' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Schema/PostgresBuilder.php', + 'Illuminate\\Database\\Schema\\PostgresSchemaState' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Schema/PostgresSchemaState.php', 'Illuminate\\Database\\Schema\\SQLiteBuilder' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Schema/SQLiteBuilder.php', + 'Illuminate\\Database\\Schema\\SchemaState' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Schema/SchemaState.php', 'Illuminate\\Database\\Schema\\SqlServerBuilder' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Schema/SqlServerBuilder.php', + 'Illuminate\\Database\\Schema\\SqliteSchemaState' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Schema/SqliteSchemaState.php', 'Illuminate\\Database\\Seeder' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/Seeder.php', 'Illuminate\\Database\\SqlServerConnection' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Database/SqlServerConnection.php', 'Illuminate\\Encryption\\Encrypter' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Encryption/Encrypter.php', 'Illuminate\\Encryption\\EncryptionServiceProvider' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Encryption/EncryptionServiceProvider.php', + 'Illuminate\\Encryption\\MissingAppKeyException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Encryption/MissingAppKeyException.php', 'Illuminate\\Events\\CallQueuedListener' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Events/CallQueuedListener.php', 'Illuminate\\Events\\Dispatcher' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Events/Dispatcher.php', 'Illuminate\\Events\\EventServiceProvider' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Events/EventServiceProvider.php', + 'Illuminate\\Events\\InvokeQueuedClosure' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Events/InvokeQueuedClosure.php', 'Illuminate\\Events\\NullDispatcher' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Events/NullDispatcher.php', + 'Illuminate\\Events\\QueuedClosure' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Events/QueuedClosure.php', 'Illuminate\\Filesystem\\Cache' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Filesystem/Cache.php', 'Illuminate\\Filesystem\\Filesystem' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Filesystem/Filesystem.php', 'Illuminate\\Filesystem\\FilesystemAdapter' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Filesystem/FilesystemAdapter.php', 'Illuminate\\Filesystem\\FilesystemManager' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Filesystem/FilesystemManager.php', 'Illuminate\\Filesystem\\FilesystemServiceProvider' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Filesystem/FilesystemServiceProvider.php', + 'Illuminate\\Filesystem\\LockableFile' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Filesystem/LockableFile.php', 'Illuminate\\Foundation\\AliasLoader' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/AliasLoader.php', 'Illuminate\\Foundation\\Application' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Application.php', 'Illuminate\\Foundation\\Auth\\Access\\Authorizable' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Auth/Access/Authorizable.php', 'Illuminate\\Foundation\\Auth\\Access\\AuthorizesRequests' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Auth/Access/AuthorizesRequests.php', 'Illuminate\\Foundation\\Auth\\AuthenticatesUsers' => __DIR__ . '/..' . '/laravel/ui/auth-backend/AuthenticatesUsers.php', 'Illuminate\\Foundation\\Auth\\ConfirmsPasswords' => __DIR__ . '/..' . '/laravel/ui/auth-backend/ConfirmsPasswords.php', + 'Illuminate\\Foundation\\Auth\\EmailVerificationRequest' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Auth/EmailVerificationRequest.php', 'Illuminate\\Foundation\\Auth\\RedirectsUsers' => __DIR__ . '/..' . '/laravel/ui/auth-backend/RedirectsUsers.php', 'Illuminate\\Foundation\\Auth\\RegistersUsers' => __DIR__ . '/..' . '/laravel/ui/auth-backend/RegistersUsers.php', 'Illuminate\\Foundation\\Auth\\ResetsPasswords' => __DIR__ . '/..' . '/laravel/ui/auth-backend/ResetsPasswords.php', @@ -2057,6 +2154,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Foundation\\Bus\\Dispatchable' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Bus/Dispatchable.php', 'Illuminate\\Foundation\\Bus\\DispatchesJobs' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Bus/DispatchesJobs.php', 'Illuminate\\Foundation\\Bus\\PendingChain' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Bus/PendingChain.php', + 'Illuminate\\Foundation\\Bus\\PendingClosureDispatch' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Bus/PendingClosureDispatch.php', 'Illuminate\\Foundation\\Bus\\PendingDispatch' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Bus/PendingDispatch.php', 'Illuminate\\Foundation\\ComposerScripts' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/ComposerScripts.php', 'Illuminate\\Foundation\\Console\\CastMakeCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Console/CastMakeCommand.php', @@ -2107,14 +2205,19 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Foundation\\Events\\DiscoverEvents' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Events/DiscoverEvents.php', 'Illuminate\\Foundation\\Events\\Dispatchable' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Events/Dispatchable.php', 'Illuminate\\Foundation\\Events\\LocaleUpdated' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Events/LocaleUpdated.php', + 'Illuminate\\Foundation\\Events\\VendorTagPublished' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Events/VendorTagPublished.php', 'Illuminate\\Foundation\\Exceptions\\Handler' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Exceptions/Handler.php', + 'Illuminate\\Foundation\\Exceptions\\RegisterErrorViewPaths' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Exceptions/RegisterErrorViewPaths.php', + 'Illuminate\\Foundation\\Exceptions\\ReportableHandler' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Exceptions/ReportableHandler.php', 'Illuminate\\Foundation\\Exceptions\\WhoopsHandler' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Exceptions/WhoopsHandler.php', 'Illuminate\\Foundation\\Http\\Events\\RequestHandled' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Http/Events/RequestHandled.php', 'Illuminate\\Foundation\\Http\\Exceptions\\MaintenanceModeException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Http/Exceptions/MaintenanceModeException.php', 'Illuminate\\Foundation\\Http\\FormRequest' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Http/FormRequest.php', 'Illuminate\\Foundation\\Http\\Kernel' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php', + 'Illuminate\\Foundation\\Http\\MaintenanceModeBypassCookie' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Http/MaintenanceModeBypassCookie.php', 'Illuminate\\Foundation\\Http\\Middleware\\CheckForMaintenanceMode' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Http/Middleware/CheckForMaintenanceMode.php', 'Illuminate\\Foundation\\Http\\Middleware\\ConvertEmptyStringsToNull' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ConvertEmptyStringsToNull.php', + 'Illuminate\\Foundation\\Http\\Middleware\\PreventRequestsDuringMaintenance' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Http/Middleware/PreventRequestsDuringMaintenance.php', 'Illuminate\\Foundation\\Http\\Middleware\\TransformsRequest' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php', 'Illuminate\\Foundation\\Http\\Middleware\\TrimStrings' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TrimStrings.php', 'Illuminate\\Foundation\\Http\\Middleware\\ValidatePostSize' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ValidatePostSize.php', @@ -2138,6 +2241,8 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Foundation\\Testing\\Concerns\\InteractsWithExceptionHandling' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithExceptionHandling.php', 'Illuminate\\Foundation\\Testing\\Concerns\\InteractsWithRedis' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithRedis.php', 'Illuminate\\Foundation\\Testing\\Concerns\\InteractsWithSession' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithSession.php', + 'Illuminate\\Foundation\\Testing\\Concerns\\InteractsWithTime' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithTime.php', + 'Illuminate\\Foundation\\Testing\\Concerns\\InteractsWithViews' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithViews.php', 'Illuminate\\Foundation\\Testing\\Concerns\\MakesHttpRequests' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/MakesHttpRequests.php', 'Illuminate\\Foundation\\Testing\\Concerns\\MocksApplicationServices' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/MocksApplicationServices.php', 'Illuminate\\Foundation\\Testing\\DatabaseMigrations' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Testing/DatabaseMigrations.php', @@ -2148,6 +2253,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Foundation\\Testing\\WithFaker' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Testing/WithFaker.php', 'Illuminate\\Foundation\\Testing\\WithoutEvents' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Testing/WithoutEvents.php', 'Illuminate\\Foundation\\Testing\\WithoutMiddleware' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Testing/WithoutMiddleware.php', + 'Illuminate\\Foundation\\Testing\\Wormhole' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Testing/Wormhole.php', 'Illuminate\\Foundation\\Validation\\ValidatesRequests' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Foundation/Validation/ValidatesRequests.php', 'Illuminate\\Hashing\\AbstractHasher' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Hashing/AbstractHasher.php', 'Illuminate\\Hashing\\Argon2IdHasher' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Hashing/Argon2IdHasher.php', @@ -2159,6 +2265,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Http\\Client\\Factory' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Http/Client/Factory.php', 'Illuminate\\Http\\Client\\HttpClientException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Http/Client/HttpClientException.php', 'Illuminate\\Http\\Client\\PendingRequest' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Http/Client/PendingRequest.php', + 'Illuminate\\Http\\Client\\Pool' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Http/Client/Pool.php', 'Illuminate\\Http\\Client\\Request' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Http/Client/Request.php', 'Illuminate\\Http\\Client\\RequestException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Http/Client/RequestException.php', 'Illuminate\\Http\\Client\\Response' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Http/Client/Response.php', @@ -2239,9 +2346,14 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Notifications\\NotificationServiceProvider' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Notifications/NotificationServiceProvider.php', 'Illuminate\\Notifications\\RoutesNotifications' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Notifications/RoutesNotifications.php', 'Illuminate\\Notifications\\SendQueuedNotifications' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Notifications/SendQueuedNotifications.php', + 'Illuminate\\Pagination\\AbstractCursorPaginator' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Pagination/AbstractCursorPaginator.php', 'Illuminate\\Pagination\\AbstractPaginator' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Pagination/AbstractPaginator.php', + 'Illuminate\\Pagination\\Cursor' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Pagination/Cursor.php', + 'Illuminate\\Pagination\\CursorPaginationException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Pagination/CursorPaginationException.php', + 'Illuminate\\Pagination\\CursorPaginator' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Pagination/CursorPaginator.php', 'Illuminate\\Pagination\\LengthAwarePaginator' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Pagination/LengthAwarePaginator.php', 'Illuminate\\Pagination\\PaginationServiceProvider' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Pagination/PaginationServiceProvider.php', + 'Illuminate\\Pagination\\PaginationState' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Pagination/PaginationState.php', 'Illuminate\\Pagination\\Paginator' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Pagination/Paginator.php', 'Illuminate\\Pagination\\UrlWindow' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Pagination/UrlWindow.php', 'Illuminate\\Pipeline\\Hub' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Pipeline/Hub.php', @@ -2258,12 +2370,16 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Queue\\Connectors\\RedisConnector' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Connectors/RedisConnector.php', 'Illuminate\\Queue\\Connectors\\SqsConnector' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Connectors/SqsConnector.php', 'Illuminate\\Queue\\Connectors\\SyncConnector' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Connectors/SyncConnector.php', + 'Illuminate\\Queue\\Console\\BatchesTableCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Console/BatchesTableCommand.php', + 'Illuminate\\Queue\\Console\\ClearCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Console/ClearCommand.php', 'Illuminate\\Queue\\Console\\FailedTableCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Console/FailedTableCommand.php', 'Illuminate\\Queue\\Console\\FlushFailedCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Console/FlushFailedCommand.php', 'Illuminate\\Queue\\Console\\ForgetFailedCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Console/ForgetFailedCommand.php', 'Illuminate\\Queue\\Console\\ListFailedCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Console/ListFailedCommand.php', 'Illuminate\\Queue\\Console\\ListenCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Console/ListenCommand.php', + 'Illuminate\\Queue\\Console\\PruneBatchesCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Console/PruneBatchesCommand.php', 'Illuminate\\Queue\\Console\\RestartCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Console/RestartCommand.php', + 'Illuminate\\Queue\\Console\\RetryBatchCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Console/RetryBatchCommand.php', 'Illuminate\\Queue\\Console\\RetryCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Console/RetryCommand.php', 'Illuminate\\Queue\\Console\\TableCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Console/TableCommand.php', 'Illuminate\\Queue\\Console\\WorkCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Console/WorkCommand.php', @@ -2272,9 +2388,11 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Queue\\Events\\JobFailed' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Events/JobFailed.php', 'Illuminate\\Queue\\Events\\JobProcessed' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Events/JobProcessed.php', 'Illuminate\\Queue\\Events\\JobProcessing' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Events/JobProcessing.php', + 'Illuminate\\Queue\\Events\\JobQueued' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Events/JobQueued.php', 'Illuminate\\Queue\\Events\\Looping' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Events/Looping.php', 'Illuminate\\Queue\\Events\\WorkerStopping' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Events/WorkerStopping.php', 'Illuminate\\Queue\\Failed\\DatabaseFailedJobProvider' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Failed/DatabaseFailedJobProvider.php', + 'Illuminate\\Queue\\Failed\\DatabaseUuidFailedJobProvider' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Failed/DatabaseUuidFailedJobProvider.php', 'Illuminate\\Queue\\Failed\\DynamoDbFailedJobProvider' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Failed/DynamoDbFailedJobProvider.php', 'Illuminate\\Queue\\Failed\\FailedJobProviderInterface' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Failed/FailedJobProviderInterface.php', 'Illuminate\\Queue\\Failed\\NullFailedJobProvider' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Failed/NullFailedJobProvider.php', @@ -2293,6 +2411,11 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Queue\\LuaScripts' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/LuaScripts.php', 'Illuminate\\Queue\\ManuallyFailedException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/ManuallyFailedException.php', 'Illuminate\\Queue\\MaxAttemptsExceededException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/MaxAttemptsExceededException.php', + 'Illuminate\\Queue\\Middleware\\RateLimited' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Middleware/RateLimited.php', + 'Illuminate\\Queue\\Middleware\\RateLimitedWithRedis' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Middleware/RateLimitedWithRedis.php', + 'Illuminate\\Queue\\Middleware\\ThrottlesExceptions' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Middleware/ThrottlesExceptions.php', + 'Illuminate\\Queue\\Middleware\\ThrottlesExceptionsWithRedis' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Middleware/ThrottlesExceptionsWithRedis.php', + 'Illuminate\\Queue\\Middleware\\WithoutOverlapping' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Middleware/WithoutOverlapping.php', 'Illuminate\\Queue\\NullQueue' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/NullQueue.php', 'Illuminate\\Queue\\Queue' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/Queue.php', 'Illuminate\\Queue\\QueueManager' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Queue/QueueManager.php', @@ -2327,6 +2450,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Routing\\Controller' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Routing/Controller.php', 'Illuminate\\Routing\\ControllerDispatcher' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Routing/ControllerDispatcher.php', 'Illuminate\\Routing\\ControllerMiddlewareOptions' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Routing/ControllerMiddlewareOptions.php', + 'Illuminate\\Routing\\CreatesRegularExpressionRouteConstraints' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Routing/CreatesRegularExpressionRouteConstraints.php', 'Illuminate\\Routing\\Events\\RouteMatched' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Routing/Events/RouteMatched.php', 'Illuminate\\Routing\\Exceptions\\InvalidSignatureException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Routing/Exceptions/InvalidSignatureException.php', 'Illuminate\\Routing\\Exceptions\\UrlGenerationException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Routing/Exceptions/UrlGenerationException.php', @@ -2381,13 +2505,13 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Session\\Store' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Session/Store.php', 'Illuminate\\Session\\TokenMismatchException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Session/TokenMismatchException.php', 'Illuminate\\Support\\AggregateServiceProvider' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/AggregateServiceProvider.php', - 'Illuminate\\Support\\Arr' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Arr.php', + 'Illuminate\\Support\\Arr' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Collections/Arr.php', 'Illuminate\\Support\\Carbon' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Carbon.php', - 'Illuminate\\Support\\Collection' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Collection.php', + 'Illuminate\\Support\\Collection' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Collections/Collection.php', 'Illuminate\\Support\\Composer' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Composer.php', 'Illuminate\\Support\\ConfigurationUrlParser' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/ConfigurationUrlParser.php', 'Illuminate\\Support\\DateFactory' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/DateFactory.php', - 'Illuminate\\Support\\Enumerable' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Enumerable.php', + 'Illuminate\\Support\\Enumerable' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Collections/Enumerable.php', 'Illuminate\\Support\\Env' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Env.php', 'Illuminate\\Support\\Facades\\App' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Facades/App.php', 'Illuminate\\Support\\Facades\\Artisan' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Facades/Artisan.php', @@ -2411,8 +2535,10 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Support\\Facades\\Log' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Facades/Log.php', 'Illuminate\\Support\\Facades\\Mail' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Facades/Mail.php', 'Illuminate\\Support\\Facades\\Notification' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Facades/Notification.php', + 'Illuminate\\Support\\Facades\\ParallelTesting' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Facades/ParallelTesting.php', 'Illuminate\\Support\\Facades\\Password' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Facades/Password.php', 'Illuminate\\Support\\Facades\\Queue' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Facades/Queue.php', + 'Illuminate\\Support\\Facades\\RateLimiter' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Facades/RateLimiter.php', 'Illuminate\\Support\\Facades\\Redirect' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Facades/Redirect.php', 'Illuminate\\Support\\Facades\\Redis' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Facades/Redis.php', 'Illuminate\\Support\\Facades\\Request' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Facades/Request.php', @@ -2425,12 +2551,12 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Support\\Facades\\Validator' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Facades/Validator.php', 'Illuminate\\Support\\Facades\\View' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Facades/View.php', 'Illuminate\\Support\\Fluent' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Fluent.php', - 'Illuminate\\Support\\HigherOrderCollectionProxy' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/HigherOrderCollectionProxy.php', + 'Illuminate\\Support\\HigherOrderCollectionProxy' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Collections/HigherOrderCollectionProxy.php', 'Illuminate\\Support\\HigherOrderTapProxy' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/HigherOrderTapProxy.php', - 'Illuminate\\Support\\HigherOrderWhenProxy' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/HigherOrderWhenProxy.php', + 'Illuminate\\Support\\HigherOrderWhenProxy' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Collections/HigherOrderWhenProxy.php', 'Illuminate\\Support\\HtmlString' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/HtmlString.php', 'Illuminate\\Support\\InteractsWithTime' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/InteractsWithTime.php', - 'Illuminate\\Support\\LazyCollection' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/LazyCollection.php', + 'Illuminate\\Support\\LazyCollection' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Collections/LazyCollection.php', 'Illuminate\\Support\\Manager' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Manager.php', 'Illuminate\\Support\\MessageBag' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/MessageBag.php', 'Illuminate\\Support\\NamespacedItemResolver' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/NamespacedItemResolver.php', @@ -2441,28 +2567,43 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Support\\ServiceProvider' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/ServiceProvider.php', 'Illuminate\\Support\\Str' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Str.php', 'Illuminate\\Support\\Stringable' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Stringable.php', + 'Illuminate\\Support\\Testing\\Fakes\\BatchRepositoryFake' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Testing/Fakes/BatchRepositoryFake.php', 'Illuminate\\Support\\Testing\\Fakes\\BusFake' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Testing/Fakes/BusFake.php', 'Illuminate\\Support\\Testing\\Fakes\\EventFake' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Testing/Fakes/EventFake.php', 'Illuminate\\Support\\Testing\\Fakes\\MailFake' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Testing/Fakes/MailFake.php', 'Illuminate\\Support\\Testing\\Fakes\\NotificationFake' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Testing/Fakes/NotificationFake.php', + 'Illuminate\\Support\\Testing\\Fakes\\PendingBatchFake' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Testing/Fakes/PendingBatchFake.php', + 'Illuminate\\Support\\Testing\\Fakes\\PendingChainFake' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Testing/Fakes/PendingChainFake.php', 'Illuminate\\Support\\Testing\\Fakes\\PendingMailFake' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Testing/Fakes/PendingMailFake.php', 'Illuminate\\Support\\Testing\\Fakes\\QueueFake' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Testing/Fakes/QueueFake.php', 'Illuminate\\Support\\Traits\\CapsuleManagerTrait' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Traits/CapsuleManagerTrait.php', - 'Illuminate\\Support\\Traits\\EnumeratesValues' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Traits/EnumeratesValues.php', + 'Illuminate\\Support\\Traits\\EnumeratesValues' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Collections/Traits/EnumeratesValues.php', 'Illuminate\\Support\\Traits\\ForwardsCalls' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Traits/ForwardsCalls.php', 'Illuminate\\Support\\Traits\\Localizable' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Traits/Localizable.php', - 'Illuminate\\Support\\Traits\\Macroable' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Traits/Macroable.php', + 'Illuminate\\Support\\Traits\\Macroable' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Macroable/Traits/Macroable.php', 'Illuminate\\Support\\Traits\\ReflectsClosures' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Traits/ReflectsClosures.php', 'Illuminate\\Support\\Traits\\Tappable' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/Traits/Tappable.php', 'Illuminate\\Support\\ViewErrorBag' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Support/ViewErrorBag.php', 'Illuminate\\Testing\\Assert' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Testing/Assert.php', + 'Illuminate\\Testing\\AssertableJsonString' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Testing/AssertableJsonString.php', + 'Illuminate\\Testing\\Concerns\\TestDatabases' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Testing/Concerns/TestDatabases.php', 'Illuminate\\Testing\\Constraints\\ArraySubset' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Testing/Constraints/ArraySubset.php', 'Illuminate\\Testing\\Constraints\\CountInDatabase' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Testing/Constraints/CountInDatabase.php', 'Illuminate\\Testing\\Constraints\\HasInDatabase' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Testing/Constraints/HasInDatabase.php', 'Illuminate\\Testing\\Constraints\\SeeInOrder' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Testing/Constraints/SeeInOrder.php', 'Illuminate\\Testing\\Constraints\\SoftDeletedInDatabase' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Testing/Constraints/SoftDeletedInDatabase.php', + 'Illuminate\\Testing\\Fluent\\AssertableJson' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Testing/Fluent/AssertableJson.php', + 'Illuminate\\Testing\\Fluent\\Concerns\\Debugging' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Testing/Fluent/Concerns/Debugging.php', + 'Illuminate\\Testing\\Fluent\\Concerns\\Has' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Testing/Fluent/Concerns/Has.php', + 'Illuminate\\Testing\\Fluent\\Concerns\\Interaction' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Testing/Fluent/Concerns/Interaction.php', + 'Illuminate\\Testing\\Fluent\\Concerns\\Matching' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Testing/Fluent/Concerns/Matching.php', + 'Illuminate\\Testing\\ParallelConsoleOutput' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Testing/ParallelConsoleOutput.php', + 'Illuminate\\Testing\\ParallelRunner' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Testing/ParallelRunner.php', + 'Illuminate\\Testing\\ParallelTesting' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Testing/ParallelTesting.php', + 'Illuminate\\Testing\\ParallelTestingServiceProvider' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Testing/ParallelTestingServiceProvider.php', 'Illuminate\\Testing\\PendingCommand' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Testing/PendingCommand.php', 'Illuminate\\Testing\\TestResponse' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Testing/TestResponse.php', + 'Illuminate\\Testing\\TestView' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Testing/TestView.php', 'Illuminate\\Translation\\ArrayLoader' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Translation/ArrayLoader.php', 'Illuminate\\Translation\\FileLoader' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Translation/FileLoader.php', 'Illuminate\\Translation\\MessageSelector' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Translation/MessageSelector.php', @@ -2476,6 +2617,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Validation\\DatabasePresenceVerifier' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Validation/DatabasePresenceVerifier.php', 'Illuminate\\Validation\\DatabasePresenceVerifierInterface' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Validation/DatabasePresenceVerifierInterface.php', 'Illuminate\\Validation\\Factory' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Validation/Factory.php', + 'Illuminate\\Validation\\NotPwnedVerifier' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Validation/NotPwnedVerifier.php', 'Illuminate\\Validation\\PresenceVerifierInterface' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Validation/PresenceVerifierInterface.php', 'Illuminate\\Validation\\Rule' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Validation/Rule.php', 'Illuminate\\Validation\\Rules\\DatabaseRule' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Validation/Rules/DatabaseRule.php', @@ -2483,6 +2625,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Validation\\Rules\\Exists' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Validation/Rules/Exists.php', 'Illuminate\\Validation\\Rules\\In' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Validation/Rules/In.php', 'Illuminate\\Validation\\Rules\\NotIn' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Validation/Rules/NotIn.php', + 'Illuminate\\Validation\\Rules\\Password' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Validation/Rules/Password.php', 'Illuminate\\Validation\\Rules\\RequiredIf' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Validation/Rules/RequiredIf.php', 'Illuminate\\Validation\\Rules\\Unique' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Validation/Rules/Unique.php', 'Illuminate\\Validation\\UnauthorizedException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Validation/UnauthorizedException.php', @@ -2493,6 +2636,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\Validation\\ValidationServiceProvider' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Validation/ValidationServiceProvider.php', 'Illuminate\\Validation\\Validator' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/Validation/Validator.php', 'Illuminate\\View\\AnonymousComponent' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/View/AnonymousComponent.php', + 'Illuminate\\View\\AppendableAttributeValue' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/View/AppendableAttributeValue.php', 'Illuminate\\View\\Compilers\\BladeCompiler' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/View/Compilers/BladeCompiler.php', 'Illuminate\\View\\Compilers\\Compiler' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/View/Compilers/Compiler.php', 'Illuminate\\View\\Compilers\\CompilerInterface' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/View/Compilers/CompilerInterface.php', @@ -2520,6 +2664,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\View\\Concerns\\ManagesLoops' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/View/Concerns/ManagesLoops.php', 'Illuminate\\View\\Concerns\\ManagesStacks' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/View/Concerns/ManagesStacks.php', 'Illuminate\\View\\Concerns\\ManagesTranslations' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/View/Concerns/ManagesTranslations.php', + 'Illuminate\\View\\DynamicComponent' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/View/DynamicComponent.php', 'Illuminate\\View\\Engines\\CompilerEngine' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/View/Engines/CompilerEngine.php', 'Illuminate\\View\\Engines\\Engine' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/View/Engines/Engine.php', 'Illuminate\\View\\Engines\\EngineResolver' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/View/Engines/EngineResolver.php', @@ -2530,6 +2675,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Illuminate\\View\\InvokableComponentVariable' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/View/InvokableComponentVariable.php', 'Illuminate\\View\\Middleware\\ShareErrorsFromSession' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/View/Middleware/ShareErrorsFromSession.php', 'Illuminate\\View\\View' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/View/View.php', + 'Illuminate\\View\\ViewException' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/View/ViewException.php', 'Illuminate\\View\\ViewFinderInterface' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/View/ViewFinderInterface.php', 'Illuminate\\View\\ViewName' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/View/ViewName.php', 'Illuminate\\View\\ViewServiceProvider' => __DIR__ . '/..' . '/laravel/framework/src/Illuminate/View/ViewServiceProvider.php', @@ -2781,11 +2927,15 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Laravel\\Horizon\\AutoScaler' => __DIR__ . '/..' . '/laravel/horizon/src/AutoScaler.php', 'Laravel\\Horizon\\BackgroundProcess' => __DIR__ . '/..' . '/laravel/horizon/src/BackgroundProcess.php', 'Laravel\\Horizon\\Connectors\\RedisConnector' => __DIR__ . '/..' . '/laravel/horizon/src/Connectors/RedisConnector.php', + 'Laravel\\Horizon\\Console\\ClearCommand' => __DIR__ . '/..' . '/laravel/horizon/src/Console/ClearCommand.php', 'Laravel\\Horizon\\Console\\ContinueCommand' => __DIR__ . '/..' . '/laravel/horizon/src/Console/ContinueCommand.php', + 'Laravel\\Horizon\\Console\\ContinueSupervisorCommand' => __DIR__ . '/..' . '/laravel/horizon/src/Console/ContinueSupervisorCommand.php', + 'Laravel\\Horizon\\Console\\ForgetFailedCommand' => __DIR__ . '/..' . '/laravel/horizon/src/Console/ForgetFailedCommand.php', 'Laravel\\Horizon\\Console\\HorizonCommand' => __DIR__ . '/..' . '/laravel/horizon/src/Console/HorizonCommand.php', 'Laravel\\Horizon\\Console\\InstallCommand' => __DIR__ . '/..' . '/laravel/horizon/src/Console/InstallCommand.php', 'Laravel\\Horizon\\Console\\ListCommand' => __DIR__ . '/..' . '/laravel/horizon/src/Console/ListCommand.php', 'Laravel\\Horizon\\Console\\PauseCommand' => __DIR__ . '/..' . '/laravel/horizon/src/Console/PauseCommand.php', + 'Laravel\\Horizon\\Console\\PauseSupervisorCommand' => __DIR__ . '/..' . '/laravel/horizon/src/Console/PauseSupervisorCommand.php', 'Laravel\\Horizon\\Console\\PublishCommand' => __DIR__ . '/..' . '/laravel/horizon/src/Console/PublishCommand.php', 'Laravel\\Horizon\\Console\\PurgeCommand' => __DIR__ . '/..' . '/laravel/horizon/src/Console/PurgeCommand.php', 'Laravel\\Horizon\\Console\\SnapshotCommand' => __DIR__ . '/..' . '/laravel/horizon/src/Console/SnapshotCommand.php', @@ -2826,6 +2976,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Laravel\\Horizon\\Horizon' => __DIR__ . '/..' . '/laravel/horizon/src/Horizon.php', 'Laravel\\Horizon\\HorizonApplicationServiceProvider' => __DIR__ . '/..' . '/laravel/horizon/src/HorizonApplicationServiceProvider.php', 'Laravel\\Horizon\\HorizonServiceProvider' => __DIR__ . '/..' . '/laravel/horizon/src/HorizonServiceProvider.php', + 'Laravel\\Horizon\\Http\\Controllers\\BatchesController' => __DIR__ . '/..' . '/laravel/horizon/src/Http/Controllers/BatchesController.php', 'Laravel\\Horizon\\Http\\Controllers\\CompletedJobsController' => __DIR__ . '/..' . '/laravel/horizon/src/Http/Controllers/CompletedJobsController.php', 'Laravel\\Horizon\\Http\\Controllers\\Controller' => __DIR__ . '/..' . '/laravel/horizon/src/Http/Controllers/Controller.php', 'Laravel\\Horizon\\Http\\Controllers\\DashboardStatsController' => __DIR__ . '/..' . '/laravel/horizon/src/Http/Controllers/DashboardStatsController.php', @@ -2840,7 +2991,6 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Laravel\\Horizon\\Http\\Controllers\\RetryController' => __DIR__ . '/..' . '/laravel/horizon/src/Http/Controllers/RetryController.php', 'Laravel\\Horizon\\Http\\Controllers\\WorkloadController' => __DIR__ . '/..' . '/laravel/horizon/src/Http/Controllers/WorkloadController.php', 'Laravel\\Horizon\\Http\\Middleware\\Authenticate' => __DIR__ . '/..' . '/laravel/horizon/src/Http/Middleware/Authenticate.php', - 'Laravel\\Horizon\\JobId' => __DIR__ . '/..' . '/laravel/horizon/src/JobId.php', 'Laravel\\Horizon\\JobPayload' => __DIR__ . '/..' . '/laravel/horizon/src/JobPayload.php', 'Laravel\\Horizon\\Jobs\\MonitorTag' => __DIR__ . '/..' . '/laravel/horizon/src/Jobs/MonitorTag.php', 'Laravel\\Horizon\\Jobs\\RetryFailedJob' => __DIR__ . '/..' . '/laravel/horizon/src/Jobs/RetryFailedJob.php', @@ -3223,6 +3373,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'League\\OAuth1\\Client\\Signature\\RsaSha1Signature' => __DIR__ . '/..' . '/league/oauth1-client/src/Signature/RsaSha1Signature.php', 'League\\OAuth1\\Client\\Signature\\Signature' => __DIR__ . '/..' . '/league/oauth1-client/src/Signature/Signature.php', 'League\\OAuth1\\Client\\Signature\\SignatureInterface' => __DIR__ . '/..' . '/league/oauth1-client/src/Signature/SignatureInterface.php', + 'Lorisleiva\\CronTranslator\\CronExpression' => __DIR__ . '/..' . '/lorisleiva/cron-translator/src/CronExpression.php', 'Lorisleiva\\CronTranslator\\CronParsingException' => __DIR__ . '/..' . '/lorisleiva/cron-translator/src/CronParsingException.php', 'Lorisleiva\\CronTranslator\\CronTranslator' => __DIR__ . '/..' . '/lorisleiva/cron-translator/src/CronTranslator.php', 'Lorisleiva\\CronTranslator\\CronType' => __DIR__ . '/..' . '/lorisleiva/cron-translator/src/CronType.php', @@ -3232,6 +3383,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Lorisleiva\\CronTranslator\\HoursField' => __DIR__ . '/..' . '/lorisleiva/cron-translator/src/HoursField.php', 'Lorisleiva\\CronTranslator\\MinutesField' => __DIR__ . '/..' . '/lorisleiva/cron-translator/src/MinutesField.php', 'Lorisleiva\\CronTranslator\\MonthsField' => __DIR__ . '/..' . '/lorisleiva/cron-translator/src/MonthsField.php', + 'Lorisleiva\\CronTranslator\\TranslationFileMissingException' => __DIR__ . '/..' . '/lorisleiva/cron-translator/src/TranslationFileMissingException.php', 'Mockery' => __DIR__ . '/..' . '/mockery/mockery/library/Mockery.php', 'Mockery\\Adapter\\Phpunit\\MockeryPHPUnitIntegration' => __DIR__ . '/..' . '/mockery/mockery/library/Mockery/Adapter/Phpunit/MockeryPHPUnitIntegration.php', 'Mockery\\Adapter\\Phpunit\\MockeryPHPUnitIntegrationAssertPostConditions' => __DIR__ . '/..' . '/mockery/mockery/library/Mockery/Adapter/Phpunit/MockeryPHPUnitIntegrationAssertPostConditions.php', @@ -3436,11 +3588,11 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'NunoMaduro\\Collision\\Adapters\\Laravel\\CollisionServiceProvider' => __DIR__ . '/..' . '/nunomaduro/collision/src/Adapters/Laravel/CollisionServiceProvider.php', 'NunoMaduro\\Collision\\Adapters\\Laravel\\Commands\\TestCommand' => __DIR__ . '/..' . '/nunomaduro/collision/src/Adapters/Laravel/Commands/TestCommand.php', 'NunoMaduro\\Collision\\Adapters\\Laravel\\ExceptionHandler' => __DIR__ . '/..' . '/nunomaduro/collision/src/Adapters/Laravel/ExceptionHandler.php', + 'NunoMaduro\\Collision\\Adapters\\Laravel\\Exceptions\\RequirementsException' => __DIR__ . '/..' . '/nunomaduro/collision/src/Adapters/Laravel/Exceptions/RequirementsException.php', 'NunoMaduro\\Collision\\Adapters\\Laravel\\IgnitionSolutionsRepository' => __DIR__ . '/..' . '/nunomaduro/collision/src/Adapters/Laravel/IgnitionSolutionsRepository.php', 'NunoMaduro\\Collision\\Adapters\\Laravel\\Inspector' => __DIR__ . '/..' . '/nunomaduro/collision/src/Adapters/Laravel/Inspector.php', 'NunoMaduro\\Collision\\Adapters\\Phpunit\\ConfigureIO' => __DIR__ . '/..' . '/nunomaduro/collision/src/Adapters/Phpunit/ConfigureIO.php', 'NunoMaduro\\Collision\\Adapters\\Phpunit\\Printer' => __DIR__ . '/..' . '/nunomaduro/collision/src/Adapters/Phpunit/Printer.php', - 'NunoMaduro\\Collision\\Adapters\\Phpunit\\PrinterContents' => __DIR__ . '/..' . '/nunomaduro/collision/src/Adapters/Phpunit/PrinterContents.php', 'NunoMaduro\\Collision\\Adapters\\Phpunit\\State' => __DIR__ . '/..' . '/nunomaduro/collision/src/Adapters/Phpunit/State.php', 'NunoMaduro\\Collision\\Adapters\\Phpunit\\Style' => __DIR__ . '/..' . '/nunomaduro/collision/src/Adapters/Phpunit/Style.php', 'NunoMaduro\\Collision\\Adapters\\Phpunit\\TestResult' => __DIR__ . '/..' . '/nunomaduro/collision/src/Adapters/Phpunit/TestResult.php', @@ -3453,8 +3605,11 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'NunoMaduro\\Collision\\Contracts\\Handler' => __DIR__ . '/..' . '/nunomaduro/collision/src/Contracts/Handler.php', 'NunoMaduro\\Collision\\Contracts\\Highlighter' => __DIR__ . '/..' . '/nunomaduro/collision/src/Contracts/Highlighter.php', 'NunoMaduro\\Collision\\Contracts\\Provider' => __DIR__ . '/..' . '/nunomaduro/collision/src/Contracts/Provider.php', + 'NunoMaduro\\Collision\\Contracts\\RenderlessEditor' => __DIR__ . '/..' . '/nunomaduro/collision/src/Contracts/RenderlessEditor.php', + 'NunoMaduro\\Collision\\Contracts\\RenderlessTrace' => __DIR__ . '/..' . '/nunomaduro/collision/src/Contracts/RenderlessTrace.php', 'NunoMaduro\\Collision\\Contracts\\SolutionsRepository' => __DIR__ . '/..' . '/nunomaduro/collision/src/Contracts/SolutionsRepository.php', 'NunoMaduro\\Collision\\Contracts\\Writer' => __DIR__ . '/..' . '/nunomaduro/collision/src/Contracts/Writer.php', + 'NunoMaduro\\Collision\\Exceptions\\InvalidStyleException' => __DIR__ . '/..' . '/nunomaduro/collision/src/Exceptions/InvalidStyleException.php', 'NunoMaduro\\Collision\\Exceptions\\ShouldNotHappen' => __DIR__ . '/..' . '/nunomaduro/collision/src/Exceptions/ShouldNotHappen.php', 'NunoMaduro\\Collision\\Handler' => __DIR__ . '/..' . '/nunomaduro/collision/src/Handler.php', 'NunoMaduro\\Collision\\Highlighter' => __DIR__ . '/..' . '/nunomaduro/collision/src/Highlighter.php', @@ -3473,66 +3628,79 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Opis\\Closure\\SerializableClosure' => __DIR__ . '/..' . '/opis/closure/src/SerializableClosure.php', 'OrePricesSeeder' => __DIR__ . '/../..' . '/database/seeds/OrePricesSeeder.php', 'PHPUnit\\Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/Exception.php', + 'PHPUnit\\Framework\\ActualValueIsNotAnObjectException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/ActualValueIsNotAnObjectException.php', 'PHPUnit\\Framework\\Assert' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Assert.php', 'PHPUnit\\Framework\\AssertionFailedError' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/AssertionFailedError.php', 'PHPUnit\\Framework\\CodeCoverageException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/CodeCoverageException.php', - 'PHPUnit\\Framework\\Constraint\\ArrayHasKey' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/ArrayHasKey.php', - 'PHPUnit\\Framework\\Constraint\\ArraySubset' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/ArraySubset.php', - 'PHPUnit\\Framework\\Constraint\\Attribute' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Attribute.php', + 'PHPUnit\\Framework\\ComparisonMethodDoesNotAcceptParameterTypeException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotAcceptParameterTypeException.php', + 'PHPUnit\\Framework\\ComparisonMethodDoesNotDeclareBoolReturnTypeException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotDeclareBoolReturnTypeException.php', + 'PHPUnit\\Framework\\ComparisonMethodDoesNotDeclareExactlyOneParameterException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotDeclareExactlyOneParameterException.php', + 'PHPUnit\\Framework\\ComparisonMethodDoesNotDeclareParameterTypeException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotDeclareParameterTypeException.php', + 'PHPUnit\\Framework\\ComparisonMethodDoesNotExistException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotExistException.php', + 'PHPUnit\\Framework\\Constraint\\ArrayHasKey' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Traversable/ArrayHasKey.php', + 'PHPUnit\\Framework\\Constraint\\BinaryOperator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Operator/BinaryOperator.php', 'PHPUnit\\Framework\\Constraint\\Callback' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Callback.php', - 'PHPUnit\\Framework\\Constraint\\ClassHasAttribute' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/ClassHasAttribute.php', - 'PHPUnit\\Framework\\Constraint\\ClassHasStaticAttribute' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/ClassHasStaticAttribute.php', - 'PHPUnit\\Framework\\Constraint\\Composite' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Composite.php', + 'PHPUnit\\Framework\\Constraint\\ClassHasAttribute' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Object/ClassHasAttribute.php', + 'PHPUnit\\Framework\\Constraint\\ClassHasStaticAttribute' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Object/ClassHasStaticAttribute.php', 'PHPUnit\\Framework\\Constraint\\Constraint' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Constraint.php', - 'PHPUnit\\Framework\\Constraint\\Count' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Count.php', - 'PHPUnit\\Framework\\Constraint\\DirectoryExists' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/DirectoryExists.php', - 'PHPUnit\\Framework\\Constraint\\Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Exception.php', - 'PHPUnit\\Framework\\Constraint\\ExceptionCode' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/ExceptionCode.php', - 'PHPUnit\\Framework\\Constraint\\ExceptionMessage' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/ExceptionMessage.php', - 'PHPUnit\\Framework\\Constraint\\ExceptionMessageRegularExpression' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/ExceptionMessageRegularExpression.php', - 'PHPUnit\\Framework\\Constraint\\FileExists' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/FileExists.php', - 'PHPUnit\\Framework\\Constraint\\GreaterThan' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/GreaterThan.php', + 'PHPUnit\\Framework\\Constraint\\Count' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Cardinality/Count.php', + 'PHPUnit\\Framework\\Constraint\\DirectoryExists' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Filesystem/DirectoryExists.php', + 'PHPUnit\\Framework\\Constraint\\Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Exception/Exception.php', + 'PHPUnit\\Framework\\Constraint\\ExceptionCode' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionCode.php', + 'PHPUnit\\Framework\\Constraint\\ExceptionMessage' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionMessage.php', + 'PHPUnit\\Framework\\Constraint\\ExceptionMessageRegularExpression' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionMessageRegularExpression.php', + 'PHPUnit\\Framework\\Constraint\\FileExists' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Filesystem/FileExists.php', + 'PHPUnit\\Framework\\Constraint\\GreaterThan' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Cardinality/GreaterThan.php', 'PHPUnit\\Framework\\Constraint\\IsAnything' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsAnything.php', - 'PHPUnit\\Framework\\Constraint\\IsEmpty' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsEmpty.php', - 'PHPUnit\\Framework\\Constraint\\IsEqual' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsEqual.php', - 'PHPUnit\\Framework\\Constraint\\IsFalse' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsFalse.php', - 'PHPUnit\\Framework\\Constraint\\IsFinite' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsFinite.php', + 'PHPUnit\\Framework\\Constraint\\IsEmpty' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Cardinality/IsEmpty.php', + 'PHPUnit\\Framework\\Constraint\\IsEqual' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqual.php', + 'PHPUnit\\Framework\\Constraint\\IsEqualCanonicalizing' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualCanonicalizing.php', + 'PHPUnit\\Framework\\Constraint\\IsEqualIgnoringCase' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualIgnoringCase.php', + 'PHPUnit\\Framework\\Constraint\\IsEqualWithDelta' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualWithDelta.php', + 'PHPUnit\\Framework\\Constraint\\IsFalse' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Boolean/IsFalse.php', + 'PHPUnit\\Framework\\Constraint\\IsFinite' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Math/IsFinite.php', 'PHPUnit\\Framework\\Constraint\\IsIdentical' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsIdentical.php', - 'PHPUnit\\Framework\\Constraint\\IsInfinite' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsInfinite.php', - 'PHPUnit\\Framework\\Constraint\\IsInstanceOf' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsInstanceOf.php', - 'PHPUnit\\Framework\\Constraint\\IsJson' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsJson.php', - 'PHPUnit\\Framework\\Constraint\\IsNan' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsNan.php', - 'PHPUnit\\Framework\\Constraint\\IsNull' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsNull.php', - 'PHPUnit\\Framework\\Constraint\\IsReadable' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsReadable.php', - 'PHPUnit\\Framework\\Constraint\\IsTrue' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsTrue.php', - 'PHPUnit\\Framework\\Constraint\\IsType' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsType.php', - 'PHPUnit\\Framework\\Constraint\\IsWritable' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsWritable.php', + 'PHPUnit\\Framework\\Constraint\\IsInfinite' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Math/IsInfinite.php', + 'PHPUnit\\Framework\\Constraint\\IsInstanceOf' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Type/IsInstanceOf.php', + 'PHPUnit\\Framework\\Constraint\\IsJson' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/String/IsJson.php', + 'PHPUnit\\Framework\\Constraint\\IsNan' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Math/IsNan.php', + 'PHPUnit\\Framework\\Constraint\\IsNull' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Type/IsNull.php', + 'PHPUnit\\Framework\\Constraint\\IsReadable' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Filesystem/IsReadable.php', + 'PHPUnit\\Framework\\Constraint\\IsTrue' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Boolean/IsTrue.php', + 'PHPUnit\\Framework\\Constraint\\IsType' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Type/IsType.php', + 'PHPUnit\\Framework\\Constraint\\IsWritable' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Filesystem/IsWritable.php', 'PHPUnit\\Framework\\Constraint\\JsonMatches' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/JsonMatches.php', 'PHPUnit\\Framework\\Constraint\\JsonMatchesErrorMessageProvider' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/JsonMatchesErrorMessageProvider.php', - 'PHPUnit\\Framework\\Constraint\\LessThan' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/LessThan.php', - 'PHPUnit\\Framework\\Constraint\\LogicalAnd' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/LogicalAnd.php', - 'PHPUnit\\Framework\\Constraint\\LogicalNot' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/LogicalNot.php', - 'PHPUnit\\Framework\\Constraint\\LogicalOr' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/LogicalOr.php', - 'PHPUnit\\Framework\\Constraint\\LogicalXor' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/LogicalXor.php', - 'PHPUnit\\Framework\\Constraint\\ObjectHasAttribute' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/ObjectHasAttribute.php', - 'PHPUnit\\Framework\\Constraint\\RegularExpression' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/RegularExpression.php', - 'PHPUnit\\Framework\\Constraint\\SameSize' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/SameSize.php', - 'PHPUnit\\Framework\\Constraint\\StringContains' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/StringContains.php', - 'PHPUnit\\Framework\\Constraint\\StringEndsWith' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/StringEndsWith.php', - 'PHPUnit\\Framework\\Constraint\\StringMatchesFormatDescription' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/StringMatchesFormatDescription.php', - 'PHPUnit\\Framework\\Constraint\\StringStartsWith' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/StringStartsWith.php', - 'PHPUnit\\Framework\\Constraint\\TraversableContains' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/TraversableContains.php', - 'PHPUnit\\Framework\\Constraint\\TraversableContainsEqual' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/TraversableContainsEqual.php', - 'PHPUnit\\Framework\\Constraint\\TraversableContainsIdentical' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/TraversableContainsIdentical.php', - 'PHPUnit\\Framework\\Constraint\\TraversableContainsOnly' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/TraversableContainsOnly.php', + 'PHPUnit\\Framework\\Constraint\\LessThan' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Cardinality/LessThan.php', + 'PHPUnit\\Framework\\Constraint\\LogicalAnd' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalAnd.php', + 'PHPUnit\\Framework\\Constraint\\LogicalNot' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalNot.php', + 'PHPUnit\\Framework\\Constraint\\LogicalOr' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalOr.php', + 'PHPUnit\\Framework\\Constraint\\LogicalXor' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalXor.php', + 'PHPUnit\\Framework\\Constraint\\ObjectEquals' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Object/ObjectEquals.php', + 'PHPUnit\\Framework\\Constraint\\ObjectHasAttribute' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Object/ObjectHasAttribute.php', + 'PHPUnit\\Framework\\Constraint\\Operator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Operator/Operator.php', + 'PHPUnit\\Framework\\Constraint\\RegularExpression' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/String/RegularExpression.php', + 'PHPUnit\\Framework\\Constraint\\SameSize' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Cardinality/SameSize.php', + 'PHPUnit\\Framework\\Constraint\\StringContains' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/String/StringContains.php', + 'PHPUnit\\Framework\\Constraint\\StringEndsWith' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/String/StringEndsWith.php', + 'PHPUnit\\Framework\\Constraint\\StringMatchesFormatDescription' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/String/StringMatchesFormatDescription.php', + 'PHPUnit\\Framework\\Constraint\\StringStartsWith' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/String/StringStartsWith.php', + 'PHPUnit\\Framework\\Constraint\\TraversableContains' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContains.php', + 'PHPUnit\\Framework\\Constraint\\TraversableContainsEqual' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContainsEqual.php', + 'PHPUnit\\Framework\\Constraint\\TraversableContainsIdentical' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContainsIdentical.php', + 'PHPUnit\\Framework\\Constraint\\TraversableContainsOnly' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContainsOnly.php', + 'PHPUnit\\Framework\\Constraint\\UnaryOperator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Operator/UnaryOperator.php', 'PHPUnit\\Framework\\CoveredCodeNotExecutedException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/CoveredCodeNotExecutedException.php', 'PHPUnit\\Framework\\DataProviderTestSuite' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/DataProviderTestSuite.php', + 'PHPUnit\\Framework\\Error' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/Error.php', + 'PHPUnit\\Framework\\ErrorTestCase' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/ErrorTestCase.php', 'PHPUnit\\Framework\\Error\\Deprecated' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Error/Deprecated.php', 'PHPUnit\\Framework\\Error\\Error' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Error/Error.php', 'PHPUnit\\Framework\\Error\\Notice' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Error/Notice.php', 'PHPUnit\\Framework\\Error\\Warning' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Error/Warning.php', 'PHPUnit\\Framework\\Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/Exception.php', 'PHPUnit\\Framework\\ExceptionWrapper' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/ExceptionWrapper.php', + 'PHPUnit\\Framework\\ExecutionOrderDependency' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/ExecutionOrderDependency.php', 'PHPUnit\\Framework\\ExpectationFailedException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/ExpectationFailedException.php', 'PHPUnit\\Framework\\IncompleteTest' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/IncompleteTest.php', 'PHPUnit\\Framework\\IncompleteTestCase' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/IncompleteTestCase.php', @@ -3547,20 +3715,31 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'PHPUnit\\Framework\\MockObject\\Builder\\Identity' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Builder/Identity.php', 'PHPUnit\\Framework\\MockObject\\Builder\\InvocationMocker' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Builder/InvocationMocker.php', 'PHPUnit\\Framework\\MockObject\\Builder\\InvocationStubber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Builder/InvocationStubber.php', - 'PHPUnit\\Framework\\MockObject\\Builder\\Match_' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Builder/Match_.php', 'PHPUnit\\Framework\\MockObject\\Builder\\MethodNameMatch' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Builder/MethodNameMatch.php', 'PHPUnit\\Framework\\MockObject\\Builder\\ParametersMatch' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Builder/ParametersMatch.php', 'PHPUnit\\Framework\\MockObject\\Builder\\Stub' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Builder/Stub.php', + 'PHPUnit\\Framework\\MockObject\\CannotUseAddMethodsException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/CannotUseAddMethodsException.php', + 'PHPUnit\\Framework\\MockObject\\CannotUseOnlyMethodsException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/CannotUseOnlyMethodsException.php', + 'PHPUnit\\Framework\\MockObject\\ClassAlreadyExistsException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/ClassAlreadyExistsException.php', + 'PHPUnit\\Framework\\MockObject\\ClassIsFinalException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsFinalException.php', 'PHPUnit\\Framework\\MockObject\\ConfigurableMethod' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/ConfigurableMethod.php', 'PHPUnit\\Framework\\MockObject\\ConfigurableMethodsAlreadyInitializedException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/ConfigurableMethodsAlreadyInitializedException.php', + 'PHPUnit\\Framework\\MockObject\\DuplicateMethodException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/DuplicateMethodException.php', 'PHPUnit\\Framework\\MockObject\\Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/Exception.php', 'PHPUnit\\Framework\\MockObject\\Generator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator.php', 'PHPUnit\\Framework\\MockObject\\IncompatibleReturnValueException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/IncompatibleReturnValueException.php', + 'PHPUnit\\Framework\\MockObject\\InvalidMethodNameException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/InvalidMethodNameException.php', 'PHPUnit\\Framework\\MockObject\\Invocation' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Invocation.php', 'PHPUnit\\Framework\\MockObject\\InvocationHandler' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/InvocationHandler.php', + 'PHPUnit\\Framework\\MockObject\\MatchBuilderNotFoundException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/MatchBuilderNotFoundException.php', 'PHPUnit\\Framework\\MockObject\\Matcher' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Matcher.php', + 'PHPUnit\\Framework\\MockObject\\MatcherAlreadyRegisteredException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/MatcherAlreadyRegisteredException.php', 'PHPUnit\\Framework\\MockObject\\Method' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Api/Method.php', + 'PHPUnit\\Framework\\MockObject\\MethodCannotBeConfiguredException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/MethodCannotBeConfiguredException.php', + 'PHPUnit\\Framework\\MockObject\\MethodNameAlreadyConfiguredException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/MethodNameAlreadyConfiguredException.php', 'PHPUnit\\Framework\\MockObject\\MethodNameConstraint' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/MethodNameConstraint.php', + 'PHPUnit\\Framework\\MockObject\\MethodNameNotConfiguredException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/MethodNameNotConfiguredException.php', + 'PHPUnit\\Framework\\MockObject\\MethodParametersAlreadyConfiguredException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/MethodParametersAlreadyConfiguredException.php', 'PHPUnit\\Framework\\MockObject\\MockBuilder' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/MockBuilder.php', 'PHPUnit\\Framework\\MockObject\\MockClass' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/MockClass.php', 'PHPUnit\\Framework\\MockObject\\MockMethod' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/MockMethod.php', @@ -3569,6 +3748,9 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'PHPUnit\\Framework\\MockObject\\MockTrait' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/MockTrait.php', 'PHPUnit\\Framework\\MockObject\\MockType' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/MockType.php', 'PHPUnit\\Framework\\MockObject\\MockedCloneMethod' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Api/MockedCloneMethod.php', + 'PHPUnit\\Framework\\MockObject\\OriginalConstructorInvocationRequiredException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/OriginalConstructorInvocationRequiredException.php', + 'PHPUnit\\Framework\\MockObject\\ReflectionException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/ReflectionException.php', + 'PHPUnit\\Framework\\MockObject\\ReturnValueNotConfiguredException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/ReturnValueNotConfiguredException.php', 'PHPUnit\\Framework\\MockObject\\Rule\\AnyInvokedCount' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Rule/AnyInvokedCount.php', 'PHPUnit\\Framework\\MockObject\\Rule\\AnyParameters' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Rule/AnyParameters.php', 'PHPUnit\\Framework\\MockObject\\Rule\\ConsecutiveParameters' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Rule/ConsecutiveParameters.php', @@ -3582,6 +3764,7 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'PHPUnit\\Framework\\MockObject\\Rule\\Parameters' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Rule/Parameters.php', 'PHPUnit\\Framework\\MockObject\\Rule\\ParametersRule' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Rule/ParametersRule.php', 'PHPUnit\\Framework\\MockObject\\RuntimeException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/RuntimeException.php', + 'PHPUnit\\Framework\\MockObject\\SoapExtensionNotAvailableException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/SoapExtensionNotAvailableException.php', 'PHPUnit\\Framework\\MockObject\\Stub' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Stub.php', 'PHPUnit\\Framework\\MockObject\\Stub\\ConsecutiveCalls' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Stub/ConsecutiveCalls.php', 'PHPUnit\\Framework\\MockObject\\Stub\\Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Stub/Exception.php', @@ -3592,11 +3775,15 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnStub' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnStub.php', 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnValueMap' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnValueMap.php', 'PHPUnit\\Framework\\MockObject\\Stub\\Stub' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Stub/Stub.php', + 'PHPUnit\\Framework\\MockObject\\UnknownClassException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownClassException.php', + 'PHPUnit\\Framework\\MockObject\\UnknownTraitException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownTraitException.php', + 'PHPUnit\\Framework\\MockObject\\UnknownTypeException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownTypeException.php', 'PHPUnit\\Framework\\MockObject\\UnmockedCloneMethod' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Api/UnmockedCloneMethod.php', 'PHPUnit\\Framework\\MockObject\\Verifiable' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Verifiable.php', 'PHPUnit\\Framework\\NoChildTestSuiteException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/NoChildTestSuiteException.php', 'PHPUnit\\Framework\\OutputError' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/OutputError.php', 'PHPUnit\\Framework\\PHPTAssertionFailedError' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/PHPTAssertionFailedError.php', + 'PHPUnit\\Framework\\Reorderable' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Reorderable.php', 'PHPUnit\\Framework\\RiskyTestError' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/RiskyTestError.php', 'PHPUnit\\Framework\\SelfDescribing' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/SelfDescribing.php', 'PHPUnit\\Framework\\SkippedTest' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/SkippedTest.php', @@ -3631,6 +3818,8 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'PHPUnit\\Runner\\BeforeTestHook' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Hook/BeforeTestHook.php', 'PHPUnit\\Runner\\DefaultTestResultCache' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/DefaultTestResultCache.php', 'PHPUnit\\Runner\\Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Exception.php', + 'PHPUnit\\Runner\\Extension\\ExtensionHandler' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Extension/ExtensionHandler.php', + 'PHPUnit\\Runner\\Extension\\PharLoader' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Extension/PharLoader.php', 'PHPUnit\\Runner\\Filter\\ExcludeGroupFilterIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Filter/ExcludeGroupFilterIterator.php', 'PHPUnit\\Runner\\Filter\\Factory' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Filter/Factory.php', 'PHPUnit\\Runner\\Filter\\GroupFilterIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Filter/GroupFilterIterator.php', @@ -3647,23 +3836,110 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'PHPUnit\\Runner\\TestSuiteLoader' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/TestSuiteLoader.php', 'PHPUnit\\Runner\\TestSuiteSorter' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/TestSuiteSorter.php', 'PHPUnit\\Runner\\Version' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Version.php', + 'PHPUnit\\TextUI\\CliArguments\\Builder' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/CliArguments/Builder.php', + 'PHPUnit\\TextUI\\CliArguments\\Configuration' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/CliArguments/Configuration.php', + 'PHPUnit\\TextUI\\CliArguments\\Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/CliArguments/Exception.php', + 'PHPUnit\\TextUI\\CliArguments\\Mapper' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/CliArguments/Mapper.php', 'PHPUnit\\TextUI\\Command' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Command.php', - 'PHPUnit\\TextUI\\Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Exception.php', + 'PHPUnit\\TextUI\\DefaultResultPrinter' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/DefaultResultPrinter.php', + 'PHPUnit\\TextUI\\Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Exception/Exception.php', 'PHPUnit\\TextUI\\Help' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Help.php', + 'PHPUnit\\TextUI\\ReflectionException' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Exception/ReflectionException.php', 'PHPUnit\\TextUI\\ResultPrinter' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/ResultPrinter.php', + 'PHPUnit\\TextUI\\RuntimeException' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Exception/RuntimeException.php', + 'PHPUnit\\TextUI\\TestDirectoryNotFoundException' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Exception/TestDirectoryNotFoundException.php', + 'PHPUnit\\TextUI\\TestFileNotFoundException' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Exception/TestFileNotFoundException.php', 'PHPUnit\\TextUI\\TestRunner' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/TestRunner.php', + 'PHPUnit\\TextUI\\TestSuiteMapper' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/TestSuiteMapper.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\CodeCoverage' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/CodeCoverage.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\FilterMapper' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/FilterMapper.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Filter\\Directory' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Filter/Directory.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Filter\\DirectoryCollection' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Filter/DirectoryCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Filter\\DirectoryCollectionIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Filter/DirectoryCollectionIterator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Report\\Clover' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Clover.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Report\\Cobertura' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Cobertura.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Report\\Crap4j' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Crap4j.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Report\\Html' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Html.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Report\\Php' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Php.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Report\\Text' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Text.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Report\\Xml' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Xml.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Configuration' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Configuration.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Constant' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/Constant.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\ConstantCollection' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/ConstantCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\ConstantCollectionIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/ConstantCollectionIterator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\ConvertLogTypes' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/ConvertLogTypes.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CoverageCloverToReport' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageCloverToReport.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CoverageCrap4jToReport' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageCrap4jToReport.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CoverageHtmlToReport' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageHtmlToReport.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CoveragePhpToReport' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoveragePhpToReport.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CoverageTextToReport' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageTextToReport.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CoverageXmlToReport' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageXmlToReport.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Directory' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/Directory.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\DirectoryCollection' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/DirectoryCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\DirectoryCollectionIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/DirectoryCollectionIterator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Exception.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Extension' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/Extension.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\ExtensionCollection' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/ExtensionCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\ExtensionCollectionIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/ExtensionCollectionIterator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\File' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/File.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\FileCollection' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/FileCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\FileCollectionIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/FileCollectionIterator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Generator' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Generator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Group' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/Group.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\GroupCollection' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/GroupCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\GroupCollectionIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/GroupCollectionIterator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Groups' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/Groups.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\IniSetting' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/IniSetting.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\IniSettingCollection' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/IniSettingCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\IniSettingCollectionIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/IniSettingCollectionIterator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\IntroduceCoverageElement' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/IntroduceCoverageElement.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Loader' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Loader.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\LogToReportMigration' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/LogToReportMigration.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Logging\\Junit' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/Junit.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Logging\\Logging' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/Logging.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Logging\\TeamCity' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TeamCity.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Logging\\TestDox\\Html' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TestDox/Html.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Logging\\TestDox\\Text' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TestDox/Text.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Logging\\TestDox\\Xml' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TestDox/Xml.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Logging\\Text' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/Text.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Migration' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/Migration.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\MigrationBuilder' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/MigrationBuilder.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\MigrationBuilderException' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/MigrationBuilderException.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\MigrationException' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/MigrationException.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Migrator' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\MoveAttributesFromFilterWhitelistToCoverage' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveAttributesFromFilterWhitelistToCoverage.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\MoveAttributesFromRootToCoverage' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveAttributesFromRootToCoverage.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\MoveWhitelistDirectoriesToCoverage' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveWhitelistDirectoriesToCoverage.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\MoveWhitelistExcludesToCoverage' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveWhitelistExcludesToCoverage.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\PHPUnit' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/PHPUnit.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Php' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/Php.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\PhpHandler' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/PhpHandler.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\RemoveCacheTokensAttribute' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/RemoveCacheTokensAttribute.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\RemoveEmptyFilter' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/RemoveEmptyFilter.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\RemoveLogTypes' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/RemoveLogTypes.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\TestDirectory' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestDirectory.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\TestDirectoryCollection' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestDirectoryCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\TestDirectoryCollectionIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestDirectoryCollectionIterator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\TestFile' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestFile.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\TestFileCollection' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestFileCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\TestFileCollectionIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestFileCollectionIterator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\TestSuite' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestSuite.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\TestSuiteCollection' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestSuiteCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\TestSuiteCollectionIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestSuiteCollectionIterator.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\UpdateSchemaLocationTo93' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/UpdateSchemaLocationTo93.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Variable' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/Variable.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\VariableCollection' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/VariableCollection.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\VariableCollectionIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/VariableCollectionIterator.php', 'PHPUnit\\Util\\Annotation\\DocBlock' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Annotation/DocBlock.php', 'PHPUnit\\Util\\Annotation\\Registry' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Annotation/Registry.php', 'PHPUnit\\Util\\Blacklist' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Blacklist.php', 'PHPUnit\\Util\\Color' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Color.php', - 'PHPUnit\\Util\\Configuration' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Configuration.php', - 'PHPUnit\\Util\\ConfigurationGenerator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/ConfigurationGenerator.php', 'PHPUnit\\Util\\ErrorHandler' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/ErrorHandler.php', 'PHPUnit\\Util\\Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Exception.php', + 'PHPUnit\\Util\\ExcludeList' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/ExcludeList.php', 'PHPUnit\\Util\\FileLoader' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/FileLoader.php', 'PHPUnit\\Util\\Filesystem' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Filesystem.php', 'PHPUnit\\Util\\Filter' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Filter.php', - 'PHPUnit\\Util\\Getopt' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Getopt.php', 'PHPUnit\\Util\\GlobalState' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/GlobalState.php', 'PHPUnit\\Util\\InvalidDataSetException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/InvalidDataSetException.php', 'PHPUnit\\Util\\Json' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Json.php', @@ -3688,184 +3964,16 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'PHPUnit\\Util\\XdebugFilterScriptGenerator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/XdebugFilterScriptGenerator.php', 'PHPUnit\\Util\\Xml' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Xml.php', 'PHPUnit\\Util\\XmlTestListRenderer' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/XmlTestListRenderer.php', - 'PHP_Token' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php', - 'PHP_TokenWithScope' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/TokenWithScope.php', - 'PHP_TokenWithScopeAndVisibility' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/TokenWithScopeAndVisibility.php', - 'PHP_Token_ABSTRACT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Abstract.php', - 'PHP_Token_AMPERSAND' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Ampersand.php', - 'PHP_Token_AND_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/AndEqual.php', - 'PHP_Token_ARRAY' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Array.php', - 'PHP_Token_ARRAY_CAST' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/ArrayCast.php', - 'PHP_Token_AS' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/As.php', - 'PHP_Token_AT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/At.php', - 'PHP_Token_BACKTICK' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Backtick.php', - 'PHP_Token_BAD_CHARACTER' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/BadCharacter.php', - 'PHP_Token_BOOLEAN_AND' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/BooleanAnd.php', - 'PHP_Token_BOOLEAN_OR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/BooleanOr.php', - 'PHP_Token_BOOL_CAST' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/BoolCast.php', - 'PHP_Token_BREAK' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/break.php', - 'PHP_Token_CALLABLE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Callable.php', - 'PHP_Token_CARET' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Caret.php', - 'PHP_Token_CASE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Case.php', - 'PHP_Token_CATCH' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Catch.php', - 'PHP_Token_CHARACTER' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Character.php', - 'PHP_Token_CLASS' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Class.php', - 'PHP_Token_CLASS_C' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/ClassC.php', - 'PHP_Token_CLASS_NAME_CONSTANT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/ClassNameConstant.php', - 'PHP_Token_CLONE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Clone.php', - 'PHP_Token_CLOSE_BRACKET' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/CloseBracket.php', - 'PHP_Token_CLOSE_CURLY' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/CloseCurly.php', - 'PHP_Token_CLOSE_SQUARE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/CloseSquare.php', - 'PHP_Token_CLOSE_TAG' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/CloseTag.php', - 'PHP_Token_COALESCE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Coalesce.php', - 'PHP_Token_COALESCE_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/CoalesceEqual.php', - 'PHP_Token_COLON' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Colon.php', - 'PHP_Token_COMMA' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Comma.php', - 'PHP_Token_COMMENT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Comment.php', - 'PHP_Token_CONCAT_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/ConcatEqual.php', - 'PHP_Token_CONST' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Const.php', - 'PHP_Token_CONSTANT_ENCAPSED_STRING' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/ConstantEncapsedString.php', - 'PHP_Token_CONTINUE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Continue.php', - 'PHP_Token_CURLY_OPEN' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/CurlyOpen.php', - 'PHP_Token_DEC' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Dec.php', - 'PHP_Token_DECLARE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Declare.php', - 'PHP_Token_DEFAULT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Default.php', - 'PHP_Token_DIR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Dir.php', - 'PHP_Token_DIV' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Div.php', - 'PHP_Token_DIV_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/DivEqual.php', - 'PHP_Token_DNUMBER' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/DNumber.php', - 'PHP_Token_DO' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Do.php', - 'PHP_Token_DOC_COMMENT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/DocComment.php', - 'PHP_Token_DOLLAR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Dollar.php', - 'PHP_Token_DOLLAR_OPEN_CURLY_BRACES' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/DollarOpenCurlyBraces.php', - 'PHP_Token_DOT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Dot.php', - 'PHP_Token_DOUBLE_ARROW' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/DoubleArrow.php', - 'PHP_Token_DOUBLE_CAST' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/DoubleCast.php', - 'PHP_Token_DOUBLE_COLON' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/DoubleColon.php', - 'PHP_Token_DOUBLE_QUOTES' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/DoubleQuotes.php', - 'PHP_Token_ECHO' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Echo.php', - 'PHP_Token_ELLIPSIS' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Ellipsis.php', - 'PHP_Token_ELSE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Else.php', - 'PHP_Token_ELSEIF' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Elseif.php', - 'PHP_Token_EMPTY' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Empty.php', - 'PHP_Token_ENCAPSED_AND_WHITESPACE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/EncapsedAndWhitespace.php', - 'PHP_Token_ENDDECLARE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Enddeclare.php', - 'PHP_Token_ENDFOR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Endfor.php', - 'PHP_Token_ENDFOREACH' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Endforeach.php', - 'PHP_Token_ENDIF' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Endif.php', - 'PHP_Token_ENDSWITCH' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Endswitch.php', - 'PHP_Token_ENDWHILE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Endwhile.php', - 'PHP_Token_END_HEREDOC' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/EndHeredoc.php', - 'PHP_Token_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Equal.php', - 'PHP_Token_EVAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Eval.php', - 'PHP_Token_EXCLAMATION_MARK' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/ExclamationMark.php', - 'PHP_Token_EXIT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Exit.php', - 'PHP_Token_EXTENDS' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Extends.php', - 'PHP_Token_FILE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/File.php', - 'PHP_Token_FINAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Final.php', - 'PHP_Token_FINALLY' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Finally.php', - 'PHP_Token_FN' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Fn.php', - 'PHP_Token_FOR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/For.php', - 'PHP_Token_FOREACH' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Foreach.php', - 'PHP_Token_FUNCTION' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Function.php', - 'PHP_Token_FUNC_C' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/FuncC.php', - 'PHP_Token_GLOBAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Global.php', - 'PHP_Token_GOTO' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Goto.php', - 'PHP_Token_GT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Gt.php', - 'PHP_Token_HALT_COMPILER' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/HaltCompiler.php', - 'PHP_Token_IF' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/If.php', - 'PHP_Token_IMPLEMENTS' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Implements.php', - 'PHP_Token_INC' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Inc.php', - 'PHP_Token_INCLUDE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Include.php', - 'PHP_Token_INCLUDE_ONCE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/IncludeOnce.php', - 'PHP_Token_INLINE_HTML' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/InlineHtml.php', - 'PHP_Token_INSTANCEOF' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Instanceof.php', - 'PHP_Token_INSTEADOF' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Insteadof.php', - 'PHP_Token_INTERFACE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Interface.php', - 'PHP_Token_INT_CAST' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/IntCast.php', - 'PHP_Token_ISSET' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Isset.php', - 'PHP_Token_IS_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/IsEqual.php', - 'PHP_Token_IS_GREATER_OR_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/IsGreaterOrEqual.php', - 'PHP_Token_IS_IDENTICAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/IsIdentical.php', - 'PHP_Token_IS_NOT_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/IsNotEqual.php', - 'PHP_Token_IS_NOT_IDENTICAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/IsNotIdentical.php', - 'PHP_Token_IS_SMALLER_OR_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/IsSmallerOrEqual.php', - 'PHP_Token_Includes' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Includes.php', - 'PHP_Token_LINE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Line.php', - 'PHP_Token_LIST' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/List.php', - 'PHP_Token_LNUMBER' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Lnumber.php', - 'PHP_Token_LOGICAL_AND' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/LogicalAnd.php', - 'PHP_Token_LOGICAL_OR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/LogicalOr.php', - 'PHP_Token_LOGICAL_XOR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/LogicalXor.php', - 'PHP_Token_LT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Lt.php', - 'PHP_Token_METHOD_C' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/MethodC.php', - 'PHP_Token_MINUS' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Minus.php', - 'PHP_Token_MINUS_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/MinusEqual.php', - 'PHP_Token_MOD_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/ModEqual.php', - 'PHP_Token_MULT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Mult.php', - 'PHP_Token_MUL_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/MulEqual.php', - 'PHP_Token_NAMESPACE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Namespace.php', - 'PHP_Token_NAME_FULLY_QUALIFIED' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/NameFullyQualified.php', - 'PHP_Token_NAME_QUALIFIED' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/NameQualified.php', - 'PHP_Token_NAME_RELATIVE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/NameRelative.php', - 'PHP_Token_NEW' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/New.php', - 'PHP_Token_NS_C' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/NsC.php', - 'PHP_Token_NS_SEPARATOR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/NsSeparator.php', - 'PHP_Token_NUM_STRING' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/NumString.php', - 'PHP_Token_OBJECT_CAST' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/ObjectCast.php', - 'PHP_Token_OBJECT_OPERATOR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/ObjectOperator.php', - 'PHP_Token_OPEN_BRACKET' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/OpenBracket.php', - 'PHP_Token_OPEN_CURLY' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/OpenCurly.php', - 'PHP_Token_OPEN_SQUARE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/OpenSquare.php', - 'PHP_Token_OPEN_TAG' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/OpenTag.php', - 'PHP_Token_OPEN_TAG_WITH_ECHO' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/OpenTagWithEcho.php', - 'PHP_Token_OR_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/OrEqual.php', - 'PHP_Token_PAAMAYIM_NEKUDOTAYIM' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/PaamayimNekudotayim.php', - 'PHP_Token_PERCENT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Percent.php', - 'PHP_Token_PIPE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Pipe.php', - 'PHP_Token_PLUS' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Plus.php', - 'PHP_Token_PLUS_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/PlusEqual.php', - 'PHP_Token_POW' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Pow.php', - 'PHP_Token_POW_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/PowEqual.php', - 'PHP_Token_PRINT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Print.php', - 'PHP_Token_PRIVATE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Private.php', - 'PHP_Token_PROTECTED' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Protected.php', - 'PHP_Token_PUBLIC' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Public.php', - 'PHP_Token_QUESTION_MARK' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/QuestionMark.php', - 'PHP_Token_REQUIRE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Require.php', - 'PHP_Token_REQUIRE_ONCE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/RequireOnce.php', - 'PHP_Token_RETURN' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Return.php', - 'PHP_Token_SEMICOLON' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Semicolon.php', - 'PHP_Token_SL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Sl.php', - 'PHP_Token_SL_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/SlEqual.php', - 'PHP_Token_SPACESHIP' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Spaceship.php', - 'PHP_Token_SR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Sr.php', - 'PHP_Token_SR_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/SrEqual.php', - 'PHP_Token_START_HEREDOC' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/StartHeredoc.php', - 'PHP_Token_STATIC' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Static.php', - 'PHP_Token_STRING' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/String.php', - 'PHP_Token_STRING_CAST' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/StringCast.php', - 'PHP_Token_STRING_VARNAME' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/StringVarname.php', - 'PHP_Token_SWITCH' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Switch.php', - 'PHP_Token_Stream' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Stream.php', - 'PHP_Token_Stream_CachingFactory' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/CachingFactory.php', - 'PHP_Token_THROW' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Throw.php', - 'PHP_Token_TILDE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Tilde.php', - 'PHP_Token_TRAIT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Trait.php', - 'PHP_Token_TRAIT_C' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/TraitC.php', - 'PHP_Token_TRY' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Try.php', - 'PHP_Token_UNSET' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Unset.php', - 'PHP_Token_UNSET_CAST' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/UnsetCast.php', - 'PHP_Token_USE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Use.php', - 'PHP_Token_USE_FUNCTION' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/UseFunction.php', - 'PHP_Token_Util' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Util.php', - 'PHP_Token_VAR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Var.php', - 'PHP_Token_VARIABLE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Variable.php', - 'PHP_Token_WHILE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/While.php', - 'PHP_Token_WHITESPACE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Whitespace.php', - 'PHP_Token_XOR_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/XorEqual.php', - 'PHP_Token_YIELD' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Yield.php', - 'PHP_Token_YIELD_FROM' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/YieldFrom.php', + 'PHPUnit\\Util\\Xml\\Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Xml/Exception.php', + 'PHPUnit\\Util\\Xml\\FailedSchemaDetectionResult' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Xml/FailedSchemaDetectionResult.php', + 'PHPUnit\\Util\\Xml\\Loader' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Xml/Loader.php', + 'PHPUnit\\Util\\Xml\\SchemaDetectionResult' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Xml/SchemaDetectionResult.php', + 'PHPUnit\\Util\\Xml\\SchemaDetector' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Xml/SchemaDetector.php', + 'PHPUnit\\Util\\Xml\\SchemaFinder' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Xml/SchemaFinder.php', + 'PHPUnit\\Util\\Xml\\SnapshotNodeList' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Xml/SnapshotNodeList.php', + 'PHPUnit\\Util\\Xml\\SuccessfulSchemaDetectionResult' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Xml/SuccessfulSchemaDetectionResult.php', + 'PHPUnit\\Util\\Xml\\ValidationResult' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Xml/ValidationResult.php', + 'PHPUnit\\Util\\Xml\\Validator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Xml/Validator.php', 'PharIo\\Manifest\\Application' => __DIR__ . '/..' . '/phar-io/manifest/src/values/Application.php', 'PharIo\\Manifest\\ApplicationName' => __DIR__ . '/..' . '/phar-io/manifest/src/values/ApplicationName.php', 'PharIo\\Manifest\\Author' => __DIR__ . '/..' . '/phar-io/manifest/src/values/Author.php', @@ -3939,6 +4047,247 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'PhpOption\\None' => __DIR__ . '/..' . '/phpoption/phpoption/src/PhpOption/None.php', 'PhpOption\\Option' => __DIR__ . '/..' . '/phpoption/phpoption/src/PhpOption/Option.php', 'PhpOption\\Some' => __DIR__ . '/..' . '/phpoption/phpoption/src/PhpOption/Some.php', + 'PhpParser\\Builder' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Builder.php', + 'PhpParser\\BuilderFactory' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/BuilderFactory.php', + 'PhpParser\\BuilderHelpers' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/BuilderHelpers.php', + 'PhpParser\\Builder\\ClassConst' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Builder/ClassConst.php', + 'PhpParser\\Builder\\Class_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Builder/Class_.php', + 'PhpParser\\Builder\\Declaration' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Builder/Declaration.php', + 'PhpParser\\Builder\\FunctionLike' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Builder/FunctionLike.php', + 'PhpParser\\Builder\\Function_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Builder/Function_.php', + 'PhpParser\\Builder\\Interface_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Builder/Interface_.php', + 'PhpParser\\Builder\\Method' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Builder/Method.php', + 'PhpParser\\Builder\\Namespace_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Builder/Namespace_.php', + 'PhpParser\\Builder\\Param' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Builder/Param.php', + 'PhpParser\\Builder\\Property' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Builder/Property.php', + 'PhpParser\\Builder\\TraitUse' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Builder/TraitUse.php', + 'PhpParser\\Builder\\TraitUseAdaptation' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Builder/TraitUseAdaptation.php', + 'PhpParser\\Builder\\Trait_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Builder/Trait_.php', + 'PhpParser\\Builder\\Use_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Builder/Use_.php', + 'PhpParser\\Comment' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Comment.php', + 'PhpParser\\Comment\\Doc' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Comment/Doc.php', + 'PhpParser\\ConstExprEvaluationException' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/ConstExprEvaluationException.php', + 'PhpParser\\ConstExprEvaluator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/ConstExprEvaluator.php', + 'PhpParser\\Error' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Error.php', + 'PhpParser\\ErrorHandler' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/ErrorHandler.php', + 'PhpParser\\ErrorHandler\\Collecting' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/ErrorHandler/Collecting.php', + 'PhpParser\\ErrorHandler\\Throwing' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/ErrorHandler/Throwing.php', + 'PhpParser\\Internal\\DiffElem' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Internal/DiffElem.php', + 'PhpParser\\Internal\\Differ' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Internal/Differ.php', + 'PhpParser\\Internal\\PrintableNewAnonClassNode' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Internal/PrintableNewAnonClassNode.php', + 'PhpParser\\Internal\\TokenStream' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Internal/TokenStream.php', + 'PhpParser\\JsonDecoder' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/JsonDecoder.php', + 'PhpParser\\Lexer' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer.php', + 'PhpParser\\Lexer\\Emulative' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/Emulative.php', + 'PhpParser\\Lexer\\TokenEmulator\\AttributeEmulator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/AttributeEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\CoaleseEqualTokenEmulator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/CoaleseEqualTokenEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\EnumTokenEmulator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/EnumTokenEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\FlexibleDocStringEmulator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/FlexibleDocStringEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\FnTokenEmulator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/FnTokenEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\KeywordEmulator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/KeywordEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\MatchTokenEmulator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/MatchTokenEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\NullsafeTokenEmulator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/NullsafeTokenEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\NumericLiteralSeparatorEmulator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/NumericLiteralSeparatorEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\ReverseEmulator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/ReverseEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\TokenEmulator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/TokenEmulator.php', + 'PhpParser\\NameContext' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/NameContext.php', + 'PhpParser\\Node' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node.php', + 'PhpParser\\NodeAbstract' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/NodeAbstract.php', + 'PhpParser\\NodeDumper' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/NodeDumper.php', + 'PhpParser\\NodeFinder' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/NodeFinder.php', + 'PhpParser\\NodeTraverser' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/NodeTraverser.php', + 'PhpParser\\NodeTraverserInterface' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/NodeTraverserInterface.php', + 'PhpParser\\NodeVisitor' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/NodeVisitor.php', + 'PhpParser\\NodeVisitorAbstract' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/NodeVisitorAbstract.php', + 'PhpParser\\NodeVisitor\\CloningVisitor' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/NodeVisitor/CloningVisitor.php', + 'PhpParser\\NodeVisitor\\FindingVisitor' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/NodeVisitor/FindingVisitor.php', + 'PhpParser\\NodeVisitor\\FirstFindingVisitor' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/NodeVisitor/FirstFindingVisitor.php', + 'PhpParser\\NodeVisitor\\NameResolver' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/NodeVisitor/NameResolver.php', + 'PhpParser\\NodeVisitor\\NodeConnectingVisitor' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/NodeVisitor/NodeConnectingVisitor.php', + 'PhpParser\\NodeVisitor\\ParentConnectingVisitor' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/NodeVisitor/ParentConnectingVisitor.php', + 'PhpParser\\Node\\Arg' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Arg.php', + 'PhpParser\\Node\\Attribute' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Attribute.php', + 'PhpParser\\Node\\AttributeGroup' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/AttributeGroup.php', + 'PhpParser\\Node\\Const_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Const_.php', + 'PhpParser\\Node\\Expr' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr.php', + 'PhpParser\\Node\\Expr\\ArrayDimFetch' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/ArrayDimFetch.php', + 'PhpParser\\Node\\Expr\\ArrayItem' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/ArrayItem.php', + 'PhpParser\\Node\\Expr\\Array_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Array_.php', + 'PhpParser\\Node\\Expr\\ArrowFunction' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/ArrowFunction.php', + 'PhpParser\\Node\\Expr\\Assign' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Assign.php', + 'PhpParser\\Node\\Expr\\AssignOp' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp.php', + 'PhpParser\\Node\\Expr\\AssignOp\\BitwiseAnd' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/BitwiseAnd.php', + 'PhpParser\\Node\\Expr\\AssignOp\\BitwiseOr' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/BitwiseOr.php', + 'PhpParser\\Node\\Expr\\AssignOp\\BitwiseXor' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/BitwiseXor.php', + 'PhpParser\\Node\\Expr\\AssignOp\\Coalesce' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Coalesce.php', + 'PhpParser\\Node\\Expr\\AssignOp\\Concat' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Concat.php', + 'PhpParser\\Node\\Expr\\AssignOp\\Div' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Div.php', + 'PhpParser\\Node\\Expr\\AssignOp\\Minus' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Minus.php', + 'PhpParser\\Node\\Expr\\AssignOp\\Mod' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Mod.php', + 'PhpParser\\Node\\Expr\\AssignOp\\Mul' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Mul.php', + 'PhpParser\\Node\\Expr\\AssignOp\\Plus' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Plus.php', + 'PhpParser\\Node\\Expr\\AssignOp\\Pow' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/Pow.php', + 'PhpParser\\Node\\Expr\\AssignOp\\ShiftLeft' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/ShiftLeft.php', + 'PhpParser\\Node\\Expr\\AssignOp\\ShiftRight' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignOp/ShiftRight.php', + 'PhpParser\\Node\\Expr\\AssignRef' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/AssignRef.php', + 'PhpParser\\Node\\Expr\\BinaryOp' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\BitwiseAnd' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/BitwiseAnd.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\BitwiseOr' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/BitwiseOr.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\BitwiseXor' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/BitwiseXor.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\BooleanAnd' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/BooleanAnd.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\BooleanOr' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/BooleanOr.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Coalesce' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Coalesce.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Concat' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Concat.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Div' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Div.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Equal' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Equal.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Greater' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Greater.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\GreaterOrEqual' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/GreaterOrEqual.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Identical' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Identical.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\LogicalAnd' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/LogicalAnd.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\LogicalOr' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/LogicalOr.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\LogicalXor' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/LogicalXor.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Minus' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Minus.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Mod' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Mod.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Mul' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Mul.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\NotEqual' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/NotEqual.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\NotIdentical' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/NotIdentical.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Plus' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Plus.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Pow' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Pow.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\ShiftLeft' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/ShiftLeft.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\ShiftRight' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/ShiftRight.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Smaller' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Smaller.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\SmallerOrEqual' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/SmallerOrEqual.php', + 'PhpParser\\Node\\Expr\\BinaryOp\\Spaceship' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BinaryOp/Spaceship.php', + 'PhpParser\\Node\\Expr\\BitwiseNot' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BitwiseNot.php', + 'PhpParser\\Node\\Expr\\BooleanNot' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/BooleanNot.php', + 'PhpParser\\Node\\Expr\\Cast' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Cast.php', + 'PhpParser\\Node\\Expr\\Cast\\Array_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Cast/Array_.php', + 'PhpParser\\Node\\Expr\\Cast\\Bool_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Cast/Bool_.php', + 'PhpParser\\Node\\Expr\\Cast\\Double' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Cast/Double.php', + 'PhpParser\\Node\\Expr\\Cast\\Int_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Cast/Int_.php', + 'PhpParser\\Node\\Expr\\Cast\\Object_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Cast/Object_.php', + 'PhpParser\\Node\\Expr\\Cast\\String_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Cast/String_.php', + 'PhpParser\\Node\\Expr\\Cast\\Unset_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Cast/Unset_.php', + 'PhpParser\\Node\\Expr\\ClassConstFetch' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/ClassConstFetch.php', + 'PhpParser\\Node\\Expr\\Clone_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Clone_.php', + 'PhpParser\\Node\\Expr\\Closure' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Closure.php', + 'PhpParser\\Node\\Expr\\ClosureUse' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/ClosureUse.php', + 'PhpParser\\Node\\Expr\\ConstFetch' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/ConstFetch.php', + 'PhpParser\\Node\\Expr\\Empty_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Empty_.php', + 'PhpParser\\Node\\Expr\\Error' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Error.php', + 'PhpParser\\Node\\Expr\\ErrorSuppress' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/ErrorSuppress.php', + 'PhpParser\\Node\\Expr\\Eval_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Eval_.php', + 'PhpParser\\Node\\Expr\\Exit_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Exit_.php', + 'PhpParser\\Node\\Expr\\FuncCall' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/FuncCall.php', + 'PhpParser\\Node\\Expr\\Include_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Include_.php', + 'PhpParser\\Node\\Expr\\Instanceof_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Instanceof_.php', + 'PhpParser\\Node\\Expr\\Isset_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Isset_.php', + 'PhpParser\\Node\\Expr\\List_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/List_.php', + 'PhpParser\\Node\\Expr\\Match_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Match_.php', + 'PhpParser\\Node\\Expr\\MethodCall' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/MethodCall.php', + 'PhpParser\\Node\\Expr\\New_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/New_.php', + 'PhpParser\\Node\\Expr\\NullsafeMethodCall' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/NullsafeMethodCall.php', + 'PhpParser\\Node\\Expr\\NullsafePropertyFetch' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/NullsafePropertyFetch.php', + 'PhpParser\\Node\\Expr\\PostDec' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/PostDec.php', + 'PhpParser\\Node\\Expr\\PostInc' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/PostInc.php', + 'PhpParser\\Node\\Expr\\PreDec' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/PreDec.php', + 'PhpParser\\Node\\Expr\\PreInc' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/PreInc.php', + 'PhpParser\\Node\\Expr\\Print_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Print_.php', + 'PhpParser\\Node\\Expr\\PropertyFetch' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/PropertyFetch.php', + 'PhpParser\\Node\\Expr\\ShellExec' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/ShellExec.php', + 'PhpParser\\Node\\Expr\\StaticCall' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/StaticCall.php', + 'PhpParser\\Node\\Expr\\StaticPropertyFetch' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/StaticPropertyFetch.php', + 'PhpParser\\Node\\Expr\\Ternary' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Ternary.php', + 'PhpParser\\Node\\Expr\\Throw_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Throw_.php', + 'PhpParser\\Node\\Expr\\UnaryMinus' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/UnaryMinus.php', + 'PhpParser\\Node\\Expr\\UnaryPlus' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/UnaryPlus.php', + 'PhpParser\\Node\\Expr\\Variable' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Variable.php', + 'PhpParser\\Node\\Expr\\YieldFrom' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/YieldFrom.php', + 'PhpParser\\Node\\Expr\\Yield_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Yield_.php', + 'PhpParser\\Node\\FunctionLike' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/FunctionLike.php', + 'PhpParser\\Node\\Identifier' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Identifier.php', + 'PhpParser\\Node\\MatchArm' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/MatchArm.php', + 'PhpParser\\Node\\Name' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Name.php', + 'PhpParser\\Node\\Name\\FullyQualified' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Name/FullyQualified.php', + 'PhpParser\\Node\\Name\\Relative' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Name/Relative.php', + 'PhpParser\\Node\\NullableType' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/NullableType.php', + 'PhpParser\\Node\\Param' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Param.php', + 'PhpParser\\Node\\Scalar' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Scalar.php', + 'PhpParser\\Node\\Scalar\\DNumber' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Scalar/DNumber.php', + 'PhpParser\\Node\\Scalar\\Encapsed' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Scalar/Encapsed.php', + 'PhpParser\\Node\\Scalar\\EncapsedStringPart' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Scalar/EncapsedStringPart.php', + 'PhpParser\\Node\\Scalar\\LNumber' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Scalar/LNumber.php', + 'PhpParser\\Node\\Scalar\\MagicConst' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst.php', + 'PhpParser\\Node\\Scalar\\MagicConst\\Class_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/Class_.php', + 'PhpParser\\Node\\Scalar\\MagicConst\\Dir' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/Dir.php', + 'PhpParser\\Node\\Scalar\\MagicConst\\File' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/File.php', + 'PhpParser\\Node\\Scalar\\MagicConst\\Function_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/Function_.php', + 'PhpParser\\Node\\Scalar\\MagicConst\\Line' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/Line.php', + 'PhpParser\\Node\\Scalar\\MagicConst\\Method' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/Method.php', + 'PhpParser\\Node\\Scalar\\MagicConst\\Namespace_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/Namespace_.php', + 'PhpParser\\Node\\Scalar\\MagicConst\\Trait_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Scalar/MagicConst/Trait_.php', + 'PhpParser\\Node\\Scalar\\String_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Scalar/String_.php', + 'PhpParser\\Node\\Stmt' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt.php', + 'PhpParser\\Node\\Stmt\\Break_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Break_.php', + 'PhpParser\\Node\\Stmt\\Case_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Case_.php', + 'PhpParser\\Node\\Stmt\\Catch_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Catch_.php', + 'PhpParser\\Node\\Stmt\\ClassConst' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/ClassConst.php', + 'PhpParser\\Node\\Stmt\\ClassLike' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/ClassLike.php', + 'PhpParser\\Node\\Stmt\\ClassMethod' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/ClassMethod.php', + 'PhpParser\\Node\\Stmt\\Class_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Class_.php', + 'PhpParser\\Node\\Stmt\\Const_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Const_.php', + 'PhpParser\\Node\\Stmt\\Continue_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Continue_.php', + 'PhpParser\\Node\\Stmt\\DeclareDeclare' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/DeclareDeclare.php', + 'PhpParser\\Node\\Stmt\\Declare_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Declare_.php', + 'PhpParser\\Node\\Stmt\\Do_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Do_.php', + 'PhpParser\\Node\\Stmt\\Echo_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Echo_.php', + 'PhpParser\\Node\\Stmt\\ElseIf_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/ElseIf_.php', + 'PhpParser\\Node\\Stmt\\Else_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Else_.php', + 'PhpParser\\Node\\Stmt\\EnumCase' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/EnumCase.php', + 'PhpParser\\Node\\Stmt\\Enum_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Enum_.php', + 'PhpParser\\Node\\Stmt\\Expression' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Expression.php', + 'PhpParser\\Node\\Stmt\\Finally_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Finally_.php', + 'PhpParser\\Node\\Stmt\\For_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/For_.php', + 'PhpParser\\Node\\Stmt\\Foreach_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Foreach_.php', + 'PhpParser\\Node\\Stmt\\Function_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Function_.php', + 'PhpParser\\Node\\Stmt\\Global_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Global_.php', + 'PhpParser\\Node\\Stmt\\Goto_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Goto_.php', + 'PhpParser\\Node\\Stmt\\GroupUse' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/GroupUse.php', + 'PhpParser\\Node\\Stmt\\HaltCompiler' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/HaltCompiler.php', + 'PhpParser\\Node\\Stmt\\If_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/If_.php', + 'PhpParser\\Node\\Stmt\\InlineHTML' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/InlineHTML.php', + 'PhpParser\\Node\\Stmt\\Interface_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Interface_.php', + 'PhpParser\\Node\\Stmt\\Label' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Label.php', + 'PhpParser\\Node\\Stmt\\Namespace_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Namespace_.php', + 'PhpParser\\Node\\Stmt\\Nop' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Nop.php', + 'PhpParser\\Node\\Stmt\\Property' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Property.php', + 'PhpParser\\Node\\Stmt\\PropertyProperty' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/PropertyProperty.php', + 'PhpParser\\Node\\Stmt\\Return_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Return_.php', + 'PhpParser\\Node\\Stmt\\StaticVar' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/StaticVar.php', + 'PhpParser\\Node\\Stmt\\Static_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Static_.php', + 'PhpParser\\Node\\Stmt\\Switch_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Switch_.php', + 'PhpParser\\Node\\Stmt\\Throw_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Throw_.php', + 'PhpParser\\Node\\Stmt\\TraitUse' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/TraitUse.php', + 'PhpParser\\Node\\Stmt\\TraitUseAdaptation' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/TraitUseAdaptation.php', + 'PhpParser\\Node\\Stmt\\TraitUseAdaptation\\Alias' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/TraitUseAdaptation/Alias.php', + 'PhpParser\\Node\\Stmt\\TraitUseAdaptation\\Precedence' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/TraitUseAdaptation/Precedence.php', + 'PhpParser\\Node\\Stmt\\Trait_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Trait_.php', + 'PhpParser\\Node\\Stmt\\TryCatch' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/TryCatch.php', + 'PhpParser\\Node\\Stmt\\Unset_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Unset_.php', + 'PhpParser\\Node\\Stmt\\UseUse' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/UseUse.php', + 'PhpParser\\Node\\Stmt\\Use_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/Use_.php', + 'PhpParser\\Node\\Stmt\\While_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Stmt/While_.php', + 'PhpParser\\Node\\UnionType' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/UnionType.php', + 'PhpParser\\Node\\VarLikeIdentifier' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/VarLikeIdentifier.php', + 'PhpParser\\Parser' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Parser.php', + 'PhpParser\\ParserAbstract' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/ParserAbstract.php', + 'PhpParser\\ParserFactory' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/ParserFactory.php', + 'PhpParser\\Parser\\Multiple' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Parser/Multiple.php', + 'PhpParser\\Parser\\Php5' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Parser/Php5.php', + 'PhpParser\\Parser\\Php7' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Parser/Php7.php', + 'PhpParser\\Parser\\Tokens' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Parser/Tokens.php', + 'PhpParser\\PrettyPrinterAbstract' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/PrettyPrinterAbstract.php', + 'PhpParser\\PrettyPrinter\\Standard' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/PrettyPrinter/Standard.php', 'Predis\\Autoloader' => __DIR__ . '/..' . '/predis/predis/src/Autoloader.php', 'Predis\\Client' => __DIR__ . '/..' . '/predis/predis/src/Client.php', 'Predis\\ClientContextInterface' => __DIR__ . '/..' . '/predis/predis/src/ClientContextInterface.php', @@ -4310,6 +4659,10 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Psr\\EventDispatcher\\EventDispatcherInterface' => __DIR__ . '/..' . '/psr/event-dispatcher/src/EventDispatcherInterface.php', 'Psr\\EventDispatcher\\ListenerProviderInterface' => __DIR__ . '/..' . '/psr/event-dispatcher/src/ListenerProviderInterface.php', 'Psr\\EventDispatcher\\StoppableEventInterface' => __DIR__ . '/..' . '/psr/event-dispatcher/src/StoppableEventInterface.php', + 'Psr\\Http\\Client\\ClientExceptionInterface' => __DIR__ . '/..' . '/psr/http-client/src/ClientExceptionInterface.php', + 'Psr\\Http\\Client\\ClientInterface' => __DIR__ . '/..' . '/psr/http-client/src/ClientInterface.php', + 'Psr\\Http\\Client\\NetworkExceptionInterface' => __DIR__ . '/..' . '/psr/http-client/src/NetworkExceptionInterface.php', + 'Psr\\Http\\Client\\RequestExceptionInterface' => __DIR__ . '/..' . '/psr/http-client/src/RequestExceptionInterface.php', 'Psr\\Http\\Message\\MessageInterface' => __DIR__ . '/..' . '/psr/http-message/src/MessageInterface.php', 'Psr\\Http\\Message\\RequestInterface' => __DIR__ . '/..' . '/psr/http-message/src/RequestInterface.php', 'Psr\\Http\\Message\\ResponseInterface' => __DIR__ . '/..' . '/psr/http-message/src/ResponseInterface.php', @@ -4498,22 +4851,50 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Seat\\Eseye\\Log\\RotatingFileLogger' => __DIR__ . '/..' . '/eveseat/eseye/src/Log/RotatingFileLogger.php', 'Seat\\Eseye\\Traits\\ConstructsContainers' => __DIR__ . '/..' . '/eveseat/eseye/src/Traits/ConstructsContainers.php', 'Seat\\Eseye\\Traits\\ValidatesContainers' => __DIR__ . '/..' . '/eveseat/eseye/src/Traits/ValidatesContainers.php', + 'SebastianBergmann\\CliParser\\AmbiguousOptionException' => __DIR__ . '/..' . '/sebastian/cli-parser/src/exceptions/AmbiguousOptionException.php', + 'SebastianBergmann\\CliParser\\Exception' => __DIR__ . '/..' . '/sebastian/cli-parser/src/exceptions/Exception.php', + 'SebastianBergmann\\CliParser\\OptionDoesNotAllowArgumentException' => __DIR__ . '/..' . '/sebastian/cli-parser/src/exceptions/OptionDoesNotAllowArgumentException.php', + 'SebastianBergmann\\CliParser\\Parser' => __DIR__ . '/..' . '/sebastian/cli-parser/src/Parser.php', + 'SebastianBergmann\\CliParser\\RequiredOptionArgumentMissingException' => __DIR__ . '/..' . '/sebastian/cli-parser/src/exceptions/RequiredOptionArgumentMissingException.php', + 'SebastianBergmann\\CliParser\\UnknownOptionException' => __DIR__ . '/..' . '/sebastian/cli-parser/src/exceptions/UnknownOptionException.php', + 'SebastianBergmann\\CodeCoverage\\BranchAndPathCoverageNotSupportedException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/BranchAndPathCoverageNotSupportedException.php', 'SebastianBergmann\\CodeCoverage\\CodeCoverage' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/CodeCoverage.php', - 'SebastianBergmann\\CodeCoverage\\CoveredCodeNotExecutedException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/CoveredCodeNotExecutedException.php', + 'SebastianBergmann\\CodeCoverage\\CrapIndex' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/CrapIndex.php', + 'SebastianBergmann\\CodeCoverage\\DeadCodeDetectionNotSupportedException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/DeadCodeDetectionNotSupportedException.php', + 'SebastianBergmann\\CodeCoverage\\Directory' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Directory.php', + 'SebastianBergmann\\CodeCoverage\\DirectoryCouldNotBeCreatedException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/DirectoryCouldNotBeCreatedException.php', 'SebastianBergmann\\CodeCoverage\\Driver\\Driver' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Driver/Driver.php', - 'SebastianBergmann\\CodeCoverage\\Driver\\PCOV' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Driver/PCOV.php', - 'SebastianBergmann\\CodeCoverage\\Driver\\PHPDBG' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Driver/PHPDBG.php', - 'SebastianBergmann\\CodeCoverage\\Driver\\Xdebug' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Driver/Xdebug.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\PathExistsButIsNotDirectoryException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/PathExistsButIsNotDirectoryException.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\PcovDriver' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Driver/PcovDriver.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\PcovNotAvailableException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/PcovNotAvailableException.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\PhpdbgDriver' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Driver/PhpdbgDriver.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\PhpdbgNotAvailableException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/PhpdbgNotAvailableException.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\Selector' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Driver/Selector.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\WriteOperationFailedException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/WriteOperationFailedException.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\WrongXdebugVersionException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/WrongXdebugVersionException.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\Xdebug2Driver' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Driver/Xdebug2Driver.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\Xdebug2NotEnabledException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/Xdebug2NotEnabledException.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\Xdebug3Driver' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Driver/Xdebug3Driver.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\Xdebug3NotEnabledException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/Xdebug3NotEnabledException.php', + 'SebastianBergmann\\CodeCoverage\\Driver\\XdebugNotAvailableException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/XdebugNotAvailableException.php', 'SebastianBergmann\\CodeCoverage\\Exception' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/Exception.php', 'SebastianBergmann\\CodeCoverage\\Filter' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Filter.php', 'SebastianBergmann\\CodeCoverage\\InvalidArgumentException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/InvalidArgumentException.php', - 'SebastianBergmann\\CodeCoverage\\MissingCoversAnnotationException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/MissingCoversAnnotationException.php', + 'SebastianBergmann\\CodeCoverage\\NoCodeCoverageDriverAvailableException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/NoCodeCoverageDriverAvailableException.php', + 'SebastianBergmann\\CodeCoverage\\NoCodeCoverageDriverWithPathCoverageSupportAvailableException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/NoCodeCoverageDriverWithPathCoverageSupportAvailableException.php', 'SebastianBergmann\\CodeCoverage\\Node\\AbstractNode' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Node/AbstractNode.php', 'SebastianBergmann\\CodeCoverage\\Node\\Builder' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Node/Builder.php', 'SebastianBergmann\\CodeCoverage\\Node\\Directory' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Node/Directory.php', 'SebastianBergmann\\CodeCoverage\\Node\\File' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Node/File.php', 'SebastianBergmann\\CodeCoverage\\Node\\Iterator' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Node/Iterator.php', + 'SebastianBergmann\\CodeCoverage\\ParserException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/ParserException.php', + 'SebastianBergmann\\CodeCoverage\\Percentage' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Percentage.php', + 'SebastianBergmann\\CodeCoverage\\ProcessedCodeCoverageData' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/ProcessedCodeCoverageData.php', + 'SebastianBergmann\\CodeCoverage\\RawCodeCoverageData' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/RawCodeCoverageData.php', + 'SebastianBergmann\\CodeCoverage\\ReflectionException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/ReflectionException.php', + 'SebastianBergmann\\CodeCoverage\\ReportAlreadyFinalizedException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/ReportAlreadyFinalizedException.php', 'SebastianBergmann\\CodeCoverage\\Report\\Clover' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Clover.php', + 'SebastianBergmann\\CodeCoverage\\Report\\Cobertura' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Cobertura.php', 'SebastianBergmann\\CodeCoverage\\Report\\Crap4j' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Crap4j.php', 'SebastianBergmann\\CodeCoverage\\Report\\Html\\Dashboard' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Html/Renderer/Dashboard.php', 'SebastianBergmann\\CodeCoverage\\Report\\Html\\Directory' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Html/Renderer/Directory.php', @@ -4535,26 +4916,63 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Tests' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Xml/Tests.php', 'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Totals' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Xml/Totals.php', 'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Unit' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Xml/Unit.php', - 'SebastianBergmann\\CodeCoverage\\RuntimeException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/RuntimeException.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysisCacheNotConfiguredException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/StaticAnalysisCacheNotConfiguredException.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\Cache' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/StaticAnalysis/Cache.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\CacheWarmer' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/StaticAnalysis/CacheWarmer.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\CachingCoveredFileAnalyser' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/StaticAnalysis/CachingCoveredFileAnalyser.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\CachingUncoveredFileAnalyser' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/StaticAnalysis/CachingUncoveredFileAnalyser.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\CodeUnitFindingVisitor' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/StaticAnalysis/CodeUnitFindingVisitor.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\CoveredFileAnalyser' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/StaticAnalysis/CoveredFileAnalyser.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\ExecutableLinesFindingVisitor' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/StaticAnalysis/ExecutableLinesFindingVisitor.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\IgnoredLinesFindingVisitor' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/StaticAnalysis/IgnoredLinesFindingVisitor.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\ParsingCoveredFileAnalyser' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/StaticAnalysis/ParsingCoveredFileAnalyser.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\ParsingUncoveredFileAnalyser' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/StaticAnalysis/ParsingUncoveredFileAnalyser.php', + 'SebastianBergmann\\CodeCoverage\\StaticAnalysis\\UncoveredFileAnalyser' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/StaticAnalysis/UncoveredFileAnalyser.php', + 'SebastianBergmann\\CodeCoverage\\TestIdMissingException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/TestIdMissingException.php', 'SebastianBergmann\\CodeCoverage\\UnintentionallyCoveredCodeException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/UnintentionallyCoveredCodeException.php', - 'SebastianBergmann\\CodeCoverage\\Util' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Util.php', 'SebastianBergmann\\CodeCoverage\\Version' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Version.php', + 'SebastianBergmann\\CodeCoverage\\XmlException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/XmlException.php', 'SebastianBergmann\\CodeUnitReverseLookup\\Wizard' => __DIR__ . '/..' . '/sebastian/code-unit-reverse-lookup/src/Wizard.php', + 'SebastianBergmann\\CodeUnit\\ClassMethodUnit' => __DIR__ . '/..' . '/sebastian/code-unit/src/ClassMethodUnit.php', + 'SebastianBergmann\\CodeUnit\\ClassUnit' => __DIR__ . '/..' . '/sebastian/code-unit/src/ClassUnit.php', + 'SebastianBergmann\\CodeUnit\\CodeUnit' => __DIR__ . '/..' . '/sebastian/code-unit/src/CodeUnit.php', + 'SebastianBergmann\\CodeUnit\\CodeUnitCollection' => __DIR__ . '/..' . '/sebastian/code-unit/src/CodeUnitCollection.php', + 'SebastianBergmann\\CodeUnit\\CodeUnitCollectionIterator' => __DIR__ . '/..' . '/sebastian/code-unit/src/CodeUnitCollectionIterator.php', + 'SebastianBergmann\\CodeUnit\\Exception' => __DIR__ . '/..' . '/sebastian/code-unit/src/exceptions/Exception.php', + 'SebastianBergmann\\CodeUnit\\FunctionUnit' => __DIR__ . '/..' . '/sebastian/code-unit/src/FunctionUnit.php', + 'SebastianBergmann\\CodeUnit\\InterfaceMethodUnit' => __DIR__ . '/..' . '/sebastian/code-unit/src/InterfaceMethodUnit.php', + 'SebastianBergmann\\CodeUnit\\InterfaceUnit' => __DIR__ . '/..' . '/sebastian/code-unit/src/InterfaceUnit.php', + 'SebastianBergmann\\CodeUnit\\InvalidCodeUnitException' => __DIR__ . '/..' . '/sebastian/code-unit/src/exceptions/InvalidCodeUnitException.php', + 'SebastianBergmann\\CodeUnit\\Mapper' => __DIR__ . '/..' . '/sebastian/code-unit/src/Mapper.php', + 'SebastianBergmann\\CodeUnit\\NoTraitException' => __DIR__ . '/..' . '/sebastian/code-unit/src/exceptions/NoTraitException.php', + 'SebastianBergmann\\CodeUnit\\ReflectionException' => __DIR__ . '/..' . '/sebastian/code-unit/src/exceptions/ReflectionException.php', + 'SebastianBergmann\\CodeUnit\\TraitMethodUnit' => __DIR__ . '/..' . '/sebastian/code-unit/src/TraitMethodUnit.php', + 'SebastianBergmann\\CodeUnit\\TraitUnit' => __DIR__ . '/..' . '/sebastian/code-unit/src/TraitUnit.php', 'SebastianBergmann\\Comparator\\ArrayComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/ArrayComparator.php', 'SebastianBergmann\\Comparator\\Comparator' => __DIR__ . '/..' . '/sebastian/comparator/src/Comparator.php', 'SebastianBergmann\\Comparator\\ComparisonFailure' => __DIR__ . '/..' . '/sebastian/comparator/src/ComparisonFailure.php', 'SebastianBergmann\\Comparator\\DOMNodeComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/DOMNodeComparator.php', 'SebastianBergmann\\Comparator\\DateTimeComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/DateTimeComparator.php', 'SebastianBergmann\\Comparator\\DoubleComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/DoubleComparator.php', + 'SebastianBergmann\\Comparator\\Exception' => __DIR__ . '/..' . '/sebastian/comparator/src/exceptions/Exception.php', 'SebastianBergmann\\Comparator\\ExceptionComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/ExceptionComparator.php', 'SebastianBergmann\\Comparator\\Factory' => __DIR__ . '/..' . '/sebastian/comparator/src/Factory.php', 'SebastianBergmann\\Comparator\\MockObjectComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/MockObjectComparator.php', 'SebastianBergmann\\Comparator\\NumericComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/NumericComparator.php', 'SebastianBergmann\\Comparator\\ObjectComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/ObjectComparator.php', 'SebastianBergmann\\Comparator\\ResourceComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/ResourceComparator.php', + 'SebastianBergmann\\Comparator\\RuntimeException' => __DIR__ . '/..' . '/sebastian/comparator/src/exceptions/RuntimeException.php', 'SebastianBergmann\\Comparator\\ScalarComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/ScalarComparator.php', 'SebastianBergmann\\Comparator\\SplObjectStorageComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/SplObjectStorageComparator.php', 'SebastianBergmann\\Comparator\\TypeComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/TypeComparator.php', + 'SebastianBergmann\\Complexity\\Calculator' => __DIR__ . '/..' . '/sebastian/complexity/src/Calculator.php', + 'SebastianBergmann\\Complexity\\Complexity' => __DIR__ . '/..' . '/sebastian/complexity/src/Complexity/Complexity.php', + 'SebastianBergmann\\Complexity\\ComplexityCalculatingVisitor' => __DIR__ . '/..' . '/sebastian/complexity/src/Visitor/ComplexityCalculatingVisitor.php', + 'SebastianBergmann\\Complexity\\ComplexityCollection' => __DIR__ . '/..' . '/sebastian/complexity/src/Complexity/ComplexityCollection.php', + 'SebastianBergmann\\Complexity\\ComplexityCollectionIterator' => __DIR__ . '/..' . '/sebastian/complexity/src/Complexity/ComplexityCollectionIterator.php', + 'SebastianBergmann\\Complexity\\CyclomaticComplexityCalculatingVisitor' => __DIR__ . '/..' . '/sebastian/complexity/src/Visitor/CyclomaticComplexityCalculatingVisitor.php', + 'SebastianBergmann\\Complexity\\Exception' => __DIR__ . '/..' . '/sebastian/complexity/src/Exception/Exception.php', + 'SebastianBergmann\\Complexity\\RuntimeException' => __DIR__ . '/..' . '/sebastian/complexity/src/Exception/RuntimeException.php', 'SebastianBergmann\\Diff\\Chunk' => __DIR__ . '/..' . '/sebastian/diff/src/Chunk.php', 'SebastianBergmann\\Diff\\ConfigurationException' => __DIR__ . '/..' . '/sebastian/diff/src/Exception/ConfigurationException.php', 'SebastianBergmann\\Diff\\Diff' => __DIR__ . '/..' . '/sebastian/diff/src/Diff.php', @@ -4578,12 +4996,23 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'SebastianBergmann\\FileIterator\\Facade' => __DIR__ . '/..' . '/phpunit/php-file-iterator/src/Facade.php', 'SebastianBergmann\\FileIterator\\Factory' => __DIR__ . '/..' . '/phpunit/php-file-iterator/src/Factory.php', 'SebastianBergmann\\FileIterator\\Iterator' => __DIR__ . '/..' . '/phpunit/php-file-iterator/src/Iterator.php', - 'SebastianBergmann\\GlobalState\\Blacklist' => __DIR__ . '/..' . '/sebastian/global-state/src/Blacklist.php', 'SebastianBergmann\\GlobalState\\CodeExporter' => __DIR__ . '/..' . '/sebastian/global-state/src/CodeExporter.php', 'SebastianBergmann\\GlobalState\\Exception' => __DIR__ . '/..' . '/sebastian/global-state/src/exceptions/Exception.php', + 'SebastianBergmann\\GlobalState\\ExcludeList' => __DIR__ . '/..' . '/sebastian/global-state/src/ExcludeList.php', 'SebastianBergmann\\GlobalState\\Restorer' => __DIR__ . '/..' . '/sebastian/global-state/src/Restorer.php', 'SebastianBergmann\\GlobalState\\RuntimeException' => __DIR__ . '/..' . '/sebastian/global-state/src/exceptions/RuntimeException.php', 'SebastianBergmann\\GlobalState\\Snapshot' => __DIR__ . '/..' . '/sebastian/global-state/src/Snapshot.php', + 'SebastianBergmann\\Invoker\\Exception' => __DIR__ . '/..' . '/phpunit/php-invoker/src/exceptions/Exception.php', + 'SebastianBergmann\\Invoker\\Invoker' => __DIR__ . '/..' . '/phpunit/php-invoker/src/Invoker.php', + 'SebastianBergmann\\Invoker\\ProcessControlExtensionNotLoadedException' => __DIR__ . '/..' . '/phpunit/php-invoker/src/exceptions/ProcessControlExtensionNotLoadedException.php', + 'SebastianBergmann\\Invoker\\TimeoutException' => __DIR__ . '/..' . '/phpunit/php-invoker/src/exceptions/TimeoutException.php', + 'SebastianBergmann\\LinesOfCode\\Counter' => __DIR__ . '/..' . '/sebastian/lines-of-code/src/Counter.php', + 'SebastianBergmann\\LinesOfCode\\Exception' => __DIR__ . '/..' . '/sebastian/lines-of-code/src/Exception/Exception.php', + 'SebastianBergmann\\LinesOfCode\\IllogicalValuesException' => __DIR__ . '/..' . '/sebastian/lines-of-code/src/Exception/IllogicalValuesException.php', + 'SebastianBergmann\\LinesOfCode\\LineCountingVisitor' => __DIR__ . '/..' . '/sebastian/lines-of-code/src/LineCountingVisitor.php', + 'SebastianBergmann\\LinesOfCode\\LinesOfCode' => __DIR__ . '/..' . '/sebastian/lines-of-code/src/LinesOfCode.php', + 'SebastianBergmann\\LinesOfCode\\NegativeValueException' => __DIR__ . '/..' . '/sebastian/lines-of-code/src/Exception/NegativeValueException.php', + 'SebastianBergmann\\LinesOfCode\\RuntimeException' => __DIR__ . '/..' . '/sebastian/lines-of-code/src/Exception/RuntimeException.php', 'SebastianBergmann\\ObjectEnumerator\\Enumerator' => __DIR__ . '/..' . '/sebastian/object-enumerator/src/Enumerator.php', 'SebastianBergmann\\ObjectEnumerator\\Exception' => __DIR__ . '/..' . '/sebastian/object-enumerator/src/Exception.php', 'SebastianBergmann\\ObjectEnumerator\\InvalidArgumentException' => __DIR__ . '/..' . '/sebastian/object-enumerator/src/InvalidArgumentException.php', @@ -4594,19 +5023,30 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'SebastianBergmann\\RecursionContext\\Exception' => __DIR__ . '/..' . '/sebastian/recursion-context/src/Exception.php', 'SebastianBergmann\\RecursionContext\\InvalidArgumentException' => __DIR__ . '/..' . '/sebastian/recursion-context/src/InvalidArgumentException.php', 'SebastianBergmann\\ResourceOperations\\ResourceOperations' => __DIR__ . '/..' . '/sebastian/resource-operations/src/ResourceOperations.php', - 'SebastianBergmann\\Timer\\Exception' => __DIR__ . '/..' . '/phpunit/php-timer/src/Exception.php', - 'SebastianBergmann\\Timer\\RuntimeException' => __DIR__ . '/..' . '/phpunit/php-timer/src/RuntimeException.php', + 'SebastianBergmann\\Template\\Exception' => __DIR__ . '/..' . '/phpunit/php-text-template/src/exceptions/Exception.php', + 'SebastianBergmann\\Template\\InvalidArgumentException' => __DIR__ . '/..' . '/phpunit/php-text-template/src/exceptions/InvalidArgumentException.php', + 'SebastianBergmann\\Template\\RuntimeException' => __DIR__ . '/..' . '/phpunit/php-text-template/src/exceptions/RuntimeException.php', + 'SebastianBergmann\\Template\\Template' => __DIR__ . '/..' . '/phpunit/php-text-template/src/Template.php', + 'SebastianBergmann\\Timer\\Duration' => __DIR__ . '/..' . '/phpunit/php-timer/src/Duration.php', + 'SebastianBergmann\\Timer\\Exception' => __DIR__ . '/..' . '/phpunit/php-timer/src/exceptions/Exception.php', + 'SebastianBergmann\\Timer\\NoActiveTimerException' => __DIR__ . '/..' . '/phpunit/php-timer/src/exceptions/NoActiveTimerException.php', + 'SebastianBergmann\\Timer\\ResourceUsageFormatter' => __DIR__ . '/..' . '/phpunit/php-timer/src/ResourceUsageFormatter.php', + 'SebastianBergmann\\Timer\\TimeSinceStartOfRequestNotAvailableException' => __DIR__ . '/..' . '/phpunit/php-timer/src/exceptions/TimeSinceStartOfRequestNotAvailableException.php', 'SebastianBergmann\\Timer\\Timer' => __DIR__ . '/..' . '/phpunit/php-timer/src/Timer.php', 'SebastianBergmann\\Type\\CallableType' => __DIR__ . '/..' . '/sebastian/type/src/CallableType.php', 'SebastianBergmann\\Type\\Exception' => __DIR__ . '/..' . '/sebastian/type/src/exception/Exception.php', 'SebastianBergmann\\Type\\GenericObjectType' => __DIR__ . '/..' . '/sebastian/type/src/GenericObjectType.php', 'SebastianBergmann\\Type\\IterableType' => __DIR__ . '/..' . '/sebastian/type/src/IterableType.php', + 'SebastianBergmann\\Type\\MixedType' => __DIR__ . '/..' . '/sebastian/type/src/MixedType.php', 'SebastianBergmann\\Type\\NullType' => __DIR__ . '/..' . '/sebastian/type/src/NullType.php', 'SebastianBergmann\\Type\\ObjectType' => __DIR__ . '/..' . '/sebastian/type/src/ObjectType.php', + 'SebastianBergmann\\Type\\ReflectionMapper' => __DIR__ . '/..' . '/sebastian/type/src/ReflectionMapper.php', 'SebastianBergmann\\Type\\RuntimeException' => __DIR__ . '/..' . '/sebastian/type/src/exception/RuntimeException.php', 'SebastianBergmann\\Type\\SimpleType' => __DIR__ . '/..' . '/sebastian/type/src/SimpleType.php', + 'SebastianBergmann\\Type\\StaticType' => __DIR__ . '/..' . '/sebastian/type/src/StaticType.php', 'SebastianBergmann\\Type\\Type' => __DIR__ . '/..' . '/sebastian/type/src/Type.php', 'SebastianBergmann\\Type\\TypeName' => __DIR__ . '/..' . '/sebastian/type/src/TypeName.php', + 'SebastianBergmann\\Type\\UnionType' => __DIR__ . '/..' . '/sebastian/type/src/UnionType.php', 'SebastianBergmann\\Type\\UnknownType' => __DIR__ . '/..' . '/sebastian/type/src/UnknownType.php', 'SebastianBergmann\\Type\\VoidType' => __DIR__ . '/..' . '/sebastian/type/src/VoidType.php', 'SebastianBergmann\\Version' => __DIR__ . '/..' . '/sebastian/version/src/Version.php', @@ -5398,7 +5838,6 @@ class ComposerStaticInitc3f953f8a7291d41a76e1664339777c9 'Tests\\Feature\\ExampleTest' => __DIR__ . '/../..' . '/tests/Feature/ExampleTest.php', 'Tests\\TestCase' => __DIR__ . '/../..' . '/tests/TestCase.php', 'Tests\\Unit\\ExampleTest' => __DIR__ . '/../..' . '/tests/Unit/ExampleTest.php', - 'Text_Template' => __DIR__ . '/..' . '/phpunit/php-text-template/src/Template.php', 'TheSeer\\Tokenizer\\Exception' => __DIR__ . '/..' . '/theseer/tokenizer/src/Exception.php', 'TheSeer\\Tokenizer\\NamespaceUri' => __DIR__ . '/..' . '/theseer/tokenizer/src/NamespaceUri.php', 'TheSeer\\Tokenizer\\NamespaceUriException' => __DIR__ . '/..' . '/theseer/tokenizer/src/NamespaceUriException.php', diff --git a/vendor/composer/installed.json b/vendor/composer/installed.json index 0aef008c4..1f4107485 100644 --- a/vendor/composer/installed.json +++ b/vendor/composer/installed.json @@ -127,68 +127,6 @@ ], "install-path": "../brick/math" }, - { - "name": "cakephp/chronos", - "version": "2.1.2", - "version_normalized": "2.1.2.0", - "source": { - "type": "git", - "url": "https://github.com/cakephp/chronos.git", - "reference": "1d187c71587c97520c00491f626e0f255144953e" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/cakephp/chronos/zipball/1d187c71587c97520c00491f626e0f255144953e", - "reference": "1d187c71587c97520c00491f626e0f255144953e", - "shasum": "" - }, - "require": { - "php": ">=7.2" - }, - "require-dev": { - "cakephp/cakephp-codesniffer": "^4.0", - "phpunit/phpunit": "^8.0 || ^9.0" - }, - "time": "2021-04-07T01:06:46+00:00", - "type": "library", - "installation-source": "dist", - "autoload": { - "psr-4": { - "Cake\\Chronos\\": "src/" - }, - "files": [ - "src/carbon_compat.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Brian Nesbitt", - "email": "brian@nesbot.com", - "homepage": "http://nesbot.com" - }, - { - "name": "The CakePHP Team", - "homepage": "http://cakephp.org" - } - ], - "description": "A simple API extension for DateTime.", - "homepage": "http://cakephp.org", - "keywords": [ - "date", - "datetime", - "time" - ], - "support": { - "irc": "irc://irc.freenode.org/cakephp", - "issues": "https://github.com/cakephp/chronos/issues", - "source": "https://github.com/cakephp/chronos" - }, - "install-path": "../cakephp/chronos" - }, { "name": "doctrine/inflector", "version": "2.0.3", @@ -408,32 +346,34 @@ }, { "name": "dragonmantank/cron-expression", - "version": "v2.3.1", - "version_normalized": "2.3.1.0", + "version": "v3.1.0", + "version_normalized": "3.1.0.0", "source": { "type": "git", "url": "https://github.com/dragonmantank/cron-expression.git", - "reference": "65b2d8ee1f10915efb3b55597da3404f096acba2" + "reference": "7a8c6e56ab3ffcc538d05e8155bb42269abf1a0c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/dragonmantank/cron-expression/zipball/65b2d8ee1f10915efb3b55597da3404f096acba2", - "reference": "65b2d8ee1f10915efb3b55597da3404f096acba2", + "url": "https://api.github.com/repos/dragonmantank/cron-expression/zipball/7a8c6e56ab3ffcc538d05e8155bb42269abf1a0c", + "reference": "7a8c6e56ab3ffcc538d05e8155bb42269abf1a0c", "shasum": "" }, "require": { - "php": "^7.0|^8.0" + "php": "^7.2|^8.0", + "webmozart/assert": "^1.7.0" + }, + "replace": { + "mtdowling/cron-expression": "^1.0" }, "require-dev": { - "phpunit/phpunit": "^6.4|^7.0|^8.0|^9.0" + "phpstan/extension-installer": "^1.0", + "phpstan/phpstan": "^0.12", + "phpstan/phpstan-webmozart-assert": "^0.12.7", + "phpunit/phpunit": "^7.0|^8.0|^9.0" }, - "time": "2020-10-13T00:52:37+00:00", + "time": "2020-11-24T19:55:57+00:00", "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.3-dev" - } - }, "installation-source": "dist", "autoload": { "psr-4": { @@ -445,11 +385,6 @@ "MIT" ], "authors": [ - { - "name": "Michael Dowling", - "email": "mtdowling@gmail.com", - "homepage": "https://github.com/mtdowling" - }, { "name": "Chris Tankersley", "email": "chris@ctankersley.com", @@ -461,6 +396,16 @@ "cron", "schedule" ], + "support": { + "issues": "https://github.com/dragonmantank/cron-expression/issues", + "source": "https://github.com/dragonmantank/cron-expression/tree/v3.1.0" + }, + "funding": [ + { + "url": "https://github.com/dragonmantank", + "type": "github" + } + ], "install-path": "../dragonmantank/cron-expression" }, { @@ -536,17 +481,17 @@ }, { "name": "eveseat/eseye", - "version": "2.3.2", - "version_normalized": "2.3.2.0", + "version": "2.4.0", + "version_normalized": "2.4.0.0", "source": { "type": "git", "url": "https://github.com/eveseat/eseye.git", - "reference": "69a0180f1727369614971fe377a1a8b2301c505d" + "reference": "b9d6753ccad9edce2bed6c91142f62eaebe24a8c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/eveseat/eseye/zipball/69a0180f1727369614971fe377a1a8b2301c505d", - "reference": "69a0180f1727369614971fe377a1a8b2301c505d", + "url": "https://api.github.com/repos/eveseat/eseye/zipball/b9d6753ccad9edce2bed6c91142f62eaebe24a8c", + "reference": "b9d6753ccad9edce2bed6c91142f62eaebe24a8c", "shasum": "" }, "require": { @@ -554,7 +499,7 @@ "ext-json": "*", "ext-mbstring": "*", "ext-openssl": "*", - "guzzlehttp/guzzle": "^6.2", + "guzzlehttp/guzzle": "^6.2|^7.0", "monolog/monolog": "^2.0", "nesbot/carbon": "^2.0", "php": ">= 7.2", @@ -566,10 +511,11 @@ }, "require-dev": { "codeclimate/php-test-reporter": "dev-master", + "m6web/redis-mock": "^5.0", "mikey179/vfsstream": "~1", - "phpunit/phpunit": "^5.7" + "phpunit/phpunit": "^8.0|^9.0" }, - "time": "2021-04-04T20:29:19+00:00", + "time": "2021-05-19T05:42:25+00:00", "bin": [ "bin/tokengenerator" ], @@ -596,7 +542,7 @@ "description": "A Standalone PHP ESI (EVE Swagger Interface) Client Library", "support": { "issues": "https://github.com/eveseat/eseye/issues", - "source": "https://github.com/eveseat/eseye/tree/2.3.2" + "source": "https://github.com/eveseat/eseye/tree/2.4.0" }, "install-path": "../eveseat/eseye" }, @@ -920,40 +866,116 @@ "install-path": "../fzaninotto/faker" }, { - "name": "guzzlehttp/guzzle", - "version": "6.5.5", - "version_normalized": "6.5.5.0", + "name": "graham-campbell/result-type", + "version": "v1.0.1", + "version_normalized": "1.0.1.0", "source": { "type": "git", - "url": "https://github.com/guzzle/guzzle.git", - "reference": "9d4290de1cfd701f38099ef7e183b64b4b7b0c5e" + "url": "https://github.com/GrahamCampbell/Result-Type.git", + "reference": "7e279d2cd5d7fbb156ce46daada972355cea27bb" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/guzzle/zipball/9d4290de1cfd701f38099ef7e183b64b4b7b0c5e", - "reference": "9d4290de1cfd701f38099ef7e183b64b4b7b0c5e", + "url": "https://api.github.com/repos/GrahamCampbell/Result-Type/zipball/7e279d2cd5d7fbb156ce46daada972355cea27bb", + "reference": "7e279d2cd5d7fbb156ce46daada972355cea27bb", + "shasum": "" + }, + "require": { + "php": "^7.0|^8.0", + "phpoption/phpoption": "^1.7.3" + }, + "require-dev": { + "phpunit/phpunit": "^6.5|^7.5|^8.5|^9.0" + }, + "time": "2020-04-13T13:17:36+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "GrahamCampbell\\ResultType\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Graham Campbell", + "email": "graham@alt-three.com" + } + ], + "description": "An Implementation Of The Result Type", + "keywords": [ + "Graham Campbell", + "GrahamCampbell", + "Result Type", + "Result-Type", + "result" + ], + "support": { + "issues": "https://github.com/GrahamCampbell/Result-Type/issues", + "source": "https://github.com/GrahamCampbell/Result-Type/tree/v1.0.1" + }, + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/graham-campbell/result-type", + "type": "tidelift" + } + ], + "install-path": "../graham-campbell/result-type" + }, + { + "name": "guzzlehttp/guzzle", + "version": "7.3.0", + "version_normalized": "7.3.0.0", + "source": { + "type": "git", + "url": "https://github.com/guzzle/guzzle.git", + "reference": "7008573787b430c1c1f650e3722d9bba59967628" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/guzzle/guzzle/zipball/7008573787b430c1c1f650e3722d9bba59967628", + "reference": "7008573787b430c1c1f650e3722d9bba59967628", "shasum": "" }, "require": { "ext-json": "*", - "guzzlehttp/promises": "^1.0", - "guzzlehttp/psr7": "^1.6.1", - "php": ">=5.5", - "symfony/polyfill-intl-idn": "^1.17.0" + "guzzlehttp/promises": "^1.4", + "guzzlehttp/psr7": "^1.7 || ^2.0", + "php": "^7.2.5 || ^8.0", + "psr/http-client": "^1.0" + }, + "provide": { + "psr/http-client-implementation": "1.0" }, "require-dev": { + "bamarni/composer-bin-plugin": "^1.4.1", "ext-curl": "*", - "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.4 || ^7.0", + "php-http/client-integration-tests": "^3.0", + "phpunit/phpunit": "^8.5.5 || ^9.3.5", "psr/log": "^1.1" }, "suggest": { + "ext-curl": "Required for CURL handler support", + "ext-intl": "Required for Internationalized Domain Name (IDN) support", "psr/log": "Required for using the Log middleware" }, - "time": "2020-06-16T21:01:06+00:00", + "time": "2021-03-23T11:33:13+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "6.5-dev" + "dev-master": "7.3-dev" } }, "installation-source": "dist", @@ -974,6 +996,11 @@ "name": "Michael Dowling", "email": "mtdowling@gmail.com", "homepage": "https://github.com/mtdowling" + }, + { + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com", + "homepage": "https://sagikazarmark.hu" } ], "description": "Guzzle is a PHP HTTP client library", @@ -984,9 +1011,33 @@ "framework", "http", "http client", + "psr-18", + "psr-7", "rest", "web service" ], + "support": { + "issues": "https://github.com/guzzle/guzzle/issues", + "source": "https://github.com/guzzle/guzzle/tree/7.3.0" + }, + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://github.com/Nyholm", + "type": "github" + }, + { + "url": "https://github.com/alexeyshockov", + "type": "github" + }, + { + "url": "https://github.com/gmponos", + "type": "github" + } + ], "install-path": "../guzzlehttp/guzzle" }, { @@ -1246,22 +1297,22 @@ }, { "name": "laravel/framework", - "version": "v7.30.4", - "version_normalized": "7.30.4.0", + "version": "v8.44.0", + "version_normalized": "8.44.0.0", "source": { "type": "git", "url": "https://github.com/laravel/framework.git", - "reference": "9dd38140dc2924daa1a020a3d7a45f9ceff03df3" + "reference": "7b3b27dc8911ab02a69731af2ba97b5130b2ddb8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/framework/zipball/9dd38140dc2924daa1a020a3d7a45f9ceff03df3", - "reference": "9dd38140dc2924daa1a020a3d7a45f9ceff03df3", + "url": "https://api.github.com/repos/laravel/framework/zipball/7b3b27dc8911ab02a69731af2ba97b5130b2ddb8", + "reference": "7b3b27dc8911ab02a69731af2ba97b5130b2ddb8", "shasum": "" }, "require": { "doctrine/inflector": "^1.4|^2.0", - "dragonmantank/cron-expression": "^2.3.1", + "dragonmantank/cron-expression": "^3.0.2", "egulias/email-validator": "^2.1.10", "ext-json": "*", "ext-mbstring": "*", @@ -1271,23 +1322,22 @@ "monolog/monolog": "^2.0", "nesbot/carbon": "^2.31", "opis/closure": "^3.6", - "php": "^7.2.5|^8.0", + "php": "^7.3|^8.0", "psr/container": "^1.0", "psr/simple-cache": "^1.0", - "ramsey/uuid": "^3.7|^4.0", + "ramsey/uuid": "^4.0", "swiftmailer/swiftmailer": "^6.0", - "symfony/console": "^5.0", - "symfony/error-handler": "^5.0", - "symfony/finder": "^5.0", - "symfony/http-foundation": "^5.0", - "symfony/http-kernel": "^5.0", - "symfony/mime": "^5.0", - "symfony/polyfill-php73": "^1.17", - "symfony/process": "^5.0", - "symfony/routing": "^5.0", - "symfony/var-dumper": "^5.0", + "symfony/console": "^5.1.4", + "symfony/error-handler": "^5.1.4", + "symfony/finder": "^5.1.4", + "symfony/http-foundation": "^5.1.4", + "symfony/http-kernel": "^5.1.4", + "symfony/mime": "^5.1.4", + "symfony/process": "^5.1.4", + "symfony/routing": "^5.1.4", + "symfony/var-dumper": "^5.1.4", "tijsverkoyen/css-to-inline-styles": "^2.2.2", - "vlucas/phpdotenv": "^4.0", + "vlucas/phpdotenv": "^5.2", "voku/portable-ascii": "^1.4.8" }, "conflict": { @@ -1301,6 +1351,7 @@ "illuminate/broadcasting": "self.version", "illuminate/bus": "self.version", "illuminate/cache": "self.version", + "illuminate/collections": "self.version", "illuminate/config": "self.version", "illuminate/console": "self.version", "illuminate/container": "self.version", @@ -1313,6 +1364,7 @@ "illuminate/hashing": "self.version", "illuminate/http": "self.version", "illuminate/log": "self.version", + "illuminate/macroable": "self.version", "illuminate/mail": "self.version", "illuminate/notifications": "self.version", "illuminate/pagination": "self.version", @@ -1329,21 +1381,21 @@ }, "require-dev": { "aws/aws-sdk-php": "^3.155", - "doctrine/dbal": "^2.6", + "doctrine/dbal": "^2.6|^3.0", "filp/whoops": "^2.8", - "guzzlehttp/guzzle": "^6.3.1|^7.0.1", + "guzzlehttp/guzzle": "^6.5.5|^7.0.1", "league/flysystem-cached-adapter": "^1.0", - "mockery/mockery": "~1.3.3|^1.4.2", - "moontoast/math": "^1.1", - "orchestra/testbench-core": "^5.8", + "mockery/mockery": "^1.4.2", + "orchestra/testbench-core": "^6.8", "pda/pheanstalk": "^4.0", - "phpunit/phpunit": "^8.4|^9.3.3", + "phpunit/phpunit": "^8.5.8|^9.3.3", "predis/predis": "^1.1.1", - "symfony/cache": "^5.0" + "symfony/cache": "^5.1.4" }, "suggest": { "aws/aws-sdk-php": "Required to use the SQS queue driver, DynamoDb failed job storage and SES mail driver (^3.155).", - "doctrine/dbal": "Required to rename columns and drop SQLite columns (^2.6).", + "brianium/paratest": "Required to run tests in parallel (^6.0).", + "doctrine/dbal": "Required to rename columns and drop SQLite columns (^2.6|^3.0).", "ext-ftp": "Required to use the Flysystem FTP driver.", "ext-gd": "Required to use Illuminate\\Http\\Testing\\FileFactory::image().", "ext-memcached": "Required to use the memcache cache driver.", @@ -1352,39 +1404,44 @@ "ext-redis": "Required to use the Redis cache and queue drivers (^4.0|^5.0).", "fakerphp/faker": "Required to use the eloquent factory builder (^1.9.1).", "filp/whoops": "Required for friendly error pages in development (^2.8).", - "guzzlehttp/guzzle": "Required to use the HTTP Client, Mailgun mail driver and the ping methods on schedules (^6.3.1|^7.0.1).", + "guzzlehttp/guzzle": "Required to use the HTTP Client, Mailgun mail driver and the ping methods on schedules (^6.5.5|^7.0.1).", "laravel/tinker": "Required to use the tinker console command (^2.0).", "league/flysystem-aws-s3-v3": "Required to use the Flysystem S3 driver (^1.0).", "league/flysystem-cached-adapter": "Required to use the Flysystem cache (^1.0).", "league/flysystem-sftp": "Required to use the Flysystem SFTP driver (^1.0).", - "mockery/mockery": "Required to use mocking (~1.3.3|^1.4.2).", - "moontoast/math": "Required to use ordered UUIDs (^1.1).", + "mockery/mockery": "Required to use mocking (^1.4.2).", "nyholm/psr7": "Required to use PSR-7 bridging features (^1.2).", "pda/pheanstalk": "Required to use the beanstalk queue driver (^4.0).", - "phpunit/phpunit": "Required to use assertions and run tests (^8.4|^9.3.3).", + "phpunit/phpunit": "Required to use assertions and run tests (^8.5.8|^9.3.3).", "predis/predis": "Required to use the predis connector (^1.1.2).", "psr/http-message": "Required to allow Storage::put to accept a StreamInterface (^1.0).", - "pusher/pusher-php-server": "Required to use the Pusher broadcast driver (^4.0).", - "symfony/cache": "Required to PSR-6 cache bridge (^5.0).", - "symfony/filesystem": "Required to create relative storage directory symbolic links (^5.0).", + "pusher/pusher-php-server": "Required to use the Pusher broadcast driver (^4.0|^5.0|^6.0).", + "symfony/cache": "Required to PSR-6 cache bridge (^5.1.4).", + "symfony/filesystem": "Required to enable support for relative symbolic links (^5.1.4).", "symfony/psr-http-message-bridge": "Required to use PSR-7 bridging features (^2.0).", "wildbit/swiftmailer-postmark": "Required to use Postmark mail driver (^3.0)." }, - "time": "2021-01-21T14:10:48+00:00", + "time": "2021-05-27T16:46:06+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "7.x-dev" + "dev-master": "8.x-dev" } }, "installation-source": "dist", "autoload": { "files": [ + "src/Illuminate/Collections/helpers.php", + "src/Illuminate/Events/functions.php", "src/Illuminate/Foundation/helpers.php", "src/Illuminate/Support/helpers.php" ], "psr-4": { - "Illuminate\\": "src/Illuminate/" + "Illuminate\\": "src/Illuminate/", + "Illuminate\\Support\\": [ + "src/Illuminate/Macroable/", + "src/Illuminate/Collections/" + ] } }, "notification-url": "https://packagist.org/downloads/", @@ -1470,47 +1527,47 @@ }, { "name": "laravel/horizon", - "version": "v4.3.5", - "version_normalized": "4.3.5.0", + "version": "v5.7.8", + "version_normalized": "5.7.8.0", "source": { "type": "git", "url": "https://github.com/laravel/horizon.git", - "reference": "b3fba0daaaaf5e84197b06dd25f3b27bb7301171" + "reference": "2b5628b598c813650458dc7e4afacb500d72ff9a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/horizon/zipball/b3fba0daaaaf5e84197b06dd25f3b27bb7301171", - "reference": "b3fba0daaaaf5e84197b06dd25f3b27bb7301171", + "url": "https://api.github.com/repos/laravel/horizon/zipball/2b5628b598c813650458dc7e4afacb500d72ff9a", + "reference": "2b5628b598c813650458dc7e4afacb500d72ff9a", "shasum": "" }, "require": { - "cakephp/chronos": "^2.0", "ext-json": "*", "ext-pcntl": "*", "ext-posix": "*", - "illuminate/contracts": "^7.0", - "illuminate/queue": "^7.0", - "illuminate/support": "^7.0", - "php": "^7.2", - "ramsey/uuid": "^3.5|^4.0", + "illuminate/contracts": "^8.17", + "illuminate/queue": "^8.17", + "illuminate/support": "^8.17", + "nesbot/carbon": "^2.17", + "php": "^7.3|^8.0", + "ramsey/uuid": "^4.0", "symfony/error-handler": "^5.0", "symfony/process": "^5.0" }, "require-dev": { "mockery/mockery": "^1.0", - "orchestra/testbench": "^5.0", - "phpunit/phpunit": "^8.0", + "orchestra/testbench": "^6.0", + "phpunit/phpunit": "^9.0", "predis/predis": "^1.1" }, "suggest": { "ext-redis": "Required to use the Redis PHP driver.", "predis/predis": "Required when not using the Redis PHP driver (^1.1)." }, - "time": "2020-09-08T13:19:23+00:00", + "time": "2021-05-27T12:07:58+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "4.x-dev" + "dev-master": "5.x-dev" }, "laravel": { "providers": [ @@ -1544,7 +1601,7 @@ ], "support": { "issues": "https://github.com/laravel/horizon/issues", - "source": "https://github.com/laravel/horizon/tree/4.x" + "source": "https://github.com/laravel/horizon/tree/v5.7.8" }, "install-path": "../laravel/horizon" }, @@ -1622,28 +1679,32 @@ }, { "name": "laravel/ui", - "version": "v2.5.0", - "version_normalized": "2.5.0.0", + "version": "v3.3.0", + "version_normalized": "3.3.0.0", "source": { "type": "git", "url": "https://github.com/laravel/ui.git", - "reference": "d01a705763c243b07be795e9d1bb47f89260f73d" + "reference": "07d725813350c695c779382cbd6dac0ab8665537" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/ui/zipball/d01a705763c243b07be795e9d1bb47f89260f73d", - "reference": "d01a705763c243b07be795e9d1bb47f89260f73d", + "url": "https://api.github.com/repos/laravel/ui/zipball/07d725813350c695c779382cbd6dac0ab8665537", + "reference": "07d725813350c695c779382cbd6dac0ab8665537", "shasum": "" }, "require": { - "illuminate/console": "^7.0", - "illuminate/filesystem": "^7.0", - "illuminate/support": "^7.0", - "php": "^7.2.5|^8.0" + "illuminate/console": "^8.42", + "illuminate/filesystem": "^8.42", + "illuminate/support": "^8.42", + "illuminate/validation": "^8.42", + "php": "^7.3|^8.0" }, - "time": "2020-11-03T19:45:19+00:00", + "time": "2021-05-25T16:45:33+00:00", "type": "library", "extra": { + "branch-alias": { + "dev-master": "3.x-dev" + }, "laravel": { "providers": [ "Laravel\\Ui\\UiServiceProvider" @@ -1673,8 +1734,7 @@ "ui" ], "support": { - "issues": "https://github.com/laravel/ui/issues", - "source": "https://github.com/laravel/ui/tree/v2.5.0" + "source": "https://github.com/laravel/ui/tree/v3.3.0" }, "install-path": "../laravel/ui" }, @@ -2084,23 +2144,23 @@ }, { "name": "lorisleiva/cron-translator", - "version": "v0.1.1", - "version_normalized": "0.1.1.0", + "version": "v0.2.0", + "version_normalized": "0.2.0.0", "source": { "type": "git", "url": "https://github.com/lorisleiva/cron-translator.git", - "reference": "784a6f6255a4b5f45da5d89dc6ec631a14d7b011" + "reference": "764996770558dddc7def8619095391a4ec8048f2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/lorisleiva/cron-translator/zipball/784a6f6255a4b5f45da5d89dc6ec631a14d7b011", - "reference": "784a6f6255a4b5f45da5d89dc6ec631a14d7b011", + "url": "https://api.github.com/repos/lorisleiva/cron-translator/zipball/764996770558dddc7def8619095391a4ec8048f2", + "reference": "764996770558dddc7def8619095391a4ec8048f2", "shasum": "" }, "require-dev": { "phpunit/phpunit": "^8.0" }, - "time": "2020-03-01T14:44:47+00:00", + "time": "2021-01-20T10:55:08+00:00", "type": "library", "installation-source": "dist", "autoload": { @@ -2128,8 +2188,14 @@ ], "support": { "issues": "https://github.com/lorisleiva/cron-translator/issues", - "source": "https://github.com/lorisleiva/cron-translator/tree/v0.1.1" + "source": "https://github.com/lorisleiva/cron-translator/tree/v0.2.0" }, + "funding": [ + { + "url": "https://github.com/lorisleiva", + "type": "github" + } + ], "install-path": "../lorisleiva/cron-translator" }, { @@ -2359,17 +2425,17 @@ }, { "name": "nesbot/carbon", - "version": "2.48.0", - "version_normalized": "2.48.0.0", + "version": "2.48.1", + "version_normalized": "2.48.1.0", "source": { "type": "git", "url": "https://github.com/briannesbitt/Carbon.git", - "reference": "d3c447f21072766cddec3522f9468a5849a76147" + "reference": "8d1f50f1436fb4b05e7127360483dd9c6e73da16" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/d3c447f21072766cddec3522f9468a5849a76147", - "reference": "d3c447f21072766cddec3522f9468a5849a76147", + "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/8d1f50f1436fb4b05e7127360483dd9c6e73da16", + "reference": "8d1f50f1436fb4b05e7127360483dd9c6e73da16", "shasum": "" }, "require": { @@ -2388,7 +2454,7 @@ "phpunit/phpunit": "^7.5.20 || ^8.5.14", "squizlabs/php_codesniffer": "^3.4" }, - "time": "2021-05-07T10:08:30+00:00", + "time": "2021-05-26T22:08:38+00:00", "bin": [ "bin/carbon" ], @@ -2454,39 +2520,98 @@ "install-path": "../nesbot/carbon" }, { - "name": "nunomaduro/collision", - "version": "v4.3.0", - "version_normalized": "4.3.0.0", + "name": "nikic/php-parser", + "version": "v4.10.5", + "version_normalized": "4.10.5.0", "source": { "type": "git", - "url": "https://github.com/nunomaduro/collision.git", - "reference": "7c125dc2463f3e144ddc7e05e63077109508c94e" + "url": "https://github.com/nikic/PHP-Parser.git", + "reference": "4432ba399e47c66624bc73c8c0f811e5c109576f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nunomaduro/collision/zipball/7c125dc2463f3e144ddc7e05e63077109508c94e", - "reference": "7c125dc2463f3e144ddc7e05e63077109508c94e", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/4432ba399e47c66624bc73c8c0f811e5c109576f", + "reference": "4432ba399e47c66624bc73c8c0f811e5c109576f", + "shasum": "" + }, + "require": { + "ext-tokenizer": "*", + "php": ">=7.0" + }, + "require-dev": { + "ircmaxell/php-yacc": "^0.0.7", + "phpunit/phpunit": "^6.5 || ^7.0 || ^8.0 || ^9.0" + }, + "time": "2021-05-03T19:11:20+00:00", + "bin": [ + "bin/php-parse" + ], + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.9-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "PhpParser\\": "lib/PhpParser" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Nikita Popov" + } + ], + "description": "A PHP parser written in PHP", + "keywords": [ + "parser", + "php" + ], + "support": { + "issues": "https://github.com/nikic/PHP-Parser/issues", + "source": "https://github.com/nikic/PHP-Parser/tree/v4.10.5" + }, + "install-path": "../nikic/php-parser" + }, + { + "name": "nunomaduro/collision", + "version": "v5.4.0", + "version_normalized": "5.4.0.0", + "source": { + "type": "git", + "url": "https://github.com/nunomaduro/collision.git", + "reference": "41b7e9999133d5082700d31a1d0977161df8322a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/nunomaduro/collision/zipball/41b7e9999133d5082700d31a1d0977161df8322a", + "reference": "41b7e9999133d5082700d31a1d0977161df8322a", "shasum": "" }, "require": { "facade/ignition-contracts": "^1.0", - "filp/whoops": "^2.4", - "php": "^7.2.5 || ^8.0", + "filp/whoops": "^2.7.2", + "php": "^7.3 || ^8.0", "symfony/console": "^5.0" }, "require-dev": { - "facade/ignition": "^2.0", - "fideloper/proxy": "^4.2", - "friendsofphp/php-cs-fixer": "^2.16", - "fruitcake/laravel-cors": "^1.0", - "laravel/framework": "^7.0", - "laravel/tinker": "^2.0", - "nunomaduro/larastan": "^0.6", - "orchestra/testbench": "^5.0", - "phpstan/phpstan": "^0.12.3", - "phpunit/phpunit": "^8.5.1 || ^9.0" + "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" }, - "time": "2020-10-29T15:12:23+00:00", + "time": "2021-04-09T13:38:32+00:00", "type": "library", "extra": { "laravel": { @@ -3014,42 +3139,46 @@ }, { "name": "phpunit/php-code-coverage", - "version": "7.0.14", - "version_normalized": "7.0.14.0", + "version": "9.2.6", + "version_normalized": "9.2.6.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "bb7c9a210c72e4709cdde67f8b7362f672f2225c" + "reference": "f6293e1b30a2354e8428e004689671b83871edde" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/bb7c9a210c72e4709cdde67f8b7362f672f2225c", - "reference": "bb7c9a210c72e4709cdde67f8b7362f672f2225c", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/f6293e1b30a2354e8428e004689671b83871edde", + "reference": "f6293e1b30a2354e8428e004689671b83871edde", "shasum": "" }, "require": { "ext-dom": "*", + "ext-libxml": "*", "ext-xmlwriter": "*", - "php": ">=7.2", - "phpunit/php-file-iterator": "^2.0.2", - "phpunit/php-text-template": "^1.2.1", - "phpunit/php-token-stream": "^3.1.1 || ^4.0", - "sebastian/code-unit-reverse-lookup": "^1.0.1", - "sebastian/environment": "^4.2.2", - "sebastian/version": "^2.0.1", - "theseer/tokenizer": "^1.1.3" + "nikic/php-parser": "^4.10.2", + "php": ">=7.3", + "phpunit/php-file-iterator": "^3.0.3", + "phpunit/php-text-template": "^2.0.2", + "sebastian/code-unit-reverse-lookup": "^2.0.2", + "sebastian/complexity": "^2.0", + "sebastian/environment": "^5.1.2", + "sebastian/lines-of-code": "^1.0.3", + "sebastian/version": "^3.0.1", + "theseer/tokenizer": "^1.2.0" }, "require-dev": { - "phpunit/phpunit": "^8.2.2" + "phpunit/phpunit": "^9.3" }, "suggest": { - "ext-xdebug": "^2.7.2" + "ext-pcov": "*", + "ext-xdebug": "*" }, - "time": "2020-12-02T13:39:03+00:00", + "time": "2021-03-28T07:26:59+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "7.0-dev" + "dev-master": "9.2-dev" } }, "installation-source": "dist", @@ -3078,7 +3207,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/7.0.14" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.6" }, "funding": [ { @@ -3090,30 +3219,30 @@ }, { "name": "phpunit/php-file-iterator", - "version": "2.0.3", - "version_normalized": "2.0.3.0", + "version": "3.0.5", + "version_normalized": "3.0.5.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "4b49fb70f067272b659ef0174ff9ca40fdaa6357" + "reference": "aa4be8575f26070b100fccb67faabb28f21f66f8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/4b49fb70f067272b659ef0174ff9ca40fdaa6357", - "reference": "4b49fb70f067272b659ef0174ff9ca40fdaa6357", + "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/aa4be8575f26070b100fccb67faabb28f21f66f8", + "reference": "aa4be8575f26070b100fccb67faabb28f21f66f8", "shasum": "" }, "require": { - "php": ">=7.1" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^8.5" + "phpunit/phpunit": "^9.3" }, - "time": "2020-11-30T08:25:21+00:00", + "time": "2020-09-28T05:57:25+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "3.0-dev" } }, "installation-source": "dist", @@ -3139,28 +3268,112 @@ "filesystem", "iterator" ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-file-iterator/issues", + "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/3.0.5" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], "install-path": "../phpunit/php-file-iterator" }, { - "name": "phpunit/php-text-template", - "version": "1.2.1", - "version_normalized": "1.2.1.0", + "name": "phpunit/php-invoker", + "version": "3.1.1", + "version_normalized": "3.1.1.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/php-text-template.git", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686" + "url": "https://github.com/sebastianbergmann/php-invoker.git", + "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/31f8b717e51d9a2afca6c9f046f5d69fc27c8686", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686", + "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/5a10147d0aaf65b58940a0b72f71c9ac0423cc67", + "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=7.3" }, - "time": "2015-06-21T13:50:34+00:00", + "require-dev": { + "ext-pcntl": "*", + "phpunit/phpunit": "^9.3" + }, + "suggest": { + "ext-pcntl": "*" + }, + "time": "2020-09-28T05:58:55+00:00", "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.1-dev" + } + }, + "installation-source": "dist", + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Invoke callables with a timeout", + "homepage": "https://github.com/sebastianbergmann/php-invoker/", + "keywords": [ + "process" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-invoker/issues", + "source": "https://github.com/sebastianbergmann/php-invoker/tree/3.1.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "install-path": "../phpunit/php-invoker" + }, + { + "name": "phpunit/php-text-template", + "version": "2.0.4", + "version_normalized": "2.0.4.0", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-text-template.git", + "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", + "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "time": "2020-10-26T05:33:50+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" + } + }, "installation-source": "dist", "autoload": { "classmap": [ @@ -3183,34 +3396,44 @@ "keywords": [ "template" ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-text-template/issues", + "source": "https://github.com/sebastianbergmann/php-text-template/tree/2.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], "install-path": "../phpunit/php-text-template" }, { "name": "phpunit/php-timer", - "version": "2.1.3", - "version_normalized": "2.1.3.0", + "version": "5.0.3", + "version_normalized": "5.0.3.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-timer.git", - "reference": "2454ae1765516d20c4ffe103d85a58a9a3bd5662" + "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/2454ae1765516d20c4ffe103d85a58a9a3bd5662", - "reference": "2454ae1765516d20c4ffe103d85a58a9a3bd5662", + "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", + "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", "shasum": "" }, "require": { - "php": ">=7.1" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^8.5" + "phpunit/phpunit": "^9.3" }, - "time": "2020-11-30T08:20:02+00:00", + "time": "2020-10-26T13:16:10+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "2.1-dev" + "dev-master": "5.0-dev" } }, "installation-source": "dist", @@ -3235,61 +3458,9 @@ "keywords": [ "timer" ], - "install-path": "../phpunit/php-timer" - }, - { - "name": "phpunit/php-token-stream", - "version": "4.0.4", - "version_normalized": "4.0.4.0", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-token-stream.git", - "reference": "a853a0e183b9db7eed023d7933a858fa1c8d25a3" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/a853a0e183b9db7eed023d7933a858fa1c8d25a3", - "reference": "a853a0e183b9db7eed023d7933a858fa1c8d25a3", - "shasum": "" - }, - "require": { - "ext-tokenizer": "*", - "php": "^7.3 || ^8.0" - }, - "require-dev": { - "phpunit/phpunit": "^9.0" - }, - "time": "2020-08-04T08:28:15+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "4.0-dev" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Wrapper around PHP's tokenizer extension.", - "homepage": "https://github.com/sebastianbergmann/php-token-stream/", - "keywords": [ - "tokenizer" - ], "support": { - "issues": "https://github.com/sebastianbergmann/php-token-stream/issues", - "source": "https://github.com/sebastianbergmann/php-token-stream/tree/master" + "issues": "https://github.com/sebastianbergmann/php-timer/issues", + "source": "https://github.com/sebastianbergmann/php-timer/tree/5.0.3" }, "funding": [ { @@ -3297,22 +3468,21 @@ "type": "github" } ], - "abandoned": true, - "install-path": "../phpunit/php-token-stream" + "install-path": "../phpunit/php-timer" }, { "name": "phpunit/phpunit", - "version": "8.5.15", - "version_normalized": "8.5.15.0", + "version": "9.5.4", + "version_normalized": "9.5.4.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "038d4196d8e8cb405cd5e82cedfe413ad6eef9ef" + "reference": "c73c6737305e779771147af66c96ca6a7ed8a741" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/038d4196d8e8cb405cd5e82cedfe413ad6eef9ef", - "reference": "038d4196d8e8cb405cd5e82cedfe413ad6eef9ef", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/c73c6737305e779771147af66c96ca6a7ed8a741", + "reference": "c73c6737305e779771147af66c96ca6a7ed8a741", "shasum": "" }, "require": { @@ -3323,47 +3493,53 @@ "ext-mbstring": "*", "ext-xml": "*", "ext-xmlwriter": "*", - "myclabs/deep-copy": "^1.10.0", + "myclabs/deep-copy": "^1.10.1", "phar-io/manifest": "^2.0.1", "phar-io/version": "^3.0.2", - "php": ">=7.2", - "phpspec/prophecy": "^1.10.3", - "phpunit/php-code-coverage": "^7.0.12", - "phpunit/php-file-iterator": "^2.0.2", - "phpunit/php-text-template": "^1.2.1", - "phpunit/php-timer": "^2.1.2", - "sebastian/comparator": "^3.0.2", - "sebastian/diff": "^3.0.2", - "sebastian/environment": "^4.2.3", - "sebastian/exporter": "^3.1.2", - "sebastian/global-state": "^3.0.0", - "sebastian/object-enumerator": "^3.0.3", - "sebastian/resource-operations": "^2.0.1", - "sebastian/type": "^1.1.3", - "sebastian/version": "^2.0.1" + "php": ">=7.3", + "phpspec/prophecy": "^1.12.1", + "phpunit/php-code-coverage": "^9.2.3", + "phpunit/php-file-iterator": "^3.0.5", + "phpunit/php-invoker": "^3.1.1", + "phpunit/php-text-template": "^2.0.3", + "phpunit/php-timer": "^5.0.2", + "sebastian/cli-parser": "^1.0.1", + "sebastian/code-unit": "^1.0.6", + "sebastian/comparator": "^4.0.5", + "sebastian/diff": "^4.0.3", + "sebastian/environment": "^5.1.3", + "sebastian/exporter": "^4.0.3", + "sebastian/global-state": "^5.0.1", + "sebastian/object-enumerator": "^4.0.3", + "sebastian/resource-operations": "^3.0.3", + "sebastian/type": "^2.3", + "sebastian/version": "^3.0.2" }, "require-dev": { - "ext-pdo": "*" + "ext-pdo": "*", + "phpspec/prophecy-phpunit": "^2.0.1" }, "suggest": { "ext-soap": "*", - "ext-xdebug": "*", - "phpunit/php-invoker": "^2.0.0" + "ext-xdebug": "*" }, - "time": "2021-03-17T07:27:54+00:00", + "time": "2021-03-23T07:16:29+00:00", "bin": [ "phpunit" ], "type": "library", "extra": { "branch-alias": { - "dev-master": "8.5-dev" + "dev-master": "9.5-dev" } }, "installation-source": "dist", "autoload": { "classmap": [ "src/" + ], + "files": [ + "src/Framework/Assert/Functions.php" ] }, "notification-url": "https://packagist.org/downloads/", @@ -3386,7 +3562,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", - "source": "https://github.com/sebastianbergmann/phpunit/tree/8.5.15" + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.4" }, "funding": [ { @@ -3573,6 +3749,61 @@ }, "install-path": "../psr/event-dispatcher" }, + { + "name": "psr/http-client", + "version": "1.0.1", + "version_normalized": "1.0.1.0", + "source": { + "type": "git", + "url": "https://github.com/php-fig/http-client.git", + "reference": "2dfb5f6c5eff0e91e20e913f8c5452ed95b86621" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/http-client/zipball/2dfb5f6c5eff0e91e20e913f8c5452ed95b86621", + "reference": "2dfb5f6c5eff0e91e20e913f8c5452ed95b86621", + "shasum": "" + }, + "require": { + "php": "^7.0 || ^8.0", + "psr/http-message": "^1.0" + }, + "time": "2020-06-29T06:28:15+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "Psr\\Http\\Client\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" + } + ], + "description": "Common interface for HTTP clients", + "homepage": "https://github.com/php-fig/http-client", + "keywords": [ + "http", + "http-client", + "psr", + "psr-18" + ], + "support": { + "source": "https://github.com/php-fig/http-client/tree/master" + }, + "install-path": "../psr/http-client" + }, { "name": "psr/http-message", "version": "1.0.1", @@ -3949,31 +4180,149 @@ "install-path": "../ramsey/uuid" }, { - "name": "sebastian/code-unit-reverse-lookup", - "version": "1.0.2", - "version_normalized": "1.0.2.0", + "name": "sebastian/cli-parser", + "version": "1.0.1", + "version_normalized": "1.0.1.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", - "reference": "1de8cd5c010cb153fcd68b8d0f64606f523f7619" + "url": "https://github.com/sebastianbergmann/cli-parser.git", + "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/1de8cd5c010cb153fcd68b8d0f64606f523f7619", - "reference": "1de8cd5c010cb153fcd68b8d0f64606f523f7619", + "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/442e7c7e687e42adc03470c7b668bc4b2402c0b2", + "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2", "shasum": "" }, "require": { - "php": ">=5.6" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^8.5" + "phpunit/phpunit": "^9.3" }, - "time": "2020-11-30T08:15:22+00:00", + "time": "2020-09-28T06:08:49+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "1.0-dev" + } + }, + "installation-source": "dist", + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library for parsing CLI options", + "homepage": "https://github.com/sebastianbergmann/cli-parser", + "support": { + "issues": "https://github.com/sebastianbergmann/cli-parser/issues", + "source": "https://github.com/sebastianbergmann/cli-parser/tree/1.0.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "install-path": "../sebastian/cli-parser" + }, + { + "name": "sebastian/code-unit", + "version": "1.0.8", + "version_normalized": "1.0.8.0", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/code-unit.git", + "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit/zipball/1fc9f64c0927627ef78ba436c9b17d967e68e120", + "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "time": "2020-10-26T13:08:54+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "installation-source": "dist", + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Collection of value objects that represent the PHP code units", + "homepage": "https://github.com/sebastianbergmann/code-unit", + "support": { + "issues": "https://github.com/sebastianbergmann/code-unit/issues", + "source": "https://github.com/sebastianbergmann/code-unit/tree/1.0.8" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "install-path": "../sebastian/code-unit" + }, + { + "name": "sebastian/code-unit-reverse-lookup", + "version": "2.0.3", + "version_normalized": "2.0.3.0", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", + "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", + "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "time": "2020-09-28T05:30:19+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" } }, "installation-source": "dist", @@ -3994,36 +4343,46 @@ ], "description": "Looks up which function or method a line of code belongs to", "homepage": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/", + "support": { + "issues": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/issues", + "source": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/tree/2.0.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], "install-path": "../sebastian/code-unit-reverse-lookup" }, { "name": "sebastian/comparator", - "version": "3.0.3", - "version_normalized": "3.0.3.0", + "version": "4.0.6", + "version_normalized": "4.0.6.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "1071dfcef776a57013124ff35e1fc41ccd294758" + "reference": "55f4261989e546dc112258c7a75935a81a7ce382" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/1071dfcef776a57013124ff35e1fc41ccd294758", - "reference": "1071dfcef776a57013124ff35e1fc41ccd294758", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/55f4261989e546dc112258c7a75935a81a7ce382", + "reference": "55f4261989e546dc112258c7a75935a81a7ce382", "shasum": "" }, "require": { - "php": ">=7.1", - "sebastian/diff": "^3.0", - "sebastian/exporter": "^3.1" + "php": ">=7.3", + "sebastian/diff": "^4.0", + "sebastian/exporter": "^4.0" }, "require-dev": { - "phpunit/phpunit": "^8.5" + "phpunit/phpunit": "^9.3" }, - "time": "2020-11-30T08:04:30+00:00", + "time": "2020-10-26T15:49:45+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "4.0-dev" } }, "installation-source": "dist", @@ -4061,35 +4420,105 @@ "compare", "equality" ], + "support": { + "issues": "https://github.com/sebastianbergmann/comparator/issues", + "source": "https://github.com/sebastianbergmann/comparator/tree/4.0.6" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], "install-path": "../sebastian/comparator" }, { - "name": "sebastian/diff", - "version": "3.0.3", - "version_normalized": "3.0.3.0", + "name": "sebastian/complexity", + "version": "2.0.2", + "version_normalized": "2.0.2.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "14f72dd46eaf2f2293cbe79c93cc0bc43161a211" + "url": "https://github.com/sebastianbergmann/complexity.git", + "reference": "739b35e53379900cc9ac327b2147867b8b6efd88" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/14f72dd46eaf2f2293cbe79c93cc0bc43161a211", - "reference": "14f72dd46eaf2f2293cbe79c93cc0bc43161a211", + "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/739b35e53379900cc9ac327b2147867b8b6efd88", + "reference": "739b35e53379900cc9ac327b2147867b8b6efd88", "shasum": "" }, "require": { - "php": ">=7.1" + "nikic/php-parser": "^4.7", + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^7.5 || ^8.0", - "symfony/process": "^2 || ^3.3 || ^4" + "phpunit/phpunit": "^9.3" }, - "time": "2020-11-30T07:59:04+00:00", + "time": "2020-10-26T15:52:27+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "2.0-dev" + } + }, + "installation-source": "dist", + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library for calculating the complexity of PHP code units", + "homepage": "https://github.com/sebastianbergmann/complexity", + "support": { + "issues": "https://github.com/sebastianbergmann/complexity/issues", + "source": "https://github.com/sebastianbergmann/complexity/tree/2.0.2" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "install-path": "../sebastian/complexity" + }, + { + "name": "sebastian/diff", + "version": "4.0.4", + "version_normalized": "4.0.4.0", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/diff.git", + "reference": "3461e3fccc7cfdfc2720be910d3bd73c69be590d" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/3461e3fccc7cfdfc2720be910d3bd73c69be590d", + "reference": "3461e3fccc7cfdfc2720be910d3bd73c69be590d", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3", + "symfony/process": "^4.2 || ^5" + }, + "time": "2020-10-26T13:10:38+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.0-dev" } }, "installation-source": "dist", @@ -4120,37 +4549,47 @@ "unidiff", "unified diff" ], + "support": { + "issues": "https://github.com/sebastianbergmann/diff/issues", + "source": "https://github.com/sebastianbergmann/diff/tree/4.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], "install-path": "../sebastian/diff" }, { "name": "sebastian/environment", - "version": "4.2.4", - "version_normalized": "4.2.4.0", + "version": "5.1.3", + "version_normalized": "5.1.3.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "d47bbbad83711771f167c72d4e3f25f7fcc1f8b0" + "reference": "388b6ced16caa751030f6a69e588299fa09200ac" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/d47bbbad83711771f167c72d4e3f25f7fcc1f8b0", - "reference": "d47bbbad83711771f167c72d4e3f25f7fcc1f8b0", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/388b6ced16caa751030f6a69e588299fa09200ac", + "reference": "388b6ced16caa751030f6a69e588299fa09200ac", "shasum": "" }, "require": { - "php": ">=7.1" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^7.5" + "phpunit/phpunit": "^9.3" }, "suggest": { "ext-posix": "*" }, - "time": "2020-11-30T07:53:42+00:00", + "time": "2020-09-28T05:52:38+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "4.2-dev" + "dev-master": "5.1-dev" } }, "installation-source": "dist", @@ -4176,36 +4615,46 @@ "environment", "hhvm" ], + "support": { + "issues": "https://github.com/sebastianbergmann/environment/issues", + "source": "https://github.com/sebastianbergmann/environment/tree/5.1.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], "install-path": "../sebastian/environment" }, { "name": "sebastian/exporter", - "version": "3.1.3", - "version_normalized": "3.1.3.0", + "version": "4.0.3", + "version_normalized": "4.0.3.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "6b853149eab67d4da22291d36f5b0631c0fd856e" + "reference": "d89cc98761b8cb5a1a235a6b703ae50d34080e65" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/6b853149eab67d4da22291d36f5b0631c0fd856e", - "reference": "6b853149eab67d4da22291d36f5b0631c0fd856e", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/d89cc98761b8cb5a1a235a6b703ae50d34080e65", + "reference": "d89cc98761b8cb5a1a235a6b703ae50d34080e65", "shasum": "" }, "require": { - "php": ">=7.0", - "sebastian/recursion-context": "^3.0" + "php": ">=7.3", + "sebastian/recursion-context": "^4.0" }, "require-dev": { "ext-mbstring": "*", - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^9.3" }, - "time": "2020-11-30T07:47:53+00:00", + "time": "2020-09-28T05:24:23+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "3.1.x-dev" + "dev-master": "4.0-dev" } }, "installation-source": "dist", @@ -4246,40 +4695,50 @@ "export", "exporter" ], + "support": { + "issues": "https://github.com/sebastianbergmann/exporter/issues", + "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], "install-path": "../sebastian/exporter" }, { "name": "sebastian/global-state", - "version": "3.0.1", - "version_normalized": "3.0.1.0", + "version": "5.0.2", + "version_normalized": "5.0.2.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "474fb9edb7ab891665d3bfc6317f42a0a150454b" + "reference": "a90ccbddffa067b51f574dea6eb25d5680839455" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/474fb9edb7ab891665d3bfc6317f42a0a150454b", - "reference": "474fb9edb7ab891665d3bfc6317f42a0a150454b", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/a90ccbddffa067b51f574dea6eb25d5680839455", + "reference": "a90ccbddffa067b51f574dea6eb25d5680839455", "shasum": "" }, "require": { - "php": ">=7.2", - "sebastian/object-reflector": "^1.1.1", - "sebastian/recursion-context": "^3.0" + "php": ">=7.3", + "sebastian/object-reflector": "^2.0", + "sebastian/recursion-context": "^4.0" }, "require-dev": { "ext-dom": "*", - "phpunit/phpunit": "^8.0" + "phpunit/phpunit": "^9.3" }, "suggest": { "ext-uopz": "*" }, - "time": "2020-11-30T07:43:24+00:00", + "time": "2020-10-26T15:55:19+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "5.0-dev" } }, "installation-source": "dist", @@ -4305,7 +4764,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/global-state/issues", - "source": "https://github.com/sebastianbergmann/global-state/tree/3.0.1" + "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.2" }, "funding": [ { @@ -4316,33 +4775,93 @@ "install-path": "../sebastian/global-state" }, { - "name": "sebastian/object-enumerator", - "version": "3.0.4", - "version_normalized": "3.0.4.0", + "name": "sebastian/lines-of-code", + "version": "1.0.3", + "version_normalized": "1.0.3.0", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/object-enumerator.git", - "reference": "e67f6d32ebd0c749cf9d1dbd9f226c727043cdf2" + "url": "https://github.com/sebastianbergmann/lines-of-code.git", + "reference": "c1c2e997aa3146983ed888ad08b15470a2e22ecc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/e67f6d32ebd0c749cf9d1dbd9f226c727043cdf2", - "reference": "e67f6d32ebd0c749cf9d1dbd9f226c727043cdf2", + "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/c1c2e997aa3146983ed888ad08b15470a2e22ecc", + "reference": "c1c2e997aa3146983ed888ad08b15470a2e22ecc", "shasum": "" }, "require": { - "php": ">=7.0", - "sebastian/object-reflector": "^1.1.1", - "sebastian/recursion-context": "^3.0" + "nikic/php-parser": "^4.6", + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^9.3" }, - "time": "2020-11-30T07:40:27+00:00", + "time": "2020-11-28T06:42:11+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0.x-dev" + "dev-master": "1.0-dev" + } + }, + "installation-source": "dist", + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library for counting the lines of code in PHP source code", + "homepage": "https://github.com/sebastianbergmann/lines-of-code", + "support": { + "issues": "https://github.com/sebastianbergmann/lines-of-code/issues", + "source": "https://github.com/sebastianbergmann/lines-of-code/tree/1.0.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "install-path": "../sebastian/lines-of-code" + }, + { + "name": "sebastian/object-enumerator", + "version": "4.0.4", + "version_normalized": "4.0.4.0", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/object-enumerator.git", + "reference": "5c9eeac41b290a3712d88851518825ad78f45c71" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/5c9eeac41b290a3712d88851518825ad78f45c71", + "reference": "5c9eeac41b290a3712d88851518825ad78f45c71", + "shasum": "" + }, + "require": { + "php": ">=7.3", + "sebastian/object-reflector": "^2.0", + "sebastian/recursion-context": "^4.0" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "time": "2020-10-26T13:12:34+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.0-dev" } }, "installation-source": "dist", @@ -4363,34 +4882,44 @@ ], "description": "Traverses array structures and object graphs to enumerate all referenced objects", "homepage": "https://github.com/sebastianbergmann/object-enumerator/", + "support": { + "issues": "https://github.com/sebastianbergmann/object-enumerator/issues", + "source": "https://github.com/sebastianbergmann/object-enumerator/tree/4.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], "install-path": "../sebastian/object-enumerator" }, { "name": "sebastian/object-reflector", - "version": "1.1.2", - "version_normalized": "1.1.2.0", + "version": "2.0.4", + "version_normalized": "2.0.4.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/object-reflector.git", - "reference": "9b8772b9cbd456ab45d4a598d2dd1a1bced6363d" + "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/9b8772b9cbd456ab45d4a598d2dd1a1bced6363d", - "reference": "9b8772b9cbd456ab45d4a598d2dd1a1bced6363d", + "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", + "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", "shasum": "" }, "require": { - "php": ">=7.0" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^9.3" }, - "time": "2020-11-30T07:37:18+00:00", + "time": "2020-10-26T13:14:26+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.1-dev" + "dev-master": "2.0-dev" } }, "installation-source": "dist", @@ -4411,34 +4940,44 @@ ], "description": "Allows reflection of object attributes, including inherited and non-public ones", "homepage": "https://github.com/sebastianbergmann/object-reflector/", + "support": { + "issues": "https://github.com/sebastianbergmann/object-reflector/issues", + "source": "https://github.com/sebastianbergmann/object-reflector/tree/2.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], "install-path": "../sebastian/object-reflector" }, { "name": "sebastian/recursion-context", - "version": "3.0.1", - "version_normalized": "3.0.1.0", + "version": "4.0.4", + "version_normalized": "4.0.4.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/recursion-context.git", - "reference": "367dcba38d6e1977be014dc4b22f47a484dac7fb" + "reference": "cd9d8cf3c5804de4341c283ed787f099f5506172" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/367dcba38d6e1977be014dc4b22f47a484dac7fb", - "reference": "367dcba38d6e1977be014dc4b22f47a484dac7fb", + "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/cd9d8cf3c5804de4341c283ed787f099f5506172", + "reference": "cd9d8cf3c5804de4341c283ed787f099f5506172", "shasum": "" }, "require": { - "php": ">=7.0" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^9.3" }, - "time": "2020-11-30T07:34:24+00:00", + "time": "2020-10-26T13:17:30+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0.x-dev" + "dev-master": "4.0-dev" } }, "installation-source": "dist", @@ -4467,31 +5006,44 @@ ], "description": "Provides functionality to recursively process PHP variables", "homepage": "http://www.github.com/sebastianbergmann/recursion-context", + "support": { + "issues": "https://github.com/sebastianbergmann/recursion-context/issues", + "source": "https://github.com/sebastianbergmann/recursion-context/tree/4.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], "install-path": "../sebastian/recursion-context" }, { "name": "sebastian/resource-operations", - "version": "2.0.2", - "version_normalized": "2.0.2.0", + "version": "3.0.3", + "version_normalized": "3.0.3.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/resource-operations.git", - "reference": "31d35ca87926450c44eae7e2611d45a7a65ea8b3" + "reference": "0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/31d35ca87926450c44eae7e2611d45a7a65ea8b3", - "reference": "31d35ca87926450c44eae7e2611d45a7a65ea8b3", + "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8", + "reference": "0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8", "shasum": "" }, "require": { - "php": ">=7.1" + "php": ">=7.3" }, - "time": "2020-11-30T07:30:19+00:00", + "require-dev": { + "phpunit/phpunit": "^9.0" + }, + "time": "2020-09-28T06:45:17+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-master": "3.0-dev" } }, "installation-source": "dist", @@ -4512,34 +5064,44 @@ ], "description": "Provides a list of PHP built-in functions that operate on resources", "homepage": "https://www.github.com/sebastianbergmann/resource-operations", + "support": { + "issues": "https://github.com/sebastianbergmann/resource-operations/issues", + "source": "https://github.com/sebastianbergmann/resource-operations/tree/3.0.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], "install-path": "../sebastian/resource-operations" }, { "name": "sebastian/type", - "version": "1.1.4", - "version_normalized": "1.1.4.0", + "version": "2.3.1", + "version_normalized": "2.3.1.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/type.git", - "reference": "0150cfbc4495ed2df3872fb31b26781e4e077eb4" + "reference": "81cd61ab7bbf2de744aba0ea61fae32f721df3d2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/0150cfbc4495ed2df3872fb31b26781e4e077eb4", - "reference": "0150cfbc4495ed2df3872fb31b26781e4e077eb4", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/81cd61ab7bbf2de744aba0ea61fae32f721df3d2", + "reference": "81cd61ab7bbf2de744aba0ea61fae32f721df3d2", "shasum": "" }, "require": { - "php": ">=7.2" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^8.2" + "phpunit/phpunit": "^9.3" }, - "time": "2020-11-30T07:25:11+00:00", + "time": "2020-10-26T13:18:59+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "1.1-dev" + "dev-master": "2.3-dev" } }, "installation-source": "dist", @@ -4563,7 +5125,7 @@ "homepage": "https://github.com/sebastianbergmann/type", "support": { "issues": "https://github.com/sebastianbergmann/type/issues", - "source": "https://github.com/sebastianbergmann/type/tree/1.1.4" + "source": "https://github.com/sebastianbergmann/type/tree/2.3.1" }, "funding": [ { @@ -4575,27 +5137,27 @@ }, { "name": "sebastian/version", - "version": "2.0.1", - "version_normalized": "2.0.1.0", + "version": "3.0.2", + "version_normalized": "3.0.2.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/version.git", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019" + "reference": "c6c1022351a901512170118436c764e473f6de8c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/99732be0ddb3361e16ad77b68ba41efc8e979019", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019", + "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/c6c1022351a901512170118436c764e473f6de8c", + "reference": "c6c1022351a901512170118436c764e473f6de8c", "shasum": "" }, "require": { - "php": ">=5.6" + "php": ">=7.3" }, - "time": "2016-10-03T07:35:21+00:00", + "time": "2020-09-28T06:39:44+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "3.0-dev" } }, "installation-source": "dist", @@ -4617,6 +5179,16 @@ ], "description": "Library that helps with managing the version number of Git-hosted PHP projects", "homepage": "https://github.com/sebastianbergmann/version", + "support": { + "issues": "https://github.com/sebastianbergmann/version/issues", + "source": "https://github.com/sebastianbergmann/version/tree/3.0.2" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], "install-path": "../sebastian/version" }, { @@ -4754,38 +5326,39 @@ }, { "name": "spatie/laravel-schedule-monitor", - "version": "2.0.1", - "version_normalized": "2.0.1.0", + "version": "2.3.0", + "version_normalized": "2.3.0.0", "source": { "type": "git", "url": "https://github.com/spatie/laravel-schedule-monitor.git", - "reference": "4ffdaea81b5c27a119b6cbac8f4894657b8fd6d9" + "reference": "cc65f9822d0e0b69043372d6c7d3e8dbd072f85d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/spatie/laravel-schedule-monitor/zipball/4ffdaea81b5c27a119b6cbac8f4894657b8fd6d9", - "reference": "4ffdaea81b5c27a119b6cbac8f4894657b8fd6d9", + "url": "https://api.github.com/repos/spatie/laravel-schedule-monitor/zipball/cc65f9822d0e0b69043372d6c7d3e8dbd072f85d", + "reference": "cc65f9822d0e0b69043372d6c7d3e8dbd072f85d", "shasum": "" }, "require": { - "illuminate/bus": "^7.19|^8.0", - "lorisleiva/cron-translator": "^0.1.1", - "php": "^7.4" + "illuminate/bus": "^8.0", + "lorisleiva/cron-translator": "^0.2.0", + "nesbot/carbon": "^2.41.3", + "php": "^7.4|^8.0" }, "require-dev": { - "friendsofphp/php-cs-fixer": "^2.16", "laravel/legacy-factories": "^1.0.4", + "mockery/mockery": "^1.4", "ohdearapp/ohdear-php-sdk": "^3.0", - "orchestra/testbench": "^5.0|^6.0", - "phpunit/phpunit": "^9.0", + "orchestra/testbench": "^6.8", + "phpunit/phpunit": "^9.3", "spatie/phpunit-snapshot-assertions": "^4.2", "spatie/test-time": "^1.2", - "vimeo/psalm": "^3.11" + "vimeo/psalm": "^4.0" }, "suggest": { "ohdearapp/ohdear-php-sdk": "Needed to sync your schedule with Oh Dear" }, - "time": "2020-10-06T10:38:45+00:00", + "time": "2021-05-13T11:57:52+00:00", "type": "library", "extra": { "laravel": { @@ -4820,7 +5393,7 @@ ], "support": { "issues": "https://github.com/spatie/laravel-schedule-monitor/issues", - "source": "https://github.com/spatie/laravel-schedule-monitor/tree/2.0.1" + "source": "https://github.com/spatie/laravel-schedule-monitor/tree/2.3.0" }, "funding": [ { @@ -5078,23 +5651,23 @@ }, { "name": "symfony/css-selector", - "version": "v5.2.7", - "version_normalized": "5.2.7.0", + "version": "v5.2.9", + "version_normalized": "5.2.9.0", "source": { "type": "git", "url": "https://github.com/symfony/css-selector.git", - "reference": "59a684f5ac454f066ecbe6daecce6719aed283fb" + "reference": "5d5f97809015102116208b976eb2edb44b689560" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/css-selector/zipball/59a684f5ac454f066ecbe6daecce6719aed283fb", - "reference": "59a684f5ac454f066ecbe6daecce6719aed283fb", + "url": "https://api.github.com/repos/symfony/css-selector/zipball/5d5f97809015102116208b976eb2edb44b689560", + "reference": "5d5f97809015102116208b976eb2edb44b689560", "shasum": "" }, "require": { "php": ">=7.2.5" }, - "time": "2021-04-07T16:07:52+00:00", + "time": "2021-05-16T13:07:46+00:00", "type": "library", "installation-source": "dist", "autoload": { @@ -5126,7 +5699,7 @@ "description": "Converts CSS selectors to XPath expressions", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/css-selector/tree/v5.3.0-BETA1" + "source": "https://github.com/symfony/css-selector/tree/v5.2.9" }, "funding": [ { @@ -5458,23 +6031,23 @@ }, { "name": "symfony/finder", - "version": "v5.2.8", - "version_normalized": "5.2.8.0", + "version": "v5.2.9", + "version_normalized": "5.2.9.0", "source": { "type": "git", "url": "https://github.com/symfony/finder.git", - "reference": "eccb8be70d7a6a2230d05f6ecede40f3fdd9e252" + "reference": "ccccb9d48ca42757dd12f2ca4bf857a4e217d90d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/finder/zipball/eccb8be70d7a6a2230d05f6ecede40f3fdd9e252", - "reference": "eccb8be70d7a6a2230d05f6ecede40f3fdd9e252", + "url": "https://api.github.com/repos/symfony/finder/zipball/ccccb9d48ca42757dd12f2ca4bf857a4e217d90d", + "reference": "ccccb9d48ca42757dd12f2ca4bf857a4e217d90d", "shasum": "" }, "require": { "php": ">=7.2.5" }, - "time": "2021-05-10T14:39:23+00:00", + "time": "2021-05-16T13:07:46+00:00", "type": "library", "installation-source": "dist", "autoload": { @@ -5502,7 +6075,7 @@ "description": "Finds files and directories via an intuitive fluent interface", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/finder/tree/v5.2.8" + "source": "https://github.com/symfony/finder/tree/v5.2.9" }, "funding": [ { @@ -5679,17 +6252,17 @@ }, { "name": "symfony/http-kernel", - "version": "v5.2.8", - "version_normalized": "5.2.8.0", + "version": "v5.2.9", + "version_normalized": "5.2.9.0", "source": { "type": "git", "url": "https://github.com/symfony/http-kernel.git", - "reference": "c3cb71ee7e2d3eae5fe1001f81780d6a49b37937" + "reference": "eb540ef6870dbf33c92e372cfb869ebf9649e6cb" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-kernel/zipball/c3cb71ee7e2d3eae5fe1001f81780d6a49b37937", - "reference": "c3cb71ee7e2d3eae5fe1001f81780d6a49b37937", + "url": "https://api.github.com/repos/symfony/http-kernel/zipball/eb540ef6870dbf33c92e372cfb869ebf9649e6cb", + "reference": "eb540ef6870dbf33c92e372cfb869ebf9649e6cb", "shasum": "" }, "require": { @@ -5746,7 +6319,7 @@ "symfony/console": "", "symfony/dependency-injection": "" }, - "time": "2021-05-12T13:27:53+00:00", + "time": "2021-05-19T12:23:45+00:00", "type": "library", "installation-source": "dist", "autoload": { @@ -5774,7 +6347,7 @@ "description": "Provides a structured process for converting a Request into a Response", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/http-kernel/tree/v5.2.8" + "source": "https://github.com/symfony/http-kernel/tree/v5.2.9" }, "funding": [ { @@ -5794,17 +6367,17 @@ }, { "name": "symfony/mime", - "version": "v5.2.7", - "version_normalized": "5.2.7.0", + "version": "v5.2.9", + "version_normalized": "5.2.9.0", "source": { "type": "git", "url": "https://github.com/symfony/mime.git", - "reference": "7af452bf51c46f18da00feb32e1ad36db9426515" + "reference": "64258e870f8cc75c3dae986201ea2df58c210b52" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/mime/zipball/7af452bf51c46f18da00feb32e1ad36db9426515", - "reference": "7af452bf51c46f18da00feb32e1ad36db9426515", + "url": "https://api.github.com/repos/symfony/mime/zipball/64258e870f8cc75c3dae986201ea2df58c210b52", + "reference": "64258e870f8cc75c3dae986201ea2df58c210b52", "shasum": "" }, "require": { @@ -5828,7 +6401,7 @@ "symfony/property-info": "^4.4|^5.1", "symfony/serializer": "^5.2" }, - "time": "2021-04-29T20:47:09+00:00", + "time": "2021-05-16T13:07:46+00:00", "type": "library", "installation-source": "dist", "autoload": { @@ -5860,7 +6433,7 @@ "mime-type" ], "support": { - "source": "https://github.com/symfony/mime/tree/v5.2.7" + "source": "https://github.com/symfony/mime/tree/v5.2.9" }, "funding": [ { @@ -5880,17 +6453,17 @@ }, { "name": "symfony/polyfill-ctype", - "version": "v1.22.1", - "version_normalized": "1.22.1.0", + "version": "v1.23.0", + "version_normalized": "1.23.0.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-ctype.git", - "reference": "c6c942b1ac76c82448322025e084cadc56048b4e" + "reference": "46cd95797e9df938fdd2b03693b5fca5e64b01ce" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/c6c942b1ac76c82448322025e084cadc56048b4e", - "reference": "c6c942b1ac76c82448322025e084cadc56048b4e", + "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/46cd95797e9df938fdd2b03693b5fca5e64b01ce", + "reference": "46cd95797e9df938fdd2b03693b5fca5e64b01ce", "shasum": "" }, "require": { @@ -5899,11 +6472,11 @@ "suggest": { "ext-ctype": "For best performance" }, - "time": "2021-01-07T16:49:33+00:00", + "time": "2021-02-19T12:13:01+00:00", "type": "library", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", @@ -5942,7 +6515,7 @@ "portable" ], "support": { - "source": "https://github.com/symfony/polyfill-ctype/tree/v1.22.1" + "source": "https://github.com/symfony/polyfill-ctype/tree/v1.23.0" }, "funding": [ { @@ -5962,17 +6535,17 @@ }, { "name": "symfony/polyfill-iconv", - "version": "v1.22.1", - "version_normalized": "1.22.1.0", + "version": "v1.23.0", + "version_normalized": "1.23.0.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-iconv.git", - "reference": "06fb361659649bcfd6a208a0f1fcaf4e827ad342" + "reference": "63b5bb7db83e5673936d6e3b8b3e022ff6474933" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-iconv/zipball/06fb361659649bcfd6a208a0f1fcaf4e827ad342", - "reference": "06fb361659649bcfd6a208a0f1fcaf4e827ad342", + "url": "https://api.github.com/repos/symfony/polyfill-iconv/zipball/63b5bb7db83e5673936d6e3b8b3e022ff6474933", + "reference": "63b5bb7db83e5673936d6e3b8b3e022ff6474933", "shasum": "" }, "require": { @@ -5981,11 +6554,11 @@ "suggest": { "ext-iconv": "For best performance" }, - "time": "2021-01-22T09:19:47+00:00", + "time": "2021-05-27T09:27:20+00:00", "type": "library", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", @@ -6025,7 +6598,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-iconv/tree/v1.22.1" + "source": "https://github.com/symfony/polyfill-iconv/tree/v1.23.0" }, "funding": [ { @@ -6045,17 +6618,17 @@ }, { "name": "symfony/polyfill-intl-grapheme", - "version": "v1.22.1", - "version_normalized": "1.22.1.0", + "version": "v1.23.0", + "version_normalized": "1.23.0.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-grapheme.git", - "reference": "5601e09b69f26c1828b13b6bb87cb07cddba3170" + "reference": "24b72c6baa32c746a4d0840147c9715e42bb68ab" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-intl-grapheme/zipball/5601e09b69f26c1828b13b6bb87cb07cddba3170", - "reference": "5601e09b69f26c1828b13b6bb87cb07cddba3170", + "url": "https://api.github.com/repos/symfony/polyfill-intl-grapheme/zipball/24b72c6baa32c746a4d0840147c9715e42bb68ab", + "reference": "24b72c6baa32c746a4d0840147c9715e42bb68ab", "shasum": "" }, "require": { @@ -6064,11 +6637,11 @@ "suggest": { "ext-intl": "For best performance" }, - "time": "2021-01-22T09:19:47+00:00", + "time": "2021-05-27T09:17:38+00:00", "type": "library", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", @@ -6109,7 +6682,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-intl-grapheme/tree/v1.22.1" + "source": "https://github.com/symfony/polyfill-intl-grapheme/tree/v1.23.0" }, "funding": [ { @@ -6129,17 +6702,17 @@ }, { "name": "symfony/polyfill-intl-idn", - "version": "v1.22.1", - "version_normalized": "1.22.1.0", + "version": "v1.23.0", + "version_normalized": "1.23.0.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-idn.git", - "reference": "2d63434d922daf7da8dd863e7907e67ee3031483" + "reference": "65bd267525e82759e7d8c4e8ceea44f398838e65" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-intl-idn/zipball/2d63434d922daf7da8dd863e7907e67ee3031483", - "reference": "2d63434d922daf7da8dd863e7907e67ee3031483", + "url": "https://api.github.com/repos/symfony/polyfill-intl-idn/zipball/65bd267525e82759e7d8c4e8ceea44f398838e65", + "reference": "65bd267525e82759e7d8c4e8ceea44f398838e65", "shasum": "" }, "require": { @@ -6150,11 +6723,11 @@ "suggest": { "ext-intl": "For best performance" }, - "time": "2021-01-22T09:19:47+00:00", + "time": "2021-05-27T09:27:20+00:00", "type": "library", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", @@ -6199,7 +6772,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-intl-idn/tree/v1.22.1" + "source": "https://github.com/symfony/polyfill-intl-idn/tree/v1.23.0" }, "funding": [ { @@ -6219,17 +6792,17 @@ }, { "name": "symfony/polyfill-intl-normalizer", - "version": "v1.22.1", - "version_normalized": "1.22.1.0", + "version": "v1.23.0", + "version_normalized": "1.23.0.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-normalizer.git", - "reference": "43a0283138253ed1d48d352ab6d0bdb3f809f248" + "reference": "8590a5f561694770bdcd3f9b5c69dde6945028e8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-intl-normalizer/zipball/43a0283138253ed1d48d352ab6d0bdb3f809f248", - "reference": "43a0283138253ed1d48d352ab6d0bdb3f809f248", + "url": "https://api.github.com/repos/symfony/polyfill-intl-normalizer/zipball/8590a5f561694770bdcd3f9b5c69dde6945028e8", + "reference": "8590a5f561694770bdcd3f9b5c69dde6945028e8", "shasum": "" }, "require": { @@ -6238,11 +6811,11 @@ "suggest": { "ext-intl": "For best performance" }, - "time": "2021-01-22T09:19:47+00:00", + "time": "2021-02-19T12:13:01+00:00", "type": "library", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", @@ -6286,7 +6859,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.22.1" + "source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.23.0" }, "funding": [ { @@ -6306,17 +6879,17 @@ }, { "name": "symfony/polyfill-mbstring", - "version": "v1.22.1", - "version_normalized": "1.22.1.0", + "version": "v1.23.0", + "version_normalized": "1.23.0.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "5232de97ee3b75b0360528dae24e73db49566ab1" + "reference": "2df51500adbaebdc4c38dea4c89a2e131c45c8a1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/5232de97ee3b75b0360528dae24e73db49566ab1", - "reference": "5232de97ee3b75b0360528dae24e73db49566ab1", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/2df51500adbaebdc4c38dea4c89a2e131c45c8a1", + "reference": "2df51500adbaebdc4c38dea4c89a2e131c45c8a1", "shasum": "" }, "require": { @@ -6325,11 +6898,11 @@ "suggest": { "ext-mbstring": "For best performance" }, - "time": "2021-01-22T09:19:47+00:00", + "time": "2021-05-27T09:27:20+00:00", "type": "library", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", @@ -6369,7 +6942,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.22.1" + "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.23.0" }, "funding": [ { @@ -6389,27 +6962,27 @@ }, { "name": "symfony/polyfill-php72", - "version": "v1.22.1", - "version_normalized": "1.22.1.0", + "version": "v1.23.0", + "version_normalized": "1.23.0.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php72.git", - "reference": "cc6e6f9b39fe8075b3dabfbaf5b5f645ae1340c9" + "reference": "9a142215a36a3888e30d0a9eeea9766764e96976" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php72/zipball/cc6e6f9b39fe8075b3dabfbaf5b5f645ae1340c9", - "reference": "cc6e6f9b39fe8075b3dabfbaf5b5f645ae1340c9", + "url": "https://api.github.com/repos/symfony/polyfill-php72/zipball/9a142215a36a3888e30d0a9eeea9766764e96976", + "reference": "9a142215a36a3888e30d0a9eeea9766764e96976", "shasum": "" }, "require": { "php": ">=7.1" }, - "time": "2021-01-07T16:49:33+00:00", + "time": "2021-05-27T09:17:38+00:00", "type": "library", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", @@ -6448,7 +7021,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php72/tree/v1.22.1" + "source": "https://github.com/symfony/polyfill-php72/tree/v1.23.0" }, "funding": [ { @@ -6468,27 +7041,27 @@ }, { "name": "symfony/polyfill-php73", - "version": "v1.22.1", - "version_normalized": "1.22.1.0", + "version": "v1.23.0", + "version_normalized": "1.23.0.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php73.git", - "reference": "a678b42e92f86eca04b7fa4c0f6f19d097fb69e2" + "reference": "fba8933c384d6476ab14fb7b8526e5287ca7e010" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php73/zipball/a678b42e92f86eca04b7fa4c0f6f19d097fb69e2", - "reference": "a678b42e92f86eca04b7fa4c0f6f19d097fb69e2", + "url": "https://api.github.com/repos/symfony/polyfill-php73/zipball/fba8933c384d6476ab14fb7b8526e5287ca7e010", + "reference": "fba8933c384d6476ab14fb7b8526e5287ca7e010", "shasum": "" }, "require": { "php": ">=7.1" }, - "time": "2021-01-07T16:49:33+00:00", + "time": "2021-02-19T12:13:01+00:00", "type": "library", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", @@ -6530,7 +7103,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php73/tree/v1.22.1" + "source": "https://github.com/symfony/polyfill-php73/tree/v1.23.0" }, "funding": [ { @@ -6550,27 +7123,27 @@ }, { "name": "symfony/polyfill-php80", - "version": "v1.22.1", - "version_normalized": "1.22.1.0", + "version": "v1.23.0", + "version_normalized": "1.23.0.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php80.git", - "reference": "dc3063ba22c2a1fd2f45ed856374d79114998f91" + "reference": "eca0bf41ed421bed1b57c4958bab16aa86b757d0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/dc3063ba22c2a1fd2f45ed856374d79114998f91", - "reference": "dc3063ba22c2a1fd2f45ed856374d79114998f91", + "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/eca0bf41ed421bed1b57c4958bab16aa86b757d0", + "reference": "eca0bf41ed421bed1b57c4958bab16aa86b757d0", "shasum": "" }, "require": { "php": ">=7.1" }, - "time": "2021-01-07T16:49:33+00:00", + "time": "2021-02-19T12:13:01+00:00", "type": "library", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", @@ -6616,7 +7189,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php80/tree/v1.22.1" + "source": "https://github.com/symfony/polyfill-php80/tree/v1.23.0" }, "funding": [ { @@ -6701,17 +7274,17 @@ }, { "name": "symfony/routing", - "version": "v5.2.7", - "version_normalized": "5.2.7.0", + "version": "v5.2.9", + "version_normalized": "5.2.9.0", "source": { "type": "git", "url": "https://github.com/symfony/routing.git", - "reference": "3f0cab2e95b5e92226f34c2c1aa969d3fc41f48c" + "reference": "4a7b2bf5e1221be1902b6853743a9bb317f6925e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/routing/zipball/3f0cab2e95b5e92226f34c2c1aa969d3fc41f48c", - "reference": "3f0cab2e95b5e92226f34c2c1aa969d3fc41f48c", + "url": "https://api.github.com/repos/symfony/routing/zipball/4a7b2bf5e1221be1902b6853743a9bb317f6925e", + "reference": "4a7b2bf5e1221be1902b6853743a9bb317f6925e", "shasum": "" }, "require": { @@ -6739,7 +7312,7 @@ "symfony/http-foundation": "For using a Symfony Request object", "symfony/yaml": "For using the YAML loader" }, - "time": "2021-04-11T22:55:21+00:00", + "time": "2021-05-16T13:07:46+00:00", "type": "library", "installation-source": "dist", "autoload": { @@ -6773,7 +7346,7 @@ "url" ], "support": { - "source": "https://github.com/symfony/routing/tree/v5.2.7" + "source": "https://github.com/symfony/routing/tree/v5.2.9" }, "funding": [ { @@ -6961,17 +7534,17 @@ }, { "name": "symfony/translation", - "version": "v5.2.8", - "version_normalized": "5.2.8.0", + "version": "v5.2.9", + "version_normalized": "5.2.9.0", "source": { "type": "git", "url": "https://github.com/symfony/translation.git", - "reference": "445caa74a5986f1cc9dd91a2975ef68fa7cb2068" + "reference": "61af68dba333e2d376a325a29c2a3f2a605b4876" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/translation/zipball/445caa74a5986f1cc9dd91a2975ef68fa7cb2068", - "reference": "445caa74a5986f1cc9dd91a2975ef68fa7cb2068", + "url": "https://api.github.com/repos/symfony/translation/zipball/61af68dba333e2d376a325a29c2a3f2a605b4876", + "reference": "61af68dba333e2d376a325a29c2a3f2a605b4876", "shasum": "" }, "require": { @@ -7006,7 +7579,7 @@ "symfony/config": "", "symfony/yaml": "" }, - "time": "2021-05-07T13:41:16+00:00", + "time": "2021-05-16T13:07:46+00:00", "type": "library", "installation-source": "dist", "autoload": { @@ -7037,7 +7610,7 @@ "description": "Provides tools to internationalize your application", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/translation/tree/v5.2.8" + "source": "https://github.com/symfony/translation/tree/v5.2.9" }, "funding": [ { @@ -7388,39 +7961,41 @@ }, { "name": "vlucas/phpdotenv", - "version": "v4.2.0", - "version_normalized": "4.2.0.0", + "version": "v5.3.0", + "version_normalized": "5.3.0.0", "source": { "type": "git", "url": "https://github.com/vlucas/phpdotenv.git", - "reference": "da64796370fc4eb03cc277088f6fede9fde88482" + "reference": "b3eac5c7ac896e52deab4a99068e3f4ab12d9e56" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/vlucas/phpdotenv/zipball/da64796370fc4eb03cc277088f6fede9fde88482", - "reference": "da64796370fc4eb03cc277088f6fede9fde88482", + "url": "https://api.github.com/repos/vlucas/phpdotenv/zipball/b3eac5c7ac896e52deab4a99068e3f4ab12d9e56", + "reference": "b3eac5c7ac896e52deab4a99068e3f4ab12d9e56", "shasum": "" }, "require": { - "php": "^5.5.9 || ^7.0 || ^8.0", - "phpoption/phpoption": "^1.7.3", - "symfony/polyfill-ctype": "^1.17" + "ext-pcre": "*", + "graham-campbell/result-type": "^1.0.1", + "php": "^7.1.3 || ^8.0", + "phpoption/phpoption": "^1.7.4", + "symfony/polyfill-ctype": "^1.17", + "symfony/polyfill-mbstring": "^1.17", + "symfony/polyfill-php80": "^1.17" }, "require-dev": { "bamarni/composer-bin-plugin": "^1.4.1", "ext-filter": "*", - "ext-pcre": "*", - "phpunit/phpunit": "^4.8.36 || ^5.7.27 || ^6.5.14 || ^7.5.20" + "phpunit/phpunit": "^7.5.20 || ^8.5.14 || ^9.5.1" }, "suggest": { - "ext-filter": "Required to use the boolean validator.", - "ext-pcre": "Required to use most of the library." + "ext-filter": "Required to use the boolean validator." }, - "time": "2021-01-20T15:11:48+00:00", + "time": "2021-01-20T15:23:13+00:00", "type": "library", "extra": { "branch-alias": { - "dev-master": "4.1-dev" + "dev-master": "5.3-dev" } }, "installation-source": "dist", @@ -7453,7 +8028,7 @@ ], "support": { "issues": "https://github.com/vlucas/phpdotenv/issues", - "source": "https://github.com/vlucas/phpdotenv/tree/v4.2.0" + "source": "https://github.com/vlucas/phpdotenv/tree/v5.3.0" }, "funding": [ { @@ -8235,6 +8810,7 @@ "hamcrest/hamcrest-php", "mockery/mockery", "myclabs/deep-copy", + "nikic/php-parser", "nunomaduro/collision", "phar-io/manifest", "phar-io/version", @@ -8244,23 +8820,26 @@ "phpspec/prophecy", "phpunit/php-code-coverage", "phpunit/php-file-iterator", + "phpunit/php-invoker", "phpunit/php-text-template", "phpunit/php-timer", - "phpunit/php-token-stream", "phpunit/phpunit", + "sebastian/cli-parser", + "sebastian/code-unit", "sebastian/code-unit-reverse-lookup", "sebastian/comparator", + "sebastian/complexity", "sebastian/diff", "sebastian/environment", "sebastian/exporter", "sebastian/global-state", + "sebastian/lines-of-code", "sebastian/object-enumerator", "sebastian/object-reflector", "sebastian/recursion-context", "sebastian/resource-operations", "sebastian/type", "sebastian/version", - "theseer/tokenizer", - "webmozart/assert" + "theseer/tokenizer" ] } diff --git a/vendor/composer/installed.php b/vendor/composer/installed.php index f087dbf14..dd293b2c0 100644 --- a/vendor/composer/installed.php +++ b/vendor/composer/installed.php @@ -6,7 +6,7 @@ 'aliases' => array ( ), - 'reference' => 'e248cd036c7757b009d90b73fcd77176cbb45e76', + 'reference' => '41b78a0599d303bea0254a30f8ebc3c778e3e34e', 'name' => 'laravel/laravel', ), 'versions' => @@ -29,15 +29,6 @@ ), 'reference' => 'dff976c2f3487d42c1db75a3b180e2b9f0e72ce0', ), - 'cakephp/chronos' => - array ( - 'pretty_version' => '2.1.2', - 'version' => '2.1.2.0', - 'aliases' => - array ( - ), - 'reference' => '1d187c71587c97520c00491f626e0f255144953e', - ), 'cordoval/hamcrest-php' => array ( 'replaced' => @@ -81,12 +72,12 @@ ), 'dragonmantank/cron-expression' => array ( - 'pretty_version' => 'v2.3.1', - 'version' => '2.3.1.0', + 'pretty_version' => 'v3.1.0', + 'version' => '3.1.0.0', 'aliases' => array ( ), - 'reference' => '65b2d8ee1f10915efb3b55597da3404f096acba2', + 'reference' => '7a8c6e56ab3ffcc538d05e8155bb42269abf1a0c', ), 'egulias/email-validator' => array ( @@ -99,12 +90,12 @@ ), 'eveseat/eseye' => array ( - 'pretty_version' => '2.3.2', - 'version' => '2.3.2.0', + 'pretty_version' => '2.4.0', + 'version' => '2.4.0.0', 'aliases' => array ( ), - 'reference' => '69a0180f1727369614971fe377a1a8b2301c505d', + 'reference' => 'b9d6753ccad9edce2bed6c91142f62eaebe24a8c', ), 'facade/ignition-contracts' => array ( @@ -151,14 +142,23 @@ ), 'reference' => '848d8125239d7dbf8ab25cb7f054f1a630e68c2e', ), - 'guzzlehttp/guzzle' => + 'graham-campbell/result-type' => array ( - 'pretty_version' => '6.5.5', - 'version' => '6.5.5.0', + 'pretty_version' => 'v1.0.1', + 'version' => '1.0.1.0', 'aliases' => array ( ), - 'reference' => '9d4290de1cfd701f38099ef7e183b64b4b7b0c5e', + 'reference' => '7e279d2cd5d7fbb156ce46daada972355cea27bb', + ), + 'guzzlehttp/guzzle' => + array ( + 'pretty_version' => '7.3.0', + 'version' => '7.3.0.0', + 'aliases' => + array ( + ), + 'reference' => '7008573787b430c1c1f650e3722d9bba59967628', ), 'guzzlehttp/promises' => array ( @@ -191,203 +191,217 @@ array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/broadcasting' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/bus' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/cache' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', + ), + ), + 'illuminate/collections' => + array ( + 'replaced' => + array ( + 0 => 'v8.44.0', ), ), 'illuminate/config' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/console' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/container' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/contracts' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/cookie' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/database' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/encryption' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/events' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/filesystem' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/hashing' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/http' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/log' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', + ), + ), + 'illuminate/macroable' => + array ( + 'replaced' => + array ( + 0 => 'v8.44.0', ), ), 'illuminate/mail' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/notifications' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/pagination' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/pipeline' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/queue' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/redis' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/routing' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/session' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/support' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/testing' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/translation' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/validation' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'illuminate/view' => array ( 'replaced' => array ( - 0 => 'v7.30.4', + 0 => 'v8.44.0', ), ), 'khill/lavacharts' => @@ -408,12 +422,12 @@ ), 'laravel/framework' => array ( - 'pretty_version' => 'v7.30.4', - 'version' => '7.30.4.0', + 'pretty_version' => 'v8.44.0', + 'version' => '8.44.0.0', 'aliases' => array ( ), - 'reference' => '9dd38140dc2924daa1a020a3d7a45f9ceff03df3', + 'reference' => '7b3b27dc8911ab02a69731af2ba97b5130b2ddb8', ), 'laravel/helpers' => array ( @@ -426,12 +440,12 @@ ), 'laravel/horizon' => array ( - 'pretty_version' => 'v4.3.5', - 'version' => '4.3.5.0', + 'pretty_version' => 'v5.7.8', + 'version' => '5.7.8.0', 'aliases' => array ( ), - 'reference' => 'b3fba0daaaaf5e84197b06dd25f3b27bb7301171', + 'reference' => '2b5628b598c813650458dc7e4afacb500d72ff9a', ), 'laravel/laravel' => array ( @@ -440,7 +454,7 @@ 'aliases' => array ( ), - 'reference' => 'e248cd036c7757b009d90b73fcd77176cbb45e76', + 'reference' => '41b78a0599d303bea0254a30f8ebc3c778e3e34e', ), 'laravel/socialite' => array ( @@ -453,12 +467,12 @@ ), 'laravel/ui' => array ( - 'pretty_version' => 'v2.5.0', - 'version' => '2.5.0.0', + 'pretty_version' => 'v3.3.0', + 'version' => '3.3.0.0', 'aliases' => array ( ), - 'reference' => 'd01a705763c243b07be795e9d1bb47f89260f73d', + 'reference' => '07d725813350c695c779382cbd6dac0ab8665537', ), 'laravelcollective/html' => array ( @@ -507,12 +521,12 @@ ), 'lorisleiva/cron-translator' => array ( - 'pretty_version' => 'v0.1.1', - 'version' => '0.1.1.0', + 'pretty_version' => 'v0.2.0', + 'version' => '0.2.0.0', 'aliases' => array ( ), - 'reference' => '784a6f6255a4b5f45da5d89dc6ec631a14d7b011', + 'reference' => '764996770558dddc7def8619095391a4ec8048f2', ), 'mockery/mockery' => array ( @@ -532,6 +546,13 @@ ), 'reference' => '1cb1cde8e8dd0f70cc0fe51354a59acad9302084', ), + 'mtdowling/cron-expression' => + array ( + 'replaced' => + array ( + 0 => '^1.0', + ), + ), 'myclabs/deep-copy' => array ( 'pretty_version' => '1.10.2', @@ -547,21 +568,30 @@ ), 'nesbot/carbon' => array ( - 'pretty_version' => '2.48.0', - 'version' => '2.48.0.0', + 'pretty_version' => '2.48.1', + 'version' => '2.48.1.0', 'aliases' => array ( ), - 'reference' => 'd3c447f21072766cddec3522f9468a5849a76147', + 'reference' => '8d1f50f1436fb4b05e7127360483dd9c6e73da16', + ), + 'nikic/php-parser' => + array ( + 'pretty_version' => 'v4.10.5', + 'version' => '4.10.5.0', + 'aliases' => + array ( + ), + 'reference' => '4432ba399e47c66624bc73c8c0f811e5c109576f', ), 'nunomaduro/collision' => array ( - 'pretty_version' => 'v4.3.0', - 'version' => '4.3.0.0', + 'pretty_version' => 'v5.4.0', + 'version' => '5.4.0.0', 'aliases' => array ( ), - 'reference' => '7c125dc2463f3e144ddc7e05e63077109508c94e', + 'reference' => '41b7e9999133d5082700d31a1d0977161df8322a', ), 'opis/closure' => array ( @@ -637,57 +667,57 @@ ), 'phpunit/php-code-coverage' => array ( - 'pretty_version' => '7.0.14', - 'version' => '7.0.14.0', + 'pretty_version' => '9.2.6', + 'version' => '9.2.6.0', 'aliases' => array ( ), - 'reference' => 'bb7c9a210c72e4709cdde67f8b7362f672f2225c', + 'reference' => 'f6293e1b30a2354e8428e004689671b83871edde', ), 'phpunit/php-file-iterator' => array ( - 'pretty_version' => '2.0.3', - 'version' => '2.0.3.0', + 'pretty_version' => '3.0.5', + 'version' => '3.0.5.0', 'aliases' => array ( ), - 'reference' => '4b49fb70f067272b659ef0174ff9ca40fdaa6357', + 'reference' => 'aa4be8575f26070b100fccb67faabb28f21f66f8', + ), + 'phpunit/php-invoker' => + array ( + 'pretty_version' => '3.1.1', + 'version' => '3.1.1.0', + 'aliases' => + array ( + ), + 'reference' => '5a10147d0aaf65b58940a0b72f71c9ac0423cc67', ), 'phpunit/php-text-template' => array ( - 'pretty_version' => '1.2.1', - 'version' => '1.2.1.0', + 'pretty_version' => '2.0.4', + 'version' => '2.0.4.0', 'aliases' => array ( ), - 'reference' => '31f8b717e51d9a2afca6c9f046f5d69fc27c8686', + 'reference' => '5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28', ), 'phpunit/php-timer' => array ( - 'pretty_version' => '2.1.3', - 'version' => '2.1.3.0', + 'pretty_version' => '5.0.3', + 'version' => '5.0.3.0', 'aliases' => array ( ), - 'reference' => '2454ae1765516d20c4ffe103d85a58a9a3bd5662', - ), - 'phpunit/php-token-stream' => - array ( - 'pretty_version' => '4.0.4', - 'version' => '4.0.4.0', - 'aliases' => - array ( - ), - 'reference' => 'a853a0e183b9db7eed023d7933a858fa1c8d25a3', + 'reference' => '5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2', ), 'phpunit/phpunit' => array ( - 'pretty_version' => '8.5.15', - 'version' => '8.5.15.0', + 'pretty_version' => '9.5.4', + 'version' => '9.5.4.0', 'aliases' => array ( ), - 'reference' => '038d4196d8e8cb405cd5e82cedfe413ad6eef9ef', + 'reference' => 'c73c6737305e779771147af66c96ca6a7ed8a741', ), 'predis/predis' => array ( @@ -730,6 +760,22 @@ 0 => '1.0', ), ), + 'psr/http-client' => + array ( + 'pretty_version' => '1.0.1', + 'version' => '1.0.1.0', + 'aliases' => + array ( + ), + 'reference' => '2dfb5f6c5eff0e91e20e913f8c5452ed95b86621', + ), + 'psr/http-client-implementation' => + array ( + 'provided' => + array ( + 0 => '1.0', + ), + ), 'psr/http-message' => array ( 'pretty_version' => '1.0.1', @@ -806,113 +852,149 @@ 0 => '4.1.1', ), ), - 'sebastian/code-unit-reverse-lookup' => + 'sebastian/cli-parser' => array ( - 'pretty_version' => '1.0.2', - 'version' => '1.0.2.0', + 'pretty_version' => '1.0.1', + 'version' => '1.0.1.0', 'aliases' => array ( ), - 'reference' => '1de8cd5c010cb153fcd68b8d0f64606f523f7619', + 'reference' => '442e7c7e687e42adc03470c7b668bc4b2402c0b2', + ), + 'sebastian/code-unit' => + array ( + 'pretty_version' => '1.0.8', + 'version' => '1.0.8.0', + 'aliases' => + array ( + ), + 'reference' => '1fc9f64c0927627ef78ba436c9b17d967e68e120', + ), + 'sebastian/code-unit-reverse-lookup' => + array ( + 'pretty_version' => '2.0.3', + 'version' => '2.0.3.0', + 'aliases' => + array ( + ), + 'reference' => 'ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5', ), 'sebastian/comparator' => array ( - 'pretty_version' => '3.0.3', - 'version' => '3.0.3.0', + 'pretty_version' => '4.0.6', + 'version' => '4.0.6.0', 'aliases' => array ( ), - 'reference' => '1071dfcef776a57013124ff35e1fc41ccd294758', + 'reference' => '55f4261989e546dc112258c7a75935a81a7ce382', ), - 'sebastian/diff' => - array ( - 'pretty_version' => '3.0.3', - 'version' => '3.0.3.0', - 'aliases' => - array ( - ), - 'reference' => '14f72dd46eaf2f2293cbe79c93cc0bc43161a211', - ), - 'sebastian/environment' => - array ( - 'pretty_version' => '4.2.4', - 'version' => '4.2.4.0', - 'aliases' => - array ( - ), - 'reference' => 'd47bbbad83711771f167c72d4e3f25f7fcc1f8b0', - ), - 'sebastian/exporter' => - array ( - 'pretty_version' => '3.1.3', - 'version' => '3.1.3.0', - 'aliases' => - array ( - ), - 'reference' => '6b853149eab67d4da22291d36f5b0631c0fd856e', - ), - 'sebastian/global-state' => - array ( - 'pretty_version' => '3.0.1', - 'version' => '3.0.1.0', - 'aliases' => - array ( - ), - 'reference' => '474fb9edb7ab891665d3bfc6317f42a0a150454b', - ), - 'sebastian/object-enumerator' => - array ( - 'pretty_version' => '3.0.4', - 'version' => '3.0.4.0', - 'aliases' => - array ( - ), - 'reference' => 'e67f6d32ebd0c749cf9d1dbd9f226c727043cdf2', - ), - 'sebastian/object-reflector' => - array ( - 'pretty_version' => '1.1.2', - 'version' => '1.1.2.0', - 'aliases' => - array ( - ), - 'reference' => '9b8772b9cbd456ab45d4a598d2dd1a1bced6363d', - ), - 'sebastian/recursion-context' => - array ( - 'pretty_version' => '3.0.1', - 'version' => '3.0.1.0', - 'aliases' => - array ( - ), - 'reference' => '367dcba38d6e1977be014dc4b22f47a484dac7fb', - ), - 'sebastian/resource-operations' => + 'sebastian/complexity' => array ( 'pretty_version' => '2.0.2', 'version' => '2.0.2.0', 'aliases' => array ( ), - 'reference' => '31d35ca87926450c44eae7e2611d45a7a65ea8b3', + 'reference' => '739b35e53379900cc9ac327b2147867b8b6efd88', + ), + 'sebastian/diff' => + array ( + 'pretty_version' => '4.0.4', + 'version' => '4.0.4.0', + 'aliases' => + array ( + ), + 'reference' => '3461e3fccc7cfdfc2720be910d3bd73c69be590d', + ), + 'sebastian/environment' => + array ( + 'pretty_version' => '5.1.3', + 'version' => '5.1.3.0', + 'aliases' => + array ( + ), + 'reference' => '388b6ced16caa751030f6a69e588299fa09200ac', + ), + 'sebastian/exporter' => + array ( + 'pretty_version' => '4.0.3', + 'version' => '4.0.3.0', + 'aliases' => + array ( + ), + 'reference' => 'd89cc98761b8cb5a1a235a6b703ae50d34080e65', + ), + 'sebastian/global-state' => + array ( + 'pretty_version' => '5.0.2', + 'version' => '5.0.2.0', + 'aliases' => + array ( + ), + 'reference' => 'a90ccbddffa067b51f574dea6eb25d5680839455', + ), + 'sebastian/lines-of-code' => + array ( + 'pretty_version' => '1.0.3', + 'version' => '1.0.3.0', + 'aliases' => + array ( + ), + 'reference' => 'c1c2e997aa3146983ed888ad08b15470a2e22ecc', + ), + 'sebastian/object-enumerator' => + array ( + 'pretty_version' => '4.0.4', + 'version' => '4.0.4.0', + 'aliases' => + array ( + ), + 'reference' => '5c9eeac41b290a3712d88851518825ad78f45c71', + ), + 'sebastian/object-reflector' => + array ( + 'pretty_version' => '2.0.4', + 'version' => '2.0.4.0', + 'aliases' => + array ( + ), + 'reference' => 'b4f479ebdbf63ac605d183ece17d8d7fe49c15c7', + ), + 'sebastian/recursion-context' => + array ( + 'pretty_version' => '4.0.4', + 'version' => '4.0.4.0', + 'aliases' => + array ( + ), + 'reference' => 'cd9d8cf3c5804de4341c283ed787f099f5506172', + ), + 'sebastian/resource-operations' => + array ( + 'pretty_version' => '3.0.3', + 'version' => '3.0.3.0', + 'aliases' => + array ( + ), + 'reference' => '0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8', ), 'sebastian/type' => array ( - 'pretty_version' => '1.1.4', - 'version' => '1.1.4.0', + 'pretty_version' => '2.3.1', + 'version' => '2.3.1.0', 'aliases' => array ( ), - 'reference' => '0150cfbc4495ed2df3872fb31b26781e4e077eb4', + 'reference' => '81cd61ab7bbf2de744aba0ea61fae32f721df3d2', ), 'sebastian/version' => array ( - 'pretty_version' => '2.0.1', - 'version' => '2.0.1.0', + 'pretty_version' => '3.0.2', + 'version' => '3.0.2.0', 'aliases' => array ( ), - 'reference' => '99732be0ddb3361e16ad77b68ba41efc8e979019', + 'reference' => 'c6c1022351a901512170118436c764e473f6de8c', ), 'socialiteproviders/manager' => array ( @@ -934,12 +1016,12 @@ ), 'spatie/laravel-schedule-monitor' => array ( - 'pretty_version' => '2.0.1', - 'version' => '2.0.1.0', + 'pretty_version' => '2.3.0', + 'version' => '2.3.0.0', 'aliases' => array ( ), - 'reference' => '4ffdaea81b5c27a119b6cbac8f4894657b8fd6d9', + 'reference' => 'cc65f9822d0e0b69043372d6c7d3e8dbd072f85d', ), 'spomky-labs/base64url' => array ( @@ -970,12 +1052,12 @@ ), 'symfony/css-selector' => array ( - 'pretty_version' => 'v5.2.7', - 'version' => '5.2.7.0', + 'pretty_version' => 'v5.2.9', + 'version' => '5.2.9.0', 'aliases' => array ( ), - 'reference' => '59a684f5ac454f066ecbe6daecce6719aed283fb', + 'reference' => '5d5f97809015102116208b976eb2edb44b689560', ), 'symfony/deprecation-contracts' => array ( @@ -1022,12 +1104,12 @@ ), 'symfony/finder' => array ( - 'pretty_version' => 'v5.2.8', - 'version' => '5.2.8.0', + 'pretty_version' => 'v5.2.9', + 'version' => '5.2.9.0', 'aliases' => array ( ), - 'reference' => 'eccb8be70d7a6a2230d05f6ecede40f3fdd9e252', + 'reference' => 'ccccb9d48ca42757dd12f2ca4bf857a4e217d90d', ), 'symfony/http-client-contracts' => array ( @@ -1049,102 +1131,102 @@ ), 'symfony/http-kernel' => array ( - 'pretty_version' => 'v5.2.8', - 'version' => '5.2.8.0', + 'pretty_version' => 'v5.2.9', + 'version' => '5.2.9.0', 'aliases' => array ( ), - 'reference' => 'c3cb71ee7e2d3eae5fe1001f81780d6a49b37937', + 'reference' => 'eb540ef6870dbf33c92e372cfb869ebf9649e6cb', ), 'symfony/mime' => array ( - 'pretty_version' => 'v5.2.7', - 'version' => '5.2.7.0', + 'pretty_version' => 'v5.2.9', + 'version' => '5.2.9.0', 'aliases' => array ( ), - 'reference' => '7af452bf51c46f18da00feb32e1ad36db9426515', + 'reference' => '64258e870f8cc75c3dae986201ea2df58c210b52', ), 'symfony/polyfill-ctype' => array ( - 'pretty_version' => 'v1.22.1', - 'version' => '1.22.1.0', + 'pretty_version' => 'v1.23.0', + 'version' => '1.23.0.0', 'aliases' => array ( ), - 'reference' => 'c6c942b1ac76c82448322025e084cadc56048b4e', + 'reference' => '46cd95797e9df938fdd2b03693b5fca5e64b01ce', ), 'symfony/polyfill-iconv' => array ( - 'pretty_version' => 'v1.22.1', - 'version' => '1.22.1.0', + 'pretty_version' => 'v1.23.0', + 'version' => '1.23.0.0', 'aliases' => array ( ), - 'reference' => '06fb361659649bcfd6a208a0f1fcaf4e827ad342', + 'reference' => '63b5bb7db83e5673936d6e3b8b3e022ff6474933', ), 'symfony/polyfill-intl-grapheme' => array ( - 'pretty_version' => 'v1.22.1', - 'version' => '1.22.1.0', + 'pretty_version' => 'v1.23.0', + 'version' => '1.23.0.0', 'aliases' => array ( ), - 'reference' => '5601e09b69f26c1828b13b6bb87cb07cddba3170', + 'reference' => '24b72c6baa32c746a4d0840147c9715e42bb68ab', ), 'symfony/polyfill-intl-idn' => array ( - 'pretty_version' => 'v1.22.1', - 'version' => '1.22.1.0', + 'pretty_version' => 'v1.23.0', + 'version' => '1.23.0.0', 'aliases' => array ( ), - 'reference' => '2d63434d922daf7da8dd863e7907e67ee3031483', + 'reference' => '65bd267525e82759e7d8c4e8ceea44f398838e65', ), 'symfony/polyfill-intl-normalizer' => array ( - 'pretty_version' => 'v1.22.1', - 'version' => '1.22.1.0', + 'pretty_version' => 'v1.23.0', + 'version' => '1.23.0.0', 'aliases' => array ( ), - 'reference' => '43a0283138253ed1d48d352ab6d0bdb3f809f248', + 'reference' => '8590a5f561694770bdcd3f9b5c69dde6945028e8', ), 'symfony/polyfill-mbstring' => array ( - 'pretty_version' => 'v1.22.1', - 'version' => '1.22.1.0', + 'pretty_version' => 'v1.23.0', + 'version' => '1.23.0.0', 'aliases' => array ( ), - 'reference' => '5232de97ee3b75b0360528dae24e73db49566ab1', + 'reference' => '2df51500adbaebdc4c38dea4c89a2e131c45c8a1', ), 'symfony/polyfill-php72' => array ( - 'pretty_version' => 'v1.22.1', - 'version' => '1.22.1.0', + 'pretty_version' => 'v1.23.0', + 'version' => '1.23.0.0', 'aliases' => array ( ), - 'reference' => 'cc6e6f9b39fe8075b3dabfbaf5b5f645ae1340c9', + 'reference' => '9a142215a36a3888e30d0a9eeea9766764e96976', ), 'symfony/polyfill-php73' => array ( - 'pretty_version' => 'v1.22.1', - 'version' => '1.22.1.0', + 'pretty_version' => 'v1.23.0', + 'version' => '1.23.0.0', 'aliases' => array ( ), - 'reference' => 'a678b42e92f86eca04b7fa4c0f6f19d097fb69e2', + 'reference' => 'fba8933c384d6476ab14fb7b8526e5287ca7e010', ), 'symfony/polyfill-php80' => array ( - 'pretty_version' => 'v1.22.1', - 'version' => '1.22.1.0', + 'pretty_version' => 'v1.23.0', + 'version' => '1.23.0.0', 'aliases' => array ( ), - 'reference' => 'dc3063ba22c2a1fd2f45ed856374d79114998f91', + 'reference' => 'eca0bf41ed421bed1b57c4958bab16aa86b757d0', ), 'symfony/process' => array ( @@ -1157,12 +1239,12 @@ ), 'symfony/routing' => array ( - 'pretty_version' => 'v5.2.7', - 'version' => '5.2.7.0', + 'pretty_version' => 'v5.2.9', + 'version' => '5.2.9.0', 'aliases' => array ( ), - 'reference' => '3f0cab2e95b5e92226f34c2c1aa969d3fc41f48c', + 'reference' => '4a7b2bf5e1221be1902b6853743a9bb317f6925e', ), 'symfony/service-contracts' => array ( @@ -1184,12 +1266,12 @@ ), 'symfony/translation' => array ( - 'pretty_version' => 'v5.2.8', - 'version' => '5.2.8.0', + 'pretty_version' => 'v5.2.9', + 'version' => '5.2.9.0', 'aliases' => array ( ), - 'reference' => '445caa74a5986f1cc9dd91a2975ef68fa7cb2068', + 'reference' => '61af68dba333e2d376a325a29c2a3f2a605b4876', ), 'symfony/translation-contracts' => array ( @@ -1252,12 +1334,12 @@ ), 'vlucas/phpdotenv' => array ( - 'pretty_version' => 'v4.2.0', - 'version' => '4.2.0.0', + 'pretty_version' => 'v5.3.0', + 'version' => '5.3.0.0', 'aliases' => array ( ), - 'reference' => 'da64796370fc4eb03cc277088f6fede9fde88482', + 'reference' => 'b3eac5c7ac896e52deab4a99068e3f4ab12d9e56', ), 'voku/portable-ascii' => array ( diff --git a/vendor/dragonmantank/cron-expression/CHANGELOG.md b/vendor/dragonmantank/cron-expression/CHANGELOG.md index 4e207aadd..fab237574 100644 --- a/vendor/dragonmantank/cron-expression/CHANGELOG.md +++ b/vendor/dragonmantank/cron-expression/CHANGELOG.md @@ -1,5 +1,55 @@ # Change Log +## [3.1.0] - 2020-11-24 + +### Added +- Added `CronExpression::getParts()` method to get parts of the expression as an array (#83) + +### Changed +- Changed to Interfaces for some type hints (#97, #86) +- Dropped minimum PHP version to 7.2 +- Few syntax changes for phpstan compatibility (#93) + +### Fixed +- N/A + +### Deprecated +- Deprecated `CronExpression::factory` in favor of the constructor (#56) +- Deprecated `CronExpression::YEAR` as a formality, the functionality is already removed (#87) + +## [3.0.1] - 2020-10-12 +### Added +- Added support for PHP 8 (#92) +### Changed +- N/A +### Fixed +- N/A + +## [3.0.0] - 2020-03-25 + +**MAJOR CHANGE** - In previous versions of this library, setting both a "Day of Month" and a "Day of Week" would be interpreted as an `AND` statement, not an `OR` statement. For example: + +`30 0 1 * 1` + +would evaluate to "Run 30 minutes after the 0 hour when the Day Of Month is 1 AND a Monday" instead of "Run 30 minutes after the 0 hour on Day Of Month 1 OR a Monday", where the latter is more inline with most cron systems. This means that if your cron expression has both of these fields set, you may see your expression fire more often starting with v3.0.0. + +### Added +- Additional docblocks for IDE and documentation +- Added phpstan as a development dependency +- Added a `Cron\FieldFactoryInterface` to make migrations easier (#38) +### Changed +- Changed some DI testing during TravisCI runs +- `\Cron\CronExpression::determineTimezone()` now checks for `\DateTimeInterface` instead of just `\DateTime` +- Errors with fields now report a more human-understandable error and are 1-based instead of 0-based +- Better support for `\DateTimeImmutable` across the library by typehinting for `\DateTimeInterface` now +- Literals should now be less case-sensative across the board +- Changed logic for when both a Day of Week and a Day of Month are supplied to now be an OR statement, not an AND +### Fixed +- Fixed infinite loop when determining last day of week from literals +- Fixed bug where single number ranges were allowed (ex: `1/10`) +- Fixed nullable FieldFactory in CronExpression where no factory could be supplied +- Fixed issue where logic for dropping seconds to 0 could lead to a timezone change + ## [2.3.1] - 2020-10-12 ### Added - Added support for PHP 8 (#92) diff --git a/vendor/dragonmantank/cron-expression/README.md b/vendor/dragonmantank/cron-expression/README.md index 8e8021b2a..fbdbdea92 100644 --- a/vendor/dragonmantank/cron-expression/README.md +++ b/vendor/dragonmantank/cron-expression/README.md @@ -1,7 +1,7 @@ PHP Cron Expression Parser ========================== -[![Latest Stable Version](https://poser.pugx.org/dragonmantank/cron-expression/v/stable.png)](https://packagist.org/packages/dragonmantank/cron-expression) [![Total Downloads](https://poser.pugx.org/dragonmantank/cron-expression/downloads.png)](https://packagist.org/packages/dragonmantank/cron-expression) [![Build Status](https://secure.travis-ci.org/dragonmantank/cron-expression.png)](http://travis-ci.org/dragonmantank/cron-expression) +[![Latest Stable Version](https://poser.pugx.org/dragonmantank/cron-expression/v/stable.png)](https://packagist.org/packages/dragonmantank/cron-expression) [![Total Downloads](https://poser.pugx.org/dragonmantank/cron-expression/downloads.png)](https://packagist.org/packages/dragonmantank/cron-expression) [![Build Status](https://secure.travis-ci.org/dragonmantank/cron-expression.png)](http://travis-ci.org/dragonmantank/cron-expression) [![StyleCI](https://github.styleci.io/repos/103715337/shield?branch=master)](https://github.styleci.io/repos/103715337) The PHP cron expression parser can parse a CRON expression, determine if it is due to run, calculate the next run date of the expression, and calculate the previous @@ -32,21 +32,21 @@ Usage require_once '/vendor/autoload.php'; // Works with predefined scheduling definitions -$cron = Cron\CronExpression::factory('@daily'); +$cron = new Cron\CronExpression('@daily'); $cron->isDue(); echo $cron->getNextRunDate()->format('Y-m-d H:i:s'); echo $cron->getPreviousRunDate()->format('Y-m-d H:i:s'); // Works with complex expressions -$cron = Cron\CronExpression::factory('3-59/15 6-12 */15 1 2-5'); +$cron = new Cron\CronExpression('3-59/15 6-12 */15 1 2-5'); echo $cron->getNextRunDate()->format('Y-m-d H:i:s'); // Calculate a run date two iterations into the future -$cron = Cron\CronExpression::factory('@daily'); +$cron = new Cron\CronExpression('@daily'); echo $cron->getNextRunDate(null, 2)->format('Y-m-d H:i:s'); // Calculate a run date relative to a specific time -$cron = Cron\CronExpression::factory('@monthly'); +$cron = new Cron\CronExpression('@monthly'); echo $cron->getNextRunDate('2010-01-12 00:00:00')->format('Y-m-d H:i:s'); ``` @@ -65,14 +65,23 @@ A CRON expression is a string representing the schedule for a particular command | +-------------------- hour (0 - 23) +------------------------- min (0 - 59) +This library also supports a few macros: + +* `@yearly`, `@annually` - Run once a year, midnight, Jan. 1 - `0 0 1 1 *` +* `@monthly` - Run once a month, midnight, first of month - `0 0 1 * *` +* `@weekly` - Run once a week, midnight on Sun - `0 0 * * 0` +* `@daily` - Run once a day, midnight - `0 0 * * *` +* `@hourly` - Run once an hour, first minute - `0 * * * *` + Requirements ============ -- PHP 7.0+ +- PHP 7.1+ - PHPUnit is required to run the unit tests - Composer is required to run the unit tests Projects that Use cron-expression ================================= * Part of the [Laravel Framework](https://github.com/laravel/framework/) -* Available as a [Symfony Bundle - setono/cron-expression-bundle](https://github.com/Setono/CronExpressionBundle) \ No newline at end of file +* Available as a [Symfony Bundle - setono/cron-expression-bundle](https://github.com/Setono/CronExpressionBundle) +* Framework agnostic, PHP-based job scheduler - [Crunz](https://github.com/lavary/crunz) diff --git a/vendor/dragonmantank/cron-expression/composer.json b/vendor/dragonmantank/cron-expression/composer.json index 6fcf8184c..59439b054 100644 --- a/vendor/dragonmantank/cron-expression/composer.json +++ b/vendor/dragonmantank/cron-expression/composer.json @@ -5,11 +5,6 @@ "keywords": ["cron", "schedule"], "license": "MIT", "authors": [ - { - "name": "Michael Dowling", - "email": "mtdowling@gmail.com", - "homepage": "https://github.com/mtdowling" - }, { "name": "Chris Tankersley", "email": "chris@ctankersley.com", @@ -17,10 +12,14 @@ } ], "require": { - "php": "^7.0|^8.0" + "php": "^7.2|^8.0", + "webmozart/assert": "^1.7.0" }, "require-dev": { - "phpunit/phpunit": "^6.4|^7.0|^8.0|^9.0" + "phpstan/phpstan": "^0.12", + "phpunit/phpunit": "^7.0|^8.0|^9.0", + "phpstan/phpstan-webmozart-assert": "^0.12.7", + "phpstan/extension-installer": "^1.0" }, "autoload": { "psr-4": { @@ -29,12 +28,14 @@ }, "autoload-dev": { "psr-4": { - "Tests\\": "tests/Cron/" + "Cron\\Tests\\": "tests/Cron/" } }, - "extra": { - "branch-alias": { - "dev-master": "2.3-dev" - } + "replace": { + "mtdowling/cron-expression": "^1.0" + }, + "scripts": { + "phpstan": "./vendor/bin/phpstan analyse -l max src", + "test": "phpunit" } } diff --git a/vendor/dragonmantank/cron-expression/phpstan.neon b/vendor/dragonmantank/cron-expression/phpstan.neon new file mode 100644 index 000000000..9d52fd982 --- /dev/null +++ b/vendor/dragonmantank/cron-expression/phpstan.neon @@ -0,0 +1,2 @@ +parameters: + checkMissingIterableValueType: false diff --git a/vendor/dragonmantank/cron-expression/src/Cron/AbstractField.php b/vendor/dragonmantank/cron-expression/src/Cron/AbstractField.php index 8b1072ab2..22d5d0cf6 100644 --- a/vendor/dragonmantank/cron-expression/src/Cron/AbstractField.php +++ b/vendor/dragonmantank/cron-expression/src/Cron/AbstractField.php @@ -1,33 +1,39 @@ isIncrementsOfRanges($value)) { return $this->isInIncrementsOfRanges($dateValue, $value); - } elseif ($this->isRange($value)) { + } + + if ($this->isRange($value)) { return $this->isInRange($dateValue, $value); } - return $value == '*' || $dateValue == $value; + return '*' === $value || $dateValue === (int) $value; } /** - * Check if a value is a range + * Check if a value is a range. * * @param string $value Value to test * * @return bool */ - public function isRange($value) + public function isRange(string $value): bool { - return strpos($value, '-') !== false; + return false !== strpos($value, '-'); } /** - * Check if a value is an increments of ranges + * Check if a value is an increments of ranges. * * @param string $value Value to test * * @return bool */ - public function isIncrementsOfRanges($value) + public function isIncrementsOfRanges(string $value): bool { - return strpos($value, '/') !== false; + return false !== strpos($value, '/'); } /** - * Test if a value is within a range + * Test if a value is within a range. * - * @param string $dateValue Set date value - * @param string $value Value to test + * @param int $dateValue Set date value + * @param string $value Value to test * * @return bool */ - public function isInRange($dateValue, $value) + public function isInRange(int $dateValue, $value): bool { - $parts = array_map(function($value) { + $parts = array_map( + function ($value) { $value = trim($value); - $value = $this->convertLiterals($value); - return $value; + + return $this->convertLiterals($value); }, explode('-', $value, 2) ); - return $dateValue >= $parts[0] && $dateValue <= $parts[1]; } /** - * Test if a value is within an increments of ranges (offset[-to]/step size) + * Test if a value is within an increments of ranges (offset[-to]/step size). * - * @param string $dateValue Set date value - * @param string $value Value to test + * @param int $dateValue Set date value + * @param string $value Value to test * * @return bool */ - public function isInIncrementsOfRanges($dateValue, $value) + public function isInIncrementsOfRanges(int $dateValue, string $value): bool { $chunks = array_map('trim', explode('/', $value, 2)); $range = $chunks[0]; - $step = isset($chunks[1]) ? $chunks[1] : 0; + $step = $chunks[1] ?? 0; // No step or 0 steps aren't cool - if (is_null($step) || '0' === $step || 0 === $step) { + /** @phpstan-ignore-next-line */ + if (null === $step || '0' === $step || 0 === $step) { return false; } // Expand the * to a full range - if ('*' == $range) { + if ('*' === $range) { $range = $this->rangeStart . '-' . $this->rangeEnd; } // Generate the requested small range $rangeChunks = explode('-', $range, 2); $rangeStart = $rangeChunks[0]; - $rangeEnd = isset($rangeChunks[1]) ? $rangeChunks[1] : $rangeStart; + $rangeEnd = $rangeChunks[1] ?? $rangeStart; if ($rangeStart < $this->rangeStart || $rangeStart > $this->rangeEnd || $rangeStart > $rangeEnd) { throw new \OutOfRangeException('Invalid range start requested'); @@ -143,80 +152,80 @@ abstract class AbstractField implements FieldInterface // Steps larger than the range need to wrap around and be handled slightly differently than smaller steps if ($step >= $this->rangeEnd) { - $thisRange = [$this->fullRange[$step % count($this->fullRange)]]; + $thisRange = [$this->fullRange[$step % \count($this->fullRange)]]; } else { - $thisRange = range($rangeStart, $rangeEnd, $step); + $thisRange = range($rangeStart, $rangeEnd, (int) $step); } - return in_array($dateValue, $thisRange); + return \in_array($dateValue, $thisRange, true); } /** - * Returns a range of values for the given cron expression + * Returns a range of values for the given cron expression. * * @param string $expression The expression to evaluate - * @param int $max Maximum offset for range + * @param int $max Maximum offset for range * * @return array */ - public function getRangeForExpression($expression, $max) + public function getRangeForExpression(string $expression, int $max): array { - $values = array(); + $values = []; $expression = $this->convertLiterals($expression); - if (strpos($expression, ',') !== false) { + if (false !== strpos($expression, ',')) { $ranges = explode(',', $expression); $values = []; foreach ($ranges as $range) { $expanded = $this->getRangeForExpression($range, $this->rangeEnd); $values = array_merge($values, $expanded); } + return $values; } if ($this->isRange($expression) || $this->isIncrementsOfRanges($expression)) { if (!$this->isIncrementsOfRanges($expression)) { - list ($offset, $to) = explode('-', $expression); + [$offset, $to] = explode('-', $expression); $offset = $this->convertLiterals($offset); $to = $this->convertLiterals($to); $stepSize = 1; - } - else { + } else { $range = array_map('trim', explode('/', $expression, 2)); - $stepSize = isset($range[1]) ? $range[1] : 0; + $stepSize = $range[1] ?? 0; $range = $range[0]; $range = explode('-', $range, 2); $offset = $range[0]; - $to = isset($range[1]) ? $range[1] : $max; + $to = $range[1] ?? $max; } - $offset = $offset == '*' ? $this->rangeStart : $offset; + $offset = '*' === $offset ? $this->rangeStart : $offset; if ($stepSize >= $this->rangeEnd) { - $values = [$this->fullRange[$stepSize % count($this->fullRange)]]; + $values = [$this->fullRange[$stepSize % \count($this->fullRange)]]; } else { for ($i = $offset; $i <= $to; $i += $stepSize) { - $values[] = (int)$i; + $values[] = (int) $i; } } sort($values); - } - else { - $values = array($expression); + } else { + $values = [$expression]; } return $values; } /** - * Convert literal + * Convert literal. * * @param string $value + * * @return string */ - protected function convertLiterals($value) + protected function convertLiterals(string $value): string { - if (count($this->literals)) { - $key = array_search($value, $this->literals); - if ($key !== false) { + if (\count($this->literals)) { + $key = array_search(strtoupper($value), $this->literals, true); + if (false !== $key) { return (string) $key; } } @@ -225,12 +234,13 @@ abstract class AbstractField implements FieldInterface } /** - * Checks to see if a value is valid for the field + * Checks to see if a value is valid for the field. * * @param string $value + * * @return bool */ - public function validate($value) + public function validate(string $value): bool { $value = $this->convertLiterals($value); @@ -239,22 +249,29 @@ abstract class AbstractField implements FieldInterface return true; } - if (strpos($value, '/') !== false) { - list($range, $step) = explode('/', $value); + if (false !== strpos($value, '/')) { + [$range, $step] = explode('/', $value); + + // Don't allow numeric ranges + if (is_numeric($range)) { + return false; + } + return $this->validate($range) && filter_var($step, FILTER_VALIDATE_INT); } // Validate each chunk of a list individually - if (strpos($value, ',') !== false) { + if (false !== strpos($value, ',')) { foreach (explode(',', $value) as $listItem) { if (!$this->validate($listItem)) { return false; } } + return true; } - if (strpos($value, '-') !== false) { + if (false !== strpos($value, '-')) { if (substr_count($value, '-') > 1) { return false; } @@ -263,7 +280,7 @@ abstract class AbstractField implements FieldInterface $chunks[0] = $this->convertLiterals($chunks[0]); $chunks[1] = $this->convertLiterals($chunks[1]); - if ('*' == $chunks[0] || '*' == $chunks[1]) { + if ('*' === $chunks[0] || '*' === $chunks[1]) { return false; } @@ -274,13 +291,13 @@ abstract class AbstractField implements FieldInterface return false; } - if (is_float($value) || strpos($value, '.') !== false) { + if (false !== strpos($value, '.')) { return false; } // We should have a numeric by now, so coerce this into an integer $value = (int) $value; - return in_array($value, $this->fullRange, true); + return \in_array($value, $this->fullRange, true); } } diff --git a/vendor/dragonmantank/cron-expression/src/Cron/CronExpression.php b/vendor/dragonmantank/cron-expression/src/Cron/CronExpression.php index 594b43582..9b342761b 100644 --- a/vendor/dragonmantank/cron-expression/src/Cron/CronExpression.php +++ b/vendor/dragonmantank/cron-expression/src/Cron/CronExpression.php @@ -1,5 +1,7 @@ '0 0 1 1 *', + '@annually' => '0 0 1 1 *', + '@monthly' => '0 0 1 * *', + '@weekly' => '0 0 * * 0', + '@daily' => '0 0 * * *', + '@hourly' => '0 * * * *', + ]; /** * @var array CRON expression parts @@ -37,7 +51,7 @@ class CronExpression private $cronParts; /** - * @var FieldFactory CRON field factory + * @var FieldFactoryInterface CRON field factory */ private $fieldFactory; @@ -49,54 +63,35 @@ class CronExpression /** * @var array Order in which to test of cron parts */ - private static $order = array(self::YEAR, self::MONTH, self::DAY, self::WEEKDAY, self::HOUR, self::MINUTE); + private static $order = [ + self::YEAR, + self::MONTH, + self::DAY, + self::WEEKDAY, + self::HOUR, + self::MINUTE, + ]; /** - * Factory method to create a new CronExpression. - * - * @param string $expression The CRON expression to create. There are - * several special predefined values which can be used to substitute the - * CRON expression: - * - * `@yearly`, `@annually` - Run once a year, midnight, Jan. 1 - 0 0 1 1 * - * `@monthly` - Run once a month, midnight, first of month - 0 0 1 * * - * `@weekly` - Run once a week, midnight on Sun - 0 0 * * 0 - * `@daily` - Run once a day, midnight - 0 0 * * * - * `@hourly` - Run once an hour, first minute - 0 * * * * - * @param FieldFactory|null $fieldFactory Field factory to use - * - * @return CronExpression + * @deprecated since version 3.0.2, use __construct instead. */ - public static function factory($expression, FieldFactory $fieldFactory = null) + public static function factory(string $expression, FieldFactoryInterface $fieldFactory = null): CronExpression { - $mappings = array( - '@yearly' => '0 0 1 1 *', - '@annually' => '0 0 1 1 *', - '@monthly' => '0 0 1 * *', - '@weekly' => '0 0 * * 0', - '@daily' => '0 0 * * *', - '@hourly' => '0 * * * *' - ); - - if (isset($mappings[$expression])) { - $expression = $mappings[$expression]; - } - - return new static($expression, $fieldFactory ?: new FieldFactory()); + /** @phpstan-ignore-next-line */ + return new static($expression, $fieldFactory); } /** * Validate a CronExpression. * - * @param string $expression The CRON expression to validate. + * @param string $expression the CRON expression to validate * * @return bool True if a valid CRON expression was passed. False if not. - * @see \Cron\CronExpression::factory */ - public static function isValidExpression($expression) + public static function isValidExpression(string $expression): bool { try { - self::factory($expression); + new CronExpression($expression); } catch (InvalidArgumentException $e) { return false; } @@ -105,29 +100,36 @@ class CronExpression } /** - * Parse a CRON expression + * Parse a CRON expression. * - * @param string $expression CRON expression (e.g. '8 * * * *') - * @param FieldFactory|null $fieldFactory Factory to create cron fields + * @param string $expression CRON expression (e.g. '8 * * * *') + * @param null|FieldFactoryInterface $fieldFactory Factory to create cron fields */ - public function __construct($expression, FieldFactory $fieldFactory = null) + public function __construct(string $expression, FieldFactoryInterface $fieldFactory = null) { - $this->fieldFactory = $fieldFactory; + $shortcut = strtolower($expression); + $expression = self::MAPPINGS[$shortcut] ?? $expression; + + $this->fieldFactory = $fieldFactory ?: new FieldFactory(); $this->setExpression($expression); } /** - * Set or change the CRON expression + * Set or change the CRON expression. * * @param string $value CRON expression (e.g. 8 * * * *) * - * @return CronExpression * @throws \InvalidArgumentException if not a valid CRON expression + * + * @return CronExpression */ - public function setExpression($value) + public function setExpression(string $value): CronExpression { - $this->cronParts = preg_split('/\s/', $value, -1, PREG_SPLIT_NO_EMPTY); - if (count($this->cronParts) < 5) { + $split = preg_split('/\s/', $value, -1, PREG_SPLIT_NO_EMPTY); + Assert::isArray($split); + + $this->cronParts = $split; + if (\count($this->cronParts) < 5) { throw new InvalidArgumentException( $value . ' is not a valid CRON expression' ); @@ -141,15 +143,16 @@ class CronExpression } /** - * Set part of the CRON expression + * Set part of the CRON expression. * - * @param int $position The position of the CRON expression to set - * @param string $value The value to set + * @param int $position The position of the CRON expression to set + * @param string $value The value to set + * + * @throws \InvalidArgumentException if the value is not valid for the part * * @return CronExpression - * @throws \InvalidArgumentException if the value is not valid for the part */ - public function setPart($position, $value) + public function setPart(int $position, string $value): CronExpression { if (!$this->fieldFactory->getField($position)->validate($value)) { throw new InvalidArgumentException( @@ -163,13 +166,13 @@ class CronExpression } /** - * Set max iteration count for searching next run dates + * Set max iteration count for searching next run dates. * * @param int $maxIterationCount Max iteration count when searching for next run date * * @return CronExpression */ - public function setMaxIterationCount($maxIterationCount) + public function setMaxIterationCount(int $maxIterationCount): CronExpression { $this->maxIterationCount = $maxIterationCount; @@ -191,16 +194,18 @@ class CronExpression * it matches the cron expression. * @param null|string $timeZone TimeZone to use instead of the system default * - * @return \DateTime * @throws \RuntimeException on too many iterations + * @throws \Exception + * + * @return \DateTime */ - public function getNextRunDate($currentTime = 'now', $nth = 0, $allowCurrentDate = false, $timeZone = null) + public function getNextRunDate($currentTime = 'now', int $nth = 0, bool $allowCurrentDate = false, $timeZone = null): DateTime { return $this->getRunDate($currentTime, $nth, false, $allowCurrentDate, $timeZone); } /** - * Get a previous run date relative to the current date or a specific date + * Get a previous run date relative to the current date or a specific date. * * @param string|\DateTimeInterface $currentTime Relative calculation date * @param int $nth Number of matches to skip before returning @@ -208,31 +213,35 @@ class CronExpression * current date if it matches the cron expression * @param null|string $timeZone TimeZone to use instead of the system default * - * @return \DateTime * @throws \RuntimeException on too many iterations + * @throws \Exception + * + * @return \DateTime + * * @see \Cron\CronExpression::getNextRunDate */ - public function getPreviousRunDate($currentTime = 'now', $nth = 0, $allowCurrentDate = false, $timeZone = null) + public function getPreviousRunDate($currentTime = 'now', int $nth = 0, bool $allowCurrentDate = false, $timeZone = null): DateTime { return $this->getRunDate($currentTime, $nth, true, $allowCurrentDate, $timeZone); } /** - * Get multiple run dates starting at the current date or a specific date + * Get multiple run dates starting at the current date or a specific date. * - * @param int $total Set the total number of dates to calculate - * @param string|\DateTimeInterface $currentTime Relative calculation date - * @param bool $invert Set to TRUE to retrieve previous dates - * @param bool $allowCurrentDate Set to TRUE to return the - * current date if it matches the cron expression - * @param null|string $timeZone TimeZone to use instead of the system default + * @param int $total Set the total number of dates to calculate + * @param string|\DateTimeInterface|null $currentTime Relative calculation date + * @param bool $invert Set to TRUE to retrieve previous dates + * @param bool $allowCurrentDate Set to TRUE to return the + * current date if it matches the cron expression + * @param null|string $timeZone TimeZone to use instead of the system default * * @return \DateTime[] Returns an array of run dates */ - public function getMultipleRunDates($total, $currentTime = 'now', $invert = false, $allowCurrentDate = false, $timeZone = null) + public function getMultipleRunDates(int $total, $currentTime = 'now', bool $invert = false, bool $allowCurrentDate = false, $timeZone = null): array { - $matches = array(); - for ($i = 0; $i < max(0, $total); $i++) { + $matches = []; + $max = max(0, $total); + for ($i = 0; $i < $max; ++$i) { try { $matches[] = $this->getRunDate($currentTime, $i, $invert, $allowCurrentDate, $timeZone); } catch (RuntimeException $e) { @@ -244,33 +253,46 @@ class CronExpression } /** - * Get all or part of the CRON expression + * Get all or part of the CRON expression. * - * @param string $part Specify the part to retrieve or NULL to get the full - * cron schedule string. + * @param int|string|null $part specify the part to retrieve or NULL to get the full + * cron schedule string * - * @return string|null Returns the CRON expression, a part of the + * @return null|string Returns the CRON expression, a part of the * CRON expression, or NULL if the part was specified but not found */ - public function getExpression($part = null) + public function getExpression($part = null): ?string { if (null === $part) { return implode(' ', $this->cronParts); - } elseif (array_key_exists($part, $this->cronParts)) { + } + + if (array_key_exists($part, $this->cronParts)) { return $this->cronParts[$part]; } return null; } + /** + * Gets the parts of the cron expression as an array. + * + * @return string[] + * The array of parts that make up this expression. + */ + public function getParts() + { + return $this->cronParts; + } + /** * Helper method to output the full expression. * * @return string Full CRON expression */ - public function __toString() + public function __toString(): string { - return $this->getExpression(); + return (string) $this->getExpression(); } /** @@ -283,23 +305,25 @@ class CronExpression * * @return bool Returns TRUE if the cron is due to run or FALSE if not */ - public function isDue($currentTime = 'now', $timeZone = null) + public function isDue($currentTime = 'now', $timeZone = null): bool { $timeZone = $this->determineTimeZone($currentTime, $timeZone); if ('now' === $currentTime) { $currentTime = new DateTime(); } elseif ($currentTime instanceof DateTime) { - // + $currentTime = clone $currentTime; } elseif ($currentTime instanceof DateTimeImmutable) { $currentTime = DateTime::createFromFormat('U', $currentTime->format('U')); - } else { + } elseif (\is_string($currentTime)) { $currentTime = new DateTime($currentTime); } - $currentTime->setTimeZone(new DateTimeZone($timeZone)); + + Assert::isInstanceOf($currentTime, DateTime::class); + $currentTime->setTimezone(new DateTimeZone($timeZone)); // drop the seconds to 0 - $currentTime = DateTime::createFromFormat('Y-m-d H:i', $currentTime->format('Y-m-d H:i')); + $currentTime->setTime((int) $currentTime->format('H'), (int) $currentTime->format('i'), 0); try { return $this->getNextRunDate($currentTime, 0, true)->getTimestamp() === $currentTime->getTimestamp(); @@ -309,19 +333,21 @@ class CronExpression } /** - * Get the next or previous run date of the expression relative to a date + * Get the next or previous run date of the expression relative to a date. * - * @param string|\DateTimeInterface $currentTime Relative calculation date - * @param int $nth Number of matches to skip before returning - * @param bool $invert Set to TRUE to go backwards in time - * @param bool $allowCurrentDate Set to TRUE to return the - * current date if it matches the cron expression - * @param string|null $timeZone TimeZone to use instead of the system default + * @param string|\DateTimeInterface|null $currentTime Relative calculation date + * @param int $nth Number of matches to skip before returning + * @param bool $invert Set to TRUE to go backwards in time + * @param bool $allowCurrentDate Set to TRUE to return the + * current date if it matches the cron expression + * @param string|null $timeZone TimeZone to use instead of the system default + * + * @throws \RuntimeException on too many iterations + * @throws Exception * * @return \DateTime - * @throws \RuntimeException on too many iterations */ - protected function getRunDate($currentTime = null, $nth = 0, $invert = false, $allowCurrentDate = false, $timeZone = null) + protected function getRunDate($currentTime = null, int $nth = 0, bool $invert = false, bool $allowCurrentDate = false, $timeZone = null): DateTime { $timeZone = $this->determineTimeZone($currentTime, $timeZone); @@ -329,18 +355,21 @@ class CronExpression $currentDate = clone $currentTime; } elseif ($currentTime instanceof DateTimeImmutable) { $currentDate = DateTime::createFromFormat('U', $currentTime->format('U')); + } elseif (\is_string($currentTime)) { + $currentDate = new DateTime($currentTime); } else { - $currentDate = new DateTime($currentTime ?: 'now'); + $currentDate = new DateTime('now'); } - $currentDate->setTimeZone(new DateTimeZone($timeZone)); - $currentDate->setTime($currentDate->format('H'), $currentDate->format('i'), 0); + Assert::isInstanceOf($currentDate, DateTime::class); + $currentDate->setTimezone(new DateTimeZone($timeZone)); + $currentDate->setTime((int) $currentDate->format('H'), (int) $currentDate->format('i'), 0); + $nextRun = clone $currentDate; - $nth = (int) $nth; // We don't have to satisfy * or null fields - $parts = array(); - $fields = array(); + $parts = []; + $fields = []; foreach (self::$order as $position) { $part = $this->getExpression($position); if (null === $part || '*' === $part) { @@ -350,20 +379,38 @@ class CronExpression $fields[$position] = $this->fieldFactory->getField($position); } - // Set a hard limit to bail on an impossible date - for ($i = 0; $i < $this->maxIterationCount; $i++) { + if (isset($parts[2]) && isset($parts[4])) { + $domExpression = sprintf('%s %s %s %s *', $this->getExpression(0), $this->getExpression(1), $this->getExpression(2), $this->getExpression(3)); + $dowExpression = sprintf('%s %s * %s %s', $this->getExpression(0), $this->getExpression(1), $this->getExpression(3), $this->getExpression(4)); + $domExpression = new self($domExpression); + $dowExpression = new self($dowExpression); + + $domRunDates = $domExpression->getMultipleRunDates($nth + 1, $currentTime, $invert, $allowCurrentDate, $timeZone); + $dowRunDates = $dowExpression->getMultipleRunDates($nth + 1, $currentTime, $invert, $allowCurrentDate, $timeZone); + + $combined = array_merge($domRunDates, $dowRunDates); + usort($combined, function ($a, $b) { + return $a->format('Y-m-d H:i:s') <=> $b->format('Y-m-d H:i:s'); + }); + + return $combined[$nth]; + } + + // Set a hard limit to bail on an impossible date + for ($i = 0; $i < $this->maxIterationCount; ++$i) { foreach ($parts as $position => $part) { $satisfied = false; // Get the field object used to validate this part $field = $fields[$position]; // Check if this is singular or a list - if (strpos($part, ',') === false) { + if (false === strpos($part, ',')) { $satisfied = $field->isSatisfiedBy($nextRun, $part); } else { foreach (array_map('trim', explode(',', $part)) as $listPart) { if ($field->isSatisfiedBy($nextRun, $listPart)) { $satisfied = true; + break; } } @@ -372,13 +419,15 @@ class CronExpression // If the field is not satisfied, then start over if (!$satisfied) { $field->increment($nextRun, $invert, $part); + continue 2; } } // Skip this match if needed if ((!$allowCurrentDate && $nextRun == $currentDate) || --$nth > -1) { - $this->fieldFactory->getField(0)->increment($nextRun, $invert, isset($parts[0]) ? $parts[0] : null); + $this->fieldFactory->getField(0)->increment($nextRun, $invert, $parts[0] ?? null); + continue; } @@ -393,18 +442,18 @@ class CronExpression /** * Workout what timeZone should be used. * - * @param string|\DateTimeInterface $currentTime Relative calculation date - * @param string|null $timeZone TimeZone to use instead of the system default + * @param string|\DateTimeInterface|null $currentTime Relative calculation date + * @param string|null $timeZone TimeZone to use instead of the system default * * @return string */ - protected function determineTimeZone($currentTime, $timeZone) + protected function determineTimeZone($currentTime, ?string $timeZone): string { - if (! is_null($timeZone)) { + if (null !== $timeZone) { return $timeZone; } - if ($currentTime instanceOf DateTimeInterface) { + if ($currentTime instanceof DateTimeInterface) { return $currentTime->getTimeZone()->getName(); } diff --git a/vendor/dragonmantank/cron-expression/src/Cron/DayOfMonthField.php b/vendor/dragonmantank/cron-expression/src/Cron/DayOfMonthField.php index d4552e06b..21c2d97e7 100644 --- a/vendor/dragonmantank/cron-expression/src/Cron/DayOfMonthField.php +++ b/vendor/dragonmantank/cron-expression/src/Cron/DayOfMonthField.php @@ -1,12 +1,14 @@ format('N'); if ($currentWeekday < 6) { @@ -55,56 +62,60 @@ class DayOfMonthField extends AbstractField } $lastDayOfMonth = $target->format('t'); - - foreach (array(-1, 1, -2, 2) as $i) { + foreach ([-1, 1, -2, 2] as $i) { $adjusted = $targetDay + $i; if ($adjusted > 0 && $adjusted <= $lastDayOfMonth) { $target->setDate($currentYear, $currentMonth, $adjusted); - if ($target->format('N') < 6 && $target->format('m') == $currentMonth) { + + if ((int) $target->format('N') < 6 && (int) $target->format('m') === $currentMonth) { return $target; } } } + + return null; } /** - * @inheritDoc + * {@inheritdoc} */ - public function isSatisfiedBy(DateTimeInterface $date, $value) + public function isSatisfiedBy(DateTimeInterface $date, $value): bool { // ? states that the field value is to be skipped - if ($value == '?') { + if ('?' === $value) { return true; } $fieldValue = $date->format('d'); // Check to see if this is the last day of the month - if ($value == 'L') { - return $fieldValue == $date->format('t'); + if ('L' === $value) { + return $fieldValue === $date->format('t'); } // Check to see if this is the nearest weekday to a particular value if (strpos($value, 'W')) { // Parse the target day - $targetDay = substr($value, 0, strpos($value, 'W')); + /** @phpstan-ignore-next-line */ + $targetDay = (int) substr($value, 0, strpos($value, 'W')); // Find out if the current day is the nearest day of the week - return $date->format('j') == self::getNearestWeekday( - $date->format('Y'), - $date->format('m'), + /** @phpstan-ignore-next-line */ + return $date->format('j') === self::getNearestWeekday( + (int) $date->format('Y'), + (int) $date->format('m'), $targetDay )->format('j'); } - return $this->isSatisfied($date->format('d'), $value); + return $this->isSatisfied((int) $date->format('d'), $value); } /** * @inheritDoc * - * @param \DateTime|\DateTimeImmutable &$date + * @param \DateTime|\DateTimeImmutable $date */ - public function increment(DateTimeInterface &$date, $invert = false) + public function increment(DateTimeInterface &$date, $invert = false, $parts = null): FieldInterface { if ($invert) { $date = $date->modify('previous day')->setTime(23, 59); @@ -116,20 +127,23 @@ class DayOfMonthField extends AbstractField } /** - * @inheritDoc + * {@inheritdoc} */ - public function validate($value) + public function validate(string $value): bool { $basicChecks = parent::validate($value); // Validate that a list don't have W or L - if (strpos($value, ',') !== false && (strpos($value, 'W') !== false || strpos($value, 'L') !== false)) { + if (false !== strpos($value, ',') && (false !== strpos($value, 'W') || false !== strpos($value, 'L'))) { return false; } if (!$basicChecks) { + if ('?' === $value) { + return true; + } - if ($value === 'L') { + if ('L' === $value) { return true; } diff --git a/vendor/dragonmantank/cron-expression/src/Cron/DayOfWeekField.php b/vendor/dragonmantank/cron-expression/src/Cron/DayOfWeekField.php index d4ba3156e..980569516 100644 --- a/vendor/dragonmantank/cron-expression/src/Cron/DayOfWeekField.php +++ b/vendor/dragonmantank/cron-expression/src/Cron/DayOfWeekField.php @@ -1,5 +1,7 @@ 'MON', 2 => 'TUE', 3 => 'WED', 4 => 'THU', 5 => 'FRI', 6 => 'SAT', 7 => 'SUN']; @@ -55,39 +57,39 @@ class DayOfWeekField extends AbstractField * * @param \DateTime|\DateTimeImmutable $date */ - public function isSatisfiedBy(DateTimeInterface $date, $value) + public function isSatisfiedBy(DateTimeInterface $date, $value): bool { - if ($value == '?') { + if ('?' === $value) { return true; } // Convert text day of the week values to integers $value = $this->convertLiterals($value); - $currentYear = $date->format('Y'); - $currentMonth = $date->format('m'); - $lastDayOfMonth = $date->format('t'); + $currentYear = (int) $date->format('Y'); + $currentMonth = (int) $date->format('m'); + $lastDayOfMonth = (int) $date->format('t'); // Find out if this is the last specific weekday of the month if (strpos($value, 'L')) { - $weekday = (int) $this->convertLiterals(substr($value, 0, strpos($value, 'L'))); + /** @phpstan-ignore-next-line */ + $weekday = $this->convertLiterals(substr($value, 0, strpos($value, 'L'))); $weekday %= 7; $tdate = clone $date; $tdate = $tdate->setDate($currentYear, $currentMonth, $lastDayOfMonth); while ($tdate->format('w') != $weekday) { $tdateClone = new DateTime(); - $tdate = $tdateClone - ->setTimezone($tdate->getTimezone()) + $tdate = $tdateClone->setTimezone($tdate->getTimezone()) ->setDate($currentYear, $currentMonth, --$lastDayOfMonth); } - return $date->format('j') == $lastDayOfMonth; + return (int) $date->format('j') === $lastDayOfMonth; } // Handle # hash tokens if (strpos($value, '#')) { - list($weekday, $nth) = explode('#', $value); + [$weekday, $nth] = explode('#', $value); if (!is_numeric($nth)) { throw new InvalidArgumentException("Hashed weekdays must be numeric, {$nth} given"); @@ -96,23 +98,23 @@ class DayOfWeekField extends AbstractField } // 0 and 7 are both Sunday, however 7 matches date('N') format ISO-8601 - if ($weekday === '0') { + if ('0' === $weekday) { $weekday = 7; } - $weekday = $this->convertLiterals($weekday); + $weekday = (int) $this->convertLiterals((string) $weekday); // Validate the hash fields if ($weekday < 0 || $weekday > 7) { throw new InvalidArgumentException("Weekday must be a value between 0 and 7. {$weekday} given"); } - if (!in_array($nth, $this->nthRange)) { + if (!\in_array($nth, $this->nthRange, true)) { throw new InvalidArgumentException("There are never more than 5 or less than 1 of a given weekday in a month, {$nth} given"); } // The current weekday must match the targeted weekday to proceed - if ($date->format('N') != $weekday) { + if ((int) $date->format('N') !== $weekday) { return false; } @@ -121,7 +123,7 @@ class DayOfWeekField extends AbstractField $dayCount = 0; $currentDay = 1; while ($currentDay < $lastDayOfMonth + 1) { - if ($tdate->format('N') == $weekday) { + if ((int) $tdate->format('N') === $weekday) { if (++$dayCount >= $nth) { break; } @@ -129,23 +131,25 @@ class DayOfWeekField extends AbstractField $tdate = $tdate->setDate($currentYear, $currentMonth, ++$currentDay); } - return $date->format('j') == $currentDay; + return (int) $date->format('j') === $currentDay; } // Handle day of the week values - if (strpos($value, '-')) { + if (false !== strpos($value, '-')) { $parts = explode('-', $value); - if ($parts[0] == '7') { - $parts[0] = '0'; - } elseif ($parts[1] == '0') { - $parts[1] = '7'; + if ('7' === $parts[0]) { + $parts[0] = 0; + } elseif ('0' === $parts[1]) { + $parts[1] = 7; } $value = implode('-', $parts); } // Test to see which Sunday to use -- 0 == 7 == Sunday - $format = in_array(7, str_split($value)) ? 'N' : 'w'; - $fieldValue = $date->format($format); + $format = \in_array(7, array_map(function ($value) { + return (int) $value; + }, str_split($value)), true) ? 'N' : 'w'; + $fieldValue = (int) $date->format($format); return $this->isSatisfied($fieldValue, $value); } @@ -153,9 +157,9 @@ class DayOfWeekField extends AbstractField /** * @inheritDoc * - * @param \DateTime|\DateTimeImmutable &$date + * @param \DateTime|\DateTimeImmutable $date */ - public function increment(DateTimeInterface &$date, $invert = false) + public function increment(DateTimeInterface &$date, $invert = false, $parts = null): FieldInterface { if ($invert) { $date = $date->modify('-1 day')->setTime(23, 59, 0); @@ -167,19 +171,23 @@ class DayOfWeekField extends AbstractField } /** - * @inheritDoc + * {@inheritdoc} */ - public function validate($value) + public function validate(string $value): bool { $basicChecks = parent::validate($value); if (!$basicChecks) { + if ('?' === $value) { + return true; + } + // Handle the # value - if (strpos($value, '#') !== false) { + if (false !== strpos($value, '#')) { $chunks = explode('#', $value); $chunks[0] = $this->convertLiterals($chunks[0]); - if (parent::validate($chunks[0]) && is_numeric($chunks[1]) && in_array($chunks[1], $this->nthRange)) { + if (parent::validate($chunks[0]) && is_numeric($chunks[1]) && \in_array((int) $chunks[1], $this->nthRange, true)) { return true; } } diff --git a/vendor/dragonmantank/cron-expression/src/Cron/FieldFactory.php b/vendor/dragonmantank/cron-expression/src/Cron/FieldFactory.php index 545e4b837..839b2757d 100644 --- a/vendor/dragonmantank/cron-expression/src/Cron/FieldFactory.php +++ b/vendor/dragonmantank/cron-expression/src/Cron/FieldFactory.php @@ -1,54 +1,52 @@ fields[$position])) { - switch ($position) { - case 0: - $this->fields[$position] = new MinutesField(); - break; - case 1: - $this->fields[$position] = new HoursField(); - break; - case 2: - $this->fields[$position] = new DayOfMonthField(); - break; - case 3: - $this->fields[$position] = new MonthField(); - break; - case 4: - $this->fields[$position] = new DayOfWeekField(); - break; - default: - throw new InvalidArgumentException( - ($position + 1) . ' is not a valid position' - ); - } + return $this->fields[$position] ?? $this->fields[$position] = $this->instantiateField($position); + } + + private function instantiateField(int $position): FieldInterface + { + switch ($position) { + case CronExpression::MINUTE: + return new MinutesField(); + case CronExpression::HOUR: + return new HoursField(); + case CronExpression::DAY: + return new DayOfMonthField(); + case CronExpression::MONTH: + return new MonthField(); + case CronExpression::WEEKDAY: + return new DayOfWeekField(); } - return $this->fields[$position]; + throw new InvalidArgumentException( + ($position + 1) . ' is not a valid position' + ); } } diff --git a/vendor/dragonmantank/cron-expression/src/Cron/FieldFactoryInterface.php b/vendor/dragonmantank/cron-expression/src/Cron/FieldFactoryInterface.php new file mode 100644 index 000000000..8bd3c6581 --- /dev/null +++ b/vendor/dragonmantank/cron-expression/src/Cron/FieldFactoryInterface.php @@ -0,0 +1,8 @@ +isSatisfied($date->format('H'), $value); + return $this->isSatisfied((int) $date->format('H'), $value); } /** - * {@inheritDoc} + * {@inheritdoc} * - * @param \DateTime|\DateTimeImmutable &$date + * @param \DateTime|\DateTimeImmutable $date * @param string|null $parts */ - public function increment(DateTimeInterface &$date, $invert = false, $parts = null) + public function increment(DateTimeInterface &$date, $invert = false, $parts = null): FieldInterface { // Change timezone to UTC temporarily. This will // allow us to go back or forwards and hour even // if DST will be changed between the hours. - if (is_null($parts) || $parts == '*') { + if (null === $parts || '*' === $parts) { $timezone = $date->getTimezone(); $date = $date->setTimezone(new DateTimeZone('UTC')); $date = $date->modify(($invert ? '-' : '+') . '1 hour'); $date = $date->setTimezone($timezone); - $date = $date->setTime($date->format('H'), $invert ? 59 : 0); + $date = $date->setTime((int)$date->format('H'), $invert ? 59 : 0); return $this; } - $parts = strpos($parts, ',') !== false ? explode(',', $parts) : array($parts); - $hours = array(); + $parts = false !== strpos($parts, ',') ? explode(',', $parts) : [$parts]; + $hours = []; foreach ($parts as $part) { $hours = array_merge($hours, $this->getRangeForExpression($part, 23)); } $current_hour = $date->format('H'); - $position = $invert ? count($hours) - 1 : 0; - if (count($hours) > 1) { - for ($i = 0; $i < count($hours) - 1; $i++) { + $position = $invert ? \count($hours) - 1 : 0; + $countHours = \count($hours); + if ($countHours > 1) { + for ($i = 0; $i < $countHours - 1; ++$i) { if ((!$invert && $current_hour >= $hours[$i] && $current_hour < $hours[$i + 1]) || ($invert && $current_hour > $hours[$i] && $current_hour <= $hours[$i + 1])) { $position = $invert ? $i : $i + 1; + break; } } } - $hour = $hours[$position]; - if ((!$invert && $date->format('H') >= $hour) || ($invert && $date->format('H') <= $hour)) { + $hour = (int) $hours[$position]; + if ((!$invert && (int) $date->format('H') >= $hour) || ($invert && (int) $date->format('H') <= $hour)) { $date = $date->modify(($invert ? '-' : '+') . '1 day'); $date = $date->setTime($invert ? 23 : 0, $invert ? 59 : 0); - } - else { + } else { $date = $date->setTime($hour, $invert ? 59 : 0); } diff --git a/vendor/dragonmantank/cron-expression/src/Cron/MinutesField.php b/vendor/dragonmantank/cron-expression/src/Cron/MinutesField.php index fecc9b6da..d95ba7492 100644 --- a/vendor/dragonmantank/cron-expression/src/Cron/MinutesField.php +++ b/vendor/dragonmantank/cron-expression/src/Cron/MinutesField.php @@ -1,62 +1,66 @@ isSatisfied($date->format('i'), $value); + return $this->isSatisfied((int)$date->format('i'), $value); } /** + * {@inheritdoc} * {@inheritDoc} * - * @param \DateTime|\DateTimeImmutable &$date + * @param \DateTime|\DateTimeImmutable $date * @param string|null $parts */ - public function increment(DateTimeInterface &$date, $invert = false, $parts = null) + public function increment(DateTimeInterface &$date, $invert = false, $parts = null): FieldInterface { if (is_null($parts)) { $date = $date->modify(($invert ? '-' : '+') . '1 minute'); return $this; } - $parts = strpos($parts, ',') !== false ? explode(',', $parts) : array($parts); - $minutes = array(); + $parts = false !== strpos($parts, ',') ? explode(',', $parts) : [$parts]; + $minutes = []; foreach ($parts as $part) { $minutes = array_merge($minutes, $this->getRangeForExpression($part, 59)); } $current_minute = $date->format('i'); - $position = $invert ? count($minutes) - 1 : 0; - if (count($minutes) > 1) { - for ($i = 0; $i < count($minutes) - 1; $i++) { + $position = $invert ? \count($minutes) - 1 : 0; + if (\count($minutes) > 1) { + for ($i = 0; $i < \count($minutes) - 1; ++$i) { if ((!$invert && $current_minute >= $minutes[$i] && $current_minute < $minutes[$i + 1]) || ($invert && $current_minute > $minutes[$i] && $current_minute <= $minutes[$i + 1])) { $position = $invert ? $i : $i + 1; + break; } } @@ -64,10 +68,9 @@ class MinutesField extends AbstractField if ((!$invert && $current_minute >= $minutes[$position]) || ($invert && $current_minute <= $minutes[$position])) { $date = $date->modify(($invert ? '-' : '+') . '1 hour'); - $date = $date->setTime($date->format('H'), $invert ? 59 : 0); - } - else { - $date = $date->setTime($date->format('H'), $minutes[$position]); + $date = $date->setTime((int) $date->format('H'), $invert ? 59 : 0); + } else { + $date = $date->setTime((int) $date->format('H'), (int) $minutes[$position]); } return $this; diff --git a/vendor/dragonmantank/cron-expression/src/Cron/MonthField.php b/vendor/dragonmantank/cron-expression/src/Cron/MonthField.php index afc9caff2..06bdbf46b 100644 --- a/vendor/dragonmantank/cron-expression/src/Cron/MonthField.php +++ b/vendor/dragonmantank/cron-expression/src/Cron/MonthField.php @@ -1,34 +1,36 @@ 'JAN', 2 => 'FEB', 3 => 'MAR', 4 => 'APR', 5 => 'MAY', 6 => 'JUN', 7 => 'JUL', - 8 => 'AUG', 9 => 'SEP', 10 => 'OCT', 11 => 'NOV', 12 => 'DEC']; + 8 => 'AUG', 9 => 'SEP', 10 => 'OCT', 11 => 'NOV', 12 => 'DEC', ]; /** - * @inheritDoc + * {@inheritdoc} */ - public function isSatisfiedBy(DateTimeInterface $date, $value) + public function isSatisfiedBy(DateTimeInterface $date, $value): bool { if ($value == '?') { return true; @@ -36,15 +38,15 @@ class MonthField extends AbstractField $value = $this->convertLiterals($value); - return $this->isSatisfied($date->format('m'), $value); + return $this->isSatisfied((int) $date->format('m'), $value); } /** * @inheritDoc * - * @param \DateTime|\DateTimeImmutable &$date + * @param \DateTime|\DateTimeImmutable $date */ - public function increment(DateTimeInterface &$date, $invert = false) + public function increment(DateTimeInterface &$date, $invert = false, $parts = null): FieldInterface { if ($invert) { $date = $date->modify('last day of previous month')->setTime(23, 59); @@ -54,6 +56,4 @@ class MonthField extends AbstractField return $this; } - - } diff --git a/vendor/dragonmantank/cron-expression/tests/Cron/AbstractFieldTest.php b/vendor/dragonmantank/cron-expression/tests/Cron/AbstractFieldTest.php deleted file mode 100644 index 38114392e..000000000 --- a/vendor/dragonmantank/cron-expression/tests/Cron/AbstractFieldTest.php +++ /dev/null @@ -1,139 +0,0 @@ - - */ -class AbstractFieldTest extends TestCase -{ - /** - * @covers \Cron\AbstractField::isRange - */ - public function testTestsIfRange() - { - $f = new DayOfWeekField(); - $this->assertTrue($f->isRange('1-2')); - $this->assertFalse($f->isRange('2')); - } - - /** - * @covers \Cron\AbstractField::isIncrementsOfRanges - */ - public function testTestsIfIncrementsOfRanges() - { - $f = new DayOfWeekField(); - $this->assertFalse($f->isIncrementsOfRanges('1-2')); - $this->assertTrue($f->isIncrementsOfRanges('1/2')); - $this->assertTrue($f->isIncrementsOfRanges('*/2')); - $this->assertTrue($f->isIncrementsOfRanges('3-12/2')); - } - - /** - * @covers \Cron\AbstractField::isInRange - */ - public function testTestsIfInRange() - { - $f = new DayOfWeekField(); - $this->assertTrue($f->isInRange('1', '1-2')); - $this->assertTrue($f->isInRange('2', '1-2')); - $this->assertTrue($f->isInRange('5', '4-12')); - $this->assertFalse($f->isInRange('3', '4-12')); - $this->assertFalse($f->isInRange('13', '4-12')); - } - - /** - * @covers \Cron\AbstractField::isInIncrementsOfRanges - */ - public function testTestsIfInIncrementsOfRangesOnZeroStartRange() - { - $f = new MinutesField(); - $this->assertTrue($f->isInIncrementsOfRanges('3', '3-59/2')); - $this->assertTrue($f->isInIncrementsOfRanges('13', '3-59/2')); - $this->assertTrue($f->isInIncrementsOfRanges('15', '3-59/2')); - $this->assertTrue($f->isInIncrementsOfRanges('14', '*/2')); - $this->assertFalse($f->isInIncrementsOfRanges('2', '3-59/13')); - $this->assertFalse($f->isInIncrementsOfRanges('14', '*/13')); - $this->assertFalse($f->isInIncrementsOfRanges('14', '3-59/2')); - $this->assertFalse($f->isInIncrementsOfRanges('3', '2-59')); - $this->assertFalse($f->isInIncrementsOfRanges('3', '2')); - $this->assertFalse($f->isInIncrementsOfRanges('3', '*')); - $this->assertFalse($f->isInIncrementsOfRanges('0', '*/0')); - $this->assertFalse($f->isInIncrementsOfRanges('1', '*/0')); - - $this->assertTrue($f->isInIncrementsOfRanges('4', '4/1')); - $this->assertFalse($f->isInIncrementsOfRanges('14', '4/1')); - $this->assertFalse($f->isInIncrementsOfRanges('34', '4/1')); - } - - /** - * @covers \Cron\AbstractField::isInIncrementsOfRanges - */ - public function testTestsIfInIncrementsOfRangesOnOneStartRange() - { - $f = new MonthField(); - $this->assertTrue($f->isInIncrementsOfRanges('3', '3-12/2')); - $this->assertFalse($f->isInIncrementsOfRanges('13', '3-12/2')); - $this->assertFalse($f->isInIncrementsOfRanges('15', '3-12/2')); - $this->assertTrue($f->isInIncrementsOfRanges('3', '*/2')); - $this->assertFalse($f->isInIncrementsOfRanges('3', '*/3')); - $this->assertTrue($f->isInIncrementsOfRanges('7', '*/3')); - $this->assertFalse($f->isInIncrementsOfRanges('14', '3-12/2')); - $this->assertFalse($f->isInIncrementsOfRanges('3', '2-12')); - $this->assertFalse($f->isInIncrementsOfRanges('3', '2')); - $this->assertFalse($f->isInIncrementsOfRanges('3', '*')); - $this->assertFalse($f->isInIncrementsOfRanges('0', '*/0')); - $this->assertFalse($f->isInIncrementsOfRanges('1', '*/0')); - - $this->assertTrue($f->isInIncrementsOfRanges('4', '4/1')); - $this->assertFalse($f->isInIncrementsOfRanges('14', '4/1')); - $this->assertFalse($f->isInIncrementsOfRanges('34', '4/1')); - } - - /** - * @covers \Cron\AbstractField::isSatisfied - */ - public function testTestsIfSatisfied() - { - $f = new DayOfWeekField(); - $this->assertTrue($f->isSatisfied('12', '3-13')); - $this->assertFalse($f->isSatisfied('15', '3-7/2')); - $this->assertTrue($f->isSatisfied('12', '*')); - $this->assertTrue($f->isSatisfied('12', '12')); - $this->assertFalse($f->isSatisfied('12', '3-11')); - $this->assertFalse($f->isSatisfied('12', '3-7/2')); - $this->assertFalse($f->isSatisfied('12', '11')); - } - - /** - * Allows ranges and lists to coexist in the same expression - * - * @see https://github.com/dragonmantank/cron-expression/issues/5 - */ - public function testAllowRangesAndLists() - { - $expression = '5-7,11-13'; - $f = new HoursField(); - $this->assertTrue($f->validate($expression)); - } - - /** - * Makes sure that various types of ranges expand out properly - * - * @see https://github.com/dragonmantank/cron-expression/issues/5 - */ - public function testGetRangeForExpressionExpandsCorrectly() - { - $f = new HoursField(); - $this->assertSame([5, 6, 7, 11, 12, 13], $f->getRangeForExpression('5-7,11-13', 23)); - $this->assertSame(['5', '6', '7', '11', '12', '13'], $f->getRangeForExpression('5,6,7,11,12,13', 23)); - $this->assertSame([0, 6, 12, 18], $f->getRangeForExpression('*/6', 23)); - $this->assertSame([5, 11], $f->getRangeForExpression('5-13/6', 23)); - } -} diff --git a/vendor/dragonmantank/cron-expression/tests/Cron/CronExpressionTest.php b/vendor/dragonmantank/cron-expression/tests/Cron/CronExpressionTest.php deleted file mode 100644 index 8810d43da..000000000 --- a/vendor/dragonmantank/cron-expression/tests/Cron/CronExpressionTest.php +++ /dev/null @@ -1,589 +0,0 @@ - - */ -class CronExpressionTest extends TestCase -{ - /** - * @covers \Cron\CronExpression::factory - */ - public function testFactoryRecognizesTemplates() - { - $this->assertSame('0 0 1 1 *', CronExpression::factory('@annually')->getExpression()); - $this->assertSame('0 0 1 1 *', CronExpression::factory('@yearly')->getExpression()); - $this->assertSame('0 0 * * 0', CronExpression::factory('@weekly')->getExpression()); - } - - /** - * @covers \Cron\CronExpression::__construct - * @covers \Cron\CronExpression::getExpression - * @covers \Cron\CronExpression::__toString - */ - public function testParsesCronSchedule() - { - // '2010-09-10 12:00:00' - $cron = CronExpression::factory('1 2-4 * 4,5,6 */3'); - $this->assertSame('1', $cron->getExpression(CronExpression::MINUTE)); - $this->assertSame('2-4', $cron->getExpression(CronExpression::HOUR)); - $this->assertSame('*', $cron->getExpression(CronExpression::DAY)); - $this->assertSame('4,5,6', $cron->getExpression(CronExpression::MONTH)); - $this->assertSame('*/3', $cron->getExpression(CronExpression::WEEKDAY)); - $this->assertSame('1 2-4 * 4,5,6 */3', $cron->getExpression()); - $this->assertSame('1 2-4 * 4,5,6 */3', (string) $cron); - $this->assertNull($cron->getExpression('foo')); - } - - /** - * @covers \Cron\CronExpression::__construct - * @covers \Cron\CronExpression::getExpression - * @covers \Cron\CronExpression::__toString - */ - public function testParsesCronScheduleThrowsAnException() - { - $this->expectException(\InvalidArgumentException::class); - $this->expectExceptionMessage('Invalid CRON field value A at position 0'); - - CronExpression::factory('A 1 2 3 4'); - } - - /** - * @covers \Cron\CronExpression::__construct - * @covers \Cron\CronExpression::getExpression - * @dataProvider scheduleWithDifferentSeparatorsProvider - */ - public function testParsesCronScheduleWithAnySpaceCharsAsSeparators($schedule, array $expected) - { - $cron = CronExpression::factory($schedule); - $this->assertSame($expected[0], $cron->getExpression(CronExpression::MINUTE)); - $this->assertSame($expected[1], $cron->getExpression(CronExpression::HOUR)); - $this->assertSame($expected[2], $cron->getExpression(CronExpression::DAY)); - $this->assertSame($expected[3], $cron->getExpression(CronExpression::MONTH)); - $this->assertSame($expected[4], $cron->getExpression(CronExpression::WEEKDAY)); - } - - /** - * Data provider for testParsesCronScheduleWithAnySpaceCharsAsSeparators - * - * @return array - */ - public static function scheduleWithDifferentSeparatorsProvider() - { - return array( - array("*\t*\t*\t*\t*\t", array('*', '*', '*', '*', '*', '*')), - array("* * * * * ", array('*', '*', '*', '*', '*', '*')), - array("* \t * \t * \t * \t * \t", array('*', '*', '*', '*', '*', '*')), - array("*\t \t*\t \t*\t \t*\t \t*\t \t", array('*', '*', '*', '*', '*', '*')), - ); - } - - /** - * @covers \Cron\CronExpression::__construct - * @covers \Cron\CronExpression::setExpression - * @covers \Cron\CronExpression::setPart - */ - public function testInvalidCronsWillFail() - { - $this->expectException(\InvalidArgumentException::class); - - // Only four values - $cron = CronExpression::factory('* * * 1'); - } - - /** - * @covers \Cron\CronExpression::setPart - */ - public function testInvalidPartsWillFail() - { - $this->expectException(\InvalidArgumentException::class); - - // Only four values - $cron = CronExpression::factory('* * * * *'); - $cron->setPart(1, 'abc'); - } - - /** - * Data provider for cron schedule - * - * @return array - */ - public function scheduleProvider() - { - return array( - array('*/2 */2 * * *', '2015-08-10 21:47:27', '2015-08-10 22:00:00', false), - array('* * * * *', '2015-08-10 21:50:37', '2015-08-10 21:50:00', true), - array('* 20,21,22 * * *', '2015-08-10 21:50:00', '2015-08-10 21:50:00', true), - // Handles CSV values - array('* 20,22 * * *', '2015-08-10 21:50:00', '2015-08-10 22:00:00', false), - // CSV values can be complex - array('7-9 * */9 * *', '2015-08-10 22:02:33', '2015-08-10 22:07:00', false), - // 15th minute, of the second hour, every 15 days, in January, every Friday - array('1 * * * 7', '2015-08-10 21:47:27', '2015-08-16 00:01:00', false), - // Test with exact times - array('47 21 * * *', strtotime('2015-08-10 21:47:30'), '2015-08-10 21:47:00', true), - // Test Day of the week (issue #1) - // According cron implementation, 0|7 = sunday, 1 => monday, etc - array('* * * * 0', strtotime('2011-06-15 23:09:00'), '2011-06-19 00:00:00', false), - array('* * * * 7', strtotime('2011-06-15 23:09:00'), '2011-06-19 00:00:00', false), - array('* * * * 1', strtotime('2011-06-15 23:09:00'), '2011-06-20 00:00:00', false), - // Should return the sunday date as 7 equals 0 - array('0 0 * * MON,SUN', strtotime('2011-06-15 23:09:00'), '2011-06-19 00:00:00', false), - array('0 0 * * 1,7', strtotime('2011-06-15 23:09:00'), '2011-06-19 00:00:00', false), - array('0 0 * * 0-4', strtotime('2011-06-15 23:09:00'), '2011-06-16 00:00:00', false), - array('0 0 * * 7-4', strtotime('2011-06-15 23:09:00'), '2011-06-16 00:00:00', false), - array('0 0 * * 4-7', strtotime('2011-06-15 23:09:00'), '2011-06-16 00:00:00', false), - array('0 0 * * 7-3', strtotime('2011-06-15 23:09:00'), '2011-06-19 00:00:00', false), - array('0 0 * * 3-7', strtotime('2011-06-15 23:09:00'), '2011-06-16 00:00:00', false), - array('0 0 * * 3-7', strtotime('2011-06-18 23:09:00'), '2011-06-19 00:00:00', false), - // Test lists of values and ranges (Abhoryo) - array('0 0 * * 2-7', strtotime('2011-06-20 23:09:00'), '2011-06-21 00:00:00', false), - array('0 0 * * 2-7', strtotime('2011-06-18 23:09:00'), '2011-06-19 00:00:00', false), - array('0 0 * * 4-7', strtotime('2011-07-19 00:00:00'), '2011-07-21 00:00:00', false), - // Test increments of ranges - array('0-12/4 * * * *', strtotime('2011-06-20 12:04:00'), '2011-06-20 12:04:00', true), - array('4-59/2 * * * *', strtotime('2011-06-20 12:04:00'), '2011-06-20 12:04:00', true), - array('4-59/2 * * * *', strtotime('2011-06-20 12:06:00'), '2011-06-20 12:06:00', true), - array('4-59/3 * * * *', strtotime('2011-06-20 12:06:00'), '2011-06-20 12:07:00', false), - // Test Day of the Week and the Day of the Month (issue #1) - array('0 0 1 1 0', strtotime('2011-06-15 23:09:00'), '2012-01-01 00:00:00', false), - array('0 0 1 JAN 0', strtotime('2011-06-15 23:09:00'), '2012-01-01 00:00:00', false), - array('0 0 1 * 0', strtotime('2011-06-15 23:09:00'), '2012-01-01 00:00:00', false), - // Test the W day of the week modifier for day of the month field - array('0 0 2W * *', strtotime('2011-07-01 00:00:00'), '2011-07-01 00:00:00', true), - array('0 0 1W * *', strtotime('2011-05-01 00:00:00'), '2011-05-02 00:00:00', false), - array('0 0 1W * *', strtotime('2011-07-01 00:00:00'), '2011-07-01 00:00:00', true), - array('0 0 3W * *', strtotime('2011-07-01 00:00:00'), '2011-07-04 00:00:00', false), - array('0 0 16W * *', strtotime('2011-07-01 00:00:00'), '2011-07-15 00:00:00', false), - array('0 0 28W * *', strtotime('2011-07-01 00:00:00'), '2011-07-28 00:00:00', false), - array('0 0 30W * *', strtotime('2011-07-01 00:00:00'), '2011-07-29 00:00:00', false), - array('0 0 31W * *', strtotime('2011-07-01 00:00:00'), '2011-07-29 00:00:00', false), - // Test the last weekday of a month - array('* * * * 5L', strtotime('2011-07-01 00:00:00'), '2011-07-29 00:00:00', false), - array('* * * * 6L', strtotime('2011-07-01 00:00:00'), '2011-07-30 00:00:00', false), - array('* * * * 7L', strtotime('2011-07-01 00:00:00'), '2011-07-31 00:00:00', false), - array('* * * * 1L', strtotime('2011-07-24 00:00:00'), '2011-07-25 00:00:00', false), - array('* * * 1 5L', strtotime('2011-12-25 00:00:00'), '2012-01-27 00:00:00', false), - // Test the hash symbol for the nth weekday of a given month - array('* * * * 5#2', strtotime('2011-07-01 00:00:00'), '2011-07-08 00:00:00', false), - array('* * * * 5#1', strtotime('2011-07-01 00:00:00'), '2011-07-01 00:00:00', true), - array('* * * * 3#4', strtotime('2011-07-01 00:00:00'), '2011-07-27 00:00:00', false), - - // Issue #7, documented example failed - ['3-59/15 6-12 */15 1 2-5', strtotime('2017-01-08 00:00:00'), '2017-01-31 06:03:00', false], - - // https://github.com/laravel/framework/commit/07d160ac3cc9764d5b429734ffce4fa311385403 - ['* * * * MON-FRI', strtotime('2017-01-08 00:00:00'), strtotime('2017-01-09 00:00:00'), false], - ['* * * * TUE', strtotime('2017-01-08 00:00:00'), strtotime('2017-01-10 00:00:00'), false], - ); - } - - /** - * @covers \Cron\CronExpression::isDue - * @covers \Cron\CronExpression::getNextRunDate - * @covers \Cron\DayOfMonthField - * @covers \Cron\DayOfWeekField - * @covers \Cron\MinutesField - * @covers \Cron\HoursField - * @covers \Cron\MonthField - * @covers \Cron\CronExpression::getRunDate - * @dataProvider scheduleProvider - */ - public function testDeterminesIfCronIsDue($schedule, $relativeTime, $nextRun, $isDue) - { - $relativeTimeString = is_int($relativeTime) ? date('Y-m-d H:i:s', $relativeTime) : $relativeTime; - - // Test next run date - $cron = CronExpression::factory($schedule); - if (is_string($relativeTime)) { - $relativeTime = new DateTime($relativeTime); - } elseif (is_int($relativeTime)) { - $relativeTime = date('Y-m-d H:i:s', $relativeTime); - } - - if (is_string($nextRun)) { - $nextRunDate = new DateTime($nextRun); - } elseif (is_int($nextRun)) { - $nextRunDate = new DateTime(); - $nextRunDate->setTimestamp($nextRun); - } - $this->assertSame($isDue, $cron->isDue($relativeTime)); - $next = $cron->getNextRunDate($relativeTime, 0, true); - - $this->assertEquals($nextRunDate, $next); - } - - /** - * @covers \Cron\CronExpression::isDue - */ - public function testIsDueHandlesDifferentDates() - { - $cron = CronExpression::factory('* * * * *'); - $this->assertTrue($cron->isDue()); - $this->assertTrue($cron->isDue('now')); - $this->assertTrue($cron->isDue(new DateTime('now'))); - $this->assertTrue($cron->isDue(date('Y-m-d H:i'))); - $this->assertTrue($cron->isDue(new DateTimeImmutable('now'))); - } - - /** - * @covers \Cron\CronExpression::isDue - */ - public function testIsDueHandlesDifferentDefaultTimezones() - { - $originalTimezone = date_default_timezone_get(); - $cron = CronExpression::factory('0 15 * * 3'); //Wednesday at 15:00 - $date = '2014-01-01 15:00'; //Wednesday - - date_default_timezone_set('UTC'); - $this->assertTrue($cron->isDue(new DateTime($date), 'UTC')); - $this->assertFalse($cron->isDue(new DateTime($date), 'Europe/Amsterdam')); - $this->assertFalse($cron->isDue(new DateTime($date), 'Asia/Tokyo')); - - date_default_timezone_set('Europe/Amsterdam'); - $this->assertFalse($cron->isDue(new DateTime($date), 'UTC')); - $this->assertTrue($cron->isDue(new DateTime($date), 'Europe/Amsterdam')); - $this->assertFalse($cron->isDue(new DateTime($date), 'Asia/Tokyo')); - - date_default_timezone_set('Asia/Tokyo'); - $this->assertFalse($cron->isDue(new DateTime($date), 'UTC')); - $this->assertFalse($cron->isDue(new DateTime($date), 'Europe/Amsterdam')); - $this->assertTrue($cron->isDue(new DateTime($date), 'Asia/Tokyo')); - - date_default_timezone_set($originalTimezone); - } - - /** - * @covers \Cron\CronExpression::isDue - */ - public function testIsDueHandlesDifferentSuppliedTimezones() - { - $cron = CronExpression::factory('0 15 * * 3'); //Wednesday at 15:00 - $date = '2014-01-01 15:00'; //Wednesday - - $this->assertTrue($cron->isDue(new DateTime($date, new DateTimeZone('UTC')), 'UTC')); - $this->assertFalse($cron->isDue(new DateTime($date, new DateTimeZone('UTC')), 'Europe/Amsterdam')); - $this->assertFalse($cron->isDue(new DateTime($date, new DateTimeZone('UTC')), 'Asia/Tokyo')); - - $this->assertFalse($cron->isDue(new DateTime($date, new DateTimeZone('Europe/Amsterdam')), 'UTC')); - $this->assertTrue($cron->isDue(new DateTime($date, new DateTimeZone('Europe/Amsterdam')), 'Europe/Amsterdam')); - $this->assertFalse($cron->isDue(new DateTime($date, new DateTimeZone('Europe/Amsterdam')), 'Asia/Tokyo')); - - $this->assertFalse($cron->isDue(new DateTime($date, new DateTimeZone('Asia/Tokyo')), 'UTC')); - $this->assertFalse($cron->isDue(new DateTime($date, new DateTimeZone('Asia/Tokyo')), 'Europe/Amsterdam')); - $this->assertTrue($cron->isDue(new DateTime($date, new DateTimeZone('Asia/Tokyo')), 'Asia/Tokyo')); - } - - /** - * @covers Cron\CronExpression::isDue - */ - public function testIsDueHandlesDifferentTimezonesAsArgument() - { - $cron = CronExpression::factory('0 15 * * 3'); //Wednesday at 15:00 - $date = '2014-01-01 15:00'; //Wednesday - $utc = new \DateTimeZone('UTC'); - $amsterdam = new \DateTimeZone('Europe/Amsterdam'); - $tokyo = new \DateTimeZone('Asia/Tokyo'); - $this->assertTrue($cron->isDue(new DateTime($date, $utc), 'UTC')); - $this->assertFalse($cron->isDue(new DateTime($date, $amsterdam), 'UTC')); - $this->assertFalse($cron->isDue(new DateTime($date, $tokyo), 'UTC')); - $this->assertFalse($cron->isDue(new DateTime($date, $utc), 'Europe/Amsterdam')); - $this->assertTrue($cron->isDue(new DateTime($date, $amsterdam), 'Europe/Amsterdam')); - $this->assertFalse($cron->isDue(new DateTime($date, $tokyo), 'Europe/Amsterdam')); - $this->assertFalse($cron->isDue(new DateTime($date, $utc), 'Asia/Tokyo')); - $this->assertFalse($cron->isDue(new DateTime($date, $amsterdam), 'Asia/Tokyo')); - $this->assertTrue($cron->isDue(new DateTime($date, $tokyo), 'Asia/Tokyo')); - } - - /** - * @covers Cron\CronExpression::isDue - */ - public function testRecognisesTimezonesAsPartOfDateTime() - { - $cron = CronExpression::factory("0 7 * * *"); - $tzCron = "America/New_York"; - $tzServer = new \DateTimeZone("Europe/London"); - - $dtCurrent = \DateTime::createFromFormat("!Y-m-d H:i:s", "2017-10-17 10:00:00", $tzServer); - $dtPrev = $cron->getPreviousRunDate($dtCurrent, 0, true, $tzCron); - $this->assertEquals('1508151600 : 2017-10-16T07:00:00-04:00 : America/New_York', $dtPrev->format("U \: c \: e")); - - $dtCurrent = \DateTimeImmutable::createFromFormat("!Y-m-d H:i:s", "2017-10-17 10:00:00", $tzServer); - $dtPrev = $cron->getPreviousRunDate($dtCurrent, 0, true, $tzCron); - $this->assertEquals('1508151600 : 2017-10-16T07:00:00-04:00 : America/New_York', $dtPrev->format("U \: c \: e")); - - $dtCurrent = \DateTimeImmutable::createFromFormat("!Y-m-d H:i:s", "2017-10-17 10:00:00", $tzServer); - $dtPrev = $cron->getPreviousRunDate($dtCurrent->format("c"), 0, true, $tzCron); - $this->assertEquals('1508151600 : 2017-10-16T07:00:00-04:00 : America/New_York', $dtPrev->format("U \: c \: e")); - - $dtCurrent = \DateTimeImmutable::createFromFormat("!Y-m-d H:i:s", "2017-10-17 10:00:00", $tzServer); - $dtPrev = $cron->getPreviousRunDate($dtCurrent->format("\@U"), 0, true, $tzCron); - $this->assertEquals('1508151600 : 2017-10-16T07:00:00-04:00 : America/New_York', $dtPrev->format("U \: c \: e")); - - } - - - /** - * @covers \Cron\CronExpression::getPreviousRunDate - */ - public function testCanGetPreviousRunDates() - { - $cron = CronExpression::factory('* * * * *'); - $next = $cron->getNextRunDate('now'); - $two = $cron->getNextRunDate('now', 1); - $this->assertEquals($next, $cron->getPreviousRunDate($two)); - - $cron = CronExpression::factory('* */2 * * *'); - $next = $cron->getNextRunDate('now'); - $two = $cron->getNextRunDate('now', 1); - $this->assertEquals($next, $cron->getPreviousRunDate($two)); - - $cron = CronExpression::factory('* * * */2 *'); - $next = $cron->getNextRunDate('now'); - $two = $cron->getNextRunDate('now', 1); - $this->assertEquals($next, $cron->getPreviousRunDate($two)); - } - - /** - * @covers \Cron\CronExpression::getMultipleRunDates - */ - public function testProvidesMultipleRunDates() - { - $cron = CronExpression::factory('*/2 * * * *'); - $this->assertEquals(array( - new DateTime('2008-11-09 00:00:00'), - new DateTime('2008-11-09 00:02:00'), - new DateTime('2008-11-09 00:04:00'), - new DateTime('2008-11-09 00:06:00') - ), $cron->getMultipleRunDates(4, '2008-11-09 00:00:00', false, true)); - } - - /** - * @covers \Cron\CronExpression::getMultipleRunDates - * @covers \Cron\CronExpression::setMaxIterationCount - */ - public function testProvidesMultipleRunDatesForTheFarFuture() { - // Fails with the default 1000 iteration limit - $cron = CronExpression::factory('0 0 12 1 *'); - $cron->setMaxIterationCount(2000); - $this->assertEquals(array( - new DateTime('2016-01-12 00:00:00'), - new DateTime('2017-01-12 00:00:00'), - new DateTime('2018-01-12 00:00:00'), - new DateTime('2019-01-12 00:00:00'), - new DateTime('2020-01-12 00:00:00'), - new DateTime('2021-01-12 00:00:00'), - new DateTime('2022-01-12 00:00:00'), - new DateTime('2023-01-12 00:00:00'), - new DateTime('2024-01-12 00:00:00'), - ), $cron->getMultipleRunDates(9, '2015-04-28 00:00:00', false, true)); - } - - /** - * @covers \Cron\CronExpression - */ - public function testCanIterateOverNextRuns() - { - $cron = CronExpression::factory('@weekly'); - $nextRun = $cron->getNextRunDate("2008-11-09 08:00:00"); - $this->assertEquals($nextRun, new DateTime("2008-11-16 00:00:00")); - - // true is cast to 1 - $nextRun = $cron->getNextRunDate("2008-11-09 00:00:00", true, true); - $this->assertEquals($nextRun, new DateTime("2008-11-16 00:00:00")); - - // You can iterate over them - $nextRun = $cron->getNextRunDate($cron->getNextRunDate("2008-11-09 00:00:00", 1, true), 1, true); - $this->assertEquals($nextRun, new DateTime("2008-11-23 00:00:00")); - - // You can skip more than one - $nextRun = $cron->getNextRunDate("2008-11-09 00:00:00", 2, true); - $this->assertEquals($nextRun, new DateTime("2008-11-23 00:00:00")); - $nextRun = $cron->getNextRunDate("2008-11-09 00:00:00", 3, true); - $this->assertEquals($nextRun, new DateTime("2008-11-30 00:00:00")); - } - - /** - * @covers \Cron\CronExpression::getRunDate - */ - public function testGetRunDateHandlesDifferentDates() - { - $cron = CronExpression::factory('@weekly'); - $date = new DateTime("2019-03-10 00:00:00"); - $this->assertEquals($date, $cron->getNextRunDate("2019-03-03 08:00:00")); - $this->assertEquals($date, $cron->getNextRunDate(new DateTime("2019-03-03 08:00:00"))); - $this->assertEquals($date, $cron->getNextRunDate(new DateTimeImmutable("2019-03-03 08:00:00"))); - } - - /** - * @covers \Cron\CronExpression::getRunDate - */ - public function testSkipsCurrentDateByDefault() - { - $cron = CronExpression::factory('* * * * *'); - $current = new DateTime('now'); - $next = $cron->getNextRunDate($current); - $nextPrev = $cron->getPreviousRunDate($next); - $this->assertSame($current->format('Y-m-d H:i:00'), $nextPrev->format('Y-m-d H:i:s')); - } - - /** - * @covers \Cron\CronExpression::getRunDate - * @ticket 7 - */ - public function testStripsForSeconds() - { - $cron = CronExpression::factory('* * * * *'); - $current = new DateTime('2011-09-27 10:10:54'); - $this->assertSame('2011-09-27 10:11:00', $cron->getNextRunDate($current)->format('Y-m-d H:i:s')); - } - - /** - * @covers \Cron\CronExpression::getRunDate - */ - public function testFixesPhpBugInDateIntervalMonth() - { - $cron = CronExpression::factory('0 0 27 JAN *'); - $this->assertSame('2011-01-27 00:00:00', $cron->getPreviousRunDate('2011-08-22 00:00:00')->format('Y-m-d H:i:s')); - } - - public function testIssue29() - { - $cron = CronExpression::factory('@weekly'); - $this->assertSame( - '2013-03-10 00:00:00', - $cron->getPreviousRunDate('2013-03-17 00:00:00')->format('Y-m-d H:i:s') - ); - } - - /** - * @see https://github.com/mtdowling/cron-expression/issues/20 - */ - public function testIssue20() { - $e = CronExpression::factory('* * * * MON#1'); - $this->assertTrue($e->isDue(new DateTime('2014-04-07 00:00:00'))); - $this->assertFalse($e->isDue(new DateTime('2014-04-14 00:00:00'))); - $this->assertFalse($e->isDue(new DateTime('2014-04-21 00:00:00'))); - - $e = CronExpression::factory('* * * * SAT#2'); - $this->assertFalse($e->isDue(new DateTime('2014-04-05 00:00:00'))); - $this->assertTrue($e->isDue(new DateTime('2014-04-12 00:00:00'))); - $this->assertFalse($e->isDue(new DateTime('2014-04-19 00:00:00'))); - - $e = CronExpression::factory('* * * * SUN#3'); - $this->assertFalse($e->isDue(new DateTime('2014-04-13 00:00:00'))); - $this->assertTrue($e->isDue(new DateTime('2014-04-20 00:00:00'))); - $this->assertFalse($e->isDue(new DateTime('2014-04-27 00:00:00'))); - } - - /** - * @covers \Cron\CronExpression::getRunDate - */ - public function testKeepOriginalTime() - { - $now = new \DateTime; - $strNow = $now->format(DateTime::ISO8601); - $cron = CronExpression::factory('0 0 * * *'); - $cron->getPreviousRunDate($now); - $this->assertSame($strNow, $now->format(DateTime::ISO8601)); - } - - /** - * @covers \Cron\CronExpression::__construct - * @covers \Cron\CronExpression::factory - * @covers \Cron\CronExpression::isValidExpression - * @covers \Cron\CronExpression::setExpression - * @covers \Cron\CronExpression::setPart - */ - public function testValidationWorks() - { - // Invalid. Only four values - $this->assertFalse(CronExpression::isValidExpression('* * * 1')); - // Valid - $this->assertTrue(CronExpression::isValidExpression('* * * * 1')); - - // Issue #156, 13 is an invalid month - $this->assertFalse(CronExpression::isValidExpression("* * * 13 * ")); - - // Issue #155, 90 is an invalid second - $this->assertFalse(CronExpression::isValidExpression('90 * * * *')); - - // Issue #154, 24 is an invalid hour - $this->assertFalse(CronExpression::isValidExpression("0 24 1 12 0")); - - // Issue #125, this is just all sorts of wrong - $this->assertFalse(CronExpression::isValidExpression('990 14 * * mon-fri0345345')); - - // see https://github.com/dragonmantank/cron-expression/issues/5 - $this->assertTrue(CronExpression::isValidExpression('2,17,35,47 5-7,11-13 * * *')); - } - - /** - * Makes sure that 00 is considered a valid value for 0-based fields - * cronie allows numbers with a leading 0, so adding support for this as well - * - * @see https://github.com/dragonmantank/cron-expression/issues/12 - */ - public function testDoubleZeroIsValid() - { - $this->assertTrue(CronExpression::isValidExpression('00 * * * *')); - $this->assertTrue(CronExpression::isValidExpression('01 * * * *')); - $this->assertTrue(CronExpression::isValidExpression('* 00 * * *')); - $this->assertTrue(CronExpression::isValidExpression('* 01 * * *')); - - $e = CronExpression::factory('00 * * * *'); - $this->assertTrue($e->isDue(new DateTime('2014-04-07 00:00:00'))); - $e = CronExpression::factory('01 * * * *'); - $this->assertTrue($e->isDue(new DateTime('2014-04-07 00:01:00'))); - - $e = CronExpression::factory('* 00 * * *'); - $this->assertTrue($e->isDue(new DateTime('2014-04-07 00:00:00'))); - $e = CronExpression::factory('* 01 * * *'); - $this->assertTrue($e->isDue(new DateTime('2014-04-07 01:00:00'))); - } - - - /** - * Ranges with large steps should "wrap around" to the appropriate value - * cronie allows for steps that are larger than the range of a field, with it wrapping around like a ring buffer. We - * should do the same. - * - * @see https://github.com/dragonmantank/cron-expression/issues/6 - */ - public function testRangesWrapAroundWithLargeSteps() - { - $f = new MonthField(); - $this->assertTrue($f->validate('*/123')); - $this->assertSame([4], $f->getRangeForExpression('*/123', 12)); - - $e = CronExpression::factory('* * * */123 *'); - $this->assertTrue($e->isDue(new DateTime('2014-04-07 00:00:00'))); - - $nextRunDate = $e->getNextRunDate(new DateTime('2014-04-07 00:00:00')); - $this->assertSame('2014-04-07 00:01:00', $nextRunDate->format('Y-m-d H:i:s')); - - $nextRunDate = $e->getNextRunDate(new DateTime('2014-05-07 00:00:00')); - $this->assertSame('2015-04-01 00:00:00', $nextRunDate->format('Y-m-d H:i:s')); - } - - /** - * When there is an issue with a field, we should report the human readable position - * - * @see https://github.com/dragonmantank/cron-expression/issues/29 - */ - public function testFieldPositionIsHumanAdjusted() - { - $this->expectException(InvalidArgumentException::class); - $this->expectExceptionMessage("6 is not a valid position"); - $e = CronExpression::factory('0 * * * * ? *'); - } -} diff --git a/vendor/dragonmantank/cron-expression/tests/Cron/DayOfMonthFieldTest.php b/vendor/dragonmantank/cron-expression/tests/Cron/DayOfMonthFieldTest.php deleted file mode 100644 index 2191b6bff..000000000 --- a/vendor/dragonmantank/cron-expression/tests/Cron/DayOfMonthFieldTest.php +++ /dev/null @@ -1,77 +0,0 @@ - - */ -class DayOfMonthFieldTest extends TestCase -{ - /** - * @covers \Cron\DayOfMonthField::validate - */ - public function testValidatesField() - { - $f = new DayOfMonthField(); - $this->assertTrue($f->validate('1')); - $this->assertTrue($f->validate('*')); - $this->assertTrue($f->validate('L')); - $this->assertTrue($f->validate('5W')); - $this->assertTrue($f->validate('01')); - $this->assertFalse($f->validate('5W,L')); - $this->assertFalse($f->validate('1.')); - } - - /** - * @covers \Cron\DayOfMonthField::isSatisfiedBy - */ - public function testChecksIfSatisfied() - { - $f = new DayOfMonthField(); - $this->assertTrue($f->isSatisfiedBy(new DateTime(), '?')); - $this->assertTrue($f->isSatisfiedBy(new DateTimeImmutable(), '?')); - } - - /** - * @covers \Cron\DayOfMonthField::increment - */ - public function testIncrementsDate() - { - $d = new DateTime('2011-03-15 11:15:00'); - $f = new DayOfMonthField(); - $f->increment($d); - $this->assertSame('2011-03-16 00:00:00', $d->format('Y-m-d H:i:s')); - - $d = new DateTime('2011-03-15 11:15:00'); - $f->increment($d, true); - $this->assertSame('2011-03-14 23:59:00', $d->format('Y-m-d H:i:s')); - } - - /** - * @covers \Cron\DayOfMonthField::increment - */ - public function testIncrementsDateTimeImmutable() - { - $d = new DateTimeImmutable('2011-03-15 11:15:00'); - $f = new DayOfMonthField(); - $f->increment($d); - $this->assertSame('2011-03-16 00:00:00', $d->format('Y-m-d H:i:s')); - } - - /** - * Day of the month cannot accept a 0 value, it must be between 1 and 31 - * See Github issue #120 - * - * @since 2017-01-22 - */ - public function testDoesNotAccept0Date() - { - $f = new DayOfMonthField(); - $this->assertFalse($f->validate(0)); - } -} diff --git a/vendor/dragonmantank/cron-expression/tests/Cron/DayOfWeekFieldTest.php b/vendor/dragonmantank/cron-expression/tests/Cron/DayOfWeekFieldTest.php deleted file mode 100644 index 74e63c28c..000000000 --- a/vendor/dragonmantank/cron-expression/tests/Cron/DayOfWeekFieldTest.php +++ /dev/null @@ -1,156 +0,0 @@ - - */ -class DayOfWeekFieldTest extends TestCase -{ - /** - * @covers \Cron\DayOfWeekField::validate - */ - public function testValidatesField() - { - $f = new DayOfWeekField(); - $this->assertTrue($f->validate('1')); - $this->assertTrue($f->validate('01')); - $this->assertTrue($f->validate('00')); - $this->assertTrue($f->validate('*')); - $this->assertFalse($f->validate('*/3,1,1-12')); - $this->assertTrue($f->validate('SUN-2')); - $this->assertFalse($f->validate('1.')); - } - - /** - * @covers \Cron\DayOfWeekField::isSatisfiedBy - */ - public function testChecksIfSatisfied() - { - $f = new DayOfWeekField(); - $this->assertTrue($f->isSatisfiedBy(new DateTime(), '?')); - $this->assertTrue($f->isSatisfiedBy(new DateTimeImmutable(), '?')); - } - - /** - * @covers \Cron\DayOfWeekField::increment - */ - public function testIncrementsDate() - { - $d = new DateTime('2011-03-15 11:15:00'); - $f = new DayOfWeekField(); - $f->increment($d); - $this->assertSame('2011-03-16 00:00:00', $d->format('Y-m-d H:i:s')); - - $d = new DateTime('2011-03-15 11:15:00'); - $f->increment($d, true); - $this->assertSame('2011-03-14 23:59:00', $d->format('Y-m-d H:i:s')); - } - - /** - * @covers \Cron\DayOfWeekField::increment - */ - public function testIncrementsDateTimeImmutable() - { - $d = new DateTimeImmutable('2011-03-15 11:15:00'); - $f = new DayOfWeekField(); - $f->increment($d); - $this->assertSame('2011-03-16 00:00:00', $d->format('Y-m-d H:i:s')); - } - - /** - * @covers \Cron\DayOfWeekField::isSatisfiedBy - */ - public function testValidatesHashValueWeekday() - { - $this->expectException(\InvalidArgumentException::class); - $this->expectExceptionMessage('Weekday must be a value between 0 and 7. 12 given'); - - $f = new DayOfWeekField(); - $this->assertTrue($f->isSatisfiedBy(new DateTime(), '12#1')); - } - - /** - * @covers \Cron\DayOfWeekField::isSatisfiedBy - */ - public function testValidatesHashValueNth() - { - $this->expectException(\InvalidArgumentException::class); - $this->expectExceptionMessage('There are never more than 5 or less than 1 of a given weekday in a month'); - - $f = new DayOfWeekField(); - $this->assertTrue($f->isSatisfiedBy(new DateTime(), '3#6')); - } - - /** - * @covers \Cron\DayOfWeekField::validate - */ - public function testValidateWeekendHash() - { - $f = new DayOfWeekField(); - $this->assertTrue($f->validate('MON#1')); - $this->assertTrue($f->validate('TUE#2')); - $this->assertTrue($f->validate('WED#3')); - $this->assertTrue($f->validate('THU#4')); - $this->assertTrue($f->validate('FRI#5')); - $this->assertTrue($f->validate('SAT#1')); - $this->assertTrue($f->validate('SUN#3')); - $this->assertTrue($f->validate('MON#1,MON#3')); - } - - /** - * @covers \Cron\DayOfWeekField::isSatisfiedBy - */ - public function testHandlesZeroAndSevenDayOfTheWeekValues() - { - $f = new DayOfWeekField(); - $this->assertTrue($f->isSatisfiedBy(new DateTime('2011-09-04 00:00:00'), '0-2')); - $this->assertTrue($f->isSatisfiedBy(new DateTime('2011-09-04 00:00:00'), '6-0')); - - $this->assertTrue($f->isSatisfiedBy(new DateTime('2014-04-20 00:00:00'), 'SUN')); - $this->assertTrue($f->isSatisfiedBy(new DateTime('2014-04-20 00:00:00'), 'SUN#3')); - $this->assertTrue($f->isSatisfiedBy(new DateTime('2014-04-20 00:00:00'), '0#3')); - $this->assertTrue($f->isSatisfiedBy(new DateTime('2014-04-20 00:00:00'), '7#3')); - } - - /** - * @covers \Cron\DayOfWeekField::isSatisfiedBy - */ - public function testHandlesLastWeekdayOfTheMonth() - { - $f = new DayOfWeekField(); - $this->assertTrue($f->isSatisfiedBy(new DateTime('2018-12-28 00:00:00'), 'FRIL')); - $this->assertTrue($f->isSatisfiedBy(new DateTime('2018-12-28 00:00:00'), '5L')); - $this->assertFalse($f->isSatisfiedBy(new DateTime('2018-12-21 00:00:00'), 'FRIL')); - $this->assertFalse($f->isSatisfiedBy(new DateTime('2018-12-21 00:00:00'), '5L')); - } - - /** - * @see https://github.com/mtdowling/cron-expression/issues/47 - */ - public function testIssue47() { - $f = new DayOfWeekField(); - $this->assertFalse($f->validate('mon,')); - $this->assertFalse($f->validate('mon-')); - $this->assertFalse($f->validate('*/2,')); - $this->assertFalse($f->validate('-mon')); - $this->assertFalse($f->validate(',1')); - $this->assertFalse($f->validate('*-')); - $this->assertFalse($f->validate(',-')); - } - - /** - * @see https://github.com/laravel/framework/commit/07d160ac3cc9764d5b429734ffce4fa311385403 - */ - public function testLiteralsExpandProperly() - { - $f = new DayOfWeekField(); - $this->assertTrue($f->validate('MON-FRI')); - $this->assertSame([1,2,3,4,5], $f->getRangeForExpression('MON-FRI', 7)); - } -} diff --git a/vendor/dragonmantank/cron-expression/tests/Cron/FieldFactoryTest.php b/vendor/dragonmantank/cron-expression/tests/Cron/FieldFactoryTest.php deleted file mode 100644 index e25d07075..000000000 --- a/vendor/dragonmantank/cron-expression/tests/Cron/FieldFactoryTest.php +++ /dev/null @@ -1,43 +0,0 @@ - - */ -class FieldFactoryTest extends TestCase -{ - /** - * @covers \Cron\FieldFactory::getField - */ - public function testRetrievesFieldInstances() - { - $mappings = array( - 0 => 'Cron\MinutesField', - 1 => 'Cron\HoursField', - 2 => 'Cron\DayOfMonthField', - 3 => 'Cron\MonthField', - 4 => 'Cron\DayOfWeekField', - ); - - $f = new FieldFactory(); - - foreach ($mappings as $position => $class) { - $this->assertSame($class, get_class($f->getField($position))); - } - } - - /** - * @covers \Cron\FieldFactory::getField - */ - public function testValidatesFieldPosition() - { - $this->expectException(\InvalidArgumentException::class); - - $f = new FieldFactory(); - $f->getField(-1); - } -} diff --git a/vendor/dragonmantank/cron-expression/tests/Cron/HoursFieldTest.php b/vendor/dragonmantank/cron-expression/tests/Cron/HoursFieldTest.php deleted file mode 100644 index 1849f28be..000000000 --- a/vendor/dragonmantank/cron-expression/tests/Cron/HoursFieldTest.php +++ /dev/null @@ -1,99 +0,0 @@ - - */ -class HoursFieldTest extends TestCase -{ - /** - * @covers \Cron\HoursField::validate - */ - public function testValidatesField() - { - $f = new HoursField(); - $this->assertTrue($f->validate('1')); - $this->assertTrue($f->validate('00')); - $this->assertTrue($f->validate('01')); - $this->assertTrue($f->validate('*')); - $this->assertFalse($f->validate('*/3,1,1-12')); - } - - /** - * @covers \Cron\HoursField::isSatisfiedBy - */ - public function testChecksIfSatisfied() - { - $f = new HoursField(); - $this->assertTrue($f->isSatisfiedBy(new DateTime(), '?')); - $this->assertTrue($f->isSatisfiedBy(new DateTimeImmutable(), '?')); - } - - /** - * @covers \Cron\HoursField::increment - */ - public function testIncrementsDate() - { - $d = new DateTime('2011-03-15 11:15:00'); - $f = new HoursField(); - $f->increment($d); - $this->assertSame('2011-03-15 12:00:00', $d->format('Y-m-d H:i:s')); - - $d->setTime(11, 15, 0); - $f->increment($d, true); - $this->assertSame('2011-03-15 10:59:00', $d->format('Y-m-d H:i:s')); - } - - /** - * @covers \Cron\HoursField::increment - */ - public function testIncrementsDateTimeImmutable() - { - $d = new DateTimeImmutable('2011-03-15 11:15:00'); - $f = new HoursField(); - $f->increment($d); - $this->assertSame('2011-03-15 12:00:00', $d->format('Y-m-d H:i:s')); - } - - /** - * @covers \Cron\HoursField::increment - */ - public function testIncrementsDateWithThirtyMinuteOffsetTimezone() - { - $tz = date_default_timezone_get(); - date_default_timezone_set('America/St_Johns'); - $d = new DateTime('2011-03-15 11:15:00'); - $f = new HoursField(); - $f->increment($d); - $this->assertSame('2011-03-15 12:00:00', $d->format('Y-m-d H:i:s')); - - $d->setTime(11, 15, 0); - $f->increment($d, true); - $this->assertSame('2011-03-15 10:59:00', $d->format('Y-m-d H:i:s')); - date_default_timezone_set($tz); - } - - /** - * @covers \Cron\HoursField::increment - */ - public function testIncrementDateWithFifteenMinuteOffsetTimezone() - { - $tz = date_default_timezone_get(); - date_default_timezone_set('Asia/Kathmandu'); - $d = new DateTime('2011-03-15 11:15:00'); - $f = new HoursField(); - $f->increment($d); - $this->assertSame('2011-03-15 12:00:00', $d->format('Y-m-d H:i:s')); - - $d->setTime(11, 15, 0); - $f->increment($d, true); - $this->assertSame('2011-03-15 10:59:00', $d->format('Y-m-d H:i:s')); - date_default_timezone_set($tz); - } -} diff --git a/vendor/dragonmantank/cron-expression/tests/Cron/MinutesFieldTest.php b/vendor/dragonmantank/cron-expression/tests/Cron/MinutesFieldTest.php deleted file mode 100644 index 41a536d68..000000000 --- a/vendor/dragonmantank/cron-expression/tests/Cron/MinutesFieldTest.php +++ /dev/null @@ -1,73 +0,0 @@ - - */ -class MinutesFieldTest extends TestCase -{ - /** - * @covers \Cron\MinutesField::validate - */ - public function testValidatesField() - { - $f = new MinutesField(); - $this->assertTrue($f->validate('1')); - $this->assertTrue($f->validate('*')); - $this->assertFalse($f->validate('*/3,1,1-12')); - } - - /** - * @covers \Cron\MinutesField::isSatisfiedBy - */ - public function testChecksIfSatisfied() - { - $f = new MinutesField(); - $this->assertTrue($f->isSatisfiedBy(new DateTime(), '?')); - $this->assertTrue($f->isSatisfiedBy(new DateTimeImmutable(), '?')); - } - - /** - * @covers \Cron\MinutesField::increment - */ - public function testIncrementsDate() - { - $d = new DateTime('2011-03-15 11:15:00'); - $f = new MinutesField(); - $f->increment($d); - $this->assertSame('2011-03-15 11:16:00', $d->format('Y-m-d H:i:s')); - $f->increment($d, true); - $this->assertSame('2011-03-15 11:15:00', $d->format('Y-m-d H:i:s')); - } - - /** - * @covers \Cron\MinutesField::increment - */ - public function testIncrementsDateTimeImmutable() - { - $d = new DateTimeImmutable('2011-03-15 11:15:00'); - $f = new MinutesField(); - $f->increment($d); - $this->assertSame('2011-03-15 11:16:00', $d->format('Y-m-d H:i:s')); - } - - /** - * Various bad syntaxes that are reported to work, but shouldn't. - * - * @author Chris Tankersley - * @since 2017-08-18 - */ - public function testBadSyntaxesShouldNotValidate() - { - $f = new MinutesField(); - $this->assertFalse($f->validate('*-1')); - $this->assertFalse($f->validate('1-2-3')); - $this->assertFalse($f->validate('-1')); - } -} diff --git a/vendor/dragonmantank/cron-expression/tests/Cron/MonthFieldTest.php b/vendor/dragonmantank/cron-expression/tests/Cron/MonthFieldTest.php deleted file mode 100644 index f329f4c16..000000000 --- a/vendor/dragonmantank/cron-expression/tests/Cron/MonthFieldTest.php +++ /dev/null @@ -1,103 +0,0 @@ - - */ -class MonthFieldTest extends TestCase -{ - /** - * @covers \Cron\MonthField::validate - */ - public function testValidatesField() - { - $f = new MonthField(); - $this->assertTrue($f->validate('12')); - $this->assertTrue($f->validate('*')); - $this->assertFalse($f->validate('*/10,2,1-12')); - $this->assertFalse($f->validate('1.fix-regexp')); - } - - /** - * @covers \Cron\MonthField::isSatisfiedBy - */ - public function testChecksIfSatisfied() - { - $f = new MonthField(); - $this->assertTrue($f->isSatisfiedBy(new DateTime(), '?')); - $this->assertTrue($f->isSatisfiedBy(new DateTimeImmutable(), '?')); - } - - /** - * @covers \Cron\MonthField::increment - */ - public function testIncrementsDate() - { - $d = new DateTime('2011-03-15 11:15:00'); - $f = new MonthField(); - $f->increment($d); - $this->assertSame('2011-04-01 00:00:00', $d->format('Y-m-d H:i:s')); - - $d = new DateTime('2011-03-15 11:15:00'); - $f->increment($d, true); - $this->assertSame('2011-02-28 23:59:00', $d->format('Y-m-d H:i:s')); - } - - /** - * @covers \Cron\MonthField::increment - */ - public function testIncrementsDateTimeImmutable() - { - $d = new DateTimeImmutable('2011-03-15 11:15:00'); - $f = new MonthField(); - $f->increment($d); - $this->assertSame('2011-04-01 00:00:00', $d->format('Y-m-d H:i:s')); - } - - /** - * @covers \Cron\MonthField::increment - */ - public function testIncrementsDateWithThirtyMinuteTimezone() - { - $tz = date_default_timezone_get(); - date_default_timezone_set('America/St_Johns'); - $d = new DateTime('2011-03-31 11:59:59'); - $f = new MonthField(); - $f->increment($d); - $this->assertSame('2011-04-01 00:00:00', $d->format('Y-m-d H:i:s')); - - $d = new DateTime('2011-03-15 11:15:00'); - $f->increment($d, true); - $this->assertSame('2011-02-28 23:59:00', $d->format('Y-m-d H:i:s')); - date_default_timezone_set($tz); - } - - - /** - * @covers \Cron\MonthField::increment - */ - public function testIncrementsYearAsNeeded() - { - $f = new MonthField(); - $d = new DateTime('2011-12-15 00:00:00'); - $f->increment($d); - $this->assertSame('2012-01-01 00:00:00', $d->format('Y-m-d H:i:s')); - } - - /** - * @covers \Cron\MonthField::increment - */ - public function testDecrementsYearAsNeeded() - { - $f = new MonthField(); - $d = new DateTime('2011-01-15 00:00:00'); - $f->increment($d, true); - $this->assertSame('2010-12-31 23:59:00', $d->format('Y-m-d H:i:s')); - } -} diff --git a/vendor/eveseat/eseye/.styleci.yml b/vendor/eveseat/eseye/.styleci.yml index 6f69d566a..871bb4f74 100644 --- a/vendor/eveseat/eseye/.styleci.yml +++ b/vendor/eveseat/eseye/.styleci.yml @@ -6,7 +6,7 @@ enabled: - no_empty_comment disabled: - - psr12_braces + - laravel_braces - concat_without_spaces - phpdoc_no_package - no_blank_lines_after_class_opening diff --git a/vendor/eveseat/eseye/bin/index.php b/vendor/eveseat/eseye/bin/index.php index 2a7f19c36..58c0bac96 100644 --- a/vendor/eveseat/eseye/bin/index.php +++ b/vendor/eveseat/eseye/bin/index.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -36,7 +36,7 @@ function redirect_to_new() { header('Location: ' . $_SERVER['PHP_SELF'] . '?action=new'); - die(); + exit(); } /** @@ -333,7 +333,7 @@ switch ($_GET['action']) { echo 'All fields are mandatory!
' . PHP_EOL; echo 'Start again'; - die(); + exit(); } $_SESSION['clientid'] = $_REQUEST['clientid']; @@ -355,7 +355,7 @@ switch ($_GET['action']) { echo 'Invalid State! You will have to start again!
'; echo 'Start again'; - die(); + exit(); } // Clear the state value. diff --git a/vendor/eveseat/eseye/composer.json b/vendor/eveseat/eseye/composer.json index 6bea4d814..c28778761 100644 --- a/vendor/eveseat/eseye/composer.json +++ b/vendor/eveseat/eseye/composer.json @@ -8,7 +8,7 @@ "ext-json": "*", "ext-mbstring": "*", "ext-openssl": "*", - "guzzlehttp/guzzle": "^6.2", + "guzzlehttp/guzzle": "^6.2|^7.0", "nesbot/carbon": "^2.0", "monolog/monolog": "^2.0", "predis/predis": "^1.1", @@ -18,8 +18,9 @@ "web-token/jwt-signature-algorithm-ecdsa": "^2.1" }, "require-dev": { - "phpunit/phpunit": "^5.7", + "phpunit/phpunit": "^8.0|^9.0", "mikey179/vfsstream": "~1", + "m6web/redis-mock": "^5.0", "codeclimate/php-test-reporter": "dev-master" }, "license": "GPL-2.0", diff --git a/vendor/eveseat/eseye/example.php b/vendor/eveseat/eseye/example.php index b9e625007..064e1afb7 100644 --- a/vendor/eveseat/eseye/example.php +++ b/vendor/eveseat/eseye/example.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Access/AccessInterface.php b/vendor/eveseat/eseye/src/Access/AccessInterface.php index fd6999e6d..614836e32 100644 --- a/vendor/eveseat/eseye/src/Access/AccessInterface.php +++ b/vendor/eveseat/eseye/src/Access/AccessInterface.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Access/CheckAccess.php b/vendor/eveseat/eseye/src/Access/CheckAccess.php index 8f92d2b49..8f1ef1e3d 100644 --- a/vendor/eveseat/eseye/src/Access/CheckAccess.php +++ b/vendor/eveseat/eseye/src/Access/CheckAccess.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Cache/CacheInterface.php b/vendor/eveseat/eseye/src/Cache/CacheInterface.php index fc1cf0e8f..8ed35976b 100644 --- a/vendor/eveseat/eseye/src/Cache/CacheInterface.php +++ b/vendor/eveseat/eseye/src/Cache/CacheInterface.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Cache/FileCache.php b/vendor/eveseat/eseye/src/Cache/FileCache.php index a78a2cb02..b0c513991 100644 --- a/vendor/eveseat/eseye/src/Cache/FileCache.php +++ b/vendor/eveseat/eseye/src/Cache/FileCache.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Cache/HashesStrings.php b/vendor/eveseat/eseye/src/Cache/HashesStrings.php index cda3f7df7..5fea36cbc 100644 --- a/vendor/eveseat/eseye/src/Cache/HashesStrings.php +++ b/vendor/eveseat/eseye/src/Cache/HashesStrings.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Cache/MemcachedCache.php b/vendor/eveseat/eseye/src/Cache/MemcachedCache.php index fc0f0c8f3..fe236bc71 100644 --- a/vendor/eveseat/eseye/src/Cache/MemcachedCache.php +++ b/vendor/eveseat/eseye/src/Cache/MemcachedCache.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Cache/NullCache.php b/vendor/eveseat/eseye/src/Cache/NullCache.php index 54a2001f1..d159b59ff 100644 --- a/vendor/eveseat/eseye/src/Cache/NullCache.php +++ b/vendor/eveseat/eseye/src/Cache/NullCache.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Cache/RedisCache.php b/vendor/eveseat/eseye/src/Cache/RedisCache.php index 8bfa20451..427bf3fde 100644 --- a/vendor/eveseat/eseye/src/Cache/RedisCache.php +++ b/vendor/eveseat/eseye/src/Cache/RedisCache.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Checker/Claim/AzpChecker.php b/vendor/eveseat/eseye/src/Checker/Claim/AzpChecker.php index b61899f32..ca02563d9 100644 --- a/vendor/eveseat/eseye/src/Checker/Claim/AzpChecker.php +++ b/vendor/eveseat/eseye/src/Checker/Claim/AzpChecker.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Checker/Claim/NameChecker.php b/vendor/eveseat/eseye/src/Checker/Claim/NameChecker.php index 6d7a59ca2..5277ef383 100644 --- a/vendor/eveseat/eseye/src/Checker/Claim/NameChecker.php +++ b/vendor/eveseat/eseye/src/Checker/Claim/NameChecker.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Checker/Claim/OwnerChecker.php b/vendor/eveseat/eseye/src/Checker/Claim/OwnerChecker.php index 16c6fba0a..0b423e8ec 100644 --- a/vendor/eveseat/eseye/src/Checker/Claim/OwnerChecker.php +++ b/vendor/eveseat/eseye/src/Checker/Claim/OwnerChecker.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Checker/Claim/SubEveCharacterChecker.php b/vendor/eveseat/eseye/src/Checker/Claim/SubEveCharacterChecker.php index 32941c590..5b56c7769 100644 --- a/vendor/eveseat/eseye/src/Checker/Claim/SubEveCharacterChecker.php +++ b/vendor/eveseat/eseye/src/Checker/Claim/SubEveCharacterChecker.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Checker/Header/TypeChecker.php b/vendor/eveseat/eseye/src/Checker/Header/TypeChecker.php index 859b17d6c..5096c3882 100644 --- a/vendor/eveseat/eseye/src/Checker/Header/TypeChecker.php +++ b/vendor/eveseat/eseye/src/Checker/Header/TypeChecker.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Configuration.php b/vendor/eveseat/eseye/src/Configuration.php index 5dc732970..dcc14f643 100644 --- a/vendor/eveseat/eseye/src/Configuration.php +++ b/vendor/eveseat/eseye/src/Configuration.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Containers/AbstractArrayAccess.php b/vendor/eveseat/eseye/src/Containers/AbstractArrayAccess.php index 863757c51..d6383cd9f 100644 --- a/vendor/eveseat/eseye/src/Containers/AbstractArrayAccess.php +++ b/vendor/eveseat/eseye/src/Containers/AbstractArrayAccess.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Containers/EsiAuthentication.php b/vendor/eveseat/eseye/src/Containers/EsiAuthentication.php index 06ebe84c9..59713fc08 100644 --- a/vendor/eveseat/eseye/src/Containers/EsiAuthentication.php +++ b/vendor/eveseat/eseye/src/Containers/EsiAuthentication.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Containers/EsiConfiguration.php b/vendor/eveseat/eseye/src/Containers/EsiConfiguration.php index 49744702e..6f2d447d9 100644 --- a/vendor/eveseat/eseye/src/Containers/EsiConfiguration.php +++ b/vendor/eveseat/eseye/src/Containers/EsiConfiguration.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Containers/EsiResponse.php b/vendor/eveseat/eseye/src/Containers/EsiResponse.php index 8175981c7..41786397d 100644 --- a/vendor/eveseat/eseye/src/Containers/EsiResponse.php +++ b/vendor/eveseat/eseye/src/Containers/EsiResponse.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Eseye.php b/vendor/eveseat/eseye/src/Eseye.php index 96832a866..18d058447 100644 --- a/vendor/eveseat/eseye/src/Eseye.php +++ b/vendor/eveseat/eseye/src/Eseye.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -45,7 +45,7 @@ class Eseye /** * The Eseye Version. */ - const VERSION = '2.3.2'; + const VERSION = '2.4.0'; /** * @var \Seat\Eseye\Containers\EsiAuthentication diff --git a/vendor/eveseat/eseye/src/Exceptions/CachePathException.php b/vendor/eveseat/eseye/src/Exceptions/CachePathException.php index bb8753f25..340a85dc8 100644 --- a/vendor/eveseat/eseye/src/Exceptions/CachePathException.php +++ b/vendor/eveseat/eseye/src/Exceptions/CachePathException.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Exceptions/EsiScopeAccessDeniedException.php b/vendor/eveseat/eseye/src/Exceptions/EsiScopeAccessDeniedException.php index 5f2733bc2..b02ba6a8c 100644 --- a/vendor/eveseat/eseye/src/Exceptions/EsiScopeAccessDeniedException.php +++ b/vendor/eveseat/eseye/src/Exceptions/EsiScopeAccessDeniedException.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Exceptions/InvalidAuthenticationException.php b/vendor/eveseat/eseye/src/Exceptions/InvalidAuthenticationException.php index ae8178495..82b2a5695 100644 --- a/vendor/eveseat/eseye/src/Exceptions/InvalidAuthenticationException.php +++ b/vendor/eveseat/eseye/src/Exceptions/InvalidAuthenticationException.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Exceptions/InvalidConfigurationException.php b/vendor/eveseat/eseye/src/Exceptions/InvalidConfigurationException.php index 398b18d6d..b5135f99a 100644 --- a/vendor/eveseat/eseye/src/Exceptions/InvalidConfigurationException.php +++ b/vendor/eveseat/eseye/src/Exceptions/InvalidConfigurationException.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Exceptions/InvalidContainerDataException.php b/vendor/eveseat/eseye/src/Exceptions/InvalidContainerDataException.php index 1fa078011..2a0449c3b 100644 --- a/vendor/eveseat/eseye/src/Exceptions/InvalidContainerDataException.php +++ b/vendor/eveseat/eseye/src/Exceptions/InvalidContainerDataException.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Exceptions/InvalidEsiSpecException.php b/vendor/eveseat/eseye/src/Exceptions/InvalidEsiSpecException.php index e8f3e0d49..51fe54d62 100644 --- a/vendor/eveseat/eseye/src/Exceptions/InvalidEsiSpecException.php +++ b/vendor/eveseat/eseye/src/Exceptions/InvalidEsiSpecException.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Exceptions/RequestFailedException.php b/vendor/eveseat/eseye/src/Exceptions/RequestFailedException.php index ff792845f..2b64f376f 100644 --- a/vendor/eveseat/eseye/src/Exceptions/RequestFailedException.php +++ b/vendor/eveseat/eseye/src/Exceptions/RequestFailedException.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Exceptions/UriDataMissingException.php b/vendor/eveseat/eseye/src/Exceptions/UriDataMissingException.php index ed04007f0..4b7498294 100644 --- a/vendor/eveseat/eseye/src/Exceptions/UriDataMissingException.php +++ b/vendor/eveseat/eseye/src/Exceptions/UriDataMissingException.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Fetchers/FetcherInterface.php b/vendor/eveseat/eseye/src/Fetchers/FetcherInterface.php index 1334175ea..416f8af81 100644 --- a/vendor/eveseat/eseye/src/Fetchers/FetcherInterface.php +++ b/vendor/eveseat/eseye/src/Fetchers/FetcherInterface.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Fetchers/GuzzleFetcher.php b/vendor/eveseat/eseye/src/Fetchers/GuzzleFetcher.php index 281efa3e7..894d3c8d5 100644 --- a/vendor/eveseat/eseye/src/Fetchers/GuzzleFetcher.php +++ b/vendor/eveseat/eseye/src/Fetchers/GuzzleFetcher.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Helpers/helpers.php b/vendor/eveseat/eseye/src/Helpers/helpers.php index d192032f2..4d9d5be65 100644 --- a/vendor/eveseat/eseye/src/Helpers/helpers.php +++ b/vendor/eveseat/eseye/src/Helpers/helpers.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Log/FileLogger.php b/vendor/eveseat/eseye/src/Log/FileLogger.php index 673e30cfb..e82ceca18 100644 --- a/vendor/eveseat/eseye/src/Log/FileLogger.php +++ b/vendor/eveseat/eseye/src/Log/FileLogger.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Log/LogInterface.php b/vendor/eveseat/eseye/src/Log/LogInterface.php index b8ca8cacc..3a109a4ba 100644 --- a/vendor/eveseat/eseye/src/Log/LogInterface.php +++ b/vendor/eveseat/eseye/src/Log/LogInterface.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Log/NullLogger.php b/vendor/eveseat/eseye/src/Log/NullLogger.php index 786e2f803..60086a7bb 100644 --- a/vendor/eveseat/eseye/src/Log/NullLogger.php +++ b/vendor/eveseat/eseye/src/Log/NullLogger.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Log/RotatingFileLogger.php b/vendor/eveseat/eseye/src/Log/RotatingFileLogger.php index 3d1e4de6b..2a1d5a405 100644 --- a/vendor/eveseat/eseye/src/Log/RotatingFileLogger.php +++ b/vendor/eveseat/eseye/src/Log/RotatingFileLogger.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Traits/ConstructsContainers.php b/vendor/eveseat/eseye/src/Traits/ConstructsContainers.php index 44f3a9884..269c67b72 100644 --- a/vendor/eveseat/eseye/src/Traits/ConstructsContainers.php +++ b/vendor/eveseat/eseye/src/Traits/ConstructsContainers.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/src/Traits/ValidatesContainers.php b/vendor/eveseat/eseye/src/Traits/ValidatesContainers.php index 5ecc09e7f..62959812e 100644 --- a/vendor/eveseat/eseye/src/Traits/ValidatesContainers.php +++ b/vendor/eveseat/eseye/src/Traits/ValidatesContainers.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/tests/Access/CheckAccessTest.php b/vendor/eveseat/eseye/tests/Access/CheckAccessTest.php index a004743a3..595aaac16 100644 --- a/vendor/eveseat/eseye/tests/Access/CheckAccessTest.php +++ b/vendor/eveseat/eseye/tests/Access/CheckAccessTest.php @@ -20,16 +20,17 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ +use PHPUnit\Framework\TestCase; use Seat\Eseye\Access\CheckAccess; use Seat\Eseye\Configuration; use Seat\Eseye\Log\NullLogger; -class CheckAccessTest extends PHPUnit_Framework_TestCase +class CheckAccessTest extends TestCase { protected $check_access; - public function setUp() + public function setUp(): void { $this->check_access = new CheckAccess; diff --git a/vendor/eveseat/eseye/tests/Cache/FileCacheTest.php b/vendor/eveseat/eseye/tests/Cache/FileCacheTest.php index 98a7d220d..91cf2acd1 100644 --- a/vendor/eveseat/eseye/tests/Cache/FileCacheTest.php +++ b/vendor/eveseat/eseye/tests/Cache/FileCacheTest.php @@ -21,18 +21,19 @@ */ use org\bovigo\vfs\vfsStream; +use PHPUnit\Framework\TestCase; use Seat\Eseye\Cache\FileCache; use Seat\Eseye\Configuration; use Seat\Eseye\Exceptions\CachePathException; -class FileCacheTest extends PHPUnit_Framework_TestCase +class FileCacheTest extends TestCase { protected $root; protected $file_cache; - public function setUp() + public function setUp(): void { // Set the file cache path in the config singleton diff --git a/vendor/eveseat/eseye/tests/Cache/HashesStringsTest.php b/vendor/eveseat/eseye/tests/Cache/HashesStringsTest.php index f269e824d..49d5754de 100644 --- a/vendor/eveseat/eseye/tests/Cache/HashesStringsTest.php +++ b/vendor/eveseat/eseye/tests/Cache/HashesStringsTest.php @@ -20,9 +20,10 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ +use PHPUnit\Framework\TestCase; use Seat\Eseye\Cache\HashesStrings; -class HashesStringsTest extends PHPUnit_Framework_TestCase +class HashesStringsTest extends TestCase { use HashesStrings; diff --git a/vendor/eveseat/eseye/tests/Cache/MemcachedCacheTest.php b/vendor/eveseat/eseye/tests/Cache/MemcachedCacheTest.php index 05a255162..92a3bdfb3 100644 --- a/vendor/eveseat/eseye/tests/Cache/MemcachedCacheTest.php +++ b/vendor/eveseat/eseye/tests/Cache/MemcachedCacheTest.php @@ -20,56 +20,66 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ +use PHPUnit\Framework\TestCase; use Seat\Eseye\Cache\MemcachedCache; use Seat\Eseye\Containers\EsiResponse; -class MemcachedCacheTest extends PHPUnit_Framework_TestCase +class MemcachedCacheTest extends TestCase { - /* - * @var MemcachedCache + /** + * @var \Seat\Eseye\Containers\EsiResponse */ - protected $memcached_cache; - protected $esi_response_object; - public function setUp() + public function setUp(): void { - - $is_memcached = class_exists('Memcached', false); - if ($is_memcached) - $instance = $this->createMock(\Memcached::class); - else - $instance = $this->createMock(\Memcache::class); - - // Set the cache - $this->memcached_cache = new MemcachedCache($instance); - - $this->esi_response_object = new EsiResponse('', [], 'now', 200); + $this->esi_response_object = new EsiResponse('', ['ETag' => 'W/"b3ef78b1064a27974cbf18270c1f126d519f7b467ba2e35ccb6f0819"'], 'now', 200); } public function testMemcachedCacheInstantiates() { + $cache = new MemcachedCache(); - $this->assertInstanceOf(MemcachedCache::class, $this->memcached_cache); + $this->assertInstanceOf(MemcachedCache::class, $cache); } public function testMemcachedCacheBuildsCacheKey() { + $cache = new MemcachedCache(); - $key = $this->memcached_cache->buildCacheKey('/test', 'foo=bar'); + $key = $cache->buildCacheKey('/test', 'foo=bar'); $this->assertEquals('eseye:b0f071c288f528954cddef0e1aa24df41de874aa', $key); } public function testMemcachedCacheSetsKey() { + // Mock a memcache instance + $instance = $this->getMockBuilder(stdClass::class)->addMethods(['set', 'get'])->getMock(); + $instance->expects($this->once())->method('set')->willReturn(true); + $instance->expects($this->once())->method('get')->willReturn(serialize($this->esi_response_object)); - $this->memcached_cache->set('/foo', 'foo=bar', $this->esi_response_object); + // Set the cache + $cache = new MemcachedCache($instance); + + $cache->set('/foo', 'foo=bar', $this->esi_response_object); + + $this->assertEquals($this->esi_response_object, $cache->get('/foo', 'foo=bar')); } public function testMemcachedCacheForgetsKey() { - $this->memcached_cache->forget('/foo', 'foo=bar'); + // Mock a memcache instance + $instance = $this->getMockBuilder(stdClass::class)->addMethods(['delete', 'get'])->getMock(); + $instance->expects($this->once())->method('delete')->willReturn(true); + $instance->expects($this->once())->method('get')->willReturn(false); + + // Set the cache + $cache = new MemcachedCache($instance); + + $cache->forget('/foo', 'foo=bar'); + + $this->assertFalse($cache->get('/foo', 'foo=bar')); } } diff --git a/vendor/eveseat/eseye/tests/Cache/NullCacheTest.php b/vendor/eveseat/eseye/tests/Cache/NullCacheTest.php index a564e89fd..8e8b164ca 100644 --- a/vendor/eveseat/eseye/tests/Cache/NullCacheTest.php +++ b/vendor/eveseat/eseye/tests/Cache/NullCacheTest.php @@ -20,15 +20,16 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ +use PHPUnit\Framework\TestCase; use Seat\Eseye\Cache\NullCache; use Seat\Eseye\Containers\EsiResponse; -class NullCacheTest extends PHPUnit_Framework_TestCase +class NullCacheTest extends TestCase { protected $null_cache; - public function setUp() + public function setUp(): void { $this->null_cache = new NullCache; diff --git a/vendor/eveseat/eseye/tests/Cache/RedisCacheTest.php b/vendor/eveseat/eseye/tests/Cache/RedisCacheTest.php index a311f6a2a..8a2e94fbe 100644 --- a/vendor/eveseat/eseye/tests/Cache/RedisCacheTest.php +++ b/vendor/eveseat/eseye/tests/Cache/RedisCacheTest.php @@ -20,11 +20,13 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ +use M6Web\Component\RedisMock\RedisMockFactory; +use PHPUnit\Framework\TestCase; use Predis\Client; use Seat\Eseye\Cache\RedisCache; use Seat\Eseye\Containers\EsiResponse; -class RedisCacheTest extends PHPUnit_Framework_TestCase +class RedisCacheTest extends TestCase { /** @@ -34,14 +36,16 @@ class RedisCacheTest extends PHPUnit_Framework_TestCase protected $esi_response_object; - public function setUp() + public function setUp(): void { - $redis = $this->createMock(Client::class); + $factory = new RedisMockFactory(); + $class = $factory->getAdapterClass(Client::class, true); + $redis = new $class(); // Set the cache $this->redis_cache = new RedisCache($redis); - $this->esi_response_object = new EsiResponse('', [], 'now', 200); + $this->esi_response_object = new EsiResponse('', ['ETag' => 'W/"b3ef78b1064a27974cbf18270c1f126d519f7b467ba2e35ccb6f0819"'], 'now', 200); } public function testRedisCacheInstantiates() @@ -67,12 +71,16 @@ class RedisCacheTest extends PHPUnit_Framework_TestCase { $this->redis_cache->set('/foo', 'foo=bar', $this->esi_response_object); + + $this->assertEquals($this->esi_response_object, $this->redis_cache->get('/foo', 'foo=bar')); } public function testRedisCacheForgetsKey() { $this->redis_cache->forget('/foo', 'foo=bar'); + + $this->assertFalse($this->redis_cache->has('/foo', 'foo=bar')); } } diff --git a/vendor/eveseat/eseye/tests/ConfigurationTest.php b/vendor/eveseat/eseye/tests/ConfigurationTest.php index 73d4e8376..c71e87e29 100644 --- a/vendor/eveseat/eseye/tests/ConfigurationTest.php +++ b/vendor/eveseat/eseye/tests/ConfigurationTest.php @@ -20,13 +20,14 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ +use PHPUnit\Framework\TestCase; use Seat\Eseye\Cache\CacheInterface; use Seat\Eseye\Configuration; use Seat\Eseye\Containers\EsiConfiguration; use Seat\Eseye\Exceptions\InvalidContainerDataException; use Seat\Eseye\Log\LogInterface; -class ConfigurationTest extends PHPUnit_Framework_TestCase +class ConfigurationTest extends TestCase { public function testConfigurationInstantiation() diff --git a/vendor/eveseat/eseye/tests/Containers/EsiAuthenticationTest.php b/vendor/eveseat/eseye/tests/Containers/EsiAuthenticationTest.php index d38bddb05..6535dff7e 100644 --- a/vendor/eveseat/eseye/tests/Containers/EsiAuthenticationTest.php +++ b/vendor/eveseat/eseye/tests/Containers/EsiAuthenticationTest.php @@ -20,15 +20,16 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ +use PHPUnit\Framework\TestCase; use Seat\Eseye\Containers\EsiAuthentication; use Seat\Eseye\Exceptions\InvalidContainerDataException; -class EsiAuthenticationTest extends PHPUnit_Framework_TestCase +class EsiAuthenticationTest extends TestCase { protected $esi_authentication; - public function setUp() + public function setUp(): void { $this->esi_authentication = new EsiAuthentication; diff --git a/vendor/eveseat/eseye/tests/Containers/EsiConfigurationTest.php b/vendor/eveseat/eseye/tests/Containers/EsiConfigurationTest.php index a6c4f9901..5862c9103 100644 --- a/vendor/eveseat/eseye/tests/Containers/EsiConfigurationTest.php +++ b/vendor/eveseat/eseye/tests/Containers/EsiConfigurationTest.php @@ -20,18 +20,19 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ +use PHPUnit\Framework\TestCase; use Seat\Eseye\Containers\EsiConfiguration; use Seat\Eseye\Exceptions\InvalidContainerDataException; /** * Class EsiConfigurationTest */ -class EsiConfigurationTest extends \PHPUnit_Framework_TestCase +class EsiConfigurationTest extends TestCase { protected $esi_configuration; - public function setUp() + public function setUp(): void { $this->esi_configuration = new EsiConfiguration; diff --git a/vendor/eveseat/eseye/tests/Containers/EsiResponseTest.php b/vendor/eveseat/eseye/tests/Containers/EsiResponseTest.php index cd9a71fe7..d0c230e01 100644 --- a/vendor/eveseat/eseye/tests/Containers/EsiResponseTest.php +++ b/vendor/eveseat/eseye/tests/Containers/EsiResponseTest.php @@ -20,16 +20,17 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ +use PHPUnit\Framework\TestCase; use Seat\Eseye\Containers\EsiResponse; -class EsiResponseTest extends PHPUnit_Framework_TestCase +class EsiResponseTest extends TestCase { protected $esi_response; protected $headers; - public function setUp() + public function setUp(): void { // Sample data to work with diff --git a/vendor/eveseat/eseye/tests/EseyeTest.php b/vendor/eveseat/eseye/tests/EseyeTest.php index e55ae2bef..807f330e7 100644 --- a/vendor/eveseat/eseye/tests/EseyeTest.php +++ b/vendor/eveseat/eseye/tests/EseyeTest.php @@ -24,6 +24,7 @@ use GuzzleHttp\Client; use GuzzleHttp\Handler\MockHandler; use GuzzleHttp\HandlerStack; use GuzzleHttp\Psr7\Response; +use PHPUnit\Framework\TestCase; use Seat\Eseye\Access\CheckAccess; use Seat\Eseye\Cache\CacheInterface; use Seat\Eseye\Cache\FileCache; @@ -40,7 +41,7 @@ use Seat\Eseye\Fetchers\GuzzleFetcher; use Seat\Eseye\Log\LogInterface; use Seat\Eseye\Log\NullLogger; -class EseyeTest extends PHPUnit_Framework_TestCase +class EseyeTest extends TestCase { /** @@ -48,7 +49,7 @@ class EseyeTest extends PHPUnit_Framework_TestCase */ protected $esi; - public function setUp() + public function setUp(): void { // Remove logging @@ -89,7 +90,9 @@ class EseyeTest extends PHPUnit_Framework_TestCase 'secret' => 'SSO_SECRET', 'refresh_token' => 'CHARACTER_REFRESH_TOKEN', ]); - new Eseye($authentication); + $client = new Eseye($authentication); + + $this->assertEquals($authentication, $client->getAuthentication()); } public function testEseyeSetNewInvalidAuthenticationData() @@ -116,6 +119,8 @@ class EseyeTest extends PHPUnit_Framework_TestCase 'scopes' => ['public'], ]); $this->esi->setAuthentication($authentication); + + $this->assertEquals($authentication, $this->esi->getAuthentication()); } public function testEseyeGetAuthenticationBeforeSet() diff --git a/vendor/eveseat/eseye/tests/Exceptions/RequestFailedExceptionTest.php b/vendor/eveseat/eseye/tests/Exceptions/RequestFailedExceptionTest.php index cdf3b3f12..64d03982c 100644 --- a/vendor/eveseat/eseye/tests/Exceptions/RequestFailedExceptionTest.php +++ b/vendor/eveseat/eseye/tests/Exceptions/RequestFailedExceptionTest.php @@ -20,10 +20,11 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ +use PHPUnit\Framework\TestCase; use Seat\Eseye\Containers\EsiResponse; use Seat\Eseye\Exceptions\RequestFailedException; -class RequestFailedExceptionTest extends PHPUnit_Framework_TestCase +class RequestFailedExceptionTest extends TestCase { /** @@ -31,7 +32,7 @@ class RequestFailedExceptionTest extends PHPUnit_Framework_TestCase */ protected $exception; - public function setUp() + public function setUp(): void { $this->exception = new RequestFailedException(new Exception('Foo'), new EsiResponse( diff --git a/vendor/eveseat/eseye/tests/Fetchers/GuzzleFetcherTest.php b/vendor/eveseat/eseye/tests/Fetchers/GuzzleFetcherTest.php index 22e340753..03601b389 100644 --- a/vendor/eveseat/eseye/tests/Fetchers/GuzzleFetcherTest.php +++ b/vendor/eveseat/eseye/tests/Fetchers/GuzzleFetcherTest.php @@ -26,6 +26,7 @@ use GuzzleHttp\HandlerStack; use GuzzleHttp\Psr7\Response; use Jose\Component\Core\JWK; use Jose\Easy\Build; +use PHPUnit\Framework\TestCase; use Seat\Eseye\Configuration; use Seat\Eseye\Containers\EsiAuthentication; use Seat\Eseye\Containers\EsiResponse; @@ -34,7 +35,7 @@ use Seat\Eseye\Exceptions\RequestFailedException; use Seat\Eseye\Fetchers\GuzzleFetcher; use Seat\Eseye\Log\NullLogger; -class GuzzleFetcherTest extends PHPUnit_Framework_TestCase +class GuzzleFetcherTest extends TestCase { /** @@ -42,7 +43,7 @@ class GuzzleFetcherTest extends PHPUnit_Framework_TestCase */ protected $fetcher; - public function setUp() + public function setUp(): void { // Remove logging diff --git a/vendor/eveseat/eseye/tests/Log/FileLoggerTest.php b/vendor/eveseat/eseye/tests/Log/FileLoggerTest.php index ba0eb4414..f366bcb7a 100644 --- a/vendor/eveseat/eseye/tests/Log/FileLoggerTest.php +++ b/vendor/eveseat/eseye/tests/Log/FileLoggerTest.php @@ -22,17 +22,18 @@ use Monolog\Logger; use org\bovigo\vfs\vfsStream; +use PHPUnit\Framework\TestCase; use Seat\Eseye\Configuration; use Seat\Eseye\Log\FileLogger; -class FileLoggerTest extends PHPUnit_Framework_TestCase +class FileLoggerTest extends TestCase { protected $root; protected $logger; - public function setUp() + public function setUp(): void { // Set the file cache path in the config singleton @@ -48,7 +49,7 @@ class FileLoggerTest extends PHPUnit_Framework_TestCase $this->logger->log('foo'); $logfile_content = $this->root->getChild('eseye.log')->getContent(); - $this->assertContains('eseye.INFO: foo', $logfile_content); + $this->assertStringContainsString('eseye.INFO: foo', $logfile_content); } public function testFileLoggerSkipWritesLogDebugWithoutRequiredLevel() @@ -71,7 +72,7 @@ class FileLoggerTest extends PHPUnit_Framework_TestCase $logger->debug('foo'); $logfile_content = $this->root->getChild('eseye.log')->getContent(); - $this->assertContains('eseye.DEBUG: foo', $logfile_content); + $this->assertStringContainsString('eseye.DEBUG: foo', $logfile_content); } public function testFileLoggerWritesLogWarning() @@ -80,7 +81,7 @@ class FileLoggerTest extends PHPUnit_Framework_TestCase $this->logger->warning('foo'); $logfile_content = $this->root->getChild('eseye.log')->getContent(); - $this->assertContains('eseye.WARNING: foo', $logfile_content); + $this->assertStringContainsString('eseye.WARNING: foo', $logfile_content); } public function testFileLoggerWritesLogError() @@ -89,7 +90,7 @@ class FileLoggerTest extends PHPUnit_Framework_TestCase $this->logger->error('foo'); $logfile_content = $this->root->getChild('eseye.log')->getContent(); - $this->assertContains('eseye.ERROR: foo', $logfile_content); + $this->assertStringContainsString('eseye.ERROR: foo', $logfile_content); } } diff --git a/vendor/eveseat/eseye/tests/Log/NullLoggerTest.php b/vendor/eveseat/eseye/tests/Log/NullLoggerTest.php index bd2533b11..b0f723222 100644 --- a/vendor/eveseat/eseye/tests/Log/NullLoggerTest.php +++ b/vendor/eveseat/eseye/tests/Log/NullLoggerTest.php @@ -20,17 +20,17 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ +use PHPUnit\Framework\TestCase; use Seat\Eseye\Log\NullLogger; -class NullLoggerTest extends PHPUnit_Framework_TestCase +class NullLoggerTest extends TestCase { protected $logger; - public function setUp() + public function setUp(): void { - $this->logger = new NullLogger; } diff --git a/vendor/eveseat/eseye/tests/Log/RotatingFileLoggerTest.php b/vendor/eveseat/eseye/tests/Log/RotatingFileLoggerTest.php index f388e9c5f..0ac7fab40 100644 --- a/vendor/eveseat/eseye/tests/Log/RotatingFileLoggerTest.php +++ b/vendor/eveseat/eseye/tests/Log/RotatingFileLoggerTest.php @@ -22,10 +22,11 @@ use Monolog\Logger; use org\bovigo\vfs\vfsStream; +use PHPUnit\Framework\TestCase; use Seat\Eseye\Configuration; use Seat\Eseye\Log\RotatingFileLogger; -class RotatingFileLoggerTest extends PHPUnit_Framework_TestCase +class RotatingFileLoggerTest extends TestCase { protected $root; @@ -34,7 +35,7 @@ class RotatingFileLoggerTest extends PHPUnit_Framework_TestCase protected $logfile_name; - public function setUp() + public function setUp(): void { // Set the file cache path in the config singleton @@ -54,7 +55,7 @@ class RotatingFileLoggerTest extends PHPUnit_Framework_TestCase $this->logger->log('foo'); $logfile_content = $this->root->getChild($this->logfile_name)->getContent(); - $this->assertContains('eseye.INFO: foo', $logfile_content); + $this->assertStringContainsString('eseye.INFO: foo', $logfile_content); } public function testFileLoggerSkipWritesLogDebugWithoutRequiredLevel() @@ -77,7 +78,7 @@ class RotatingFileLoggerTest extends PHPUnit_Framework_TestCase $logger->debug('foo'); $logfile_content = $this->root->getChild($this->logfile_name)->getContent(); - $this->assertContains('eseye.DEBUG: foo', $logfile_content); + $this->assertStringContainsString('eseye.DEBUG: foo', $logfile_content); } public function testFileLoggerWritesLogWarning() @@ -86,7 +87,7 @@ class RotatingFileLoggerTest extends PHPUnit_Framework_TestCase $this->logger->warning('foo'); $logfile_content = $this->root->getChild($this->logfile_name)->getContent(); - $this->assertContains('eseye.WARNING: foo', $logfile_content); + $this->assertStringContainsString('eseye.WARNING: foo', $logfile_content); } public function testFileLoggerWritesLogError() @@ -95,7 +96,7 @@ class RotatingFileLoggerTest extends PHPUnit_Framework_TestCase $this->logger->error('foo'); $logfile_content = $this->root->getChild($this->logfile_name)->getContent(); - $this->assertContains('eseye.ERROR: foo', $logfile_content); + $this->assertStringContainsString('eseye.ERROR: foo', $logfile_content); } } diff --git a/vendor/eveseat/eseye/tools/get_endpoints_and_scopes.php b/vendor/eveseat/eseye/tools/get_endpoints_and_scopes.php index 6809d1970..03feb6069 100644 --- a/vendor/eveseat/eseye/tools/get_endpoints_and_scopes.php +++ b/vendor/eveseat/eseye/tools/get_endpoints_and_scopes.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/eveseat/eseye/tools/swagger_download.php b/vendor/eveseat/eseye/tools/swagger_download.php index 8313ae511..91490909d 100644 --- a/vendor/eveseat/eseye/tools/swagger_download.php +++ b/vendor/eveseat/eseye/tools/swagger_download.php @@ -3,7 +3,7 @@ /* * This file is part of SeAT * - * Copyright (C) 2015 to 2020 Leon Jacobs + * Copyright (C) 2015 to 2021 Leon Jacobs * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/vendor/cakephp/chronos/LICENSE b/vendor/graham-campbell/result-type/LICENSE similarity index 79% rename from vendor/cakephp/chronos/LICENSE rename to vendor/graham-campbell/result-type/LICENSE index 97f3ee6d4..b99eca483 100644 --- a/vendor/cakephp/chronos/LICENSE +++ b/vendor/graham-campbell/result-type/LICENSE @@ -1,15 +1,16 @@ -Copyright (C) Brian Nesbitt -Copyright (C) Cake Software Foundation, Inc. (http://cakefoundation.org) +The MIT License (MIT) + +Copyright (c) 2020 Graham Campbell Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is furnished -to do so, subject to the following conditions: +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, diff --git a/vendor/graham-campbell/result-type/composer.json b/vendor/graham-campbell/result-type/composer.json new file mode 100644 index 000000000..9c394ada2 --- /dev/null +++ b/vendor/graham-campbell/result-type/composer.json @@ -0,0 +1,39 @@ +{ + "name": "graham-campbell/result-type", + "description": "An Implementation Of The Result Type", + "keywords": ["result", "result-type", "Result", "Result Type", "Result-Type", "Graham Campbell", "GrahamCampbell"], + "license": "MIT", + "authors": [ + { + "name": "Graham Campbell", + "email": "graham@alt-three.com" + } + ], + "require": { + "php": "^7.0|^8.0", + "phpoption/phpoption": "^1.7.3" + }, + "require-dev": { + "phpunit/phpunit": "^6.5|^7.5|^8.5|^9.0" + }, + "autoload": { + "psr-4": { + "GrahamCampbell\\ResultType\\": "src/" + } + }, + "autoload-dev": { + "psr-4": { + "GrahamCampbell\\Tests\\ResultType\\": "tests/" + } + }, + "config": { + "preferred-install": "dist" + }, + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "minimum-stability": "dev", + "prefer-stable": true +} diff --git a/vendor/vlucas/phpdotenv/src/Result/Error.php b/vendor/graham-campbell/result-type/src/Error.php similarity index 57% rename from vendor/vlucas/phpdotenv/src/Result/Error.php rename to vendor/graham-campbell/result-type/src/Error.php index d0be21d9c..dba6d79cb 100644 --- a/vendor/vlucas/phpdotenv/src/Result/Error.php +++ b/vendor/graham-campbell/result-type/src/Error.php @@ -1,6 +1,17 @@ + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +namespace GrahamCampbell\ResultType; use PhpOption\None; use PhpOption\Some; @@ -8,9 +19,9 @@ use PhpOption\Some; /** * @template T * @template E - * @extends \Dotenv\Result\Result + * @extends \GrahamCampbell\ResultType\Result */ -class Error extends Result +final class Error extends Result { /** * @var E @@ -36,7 +47,7 @@ class Error extends Result * * @param F $value * - * @return \Dotenv\Result\Result + * @return \GrahamCampbell\ResultType\Result */ public static function create($value) { @@ -60,13 +71,29 @@ class Error extends Result * * @param callable(T):S $f * - * @return \Dotenv\Result\Result + * @return \GrahamCampbell\ResultType\Result */ - public function mapSuccess(callable $f) + public function map(callable $f) { return self::create($this->value); } + /** + * Flat map over the success value. + * + * @template S + * @template F + * + * @param callable(T):\GrahamCampbell\ResultType\Result $f + * + * @return \GrahamCampbell\ResultType\Result + */ + public function flatMap(callable $f) + { + /** @var \GrahamCampbell\ResultType\Result */ + return self::create($this->value); + } + /** * Get the error option value. * @@ -84,7 +111,7 @@ class Error extends Result * * @param callable(E):F $f * - * @return \Dotenv\Result\Result + * @return \GrahamCampbell\ResultType\Result */ public function mapError(callable $f) { diff --git a/vendor/graham-campbell/result-type/src/Result.php b/vendor/graham-campbell/result-type/src/Result.php new file mode 100644 index 000000000..485fa0858 --- /dev/null +++ b/vendor/graham-campbell/result-type/src/Result.php @@ -0,0 +1,69 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +namespace GrahamCampbell\ResultType; + +/** + * @template T + * @template E + */ +abstract class Result +{ + /** + * Get the success option value. + * + * @return \PhpOption\Option + */ + abstract public function success(); + + /** + * Map over the success value. + * + * @template S + * + * @param callable(T):S $f + * + * @return \GrahamCampbell\ResultType\Result + */ + abstract public function map(callable $f); + + /** + * Flat map over the success value. + * + * @template S + * @template F + * + * @param callable(T):\GrahamCampbell\ResultType\Result $f + * + * @return \GrahamCampbell\ResultType\Result + */ + abstract public function flatMap(callable $f); + + /** + * Get the error option value. + * + * @return \PhpOption\Option + */ + abstract public function error(); + + /** + * Map over the error value. + * + * @template F + * + * @param callable(E):F $f + * + * @return \GrahamCampbell\ResultType\Result + */ + abstract public function mapError(callable $f); +} diff --git a/vendor/vlucas/phpdotenv/src/Result/Success.php b/vendor/graham-campbell/result-type/src/Success.php similarity index 59% rename from vendor/vlucas/phpdotenv/src/Result/Success.php rename to vendor/graham-campbell/result-type/src/Success.php index 32ebd9afb..1cb086683 100644 --- a/vendor/vlucas/phpdotenv/src/Result/Success.php +++ b/vendor/graham-campbell/result-type/src/Success.php @@ -1,6 +1,17 @@ + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +namespace GrahamCampbell\ResultType; use PhpOption\None; use PhpOption\Some; @@ -8,9 +19,9 @@ use PhpOption\Some; /** * @template T * @template E - * @extends \Dotenv\Result\Result + * @extends \GrahamCampbell\ResultType\Result */ -class Success extends Result +final class Success extends Result { /** * @var T @@ -36,7 +47,7 @@ class Success extends Result * * @param S $value * - * @return \Dotenv\Result\Result + * @return \GrahamCampbell\ResultType\Result */ public static function create($value) { @@ -60,13 +71,28 @@ class Success extends Result * * @param callable(T):S $f * - * @return \Dotenv\Result\Result + * @return \GrahamCampbell\ResultType\Result */ - public function mapSuccess(callable $f) + public function map(callable $f) { return self::create($f($this->value)); } + /** + * Flat map over the success value. + * + * @template S + * @template F + * + * @param callable(T):\GrahamCampbell\ResultType\Result $f + * + * @return \GrahamCampbell\ResultType\Result + */ + public function flatMap(callable $f) + { + return $f($this->value); + } + /** * Get the error option value. * @@ -84,7 +110,7 @@ class Success extends Result * * @param callable(E):F $f * - * @return \Dotenv\Result\Result + * @return \GrahamCampbell\ResultType\Result */ public function mapError(callable $f) { diff --git a/vendor/guzzlehttp/guzzle/.php_cs b/vendor/guzzlehttp/guzzle/.php_cs deleted file mode 100644 index 2dd5036c1..000000000 --- a/vendor/guzzlehttp/guzzle/.php_cs +++ /dev/null @@ -1,23 +0,0 @@ -setRiskyAllowed(true) - ->setRules([ - '@PSR2' => true, - 'array_syntax' => ['syntax' => 'short'], - 'declare_strict_types' => false, - 'concat_space' => ['spacing'=>'one'], - 'php_unit_test_case_static_method_calls' => ['call_type' => 'self'], - 'ordered_imports' => true, - // 'phpdoc_align' => ['align'=>'vertical'], - // 'native_function_invocation' => true, - ]) - ->setFinder( - PhpCsFixer\Finder::create() - ->in(__DIR__.'/src') - ->in(__DIR__.'/tests') - ->name('*.php') - ) -; - -return $config; diff --git a/vendor/guzzlehttp/guzzle/CHANGELOG.md b/vendor/guzzlehttp/guzzle/CHANGELOG.md index 464cf1c50..e303af281 100644 --- a/vendor/guzzlehttp/guzzle/CHANGELOG.md +++ b/vendor/guzzlehttp/guzzle/CHANGELOG.md @@ -1,17 +1,146 @@ # Change Log -## 6.5.5 - 2020-06-16 +Please refer to [UPGRADING](UPGRADING.md) guide for upgrading to a major version. -* Unpin version constraint for `symfony/polyfill-intl-idn` [#2678](https://github.com/guzzle/guzzle/pull/2678) +## 7.3.0 - 2021-03-23 -## 6.5.4 - 2020-05-25 +### Added -* Fix various intl icu issues [#2626](https://github.com/guzzle/guzzle/pull/2626) +- Support for DER and P12 certificates [#2413](https://github.com/guzzle/guzzle/pull/2413) +- Support the cURL (http://) scheme for StreamHandler proxies [#2850](https://github.com/guzzle/guzzle/pull/2850) +- Support for `guzzlehttp/psr7:^2.0` [#2878](https://github.com/guzzle/guzzle/pull/2878) -## 6.5.3 - 2020-04-18 +### Fixed +- Handle exceptions on invalid header consistently between PHP versions and handlers [#2872](https://github.com/guzzle/guzzle/pull/2872) + +## 7.2.0 - 2020-10-10 + +### Added + +- Support for PHP 8 [#2712](https://github.com/guzzle/guzzle/pull/2712), [#2715](https://github.com/guzzle/guzzle/pull/2715), [#2789](https://github.com/guzzle/guzzle/pull/2789) +- Support passing a body summarizer to the http errors middleware [#2795](https://github.com/guzzle/guzzle/pull/2795) + +### Fixed + +- Handle exceptions during response creation [#2591](https://github.com/guzzle/guzzle/pull/2591) +- Fix CURLOPT_ENCODING not to be overwritten [#2595](https://github.com/guzzle/guzzle/pull/2595) +- Make sure the Request always has a body object [#2804](https://github.com/guzzle/guzzle/pull/2804) + +### Changed + +- The `TooManyRedirectsException` has a response [#2660](https://github.com/guzzle/guzzle/pull/2660) +- Avoid "functions" from dependencies [#2712](https://github.com/guzzle/guzzle/pull/2712) + +### Deprecated + +- Using environment variable GUZZLE_CURL_SELECT_TIMEOUT [#2786](https://github.com/guzzle/guzzle/pull/2786) + +## 7.1.1 - 2020-09-30 + +### Fixed + +- Incorrect EOF detection for response body streams on Windows. + +### Changed + +- We dont connect curl `sink` on HEAD requests. +- Removed some PHP 5 workarounds + +## 7.1.0 - 2020-09-22 + +### Added + +- `GuzzleHttp\MessageFormatterInterface` + +### Fixed + +- Fixed issue that caused cookies with no value not to be stored. +- On redirects, we allow all safe methods like GET, HEAD and OPTIONS. +- Fixed logging on empty responses. +- Make sure MessageFormatter::format returns string + +### Deprecated + +- All functions in `GuzzleHttp` has been deprecated. Use static methods on `Utils` instead. +- `ClientInterface::getConfig()` +- `Client::getConfig()` +- `Client::__call()` +- `Utils::defaultCaBundle()` +- `CurlFactory::LOW_CURL_VERSION_NUMBER` + +## 7.0.1 - 2020-06-27 + +* Fix multiply defined functions fatal error [#2699](https://github.com/guzzle/guzzle/pull/2699) + +## 7.0.0 - 2020-06-27 + +No changes since 7.0.0-rc1. + +## 7.0.0-rc1 - 2020-06-15 + +### Changed + +* Use error level for logging errors in Middleware [#2629](https://github.com/guzzle/guzzle/pull/2629) +* Disabled IDN support by default and require ext-intl to use it [#2675](https://github.com/guzzle/guzzle/pull/2675) + +## 7.0.0-beta2 - 2020-05-25 + +### Added + +* Using `Utils` class instead of functions in the `GuzzleHttp` namespace. [#2546](https://github.com/guzzle/guzzle/pull/2546) +* `ClientInterface::MAJOR_VERSION` [#2583](https://github.com/guzzle/guzzle/pull/2583) + +### Changed + +* Avoid the `getenv` function when unsafe [#2531](https://github.com/guzzle/guzzle/pull/2531) +* Added real client methods [#2529](https://github.com/guzzle/guzzle/pull/2529) +* Avoid functions due to global install conflicts [#2546](https://github.com/guzzle/guzzle/pull/2546) * Use Symfony intl-idn polyfill [#2550](https://github.com/guzzle/guzzle/pull/2550) -* Remove use of internal functions [#2548](https://github.com/guzzle/guzzle/pull/2548) +* Adding methods for HTTP verbs like `Client::get()`, `Client::head()`, `Client::patch()` etc [#2529](https://github.com/guzzle/guzzle/pull/2529) +* `ConnectException` extends `TransferException` [#2541](https://github.com/guzzle/guzzle/pull/2541) +* Updated the default User Agent to "GuzzleHttp/7" [#2654](https://github.com/guzzle/guzzle/pull/2654) + +### Fixed + +* Various intl icu issues [#2626](https://github.com/guzzle/guzzle/pull/2626) + +### Removed + +* Pool option `pool_size` [#2528](https://github.com/guzzle/guzzle/pull/2528) + +## 7.0.0-beta1 - 2019-12-30 + +The diff might look very big but 95% of Guzzle users will be able to upgrade without modification. +Please see [the upgrade document](UPGRADING.md) that describes all BC breaking changes. + +### Added + +* Implement PSR-18 and dropped PHP 5 support [#2421](https://github.com/guzzle/guzzle/pull/2421) [#2474](https://github.com/guzzle/guzzle/pull/2474) +* PHP 7 types [#2442](https://github.com/guzzle/guzzle/pull/2442) [#2449](https://github.com/guzzle/guzzle/pull/2449) [#2466](https://github.com/guzzle/guzzle/pull/2466) [#2497](https://github.com/guzzle/guzzle/pull/2497) [#2499](https://github.com/guzzle/guzzle/pull/2499) +* IDN support for redirects [2424](https://github.com/guzzle/guzzle/pull/2424) + +### Changed + +* Dont allow passing null as third argument to `BadResponseException::__construct()` [#2427](https://github.com/guzzle/guzzle/pull/2427) +* Use SAPI constant instead of method call [#2450](https://github.com/guzzle/guzzle/pull/2450) +* Use native function invocation [#2444](https://github.com/guzzle/guzzle/pull/2444) +* Better defaults for PHP installations with old ICU lib [2454](https://github.com/guzzle/guzzle/pull/2454) +* Added visibility to all constants [#2462](https://github.com/guzzle/guzzle/pull/2462) +* Dont allow passing `null` as URI to `Client::request()` and `Client::requestAsync()` [#2461](https://github.com/guzzle/guzzle/pull/2461) +* Widen the exception argument to throwable [#2495](https://github.com/guzzle/guzzle/pull/2495) + +### Fixed + +* Logging when Promise rejected with a string [#2311](https://github.com/guzzle/guzzle/pull/2311) + +### Removed + +* Class `SeekException` [#2162](https://github.com/guzzle/guzzle/pull/2162) +* `RequestException::getResponseBodySummary()` [#2425](https://github.com/guzzle/guzzle/pull/2425) +* `CookieJar::getCookieValue()` [#2433](https://github.com/guzzle/guzzle/pull/2433) +* `uri_template()` and `UriTemplate` [#2440](https://github.com/guzzle/guzzle/pull/2440) +* Request options `save_to` and `exceptions` [#2464](https://github.com/guzzle/guzzle/pull/2464) ## 6.5.2 - 2019-12-23 @@ -27,16 +156,13 @@ * Improvement: Added support for reset internal queue in MockHandler. [#2143](https://github.com/guzzle/guzzle/pull/2143) * Improvement: Added support to pass arbitrary options to `curl_multi_init`. [#2287](https://github.com/guzzle/guzzle/pull/2287) * Fix: Gracefully handle passing `null` to the `header` option. [#2132](https://github.com/guzzle/guzzle/pull/2132) -* Fix: `RetryMiddleware` did not do exponential delay between retries due unit mismatch. [#2132](https://github.com/guzzle/guzzle/pull/2132) - Previously, `RetryMiddleware` would sleep for 1 millisecond, then 2 milliseconds, then 4 milliseconds. - **After this change, `RetryMiddleware` will sleep for 1 second, then 2 seconds, then 4 seconds.** - `Middleware::retry()` accepts a second callback parameter to override the default timeouts if needed. +* Fix: `RetryMiddleware` did not do exponential delay between retires due unit mismatch. [#2132](https://github.com/guzzle/guzzle/pull/2132) * Fix: Prevent undefined offset when using array for ssl_key options. [#2348](https://github.com/guzzle/guzzle/pull/2348) * Deprecated `ClientInterface::VERSION` ## 6.4.1 - 2019-10-23 -* No `guzzle.phar` was created in 6.4.0 due expired API token. This release will fix that +* No `guzzle.phar` was created in 6.4.0 due expired API token. This release will fix that * Added `parent::__construct()` to `FileCookieJar` and `SessionCookieJar` ## 6.4.0 - 2019-10-23 @@ -358,7 +484,7 @@ object). * Note: This has been changed in 5.0.3 to now encode query string values by default unless the `rawString` argument is provided when setting the query string on a URL: Now allowing many more characters to be present in the - query string without being percent encoded. See http://tools.ietf.org/html/rfc3986#appendix-A + query string without being percent encoded. See https://tools.ietf.org/html/rfc3986#appendix-A ## 5.0.1 - 2014-10-16 @@ -400,7 +526,7 @@ interfaces. responses, `GuzzleHttp\Collection`, `GuzzleHttp\Url`, `GuzzleHttp\Query`, `GuzzleHttp\Post\PostBody`, and `GuzzleHttp\Cookie\SetCookie`. This blog post provides a good outline of - why I did this: http://ocramius.github.io/blog/fluent-interfaces-are-evil/. + why I did this: https://ocramius.github.io/blog/fluent-interfaces-are-evil/. This also makes the Guzzle message interfaces compatible with the current PSR-7 message proposal. * Removed "functions.php", so that Guzzle is truly PSR-4 compliant. Except @@ -586,8 +712,6 @@ interfaces. ## 4.0.0 - 2014-03-29 -* For more information on the 4.0 transition, see: - http://mtdowling.com/blog/2014/03/15/guzzle-4-rc/ * For information on changes and upgrading, see: https://github.com/guzzle/guzzle/blob/master/UPGRADING.md#3x-to-40 * Added `GuzzleHttp\batch()` as a convenience function for sending requests in @@ -896,7 +1020,7 @@ interfaces. ## 3.4.0 - 2013-04-11 -* Bug fix: URLs are now resolved correctly based on http://tools.ietf.org/html/rfc3986#section-5.2. #289 +* Bug fix: URLs are now resolved correctly based on https://tools.ietf.org/html/rfc3986#section-5.2. #289 * Bug fix: Absolute URLs with a path in a service description will now properly override the base URL. #289 * Bug fix: Parsing a query string with a single PHP array value will now result in an array. #263 * Bug fix: Better normalization of the User-Agent header to prevent duplicate headers. #264. diff --git a/vendor/guzzlehttp/guzzle/Dockerfile b/vendor/guzzlehttp/guzzle/Dockerfile deleted file mode 100644 index f6a095230..000000000 --- a/vendor/guzzlehttp/guzzle/Dockerfile +++ /dev/null @@ -1,18 +0,0 @@ -FROM composer:latest as setup - -RUN mkdir /guzzle - -WORKDIR /guzzle - -RUN set -xe \ - && composer init --name=guzzlehttp/test --description="Simple project for testing Guzzle scripts" --author="Márk Sági-Kazár " --no-interaction \ - && composer require guzzlehttp/guzzle - - -FROM php:7.3 - -RUN mkdir /guzzle - -WORKDIR /guzzle - -COPY --from=setup /guzzle /guzzle diff --git a/vendor/guzzlehttp/guzzle/LICENSE b/vendor/guzzlehttp/guzzle/LICENSE index 50a177b03..d51aa6986 100644 --- a/vendor/guzzlehttp/guzzle/LICENSE +++ b/vendor/guzzlehttp/guzzle/LICENSE @@ -1,4 +1,4 @@ -Copyright (c) 2011-2018 Michael Dowling, https://github.com/mtdowling +Copyright (c) 2011 Michael Dowling, https://github.com/mtdowling Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/vendor/guzzlehttp/guzzle/README.md b/vendor/guzzlehttp/guzzle/README.md index 5fdb6c5f4..363d6f80d 100644 --- a/vendor/guzzlehttp/guzzle/README.md +++ b/vendor/guzzlehttp/guzzle/README.md @@ -1,8 +1,9 @@ -Guzzle, PHP HTTP client -======================= +![Guzzle](.github/logo.png?raw=true) + +# Guzzle, PHP HTTP client [![Latest Version](https://img.shields.io/github/release/guzzle/guzzle.svg?style=flat-square)](https://github.com/guzzle/guzzle/releases) -[![Build Status](https://img.shields.io/travis/guzzle/guzzle.svg?style=flat-square)](https://travis-ci.org/guzzle/guzzle) +[![Build Status](https://img.shields.io/github/workflow/status/guzzle/guzzle/CI?label=ci%20build&style=flat-square)](https://github.com/guzzle/guzzle/actions?query=workflow%3ACI) [![Total Downloads](https://img.shields.io/packagist/dt/guzzlehttp/guzzle.svg?style=flat-square)](https://packagist.org/packages/guzzlehttp/guzzle) Guzzle is a PHP HTTP client that makes it easy to send HTTP requests and @@ -14,6 +15,7 @@ trivial to integrate with web services. - Can send both synchronous and asynchronous requests using the same interface. - Uses PSR-7 interfaces for requests, responses, and streams. This allows you to utilize other PSR-7 compatible libraries with Guzzle. +- Supports PSR-18 allowing interoperability between other PSR-18 HTTP Clients. - Abstracts away the underlying HTTP transport, allowing you to write environment and transport agnostic code; i.e., no hard dependency on cURL, PHP streams, sockets, or non-blocking event loops. @@ -23,11 +25,11 @@ trivial to integrate with web services. $client = new \GuzzleHttp\Client(); $response = $client->request('GET', 'https://api.github.com/repos/guzzle/guzzle'); -echo $response->getStatusCode(); # 200 -echo $response->getHeaderLine('content-type'); # 'application/json; charset=utf8' -echo $response->getBody(); # '{"id": 1420053, "name": "guzzle", ...}' +echo $response->getStatusCode(); // 200 +echo $response->getHeaderLine('content-type'); // 'application/json; charset=utf8' +echo $response->getBody(); // '{"id": 1420053, "name": "guzzle", ...}' -# Send an asynchronous request. +// Send an asynchronous request. $request = new \GuzzleHttp\Psr7\Request('GET', 'http://httpbin.org'); $promise = $client->sendAsync($request)->then(function ($response) { echo 'I completed! ' . $response->getBody(); @@ -38,39 +40,23 @@ $promise->wait(); ## Help and docs +We use GitHub issues only to discuss bugs and new features. For support please refer to: + - [Documentation](http://guzzlephp.org/) - [Stack Overflow](http://stackoverflow.com/questions/tagged/guzzle) +- [#guzzle](https://app.slack.com/client/T0D2S9JCT/CE6UAAKL4) channel on [PHP-HTTP Slack](http://slack.httplug.io/) - [Gitter](https://gitter.im/guzzle/guzzle) ## Installing Guzzle The recommended way to install Guzzle is through -[Composer](http://getcomposer.org). - -```bash -# Install Composer -curl -sS https://getcomposer.org/installer | php -``` - -Next, run the Composer command to install the latest stable version of Guzzle: +[Composer](https://getcomposer.org/). ```bash composer require guzzlehttp/guzzle ``` -After installing, you need to require Composer's autoloader: - -```php -require 'vendor/autoload.php'; -``` - -You can then later update Guzzle using composer: - - ```bash -composer update - ``` - ## Version Guidance @@ -79,12 +65,15 @@ composer update | 3.x | EOL | `guzzle/guzzle` | `Guzzle` | [v3][guzzle-3-repo] | [v3][guzzle-3-docs] | No | >= 5.3.3 | | 4.x | EOL | `guzzlehttp/guzzle` | `GuzzleHttp` | [v4][guzzle-4-repo] | N/A | No | >= 5.4 | | 5.x | EOL | `guzzlehttp/guzzle` | `GuzzleHttp` | [v5][guzzle-5-repo] | [v5][guzzle-5-docs] | No | >= 5.4 | -| 6.x | Latest | `guzzlehttp/guzzle` | `GuzzleHttp` | [v6][guzzle-6-repo] | [v6][guzzle-6-docs] | Yes | >= 5.5 | +| 6.x | Security fixes | `guzzlehttp/guzzle` | `GuzzleHttp` | [v6][guzzle-6-repo] | [v6][guzzle-6-docs] | Yes | >= 5.5 | +| 7.x | Latest | `guzzlehttp/guzzle` | `GuzzleHttp` | [v7][guzzle-7-repo] | [v7][guzzle-7-docs] | Yes | >= 7.2 | [guzzle-3-repo]: https://github.com/guzzle/guzzle3 [guzzle-4-repo]: https://github.com/guzzle/guzzle/tree/4.x [guzzle-5-repo]: https://github.com/guzzle/guzzle/tree/5.3 -[guzzle-6-repo]: https://github.com/guzzle/guzzle +[guzzle-6-repo]: https://github.com/guzzle/guzzle/tree/6.5 +[guzzle-7-repo]: https://github.com/guzzle/guzzle [guzzle-3-docs]: http://guzzle3.readthedocs.org -[guzzle-5-docs]: http://guzzle.readthedocs.org/en/5.3/ -[guzzle-6-docs]: http://guzzle.readthedocs.org/en/latest/ +[guzzle-5-docs]: http://docs.guzzlephp.org/en/5.3/ +[guzzle-6-docs]: http://docs.guzzlephp.org/en/6.5/ +[guzzle-7-docs]: http://docs.guzzlephp.org/en/latest/ diff --git a/vendor/guzzlehttp/guzzle/UPGRADING.md b/vendor/guzzlehttp/guzzle/UPGRADING.md index 91d1dcc99..45417a7e1 100644 --- a/vendor/guzzlehttp/guzzle/UPGRADING.md +++ b/vendor/guzzlehttp/guzzle/UPGRADING.md @@ -1,10 +1,60 @@ Guzzle Upgrade Guide ==================== +6.0 to 7.0 +---------- + +In order to take advantage of the new features of PHP, Guzzle dropped the support +of PHP 5. The minimum supported PHP version is now PHP 7.2. Type hints and return +types for functions and methods have been added wherever possible. + +Please make sure: +- You are calling a function or a method with the correct type. +- If you extend a class of Guzzle; update all signatures on methods you override. + +#### Other backwards compatibility breaking changes + +- Class `GuzzleHttp\UriTemplate` is removed. +- Class `GuzzleHttp\Exception\SeekException` is removed. +- Classes `GuzzleHttp\Exception\BadResponseException`, `GuzzleHttp\Exception\ClientException`, + `GuzzleHttp\Exception\ServerException` can no longer be initialized with an empty + Response as argument. +- Class `GuzzleHttp\Exception\ConnectException` now extends `GuzzleHttp\Exception\TransferException` + instead of `GuzzleHttp\Exception\RequestException`. +- Function `GuzzleHttp\Exception\ConnectException::getResponse()` is removed. +- Function `GuzzleHttp\Exception\ConnectException::hasResponse()` is removed. +- Constant `GuzzleHttp\ClientInterface::VERSION` is removed. Added `GuzzleHttp\ClientInterface::MAJOR_VERSION` instead. +- Function `GuzzleHttp\Exception\RequestException::getResponseBodySummary` is removed. + Use `\GuzzleHttp\Psr7\get_message_body_summary` as an alternative. +- Function `GuzzleHttp\Cookie\CookieJar::getCookieValue` is removed. +- Request option `exception` is removed. Please use `http_errors`. +- Request option `save_to` is removed. Please use `sink`. +- Pool option `pool_size` is removed. Please use `concurrency`. +- We now look for environment variables in the `$_SERVER` super global, due to thread safety issues with `getenv`. We continue to fallback to `getenv` in CLI environments, for maximum compatibility. +- The `get`, `head`, `put`, `post`, `patch`, `delete`, `getAsync`, `headAsync`, `putAsync`, `postAsync`, `patchAsync`, and `deleteAsync` methods are now implemented as genuine methods on `GuzzleHttp\Client`, with strong typing. The original `__call` implementation remains unchanged for now, for maximum backwards compatibility, but won't be invoked under normal operation. +- The `log` middleware will log the errors with level `error` instead of `notice` +- Support for international domain names (IDN) is now disabled by default, and enabling it requires installing ext-intl, linked against a modern version of the C library (ICU 4.6 or higher). + +#### Native functions calls + +All internal native functions calls of Guzzle are now prefixed with a slash. This +change makes it impossible for method overloading by other libraries or applications. +Example: + +```php +// Before: +curl_version(); + +// After: +\curl_version(); +``` + +For the full diff you can check [here](https://github.com/guzzle/guzzle/compare/6.5.4..master). + 5.0 to 6.0 ---------- -Guzzle now uses [PSR-7](http://www.php-fig.org/psr/psr-7/) for HTTP messages. +Guzzle now uses [PSR-7](https://www.php-fig.org/psr/psr-7/) for HTTP messages. Due to the fact that these messages are immutable, this prompted a refactoring of Guzzle to use a middleware based system rather than an event system. Any HTTP message interaction (e.g., `GuzzleHttp\Message\Request`) need to be @@ -167,7 +217,7 @@ passing a `GuzzleHttp\Adapter\AdapterInterface`, you must now pass a PHP ## Removed Fluent Interfaces -[Fluent interfaces were removed](http://ocramius.github.io/blog/fluent-interfaces-are-evil) +[Fluent interfaces were removed](https://ocramius.github.io/blog/fluent-interfaces-are-evil/) from the following classes: - `GuzzleHttp\Collection` @@ -820,7 +870,7 @@ HeaderInterface (e.g. toArray(), getAll(), etc.). 3.3 to 3.4 ---------- -Base URLs of a client now follow the rules of http://tools.ietf.org/html/rfc3986#section-5.2.2 when merging URLs. +Base URLs of a client now follow the rules of https://tools.ietf.org/html/rfc3986#section-5.2.2 when merging URLs. 3.2 to 3.3 ---------- diff --git a/vendor/guzzlehttp/guzzle/composer.json b/vendor/guzzlehttp/guzzle/composer.json index c01864f01..5da35a5bc 100644 --- a/vendor/guzzlehttp/guzzle/composer.json +++ b/vendor/guzzlehttp/guzzle/composer.json @@ -9,7 +9,9 @@ "web service", "curl", "client", - "HTTP client" + "HTTP client", + "PSR-7", + "PSR-18" ], "homepage": "http://guzzlephp.org/", "license": "MIT", @@ -18,21 +20,33 @@ "name": "Michael Dowling", "email": "mtdowling@gmail.com", "homepage": "https://github.com/mtdowling" + }, + { + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com", + "homepage": "https://sagikazarmark.hu" } ], "require": { - "php": ">=5.5", + "php": "^7.2.5 || ^8.0", "ext-json": "*", - "symfony/polyfill-intl-idn": "^1.17.0", - "guzzlehttp/promises": "^1.0", - "guzzlehttp/psr7": "^1.6.1" + "guzzlehttp/promises": "^1.4", + "guzzlehttp/psr7": "^1.7 || ^2.0", + "psr/http-client": "^1.0" + }, + "provide": { + "psr/http-client-implementation": "1.0" }, "require-dev": { "ext-curl": "*", - "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.4 || ^7.0", + "bamarni/composer-bin-plugin": "^1.4.1", + "php-http/client-integration-tests": "^3.0", + "phpunit/phpunit": "^8.5.5 || ^9.3.5", "psr/log": "^1.1" }, "suggest": { + "ext-curl": "Required for CURL handler support", + "ext-intl": "Required for Internationalized Domain Name (IDN) support", "psr/log": "Required for using the Log middleware" }, "config": { @@ -40,7 +54,7 @@ }, "extra": { "branch-alias": { - "dev-master": "6.5-dev" + "dev-master": "7.3-dev" } }, "autoload": { diff --git a/vendor/guzzlehttp/guzzle/src/BodySummarizer.php b/vendor/guzzlehttp/guzzle/src/BodySummarizer.php new file mode 100644 index 000000000..6eca94ef9 --- /dev/null +++ b/vendor/guzzlehttp/guzzle/src/BodySummarizer.php @@ -0,0 +1,28 @@ +truncateAt = $truncateAt; + } + + /** + * Returns a summarized message body. + */ + public function summarize(MessageInterface $message): ?string + { + return $this->truncateAt === null + ? \GuzzleHttp\Psr7\Message::bodySummary($message) + : \GuzzleHttp\Psr7\Message::bodySummary($message, $this->truncateAt); + } +} diff --git a/vendor/guzzlehttp/guzzle/src/BodySummarizerInterface.php b/vendor/guzzlehttp/guzzle/src/BodySummarizerInterface.php new file mode 100644 index 000000000..3e02e036e --- /dev/null +++ b/vendor/guzzlehttp/guzzle/src/BodySummarizerInterface.php @@ -0,0 +1,13 @@ +configureDefaults($config); @@ -79,19 +74,21 @@ class Client implements ClientInterface * @param string $method * @param array $args * - * @return Promise\PromiseInterface + * @return PromiseInterface|ResponseInterface + * + * @deprecated Client::__call will be removed in guzzlehttp/guzzle:8.0. */ public function __call($method, $args) { - if (count($args) < 1) { - throw new \InvalidArgumentException('Magic request methods require a URI and optional options array'); + if (\count($args) < 1) { + throw new InvalidArgumentException('Magic request methods require a URI and optional options array'); } $uri = $args[0]; - $opts = isset($args[1]) ? $args[1] : []; + $opts = $args[1] ?? []; - return substr($method, -5) === 'Async' - ? $this->requestAsync(substr($method, 0, -5), $uri, $opts) + return \substr($method, -5) === 'Async' + ? $this->requestAsync(\substr($method, 0, -5), $uri, $opts) : $this->request($method, $uri, $opts); } @@ -100,10 +97,8 @@ class Client implements ClientInterface * * @param array $options Request options to apply to the given * request and to the transfer. See \GuzzleHttp\RequestOptions. - * - * @return Promise\PromiseInterface */ - public function sendAsync(RequestInterface $request, array $options = []) + public function sendAsync(RequestInterface $request, array $options = []): PromiseInterface { // Merge the base URI into the request URI if needed. $options = $this->prepareDefaults($options); @@ -120,15 +115,28 @@ class Client implements ClientInterface * @param array $options Request options to apply to the given * request and to the transfer. See \GuzzleHttp\RequestOptions. * - * @return ResponseInterface * @throws GuzzleException */ - public function send(RequestInterface $request, array $options = []) + public function send(RequestInterface $request, array $options = []): ResponseInterface { $options[RequestOptions::SYNCHRONOUS] = true; return $this->sendAsync($request, $options)->wait(); } + /** + * The HttpClient PSR (PSR-18) specify this method. + * + * @inheritDoc + */ + public function sendRequest(RequestInterface $request): ResponseInterface + { + $options[RequestOptions::SYNCHRONOUS] = true; + $options[RequestOptions::ALLOW_REDIRECTS] = false; + $options[RequestOptions::HTTP_ERRORS] = false; + + return $this->sendAsync($request, $options)->wait(); + } + /** * Create and send an asynchronous HTTP request. * @@ -140,20 +148,18 @@ class Client implements ClientInterface * @param string $method HTTP method * @param string|UriInterface $uri URI object or string. * @param array $options Request options to apply. See \GuzzleHttp\RequestOptions. - * - * @return Promise\PromiseInterface */ - public function requestAsync($method, $uri = '', array $options = []) + public function requestAsync(string $method, $uri = '', array $options = []): PromiseInterface { $options = $this->prepareDefaults($options); // Remove request modifying parameter because it can be done up-front. - $headers = isset($options['headers']) ? $options['headers'] : []; - $body = isset($options['body']) ? $options['body'] : null; - $version = isset($options['version']) ? $options['version'] : '1.1'; + $headers = $options['headers'] ?? []; + $body = $options['body'] ?? null; + $version = $options['version'] ?? '1.1'; // Merge the URI into the base URI. - $uri = $this->buildUri($uri, $options); - if (is_array($body)) { - $this->invalidBody(); + $uri = $this->buildUri(Psr7\Utils::uriFor($uri), $options); + if (\is_array($body)) { + throw $this->invalidBody(); } $request = new Psr7\Request($method, $uri, $headers, $body, $version); // Remove the option so that they are not doubly-applied. @@ -173,10 +179,9 @@ class Client implements ClientInterface * @param string|UriInterface $uri URI object or string. * @param array $options Request options to apply. See \GuzzleHttp\RequestOptions. * - * @return ResponseInterface * @throws GuzzleException */ - public function request($method, $uri = '', array $options = []) + public function request(string $method, $uri = '', array $options = []): ResponseInterface { $options[RequestOptions::SYNCHRONOUS] = true; return $this->requestAsync($method, $uri, $options)->wait(); @@ -192,30 +197,24 @@ class Client implements ClientInterface * @param string|null $option The config option to retrieve. * * @return mixed + * + * @deprecated Client::getConfig will be removed in guzzlehttp/guzzle:8.0. */ - public function getConfig($option = null) + public function getConfig(?string $option = null) { return $option === null ? $this->config - : (isset($this->config[$option]) ? $this->config[$option] : null); + : ($this->config[$option] ?? null); } - /** - * @param string|null $uri - * - * @return UriInterface - */ - private function buildUri($uri, array $config) + private function buildUri(UriInterface $uri, array $config): UriInterface { - // for BC we accept null which would otherwise fail in uri_for - $uri = Psr7\uri_for($uri === null ? '' : $uri); - if (isset($config['base_uri'])) { - $uri = Psr7\UriResolver::resolve(Psr7\uri_for($config['base_uri']), $uri); + $uri = Psr7\UriResolver::resolve(Psr7\Utils::uriFor($config['base_uri']), $uri); } if (isset($config['idn_conversion']) && ($config['idn_conversion'] !== false)) { - $idnOptions = ($config['idn_conversion'] === true) ? IDNA_DEFAULT : $config['idn_conversion']; + $idnOptions = ($config['idn_conversion'] === true) ? \IDNA_DEFAULT : $config['idn_conversion']; $uri = Utils::idnUriConvert($uri, $idnOptions); } @@ -224,11 +223,8 @@ class Client implements ClientInterface /** * Configures the default options for a client. - * - * @param array $config - * @return void */ - private function configureDefaults(array $config) + private function configureDefaults(array $config): void { $defaults = [ 'allow_redirects' => RedirectMiddleware::$defaultSettings, @@ -236,7 +232,7 @@ class Client implements ClientInterface 'decode_content' => true, 'verify' => true, 'cookies' => false, - 'idn_conversion' => true, + 'idn_conversion' => false, ]; // Use the standard Linux HTTP_PROXY and HTTPS_PROXY if set. @@ -244,17 +240,17 @@ class Client implements ClientInterface // We can only trust the HTTP_PROXY environment variable in a CLI // process due to the fact that PHP has no reliable mechanism to // get environment variables that start with "HTTP_". - if (php_sapi_name() === 'cli' && getenv('HTTP_PROXY')) { - $defaults['proxy']['http'] = getenv('HTTP_PROXY'); + if (\PHP_SAPI === 'cli' && ($proxy = Utils::getenv('HTTP_PROXY'))) { + $defaults['proxy']['http'] = $proxy; } - if ($proxy = getenv('HTTPS_PROXY')) { + if ($proxy = Utils::getenv('HTTPS_PROXY')) { $defaults['proxy']['https'] = $proxy; } - if ($noProxy = getenv('NO_PROXY')) { - $cleanedNoProxy = str_replace(' ', '', $noProxy); - $defaults['proxy']['no'] = explode(',', $cleanedNoProxy); + if ($noProxy = Utils::getenv('NO_PROXY')) { + $cleanedNoProxy = \str_replace(' ', '', $noProxy); + $defaults['proxy']['no'] = \explode(',', $cleanedNoProxy); } $this->config = $config + $defaults; @@ -265,15 +261,15 @@ class Client implements ClientInterface // Add the default user-agent header. if (!isset($this->config['headers'])) { - $this->config['headers'] = ['User-Agent' => default_user_agent()]; + $this->config['headers'] = ['User-Agent' => Utils::defaultUserAgent()]; } else { // Add the User-Agent header if one was not already set. - foreach (array_keys($this->config['headers']) as $name) { - if (strtolower($name) === 'user-agent') { + foreach (\array_keys($this->config['headers']) as $name) { + if (\strtolower($name) === 'user-agent') { return; } } - $this->config['headers']['User-Agent'] = default_user_agent(); + $this->config['headers']['User-Agent'] = Utils::defaultUserAgent(); } } @@ -281,10 +277,8 @@ class Client implements ClientInterface * Merges default options into the array. * * @param array $options Options to modify by reference - * - * @return array */ - private function prepareDefaults(array $options) + private function prepareDefaults(array $options): array { $defaults = $this->config; @@ -296,13 +290,13 @@ class Client implements ClientInterface // Special handling for headers is required as they are added as // conditional headers and as headers passed to a request ctor. - if (array_key_exists('headers', $options)) { + if (\array_key_exists('headers', $options)) { // Allows default headers to be unset. if ($options['headers'] === null) { $defaults['_conditional'] = []; unset($options['headers']); - } elseif (!is_array($options['headers'])) { - throw new \InvalidArgumentException('headers must be an array'); + } elseif (!\is_array($options['headers'])) { + throw new InvalidArgumentException('headers must be an array'); } } @@ -326,43 +320,24 @@ class Client implements ClientInterface * as-is without merging in default options. * * @param array $options See \GuzzleHttp\RequestOptions. - * - * @return Promise\PromiseInterface */ - private function transfer(RequestInterface $request, array $options) + private function transfer(RequestInterface $request, array $options): PromiseInterface { - // save_to -> sink - if (isset($options['save_to'])) { - $options['sink'] = $options['save_to']; - unset($options['save_to']); - } - - // exceptions -> http_errors - if (isset($options['exceptions'])) { - $options['http_errors'] = $options['exceptions']; - unset($options['exceptions']); - } - $request = $this->applyOptions($request, $options); /** @var HandlerStack $handler */ $handler = $options['handler']; try { - return Promise\promise_for($handler($request, $options)); + return P\Create::promiseFor($handler($request, $options)); } catch (\Exception $e) { - return Promise\rejection_for($e); + return P\Create::rejectionFor($e); } } /** * Applies the array of request options to a request. - * - * @param RequestInterface $request - * @param array $options - * - * @return RequestInterface */ - private function applyOptions(RequestInterface $request, array &$options) + private function applyOptions(RequestInterface $request, array &$options): RequestInterface { $modify = [ 'set_headers' => [], @@ -375,16 +350,16 @@ class Client implements ClientInterface if (isset($options['form_params'])) { if (isset($options['multipart'])) { - throw new \InvalidArgumentException('You cannot use ' + throw new InvalidArgumentException('You cannot use ' . 'form_params and multipart at the same time. Use the ' . 'form_params option if you want to send application/' . 'x-www-form-urlencoded requests, and the multipart ' . 'option to send multipart/form-data requests.'); } - $options['body'] = http_build_query($options['form_params'], '', '&'); + $options['body'] = \http_build_query($options['form_params'], '', '&'); unset($options['form_params']); // Ensure that we don't have the header in different case and set the new value. - $options['_conditional'] = Psr7\_caseless_remove(['Content-Type'], $options['_conditional']); + $options['_conditional'] = Psr7\Utils::caselessRemove(['Content-Type'], $options['_conditional']); $options['_conditional']['Content-Type'] = 'application/x-www-form-urlencoded'; } @@ -394,10 +369,10 @@ class Client implements ClientInterface } if (isset($options['json'])) { - $options['body'] = \GuzzleHttp\json_encode($options['json']); + $options['body'] = Utils::jsonEncode($options['json']); unset($options['json']); // Ensure that we don't have the header in different case and set the new value. - $options['_conditional'] = Psr7\_caseless_remove(['Content-Type'], $options['_conditional']); + $options['_conditional'] = Psr7\Utils::caselessRemove(['Content-Type'], $options['_conditional']); $options['_conditional']['Content-Type'] = 'application/json'; } @@ -405,47 +380,47 @@ class Client implements ClientInterface && $options['decode_content'] !== true ) { // Ensure that we don't have the header in different case and set the new value. - $options['_conditional'] = Psr7\_caseless_remove(['Accept-Encoding'], $options['_conditional']); + $options['_conditional'] = Psr7\Utils::caselessRemove(['Accept-Encoding'], $options['_conditional']); $modify['set_headers']['Accept-Encoding'] = $options['decode_content']; } if (isset($options['body'])) { - if (is_array($options['body'])) { - $this->invalidBody(); + if (\is_array($options['body'])) { + throw $this->invalidBody(); } - $modify['body'] = Psr7\stream_for($options['body']); + $modify['body'] = Psr7\Utils::streamFor($options['body']); unset($options['body']); } - if (!empty($options['auth']) && is_array($options['auth'])) { + if (!empty($options['auth']) && \is_array($options['auth'])) { $value = $options['auth']; - $type = isset($value[2]) ? strtolower($value[2]) : 'basic'; + $type = isset($value[2]) ? \strtolower($value[2]) : 'basic'; switch ($type) { case 'basic': // Ensure that we don't have the header in different case and set the new value. - $modify['set_headers'] = Psr7\_caseless_remove(['Authorization'], $modify['set_headers']); + $modify['set_headers'] = Psr7\Utils::caselessRemove(['Authorization'], $modify['set_headers']); $modify['set_headers']['Authorization'] = 'Basic ' - . base64_encode("$value[0]:$value[1]"); + . \base64_encode("$value[0]:$value[1]"); break; case 'digest': // @todo: Do not rely on curl - $options['curl'][CURLOPT_HTTPAUTH] = CURLAUTH_DIGEST; - $options['curl'][CURLOPT_USERPWD] = "$value[0]:$value[1]"; + $options['curl'][\CURLOPT_HTTPAUTH] = \CURLAUTH_DIGEST; + $options['curl'][\CURLOPT_USERPWD] = "$value[0]:$value[1]"; break; case 'ntlm': - $options['curl'][CURLOPT_HTTPAUTH] = CURLAUTH_NTLM; - $options['curl'][CURLOPT_USERPWD] = "$value[0]:$value[1]"; + $options['curl'][\CURLOPT_HTTPAUTH] = \CURLAUTH_NTLM; + $options['curl'][\CURLOPT_USERPWD] = "$value[0]:$value[1]"; break; } } if (isset($options['query'])) { $value = $options['query']; - if (is_array($value)) { - $value = http_build_query($value, null, '&', PHP_QUERY_RFC3986); + if (\is_array($value)) { + $value = \http_build_query($value, '', '&', \PHP_QUERY_RFC3986); } - if (!is_string($value)) { - throw new \InvalidArgumentException('query must be a string or array'); + if (!\is_string($value)) { + throw new InvalidArgumentException('query must be a string or array'); } $modify['query'] = $value; unset($options['query']); @@ -454,16 +429,16 @@ class Client implements ClientInterface // Ensure that sink is not an invalid value. if (isset($options['sink'])) { // TODO: Add more sink validation? - if (is_bool($options['sink'])) { - throw new \InvalidArgumentException('sink must not be a boolean'); + if (\is_bool($options['sink'])) { + throw new InvalidArgumentException('sink must not be a boolean'); } } - $request = Psr7\modify_request($request, $modify); + $request = Psr7\Utils::modifyRequest($request, $modify); if ($request->getBody() instanceof Psr7\MultipartStream) { // Use a multipart/form-data POST if a Content-Type is not set. // Ensure that we don't have the header in different case and set the new value. - $options['_conditional'] = Psr7\_caseless_remove(['Content-Type'], $options['_conditional']); + $options['_conditional'] = Psr7\Utils::caselessRemove(['Content-Type'], $options['_conditional']); $options['_conditional']['Content-Type'] = 'multipart/form-data; boundary=' . $request->getBody()->getBoundary(); } @@ -477,7 +452,7 @@ class Client implements ClientInterface $modify['set_headers'][$k] = $v; } } - $request = Psr7\modify_request($request, $modify); + $request = Psr7\Utils::modifyRequest($request, $modify); // Don't pass this internal value along to middleware/handlers. unset($options['_conditional']); } @@ -486,14 +461,12 @@ class Client implements ClientInterface } /** - * Throw Exception with pre-set message. - * @return void - * @throws \InvalidArgumentException Invalid body. + * Return an InvalidArgumentException with pre-set message. */ - private function invalidBody() + private function invalidBody(): InvalidArgumentException { - throw new \InvalidArgumentException('Passing in the "body" request ' - . 'option as an array to send a POST request has been deprecated. ' + return new InvalidArgumentException('Passing in the "body" request ' + . 'option as an array to send a request is not supported. ' . 'Please use the "form_params" request option to send a ' . 'application/x-www-form-urlencoded request, or the "multipart" ' . 'request option to send a multipart/form-data request.'); diff --git a/vendor/guzzlehttp/guzzle/src/ClientInterface.php b/vendor/guzzlehttp/guzzle/src/ClientInterface.php index 638b75dca..f257a1a30 100644 --- a/vendor/guzzlehttp/guzzle/src/ClientInterface.php +++ b/vendor/guzzlehttp/guzzle/src/ClientInterface.php @@ -1,4 +1,5 @@ request('GET', $uri, $options); + } + + /** + * Create and send an HTTP HEAD request. + * + * Use an absolute path to override the base path of the client, or a + * relative path to append to the base path of the client. The URL can + * contain the query string as well. + * + * @param string|UriInterface $uri URI object or string. + * @param array $options Request options to apply. + * + * @throws GuzzleException + */ + public function head($uri, array $options = []): ResponseInterface + { + return $this->request('HEAD', $uri, $options); + } + + /** + * Create and send an HTTP PUT request. + * + * Use an absolute path to override the base path of the client, or a + * relative path to append to the base path of the client. The URL can + * contain the query string as well. + * + * @param string|UriInterface $uri URI object or string. + * @param array $options Request options to apply. + * + * @throws GuzzleException + */ + public function put($uri, array $options = []): ResponseInterface + { + return $this->request('PUT', $uri, $options); + } + + /** + * Create and send an HTTP POST request. + * + * Use an absolute path to override the base path of the client, or a + * relative path to append to the base path of the client. The URL can + * contain the query string as well. + * + * @param string|UriInterface $uri URI object or string. + * @param array $options Request options to apply. + * + * @throws GuzzleException + */ + public function post($uri, array $options = []): ResponseInterface + { + return $this->request('POST', $uri, $options); + } + + /** + * Create and send an HTTP PATCH request. + * + * Use an absolute path to override the base path of the client, or a + * relative path to append to the base path of the client. The URL can + * contain the query string as well. + * + * @param string|UriInterface $uri URI object or string. + * @param array $options Request options to apply. + * + * @throws GuzzleException + */ + public function patch($uri, array $options = []): ResponseInterface + { + return $this->request('PATCH', $uri, $options); + } + + /** + * Create and send an HTTP DELETE request. + * + * Use an absolute path to override the base path of the client, or a + * relative path to append to the base path of the client. The URL can + * contain the query string as well. + * + * @param string|UriInterface $uri URI object or string. + * @param array $options Request options to apply. + * + * @throws GuzzleException + */ + public function delete($uri, array $options = []): ResponseInterface + { + return $this->request('DELETE', $uri, $options); + } + + /** + * Create and send an asynchronous HTTP request. + * + * Use an absolute path to override the base path of the client, or a + * relative path to append to the base path of the client. The URL can + * contain the query string as well. Use an array to provide a URL + * template and additional variables to use in the URL template expansion. + * + * @param string $method HTTP method + * @param string|UriInterface $uri URI object or string. + * @param array $options Request options to apply. + */ + abstract public function requestAsync(string $method, $uri, array $options = []): PromiseInterface; + + /** + * Create and send an asynchronous HTTP GET request. + * + * Use an absolute path to override the base path of the client, or a + * relative path to append to the base path of the client. The URL can + * contain the query string as well. Use an array to provide a URL + * template and additional variables to use in the URL template expansion. + * + * @param string|UriInterface $uri URI object or string. + * @param array $options Request options to apply. + */ + public function getAsync($uri, array $options = []): PromiseInterface + { + return $this->requestAsync('GET', $uri, $options); + } + + /** + * Create and send an asynchronous HTTP HEAD request. + * + * Use an absolute path to override the base path of the client, or a + * relative path to append to the base path of the client. The URL can + * contain the query string as well. Use an array to provide a URL + * template and additional variables to use in the URL template expansion. + * + * @param string|UriInterface $uri URI object or string. + * @param array $options Request options to apply. + */ + public function headAsync($uri, array $options = []): PromiseInterface + { + return $this->requestAsync('HEAD', $uri, $options); + } + + /** + * Create and send an asynchronous HTTP PUT request. + * + * Use an absolute path to override the base path of the client, or a + * relative path to append to the base path of the client. The URL can + * contain the query string as well. Use an array to provide a URL + * template and additional variables to use in the URL template expansion. + * + * @param string|UriInterface $uri URI object or string. + * @param array $options Request options to apply. + */ + public function putAsync($uri, array $options = []): PromiseInterface + { + return $this->requestAsync('PUT', $uri, $options); + } + + /** + * Create and send an asynchronous HTTP POST request. + * + * Use an absolute path to override the base path of the client, or a + * relative path to append to the base path of the client. The URL can + * contain the query string as well. Use an array to provide a URL + * template and additional variables to use in the URL template expansion. + * + * @param string|UriInterface $uri URI object or string. + * @param array $options Request options to apply. + */ + public function postAsync($uri, array $options = []): PromiseInterface + { + return $this->requestAsync('POST', $uri, $options); + } + + /** + * Create and send an asynchronous HTTP PATCH request. + * + * Use an absolute path to override the base path of the client, or a + * relative path to append to the base path of the client. The URL can + * contain the query string as well. Use an array to provide a URL + * template and additional variables to use in the URL template expansion. + * + * @param string|UriInterface $uri URI object or string. + * @param array $options Request options to apply. + */ + public function patchAsync($uri, array $options = []): PromiseInterface + { + return $this->requestAsync('PATCH', $uri, $options); + } + + /** + * Create and send an asynchronous HTTP DELETE request. + * + * Use an absolute path to override the base path of the client, or a + * relative path to append to the base path of the client. The URL can + * contain the query string as well. Use an array to provide a URL + * template and additional variables to use in the URL template expansion. + * + * @param string|UriInterface $uri URI object or string. + * @param array $options Request options to apply. + */ + public function deleteAsync($uri, array $options = []): PromiseInterface + { + return $this->requestAsync('DELETE', $uri, $options); + } +} diff --git a/vendor/guzzlehttp/guzzle/src/Cookie/CookieJar.php b/vendor/guzzlehttp/guzzle/src/Cookie/CookieJar.php index 38f98ad7c..d6757c654 100644 --- a/vendor/guzzlehttp/guzzle/src/Cookie/CookieJar.php +++ b/vendor/guzzlehttp/guzzle/src/Cookie/CookieJar.php @@ -1,4 +1,5 @@ strictMode = $strictMode; @@ -39,10 +44,8 @@ class CookieJar implements CookieJarInterface * * @param array $cookies Cookies to create the jar from * @param string $domain Domain to set the cookies to - * - * @return self */ - public static function fromArray(array $cookies, $domain) + public static function fromArray(array $cookies, string $domain): self { $cookieJar = new self(); foreach ($cookies as $name => $value) { @@ -57,26 +60,15 @@ class CookieJar implements CookieJarInterface return $cookieJar; } - /** - * @deprecated - */ - public static function getCookieValue($value) - { - return $value; - } - /** * Evaluate if this cookie should be persisted to storage * that survives between requests. * - * @param SetCookie $cookie Being evaluated. - * @param bool $allowSessionCookies If we should persist session cookies - * @return bool + * @param SetCookie $cookie Being evaluated. + * @param bool $allowSessionCookies If we should persist session cookies */ - public static function shouldPersist( - SetCookie $cookie, - $allowSessionCookies = false - ) { + public static function shouldPersist(SetCookie $cookie, bool $allowSessionCookies = false): bool + { if ($cookie->getExpires() || $allowSessionCookies) { if (!$cookie->getDiscard()) { return true; @@ -90,16 +82,13 @@ class CookieJar implements CookieJarInterface * Finds and returns the cookie based on the name * * @param string $name cookie name to search for + * * @return SetCookie|null cookie that was found or null if not found */ - public function getCookieByName($name) + public function getCookieByName(string $name): ?SetCookie { - // don't allow a non string name - if ($name === null || !is_scalar($name)) { - return null; - } foreach ($this->cookies as $cookie) { - if ($cookie->getName() !== null && strcasecmp($cookie->getName(), $name) === 0) { + if ($cookie->getName() !== null && \strcasecmp($cookie->getName(), $name) === 0) { return $cookie; } } @@ -107,37 +96,43 @@ class CookieJar implements CookieJarInterface return null; } - public function toArray() + /** + * @inheritDoc + */ + public function toArray(): array { - return array_map(function (SetCookie $cookie) { + return \array_map(static function (SetCookie $cookie): array { return $cookie->toArray(); }, $this->getIterator()->getArrayCopy()); } - public function clear($domain = null, $path = null, $name = null) + /** + * @inheritDoc + */ + public function clear(?string $domain = null, ?string $path = null, ?string $name = null): void { if (!$domain) { $this->cookies = []; return; } elseif (!$path) { - $this->cookies = array_filter( + $this->cookies = \array_filter( $this->cookies, - function (SetCookie $cookie) use ($domain) { + static function (SetCookie $cookie) use ($domain): bool { return !$cookie->matchesDomain($domain); } ); } elseif (!$name) { - $this->cookies = array_filter( + $this->cookies = \array_filter( $this->cookies, - function (SetCookie $cookie) use ($path, $domain) { + static function (SetCookie $cookie) use ($path, $domain): bool { return !($cookie->matchesPath($path) && $cookie->matchesDomain($domain)); } ); } else { - $this->cookies = array_filter( + $this->cookies = \array_filter( $this->cookies, - function (SetCookie $cookie) use ($path, $domain, $name) { + static function (SetCookie $cookie) use ($path, $domain, $name) { return !($cookie->getName() == $name && $cookie->matchesPath($path) && $cookie->matchesDomain($domain)); @@ -146,17 +141,23 @@ class CookieJar implements CookieJarInterface } } - public function clearSessionCookies() + /** + * @inheritDoc + */ + public function clearSessionCookies(): void { - $this->cookies = array_filter( + $this->cookies = \array_filter( $this->cookies, - function (SetCookie $cookie) { + static function (SetCookie $cookie): bool { return !$cookie->getDiscard() && $cookie->getExpires(); } ); } - public function setCookie(SetCookie $cookie) + /** + * @inheritDoc + */ + public function setCookie(SetCookie $cookie): bool { // If the name string is empty (but not 0), ignore the set-cookie // string entirely. @@ -170,10 +171,9 @@ class CookieJar implements CookieJarInterface if ($result !== true) { if ($this->strictMode) { throw new \RuntimeException('Invalid cookie: ' . $result); - } else { - $this->removeCookieIfEmpty($cookie); - return false; } + $this->removeCookieIfEmpty($cookie); + return false; } // Resolve conflicts with previously set cookies @@ -217,27 +217,28 @@ class CookieJar implements CookieJarInterface return true; } - public function count() + public function count(): int { - return count($this->cookies); + return \count($this->cookies); } - public function getIterator() + /** + * @return \ArrayIterator + */ + public function getIterator(): \ArrayIterator { - return new \ArrayIterator(array_values($this->cookies)); + return new \ArrayIterator(\array_values($this->cookies)); } - public function extractCookies( - RequestInterface $request, - ResponseInterface $response - ) { + public function extractCookies(RequestInterface $request, ResponseInterface $response): void + { if ($cookieHeader = $response->getHeader('Set-Cookie')) { foreach ($cookieHeader as $cookie) { $sc = SetCookie::fromString($cookie); if (!$sc->getDomain()) { $sc->setDomain($request->getUri()->getHost()); } - if (0 !== strpos($sc->getPath(), '/')) { + if (0 !== \strpos($sc->getPath(), '/')) { $sc->setPath($this->getCookiePathFromRequest($request)); } $this->setCookie($sc); @@ -249,30 +250,28 @@ class CookieJar implements CookieJarInterface * Computes cookie path following RFC 6265 section 5.1.4 * * @link https://tools.ietf.org/html/rfc6265#section-5.1.4 - * - * @param RequestInterface $request - * @return string */ - private function getCookiePathFromRequest(RequestInterface $request) + private function getCookiePathFromRequest(RequestInterface $request): string { $uriPath = $request->getUri()->getPath(); - if ('' === $uriPath) { + if ('' === $uriPath) { return '/'; } - if (0 !== strpos($uriPath, '/')) { + if (0 !== \strpos($uriPath, '/')) { return '/'; } if ('/' === $uriPath) { return '/'; } - if (0 === $lastSlashPos = strrpos($uriPath, '/')) { + $lastSlashPos = \strrpos($uriPath, '/'); + if (0 === $lastSlashPos || false === $lastSlashPos) { return '/'; } - return substr($uriPath, 0, $lastSlashPos); + return \substr($uriPath, 0, $lastSlashPos); } - public function withCookieHeader(RequestInterface $request) + public function withCookieHeader(RequestInterface $request): RequestInterface { $values = []; $uri = $request->getUri(); @@ -292,17 +291,15 @@ class CookieJar implements CookieJarInterface } return $values - ? $request->withHeader('Cookie', implode('; ', $values)) + ? $request->withHeader('Cookie', \implode('; ', $values)) : $request; } /** * If a cookie already exists and the server asks to set it again with a * null value, the cookie must be deleted. - * - * @param SetCookie $cookie */ - private function removeCookieIfEmpty(SetCookie $cookie) + private function removeCookieIfEmpty(SetCookie $cookie): void { $cookieValue = $cookie->getValue(); if ($cookieValue === null || $cookieValue === '') { diff --git a/vendor/guzzlehttp/guzzle/src/Cookie/CookieJarInterface.php b/vendor/guzzlehttp/guzzle/src/Cookie/CookieJarInterface.php index 6ee11885e..7df374b5b 100644 --- a/vendor/guzzlehttp/guzzle/src/Cookie/CookieJarInterface.php +++ b/vendor/guzzlehttp/guzzle/src/Cookie/CookieJarInterface.php @@ -1,4 +1,5 @@ */ interface CookieJarInterface extends \Countable, \IteratorAggregate { @@ -26,7 +28,7 @@ interface CookieJarInterface extends \Countable, \IteratorAggregate * * @return RequestInterface returns the modified request. */ - public function withCookieHeader(RequestInterface $request); + public function withCookieHeader(RequestInterface $request): RequestInterface; /** * Extract cookies from an HTTP response and store them in the CookieJar. @@ -34,10 +36,7 @@ interface CookieJarInterface extends \Countable, \IteratorAggregate * @param RequestInterface $request Request that was sent * @param ResponseInterface $response Response that was received */ - public function extractCookies( - RequestInterface $request, - ResponseInterface $response - ); + public function extractCookies(RequestInterface $request, ResponseInterface $response): void; /** * Sets a cookie in the cookie jar. @@ -46,7 +45,7 @@ interface CookieJarInterface extends \Countable, \IteratorAggregate * * @return bool Returns true on success or false on failure */ - public function setCookie(SetCookie $cookie); + public function setCookie(SetCookie $cookie): bool; /** * Remove cookies currently held in the cookie jar. @@ -61,10 +60,8 @@ interface CookieJarInterface extends \Countable, \IteratorAggregate * @param string|null $domain Clears cookies matching a domain * @param string|null $path Clears cookies matching a domain and path * @param string|null $name Clears cookies matching a domain, path, and name - * - * @return CookieJarInterface */ - public function clear($domain = null, $path = null, $name = null); + public function clear(?string $domain = null, ?string $path = null, ?string $name = null): void; /** * Discard all sessions cookies. @@ -73,12 +70,10 @@ interface CookieJarInterface extends \Countable, \IteratorAggregate * field set to true. To be called when the user agent shuts down according * to RFC 2965. */ - public function clearSessionCookies(); + public function clearSessionCookies(): void; /** * Converts the cookie jar to an array. - * - * @return array */ - public function toArray(); + public function toArray(): array; } diff --git a/vendor/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php b/vendor/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php index 3fb8600ef..290236d54 100644 --- a/vendor/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php +++ b/vendor/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php @@ -1,33 +1,40 @@ filename = $cookieFile; $this->storeSessionCookies = $storeSessionCookies; - if (file_exists($cookieFile)) { + if (\file_exists($cookieFile)) { $this->load($cookieFile); } } @@ -44,20 +51,21 @@ class FileCookieJar extends CookieJar * Saves the cookies to a file. * * @param string $filename File to save + * * @throws \RuntimeException if the file cannot be found or created */ - public function save($filename) + public function save(string $filename): void { $json = []; + /** @var SetCookie $cookie */ foreach ($this as $cookie) { - /** @var SetCookie $cookie */ if (CookieJar::shouldPersist($cookie, $this->storeSessionCookies)) { $json[] = $cookie->toArray(); } } - $jsonStr = \GuzzleHttp\json_encode($json); - if (false === file_put_contents($filename, $jsonStr, LOCK_EX)) { + $jsonStr = Utils::jsonEncode($json); + if (false === \file_put_contents($filename, $jsonStr, \LOCK_EX)) { throw new \RuntimeException("Unable to save file {$filename}"); } } @@ -68,23 +76,25 @@ class FileCookieJar extends CookieJar * Old cookies are kept unless overwritten by newly loaded ones. * * @param string $filename Cookie file to load. + * * @throws \RuntimeException if the file cannot be loaded. */ - public function load($filename) + public function load(string $filename): void { - $json = file_get_contents($filename); + $json = \file_get_contents($filename); if (false === $json) { throw new \RuntimeException("Unable to load file {$filename}"); - } elseif ($json === '') { + } + if ($json === '') { return; } - $data = \GuzzleHttp\json_decode($json, true); - if (is_array($data)) { - foreach (json_decode($json, true) as $cookie) { + $data = Utils::jsonDecode($json, true); + if (\is_array($data)) { + foreach ($data as $cookie) { $this->setCookie(new SetCookie($cookie)); } - } elseif (strlen($data)) { + } elseif (\is_scalar($data) && !empty($data)) { throw new \RuntimeException("Invalid cookie file: {$filename}"); } } diff --git a/vendor/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php b/vendor/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php index 0224a2447..5d51ca982 100644 --- a/vendor/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php +++ b/vendor/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php @@ -1,4 +1,5 @@ sessionKey = $sessionKey; @@ -39,33 +44,33 @@ class SessionCookieJar extends CookieJar /** * Save cookies to the client session */ - public function save() + public function save(): void { $json = []; + /** @var SetCookie $cookie */ foreach ($this as $cookie) { - /** @var SetCookie $cookie */ if (CookieJar::shouldPersist($cookie, $this->storeSessionCookies)) { $json[] = $cookie->toArray(); } } - $_SESSION[$this->sessionKey] = json_encode($json); + $_SESSION[$this->sessionKey] = \json_encode($json); } /** * Load the contents of the client session into the data array */ - protected function load() + protected function load(): void { if (!isset($_SESSION[$this->sessionKey])) { return; } - $data = json_decode($_SESSION[$this->sessionKey], true); - if (is_array($data)) { + $data = \json_decode($_SESSION[$this->sessionKey], true); + if (\is_array($data)) { foreach ($data as $cookie) { $this->setCookie(new SetCookie($cookie)); } - } elseif (strlen($data)) { + } elseif (\strlen($data)) { throw new \RuntimeException("Invalid cookie data"); } } diff --git a/vendor/guzzlehttp/guzzle/src/Cookie/SetCookie.php b/vendor/guzzlehttp/guzzle/src/Cookie/SetCookie.php index 3d776a70b..602370d6f 100644 --- a/vendor/guzzlehttp/guzzle/src/Cookie/SetCookie.php +++ b/vendor/guzzlehttp/guzzle/src/Cookie/SetCookie.php @@ -1,4 +1,5 @@ null, 'Value' => null, @@ -19,42 +22,42 @@ class SetCookie 'HttpOnly' => false ]; - /** @var array Cookie data */ + /** + * @var array Cookie data + */ private $data; /** - * Create a new SetCookie object from a string + * Create a new SetCookie object from a string. * * @param string $cookie Set-Cookie header string - * - * @return self */ - public static function fromString($cookie) + public static function fromString(string $cookie): self { // Create the default return array $data = self::$defaults; // Explode the cookie string using a series of semicolons - $pieces = array_filter(array_map('trim', explode(';', $cookie))); + $pieces = \array_filter(\array_map('trim', \explode(';', $cookie))); // The name of the cookie (first kvp) must exist and include an equal sign. - if (empty($pieces[0]) || !strpos($pieces[0], '=')) { + if (!isset($pieces[0]) || \strpos($pieces[0], '=') === false) { return new self($data); } // Add the cookie pieces into the parsed data array foreach ($pieces as $part) { - $cookieParts = explode('=', $part, 2); - $key = trim($cookieParts[0]); + $cookieParts = \explode('=', $part, 2); + $key = \trim($cookieParts[0]); $value = isset($cookieParts[1]) - ? trim($cookieParts[1], " \n\r\t\0\x0B") + ? \trim($cookieParts[1], " \n\r\t\0\x0B") : true; // Only check for non-cookies when cookies have been found - if (empty($data['Name'])) { + if (!isset($data['Name'])) { $data['Name'] = $key; $data['Value'] = $value; } else { - foreach (array_keys(self::$defaults) as $search) { - if (!strcasecmp($search, $key)) { + foreach (\array_keys(self::$defaults) as $search) { + if (!\strcasecmp($search, $key)) { $data[$search] = $value; continue 2; } @@ -71,13 +74,19 @@ class SetCookie */ public function __construct(array $data = []) { - $this->data = array_replace(self::$defaults, $data); + /** @var array|null $replaced will be null in case of replace error */ + $replaced = \array_replace(self::$defaults, $data); + if ($replaced === null) { + throw new \InvalidArgumentException('Unable to replace the default values for the Cookie.'); + } + + $this->data = $replaced; // Extract the Expires value and turn it into a UNIX timestamp if needed if (!$this->getExpires() && $this->getMaxAge()) { // Calculate the Expires date - $this->setExpires(time() + $this->getMaxAge()); - } elseif ($this->getExpires() && !is_numeric($this->getExpires())) { - $this->setExpires($this->getExpires()); + $this->setExpires(\time() + $this->getMaxAge()); + } elseif (null !== ($expires = $this->getExpires()) && !\is_numeric($expires)) { + $this->setExpires($expires); } } @@ -87,23 +96,23 @@ class SetCookie foreach ($this->data as $k => $v) { if ($k !== 'Name' && $k !== 'Value' && $v !== null && $v !== false) { if ($k === 'Expires') { - $str .= 'Expires=' . gmdate('D, d M Y H:i:s \G\M\T', $v) . '; '; + $str .= 'Expires=' . \gmdate('D, d M Y H:i:s \G\M\T', $v) . '; '; } else { $str .= ($v === true ? $k : "{$k}={$v}") . '; '; } } } - return rtrim($str, '; '); + return \rtrim($str, '; '); } - public function toArray() + public function toArray(): array { return $this->data; } /** - * Get the cookie name + * Get the cookie name. * * @return string */ @@ -113,19 +122,19 @@ class SetCookie } /** - * Set the cookie name + * Set the cookie name. * * @param string $name Cookie name */ - public function setName($name) + public function setName($name): void { $this->data['Name'] = $name; } /** - * Get the cookie value + * Get the cookie value. * - * @return string + * @return string|null */ public function getValue() { @@ -133,17 +142,17 @@ class SetCookie } /** - * Set the cookie value + * Set the cookie value. * * @param string $value Cookie value */ - public function setValue($value) + public function setValue($value): void { $this->data['Value'] = $value; } /** - * Get the domain + * Get the domain. * * @return string|null */ @@ -153,17 +162,17 @@ class SetCookie } /** - * Set the domain of the cookie + * Set the domain of the cookie. * * @param string $domain */ - public function setDomain($domain) + public function setDomain($domain): void { $this->data['Domain'] = $domain; } /** - * Get the path + * Get the path. * * @return string */ @@ -173,17 +182,17 @@ class SetCookie } /** - * Set the path of the cookie + * Set the path of the cookie. * * @param string $path Path of the cookie */ - public function setPath($path) + public function setPath($path): void { $this->data['Path'] = $path; } /** - * Maximum lifetime of the cookie in seconds + * Maximum lifetime of the cookie in seconds. * * @return int|null */ @@ -193,19 +202,19 @@ class SetCookie } /** - * Set the max-age of the cookie + * Set the max-age of the cookie. * * @param int $maxAge Max age of the cookie in seconds */ - public function setMaxAge($maxAge) + public function setMaxAge($maxAge): void { $this->data['Max-Age'] = $maxAge; } /** - * The UNIX timestamp when the cookie Expires + * The UNIX timestamp when the cookie Expires. * - * @return mixed + * @return string|int|null */ public function getExpires() { @@ -213,19 +222,19 @@ class SetCookie } /** - * Set the unix timestamp for which the cookie will expire + * Set the unix timestamp for which the cookie will expire. * - * @param int $timestamp Unix timestamp + * @param int|string $timestamp Unix timestamp or any English textual datetime description. */ - public function setExpires($timestamp) + public function setExpires($timestamp): void { - $this->data['Expires'] = is_numeric($timestamp) + $this->data['Expires'] = \is_numeric($timestamp) ? (int) $timestamp - : strtotime($timestamp); + : \strtotime($timestamp); } /** - * Get whether or not this is a secure cookie + * Get whether or not this is a secure cookie. * * @return bool|null */ @@ -235,17 +244,17 @@ class SetCookie } /** - * Set whether or not the cookie is secure + * Set whether or not the cookie is secure. * * @param bool $secure Set to true or false if secure */ - public function setSecure($secure) + public function setSecure($secure): void { $this->data['Secure'] = $secure; } /** - * Get whether or not this is a session cookie + * Get whether or not this is a session cookie. * * @return bool|null */ @@ -255,17 +264,17 @@ class SetCookie } /** - * Set whether or not this is a session cookie + * Set whether or not this is a session cookie. * * @param bool $discard Set to true or false if this is a session cookie */ - public function setDiscard($discard) + public function setDiscard($discard): void { $this->data['Discard'] = $discard; } /** - * Get whether or not this is an HTTP only cookie + * Get whether or not this is an HTTP only cookie. * * @return bool */ @@ -275,11 +284,11 @@ class SetCookie } /** - * Set whether or not this is an HTTP only cookie + * Set whether or not this is an HTTP only cookie. * * @param bool $httpOnly Set to true or false if this is HTTP only */ - public function setHttpOnly($httpOnly) + public function setHttpOnly($httpOnly): void { $this->data['HttpOnly'] = $httpOnly; } @@ -298,10 +307,8 @@ class SetCookie * path is a %x2F ("/") character. * * @param string $requestPath Path to check against - * - * @return bool */ - public function matchesPath($requestPath) + public function matchesPath(string $requestPath): bool { $cookiePath = $this->getPath(); @@ -311,71 +318,71 @@ class SetCookie } // Ensure that the cookie-path is a prefix of the request path. - if (0 !== strpos($requestPath, $cookiePath)) { + if (0 !== \strpos($requestPath, $cookiePath)) { return false; } // Match if the last character of the cookie-path is "/" - if (substr($cookiePath, -1, 1) === '/') { + if (\substr($cookiePath, -1, 1) === '/') { return true; } // Match if the first character not included in cookie path is "/" - return substr($requestPath, strlen($cookiePath), 1) === '/'; + return \substr($requestPath, \strlen($cookiePath), 1) === '/'; } /** - * Check if the cookie matches a domain value + * Check if the cookie matches a domain value. * * @param string $domain Domain to check against - * - * @return bool */ - public function matchesDomain($domain) + public function matchesDomain(string $domain): bool { + $cookieDomain = $this->getDomain(); + if (null === $cookieDomain) { + return true; + } + // Remove the leading '.' as per spec in RFC 6265. - // http://tools.ietf.org/html/rfc6265#section-5.2.3 - $cookieDomain = ltrim($this->getDomain(), '.'); + // https://tools.ietf.org/html/rfc6265#section-5.2.3 + $cookieDomain = \ltrim($cookieDomain, '.'); // Domain not set or exact match. - if (!$cookieDomain || !strcasecmp($domain, $cookieDomain)) { + if (!$cookieDomain || !\strcasecmp($domain, $cookieDomain)) { return true; } // Matching the subdomain according to RFC 6265. - // http://tools.ietf.org/html/rfc6265#section-5.1.3 - if (filter_var($domain, FILTER_VALIDATE_IP)) { + // https://tools.ietf.org/html/rfc6265#section-5.1.3 + if (\filter_var($domain, \FILTER_VALIDATE_IP)) { return false; } - return (bool) preg_match('/\.' . preg_quote($cookieDomain, '/') . '$/', $domain); + return (bool) \preg_match('/\.' . \preg_quote($cookieDomain, '/') . '$/', $domain); } /** - * Check if the cookie is expired - * - * @return bool + * Check if the cookie is expired. */ - public function isExpired() + public function isExpired(): bool { - return $this->getExpires() !== null && time() > $this->getExpires(); + return $this->getExpires() !== null && \time() > $this->getExpires(); } /** - * Check if the cookie is valid according to RFC 6265 + * Check if the cookie is valid according to RFC 6265. * * @return bool|string Returns true if valid or an error message if invalid */ public function validate() { - // Names must not be empty, but can be 0 $name = $this->getName(); - if (empty($name) && !is_numeric($name)) { + if ($name === '') { return 'The cookie name must not be empty'; } // Check if any of the invalid characters are present in the cookie name - if (preg_match( + if (\preg_match( '/[\x00-\x20\x22\x28-\x29\x2c\x2f\x3a-\x40\x5c\x7b\x7d\x7f]/', $name )) { @@ -384,17 +391,17 @@ class SetCookie . 'following characters: ()<>@,;:\"/?={}'; } - // Value must not be empty, but can be 0 + // Value must not be null. 0 and empty string are valid. Empty strings + // are technically against RFC 6265, but known to happen in the wild. $value = $this->getValue(); - if (empty($value) && !is_numeric($value)) { + if ($value === null) { return 'The cookie value must not be empty'; } - // Domains must not be empty, but can be 0 - // A "0" is not a valid internet domain, but may be used as server name - // in a private network. + // Domains must not be empty, but can be 0. "0" is not a valid internet + // domain, but may be used as server name in a private network. $domain = $this->getDomain(); - if (empty($domain) && !is_numeric($domain)) { + if ($domain === null || $domain === '') { return 'The cookie domain must not be empty'; } diff --git a/vendor/guzzlehttp/guzzle/src/Exception/BadResponseException.php b/vendor/guzzlehttp/guzzle/src/Exception/BadResponseException.php index 427d896fb..a80956c9d 100644 --- a/vendor/guzzlehttp/guzzle/src/Exception/BadResponseException.php +++ b/vendor/guzzlehttp/guzzle/src/Exception/BadResponseException.php @@ -1,4 +1,5 @@ request = $request; + $this->handlerContext = $handlerContext; } /** - * @return null + * Get the request that caused the exception */ - public function getResponse() + public function getRequest(): RequestInterface { - return null; + return $this->request; } /** - * @return bool + * Get contextual information about the error from the underlying handler. + * + * The contents of this array will vary depending on which handler you are + * using. It may also be just an empty array. Relying on this data will + * couple you to a specific handler, but can give more debug information + * when needed. */ - public function hasResponse() + public function getHandlerContext(): array { - return false; + return $this->handlerContext; } } diff --git a/vendor/guzzlehttp/guzzle/src/Exception/GuzzleException.php b/vendor/guzzlehttp/guzzle/src/Exception/GuzzleException.php index 27b2722b0..fa3ed6998 100644 --- a/vendor/guzzlehttp/guzzle/src/Exception/GuzzleException.php +++ b/vendor/guzzlehttp/guzzle/src/Exception/GuzzleException.php @@ -1,23 +1,9 @@ getStatusCode() - : 0; + $code = $response ? $response->getStatusCode() : 0; parent::__construct($message, $code, $previous); $this->request = $request; $this->response = $response; @@ -39,46 +46,39 @@ class RequestException extends TransferException /** * Wrap non-RequestExceptions with a RequestException - * - * @param RequestInterface $request - * @param \Exception $e - * - * @return RequestException */ - public static function wrapException(RequestInterface $request, \Exception $e) + public static function wrapException(RequestInterface $request, \Throwable $e): RequestException { - return $e instanceof RequestException - ? $e - : new RequestException($e->getMessage(), $request, null, $e); + return $e instanceof RequestException ? $e : new RequestException($e->getMessage(), $request, null, $e); } /** * Factory method to create a new exception with a normalized error message * - * @param RequestInterface $request Request - * @param ResponseInterface $response Response received - * @param \Exception $previous Previous exception - * @param array $ctx Optional handler context. - * - * @return self + * @param RequestInterface $request Request sent + * @param ResponseInterface $response Response received + * @param \Throwable|null $previous Previous exception + * @param array $handlerContext Optional handler context + * @param BodySummarizerInterface|null $bodySummarizer Optional body summarizer */ public static function create( RequestInterface $request, ResponseInterface $response = null, - \Exception $previous = null, - array $ctx = [] - ) { + \Throwable $previous = null, + array $handlerContext = [], + BodySummarizerInterface $bodySummarizer = null + ): self { if (!$response) { return new self( 'Error completing request', $request, null, $previous, - $ctx + $handlerContext ); } - $level = (int) floor($response->getStatusCode() / 100); + $level = (int) \floor($response->getStatusCode() / 100); if ($level === 4) { $label = 'Client error'; $className = ClientException::class; @@ -95,7 +95,7 @@ class RequestException extends TransferException // Client Error: `GET /` resulted in a `404 Not Found` response: // ... (truncated) - $message = sprintf( + $message = \sprintf( '%s: `%s %s` resulted in a `%s %s` response', $label, $request->getMethod(), @@ -104,42 +104,24 @@ class RequestException extends TransferException $response->getReasonPhrase() ); - $summary = static::getResponseBodySummary($response); + $summary = ($bodySummarizer ?? new BodySummarizer())->summarize($response); if ($summary !== null) { $message .= ":\n{$summary}\n"; } - return new $className($message, $request, $response, $previous, $ctx); - } - - /** - * Get a short summary of the response - * - * Will return `null` if the response is not printable. - * - * @param ResponseInterface $response - * - * @return string|null - */ - public static function getResponseBodySummary(ResponseInterface $response) - { - return \GuzzleHttp\Psr7\get_message_body_summary($response); + return new $className($message, $request, $response, $previous, $handlerContext); } /** * Obfuscates URI if there is a username and a password present - * - * @param UriInterface $uri - * - * @return UriInterface */ - private static function obfuscateUri(UriInterface $uri) + private static function obfuscateUri(UriInterface $uri): UriInterface { $userInfo = $uri->getUserInfo(); - if (false !== ($pos = strpos($userInfo, ':'))) { - return $uri->withUserInfo(substr($userInfo, 0, $pos), '***'); + if (false !== ($pos = \strpos($userInfo, ':'))) { + return $uri->withUserInfo(\substr($userInfo, 0, $pos), '***'); } return $uri; @@ -147,30 +129,24 @@ class RequestException extends TransferException /** * Get the request that caused the exception - * - * @return RequestInterface */ - public function getRequest() + public function getRequest(): RequestInterface { return $this->request; } /** * Get the associated response - * - * @return ResponseInterface|null */ - public function getResponse() + public function getResponse(): ?ResponseInterface { return $this->response; } /** * Check if a response was received - * - * @return bool */ - public function hasResponse() + public function hasResponse(): bool { return $this->response !== null; } @@ -182,10 +158,8 @@ class RequestException extends TransferException * using. It may also be just an empty array. Relying on this data will * couple you to a specific handler, but can give more debug information * when needed. - * - * @return array */ - public function getHandlerContext() + public function getHandlerContext(): array { return $this->handlerContext; } diff --git a/vendor/guzzlehttp/guzzle/src/Exception/SeekException.php b/vendor/guzzlehttp/guzzle/src/Exception/SeekException.php deleted file mode 100644 index a77c28926..000000000 --- a/vendor/guzzlehttp/guzzle/src/Exception/SeekException.php +++ /dev/null @@ -1,27 +0,0 @@ -stream = $stream; - $msg = $msg ?: 'Could not seek the stream to position ' . $pos; - parent::__construct($msg); - } - - /** - * @return StreamInterface - */ - public function getStream() - { - return $this->stream; - } -} diff --git a/vendor/guzzlehttp/guzzle/src/Exception/ServerException.php b/vendor/guzzlehttp/guzzle/src/Exception/ServerException.php index 127094c14..8055e067c 100644 --- a/vendor/guzzlehttp/guzzle/src/Exception/ServerException.php +++ b/vendor/guzzlehttp/guzzle/src/Exception/ServerException.php @@ -1,4 +1,5 @@ maxHandles = $maxHandles; } - public function create(RequestInterface $request, array $options) + public function create(RequestInterface $request, array $options): EasyHandle { if (isset($options['curl']['body_as_string'])) { $options['_body_as_string'] = $options['curl']['body_as_string']; @@ -49,35 +62,33 @@ class CurlFactory implements CurlFactoryInterface // Add handler options from the request configuration options if (isset($options['curl'])) { - $conf = array_replace($conf, $options['curl']); + $conf = \array_replace($conf, $options['curl']); } - $conf[CURLOPT_HEADERFUNCTION] = $this->createHeaderFn($easy); - $easy->handle = $this->handles - ? array_pop($this->handles) - : curl_init(); + $conf[\CURLOPT_HEADERFUNCTION] = $this->createHeaderFn($easy); + $easy->handle = $this->handles ? \array_pop($this->handles) : \curl_init(); curl_setopt_array($easy->handle, $conf); return $easy; } - public function release(EasyHandle $easy) + public function release(EasyHandle $easy): void { $resource = $easy->handle; unset($easy->handle); - if (count($this->handles) >= $this->maxHandles) { - curl_close($resource); + if (\count($this->handles) >= $this->maxHandles) { + \curl_close($resource); } else { // Remove all callback functions as they can hold onto references // and are not cleaned up by curl_reset. Using curl_setopt_array // does not work for some reason, so removing each one // individually. - curl_setopt($resource, CURLOPT_HEADERFUNCTION, null); - curl_setopt($resource, CURLOPT_READFUNCTION, null); - curl_setopt($resource, CURLOPT_WRITEFUNCTION, null); - curl_setopt($resource, CURLOPT_PROGRESSFUNCTION, null); - curl_reset($resource); + \curl_setopt($resource, \CURLOPT_HEADERFUNCTION, null); + \curl_setopt($resource, \CURLOPT_READFUNCTION, null); + \curl_setopt($resource, \CURLOPT_WRITEFUNCTION, null); + \curl_setopt($resource, \CURLOPT_PROGRESSFUNCTION, null); + \curl_reset($resource); $this->handles[] = $resource; } } @@ -86,17 +97,11 @@ class CurlFactory implements CurlFactoryInterface * Completes a cURL transaction, either returning a response promise or a * rejected promise. * - * @param callable $handler - * @param EasyHandle $easy - * @param CurlFactoryInterface $factory Dictates how the handle is released - * - * @return \GuzzleHttp\Promise\PromiseInterface + * @param callable(RequestInterface, array): PromiseInterface $handler + * @param CurlFactoryInterface $factory Dictates how the handle is released */ - public static function finish( - callable $handler, - EasyHandle $easy, - CurlFactoryInterface $factory - ) { + public static function finish(callable $handler, EasyHandle $easy, CurlFactoryInterface $factory): PromiseInterface + { if (isset($easy->options['on_stats'])) { self::invokeStats($easy); } @@ -117,10 +122,10 @@ class CurlFactory implements CurlFactoryInterface return new FulfilledPromise($easy->response); } - private static function invokeStats(EasyHandle $easy) + private static function invokeStats(EasyHandle $easy): void { - $curlStats = curl_getinfo($easy->handle); - $curlStats['appconnect_time'] = curl_getinfo($easy->handle, CURLINFO_APPCONNECT_TIME); + $curlStats = \curl_getinfo($easy->handle); + $curlStats['appconnect_time'] = \curl_getinfo($easy->handle, \CURLINFO_APPCONNECT_TIME); $stats = new TransferStats( $easy->request, $easy->response, @@ -128,47 +133,57 @@ class CurlFactory implements CurlFactoryInterface $easy->errno, $curlStats ); - call_user_func($easy->options['on_stats'], $stats); + ($easy->options['on_stats'])($stats); } - private static function finishError( - callable $handler, - EasyHandle $easy, - CurlFactoryInterface $factory - ) { + /** + * @param callable(RequestInterface, array): PromiseInterface $handler + */ + private static function finishError(callable $handler, EasyHandle $easy, CurlFactoryInterface $factory): PromiseInterface + { // Get error information and release the handle to the factory. $ctx = [ 'errno' => $easy->errno, - 'error' => curl_error($easy->handle), - 'appconnect_time' => curl_getinfo($easy->handle, CURLINFO_APPCONNECT_TIME), - ] + curl_getinfo($easy->handle); - $ctx[self::CURL_VERSION_STR] = curl_version()['version']; + 'error' => \curl_error($easy->handle), + 'appconnect_time' => \curl_getinfo($easy->handle, \CURLINFO_APPCONNECT_TIME), + ] + \curl_getinfo($easy->handle); + $ctx[self::CURL_VERSION_STR] = \curl_version()['version']; $factory->release($easy); // Retry when nothing is present or when curl failed to rewind. - if (empty($easy->options['_err_message']) - && (!$easy->errno || $easy->errno == 65) - ) { + if (empty($easy->options['_err_message']) && (!$easy->errno || $easy->errno == 65)) { return self::retryFailedRewind($handler, $easy, $ctx); } return self::createRejection($easy, $ctx); } - private static function createRejection(EasyHandle $easy, array $ctx) + private static function createRejection(EasyHandle $easy, array $ctx): PromiseInterface { static $connectionErrors = [ - CURLE_OPERATION_TIMEOUTED => true, - CURLE_COULDNT_RESOLVE_HOST => true, - CURLE_COULDNT_CONNECT => true, - CURLE_SSL_CONNECT_ERROR => true, - CURLE_GOT_NOTHING => true, + \CURLE_OPERATION_TIMEOUTED => true, + \CURLE_COULDNT_RESOLVE_HOST => true, + \CURLE_COULDNT_CONNECT => true, + \CURLE_SSL_CONNECT_ERROR => true, + \CURLE_GOT_NOTHING => true, ]; + if ($easy->createResponseException) { + return P\Create::rejectionFor( + new RequestException( + 'An error was encountered while creating the response', + $easy->request, + $easy->response, + $easy->createResponseException, + $ctx + ) + ); + } + // If an exception was encountered during the onHeaders event, then // return a rejected promise that wraps that exception. if ($easy->onHeadersException) { - return \GuzzleHttp\Promise\rejection_for( + return P\Create::rejectionFor( new RequestException( 'An error was encountered during the on_headers event', $easy->request, @@ -178,21 +193,16 @@ class CurlFactory implements CurlFactoryInterface ) ); } - if (version_compare($ctx[self::CURL_VERSION_STR], self::LOW_CURL_VERSION_NUMBER)) { - $message = sprintf( - 'cURL error %s: %s (%s)', - $ctx['errno'], - $ctx['error'], - 'see https://curl.haxx.se/libcurl/c/libcurl-errors.html' - ); - } else { - $message = sprintf( - 'cURL error %s: %s (%s) for %s', - $ctx['errno'], - $ctx['error'], - 'see https://curl.haxx.se/libcurl/c/libcurl-errors.html', - $easy->request->getUri() - ); + + $message = \sprintf( + 'cURL error %s: %s (%s)', + $ctx['errno'], + $ctx['error'], + 'see https://curl.haxx.se/libcurl/c/libcurl-errors.html' + ); + $uriString = (string) $easy->request->getUri(); + if ($uriString !== '' && false === \strpos($ctx['error'], $uriString)) { + $message .= \sprintf(' for %s', $uriString); } // Create a connection exception if it was a specific error code. @@ -200,37 +210,40 @@ class CurlFactory implements CurlFactoryInterface ? new ConnectException($message, $easy->request, null, $ctx) : new RequestException($message, $easy->request, $easy->response, null, $ctx); - return \GuzzleHttp\Promise\rejection_for($error); + return P\Create::rejectionFor($error); } - private function getDefaultConf(EasyHandle $easy) + /** + * @return array + */ + private function getDefaultConf(EasyHandle $easy): array { $conf = [ - '_headers' => $easy->request->getHeaders(), - CURLOPT_CUSTOMREQUEST => $easy->request->getMethod(), - CURLOPT_URL => (string) $easy->request->getUri()->withFragment(''), - CURLOPT_RETURNTRANSFER => false, - CURLOPT_HEADER => false, - CURLOPT_CONNECTTIMEOUT => 150, + '_headers' => $easy->request->getHeaders(), + \CURLOPT_CUSTOMREQUEST => $easy->request->getMethod(), + \CURLOPT_URL => (string) $easy->request->getUri()->withFragment(''), + \CURLOPT_RETURNTRANSFER => false, + \CURLOPT_HEADER => false, + \CURLOPT_CONNECTTIMEOUT => 150, ]; - if (defined('CURLOPT_PROTOCOLS')) { - $conf[CURLOPT_PROTOCOLS] = CURLPROTO_HTTP | CURLPROTO_HTTPS; + if (\defined('CURLOPT_PROTOCOLS')) { + $conf[\CURLOPT_PROTOCOLS] = \CURLPROTO_HTTP | \CURLPROTO_HTTPS; } $version = $easy->request->getProtocolVersion(); if ($version == 1.1) { - $conf[CURLOPT_HTTP_VERSION] = CURL_HTTP_VERSION_1_1; + $conf[\CURLOPT_HTTP_VERSION] = \CURL_HTTP_VERSION_1_1; } elseif ($version == 2.0) { - $conf[CURLOPT_HTTP_VERSION] = CURL_HTTP_VERSION_2_0; + $conf[\CURLOPT_HTTP_VERSION] = \CURL_HTTP_VERSION_2_0; } else { - $conf[CURLOPT_HTTP_VERSION] = CURL_HTTP_VERSION_1_0; + $conf[\CURLOPT_HTTP_VERSION] = \CURL_HTTP_VERSION_1_0; } return $conf; } - private function applyMethod(EasyHandle $easy, array &$conf) + private function applyMethod(EasyHandle $easy, array &$conf): void { $body = $easy->request->getBody(); $size = $body->getSize(); @@ -242,22 +255,22 @@ class CurlFactory implements CurlFactoryInterface $method = $easy->request->getMethod(); if ($method === 'PUT' || $method === 'POST') { - // See http://tools.ietf.org/html/rfc7230#section-3.3.2 + // See https://tools.ietf.org/html/rfc7230#section-3.3.2 if (!$easy->request->hasHeader('Content-Length')) { - $conf[CURLOPT_HTTPHEADER][] = 'Content-Length: 0'; + $conf[\CURLOPT_HTTPHEADER][] = 'Content-Length: 0'; } } elseif ($method === 'HEAD') { - $conf[CURLOPT_NOBODY] = true; + $conf[\CURLOPT_NOBODY] = true; unset( - $conf[CURLOPT_WRITEFUNCTION], - $conf[CURLOPT_READFUNCTION], - $conf[CURLOPT_FILE], - $conf[CURLOPT_INFILE] + $conf[\CURLOPT_WRITEFUNCTION], + $conf[\CURLOPT_READFUNCTION], + $conf[\CURLOPT_FILE], + $conf[\CURLOPT_INFILE] ); } } - private function applyBody(RequestInterface $request, array $options, array &$conf) + private function applyBody(RequestInterface $request, array $options, array &$conf): void { $size = $request->hasHeader('Content-Length') ? (int) $request->getHeaderLine('Content-Length') @@ -265,40 +278,38 @@ class CurlFactory implements CurlFactoryInterface // Send the body as a string if the size is less than 1MB OR if the // [curl][body_as_string] request value is set. - if (($size !== null && $size < 1000000) || - !empty($options['_body_as_string']) - ) { - $conf[CURLOPT_POSTFIELDS] = (string) $request->getBody(); + if (($size !== null && $size < 1000000) || !empty($options['_body_as_string'])) { + $conf[\CURLOPT_POSTFIELDS] = (string) $request->getBody(); // Don't duplicate the Content-Length header $this->removeHeader('Content-Length', $conf); $this->removeHeader('Transfer-Encoding', $conf); } else { - $conf[CURLOPT_UPLOAD] = true; + $conf[\CURLOPT_UPLOAD] = true; if ($size !== null) { - $conf[CURLOPT_INFILESIZE] = $size; + $conf[\CURLOPT_INFILESIZE] = $size; $this->removeHeader('Content-Length', $conf); } $body = $request->getBody(); if ($body->isSeekable()) { $body->rewind(); } - $conf[CURLOPT_READFUNCTION] = function ($ch, $fd, $length) use ($body) { + $conf[\CURLOPT_READFUNCTION] = static function ($ch, $fd, $length) use ($body) { return $body->read($length); }; } // If the Expect header is not present, prevent curl from adding it if (!$request->hasHeader('Expect')) { - $conf[CURLOPT_HTTPHEADER][] = 'Expect:'; + $conf[\CURLOPT_HTTPHEADER][] = 'Expect:'; } // cURL sometimes adds a content-type by default. Prevent this. if (!$request->hasHeader('Content-Type')) { - $conf[CURLOPT_HTTPHEADER][] = 'Content-Type:'; + $conf[\CURLOPT_HTTPHEADER][] = 'Content-Type:'; } } - private function applyHeaders(EasyHandle $easy, array &$conf) + private function applyHeaders(EasyHandle $easy, array &$conf): void { foreach ($conf['_headers'] as $name => $values) { foreach ($values as $value) { @@ -306,16 +317,16 @@ class CurlFactory implements CurlFactoryInterface if ($value === '') { // cURL requires a special format for empty headers. // See https://github.com/guzzle/guzzle/issues/1882 for more details. - $conf[CURLOPT_HTTPHEADER][] = "$name;"; + $conf[\CURLOPT_HTTPHEADER][] = "$name;"; } else { - $conf[CURLOPT_HTTPHEADER][] = "$name: $value"; + $conf[\CURLOPT_HTTPHEADER][] = "$name: $value"; } } } // Remove the Accept header if one was not set if (!$easy->request->hasHeader('Accept')) { - $conf[CURLOPT_HTTPHEADER][] = 'Accept:'; + $conf[\CURLOPT_HTTPHEADER][] = 'Accept:'; } } @@ -325,115 +336,112 @@ class CurlFactory implements CurlFactoryInterface * @param string $name Case-insensitive header to remove * @param array $options Array of options to modify */ - private function removeHeader($name, array &$options) + private function removeHeader(string $name, array &$options): void { - foreach (array_keys($options['_headers']) as $key) { - if (!strcasecmp($key, $name)) { + foreach (\array_keys($options['_headers']) as $key) { + if (!\strcasecmp($key, $name)) { unset($options['_headers'][$key]); return; } } } - private function applyHandlerOptions(EasyHandle $easy, array &$conf) + private function applyHandlerOptions(EasyHandle $easy, array &$conf): void { $options = $easy->options; if (isset($options['verify'])) { if ($options['verify'] === false) { - unset($conf[CURLOPT_CAINFO]); - $conf[CURLOPT_SSL_VERIFYHOST] = 0; - $conf[CURLOPT_SSL_VERIFYPEER] = false; + unset($conf[\CURLOPT_CAINFO]); + $conf[\CURLOPT_SSL_VERIFYHOST] = 0; + $conf[\CURLOPT_SSL_VERIFYPEER] = false; } else { - $conf[CURLOPT_SSL_VERIFYHOST] = 2; - $conf[CURLOPT_SSL_VERIFYPEER] = true; - if (is_string($options['verify'])) { + $conf[\CURLOPT_SSL_VERIFYHOST] = 2; + $conf[\CURLOPT_SSL_VERIFYPEER] = true; + if (\is_string($options['verify'])) { // Throw an error if the file/folder/link path is not valid or doesn't exist. - if (!file_exists($options['verify'])) { - throw new \InvalidArgumentException( - "SSL CA bundle not found: {$options['verify']}" - ); + if (!\file_exists($options['verify'])) { + throw new \InvalidArgumentException("SSL CA bundle not found: {$options['verify']}"); } // If it's a directory or a link to a directory use CURLOPT_CAPATH. // If not, it's probably a file, or a link to a file, so use CURLOPT_CAINFO. - if (is_dir($options['verify']) || - (is_link($options['verify']) && is_dir(readlink($options['verify'])))) { - $conf[CURLOPT_CAPATH] = $options['verify']; + if ( + \is_dir($options['verify']) || + ( + \is_link($options['verify']) === true && + ($verifyLink = \readlink($options['verify'])) !== false && + \is_dir($verifyLink) + ) + ) { + $conf[\CURLOPT_CAPATH] = $options['verify']; } else { - $conf[CURLOPT_CAINFO] = $options['verify']; + $conf[\CURLOPT_CAINFO] = $options['verify']; } } } } - if (!empty($options['decode_content'])) { + if (!isset($options['curl'][\CURLOPT_ENCODING]) && !empty($options['decode_content'])) { $accept = $easy->request->getHeaderLine('Accept-Encoding'); if ($accept) { - $conf[CURLOPT_ENCODING] = $accept; + $conf[\CURLOPT_ENCODING] = $accept; } else { - $conf[CURLOPT_ENCODING] = ''; + $conf[\CURLOPT_ENCODING] = ''; // Don't let curl send the header over the wire - $conf[CURLOPT_HTTPHEADER][] = 'Accept-Encoding:'; + $conf[\CURLOPT_HTTPHEADER][] = 'Accept-Encoding:'; } } - if (isset($options['sink'])) { - $sink = $options['sink']; - if (!is_string($sink)) { - $sink = \GuzzleHttp\Psr7\stream_for($sink); - } elseif (!is_dir(dirname($sink))) { - // Ensure that the directory exists before failing in curl. - throw new \RuntimeException(sprintf( - 'Directory %s does not exist for sink value of %s', - dirname($sink), - $sink - )); - } else { - $sink = new LazyOpenStream($sink, 'w+'); - } - $easy->sink = $sink; - $conf[CURLOPT_WRITEFUNCTION] = function ($ch, $write) use ($sink) { - return $sink->write($write); - }; - } else { + if (!isset($options['sink'])) { // Use a default temp stream if no sink was set. - $conf[CURLOPT_FILE] = fopen('php://temp', 'w+'); - $easy->sink = Psr7\stream_for($conf[CURLOPT_FILE]); + $options['sink'] = \GuzzleHttp\Psr7\Utils::tryFopen('php://temp', 'w+'); } + $sink = $options['sink']; + if (!\is_string($sink)) { + $sink = \GuzzleHttp\Psr7\Utils::streamFor($sink); + } elseif (!\is_dir(\dirname($sink))) { + // Ensure that the directory exists before failing in curl. + throw new \RuntimeException(\sprintf('Directory %s does not exist for sink value of %s', \dirname($sink), $sink)); + } else { + $sink = new LazyOpenStream($sink, 'w+'); + } + $easy->sink = $sink; + $conf[\CURLOPT_WRITEFUNCTION] = static function ($ch, $write) use ($sink): int { + return $sink->write($write); + }; + $timeoutRequiresNoSignal = false; if (isset($options['timeout'])) { $timeoutRequiresNoSignal |= $options['timeout'] < 1; - $conf[CURLOPT_TIMEOUT_MS] = $options['timeout'] * 1000; + $conf[\CURLOPT_TIMEOUT_MS] = $options['timeout'] * 1000; } // CURL default value is CURL_IPRESOLVE_WHATEVER if (isset($options['force_ip_resolve'])) { if ('v4' === $options['force_ip_resolve']) { - $conf[CURLOPT_IPRESOLVE] = CURL_IPRESOLVE_V4; + $conf[\CURLOPT_IPRESOLVE] = \CURL_IPRESOLVE_V4; } elseif ('v6' === $options['force_ip_resolve']) { - $conf[CURLOPT_IPRESOLVE] = CURL_IPRESOLVE_V6; + $conf[\CURLOPT_IPRESOLVE] = \CURL_IPRESOLVE_V6; } } if (isset($options['connect_timeout'])) { $timeoutRequiresNoSignal |= $options['connect_timeout'] < 1; - $conf[CURLOPT_CONNECTTIMEOUT_MS] = $options['connect_timeout'] * 1000; + $conf[\CURLOPT_CONNECTTIMEOUT_MS] = $options['connect_timeout'] * 1000; } - if ($timeoutRequiresNoSignal && strtoupper(substr(PHP_OS, 0, 3)) !== 'WIN') { - $conf[CURLOPT_NOSIGNAL] = true; + if ($timeoutRequiresNoSignal && \strtoupper(\substr(\PHP_OS, 0, 3)) !== 'WIN') { + $conf[\CURLOPT_NOSIGNAL] = true; } if (isset($options['proxy'])) { - if (!is_array($options['proxy'])) { - $conf[CURLOPT_PROXY] = $options['proxy']; + if (!\is_array($options['proxy'])) { + $conf[\CURLOPT_PROXY] = $options['proxy']; } else { $scheme = $easy->request->getUri()->getScheme(); if (isset($options['proxy'][$scheme])) { $host = $easy->request->getUri()->getHost(); - if (!isset($options['proxy']['no']) || - !\GuzzleHttp\is_host_in_noproxy($host, $options['proxy']['no']) - ) { - $conf[CURLOPT_PROXY] = $options['proxy'][$scheme]; + if (!isset($options['proxy']['no']) || !Utils::isHostInNoProxy($host, $options['proxy']['no'])) { + $conf[\CURLOPT_PROXY] = $options['proxy'][$scheme]; } } } @@ -441,58 +449,53 @@ class CurlFactory implements CurlFactoryInterface if (isset($options['cert'])) { $cert = $options['cert']; - if (is_array($cert)) { - $conf[CURLOPT_SSLCERTPASSWD] = $cert[1]; + if (\is_array($cert)) { + $conf[\CURLOPT_SSLCERTPASSWD] = $cert[1]; $cert = $cert[0]; } - if (!file_exists($cert)) { - throw new \InvalidArgumentException( - "SSL certificate not found: {$cert}" - ); + if (!\file_exists($cert)) { + throw new \InvalidArgumentException("SSL certificate not found: {$cert}"); } - $conf[CURLOPT_SSLCERT] = $cert; + # OpenSSL (versions 0.9.3 and later) also support "P12" for PKCS#12-encoded files. + # see https://curl.se/libcurl/c/CURLOPT_SSLCERTTYPE.html + $ext = pathinfo($cert, \PATHINFO_EXTENSION); + if (preg_match('#^(der|p12)$#i', $ext)) { + $conf[\CURLOPT_SSLCERTTYPE] = strtoupper($ext); + } + $conf[\CURLOPT_SSLCERT] = $cert; } if (isset($options['ssl_key'])) { - if (is_array($options['ssl_key'])) { - if (count($options['ssl_key']) === 2) { - list($sslKey, $conf[CURLOPT_SSLKEYPASSWD]) = $options['ssl_key']; + if (\is_array($options['ssl_key'])) { + if (\count($options['ssl_key']) === 2) { + [$sslKey, $conf[\CURLOPT_SSLKEYPASSWD]] = $options['ssl_key']; } else { - list($sslKey) = $options['ssl_key']; + [$sslKey] = $options['ssl_key']; } } - $sslKey = isset($sslKey) ? $sslKey: $options['ssl_key']; + $sslKey = $sslKey ?? $options['ssl_key']; - if (!file_exists($sslKey)) { - throw new \InvalidArgumentException( - "SSL private key not found: {$sslKey}" - ); + if (!\file_exists($sslKey)) { + throw new \InvalidArgumentException("SSL private key not found: {$sslKey}"); } - $conf[CURLOPT_SSLKEY] = $sslKey; + $conf[\CURLOPT_SSLKEY] = $sslKey; } if (isset($options['progress'])) { $progress = $options['progress']; - if (!is_callable($progress)) { - throw new \InvalidArgumentException( - 'progress client option must be callable' - ); + if (!\is_callable($progress)) { + throw new \InvalidArgumentException('progress client option must be callable'); } - $conf[CURLOPT_NOPROGRESS] = false; - $conf[CURLOPT_PROGRESSFUNCTION] = function () use ($progress) { - $args = func_get_args(); - // PHP 5.5 pushed the handle onto the start of the args - if (is_resource($args[0])) { - array_shift($args); - } - call_user_func_array($progress, $args); + $conf[\CURLOPT_NOPROGRESS] = false; + $conf[\CURLOPT_PROGRESSFUNCTION] = static function ($resource, int $downloadSize, int $downloaded, int $uploadSize, int $uploaded) use ($progress) { + $progress($downloadSize, $downloaded, $uploadSize, $uploaded); }; } if (!empty($options['debug'])) { - $conf[CURLOPT_STDERR] = \GuzzleHttp\debug_resource($options['debug']); - $conf[CURLOPT_VERBOSE] = true; + $conf[\CURLOPT_STDERR] = Utils::debugResource($options['debug']); + $conf[\CURLOPT_VERBOSE] = true; } } @@ -504,12 +507,11 @@ class CurlFactory implements CurlFactoryInterface * stream, and then encountered a "necessary data rewind wasn't possible" * error, causing the request to be sent through curl_multi_info_read() * without an error status. + * + * @param callable(RequestInterface, array): PromiseInterface $handler */ - private static function retryFailedRewind( - callable $handler, - EasyHandle $easy, - array $ctx - ) { + private static function retryFailedRewind(callable $handler, EasyHandle $easy, array $ctx): PromiseInterface + { try { // Only rewind if the body has been read from. $body = $easy->request->getBody(); @@ -542,27 +544,32 @@ class CurlFactory implements CurlFactoryInterface return $handler($easy->request, $easy->options); } - private function createHeaderFn(EasyHandle $easy) + private function createHeaderFn(EasyHandle $easy): callable { if (isset($easy->options['on_headers'])) { $onHeaders = $easy->options['on_headers']; - if (!is_callable($onHeaders)) { + if (!\is_callable($onHeaders)) { throw new \InvalidArgumentException('on_headers must be callable'); } } else { $onHeaders = null; } - return function ($ch, $h) use ( + return static function ($ch, $h) use ( $onHeaders, $easy, &$startingResponse ) { - $value = trim($h); + $value = \trim($h); if ($value === '') { $startingResponse = true; - $easy->createResponse(); + try { + $easy->createResponse(); + } catch (\Exception $e) { + $easy->createResponseException = $e; + return -1; + } if ($onHeaders !== null) { try { $onHeaders($easy->response); @@ -579,7 +586,7 @@ class CurlFactory implements CurlFactoryInterface } else { $easy->headers[] = $value; } - return strlen($h); + return \strlen($h); }; } } diff --git a/vendor/guzzlehttp/guzzle/src/Handler/CurlFactoryInterface.php b/vendor/guzzlehttp/guzzle/src/Handler/CurlFactoryInterface.php index b0fc23685..fe57ed5d5 100644 --- a/vendor/guzzlehttp/guzzle/src/Handler/CurlFactoryInterface.php +++ b/vendor/guzzlehttp/guzzle/src/Handler/CurlFactoryInterface.php @@ -1,4 +1,5 @@ factory = isset($options['handle_factory']) - ? $options['handle_factory'] - : new CurlFactory(3); + $this->factory = $options['handle_factory'] + ?? new CurlFactory(3); } - public function __invoke(RequestInterface $request, array $options) + public function __invoke(RequestInterface $request, array $options): PromiseInterface { if (isset($options['delay'])) { - usleep($options['delay'] * 1000); + \usleep($options['delay'] * 1000); } $easy = $this->factory->create($request, $options); - curl_exec($easy->handle); - $easy->errno = curl_errno($easy->handle); + \curl_exec($easy->handle); + $easy->errno = \curl_errno($easy->handle); return CurlFactory::finish($this, $easy, $this->factory); } diff --git a/vendor/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php b/vendor/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php index 564c95f48..4e312631c 100644 --- a/vendor/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php +++ b/vendor/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php @@ -1,8 +1,10 @@ An array of delay times, indexed by handle id in `addRequest`. + * + * @see CurlMultiHandler::addRequest + */ private $delays = []; + + /** + * @var array An associative array of CURLMOPT_* options and corresponding values for curl_multi_setopt() + */ private $options = []; /** @@ -33,52 +63,62 @@ class CurlMultiHandler * out while selecting curl handles. Defaults to 1 second. * - options: An associative array of CURLMOPT_* options and * corresponding values for curl_multi_setopt() - * - * @param array $options */ public function __construct(array $options = []) { - $this->factory = isset($options['handle_factory']) - ? $options['handle_factory'] : new CurlFactory(50); + $this->factory = $options['handle_factory'] ?? new CurlFactory(50); if (isset($options['select_timeout'])) { $this->selectTimeout = $options['select_timeout']; - } elseif ($selectTimeout = getenv('GUZZLE_CURL_SELECT_TIMEOUT')) { - $this->selectTimeout = $selectTimeout; + } elseif ($selectTimeout = Utils::getenv('GUZZLE_CURL_SELECT_TIMEOUT')) { + @trigger_error('Since guzzlehttp/guzzle 7.2.0: Using environment variable GUZZLE_CURL_SELECT_TIMEOUT is deprecated. Use option "select_timeout" instead.', \E_USER_DEPRECATED); + $this->selectTimeout = (int) $selectTimeout; } else { $this->selectTimeout = 1; } - $this->options = isset($options['options']) ? $options['options'] : []; + $this->options = $options['options'] ?? []; } + /** + * @param string $name + * + * @return resource|\CurlMultiHandle + * + * @throws \BadMethodCallException when another field as `_mh` will be gotten + * @throws \RuntimeException when curl can not initialize a multi handle + */ public function __get($name) { - if ($name === '_mh') { - $this->_mh = curl_multi_init(); - - foreach ($this->options as $option => $value) { - // A warning is raised in case of a wrong option. - curl_multi_setopt($this->_mh, $option, $value); - } - - // Further calls to _mh will return the value directly, without entering the - // __get() method at all. - return $this->_mh; + if ($name !== '_mh') { + throw new \BadMethodCallException("Can not get other property as '_mh'."); } - throw new \BadMethodCallException(); + $multiHandle = \curl_multi_init(); + + if (false === $multiHandle) { + throw new \RuntimeException('Can not initialize curl multi handle.'); + } + + $this->_mh = $multiHandle; + + foreach ($this->options as $option => $value) { + // A warning is raised in case of a wrong option. + curl_multi_setopt($this->_mh, $option, $value); + } + + return $this->_mh; } public function __destruct() { if (isset($this->_mh)) { - curl_multi_close($this->_mh); + \curl_multi_close($this->_mh); unset($this->_mh); } } - public function __invoke(RequestInterface $request, array $options) + public function __invoke(RequestInterface $request, array $options): PromiseInterface { $easy = $this->factory->create($request, $options); $id = (int) $easy->handle; @@ -98,7 +138,7 @@ class CurlMultiHandler /** * Ticks the curl event loop. */ - public function tick() + public function tick(): void { // Add any delayed handles if needed. if ($this->delays) { @@ -106,7 +146,7 @@ class CurlMultiHandler foreach ($this->delays as $id => $delay) { if ($currentTime >= $delay) { unset($this->delays[$id]); - curl_multi_add_handle( + \curl_multi_add_handle( $this->_mh, $this->handles[$id]['easy']->handle ); @@ -115,17 +155,15 @@ class CurlMultiHandler } // Step through the task queue which may add additional requests. - P\queue()->run(); + P\Utils::queue()->run(); - if ($this->active && - curl_multi_select($this->_mh, $this->selectTimeout) === -1 - ) { + if ($this->active && \curl_multi_select($this->_mh, $this->selectTimeout) === -1) { // Perform a usleep if a select returns -1. // See: https://bugs.php.net/bug.php?id=61141 - usleep(250); + \usleep(250); } - while (curl_multi_exec($this->_mh, $this->active) === CURLM_CALL_MULTI_PERFORM); + while (\curl_multi_exec($this->_mh, $this->active) === \CURLM_CALL_MULTI_PERFORM); $this->processMessages(); } @@ -133,26 +171,26 @@ class CurlMultiHandler /** * Runs until all outstanding connections have completed. */ - public function execute() + public function execute(): void { - $queue = P\queue(); + $queue = P\Utils::queue(); while ($this->handles || !$queue->isEmpty()) { // If there are no transfers, then sleep for the next delay if (!$this->active && $this->delays) { - usleep($this->timeToNext()); + \usleep($this->timeToNext()); } $this->tick(); } } - private function addRequest(array $entry) + private function addRequest(array $entry): void { $easy = $entry['easy']; $id = (int) $easy->handle; $this->handles[$id] = $entry; if (empty($easy->options['delay'])) { - curl_multi_add_handle($this->_mh, $easy->handle); + \curl_multi_add_handle($this->_mh, $easy->handle); } else { $this->delays[$id] = Utils::currentTime() + ($easy->options['delay'] / 1000); } @@ -165,7 +203,7 @@ class CurlMultiHandler * * @return bool True on success, false on failure. */ - private function cancel($id) + private function cancel($id): bool { // Cannot cancel if it has been processed. if (!isset($this->handles[$id])) { @@ -174,17 +212,17 @@ class CurlMultiHandler $handle = $this->handles[$id]['easy']->handle; unset($this->delays[$id], $this->handles[$id]); - curl_multi_remove_handle($this->_mh, $handle); - curl_close($handle); + \curl_multi_remove_handle($this->_mh, $handle); + \curl_close($handle); return true; } - private function processMessages() + private function processMessages(): void { - while ($done = curl_multi_info_read($this->_mh)) { + while ($done = \curl_multi_info_read($this->_mh)) { $id = (int) $done['handle']; - curl_multi_remove_handle($this->_mh, $done['handle']); + \curl_multi_remove_handle($this->_mh, $done['handle']); if (!isset($this->handles[$id])) { // Probably was cancelled. @@ -195,25 +233,21 @@ class CurlMultiHandler unset($this->handles[$id], $this->delays[$id]); $entry['easy']->errno = $done['result']; $entry['deferred']->resolve( - CurlFactory::finish( - $this, - $entry['easy'], - $this->factory - ) + CurlFactory::finish($this, $entry['easy'], $this->factory) ); } } - private function timeToNext() + private function timeToNext(): int { $currentTime = Utils::currentTime(); - $nextTime = PHP_INT_MAX; + $nextTime = \PHP_INT_MAX; foreach ($this->delays as $time) { if ($time < $nextTime) { $nextTime = $time; } } - return max(0, $nextTime - $currentTime) * 1000000; + return ((int) \max(0, $nextTime - $currentTime)) * 1000000; } } diff --git a/vendor/guzzlehttp/guzzle/src/Handler/EasyHandle.php b/vendor/guzzlehttp/guzzle/src/Handler/EasyHandle.php index 7754e9111..224344d7c 100644 --- a/vendor/guzzlehttp/guzzle/src/Handler/EasyHandle.php +++ b/vendor/guzzlehttp/guzzle/src/Handler/EasyHandle.php @@ -1,7 +1,9 @@ headers)) { - throw new \RuntimeException('No headers have been received'); - } + [$ver, $status, $reason, $headers] = HeaderProcessor::parseHeaders($this->headers); - // HTTP-version SP status-code SP reason-phrase - $startLine = explode(' ', array_shift($this->headers), 3); - $headers = \GuzzleHttp\headers_from_lines($this->headers); - $normalizedKeys = \GuzzleHttp\normalize_header_keys($headers); + $normalizedKeys = Utils::normalizeHeaderKeys($headers); - if (!empty($this->options['decode_content']) - && isset($normalizedKeys['content-encoding']) - ) { - $headers['x-encoded-content-encoding'] - = $headers[$normalizedKeys['content-encoding']]; + if (!empty($this->options['decode_content']) && isset($normalizedKeys['content-encoding'])) { + $headers['x-encoded-content-encoding'] = $headers[$normalizedKeys['content-encoding']]; unset($headers[$normalizedKeys['content-encoding']]); if (isset($normalizedKeys['content-length'])) { - $headers['x-encoded-content-length'] - = $headers[$normalizedKeys['content-length']]; + $headers['x-encoded-content-length'] = $headers[$normalizedKeys['content-length']]; $bodyLength = (int) $this->sink->getSize(); if ($bodyLength) { @@ -74,19 +89,24 @@ final class EasyHandle // Attach a response to the easy handle with the parsed headers. $this->response = new Response( - $startLine[1], + $status, $headers, $this->sink, - substr($startLine[0], 5), - isset($startLine[2]) ? (string) $startLine[2] : null + $ver, + $reason ); } + /** + * @param string $name + * + * @return void + * + * @throws \BadMethodCallException + */ public function __get($name) { - $msg = $name === 'handle' - ? 'The EasyHandle has been released' - : 'Invalid property: ' . $name; + $msg = $name === 'handle' ? 'The EasyHandle has been released' : 'Invalid property: ' . $name; throw new \BadMethodCallException($msg); } } diff --git a/vendor/guzzlehttp/guzzle/src/Handler/HeaderProcessor.php b/vendor/guzzlehttp/guzzle/src/Handler/HeaderProcessor.php new file mode 100644 index 000000000..a0988845f --- /dev/null +++ b/vendor/guzzlehttp/guzzle/src/Handler/HeaderProcessor.php @@ -0,0 +1,42 @@ +|null $queue The parameters to be passed to the append function, as an indexed array. + * @param callable|null $onFulfilled Callback to invoke when the return value is fulfilled. + * @param callable|null $onRejected Callback to invoke when the return value is rejected. */ - public function __construct( - array $queue = null, - callable $onFulfilled = null, - callable $onRejected = null - ) { + public function __construct(array $queue = null, callable $onFulfilled = null, callable $onRejected = null) + { $this->onFulfilled = $onFulfilled; $this->onRejected = $onRejected; if ($queue) { - call_user_func_array([$this, 'append'], $queue); + // array_values included for BC + $this->append(...array_values($queue)); } } - public function __invoke(RequestInterface $request, array $options) + public function __invoke(RequestInterface $request, array $options): PromiseInterface { if (!$this->queue) { throw new \OutOfBoundsException('Mock queue is empty'); } - if (isset($options['delay']) && is_numeric($options['delay'])) { - usleep($options['delay'] * 1000); + if (isset($options['delay']) && \is_numeric($options['delay'])) { + \usleep((int) $options['delay'] * 1000); } $this->lastRequest = $request; $this->lastOptions = $options; - $response = array_shift($this->queue); + $response = \array_shift($this->queue); if (isset($options['on_headers'])) { - if (!is_callable($options['on_headers'])) { + if (!\is_callable($options['on_headers'])) { throw new \InvalidArgumentException('on_headers must be callable'); } try { @@ -86,29 +103,30 @@ class MockHandler implements \Countable } } - if (is_callable($response)) { - $response = call_user_func($response, $request, $options); + if (\is_callable($response)) { + $response = $response($request, $options); } - $response = $response instanceof \Exception - ? \GuzzleHttp\Promise\rejection_for($response) - : \GuzzleHttp\Promise\promise_for($response); + $response = $response instanceof \Throwable + ? P\Create::rejectionFor($response) + : P\Create::promiseFor($response); return $response->then( - function ($value) use ($request, $options) { + function (?ResponseInterface $value) use ($request, $options) { $this->invokeStats($request, $options, $value); if ($this->onFulfilled) { - call_user_func($this->onFulfilled, $value); + ($this->onFulfilled)($value); } - if (isset($options['sink'])) { + + if ($value !== null && isset($options['sink'])) { $contents = (string) $value->getBody(); $sink = $options['sink']; - if (is_resource($sink)) { - fwrite($sink, $contents); - } elseif (is_string($sink)) { - file_put_contents($sink, $contents); - } elseif ($sink instanceof \Psr\Http\Message\StreamInterface) { + if (\is_resource($sink)) { + \fwrite($sink, $contents); + } elseif (\is_string($sink)) { + \file_put_contents($sink, $contents); + } elseif ($sink instanceof StreamInterface) { $sink->write($contents); } } @@ -118,9 +136,9 @@ class MockHandler implements \Countable function ($reason) use ($request, $options) { $this->invokeStats($request, $options, null, $reason); if ($this->onRejected) { - call_user_func($this->onRejected, $reason); + ($this->onRejected)($reason); } - return \GuzzleHttp\Promise\rejection_for($reason); + return P\Create::rejectionFor($reason); } ); } @@ -128,68 +146,66 @@ class MockHandler implements \Countable /** * Adds one or more variadic requests, exceptions, callables, or promises * to the queue. + * + * @param mixed ...$values */ - public function append() + public function append(...$values): void { - foreach (func_get_args() as $value) { + foreach ($values as $value) { if ($value instanceof ResponseInterface - || $value instanceof \Exception + || $value instanceof \Throwable || $value instanceof PromiseInterface - || is_callable($value) + || \is_callable($value) ) { $this->queue[] = $value; } else { - throw new \InvalidArgumentException('Expected a response or ' - . 'exception. Found ' . \GuzzleHttp\describe_type($value)); + throw new \TypeError('Expected a Response, Promise, Throwable or callable. Found ' . Utils::describeType($value)); } } } /** * Get the last received request. - * - * @return RequestInterface */ - public function getLastRequest() + public function getLastRequest(): ?RequestInterface { return $this->lastRequest; } /** * Get the last received request options. - * - * @return array */ - public function getLastOptions() + public function getLastOptions(): array { return $this->lastOptions; } /** * Returns the number of remaining items in the queue. - * - * @return int */ - public function count() + public function count(): int { - return count($this->queue); + return \count($this->queue); } - public function reset() + public function reset(): void { $this->queue = []; } + /** + * @param mixed $reason Promise or reason. + */ private function invokeStats( RequestInterface $request, array $options, ResponseInterface $response = null, $reason = null - ) { + ): void { if (isset($options['on_stats'])) { - $transferTime = isset($options['transfer_time']) ? $options['transfer_time'] : 0; + $transferTime = $options['transfer_time'] ?? 0; $stats = new TransferStats($request, $response, $transferTime, $reason); - call_user_func($options['on_stats'], $stats); + ($options['on_stats'])($stats); } } } diff --git a/vendor/guzzlehttp/guzzle/src/Handler/Proxy.php b/vendor/guzzlehttp/guzzle/src/Handler/Proxy.php index f8b00be0b..f045b526c 100644 --- a/vendor/guzzlehttp/guzzle/src/Handler/Proxy.php +++ b/vendor/guzzlehttp/guzzle/src/Handler/Proxy.php @@ -1,11 +1,15 @@ getMessage(); // This list can probably get more comprehensive. - if (strpos($message, 'getaddrinfo') // DNS lookup failed - || strpos($message, 'Connection refused') - || strpos($message, "couldn't connect to host") // error on HHVM - || strpos($message, "connection attempt failed") + if (false !== \strpos($message, 'getaddrinfo') // DNS lookup failed + || false !== \strpos($message, 'Connection refused') + || false !== \strpos($message, "couldn't connect to host") // error on HHVM + || false !== \strpos($message, "connection attempt failed") ) { $e = new ConnectException($e->getMessage(), $request, $e); + } else { + $e = RequestException::wrapException($request, $e); } - $e = RequestException::wrapException($request, $e); $this->invokeStats($options, $request, $startTime, null, $e); - return \GuzzleHttp\Promise\rejection_for($e); + return P\Create::rejectionFor($e); } } private function invokeStats( array $options, RequestInterface $request, - $startTime, + ?float $startTime, ResponseInterface $response = null, - $error = null - ) { + \Throwable $error = null + ): void { if (isset($options['on_stats'])) { - $stats = new TransferStats( - $request, - $response, - Utils::currentTime() - $startTime, - $error, - [] - ); - call_user_func($options['on_stats'], $stats); + $stats = new TransferStats($request, $response, Utils::currentTime() - $startTime, $error, []); + ($options['on_stats'])($stats); } } - private function createResponse( - RequestInterface $request, - array $options, - $stream, - $startTime - ) { + /** + * @param resource $stream + */ + private function createResponse(RequestInterface $request, array $options, $stream, ?float $startTime): PromiseInterface + { $hdrs = $this->lastHeaders; $this->lastHeaders = []; - $parts = explode(' ', array_shift($hdrs), 3); - $ver = explode('/', $parts[0])[1]; - $status = $parts[1]; - $reason = isset($parts[2]) ? $parts[2] : null; - $headers = \GuzzleHttp\headers_from_lines($hdrs); - list($stream, $headers) = $this->checkDecode($options, $headers, $stream); - $stream = Psr7\stream_for($stream); + + try { + [$ver, $status, $reason, $headers] = HeaderProcessor::parseHeaders($hdrs); + } catch (\Exception $e) { + return P\Create::rejectionFor( + new RequestException('An error was encountered while creating the response', $request, null, $e) + ); + } + + [$stream, $headers] = $this->checkDecode($options, $headers, $stream); + $stream = Psr7\Utils::streamFor($stream); $sink = $stream; - if (strcasecmp('HEAD', $request->getMethod())) { + if (\strcasecmp('HEAD', $request->getMethod())) { $sink = $this->createSink($stream, $options); } - $response = new Psr7\Response($status, $headers, $sink, $ver, $reason); + try { + $response = new Psr7\Response($status, $headers, $sink, $ver, $reason); + } catch (\Exception $e) { + return P\Create::rejectionFor( + new RequestException('An error was encountered while creating the response', $request, null, $e) + ); + } if (isset($options['on_headers'])) { try { $options['on_headers']($response); } catch (\Exception $e) { - $msg = 'An error was encountered during the on_headers event'; - $ex = new RequestException($msg, $request, $response, $e); - return \GuzzleHttp\Promise\rejection_for($ex); + return P\Create::rejectionFor( + new RequestException('An error was encountered during the on_headers event', $request, $response, $e) + ); } } // Do not drain when the request is a HEAD request because they have // no body. if ($sink !== $stream) { - $this->drain( - $stream, - $sink, - $response->getHeaderLine('Content-Length') - ); + $this->drain($stream, $sink, $response->getHeaderLine('Content-Length')); } $this->invokeStats($options, $request, $startTime, $response, null); @@ -139,41 +145,37 @@ class StreamHandler return new FulfilledPromise($response); } - private function createSink(StreamInterface $stream, array $options) + private function createSink(StreamInterface $stream, array $options): StreamInterface { if (!empty($options['stream'])) { return $stream; } - $sink = isset($options['sink']) - ? $options['sink'] - : fopen('php://temp', 'r+'); + $sink = $options['sink'] ?? Psr7\Utils::tryFopen('php://temp', 'r+'); - return is_string($sink) - ? new Psr7\LazyOpenStream($sink, 'w+') - : Psr7\stream_for($sink); + return \is_string($sink) ? new Psr7\LazyOpenStream($sink, 'w+') : Psr7\Utils::streamFor($sink); } - private function checkDecode(array $options, array $headers, $stream) + /** + * @param resource $stream + */ + private function checkDecode(array $options, array $headers, $stream): array { // Automatically decode responses when instructed. if (!empty($options['decode_content'])) { - $normalizedKeys = \GuzzleHttp\normalize_header_keys($headers); + $normalizedKeys = Utils::normalizeHeaderKeys($headers); if (isset($normalizedKeys['content-encoding'])) { $encoding = $headers[$normalizedKeys['content-encoding']]; if ($encoding[0] === 'gzip' || $encoding[0] === 'deflate') { - $stream = new Psr7\InflateStream( - Psr7\stream_for($stream) - ); - $headers['x-encoded-content-encoding'] - = $headers[$normalizedKeys['content-encoding']]; + $stream = new Psr7\InflateStream(Psr7\Utils::streamFor($stream)); + $headers['x-encoded-content-encoding'] = $headers[$normalizedKeys['content-encoding']]; + // Remove content-encoding header unset($headers[$normalizedKeys['content-encoding']]); + // Fix content-length header if (isset($normalizedKeys['content-length'])) { - $headers['x-encoded-content-length'] - = $headers[$normalizedKeys['content-length']]; - + $headers['x-encoded-content-length'] = $headers[$normalizedKeys['content-length']]; $length = (int) $stream->getSize(); if ($length === 0) { unset($headers[$normalizedKeys['content-length']]); @@ -191,27 +193,21 @@ class StreamHandler /** * Drains the source stream into the "sink" client option. * - * @param StreamInterface $source - * @param StreamInterface $sink - * @param string $contentLength Header specifying the amount of - * data to read. + * @param string $contentLength Header specifying the amount of + * data to read. * - * @return StreamInterface * @throws \RuntimeException when the sink option is invalid. */ - private function drain( - StreamInterface $source, - StreamInterface $sink, - $contentLength - ) { + private function drain(StreamInterface $source, StreamInterface $sink, string $contentLength): StreamInterface + { // If a content-length header is provided, then stop reading once // that number of bytes has been read. This can prevent infinitely // reading from a stream when dealing with servers that do not honor // Connection: Close headers. - Psr7\copy_to_stream( + Psr7\Utils::copyToStream( $source, $sink, - (strlen($contentLength) > 0 && (int) $contentLength > 0) ? (int) $contentLength : -1 + (\strlen($contentLength) > 0 && (int) $contentLength > 0) ? (int) $contentLength : -1 ); $sink->seek(0); @@ -226,12 +222,13 @@ class StreamHandler * @param callable $callback Callable that returns stream resource * * @return resource + * * @throws \RuntimeException on error */ private function createResource(callable $callback) { - $errors = null; - set_error_handler(function ($_, $msg, $file, $line) use (&$errors) { + $errors = []; + \set_error_handler(static function ($_, $msg, $file, $line) use (&$errors): bool { $errors[] = [ 'message' => $msg, 'file' => $file, @@ -241,26 +238,29 @@ class StreamHandler }); $resource = $callback(); - restore_error_handler(); + \restore_error_handler(); if (!$resource) { $message = 'Error creating resource: '; foreach ($errors as $err) { foreach ($err as $key => $value) { - $message .= "[$key] $value" . PHP_EOL; + $message .= "[$key] $value" . \PHP_EOL; } } - throw new \RuntimeException(trim($message)); + throw new \RuntimeException(\trim($message)); } return $resource; } + /** + * @return resource + */ private function createStream(RequestInterface $request, array $options) { static $methods; if (!$methods) { - $methods = array_flip(get_class_methods(__CLASS__)); + $methods = \array_flip(\get_class_methods(__CLASS__)); } // HTTP/1.1 streams using the PHP stream wrapper require a @@ -279,7 +279,7 @@ class StreamHandler $params = []; $context = $this->getDefaultContext($request); - if (isset($options['on_headers']) && !is_callable($options['on_headers'])) { + if (isset($options['on_headers']) && !\is_callable($options['on_headers'])) { throw new \InvalidArgumentException('on_headers must be callable'); } @@ -293,42 +293,39 @@ class StreamHandler } if (isset($options['stream_context'])) { - if (!is_array($options['stream_context'])) { + if (!\is_array($options['stream_context'])) { throw new \InvalidArgumentException('stream_context must be an array'); } - $context = array_replace_recursive( - $context, - $options['stream_context'] - ); + $context = \array_replace_recursive($context, $options['stream_context']); } // Microsoft NTLM authentication only supported with curl handler - if (isset($options['auth']) - && is_array($options['auth']) - && isset($options['auth'][2]) - && 'ntlm' == $options['auth'][2] - ) { + if (isset($options['auth'][2]) && 'ntlm' === $options['auth'][2]) { throw new \InvalidArgumentException('Microsoft NTLM authentication only supported with curl handler'); } $uri = $this->resolveHost($request, $options); - $context = $this->createResource( - function () use ($context, $params) { - return stream_context_create($context, $params); + $contextResource = $this->createResource( + static function () use ($context, $params) { + return \stream_context_create($context, $params); } ); return $this->createResource( - function () use ($uri, &$http_response_header, $context, $options) { - $resource = fopen((string) $uri, 'r', null, $context); + function () use ($uri, &$http_response_header, $contextResource, $context, $options, $request) { + $resource = @\fopen((string) $uri, 'r', false, $contextResource); $this->lastHeaders = $http_response_header; + if (false === $resource) { + throw new ConnectException(sprintf('Connection refused for URI %s', $uri), $request, null, $context); + } + if (isset($options['read_timeout'])) { $readTimeout = $options['read_timeout']; $sec = (int) $readTimeout; $usec = ($readTimeout - $sec) * 100000; - stream_set_timeout($resource, $sec, $usec); + \stream_set_timeout($resource, $sec, $usec); } return $resource; @@ -336,42 +333,31 @@ class StreamHandler ); } - private function resolveHost(RequestInterface $request, array $options) + private function resolveHost(RequestInterface $request, array $options): UriInterface { $uri = $request->getUri(); - if (isset($options['force_ip_resolve']) && !filter_var($uri->getHost(), FILTER_VALIDATE_IP)) { + if (isset($options['force_ip_resolve']) && !\filter_var($uri->getHost(), \FILTER_VALIDATE_IP)) { if ('v4' === $options['force_ip_resolve']) { - $records = dns_get_record($uri->getHost(), DNS_A); - if (!isset($records[0]['ip'])) { - throw new ConnectException( - sprintf( - "Could not resolve IPv4 address for host '%s'", - $uri->getHost() - ), - $request - ); + $records = \dns_get_record($uri->getHost(), \DNS_A); + if (false === $records || !isset($records[0]['ip'])) { + throw new ConnectException(\sprintf("Could not resolve IPv4 address for host '%s'", $uri->getHost()), $request); } - $uri = $uri->withHost($records[0]['ip']); - } elseif ('v6' === $options['force_ip_resolve']) { - $records = dns_get_record($uri->getHost(), DNS_AAAA); - if (!isset($records[0]['ipv6'])) { - throw new ConnectException( - sprintf( - "Could not resolve IPv6 address for host '%s'", - $uri->getHost() - ), - $request - ); + return $uri->withHost($records[0]['ip']); + } + if ('v6' === $options['force_ip_resolve']) { + $records = \dns_get_record($uri->getHost(), \DNS_AAAA); + if (false === $records || !isset($records[0]['ipv6'])) { + throw new ConnectException(\sprintf("Could not resolve IPv6 address for host '%s'", $uri->getHost()), $request); } - $uri = $uri->withHost('[' . $records[0]['ipv6'] . ']'); + return $uri->withHost('[' . $records[0]['ipv6'] . ']'); } } return $uri; } - private function getDefaultContext(RequestInterface $request) + private function getDefaultContext(RequestInterface $request): array { $headers = ''; foreach ($request->getHeaders() as $name => $value) { @@ -400,55 +386,100 @@ class StreamHandler } } - $context['http']['header'] = rtrim($context['http']['header']); + $context['http']['header'] = \rtrim($context['http']['header']); return $context; } - private function add_proxy(RequestInterface $request, &$options, $value, &$params) + /** + * @param mixed $value as passed via Request transfer options. + */ + private function add_proxy(RequestInterface $request, array &$options, $value, array &$params): void { - if (!is_array($value)) { - $options['http']['proxy'] = $value; + $uri = null; + + if (!\is_array($value)) { + $uri = $value; } else { $scheme = $request->getUri()->getScheme(); if (isset($value[$scheme])) { - if (!isset($value['no']) - || !\GuzzleHttp\is_host_in_noproxy( - $request->getUri()->getHost(), - $value['no'] - ) - ) { - $options['http']['proxy'] = $value[$scheme]; + if (!isset($value['no']) || !Utils::isHostInNoProxy($request->getUri()->getHost(), $value['no'])) { + $uri = $value[$scheme]; } } } + + if (!$uri) { + return; + } + + $parsed = $this->parse_proxy($uri); + $options['http']['proxy'] = $parsed['proxy']; + + if ($parsed['auth']) { + if (!isset($options['http']['header'])) { + $options['http']['header'] = []; + } + $options['http']['header'] .= "\r\nProxy-Authorization: {$parsed['auth']}"; + } } - private function add_timeout(RequestInterface $request, &$options, $value, &$params) + /** + * Parses the given proxy URL to make it compatible with the format PHP's stream context expects. + */ + private function parse_proxy(string $url): array + { + $parsed = \parse_url($url); + + if ($parsed !== false && isset($parsed['scheme']) && $parsed['scheme'] === 'http') { + if (isset($parsed['host']) && isset($parsed['port'])) { + $auth = null; + if (isset($parsed['user']) && isset($parsed['pass'])) { + $auth = \base64_encode("{$parsed['user']}:{$parsed['pass']}"); + } + + return [ + 'proxy' => "tcp://{$parsed['host']}:{$parsed['port']}", + 'auth' => $auth ? "Basic {$auth}" : null, + ]; + } + } + + // Return proxy as-is. + return [ + 'proxy' => $url, + 'auth' => null, + ]; + } + + /** + * @param mixed $value as passed via Request transfer options. + */ + private function add_timeout(RequestInterface $request, array &$options, $value, array &$params): void { if ($value > 0) { $options['http']['timeout'] = $value; } } - private function add_verify(RequestInterface $request, &$options, $value, &$params) + /** + * @param mixed $value as passed via Request transfer options. + */ + private function add_verify(RequestInterface $request, array &$options, $value, array &$params): void { - if ($value === true) { - // PHP 5.6 or greater will find the system cert by default. When - // < 5.6, use the Guzzle bundled cacert. - if (PHP_VERSION_ID < 50600) { - $options['ssl']['cafile'] = \GuzzleHttp\default_ca_bundle(); - } - } elseif (is_string($value)) { - $options['ssl']['cafile'] = $value; - if (!file_exists($value)) { - throw new \RuntimeException("SSL CA bundle not found: $value"); - } - } elseif ($value === false) { + if ($value === false) { $options['ssl']['verify_peer'] = false; $options['ssl']['verify_peer_name'] = false; + return; - } else { + } + + if (\is_string($value)) { + $options['ssl']['cafile'] = $value; + if (!\file_exists($value)) { + throw new \RuntimeException("SSL CA bundle not found: $value"); + } + } elseif ($value !== true) { throw new \InvalidArgumentException('Invalid verify request option'); } @@ -457,88 +488,93 @@ class StreamHandler $options['ssl']['allow_self_signed'] = false; } - private function add_cert(RequestInterface $request, &$options, $value, &$params) + /** + * @param mixed $value as passed via Request transfer options. + */ + private function add_cert(RequestInterface $request, array &$options, $value, array &$params): void { - if (is_array($value)) { + if (\is_array($value)) { $options['ssl']['passphrase'] = $value[1]; $value = $value[0]; } - if (!file_exists($value)) { + if (!\file_exists($value)) { throw new \RuntimeException("SSL certificate not found: {$value}"); } $options['ssl']['local_cert'] = $value; } - private function add_progress(RequestInterface $request, &$options, $value, &$params) + /** + * @param mixed $value as passed via Request transfer options. + */ + private function add_progress(RequestInterface $request, array &$options, $value, array &$params): void { - $this->addNotification( + self::addNotification( $params, - function ($code, $a, $b, $c, $transferred, $total) use ($value) { - if ($code == STREAM_NOTIFY_PROGRESS) { + static function ($code, $a, $b, $c, $transferred, $total) use ($value) { + if ($code == \STREAM_NOTIFY_PROGRESS) { $value($total, $transferred, null, null); } } ); } - private function add_debug(RequestInterface $request, &$options, $value, &$params) + /** + * @param mixed $value as passed via Request transfer options. + */ + private function add_debug(RequestInterface $request, array &$options, $value, array &$params): void { if ($value === false) { return; } static $map = [ - STREAM_NOTIFY_CONNECT => 'CONNECT', - STREAM_NOTIFY_AUTH_REQUIRED => 'AUTH_REQUIRED', - STREAM_NOTIFY_AUTH_RESULT => 'AUTH_RESULT', - STREAM_NOTIFY_MIME_TYPE_IS => 'MIME_TYPE_IS', - STREAM_NOTIFY_FILE_SIZE_IS => 'FILE_SIZE_IS', - STREAM_NOTIFY_REDIRECTED => 'REDIRECTED', - STREAM_NOTIFY_PROGRESS => 'PROGRESS', - STREAM_NOTIFY_FAILURE => 'FAILURE', - STREAM_NOTIFY_COMPLETED => 'COMPLETED', - STREAM_NOTIFY_RESOLVE => 'RESOLVE', + \STREAM_NOTIFY_CONNECT => 'CONNECT', + \STREAM_NOTIFY_AUTH_REQUIRED => 'AUTH_REQUIRED', + \STREAM_NOTIFY_AUTH_RESULT => 'AUTH_RESULT', + \STREAM_NOTIFY_MIME_TYPE_IS => 'MIME_TYPE_IS', + \STREAM_NOTIFY_FILE_SIZE_IS => 'FILE_SIZE_IS', + \STREAM_NOTIFY_REDIRECTED => 'REDIRECTED', + \STREAM_NOTIFY_PROGRESS => 'PROGRESS', + \STREAM_NOTIFY_FAILURE => 'FAILURE', + \STREAM_NOTIFY_COMPLETED => 'COMPLETED', + \STREAM_NOTIFY_RESOLVE => 'RESOLVE', ]; - static $args = ['severity', 'message', 'message_code', - 'bytes_transferred', 'bytes_max']; + static $args = ['severity', 'message', 'message_code', 'bytes_transferred', 'bytes_max']; - $value = \GuzzleHttp\debug_resource($value); + $value = Utils::debugResource($value); $ident = $request->getMethod() . ' ' . $request->getUri()->withFragment(''); - $this->addNotification( + self::addNotification( $params, - function () use ($ident, $value, $map, $args) { - $passed = func_get_args(); - $code = array_shift($passed); - fprintf($value, '<%s> [%s] ', $ident, $map[$code]); - foreach (array_filter($passed) as $i => $v) { - fwrite($value, $args[$i] . ': "' . $v . '" '); + static function (int $code, ...$passed) use ($ident, $value, $map, $args): void { + \fprintf($value, '<%s> [%s] ', $ident, $map[$code]); + foreach (\array_filter($passed) as $i => $v) { + \fwrite($value, $args[$i] . ': "' . $v . '" '); } - fwrite($value, "\n"); + \fwrite($value, "\n"); } ); } - private function addNotification(array &$params, callable $notify) + private static function addNotification(array &$params, callable $notify): void { // Wrap the existing function if needed. if (!isset($params['notification'])) { $params['notification'] = $notify; } else { - $params['notification'] = $this->callArray([ + $params['notification'] = self::callArray([ $params['notification'], $notify ]); } } - private function callArray(array $functions) + private static function callArray(array $functions): callable { - return function () use ($functions) { - $args = func_get_args(); + return static function (...$args) use ($functions) { foreach ($functions as $fn) { - call_user_func_array($fn, $args); + $fn(...$args); } }; } diff --git a/vendor/guzzlehttp/guzzle/src/HandlerStack.php b/vendor/guzzlehttp/guzzle/src/HandlerStack.php index 6a49cc069..b67239e7b 100644 --- a/vendor/guzzlehttp/guzzle/src/HandlerStack.php +++ b/vendor/guzzlehttp/guzzle/src/HandlerStack.php @@ -1,4 +1,5 @@ push(Middleware::httpErrors(), 'http_errors'); $stack->push(Middleware::redirect(), 'allow_redirects'); $stack->push(Middleware::cookies(), 'cookies'); @@ -49,7 +56,7 @@ class HandlerStack } /** - * @param callable $handler Underlying HTTP handler. + * @param null|callable(RequestInterface, array): PromiseInterface $handler Underlying HTTP handler. */ public function __construct(callable $handler = null) { @@ -59,9 +66,6 @@ class HandlerStack /** * Invokes the handler stack as a composed handler * - * @param RequestInterface $request - * @param array $options - * * @return ResponseInterface|PromiseInterface */ public function __invoke(RequestInterface $request, array $options) @@ -80,12 +84,13 @@ class HandlerStack { $depth = 0; $stack = []; - if ($this->handler) { + + if ($this->handler !== null) { $stack[] = "0) Handler: " . $this->debugCallable($this->handler); } $result = ''; - foreach (array_reverse($this->stack) as $tuple) { + foreach (\array_reverse($this->stack) as $tuple) { $depth++; $str = "{$depth}) Name: '{$tuple[1]}', "; $str .= "Function: " . $this->debugCallable($tuple[0]); @@ -93,7 +98,7 @@ class HandlerStack $stack[] = $str; } - foreach (array_keys($stack) as $k) { + foreach (\array_keys($stack) as $k) { $result .= "< {$stack[$k]}\n"; } @@ -103,10 +108,10 @@ class HandlerStack /** * Set the HTTP handler that actually returns a promise. * - * @param callable $handler Accepts a request and array of options and - * returns a Promise. + * @param callable(RequestInterface, array): PromiseInterface $handler Accepts a request and array of options and + * returns a Promise. */ - public function setHandler(callable $handler) + public function setHandler(callable $handler): void { $this->handler = $handler; $this->cached = null; @@ -114,33 +119,31 @@ class HandlerStack /** * Returns true if the builder has a handler. - * - * @return bool */ - public function hasHandler() + public function hasHandler(): bool { - return (bool) $this->handler; + return $this->handler !== null ; } /** * Unshift a middleware to the bottom of the stack. * - * @param callable $middleware Middleware function - * @param string $name Name to register for this middleware. + * @param callable(callable): callable $middleware Middleware function + * @param string $name Name to register for this middleware. */ - public function unshift(callable $middleware, $name = null) + public function unshift(callable $middleware, ?string $name = null): void { - array_unshift($this->stack, [$middleware, $name]); + \array_unshift($this->stack, [$middleware, $name]); $this->cached = null; } /** * Push a middleware to the top of the stack. * - * @param callable $middleware Middleware function - * @param string $name Name to register for this middleware. + * @param callable(callable): callable $middleware Middleware function + * @param string $name Name to register for this middleware. */ - public function push(callable $middleware, $name = '') + public function push(callable $middleware, string $name = ''): void { $this->stack[] = [$middleware, $name]; $this->cached = null; @@ -149,11 +152,11 @@ class HandlerStack /** * Add a middleware before another middleware by name. * - * @param string $findName Middleware to find - * @param callable $middleware Middleware function - * @param string $withName Name to register for this middleware. + * @param string $findName Middleware to find + * @param callable(callable): callable $middleware Middleware function + * @param string $withName Name to register for this middleware. */ - public function before($findName, callable $middleware, $withName = '') + public function before(string $findName, callable $middleware, string $withName = ''): void { $this->splice($findName, $withName, $middleware, true); } @@ -161,11 +164,11 @@ class HandlerStack /** * Add a middleware after another middleware by name. * - * @param string $findName Middleware to find - * @param callable $middleware Middleware function - * @param string $withName Name to register for this middleware. + * @param string $findName Middleware to find + * @param callable(callable): callable $middleware Middleware function + * @param string $withName Name to register for this middleware. */ - public function after($findName, callable $middleware, $withName = '') + public function after(string $findName, callable $middleware, string $withName = ''): void { $this->splice($findName, $withName, $middleware, false); } @@ -175,13 +178,13 @@ class HandlerStack * * @param callable|string $remove Middleware to remove by instance or name. */ - public function remove($remove) + public function remove($remove): void { $this->cached = null; - $idx = is_callable($remove) ? 0 : 1; - $this->stack = array_values(array_filter( + $idx = \is_callable($remove) ? 0 : 1; + $this->stack = \array_values(\array_filter( $this->stack, - function ($tuple) use ($idx, $remove) { + static function ($tuple) use ($idx, $remove) { return $tuple[$idx] !== $remove; } )); @@ -190,16 +193,17 @@ class HandlerStack /** * Compose the middleware and handler into a single callable function. * - * @return callable + * @return callable(RequestInterface, array): PromiseInterface */ - public function resolve() + public function resolve(): callable { - if (!$this->cached) { - if (!($prev = $this->handler)) { + if ($this->cached === null) { + if (($prev = $this->handler) === null) { throw new \LogicException('No handler has been specified'); } - foreach (array_reverse($this->stack) as $fn) { + foreach (\array_reverse($this->stack) as $fn) { + /** @var callable(RequestInterface, array): PromiseInterface $prev */ $prev = $fn[0]($prev); } @@ -209,11 +213,7 @@ class HandlerStack return $this->cached; } - /** - * @param string $name - * @return int - */ - private function findByName($name) + private function findByName(string $name): int { foreach ($this->stack as $k => $v) { if ($v[1] === $name) { @@ -226,13 +226,8 @@ class HandlerStack /** * Splices a function into the middleware list at a specific position. - * - * @param string $findName - * @param string $withName - * @param callable $middleware - * @param bool $before */ - private function splice($findName, $withName, callable $middleware, $before) + private function splice(string $findName, string $withName, callable $middleware, bool $before): void { $this->cached = null; $idx = $this->findByName($findName); @@ -240,38 +235,37 @@ class HandlerStack if ($before) { if ($idx === 0) { - array_unshift($this->stack, $tuple); + \array_unshift($this->stack, $tuple); } else { $replacement = [$tuple, $this->stack[$idx]]; - array_splice($this->stack, $idx, 1, $replacement); + \array_splice($this->stack, $idx, 1, $replacement); } - } elseif ($idx === count($this->stack) - 1) { + } elseif ($idx === \count($this->stack) - 1) { $this->stack[] = $tuple; } else { $replacement = [$this->stack[$idx], $tuple]; - array_splice($this->stack, $idx, 1, $replacement); + \array_splice($this->stack, $idx, 1, $replacement); } } /** * Provides a debug string for a given callable. * - * @param array|callable $fn Function to write as a string. - * - * @return string + * @param callable $fn Function to write as a string. */ - private function debugCallable($fn) + private function debugCallable($fn): string { - if (is_string($fn)) { + if (\is_string($fn)) { return "callable({$fn})"; } - if (is_array($fn)) { - return is_string($fn[0]) + if (\is_array($fn)) { + return \is_string($fn[0]) ? "callable({$fn[0]}::{$fn[1]})" - : "callable(['" . get_class($fn[0]) . "', '{$fn[1]}'])"; + : "callable(['" . \get_class($fn[0]) . "', '{$fn[1]}'])"; } - return 'callable(' . spl_object_hash($fn) . ')'; + /** @var object $fn */ + return 'callable(' . \spl_object_hash($fn) . ')'; } } diff --git a/vendor/guzzlehttp/guzzle/src/MessageFormatter.php b/vendor/guzzlehttp/guzzle/src/MessageFormatter.php index dc36bb524..238770f8e 100644 --- a/vendor/guzzlehttp/guzzle/src/MessageFormatter.php +++ b/vendor/guzzlehttp/guzzle/src/MessageFormatter.php @@ -1,4 +1,5 @@ >>>>>>>\n{request}\n<<<<<<<<\n{response}\n--------\n{error}"; - const SHORT = '[{ts}] "{method} {target} HTTP/{version}" {code}'; + public const CLF = "{hostname} {req_header_User-Agent} - [{date_common_log}] \"{method} {target} HTTP/{version}\" {code} {res_header_Content-Length}"; + public const DEBUG = ">>>>>>>>\n{request}\n<<<<<<<<\n{response}\n--------\n{error}"; + public const SHORT = '[{ts}] "{method} {target} HTTP/{version}" {code}'; - /** @var string Template used to format log messages */ + /** + * @var string Template used to format log messages + */ private $template; /** * @param string $template Log message template */ - public function __construct($template = self::CLF) + public function __construct(?string $template = self::CLF) { $this->template = $template ?: self::CLF; } @@ -57,20 +64,16 @@ class MessageFormatter /** * Returns a formatted message string. * - * @param RequestInterface $request Request that was sent - * @param ResponseInterface $response Response that was received - * @param \Exception $error Exception that was received - * - * @return string + * @param RequestInterface $request Request that was sent + * @param ResponseInterface|null $response Response that was received + * @param \Throwable|null $error Exception that was received */ - public function format( - RequestInterface $request, - ResponseInterface $response = null, - \Exception $error = null - ) { + public function format(RequestInterface $request, ?ResponseInterface $response = null, ?\Throwable $error = null): string + { $cache = []; - return preg_replace_callback( + /** @var string */ + return \preg_replace_callback( '/{\s*([A-Za-z_\-\.0-9]+)\s*}/', function (array $matches) use ($request, $response, $error, &$cache) { if (isset($cache[$matches[1]])) { @@ -80,20 +83,20 @@ class MessageFormatter $result = ''; switch ($matches[1]) { case 'request': - $result = Psr7\str($request); + $result = Psr7\Message::toString($request); break; case 'response': - $result = $response ? Psr7\str($response) : ''; + $result = $response ? Psr7\Message::toString($response) : ''; break; case 'req_headers': - $result = trim($request->getMethod() + $result = \trim($request->getMethod() . ' ' . $request->getRequestTarget()) . ' HTTP/' . $request->getProtocolVersion() . "\r\n" . $this->headers($request); break; case 'res_headers': $result = $response ? - sprintf( + \sprintf( 'HTTP/%s %d %s', $response->getProtocolVersion(), $response->getStatusCode(), @@ -102,17 +105,29 @@ class MessageFormatter : 'NULL'; break; case 'req_body': - $result = $request->getBody(); + $result = $request->getBody()->__toString(); break; case 'res_body': - $result = $response ? $response->getBody() : 'NULL'; + if (!$response instanceof ResponseInterface) { + $result = 'NULL'; + break; + } + + $body = $response->getBody(); + + if (!$body->isSeekable()) { + $result = 'RESPONSE_NOT_LOGGEABLE'; + break; + } + + $result = $response->getBody()->__toString(); break; case 'ts': case 'date_iso_8601': - $result = gmdate('c'); + $result = \gmdate('c'); break; case 'date_common_log': - $result = date('d/M/Y:H:i:s O'); + $result = \date('d/M/Y:H:i:s O'); break; case 'method': $result = $request->getMethod(); @@ -139,7 +154,7 @@ class MessageFormatter $result = $request->getHeaderLine('Host'); break; case 'hostname': - $result = gethostname(); + $result = \gethostname(); break; case 'code': $result = $response ? $response->getStatusCode() : 'NULL'; @@ -152,11 +167,11 @@ class MessageFormatter break; default: // handle prefixed dynamic headers - if (strpos($matches[1], 'req_header_') === 0) { - $result = $request->getHeaderLine(substr($matches[1], 11)); - } elseif (strpos($matches[1], 'res_header_') === 0) { + if (\strpos($matches[1], 'req_header_') === 0) { + $result = $request->getHeaderLine(\substr($matches[1], 11)); + } elseif (\strpos($matches[1], 'res_header_') === 0) { $result = $response - ? $response->getHeaderLine(substr($matches[1], 11)) + ? $response->getHeaderLine(\substr($matches[1], 11)) : 'NULL'; } } @@ -170,16 +185,14 @@ class MessageFormatter /** * Get headers from message as string - * - * @return string */ - private function headers(MessageInterface $message) + private function headers(MessageInterface $message): string { $result = ''; foreach ($message->getHeaders() as $name => $values) { - $result .= $name . ': ' . implode(', ', $values) . "\r\n"; + $result .= $name . ': ' . \implode(', ', $values) . "\r\n"; } - return trim($result); + return \trim($result); } } diff --git a/vendor/guzzlehttp/guzzle/src/MessageFormatterInterface.php b/vendor/guzzlehttp/guzzle/src/MessageFormatterInterface.php new file mode 100644 index 000000000..a39ac248e --- /dev/null +++ b/vendor/guzzlehttp/guzzle/src/MessageFormatterInterface.php @@ -0,0 +1,18 @@ +withCookieHeader($request); return $handler($request, $options) ->then( - function ($response) use ($cookieJar, $request) { + static function (ResponseInterface $response) use ($cookieJar, $request): ResponseInterface { $cookieJar->extractCookies($request, $response); return $response; } @@ -45,24 +47,26 @@ final class Middleware /** * Middleware that throws exceptions for 4xx or 5xx responses when the - * "http_error" request option is set to true. + * "http_errors" request option is set to true. * - * @return callable Returns a function that accepts the next handler. + * @param BodySummarizerInterface|null $bodySummarizer The body summarizer to use in exception messages. + * + * @return callable(callable): callable Returns a function that accepts the next handler. */ - public static function httpErrors() + public static function httpErrors(BodySummarizerInterface $bodySummarizer = null): callable { - return function (callable $handler) { - return function ($request, array $options) use ($handler) { + return static function (callable $handler) use ($bodySummarizer): callable { + return static function ($request, array $options) use ($handler, $bodySummarizer) { if (empty($options['http_errors'])) { return $handler($request, $options); } return $handler($request, $options)->then( - function (ResponseInterface $response) use ($request) { + static function (ResponseInterface $response) use ($request, $bodySummarizer) { $code = $response->getStatusCode(); if ($code < 400) { return $response; } - throw RequestException::create($request, $response); + throw RequestException::create($request, $response, null, [], $bodySummarizer); } ); }; @@ -72,21 +76,22 @@ final class Middleware /** * Middleware that pushes history data to an ArrayAccess container. * - * @param array|\ArrayAccess $container Container to hold the history (by reference). + * @param array|\ArrayAccess $container Container to hold the history (by reference). + * + * @return callable(callable): callable Returns a function that accepts the next handler. * - * @return callable Returns a function that accepts the next handler. * @throws \InvalidArgumentException if container is not an array or ArrayAccess. */ - public static function history(&$container) + public static function history(&$container): callable { - if (!is_array($container) && !$container instanceof \ArrayAccess) { + if (!\is_array($container) && !$container instanceof \ArrayAccess) { throw new \InvalidArgumentException('history container must be an array or object implementing ArrayAccess'); } - return function (callable $handler) use (&$container) { - return function ($request, array $options) use ($handler, &$container) { + return static function (callable $handler) use (&$container): callable { + return static function (RequestInterface $request, array $options) use ($handler, &$container) { return $handler($request, $options)->then( - function ($value) use ($request, &$container, $options) { + static function ($value) use ($request, &$container, $options) { $container[] = [ 'request' => $request, 'response' => $value, @@ -95,14 +100,14 @@ final class Middleware ]; return $value; }, - function ($reason) use ($request, &$container, $options) { + static function ($reason) use ($request, &$container, $options) { $container[] = [ 'request' => $request, 'response' => null, 'error' => $reason, 'options' => $options ]; - return \GuzzleHttp\Promise\rejection_for($reason); + return P\Create::rejectionFor($reason); } ); }; @@ -122,10 +127,10 @@ final class Middleware * * @return callable Returns a function that accepts the next handler. */ - public static function tap(callable $before = null, callable $after = null) + public static function tap(callable $before = null, callable $after = null): callable { - return function (callable $handler) use ($before, $after) { - return function ($request, array $options) use ($handler, $before, $after) { + return static function (callable $handler) use ($before, $after): callable { + return static function (RequestInterface $request, array $options) use ($handler, $before, $after) { if ($before) { $before($request, $options); } @@ -143,9 +148,9 @@ final class Middleware * * @return callable Returns a function that accepts the next handler. */ - public static function redirect() + public static function redirect(): callable { - return function (callable $handler) { + return static function (callable $handler): RedirectMiddleware { return new RedirectMiddleware($handler); }; } @@ -165,9 +170,9 @@ final class Middleware * * @return callable Returns a function that accepts the next handler. */ - public static function retry(callable $decider, callable $delay = null) + public static function retry(callable $decider, callable $delay = null): callable { - return function (callable $handler) use ($decider, $delay) { + return static function (callable $handler) use ($decider, $delay): RetryMiddleware { return new RetryMiddleware($decider, $handler, $delay); }; } @@ -176,29 +181,34 @@ final class Middleware * Middleware that logs requests, responses, and errors using a message * formatter. * - * @param LoggerInterface $logger Logs messages. - * @param MessageFormatter $formatter Formatter used to create message strings. - * @param string $logLevel Level at which to log requests. + * @phpstan-param \Psr\Log\LogLevel::* $logLevel Level at which to log requests. + * + * @param LoggerInterface $logger Logs messages. + * @param MessageFormatterInterface|MessageFormatter $formatter Formatter used to create message strings. + * @param string $logLevel Level at which to log requests. * * @return callable Returns a function that accepts the next handler. */ - public static function log(LoggerInterface $logger, MessageFormatter $formatter, $logLevel = 'info' /* \Psr\Log\LogLevel::INFO */) + public static function log(LoggerInterface $logger, $formatter, string $logLevel = 'info'): callable { - return function (callable $handler) use ($logger, $formatter, $logLevel) { - return function ($request, array $options) use ($handler, $logger, $formatter, $logLevel) { + // To be compatible with Guzzle 7.1.x we need to allow users to pass a MessageFormatter + if (!$formatter instanceof MessageFormatter && !$formatter instanceof MessageFormatterInterface) { + throw new \LogicException(sprintf('Argument 2 to %s::log() must be of type %s', self::class, MessageFormatterInterface::class)); + } + + return static function (callable $handler) use ($logger, $formatter, $logLevel): callable { + return static function (RequestInterface $request, array $options = []) use ($handler, $logger, $formatter, $logLevel) { return $handler($request, $options)->then( - function ($response) use ($logger, $request, $formatter, $logLevel) { + static function ($response) use ($logger, $request, $formatter, $logLevel): ResponseInterface { $message = $formatter->format($request, $response); $logger->log($logLevel, $message); return $response; }, - function ($reason) use ($logger, $request, $formatter) { - $response = $reason instanceof RequestException - ? $reason->getResponse() - : null; - $message = $formatter->format($request, $response, $reason); - $logger->notice($message); - return \GuzzleHttp\Promise\rejection_for($reason); + static function ($reason) use ($logger, $request, $formatter): PromiseInterface { + $response = $reason instanceof RequestException ? $reason->getResponse() : null; + $message = $formatter->format($request, $response, P\Create::exceptionFor($reason)); + $logger->error($message); + return P\Create::rejectionFor($reason); } ); }; @@ -208,12 +218,10 @@ final class Middleware /** * This middleware adds a default content-type if possible, a default * content-length or transfer-encoding header, and the expect header. - * - * @return callable */ - public static function prepareBody() + public static function prepareBody(): callable { - return function (callable $handler) { + return static function (callable $handler): PrepareBodyMiddleware { return new PrepareBodyMiddleware($handler); }; } @@ -224,12 +232,11 @@ final class Middleware * * @param callable $fn Function that accepts a RequestInterface and returns * a RequestInterface. - * @return callable */ - public static function mapRequest(callable $fn) + public static function mapRequest(callable $fn): callable { - return function (callable $handler) use ($fn) { - return function ($request, array $options) use ($handler, $fn) { + return static function (callable $handler) use ($fn): callable { + return static function (RequestInterface $request, array $options) use ($handler, $fn) { return $handler($fn($request), $options); }; }; @@ -241,12 +248,11 @@ final class Middleware * * @param callable $fn Function that accepts a ResponseInterface and * returns a ResponseInterface. - * @return callable */ - public static function mapResponse(callable $fn) + public static function mapResponse(callable $fn): callable { - return function (callable $handler) use ($fn) { - return function ($request, array $options) use ($handler, $fn) { + return static function (callable $handler) use ($fn): callable { + return static function (RequestInterface $request, array $options) use ($handler, $fn) { return $handler($request, $options)->then($fn); }; }; diff --git a/vendor/guzzlehttp/guzzle/src/Pool.php b/vendor/guzzlehttp/guzzle/src/Pool.php index 5838db4f4..6277c61fb 100644 --- a/vendor/guzzlehttp/guzzle/src/Pool.php +++ b/vendor/guzzlehttp/guzzle/src/Pool.php @@ -1,6 +1,8 @@ $rfn) { if ($rfn instanceof RequestInterface) { yield $key => $client->sendAsync($rfn, $opts); - } elseif (is_callable($rfn)) { + } elseif (\is_callable($rfn)) { yield $key => $rfn($opts); } else { - throw new \InvalidArgumentException('Each value yielded by ' - . 'the iterator must be a Psr7\Http\Message\RequestInterface ' - . 'or a callable that returns a promise that fulfills ' - . 'with a Psr7\Message\Http\ResponseInterface object.'); + throw new \InvalidArgumentException('Each value yielded by the iterator must be a Psr7\Http\Message\RequestInterface or a callable that returns a promise that fulfills with a Psr7\Message\Http\ResponseInterface object.'); } } }; @@ -72,10 +69,8 @@ class Pool implements PromisorInterface /** * Get promise - * - * @return PromiseInterface */ - public function promise() + public function promise(): PromiseInterface { return $this->each->promise(); } @@ -91,41 +86,37 @@ class Pool implements PromisorInterface * @param ClientInterface $client Client used to send the requests * @param array|\Iterator $requests Requests to send concurrently. * @param array $options Passes through the options available in - * {@see GuzzleHttp\Pool::__construct} + * {@see \GuzzleHttp\Pool::__construct} * * @return array Returns an array containing the response or an exception * in the same order that the requests were sent. + * * @throws \InvalidArgumentException if the event format is incorrect. */ - public static function batch( - ClientInterface $client, - $requests, - array $options = [] - ) { + public static function batch(ClientInterface $client, $requests, array $options = []): array + { $res = []; self::cmpCallback($options, 'fulfilled', $res); self::cmpCallback($options, 'rejected', $res); $pool = new static($client, $requests, $options); $pool->promise()->wait(); - ksort($res); + \ksort($res); return $res; } /** * Execute callback(s) - * - * @return void */ - private static function cmpCallback(array &$options, $name, array &$results) + private static function cmpCallback(array &$options, string $name, array &$results): void { if (!isset($options[$name])) { - $options[$name] = function ($v, $k) use (&$results) { + $options[$name] = static function ($v, $k) use (&$results) { $results[$k] = $v; }; } else { $currentFn = $options[$name]; - $options[$name] = function ($v, $k) use (&$results, $currentFn) { + $options[$name] = static function ($v, $k) use (&$results, $currentFn) { $currentFn($v, $k); $results[$k] = $v; }; diff --git a/vendor/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php b/vendor/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php index 568a1e906..7ca628338 100644 --- a/vendor/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php +++ b/vendor/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php @@ -1,34 +1,32 @@ nextHandler = $nextHandler; } - /** - * @param RequestInterface $request - * @param array $options - * - * @return PromiseInterface - */ - public function __invoke(RequestInterface $request, array $options) + public function __invoke(RequestInterface $request, array $options): PromiseInterface { $fn = $this->nextHandler; @@ -42,7 +40,7 @@ class PrepareBodyMiddleware // Add a default content-type if possible. if (!$request->hasHeader('Content-Type')) { if ($uri = $request->getBody()->getMetadata('uri')) { - if ($type = Psr7\mimetype_from_filename($uri)) { + if (is_string($uri) && $type = Psr7\MimeType::fromFilename($uri)) { $modify['set_headers']['Content-Type'] = $type; } } @@ -63,25 +61,20 @@ class PrepareBodyMiddleware // Add the expect header if needed. $this->addExpectHeader($request, $options, $modify); - return $fn(Psr7\modify_request($request, $modify), $options); + return $fn(Psr7\Utils::modifyRequest($request, $modify), $options); } /** * Add expect header - * - * @return void */ - private function addExpectHeader( - RequestInterface $request, - array $options, - array &$modify - ) { + private function addExpectHeader(RequestInterface $request, array $options, array &$modify): void + { // Determine if the Expect header should be used if ($request->hasHeader('Expect')) { return; } - $expect = isset($options['expect']) ? $options['expect'] : null; + $expect = $options['expect'] ?? null; // Return if disabled or if you're not using HTTP/1.1 or HTTP/2.0 if ($expect === false || $request->getProtocolVersion() < 1.1) { diff --git a/vendor/guzzlehttp/guzzle/src/RedirectMiddleware.php b/vendor/guzzlehttp/guzzle/src/RedirectMiddleware.php index e4644b7ac..1dd38614f 100644 --- a/vendor/guzzlehttp/guzzle/src/RedirectMiddleware.php +++ b/vendor/guzzlehttp/guzzle/src/RedirectMiddleware.php @@ -1,10 +1,10 @@ 5, 'protocols' => ['http', 'https'], @@ -29,24 +34,20 @@ class RedirectMiddleware 'track_redirects' => false, ]; - /** @var callable */ + /** + * @var callable(RequestInterface, array): PromiseInterface + */ private $nextHandler; /** - * @param callable $nextHandler Next handler to invoke. + * @param callable(RequestInterface, array): PromiseInterface $nextHandler Next handler to invoke. */ public function __construct(callable $nextHandler) { $this->nextHandler = $nextHandler; } - /** - * @param RequestInterface $request - * @param array $options - * - * @return PromiseInterface - */ - public function __invoke(RequestInterface $request, array $options) + public function __invoke(RequestInterface $request, array $options): PromiseInterface { $fn = $this->nextHandler; @@ -56,7 +57,7 @@ class RedirectMiddleware if ($options['allow_redirects'] === true) { $options['allow_redirects'] = self::$defaultSettings; - } elseif (!is_array($options['allow_redirects'])) { + } elseif (!\is_array($options['allow_redirects'])) { throw new \InvalidArgumentException('allow_redirects must be true, false, or array'); } else { // Merge the default settings with the provided settings @@ -74,36 +75,27 @@ class RedirectMiddleware } /** - * @param RequestInterface $request - * @param array $options - * @param ResponseInterface $response - * * @return ResponseInterface|PromiseInterface */ - public function checkRedirect( - RequestInterface $request, - array $options, - ResponseInterface $response - ) { - if (substr($response->getStatusCode(), 0, 1) != '3' + public function checkRedirect(RequestInterface $request, array $options, ResponseInterface $response) + { + if (\strpos((string) $response->getStatusCode(), '3') !== 0 || !$response->hasHeader('Location') ) { return $response; } - $this->guardMax($request, $options); + $this->guardMax($request, $response, $options); $nextRequest = $this->modifyRequest($request, $options, $response); if (isset($options['allow_redirects']['on_redirect'])) { - call_user_func( - $options['allow_redirects']['on_redirect'], + ($options['allow_redirects']['on_redirect'])( $request, $response, $nextRequest->getUri() ); } - /** @var PromiseInterface|ResponseInterface $promise */ $promise = $this($nextRequest, $options); // Add headers to be able to track history of redirects. @@ -120,20 +112,19 @@ class RedirectMiddleware /** * Enable tracking on promise. - * - * @return PromiseInterface */ - private function withTracking(PromiseInterface $promise, $uri, $statusCode) + private function withTracking(PromiseInterface $promise, string $uri, int $statusCode): PromiseInterface { return $promise->then( - function (ResponseInterface $response) use ($uri, $statusCode) { + static function (ResponseInterface $response) use ($uri, $statusCode) { // Note that we are pushing to the front of the list as this // would be an earlier response than what is currently present // in the history header. $historyHeader = $response->getHeader(self::HISTORY_HEADER); $statusHeader = $response->getHeader(self::STATUS_HISTORY_HEADER); - array_unshift($historyHeader, $uri); - array_unshift($statusHeader, $statusCode); + \array_unshift($historyHeader, $uri); + \array_unshift($statusHeader, (string) $statusCode); + return $response->withHeader(self::HISTORY_HEADER, $historyHeader) ->withHeader(self::STATUS_HISTORY_HEADER, $statusHeader); } @@ -143,38 +134,22 @@ class RedirectMiddleware /** * Check for too many redirects * - * @return void - * * @throws TooManyRedirectsException Too many redirects. */ - private function guardMax(RequestInterface $request, array &$options) + private function guardMax(RequestInterface $request, ResponseInterface $response, array &$options): void { - $current = isset($options['__redirect_count']) - ? $options['__redirect_count'] - : 0; + $current = $options['__redirect_count'] + ?? 0; $options['__redirect_count'] = $current + 1; $max = $options['allow_redirects']['max']; if ($options['__redirect_count'] > $max) { - throw new TooManyRedirectsException( - "Will not follow more than {$max} redirects", - $request - ); + throw new TooManyRedirectsException("Will not follow more than {$max} redirects", $request, $response); } } - /** - * @param RequestInterface $request - * @param array $options - * @param ResponseInterface $response - * - * @return RequestInterface - */ - public function modifyRequest( - RequestInterface $request, - array $options, - ResponseInterface $response - ) { + public function modifyRequest(RequestInterface $request, array $options, ResponseInterface $response): RequestInterface + { // Request modifications to apply. $modify = []; $protocols = $options['allow_redirects']['protocols']; @@ -186,18 +161,21 @@ class RedirectMiddleware if ($statusCode == 303 || ($statusCode <= 302 && !$options['allow_redirects']['strict']) ) { - $modify['method'] = 'GET'; + $safeMethods = ['GET', 'HEAD', 'OPTIONS']; + $requestMethod = $request->getMethod(); + + $modify['method'] = in_array($requestMethod, $safeMethods) ? $requestMethod : 'GET'; $modify['body'] = ''; } $uri = $this->redirectUri($request, $response, $protocols); if (isset($options['idn_conversion']) && ($options['idn_conversion'] !== false)) { - $idnOptions = ($options['idn_conversion'] === true) ? IDNA_DEFAULT : $options['idn_conversion']; + $idnOptions = ($options['idn_conversion'] === true) ? \IDNA_DEFAULT : $options['idn_conversion']; $uri = Utils::idnUriConvert($uri, $idnOptions); } $modify['uri'] = $uri; - Psr7\rewind_body($request); + Psr7\Message::rewindBody($request); // Add the Referer header if it is told to do so and only // add the header if we are not redirecting from https to http. @@ -215,39 +193,22 @@ class RedirectMiddleware $modify['remove_headers'][] = 'Authorization'; } - return Psr7\modify_request($request, $modify); + return Psr7\Utils::modifyRequest($request, $modify); } /** * Set the appropriate URL on the request based on the location header - * - * @param RequestInterface $request - * @param ResponseInterface $response - * @param array $protocols - * - * @return UriInterface */ - private function redirectUri( - RequestInterface $request, - ResponseInterface $response, - array $protocols - ) { + private function redirectUri(RequestInterface $request, ResponseInterface $response, array $protocols): UriInterface + { $location = Psr7\UriResolver::resolve( $request->getUri(), new Psr7\Uri($response->getHeaderLine('Location')) ); // Ensure that the redirect URI is allowed based on the protocols. - if (!in_array($location->getScheme(), $protocols)) { - throw new BadResponseException( - sprintf( - 'Redirect URI, %s, does not use one of the allowed redirect protocols: %s', - $location, - implode(', ', $protocols) - ), - $request, - $response - ); + if (!\in_array($location->getScheme(), $protocols)) { + throw new BadResponseException(\sprintf('Redirect URI, %s, does not use one of the allowed redirect protocols: %s', $location, \implode(', ', $protocols)), $request, $response); } return $location; diff --git a/vendor/guzzlehttp/guzzle/src/RequestOptions.php b/vendor/guzzlehttp/guzzle/src/RequestOptions.php index 355f658f0..20b31bc20 100644 --- a/vendor/guzzlehttp/guzzle/src/RequestOptions.php +++ b/vendor/guzzlehttp/guzzle/src/RequestOptions.php @@ -1,4 +1,5 @@ decider = $decider; $this->nextHandler = $nextHandler; $this->delay = $delay ?: __CLASS__ . '::exponentialDelay'; @@ -45,22 +50,14 @@ class RetryMiddleware /** * Default exponential backoff delay function. * - * @param int $retries - * * @return int milliseconds. */ - public static function exponentialDelay($retries) + public static function exponentialDelay(int $retries): int { - return (int) pow(2, $retries - 1) * 1000; + return (int) \pow(2, $retries - 1) * 1000; } - /** - * @param RequestInterface $request - * @param array $options - * - * @return PromiseInterface - */ - public function __invoke(RequestInterface $request, array $options) + public function __invoke(RequestInterface $request, array $options): PromiseInterface { if (!isset($options['retries'])) { $options['retries'] = 0; @@ -76,52 +73,43 @@ class RetryMiddleware /** * Execute fulfilled closure - * - * @return mixed */ - private function onFulfilled(RequestInterface $req, array $options) + private function onFulfilled(RequestInterface $request, array $options): callable { - return function ($value) use ($req, $options) { - if (!call_user_func( - $this->decider, + return function ($value) use ($request, $options) { + if (!($this->decider)( $options['retries'], - $req, + $request, $value, null )) { return $value; } - return $this->doRetry($req, $options, $value); + return $this->doRetry($request, $options, $value); }; } /** * Execute rejected closure - * - * @return callable */ - private function onRejected(RequestInterface $req, array $options) + private function onRejected(RequestInterface $req, array $options): callable { return function ($reason) use ($req, $options) { - if (!call_user_func( - $this->decider, + if (!($this->decider)( $options['retries'], $req, null, $reason )) { - return \GuzzleHttp\Promise\rejection_for($reason); + return P\Create::rejectionFor($reason); } return $this->doRetry($req, $options); }; } - /** - * @return self - */ - private function doRetry(RequestInterface $request, array $options, ResponseInterface $response = null) + private function doRetry(RequestInterface $request, array $options, ResponseInterface $response = null): PromiseInterface { - $options['delay'] = call_user_func($this->delay, ++$options['retries'], $response); + $options['delay'] = ($this->delay)(++$options['retries'], $response); return $this($request, $options); } diff --git a/vendor/guzzlehttp/guzzle/src/TransferStats.php b/vendor/guzzlehttp/guzzle/src/TransferStats.php index 87fb3c001..93fa334c8 100644 --- a/vendor/guzzlehttp/guzzle/src/TransferStats.php +++ b/vendor/guzzlehttp/guzzle/src/TransferStats.php @@ -1,4 +1,5 @@ request = $request; $this->response = $response; @@ -38,30 +58,23 @@ final class TransferStats $this->handlerStats = $handlerStats; } - /** - * @return RequestInterface - */ - public function getRequest() + public function getRequest(): RequestInterface { return $this->request; } /** * Returns the response that was received (if any). - * - * @return ResponseInterface|null */ - public function getResponse() + public function getResponse(): ?ResponseInterface { return $this->response; } /** * Returns true if a response was received. - * - * @return bool */ - public function hasResponse() + public function hasResponse(): bool { return $this->response !== null; } @@ -82,10 +95,8 @@ final class TransferStats /** * Get the effective URI the request was sent to. - * - * @return UriInterface */ - public function getEffectiveUri() + public function getEffectiveUri(): UriInterface { return $this->request->getUri(); } @@ -95,17 +106,15 @@ final class TransferStats * * @return float|null Time in seconds. */ - public function getTransferTime() + public function getTransferTime(): ?float { return $this->transferTime; } /** * Gets an array of all of the handler specific transfer data. - * - * @return array */ - public function getHandlerStats() + public function getHandlerStats(): array { return $this->handlerStats; } @@ -117,10 +126,8 @@ final class TransferStats * * @return mixed|null */ - public function getHandlerStat($stat) + public function getHandlerStat(string $stat) { - return isset($this->handlerStats[$stat]) - ? $this->handlerStats[$stat] - : null; + return $this->handlerStats[$stat] ?? null; } } diff --git a/vendor/guzzlehttp/guzzle/src/UriTemplate.php b/vendor/guzzlehttp/guzzle/src/UriTemplate.php deleted file mode 100644 index 96dcfd09c..000000000 --- a/vendor/guzzlehttp/guzzle/src/UriTemplate.php +++ /dev/null @@ -1,237 +0,0 @@ - ['prefix' => '', 'joiner' => ',', 'query' => false], - '+' => ['prefix' => '', 'joiner' => ',', 'query' => false], - '#' => ['prefix' => '#', 'joiner' => ',', 'query' => false], - '.' => ['prefix' => '.', 'joiner' => '.', 'query' => false], - '/' => ['prefix' => '/', 'joiner' => '/', 'query' => false], - ';' => ['prefix' => ';', 'joiner' => ';', 'query' => true], - '?' => ['prefix' => '?', 'joiner' => '&', 'query' => true], - '&' => ['prefix' => '&', 'joiner' => '&', 'query' => true] - ]; - - /** @var array Delimiters */ - private static $delims = [':', '/', '?', '#', '[', ']', '@', '!', '$', - '&', '\'', '(', ')', '*', '+', ',', ';', '=']; - - /** @var array Percent encoded delimiters */ - private static $delimsPct = ['%3A', '%2F', '%3F', '%23', '%5B', '%5D', - '%40', '%21', '%24', '%26', '%27', '%28', '%29', '%2A', '%2B', '%2C', - '%3B', '%3D']; - - public function expand($template, array $variables) - { - if (false === strpos($template, '{')) { - return $template; - } - - $this->template = $template; - $this->variables = $variables; - - return preg_replace_callback( - '/\{([^\}]+)\}/', - [$this, 'expandMatch'], - $this->template - ); - } - - /** - * Parse an expression into parts - * - * @param string $expression Expression to parse - * - * @return array Returns an associative array of parts - */ - private function parseExpression($expression) - { - $result = []; - - if (isset(self::$operatorHash[$expression[0]])) { - $result['operator'] = $expression[0]; - $expression = substr($expression, 1); - } else { - $result['operator'] = ''; - } - - foreach (explode(',', $expression) as $value) { - $value = trim($value); - $varspec = []; - if ($colonPos = strpos($value, ':')) { - $varspec['value'] = substr($value, 0, $colonPos); - $varspec['modifier'] = ':'; - $varspec['position'] = (int) substr($value, $colonPos + 1); - } elseif (substr($value, -1) === '*') { - $varspec['modifier'] = '*'; - $varspec['value'] = substr($value, 0, -1); - } else { - $varspec['value'] = (string) $value; - $varspec['modifier'] = ''; - } - $result['values'][] = $varspec; - } - - return $result; - } - - /** - * Process an expansion - * - * @param array $matches Matches met in the preg_replace_callback - * - * @return string Returns the replacement string - */ - private function expandMatch(array $matches) - { - static $rfc1738to3986 = ['+' => '%20', '%7e' => '~']; - - $replacements = []; - $parsed = self::parseExpression($matches[1]); - $prefix = self::$operatorHash[$parsed['operator']]['prefix']; - $joiner = self::$operatorHash[$parsed['operator']]['joiner']; - $useQuery = self::$operatorHash[$parsed['operator']]['query']; - - foreach ($parsed['values'] as $value) { - if (!isset($this->variables[$value['value']])) { - continue; - } - - $variable = $this->variables[$value['value']]; - $actuallyUseQuery = $useQuery; - $expanded = ''; - - if (is_array($variable)) { - $isAssoc = $this->isAssoc($variable); - $kvp = []; - foreach ($variable as $key => $var) { - if ($isAssoc) { - $key = rawurlencode($key); - $isNestedArray = is_array($var); - } else { - $isNestedArray = false; - } - - if (!$isNestedArray) { - $var = rawurlencode($var); - if ($parsed['operator'] === '+' || - $parsed['operator'] === '#' - ) { - $var = $this->decodeReserved($var); - } - } - - if ($value['modifier'] === '*') { - if ($isAssoc) { - if ($isNestedArray) { - // Nested arrays must allow for deeply nested - // structures. - $var = strtr( - http_build_query([$key => $var]), - $rfc1738to3986 - ); - } else { - $var = $key . '=' . $var; - } - } elseif ($key > 0 && $actuallyUseQuery) { - $var = $value['value'] . '=' . $var; - } - } - - $kvp[$key] = $var; - } - - if (empty($variable)) { - $actuallyUseQuery = false; - } elseif ($value['modifier'] === '*') { - $expanded = implode($joiner, $kvp); - if ($isAssoc) { - // Don't prepend the value name when using the explode - // modifier with an associative array. - $actuallyUseQuery = false; - } - } else { - if ($isAssoc) { - // When an associative array is encountered and the - // explode modifier is not set, then the result must be - // a comma separated list of keys followed by their - // respective values. - foreach ($kvp as $k => &$v) { - $v = $k . ',' . $v; - } - } - $expanded = implode(',', $kvp); - } - } else { - if ($value['modifier'] === ':') { - $variable = substr($variable, 0, $value['position']); - } - $expanded = rawurlencode($variable); - if ($parsed['operator'] === '+' || $parsed['operator'] === '#') { - $expanded = $this->decodeReserved($expanded); - } - } - - if ($actuallyUseQuery) { - if (!$expanded && $joiner !== '&') { - $expanded = $value['value']; - } else { - $expanded = $value['value'] . '=' . $expanded; - } - } - - $replacements[] = $expanded; - } - - $ret = implode($joiner, $replacements); - if ($ret && $prefix) { - return $prefix . $ret; - } - - return $ret; - } - - /** - * Determines if an array is associative. - * - * This makes the assumption that input arrays are sequences or hashes. - * This assumption is a tradeoff for accuracy in favor of speed, but it - * should work in almost every case where input is supplied for a URI - * template. - * - * @param array $array Array to check - * - * @return bool - */ - private function isAssoc(array $array) - { - return $array && array_keys($array)[0] !== 0; - } - - /** - * Removes percent encoding on reserved characters (used with + and # - * modifiers). - * - * @param string $string String to fix - * - * @return string - */ - private function decodeReserved($string) - { - return str_replace(self::$delimsPct, self::$delims, $string); - } -} diff --git a/vendor/guzzlehttp/guzzle/src/Utils.php b/vendor/guzzlehttp/guzzle/src/Utils.php index c698acbf0..1e4e70462 100644 --- a/vendor/guzzlehttp/guzzle/src/Utils.php +++ b/vendor/guzzlehttp/guzzle/src/Utils.php @@ -1,41 +1,331 @@ getHost()) { $asciiHost = self::idnToAsci($uri->getHost(), $options, $info); if ($asciiHost === false) { - $errorBitSet = isset($info['errors']) ? $info['errors'] : 0; + $errorBitSet = $info['errors'] ?? 0; - $errorConstants = array_filter(array_keys(get_defined_constants()), function ($name) { + $errorConstants = array_filter(array_keys(get_defined_constants()), static function ($name) { return substr($name, 0, 11) === 'IDNA_ERROR_'; }); @@ -52,11 +342,10 @@ final class Utils } throw new InvalidArgumentException($errorMessage); - } else { - if ($uri->getHost() !== $asciiHost) { - // Replace URI only if the ASCII version is different - $uri = $uri->withHost($asciiHost); - } + } + if ($uri->getHost() !== $asciiHost) { + // Replace URI only if the ASCII version is different + $uri = $uri->withHost($asciiHost); } } @@ -64,29 +353,30 @@ final class Utils } /** - * @param string $domain - * @param int $options - * @param array $info - * + * @internal + */ + public static function getenv(string $name): ?string + { + if (isset($_SERVER[$name])) { + return (string) $_SERVER[$name]; + } + + if (\PHP_SAPI === 'cli' && ($value = \getenv($name)) !== false && $value !== null) { + return (string) $value; + } + + return null; + } + + /** * @return string|false */ - private static function idnToAsci($domain, $options, &$info = []) + private static function idnToAsci(string $domain, int $options, ?array &$info = []) { - if (\preg_match('%^[ -~]+$%', $domain) === 1) { - return $domain; + if (\function_exists('idn_to_ascii') && \defined('INTL_IDNA_VARIANT_UTS46')) { + return \idn_to_ascii($domain, $options, \INTL_IDNA_VARIANT_UTS46, $info); } - if (\extension_loaded('intl') && defined('INTL_IDNA_VARIANT_UTS46')) { - return \idn_to_ascii($domain, $options, INTL_IDNA_VARIANT_UTS46, $info); - } - - /* - * The Idn class is marked as @internal. Verify that class and method exists. - */ - if (method_exists(Idn::class, 'idn_to_ascii')) { - return Idn::idn_to_ascii($domain, $options, Idn::INTL_IDNA_VARIANT_UTS46, $info); - } - - throw new \RuntimeException('ext-intl or symfony/polyfill-intl-idn not loaded or too old'); + throw new \Error('ext-idn or symfony/polyfill-intl-idn not loaded or too old'); } } diff --git a/vendor/guzzlehttp/guzzle/src/functions.php b/vendor/guzzlehttp/guzzle/src/functions.php index c2afd8c7b..a70d2cbf3 100644 --- a/vendor/guzzlehttp/guzzle/src/functions.php +++ b/vendor/guzzlehttp/guzzle/src/functions.php @@ -1,77 +1,34 @@ expand($template, $variables); -} - /** * Debug function used to describe the provided value type and class. * - * @param mixed $input + * @param mixed $input Any type of variable to describe the type of. This + * parameter misses a typehint because of that. * * @return string Returns a string containing the type of the variable and * if a class is provided, the class name. + * + * @deprecated describe_type will be removed in guzzlehttp/guzzle:8.0. Use Utils::describeType instead. */ -function describe_type($input) +function describe_type($input): string { - switch (gettype($input)) { - case 'object': - return 'object(' . get_class($input) . ')'; - case 'array': - return 'array(' . count($input) . ')'; - default: - ob_start(); - var_dump($input); - // normalize float vs double - return str_replace('double(', 'float(', rtrim(ob_get_clean())); - } + return Utils::describeType($input); } /** * Parses an array of header lines into an associative array of headers. * * @param iterable $lines Header lines array of strings in the following - * format: "Name: Value" - * @return array + * format: "Name: Value" + * + * @deprecated headers_from_lines will be removed in guzzlehttp/guzzle:8.0. Use Utils::headersFromLines instead. */ -function headers_from_lines($lines) +function headers_from_lines(iterable $lines): array { - $headers = []; - - foreach ($lines as $line) { - $parts = explode(':', $line, 2); - $headers[trim($parts[0])][] = isset($parts[1]) - ? trim($parts[1]) - : null; - } - - return $headers; + return Utils::headersFromLines($lines); } /** @@ -80,16 +37,12 @@ function headers_from_lines($lines) * @param mixed $value Optional value * * @return resource + * + * @deprecated debug_resource will be removed in guzzlehttp/guzzle:8.0. Use Utils::debugResource instead. */ function debug_resource($value = null) { - if (is_resource($value)) { - return $value; - } elseif (defined('STDOUT')) { - return STDOUT; - } - - return fopen('php://output', 'w'); + return Utils::debugResource($value); } /** @@ -97,50 +50,25 @@ function debug_resource($value = null) * * The returned handler is not wrapped by any default middlewares. * - * @return callable Returns the best handler for the given system. * @throws \RuntimeException if no viable Handler is available. + * + * @return callable(\Psr\Http\Message\RequestInterface, array): \GuzzleHttp\Promise\PromiseInterface Returns the best handler for the given system. + * + * @deprecated choose_handler will be removed in guzzlehttp/guzzle:8.0. Use Utils::chooseHandler instead. */ -function choose_handler() +function choose_handler(): callable { - $handler = null; - if (function_exists('curl_multi_exec') && function_exists('curl_exec')) { - $handler = Proxy::wrapSync(new CurlMultiHandler(), new CurlHandler()); - } elseif (function_exists('curl_exec')) { - $handler = new CurlHandler(); - } elseif (function_exists('curl_multi_exec')) { - $handler = new CurlMultiHandler(); - } - - if (ini_get('allow_url_fopen')) { - $handler = $handler - ? Proxy::wrapStreaming($handler, new StreamHandler()) - : new StreamHandler(); - } elseif (!$handler) { - throw new \RuntimeException('GuzzleHttp requires cURL, the ' - . 'allow_url_fopen ini setting, or a custom HTTP handler.'); - } - - return $handler; + return Utils::chooseHandler(); } /** - * Get the default User-Agent string to use with Guzzle + * Get the default User-Agent string to use with Guzzle. * - * @return string + * @deprecated default_user_agent will be removed in guzzlehttp/guzzle:8.0. Use Utils::defaultUserAgent instead. */ -function default_user_agent() +function default_user_agent(): string { - static $defaultAgent = ''; - - if (!$defaultAgent) { - $defaultAgent = 'GuzzleHttp/' . Client::VERSION; - if (extension_loaded('curl') && function_exists('curl_version')) { - $defaultAgent .= ' curl/' . \curl_version()['version']; - } - $defaultAgent .= ' PHP/' . PHP_VERSION; - } - - return $defaultAgent; + return Utils::defaultUserAgent(); } /** @@ -154,82 +82,24 @@ function default_user_agent() * * Note: the result of this function is cached for subsequent calls. * - * @return string * @throws \RuntimeException if no bundle can be found. + * + * @deprecated default_ca_bundle will be removed in guzzlehttp/guzzle:8.0. This function is not needed in PHP 5.6+. */ -function default_ca_bundle() +function default_ca_bundle(): string { - static $cached = null; - static $cafiles = [ - // Red Hat, CentOS, Fedora (provided by the ca-certificates package) - '/etc/pki/tls/certs/ca-bundle.crt', - // Ubuntu, Debian (provided by the ca-certificates package) - '/etc/ssl/certs/ca-certificates.crt', - // FreeBSD (provided by the ca_root_nss package) - '/usr/local/share/certs/ca-root-nss.crt', - // SLES 12 (provided by the ca-certificates package) - '/var/lib/ca-certificates/ca-bundle.pem', - // OS X provided by homebrew (using the default path) - '/usr/local/etc/openssl/cert.pem', - // Google app engine - '/etc/ca-certificates.crt', - // Windows? - 'C:\\windows\\system32\\curl-ca-bundle.crt', - 'C:\\windows\\curl-ca-bundle.crt', - ]; - - if ($cached) { - return $cached; - } - - if ($ca = ini_get('openssl.cafile')) { - return $cached = $ca; - } - - if ($ca = ini_get('curl.cainfo')) { - return $cached = $ca; - } - - foreach ($cafiles as $filename) { - if (file_exists($filename)) { - return $cached = $filename; - } - } - - throw new \RuntimeException( - <<< EOT -No system CA bundle could be found in any of the the common system locations. -PHP versions earlier than 5.6 are not properly configured to use the system's -CA bundle by default. In order to verify peer certificates, you will need to -supply the path on disk to a certificate bundle to the 'verify' request -option: http://docs.guzzlephp.org/en/latest/clients.html#verify. If you do not -need a specific certificate bundle, then Mozilla provides a commonly used CA -bundle which can be downloaded here (provided by the maintainer of cURL): -https://raw.githubusercontent.com/bagder/ca-bundle/master/ca-bundle.crt. Once -you have a CA bundle available on disk, you can set the 'openssl.cafile' PHP -ini setting to point to the path to the file, allowing you to omit the 'verify' -request option. See http://curl.haxx.se/docs/sslcerts.html for more -information. -EOT - ); + return Utils::defaultCaBundle(); } /** * Creates an associative array of lowercase header names to the actual * header casing. * - * @param array $headers - * - * @return array + * @deprecated normalize_header_keys will be removed in guzzlehttp/guzzle:8.0. Use Utils::normalizeHeaderKeys instead. */ -function normalize_header_keys(array $headers) +function normalize_header_keys(array $headers): array { - $result = []; - foreach (array_keys($headers) as $key) { - $result[strtolower($key)] = $key; - } - - return $result; + return Utils::normalizeHeaderKeys($headers); } /** @@ -246,89 +116,52 @@ function normalize_header_keys(array $headers) * 3. The area starts with "." and the area is the last part of the host. e.g. * '.mit.edu' will match any host that ends with '.mit.edu'. * - * @param string $host Host to check against the patterns. - * @param array $noProxyArray An array of host patterns. + * @param string $host Host to check against the patterns. + * @param string[] $noProxyArray An array of host patterns. * - * @return bool + * @throws Exception\InvalidArgumentException + * + * @deprecated is_host_in_noproxy will be removed in guzzlehttp/guzzle:8.0. Use Utils::isHostInNoProxy instead. */ -function is_host_in_noproxy($host, array $noProxyArray) +function is_host_in_noproxy(string $host, array $noProxyArray): bool { - if (strlen($host) === 0) { - throw new \InvalidArgumentException('Empty host provided'); - } - - // Strip port if present. - if (strpos($host, ':')) { - $host = explode($host, ':', 2)[0]; - } - - foreach ($noProxyArray as $area) { - // Always match on wildcards. - if ($area === '*') { - return true; - } elseif (empty($area)) { - // Don't match on empty values. - continue; - } elseif ($area === $host) { - // Exact matches. - return true; - } else { - // Special match if the area when prefixed with ".". Remove any - // existing leading "." and add a new leading ".". - $area = '.' . ltrim($area, '.'); - if (substr($host, -(strlen($area))) === $area) { - return true; - } - } - } - - return false; + return Utils::isHostInNoProxy($host, $noProxyArray); } /** * Wrapper for json_decode that throws when an error occurs. * * @param string $json JSON data to parse - * @param bool $assoc When true, returned objects will be converted + * @param bool $assoc When true, returned objects will be converted * into associative arrays. * @param int $depth User specified recursion depth. * @param int $options Bitmask of JSON decode options. * - * @return mixed + * @return object|array|string|int|float|bool|null + * * @throws Exception\InvalidArgumentException if the JSON cannot be decoded. - * @link http://www.php.net/manual/en/function.json-decode.php + * + * @link https://www.php.net/manual/en/function.json-decode.php + * @deprecated json_decode will be removed in guzzlehttp/guzzle:8.0. Use Utils::jsonDecode instead. */ -function json_decode($json, $assoc = false, $depth = 512, $options = 0) +function json_decode(string $json, bool $assoc = false, int $depth = 512, int $options = 0) { - $data = \json_decode($json, $assoc, $depth, $options); - if (JSON_ERROR_NONE !== json_last_error()) { - throw new Exception\InvalidArgumentException( - 'json_decode error: ' . json_last_error_msg() - ); - } - - return $data; + return Utils::jsonDecode($json, $assoc, $depth, $options); } /** * Wrapper for JSON encoding that throws when an error occurs. * * @param mixed $value The value being encoded - * @param int $options JSON encode option bitmask - * @param int $depth Set the maximum depth. Must be greater than zero. + * @param int $options JSON encode option bitmask + * @param int $depth Set the maximum depth. Must be greater than zero. * - * @return string * @throws Exception\InvalidArgumentException if the JSON cannot be encoded. - * @link http://www.php.net/manual/en/function.json-encode.php + * + * @link https://www.php.net/manual/en/function.json-encode.php + * @deprecated json_encode will be removed in guzzlehttp/guzzle:8.0. Use Utils::jsonEncode instead. */ -function json_encode($value, $options = 0, $depth = 512) +function json_encode($value, int $options = 0, int $depth = 512): string { - $json = \json_encode($value, $options, $depth); - if (JSON_ERROR_NONE !== json_last_error()) { - throw new Exception\InvalidArgumentException( - 'json_encode error: ' . json_last_error_msg() - ); - } - - return $json; + return Utils::jsonEncode($value, $options, $depth); } diff --git a/vendor/guzzlehttp/guzzle/src/functions_include.php b/vendor/guzzlehttp/guzzle/src/functions_include.php index a93393acc..6636a4224 100644 --- a/vendor/guzzlehttp/guzzle/src/functions_include.php +++ b/vendor/guzzlehttp/guzzle/src/functions_include.php @@ -1,6 +1,6 @@ Build Status -Total Downloads -Latest Stable Version -License +Total Downloads +Latest Stable Version +License

## About Laravel diff --git a/vendor/laravel/framework/composer.json b/vendor/laravel/framework/composer.json index dea51b9ab..affcbe711 100644 --- a/vendor/laravel/framework/composer.json +++ b/vendor/laravel/framework/composer.json @@ -15,12 +15,12 @@ } ], "require": { - "php": "^7.2.5|^8.0", + "php": "^7.3|^8.0", "ext-json": "*", "ext-mbstring": "*", "ext-openssl": "*", "doctrine/inflector": "^1.4|^2.0", - "dragonmantank/cron-expression": "^2.3.1", + "dragonmantank/cron-expression": "^3.0.2", "egulias/email-validator": "^2.1.10", "league/commonmark": "^1.3", "league/flysystem": "^1.1", @@ -29,20 +29,19 @@ "opis/closure": "^3.6", "psr/container": "^1.0", "psr/simple-cache": "^1.0", - "ramsey/uuid": "^3.7|^4.0", + "ramsey/uuid": "^4.0", "swiftmailer/swiftmailer": "^6.0", - "symfony/console": "^5.0", - "symfony/error-handler": "^5.0", - "symfony/finder": "^5.0", - "symfony/http-foundation": "^5.0", - "symfony/http-kernel": "^5.0", - "symfony/mime": "^5.0", - "symfony/polyfill-php73": "^1.17", - "symfony/process": "^5.0", - "symfony/routing": "^5.0", - "symfony/var-dumper": "^5.0", + "symfony/console": "^5.1.4", + "symfony/error-handler": "^5.1.4", + "symfony/finder": "^5.1.4", + "symfony/http-foundation": "^5.1.4", + "symfony/http-kernel": "^5.1.4", + "symfony/mime": "^5.1.4", + "symfony/process": "^5.1.4", + "symfony/routing": "^5.1.4", + "symfony/var-dumper": "^5.1.4", "tijsverkoyen/css-to-inline-styles": "^2.2.2", - "vlucas/phpdotenv": "^4.0", + "vlucas/phpdotenv": "^5.2", "voku/portable-ascii": "^1.4.8" }, "replace": { @@ -50,6 +49,7 @@ "illuminate/broadcasting": "self.version", "illuminate/bus": "self.version", "illuminate/cache": "self.version", + "illuminate/collections": "self.version", "illuminate/config": "self.version", "illuminate/console": "self.version", "illuminate/container": "self.version", @@ -62,6 +62,7 @@ "illuminate/hashing": "self.version", "illuminate/http": "self.version", "illuminate/log": "self.version", + "illuminate/macroable": "self.version", "illuminate/mail": "self.version", "illuminate/notifications": "self.version", "illuminate/pagination": "self.version", @@ -78,17 +79,16 @@ }, "require-dev": { "aws/aws-sdk-php": "^3.155", - "doctrine/dbal": "^2.6", + "doctrine/dbal": "^2.6|^3.0", "filp/whoops": "^2.8", - "guzzlehttp/guzzle": "^6.3.1|^7.0.1", + "guzzlehttp/guzzle": "^6.5.5|^7.0.1", "league/flysystem-cached-adapter": "^1.0", - "mockery/mockery": "~1.3.3|^1.4.2", - "moontoast/math": "^1.1", - "orchestra/testbench-core": "^5.8", + "mockery/mockery": "^1.4.2", + "orchestra/testbench-core": "^6.8", "pda/pheanstalk": "^4.0", - "phpunit/phpunit": "^8.4|^9.3.3", + "phpunit/phpunit": "^8.5.8|^9.3.3", "predis/predis": "^1.1.1", - "symfony/cache": "^5.0" + "symfony/cache": "^5.1.4" }, "provide": { "psr/container-implementation": "1.0" @@ -98,11 +98,14 @@ }, "autoload": { "files": [ + "src/Illuminate/Collections/helpers.php", + "src/Illuminate/Events/functions.php", "src/Illuminate/Foundation/helpers.php", "src/Illuminate/Support/helpers.php" ], "psr-4": { - "Illuminate\\": "src/Illuminate/" + "Illuminate\\": "src/Illuminate/", + "Illuminate\\Support\\": ["src/Illuminate/Macroable/", "src/Illuminate/Collections/"] } }, "autoload-dev": { @@ -115,7 +118,7 @@ }, "extra": { "branch-alias": { - "dev-master": "7.x-dev" + "dev-master": "8.x-dev" } }, "suggest": { @@ -126,24 +129,24 @@ "ext-posix": "Required to use all features of the queue worker.", "ext-redis": "Required to use the Redis cache and queue drivers (^4.0|^5.0).", "aws/aws-sdk-php": "Required to use the SQS queue driver, DynamoDb failed job storage and SES mail driver (^3.155).", - "doctrine/dbal": "Required to rename columns and drop SQLite columns (^2.6).", + "brianium/paratest": "Required to run tests in parallel (^6.0).", + "doctrine/dbal": "Required to rename columns and drop SQLite columns (^2.6|^3.0).", "filp/whoops": "Required for friendly error pages in development (^2.8).", "fakerphp/faker": "Required to use the eloquent factory builder (^1.9.1).", - "guzzlehttp/guzzle": "Required to use the HTTP Client, Mailgun mail driver and the ping methods on schedules (^6.3.1|^7.0.1).", + "guzzlehttp/guzzle": "Required to use the HTTP Client, Mailgun mail driver and the ping methods on schedules (^6.5.5|^7.0.1).", "laravel/tinker": "Required to use the tinker console command (^2.0).", "league/flysystem-aws-s3-v3": "Required to use the Flysystem S3 driver (^1.0).", "league/flysystem-cached-adapter": "Required to use the Flysystem cache (^1.0).", "league/flysystem-sftp": "Required to use the Flysystem SFTP driver (^1.0).", - "mockery/mockery": "Required to use mocking (~1.3.3|^1.4.2).", - "moontoast/math": "Required to use ordered UUIDs (^1.1).", + "mockery/mockery": "Required to use mocking (^1.4.2).", "nyholm/psr7": "Required to use PSR-7 bridging features (^1.2).", "pda/pheanstalk": "Required to use the beanstalk queue driver (^4.0).", - "phpunit/phpunit": "Required to use assertions and run tests (^8.4|^9.3.3).", + "phpunit/phpunit": "Required to use assertions and run tests (^8.5.8|^9.3.3).", "predis/predis": "Required to use the predis connector (^1.1.2).", "psr/http-message": "Required to allow Storage::put to accept a StreamInterface (^1.0).", - "pusher/pusher-php-server": "Required to use the Pusher broadcast driver (^4.0).", - "symfony/cache": "Required to PSR-6 cache bridge (^5.0).", - "symfony/filesystem": "Required to create relative storage directory symbolic links (^5.0).", + "pusher/pusher-php-server": "Required to use the Pusher broadcast driver (^4.0|^5.0|^6.0).", + "symfony/cache": "Required to PSR-6 cache bridge (^5.1.4).", + "symfony/filesystem": "Required to enable support for relative symbolic links (^5.1.4).", "symfony/psr-http-message-bridge": "Required to use PSR-7 bridging features (^2.0).", "wildbit/swiftmailer-postmark": "Required to use Postmark mail driver (^3.0)." }, diff --git a/vendor/laravel/framework/src/Illuminate/Auth/Access/Events/GateEvaluated.php b/vendor/laravel/framework/src/Illuminate/Auth/Access/Events/GateEvaluated.php new file mode 100644 index 000000000..f77a9c84c --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Auth/Access/Events/GateEvaluated.php @@ -0,0 +1,51 @@ +user = $user; + $this->ability = $ability; + $this->result = $result; + $this->arguments = $arguments; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Auth/Access/Gate.php b/vendor/laravel/framework/src/Illuminate/Auth/Access/Gate.php index 8c955b462..0bcc0e358 100644 --- a/vendor/laravel/framework/src/Illuminate/Auth/Access/Gate.php +++ b/vendor/laravel/framework/src/Illuminate/Auth/Access/Gate.php @@ -5,7 +5,9 @@ namespace Illuminate\Auth\Access; use Exception; use Illuminate\Contracts\Auth\Access\Gate as GateContract; use Illuminate\Contracts\Container\Container; +use Illuminate\Contracts\Events\Dispatcher; use Illuminate\Support\Arr; +use Illuminate\Support\Collection; use Illuminate\Support\Str; use InvalidArgumentException; use ReflectionClass; @@ -373,9 +375,11 @@ class Gate implements GateContract // After calling the authorization callback, we will call the "after" callbacks // that are registered with the Gate, which allows a developer to do logging // if that is required for this application. Then we'll return the result. - return $this->callAfterCallbacks( + return tap($this->callAfterCallbacks( $user, $ability, $arguments, $result - ); + ), function ($result) use ($user, $ability, $arguments) { + $this->dispatchGateEvaluatedEvent($user, $ability, $arguments, $result); + }); } /** @@ -518,6 +522,24 @@ class Gate implements GateContract return $result; } + /** + * Dispatch a gate evaluation event. + * + * @param \Illuminate\Contracts\Auth\Authenticatable|null $user + * @param string $ability + * @param array $arguments + * @param bool|null $result + * @return void + */ + protected function dispatchGateEvaluatedEvent($user, $ability, array $arguments, $result) + { + if ($this->container->bound(Dispatcher::class)) { + $this->container->make(Dispatcher::class)->dispatch( + new Events\GateEvaluated($user, $ability, $result, $arguments) + ); + } + } + /** * Resolve the callable for the given ability and arguments. * @@ -599,7 +621,15 @@ class Gate implements GateContract $classDirname = str_replace('/', '\\', dirname(str_replace('\\', '/', $class))); - return [$classDirname.'\\Policies\\'.class_basename($class).'Policy']; + $classDirnameSegments = explode('\\', $classDirname); + + return Arr::wrap(Collection::times(count($classDirnameSegments), function ($index) use ($class, $classDirnameSegments) { + $classDirname = implode('\\', array_slice($classDirnameSegments, 0, $index)); + + return $classDirname.'\\Policies\\'.class_basename($class).'Policy'; + })->reverse()->values()->first(function ($class) { + return class_exists($class); + }) ?: [$classDirname.'\\Policies\\'.class_basename($class).'Policy']); } /** @@ -770,4 +800,17 @@ class Gate implements GateContract { return $this->policies; } + + /** + * Set the container instance used by the gate. + * + * @param \Illuminate\Contracts\Container\Container $container + * @return $this + */ + public function setContainer(Container $container) + { + $this->container = $container; + + return $this; + } } diff --git a/vendor/laravel/framework/src/Illuminate/Auth/AuthManager.php b/vendor/laravel/framework/src/Illuminate/Auth/AuthManager.php index ebbd7f5f1..823b96ca3 100755 --- a/vendor/laravel/framework/src/Illuminate/Auth/AuthManager.php +++ b/vendor/laravel/framework/src/Illuminate/Auth/AuthManager.php @@ -295,6 +295,31 @@ class AuthManager implements FactoryContract return count($this->guards) > 0; } + /** + * Forget all of the resolved guard instances. + * + * @return $this + */ + public function forgetGuards() + { + $this->guards = []; + + return $this; + } + + /** + * Set the application instance used by the manager. + * + * @param \Illuminate\Contracts\Foundation\Application $app + * @return $this + */ + public function setApplication($app) + { + $this->app = $app; + + return $this; + } + /** * Dynamically call the default driver instance. * diff --git a/vendor/laravel/framework/src/Illuminate/Auth/AuthServiceProvider.php b/vendor/laravel/framework/src/Illuminate/Auth/AuthServiceProvider.php index 7a6b41212..9c17edfa1 100755 --- a/vendor/laravel/framework/src/Illuminate/Auth/AuthServiceProvider.php +++ b/vendor/laravel/framework/src/Illuminate/Auth/AuthServiceProvider.php @@ -35,11 +35,6 @@ class AuthServiceProvider extends ServiceProvider protected function registerAuthenticator() { $this->app->singleton('auth', function ($app) { - // Once the authentication service has actually been requested by the developer - // we will set a variable in the application indicating such. This helps us - // know that we need to set any queued cookies in the after event later. - $app['auth.loaded'] = true; - return new AuthManager($app); }); @@ -55,11 +50,9 @@ class AuthServiceProvider extends ServiceProvider */ protected function registerUserResolver() { - $this->app->bind( - AuthenticatableContract::class, function ($app) { - return call_user_func($app['auth']->userResolver()); - } - ); + $this->app->bind(AuthenticatableContract::class, function ($app) { + return call_user_func($app['auth']->userResolver()); + }); } /** @@ -83,15 +76,13 @@ class AuthServiceProvider extends ServiceProvider */ protected function registerRequirePassword() { - $this->app->bind( - RequirePassword::class, function ($app) { - return new RequirePassword( - $app[ResponseFactory::class], - $app[UrlGenerator::class], - $app['config']->get('auth.password_timeout') - ); - } - ); + $this->app->bind(RequirePassword::class, function ($app) { + return new RequirePassword( + $app[ResponseFactory::class], + $app[UrlGenerator::class], + $app['config']->get('auth.password_timeout') + ); + }); } /** @@ -116,11 +107,8 @@ class AuthServiceProvider extends ServiceProvider protected function registerEventRebindHandler() { $this->app->rebinding('events', function ($app, $dispatcher) { - if (! $app->resolved('auth')) { - return; - } - - if ($app['auth']->hasResolvedGuards() === false) { + if (! $app->resolved('auth') || + $app['auth']->hasResolvedGuards() === false) { return; } diff --git a/vendor/laravel/framework/src/Illuminate/Auth/Authenticatable.php b/vendor/laravel/framework/src/Illuminate/Auth/Authenticatable.php index d7578a3dc..f1c011591 100644 --- a/vendor/laravel/framework/src/Illuminate/Auth/Authenticatable.php +++ b/vendor/laravel/framework/src/Illuminate/Auth/Authenticatable.php @@ -31,6 +31,16 @@ trait Authenticatable return $this->{$this->getAuthIdentifierName()}; } + /** + * Get the unique broadcast identifier for the user. + * + * @return mixed + */ + public function getAuthIdentifierForBroadcasting() + { + return $this->getAuthIdentifier(); + } + /** * Get the password for the user. * diff --git a/vendor/laravel/framework/src/Illuminate/Auth/Console/stubs/make/views/layouts/app.stub b/vendor/laravel/framework/src/Illuminate/Auth/Console/stubs/make/views/layouts/app.stub index 9224ba381..d1822366d 100644 --- a/vendor/laravel/framework/src/Illuminate/Auth/Console/stubs/make/views/layouts/app.stub +++ b/vendor/laravel/framework/src/Illuminate/Auth/Console/stubs/make/views/layouts/app.stub @@ -13,8 +13,8 @@ - - + + diff --git a/vendor/laravel/framework/src/Illuminate/Auth/GuardHelpers.php b/vendor/laravel/framework/src/Illuminate/Auth/GuardHelpers.php index 4d5328c6b..aa9ebf9ec 100644 --- a/vendor/laravel/framework/src/Illuminate/Auth/GuardHelpers.php +++ b/vendor/laravel/framework/src/Illuminate/Auth/GuardHelpers.php @@ -25,7 +25,7 @@ trait GuardHelpers protected $provider; /** - * Determine if current user is authenticated. If not, throw an exception. + * Determine if the current user is authenticated. If not, throw an exception. * * @return \Illuminate\Contracts\Auth\Authenticatable * diff --git a/vendor/laravel/framework/src/Illuminate/Auth/Middleware/EnsureEmailIsVerified.php b/vendor/laravel/framework/src/Illuminate/Auth/Middleware/EnsureEmailIsVerified.php index 1f73e576a..8f2b33ae5 100644 --- a/vendor/laravel/framework/src/Illuminate/Auth/Middleware/EnsureEmailIsVerified.php +++ b/vendor/laravel/framework/src/Illuminate/Auth/Middleware/EnsureEmailIsVerified.php @@ -5,6 +5,7 @@ namespace Illuminate\Auth\Middleware; use Closure; use Illuminate\Contracts\Auth\MustVerifyEmail; use Illuminate\Support\Facades\Redirect; +use Illuminate\Support\Facades\URL; class EnsureEmailIsVerified { @@ -14,7 +15,7 @@ class EnsureEmailIsVerified * @param \Illuminate\Http\Request $request * @param \Closure $next * @param string|null $redirectToRoute - * @return \Illuminate\Http\Response|\Illuminate\Http\RedirectResponse + * @return \Illuminate\Http\Response|\Illuminate\Http\RedirectResponse|null */ public function handle($request, Closure $next, $redirectToRoute = null) { @@ -23,7 +24,7 @@ class EnsureEmailIsVerified ! $request->user()->hasVerifiedEmail())) { return $request->expectsJson() ? abort(403, 'Your email address is not verified.') - : Redirect::route($redirectToRoute ?: 'verification.notice'); + : Redirect::guest(URL::route($redirectToRoute ?: 'verification.notice')); } return $next($request); diff --git a/vendor/laravel/framework/src/Illuminate/Auth/Notifications/ResetPassword.php b/vendor/laravel/framework/src/Illuminate/Auth/Notifications/ResetPassword.php index 05d010436..00042d19c 100644 --- a/vendor/laravel/framework/src/Illuminate/Auth/Notifications/ResetPassword.php +++ b/vendor/laravel/framework/src/Illuminate/Auth/Notifications/ResetPassword.php @@ -72,6 +72,17 @@ class ResetPassword extends Notification ], false)); } + return $this->buildMailMessage($url); + } + + /** + * Get the reset password notification mail message for the given URL. + * + * @param string $url + * @return \Illuminate\Notifications\Messages\MailMessage + */ + protected function buildMailMessage($url) + { return (new MailMessage) ->subject(Lang::get('Reset Password Notification')) ->line(Lang::get('You are receiving this email because we received a password reset request for your account.')) diff --git a/vendor/laravel/framework/src/Illuminate/Auth/Notifications/VerifyEmail.php b/vendor/laravel/framework/src/Illuminate/Auth/Notifications/VerifyEmail.php index f746685fc..7a5cf9164 100644 --- a/vendor/laravel/framework/src/Illuminate/Auth/Notifications/VerifyEmail.php +++ b/vendor/laravel/framework/src/Illuminate/Auth/Notifications/VerifyEmail.php @@ -11,6 +11,13 @@ use Illuminate\Support\Facades\URL; class VerifyEmail extends Notification { + /** + * The callback that should be used to create the verify email URL. + * + * @var \Closure|null + */ + public static $createUrlCallback; + /** * The callback that should be used to build the mail message. * @@ -43,10 +50,21 @@ class VerifyEmail extends Notification return call_user_func(static::$toMailCallback, $notifiable, $verificationUrl); } + return $this->buildMailMessage($verificationUrl); + } + + /** + * Get the verify email notification mail message for the given URL. + * + * @param string $url + * @return \Illuminate\Notifications\Messages\MailMessage + */ + protected function buildMailMessage($url) + { return (new MailMessage) ->subject(Lang::get('Verify Email Address')) ->line(Lang::get('Please click the button below to verify your email address.')) - ->action(Lang::get('Verify Email Address'), $verificationUrl) + ->action(Lang::get('Verify Email Address'), $url) ->line(Lang::get('If you did not create an account, no further action is required.')); } @@ -58,6 +76,10 @@ class VerifyEmail extends Notification */ protected function verificationUrl($notifiable) { + if (static::$createUrlCallback) { + return call_user_func(static::$createUrlCallback, $notifiable); + } + return URL::temporarySignedRoute( 'verification.verify', Carbon::now()->addMinutes(Config::get('auth.verification.expire', 60)), @@ -68,6 +90,17 @@ class VerifyEmail extends Notification ); } + /** + * Set a callback that should be used when creating the email verification URL. + * + * @param \Closure $callback + * @return void + */ + public static function createUrlUsing($callback) + { + static::$createUrlCallback = $callback; + } + /** * Set a callback that should be used when building the notification mail message. * diff --git a/vendor/laravel/framework/src/Illuminate/Auth/Passwords/PasswordBroker.php b/vendor/laravel/framework/src/Illuminate/Auth/Passwords/PasswordBroker.php index 662f71e27..cbbc897ab 100755 --- a/vendor/laravel/framework/src/Illuminate/Auth/Passwords/PasswordBroker.php +++ b/vendor/laravel/framework/src/Illuminate/Auth/Passwords/PasswordBroker.php @@ -42,9 +42,10 @@ class PasswordBroker implements PasswordBrokerContract * Send a password reset link to a user. * * @param array $credentials + * @param \Closure|null $callback * @return string */ - public function sendResetLink(array $credentials) + public function sendResetLink(array $credentials, Closure $callback = null) { // First we will check to see if we found a user at the given credentials and // if we did not we will redirect back to this current URI with a piece of @@ -59,12 +60,16 @@ class PasswordBroker implements PasswordBrokerContract return static::RESET_THROTTLED; } - // Once we have the reset token, we are ready to send the message out to this - // user with a link to reset their password. We will then redirect back to - // the current URI having nothing set in the session to indicate errors. - $user->sendPasswordResetNotification( - $this->tokens->create($user) - ); + $token = $this->tokens->create($user); + + if ($callback) { + $callback($user, $token); + } else { + // Once we have the reset token, we are ready to send the message out to this + // user with a link to reset their password. We will then redirect back to + // the current URI having nothing set in the session to indicate errors. + $user->sendPasswordResetNotification($token); + } return static::RESET_LINK_SENT; } diff --git a/vendor/laravel/framework/src/Illuminate/Auth/SessionGuard.php b/vendor/laravel/framework/src/Illuminate/Auth/SessionGuard.php index 4db498784..344f892e4 100644 --- a/vendor/laravel/framework/src/Illuminate/Auth/SessionGuard.php +++ b/vendor/laravel/framework/src/Illuminate/Auth/SessionGuard.php @@ -17,9 +17,11 @@ use Illuminate\Contracts\Auth\UserProvider; use Illuminate\Contracts\Cookie\QueueingFactory as CookieJar; use Illuminate\Contracts\Events\Dispatcher; use Illuminate\Contracts\Session\Session; +use Illuminate\Support\Arr; use Illuminate\Support\Facades\Hash; use Illuminate\Support\Str; use Illuminate\Support\Traits\Macroable; +use InvalidArgumentException; use RuntimeException; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpKernel\Exception\UnauthorizedHttpException; @@ -29,7 +31,7 @@ class SessionGuard implements StatefulGuard, SupportsBasicAuth use GuardHelpers, Macroable; /** - * The name of the Guard. Typically "session". + * The name of the guard. Typically "web". * * Corresponds to guard name in authentication configuration. * @@ -320,7 +322,7 @@ class SessionGuard implements StatefulGuard, SupportsBasicAuth } /** - * Get the credential array for a HTTP Basic request. + * Get the credential array for an HTTP Basic request. * * @param \Symfony\Component\HttpFoundation\Request $request * @param string $field @@ -373,6 +375,34 @@ class SessionGuard implements StatefulGuard, SupportsBasicAuth return false; } + /** + * Attempt to authenticate a user with credentials and additional callbacks. + * + * @param array $credentials + * @param array|callable $callbacks + * @param false $remember + * @return bool + */ + public function attemptWhen(array $credentials = [], $callbacks = null, $remember = false) + { + $this->fireAttemptEvent($credentials, $remember); + + $this->lastAttempted = $user = $this->provider->retrieveByCredentials($credentials); + + // This method does the exact same thing as attempt, but also executes callbacks after + // the user is retrieved and validated. If one of the callbacks returns falsy we do + // not login the user. Instead, we will fail the specific authentication attempt. + if ($this->hasValidCredentials($user, $credentials) && $this->shouldLogin($callbacks, $user)) { + $this->login($user, $remember); + + return true; + } + + $this->fireFailedEvent($user, $credentials); + + return false; + } + /** * Determine if the user matches the credentials. * @@ -391,6 +421,24 @@ class SessionGuard implements StatefulGuard, SupportsBasicAuth return $validated; } + /** + * Determine if the user should login by executing the given callbacks. + * + * @param array|callable|null $callbacks + * @param \Illuminate\Contracts\Auth\Authenticatable $user + * @return bool + */ + protected function shouldLogin($callbacks, AuthenticatableContract $user) + { + foreach (Arr::wrap($callbacks) as $callback) { + if (! $callback($user, $this)) { + return false; + } + } + + return true; + } + /** * Log the given user ID into the application. * @@ -517,6 +565,34 @@ class SessionGuard implements StatefulGuard, SupportsBasicAuth $this->loggedOut = true; } + /** + * Log the user out of the application on their current device only. + * + * This method does not cycle the "remember" token. + * + * @return void + */ + public function logoutCurrentDevice() + { + $user = $this->user(); + + $this->clearUserDataFromStorage(); + + // If we have an event dispatcher instance, we can fire off the logout event + // so any further processing can be done. This allows the developer to be + // listening for anytime a user signs out of this application manually. + if (isset($this->events)) { + $this->events->dispatch(new CurrentDeviceLogout($this->name, $user)); + } + + // Once we have fired the logout event we will clear the users out of memory + // so they are no longer available as the user is no longer considered as + // being signed into this application and should not be available here. + $this->user = null; + + $this->loggedOut = true; + } + /** * Remove the user data from the session and cookies. * @@ -545,32 +621,6 @@ class SessionGuard implements StatefulGuard, SupportsBasicAuth $this->provider->updateRememberToken($user, $token); } - /** - * Log the user out of the application on their current device only. - * - * @return void - */ - public function logoutCurrentDevice() - { - $user = $this->user(); - - $this->clearUserDataFromStorage(); - - // If we have an event dispatcher instance, we can fire off the logout event - // so any further processing can be done. This allows the developer to be - // listening for anytime a user signs out of this application manually. - if (isset($this->events)) { - $this->events->dispatch(new CurrentDeviceLogout($this->name, $user)); - } - - // Once we have fired the logout event we will clear the users out of memory - // so they are no longer available as the user is no longer considered as - // being signed into this application and should not be available here. - $this->user = null; - - $this->loggedOut = true; - } - /** * Invalidate other sessions for the current user. * @@ -579,6 +629,8 @@ class SessionGuard implements StatefulGuard, SupportsBasicAuth * @param string $password * @param string $attribute * @return bool|null + * + * @throws \Illuminate\Auth\AuthenticationException */ public function logoutOtherDevices($password, $attribute = 'password') { @@ -586,9 +638,7 @@ class SessionGuard implements StatefulGuard, SupportsBasicAuth return; } - $result = tap($this->user()->forceFill([ - $attribute => Hash::make($password), - ]))->save(); + $result = $this->rehashUserPassword($password, $attribute); if ($this->recaller() || $this->getCookieJar()->hasQueued($this->getRecallerName())) { @@ -600,6 +650,26 @@ class SessionGuard implements StatefulGuard, SupportsBasicAuth return $result; } + /** + * Rehash the current user's password. + * + * @param string $password + * @param string $attribute + * @return bool|null + * + * @throws \InvalidArgumentException + */ + protected function rehashUserPassword($password, $attribute) + { + if (! Hash::check($password, $this->user()->{$attribute})) { + throw new InvalidArgumentException('The given password does not match the current password.'); + } + + return tap($this->user()->forceFill([ + $attribute => Hash::make($password), + ]))->save(); + } + /** * Register an authentication attempt event listener. * diff --git a/vendor/laravel/framework/src/Illuminate/Auth/composer.json b/vendor/laravel/framework/src/Illuminate/Auth/composer.json index 7ef7fccbc..842066cde 100644 --- a/vendor/laravel/framework/src/Illuminate/Auth/composer.json +++ b/vendor/laravel/framework/src/Illuminate/Auth/composer.json @@ -14,11 +14,13 @@ } ], "require": { - "php": "^7.2.5|^8.0", - "illuminate/contracts": "^7.0", - "illuminate/http": "^7.0", - "illuminate/queue": "^7.0", - "illuminate/support": "^7.0" + "php": "^7.3|^8.0", + "illuminate/collections": "^8.0", + "illuminate/contracts": "^8.0", + "illuminate/http": "^8.0", + "illuminate/macroable": "^8.0", + "illuminate/queue": "^8.0", + "illuminate/support": "^8.0" }, "autoload": { "psr-4": { @@ -27,13 +29,13 @@ }, "extra": { "branch-alias": { - "dev-master": "7.x-dev" + "dev-master": "8.x-dev" } }, "suggest": { - "illuminate/console": "Required to use the auth:clear-resets command (^7.0).", - "illuminate/queue": "Required to fire login / logout events (^7.0).", - "illuminate/session": "Required to use the session based guard (^7.0)." + "illuminate/console": "Required to use the auth:clear-resets command (^8.0).", + "illuminate/queue": "Required to fire login / logout events (^8.0).", + "illuminate/session": "Required to use the session based guard (^8.0)." }, "config": { "sort-packages": true diff --git a/vendor/laravel/framework/src/Illuminate/Broadcasting/BroadcastEvent.php b/vendor/laravel/framework/src/Illuminate/Broadcasting/BroadcastEvent.php index 775df7805..e9c0897a5 100644 --- a/vendor/laravel/framework/src/Illuminate/Broadcasting/BroadcastEvent.php +++ b/vendor/laravel/framework/src/Illuminate/Broadcasting/BroadcastEvent.php @@ -46,6 +46,7 @@ class BroadcastEvent implements ShouldQueue $this->event = $event; $this->tries = property_exists($event, 'tries') ? $event->tries : null; $this->timeout = property_exists($event, 'timeout') ? $event->timeout : null; + $this->afterCommit = property_exists($event, 'afterCommit') ? $event->afterCommit : null; } /** diff --git a/vendor/laravel/framework/src/Illuminate/Broadcasting/BroadcastManager.php b/vendor/laravel/framework/src/Illuminate/Broadcasting/BroadcastManager.php index 3be0500d9..833a19948 100644 --- a/vendor/laravel/framework/src/Illuminate/Broadcasting/BroadcastManager.php +++ b/vendor/laravel/framework/src/Illuminate/Broadcasting/BroadcastManager.php @@ -2,7 +2,9 @@ namespace Illuminate\Broadcasting; +use Ably\AblyRest; use Closure; +use Illuminate\Broadcasting\Broadcasters\AblyBroadcaster; use Illuminate\Broadcasting\Broadcasters\LogBroadcaster; use Illuminate\Broadcasting\Broadcasters\NullBroadcaster; use Illuminate\Broadcasting\Broadcasters\PusherBroadcaster; @@ -70,7 +72,7 @@ class BroadcastManager implements FactoryContract $router->match( ['get', 'post'], '/broadcasting/auth', '\\'.BroadcastController::class.'@authenticate' - ); + )->withoutMiddleware([\Illuminate\Foundation\Http\Middleware\VerifyCsrfToken::class]); }); } @@ -220,6 +222,17 @@ class BroadcastManager implements FactoryContract return new PusherBroadcaster($pusher); } + /** + * Create an instance of the driver. + * + * @param array $config + * @return \Illuminate\Contracts\Broadcasting\Broadcaster + */ + protected function createAblyDriver(array $config) + { + return new AblyBroadcaster(new AblyRest($config)); + } + /** * Create an instance of the driver. * @@ -294,6 +307,19 @@ class BroadcastManager implements FactoryContract $this->app['config']['broadcasting.default'] = $name; } + /** + * Disconnect the given disk and remove from local cache. + * + * @param string|null $name + * @return void + */ + public function purge($name = null) + { + $name = $name ?? $this->getDefaultDriver(); + + unset($this->drivers[$name]); + } + /** * Register a custom driver creator Closure. * @@ -308,6 +334,41 @@ class BroadcastManager implements FactoryContract return $this; } + /** + * Get the application instance used by the manager. + * + * @return \Illuminate\Contracts\Foundation\Application + */ + public function getApplication() + { + return $this->app; + } + + /** + * Set the application instance used by the manager. + * + * @param \Illuminate\Contracts\Foundation\Application $app + * @return $this + */ + public function setApplication($app) + { + $this->app = $app; + + return $this; + } + + /** + * Forget all of the resolved driver instances. + * + * @return $this + */ + public function forgetDrivers() + { + $this->drivers = []; + + return $this; + } + /** * Dynamically call the default driver instance. * diff --git a/vendor/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/AblyBroadcaster.php b/vendor/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/AblyBroadcaster.php new file mode 100644 index 000000000..426aa747b --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/AblyBroadcaster.php @@ -0,0 +1,206 @@ +ably = $ably; + } + + /** + * Authenticate the incoming request for a given channel. + * + * @param \Illuminate\Http\Request $request + * @return mixed + * + * @throws \Symfony\Component\HttpKernel\Exception\AccessDeniedHttpException + */ + public function auth($request) + { + $channelName = $this->normalizeChannelName($request->channel_name); + + if (empty($request->channel_name) || + ($this->isGuardedChannel($request->channel_name) && + ! $this->retrieveUser($request, $channelName))) { + throw new AccessDeniedHttpException; + } + + return parent::verifyUserCanAccessChannel( + $request, $channelName + ); + } + + /** + * Return the valid authentication response. + * + * @param \Illuminate\Http\Request $request + * @param mixed $result + * @return mixed + */ + public function validAuthenticationResponse($request, $result) + { + if (Str::startsWith($request->channel_name, 'private')) { + $signature = $this->generateAblySignature( + $request->channel_name, $request->socket_id + ); + + return ['auth' => $this->getPublicToken().':'.$signature]; + } + + $channelName = $this->normalizeChannelName($request->channel_name); + + $user = $this->retrieveUser($request, $channelName); + + $broadcastIdentifier = method_exists($user, 'getAuthIdentifierForBroadcasting') + ? $user->getAuthIdentifierForBroadcasting() + : $user->getAuthIdentifier(); + + $signature = $this->generateAblySignature( + $request->channel_name, + $request->socket_id, + $userData = array_filter([ + 'user_id' => (string) $broadcastIdentifier, + 'user_info' => $result, + ]) + ); + + return [ + 'auth' => $this->getPublicToken().':'.$signature, + 'channel_data' => json_encode($userData), + ]; + } + + /** + * Generate the signature needed for Ably authentication headers. + * + * @param string $channelName + * @param string $socketId + * @param array|null $userData + * @return string + */ + public function generateAblySignature($channelName, $socketId, $userData = null) + { + return hash_hmac( + 'sha256', + sprintf('%s:%s%s', $socketId, $channelName, $userData ? ':'.json_encode($userData) : ''), + $this->getPrivateToken(), + ); + } + + /** + * Broadcast the given event. + * + * @param array $channels + * @param string $event + * @param array $payload + * @return void + */ + public function broadcast(array $channels, $event, array $payload = []) + { + foreach ($this->formatChannels($channels) as $channel) { + $this->ably->channels->get($channel)->publish($event, $payload); + } + } + + /** + * Return true if the channel is protected by authentication. + * + * @param string $channel + * @return bool + */ + public function isGuardedChannel($channel) + { + return Str::startsWith($channel, ['private-', 'presence-']); + } + + /** + * Remove prefix from channel name. + * + * @param string $channel + * @return string + */ + public function normalizeChannelName($channel) + { + if ($this->isGuardedChannel($channel)) { + return Str::startsWith($channel, 'private-') + ? Str::replaceFirst('private-', '', $channel) + : Str::replaceFirst('presence-', '', $channel); + } + + return $channel; + } + + /** + * Format the channel array into an array of strings. + * + * @param array $channels + * @return array + */ + protected function formatChannels(array $channels) + { + return array_map(function ($channel) { + $channel = (string) $channel; + + if (Str::startsWith($channel, ['private-', 'presence-'])) { + return Str::startsWith($channel, 'private-') + ? Str::replaceFirst('private-', 'private:', $channel) + : Str::replaceFirst('presence-', 'presence:', $channel); + } + + return 'public:'.$channel; + }, $channels); + } + + /** + * Get the public token value from the Ably key. + * + * @return mixed + */ + protected function getPublicToken() + { + return Str::before($this->ably->options->key, ':'); + } + + /** + * Get the private token value from the Ably key. + * + * @return mixed + */ + protected function getPrivateToken() + { + return Str::after($this->ably->options->key, ':'); + } + + /** + * Get the underlying Ably SDK instance. + * + * @return \Ably\AblyRest + */ + public function getAbly() + { + return $this->ably; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/Broadcaster.php b/vendor/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/Broadcaster.php index d39258ff5..e48b15195 100644 --- a/vendor/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/Broadcaster.php +++ b/vendor/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/Broadcaster.php @@ -317,7 +317,7 @@ abstract class Broadcaster implements BroadcasterContract } /** - * Check if channel name from request match a pattern from registered channels. + * Check if the channel name from the request matches a pattern from registered channels. * * @param string $channel * @param string $pattern diff --git a/vendor/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/PusherBroadcaster.php b/vendor/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/PusherBroadcaster.php index c39abbd6f..6b41bc740 100644 --- a/vendor/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/PusherBroadcaster.php +++ b/vendor/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/PusherBroadcaster.php @@ -5,6 +5,7 @@ namespace Illuminate\Broadcasting\Broadcasters; use Illuminate\Broadcasting\BroadcastException; use Illuminate\Support\Arr; use Illuminate\Support\Str; +use Pusher\ApiErrorException; use Pusher\Pusher; use Symfony\Component\HttpKernel\Exception\AccessDeniedHttpException; @@ -42,8 +43,9 @@ class PusherBroadcaster extends Broadcaster { $channelName = $this->normalizeChannelName($request->channel_name); - if ($this->isGuardedChannel($request->channel_name) && - ! $this->retrieveUser($request, $channelName)) { + if (empty($request->channel_name) || + ($this->isGuardedChannel($request->channel_name) && + ! $this->retrieveUser($request, $channelName))) { throw new AccessDeniedHttpException; } @@ -69,11 +71,17 @@ class PusherBroadcaster extends Broadcaster $channelName = $this->normalizeChannelName($request->channel_name); + $user = $this->retrieveUser($request, $channelName); + + $broadcastIdentifier = method_exists($user, 'getAuthIdentifierForBroadcasting') + ? $user->getAuthIdentifierForBroadcasting() + : $user->getAuthIdentifier(); + return $this->decodePusherResponse( $request, $this->pusher->presence_auth( $request->channel_name, $request->socket_id, - $this->retrieveUser($request, $channelName)->getAuthIdentifier(), $result + $broadcastIdentifier, $result ) ); } @@ -109,20 +117,44 @@ class PusherBroadcaster extends Broadcaster { $socket = Arr::pull($payload, 'socket'); - $response = $this->pusher->trigger( - $this->formatChannels($channels), $event, $payload, $socket, true - ); + if ($this->pusherServerIsVersionFiveOrGreater()) { + $parameters = $socket !== null ? ['socket_id' => $socket] : []; - if ((is_array($response) && $response['status'] >= 200 && $response['status'] <= 299) - || $response === true) { - return; + try { + $this->pusher->trigger( + $this->formatChannels($channels), $event, $payload, $parameters + ); + } catch (ApiErrorException $e) { + throw new BroadcastException( + sprintf('Pusher error: %s.', $e->getMessage()) + ); + } + } else { + $response = $this->pusher->trigger( + $this->formatChannels($channels), $event, $payload, $socket, true + ); + + if ((is_array($response) && $response['status'] >= 200 && $response['status'] <= 299) + || $response === true) { + return; + } + + throw new BroadcastException( + ! empty($response['body']) + ? sprintf('Pusher error: %s.', $response['body']) + : 'Failed to connect to Pusher.' + ); } + } - throw new BroadcastException( - ! empty($response['body']) - ? sprintf('Pusher error: %s.', $response['body']) - : 'Failed to connect to Pusher.' - ); + /** + * Determine if the Pusher PHP server is version 5.0 or greater. + * + * @return bool + */ + protected function pusherServerIsVersionFiveOrGreater() + { + return class_exists(ApiErrorException::class); } /** @@ -134,4 +166,15 @@ class PusherBroadcaster extends Broadcaster { return $this->pusher; } + + /** + * Set the Pusher SDK instance. + * + * @param \Pusher\Pusher $pusher + * @return void + */ + public function setPusher($pusher) + { + $this->pusher = $pusher; + } } diff --git a/vendor/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/RedisBroadcaster.php b/vendor/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/RedisBroadcaster.php index 18cb0fef3..2c2dc88c3 100644 --- a/vendor/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/RedisBroadcaster.php +++ b/vendor/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/RedisBroadcaster.php @@ -20,16 +20,16 @@ class RedisBroadcaster extends Broadcaster /** * The Redis connection to use for broadcasting. * - * @var string + * @var ?string */ - protected $connection; + protected $connection = null; /** * The Redis key prefix. * * @var string */ - protected $prefix; + protected $prefix = ''; /** * Create a new broadcaster instance. @@ -60,8 +60,9 @@ class RedisBroadcaster extends Broadcaster str_replace($this->prefix, '', $request->channel_name) ); - if ($this->isGuardedChannel($request->channel_name) && - ! $this->retrieveUser($request, $channelName)) { + if (empty($request->channel_name) || + ($this->isGuardedChannel($request->channel_name) && + ! $this->retrieveUser($request, $channelName))) { throw new AccessDeniedHttpException; } @@ -85,8 +86,14 @@ class RedisBroadcaster extends Broadcaster $channelName = $this->normalizeChannelName($request->channel_name); + $user = $this->retrieveUser($request, $channelName); + + $broadcastIdentifier = method_exists($user, 'getAuthIdentifierForBroadcasting') + ? $user->getAuthIdentifierForBroadcasting() + : $user->getAuthIdentifier(); + return json_encode(['channel_data' => [ - 'user_id' => $this->retrieveUser($request, $channelName)->getAuthIdentifier(), + 'user_id' => $broadcastIdentifier, 'user_info' => $result, ]]); } diff --git a/vendor/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/UsePusherChannelConventions.php b/vendor/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/UsePusherChannelConventions.php index 07c707ceb..690cf3d4a 100644 --- a/vendor/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/UsePusherChannelConventions.php +++ b/vendor/laravel/framework/src/Illuminate/Broadcasting/Broadcasters/UsePusherChannelConventions.php @@ -7,7 +7,7 @@ use Illuminate\Support\Str; trait UsePusherChannelConventions { /** - * Return true if channel is protected by authentication. + * Return true if the channel is protected by authentication. * * @param string $channel * @return bool diff --git a/vendor/laravel/framework/src/Illuminate/Broadcasting/composer.json b/vendor/laravel/framework/src/Illuminate/Broadcasting/composer.json index ecfc18c32..3c80b2b7c 100644 --- a/vendor/laravel/framework/src/Illuminate/Broadcasting/composer.json +++ b/vendor/laravel/framework/src/Illuminate/Broadcasting/composer.json @@ -14,13 +14,14 @@ } ], "require": { - "php": "^7.2.5|^8.0", + "php": "^7.3|^8.0", "ext-json": "*", "psr/log": "^1.0", - "illuminate/bus": "^7.0", - "illuminate/contracts": "^7.0", - "illuminate/queue": "^7.0", - "illuminate/support": "^7.0" + "illuminate/bus": "^8.0", + "illuminate/collections": "^8.0", + "illuminate/contracts": "^8.0", + "illuminate/queue": "^8.0", + "illuminate/support": "^8.0" }, "autoload": { "psr-4": { @@ -29,11 +30,11 @@ }, "extra": { "branch-alias": { - "dev-master": "7.x-dev" + "dev-master": "8.x-dev" } }, "suggest": { - "pusher/pusher-php-server": "Required to use the Pusher broadcast driver (^4.0)." + "pusher/pusher-php-server": "Required to use the Pusher broadcast driver (^4.0|^5.0|^6.0)." }, "config": { "sort-packages": true diff --git a/vendor/laravel/framework/src/Illuminate/Bus/Batch.php b/vendor/laravel/framework/src/Illuminate/Bus/Batch.php new file mode 100644 index 000000000..58c453d87 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Bus/Batch.php @@ -0,0 +1,466 @@ +queue = $queue; + $this->repository = $repository; + $this->id = $id; + $this->name = $name; + $this->totalJobs = $totalJobs; + $this->pendingJobs = $pendingJobs; + $this->failedJobs = $failedJobs; + $this->failedJobIds = $failedJobIds; + $this->options = $options; + $this->createdAt = $createdAt; + $this->cancelledAt = $cancelledAt; + $this->finishedAt = $finishedAt; + } + + /** + * Get a fresh instance of the batch represented by this ID. + * + * @return self + */ + public function fresh() + { + return $this->repository->find($this->id); + } + + /** + * Add additional jobs to the batch. + * + * @param \Illuminate\Support\Collection|array $jobs + * @return self + */ + public function add($jobs) + { + $count = 0; + + $jobs = Collection::wrap($jobs)->map(function ($job) use (&$count) { + $job = $job instanceof Closure ? CallQueuedClosure::create($job) : $job; + + if (is_array($job)) { + $count += count($job); + + return with($this->prepareBatchedChain($job), function ($chain) { + return $chain->first() + ->allOnQueue($this->options['queue'] ?? null) + ->allOnConnection($this->options['connection'] ?? null) + ->chain($chain->slice(1)->values()->all()); + }); + } else { + $job->withBatchId($this->id); + + $count++; + } + + return $job; + }); + + $this->repository->transaction(function () use ($jobs, $count) { + $this->repository->incrementTotalJobs($this->id, $count); + + $this->queue->connection($this->options['connection'] ?? null)->bulk( + $jobs->all(), + $data = '', + $this->options['queue'] ?? null + ); + }); + + return $this->fresh(); + } + + /** + * Prepare a chain that exists within the jobs being added. + * + * @param array $chain + * @return \Illuminate\Support\Collection + */ + protected function prepareBatchedChain(array $chain) + { + return collect($chain)->map(function ($job) { + $job = $job instanceof Closure ? CallQueuedClosure::create($job) : $job; + + return $job->withBatchId($this->id); + }); + } + + /** + * Get the total number of jobs that have been processed by the batch thus far. + * + * @return int + */ + public function processedJobs() + { + return $this->totalJobs - $this->pendingJobs; + } + + /** + * Get the percentage of jobs that have been processed (between 0-100). + * + * @return int + */ + public function progress() + { + return $this->totalJobs > 0 ? round(($this->processedJobs() / $this->totalJobs) * 100) : 0; + } + + /** + * Record that a job within the batch finished successfully, executing any callbacks if necessary. + * + * @param string $jobId + * @return void + */ + public function recordSuccessfulJob(string $jobId) + { + $counts = $this->decrementPendingJobs($jobId); + + if ($counts->pendingJobs === 0) { + $this->repository->markAsFinished($this->id); + } + + if ($counts->pendingJobs === 0 && $this->hasThenCallbacks()) { + $batch = $this->fresh(); + + collect($this->options['then'])->each(function ($handler) use ($batch) { + $this->invokeHandlerCallback($handler, $batch); + }); + } + + if ($counts->allJobsHaveRanExactlyOnce() && $this->hasFinallyCallbacks()) { + $batch = $this->fresh(); + + collect($this->options['finally'])->each(function ($handler) use ($batch) { + $this->invokeHandlerCallback($handler, $batch); + }); + } + } + + /** + * Decrement the pending jobs for the batch. + * + * @param string $jobId + * @return \Illuminate\Bus\UpdatedBatchJobCounts + */ + public function decrementPendingJobs(string $jobId) + { + return $this->repository->decrementPendingJobs($this->id, $jobId); + } + + /** + * Determine if the batch has finished executing. + * + * @return bool + */ + public function finished() + { + return ! is_null($this->finishedAt); + } + + /** + * Determine if the batch has "success" callbacks. + * + * @return bool + */ + public function hasThenCallbacks() + { + return isset($this->options['then']) && ! empty($this->options['then']); + } + + /** + * Determine if the batch allows jobs to fail without cancelling the batch. + * + * @return bool + */ + public function allowsFailures() + { + return Arr::get($this->options, 'allowFailures', false) === true; + } + + /** + * Determine if the batch has job failures. + * + * @return bool + */ + public function hasFailures() + { + return $this->failedJobs > 0; + } + + /** + * Record that a job within the batch failed to finish successfully, executing any callbacks if necessary. + * + * @param string $jobId + * @param \Throwable $e + * @return void + */ + public function recordFailedJob(string $jobId, $e) + { + $counts = $this->incrementFailedJobs($jobId); + + if ($counts->failedJobs === 1 && ! $this->allowsFailures()) { + $this->cancel(); + } + + if ($counts->failedJobs === 1 && $this->hasCatchCallbacks()) { + $batch = $this->fresh(); + + collect($this->options['catch'])->each(function ($handler) use ($batch, $e) { + $this->invokeHandlerCallback($handler, $batch, $e); + }); + } + + if ($counts->allJobsHaveRanExactlyOnce() && $this->hasFinallyCallbacks()) { + $batch = $this->fresh(); + + collect($this->options['finally'])->each(function ($handler) use ($batch, $e) { + $this->invokeHandlerCallback($handler, $batch, $e); + }); + } + } + + /** + * Increment the failed jobs for the batch. + * + * @param string $jobId + * @return \Illuminate\Bus\UpdatedBatchJobCounts + */ + public function incrementFailedJobs(string $jobId) + { + return $this->repository->incrementFailedJobs($this->id, $jobId); + } + + /** + * Determine if the batch has "catch" callbacks. + * + * @return bool + */ + public function hasCatchCallbacks() + { + return isset($this->options['catch']) && ! empty($this->options['catch']); + } + + /** + * Determine if the batch has "finally" callbacks. + * + * @return bool + */ + public function hasFinallyCallbacks() + { + return isset($this->options['finally']) && ! empty($this->options['finally']); + } + + /** + * Cancel the batch. + * + * @return void + */ + public function cancel() + { + $this->repository->cancel($this->id); + } + + /** + * Determine if the batch has been cancelled. + * + * @return bool + */ + public function canceled() + { + return $this->cancelled(); + } + + /** + * Determine if the batch has been cancelled. + * + * @return bool + */ + public function cancelled() + { + return ! is_null($this->cancelledAt); + } + + /** + * Delete the batch from storage. + * + * @return void + */ + public function delete() + { + $this->repository->delete($this->id); + } + + /** + * Invoke a batch callback handler. + * + * @param \Illuminate\Queue\SerializableClosure|callable $handler + * @param \Illuminate\Bus\Batch $batch + * @param \Throwable|null $e + * @return void + */ + protected function invokeHandlerCallback($handler, Batch $batch, Throwable $e = null) + { + return $handler instanceof SerializableClosure + ? $handler->__invoke($batch, $e) + : call_user_func($handler, $batch, $e); + } + + /** + * Convert the batch to an array. + * + * @return array + */ + public function toArray() + { + return [ + 'id' => $this->id, + 'name' => $this->name, + 'totalJobs' => $this->totalJobs, + 'pendingJobs' => $this->pendingJobs, + 'processedJobs' => $this->processedJobs(), + 'progress' => $this->progress(), + 'failedJobs' => $this->failedJobs, + 'options' => $this->options, + 'createdAt' => $this->createdAt, + 'cancelledAt' => $this->cancelledAt, + 'finishedAt' => $this->finishedAt, + ]; + } + + /** + * Get the JSON serializable representation of the object. + * + * @return array + */ + public function jsonSerialize() + { + return $this->toArray(); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Bus/BatchFactory.php b/vendor/laravel/framework/src/Illuminate/Bus/BatchFactory.php new file mode 100644 index 000000000..2c3a4e96c --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Bus/BatchFactory.php @@ -0,0 +1,58 @@ +queue = $queue; + } + + /** + * Create a new batch instance. + * + * @param \Illuminate\Bus\BatchRepository $repository + * @param string $id + * @param string $name + * @param int $totalJobs + * @param int $pendingJobs + * @param int $failedJobs + * @param array $failedJobIds + * @param array $options + * @param \Carbon\CarbonImmutable $createdAt + * @param \Carbon\CarbonImmutable|null $cancelledAt + * @param \Carbon\CarbonImmutable|null $finishedAt + * @return \Illuminate\Bus\Batch + */ + public function make(BatchRepository $repository, + string $id, + string $name, + int $totalJobs, + int $pendingJobs, + int $failedJobs, + array $failedJobIds, + array $options, + CarbonImmutable $createdAt, + ?CarbonImmutable $cancelledAt, + ?CarbonImmutable $finishedAt) + { + return new Batch($this->queue, $repository, $id, $name, $totalJobs, $pendingJobs, $failedJobs, $failedJobIds, $options, $createdAt, $cancelledAt, $finishedAt); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Bus/BatchRepository.php b/vendor/laravel/framework/src/Illuminate/Bus/BatchRepository.php new file mode 100644 index 000000000..098ccef20 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Bus/BatchRepository.php @@ -0,0 +1,92 @@ +batchId) { + return Container::getInstance()->make(BatchRepository::class)->find($this->batchId); + } + } + + /** + * Determine if the batch is still active and processing. + * + * @return bool + */ + public function batching() + { + $batch = $this->batch(); + + return $batch && ! $batch->cancelled(); + } + + /** + * Set the batch ID on the job. + * + * @param string $batchId + * @return $this + */ + public function withBatchId(string $batchId) + { + $this->batchId = $batchId; + + return $this; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Bus/BusServiceProvider.php b/vendor/laravel/framework/src/Illuminate/Bus/BusServiceProvider.php index 0b56aab56..6f3da09d1 100644 --- a/vendor/laravel/framework/src/Illuminate/Bus/BusServiceProvider.php +++ b/vendor/laravel/framework/src/Illuminate/Bus/BusServiceProvider.php @@ -23,6 +23,8 @@ class BusServiceProvider extends ServiceProvider implements DeferrableProvider }); }); + $this->registerBatchServices(); + $this->app->alias( Dispatcher::class, DispatcherContract::class ); @@ -32,6 +34,24 @@ class BusServiceProvider extends ServiceProvider implements DeferrableProvider ); } + /** + * Register the batch handling services. + * + * @return void + */ + protected function registerBatchServices() + { + $this->app->singleton(BatchRepository::class, DatabaseBatchRepository::class); + + $this->app->singleton(DatabaseBatchRepository::class, function ($app) { + return new DatabaseBatchRepository( + $app->make(BatchFactory::class), + $app->make('db')->connection(config('queue.batching.database')), + config('queue.batching.table', 'job_batches') + ); + }); + } + /** * Get the services provided by the provider. * @@ -43,6 +63,7 @@ class BusServiceProvider extends ServiceProvider implements DeferrableProvider Dispatcher::class, DispatcherContract::class, QueueingDispatcherContract::class, + BatchRepository::class, ]; } } diff --git a/vendor/laravel/framework/src/Illuminate/Bus/DatabaseBatchRepository.php b/vendor/laravel/framework/src/Illuminate/Bus/DatabaseBatchRepository.php new file mode 100644 index 000000000..ee544b042 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Bus/DatabaseBatchRepository.php @@ -0,0 +1,347 @@ +factory = $factory; + $this->connection = $connection; + $this->table = $table; + } + + /** + * Retrieve a list of batches. + * + * @param int $limit + * @param mixed $before + * @return \Illuminate\Bus\Batch[] + */ + public function get($limit = 50, $before = null) + { + return $this->connection->table($this->table) + ->orderByDesc('id') + ->take($limit) + ->when($before, function ($q) use ($before) { + return $q->where('id', '<', $before); + }) + ->get() + ->map(function ($batch) { + return $this->toBatch($batch); + }) + ->all(); + } + + /** + * Retrieve information about an existing batch. + * + * @param string $batchId + * @return \Illuminate\Bus\Batch|null + */ + public function find(string $batchId) + { + $batch = $this->connection->table($this->table) + ->where('id', $batchId) + ->first(); + + if ($batch) { + return $this->toBatch($batch); + } + } + + /** + * Store a new pending batch. + * + * @param \Illuminate\Bus\PendingBatch $batch + * @return \Illuminate\Bus\Batch + */ + public function store(PendingBatch $batch) + { + $id = (string) Str::orderedUuid(); + + $this->connection->table($this->table)->insert([ + 'id' => $id, + 'name' => $batch->name, + 'total_jobs' => 0, + 'pending_jobs' => 0, + 'failed_jobs' => 0, + 'failed_job_ids' => '[]', + 'options' => $this->serialize($batch->options), + 'created_at' => time(), + 'cancelled_at' => null, + 'finished_at' => null, + ]); + + return $this->find($id); + } + + /** + * Increment the total number of jobs within the batch. + * + * @param string $batchId + * @param int $amount + * @return void + */ + public function incrementTotalJobs(string $batchId, int $amount) + { + $this->connection->table($this->table)->where('id', $batchId)->update([ + 'total_jobs' => new Expression('total_jobs + '.$amount), + 'pending_jobs' => new Expression('pending_jobs + '.$amount), + 'finished_at' => null, + ]); + } + + /** + * Decrement the total number of pending jobs for the batch. + * + * @param string $batchId + * @param string $jobId + * @return \Illuminate\Bus\UpdatedBatchJobCounts + */ + public function decrementPendingJobs(string $batchId, string $jobId) + { + $values = $this->updateAtomicValues($batchId, function ($batch) use ($jobId) { + return [ + 'pending_jobs' => $batch->pending_jobs - 1, + 'failed_jobs' => $batch->failed_jobs, + 'failed_job_ids' => json_encode(array_values(array_diff(json_decode($batch->failed_job_ids, true), [$jobId]))), + ]; + }); + + return new UpdatedBatchJobCounts( + $values['pending_jobs'], + $values['failed_jobs'] + ); + } + + /** + * Increment the total number of failed jobs for the batch. + * + * @param string $batchId + * @param string $jobId + * @return \Illuminate\Bus\UpdatedBatchJobCounts + */ + public function incrementFailedJobs(string $batchId, string $jobId) + { + $values = $this->updateAtomicValues($batchId, function ($batch) use ($jobId) { + return [ + 'pending_jobs' => $batch->pending_jobs, + 'failed_jobs' => $batch->failed_jobs + 1, + 'failed_job_ids' => json_encode(array_values(array_unique(array_merge(json_decode($batch->failed_job_ids, true), [$jobId])))), + ]; + }); + + return new UpdatedBatchJobCounts( + $values['pending_jobs'], + $values['failed_jobs'] + ); + } + + /** + * Update an atomic value within the batch. + * + * @param string $batchId + * @param \Closure $callback + * @return int|null + */ + protected function updateAtomicValues(string $batchId, Closure $callback) + { + return $this->connection->transaction(function () use ($batchId, $callback) { + $batch = $this->connection->table($this->table)->where('id', $batchId) + ->lockForUpdate() + ->first(); + + return is_null($batch) ? [] : tap($callback($batch), function ($values) use ($batchId) { + $this->connection->table($this->table)->where('id', $batchId)->update($values); + }); + }); + } + + /** + * Mark the batch that has the given ID as finished. + * + * @param string $batchId + * @return void + */ + public function markAsFinished(string $batchId) + { + $this->connection->table($this->table)->where('id', $batchId)->update([ + 'finished_at' => time(), + ]); + } + + /** + * Cancel the batch that has the given ID. + * + * @param string $batchId + * @return void + */ + public function cancel(string $batchId) + { + $this->connection->table($this->table)->where('id', $batchId)->update([ + 'cancelled_at' => time(), + 'finished_at' => time(), + ]); + } + + /** + * Delete the batch that has the given ID. + * + * @param string $batchId + * @return void + */ + public function delete(string $batchId) + { + $this->connection->table($this->table)->where('id', $batchId)->delete(); + } + + /** + * Prune all of the entries older than the given date. + * + * @param \DateTimeInterface $before + * @return int + */ + public function prune(DateTimeInterface $before) + { + $query = $this->connection->table($this->table) + ->whereNotNull('finished_at') + ->where('finished_at', '<', $before->getTimestamp()); + + $totalDeleted = 0; + + do { + $deleted = $query->take(1000)->delete(); + + $totalDeleted += $deleted; + } while ($deleted !== 0); + + return $totalDeleted; + } + + /** + * Prune all of the unfinished entries older than the given date. + * + * @param \DateTimeInterface $before + * @return int + */ + public function pruneUnfinished(DateTimeInterface $before) + { + $query = $this->connection->table($this->table) + ->whereNull('finished_at') + ->where('created_at', '<', $before->getTimestamp()); + + $totalDeleted = 0; + + do { + $deleted = $query->take(1000)->delete(); + + $totalDeleted += $deleted; + } while ($deleted !== 0); + + return $totalDeleted; + } + + /** + * Execute the given Closure within a storage specific transaction. + * + * @param \Closure $callback + * @return mixed + */ + public function transaction(Closure $callback) + { + return $this->connection->transaction(function () use ($callback) { + return $callback(); + }); + } + + /** + * Serialize the given value. + * + * @param mixed $value + * @return string + */ + protected function serialize($value) + { + $serialized = serialize($value); + + return $this->connection instanceof PostgresConnection + ? base64_encode($serialized) + : $serialized; + } + + /** + * Unserialize the given value. + * + * @param string $serialized + * @return mixed + */ + protected function unserialize($serialized) + { + if ($this->connection instanceof PostgresConnection && + ! Str::contains($serialized, [':', ';'])) { + $serialized = base64_decode($serialized); + } + + return unserialize($serialized); + } + + /** + * Convert the given raw batch to a Batch object. + * + * @param object $batch + * @return \Illuminate\Bus\Batch + */ + protected function toBatch($batch) + { + return $this->factory->make( + $this, + $batch->id, + $batch->name, + (int) $batch->total_jobs, + (int) $batch->pending_jobs, + (int) $batch->failed_jobs, + json_decode($batch->failed_job_ids, true), + $this->unserialize($batch->options), + CarbonImmutable::createFromTimestamp($batch->created_at), + $batch->cancelled_at ? CarbonImmutable::createFromTimestamp($batch->cancelled_at) : $batch->cancelled_at, + $batch->finished_at ? CarbonImmutable::createFromTimestamp($batch->finished_at) : $batch->finished_at + ); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Bus/Dispatcher.php b/vendor/laravel/framework/src/Illuminate/Bus/Dispatcher.php index 9d8096209..4dc390e65 100644 --- a/vendor/laravel/framework/src/Illuminate/Bus/Dispatcher.php +++ b/vendor/laravel/framework/src/Illuminate/Bus/Dispatcher.php @@ -7,7 +7,11 @@ use Illuminate\Contracts\Bus\QueueingDispatcher; use Illuminate\Contracts\Container\Container; use Illuminate\Contracts\Queue\Queue; use Illuminate\Contracts\Queue\ShouldQueue; +use Illuminate\Foundation\Bus\PendingChain; use Illuminate\Pipeline\Pipeline; +use Illuminate\Queue\InteractsWithQueue; +use Illuminate\Queue\Jobs\SyncJob; +use Illuminate\Support\Collection; use RuntimeException; class Dispatcher implements QueueingDispatcher @@ -69,35 +73,100 @@ class Dispatcher implements QueueingDispatcher */ public function dispatch($command) { - if ($this->queueResolver && $this->commandShouldBeQueued($command)) { - return $this->dispatchToQueue($command); - } - - return $this->dispatchNow($command); + return $this->queueResolver && $this->commandShouldBeQueued($command) + ? $this->dispatchToQueue($command) + : $this->dispatchNow($command); } /** * Dispatch a command to its appropriate handler in the current process. * + * Queueable jobs will be dispatched to the "sync" queue. + * + * @param mixed $command + * @param mixed $handler + * @return mixed + */ + public function dispatchSync($command, $handler = null) + { + if ($this->queueResolver && + $this->commandShouldBeQueued($command) && + method_exists($command, 'onConnection')) { + return $this->dispatchToQueue($command->onConnection('sync')); + } + + return $this->dispatchNow($command, $handler); + } + + /** + * Dispatch a command to its appropriate handler in the current process without using the synchronous queue. + * * @param mixed $command * @param mixed $handler * @return mixed */ public function dispatchNow($command, $handler = null) { + $uses = class_uses_recursive($command); + + if (in_array(InteractsWithQueue::class, $uses) && + in_array(Queueable::class, $uses) && + ! $command->job) { + $command->setJob(new SyncJob($this->container, json_encode([]), 'sync', 'sync')); + } + if ($handler || $handler = $this->getCommandHandler($command)) { $callback = function ($command) use ($handler) { - return $handler->handle($command); + $method = method_exists($handler, 'handle') ? 'handle' : '__invoke'; + + return $handler->{$method}($command); }; } else { $callback = function ($command) { - return $this->container->call([$command, 'handle']); + $method = method_exists($command, 'handle') ? 'handle' : '__invoke'; + + return $this->container->call([$command, $method]); }; } return $this->pipeline->send($command)->through($this->pipes)->then($callback); } + /** + * Attempt to find the batch with the given ID. + * + * @param string $batchId + * @return \Illuminate\Bus\Batch|null + */ + public function findBatch(string $batchId) + { + return $this->container->make(BatchRepository::class)->find($batchId); + } + + /** + * Create a new batch of queueable jobs. + * + * @param \Illuminate\Support\Collection|array|mixed $jobs + * @return \Illuminate\Bus\PendingBatch + */ + public function batch($jobs) + { + return new PendingBatch($this->container, Collection::wrap($jobs)); + } + + /** + * Create a new chain of queueable jobs. + * + * @param \Illuminate\Support\Collection|array $jobs + * @return \Illuminate\Foundation\Bus\PendingChain + */ + public function chain($jobs) + { + $jobs = Collection::wrap($jobs); + + return new PendingChain($jobs->shift(), $jobs->toArray()); + } + /** * Determine if the given command has a handler. * @@ -140,6 +209,8 @@ class Dispatcher implements QueueingDispatcher * * @param mixed $command * @return mixed + * + * @throws \RuntimeException */ public function dispatchToQueue($command) { diff --git a/vendor/laravel/framework/src/Illuminate/Bus/Events/BatchDispatched.php b/vendor/laravel/framework/src/Illuminate/Bus/Events/BatchDispatched.php new file mode 100644 index 000000000..b9a161adb --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Bus/Events/BatchDispatched.php @@ -0,0 +1,26 @@ +batch = $batch; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Bus/PendingBatch.php b/vendor/laravel/framework/src/Illuminate/Bus/PendingBatch.php new file mode 100644 index 000000000..e9bec4862 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Bus/PendingBatch.php @@ -0,0 +1,256 @@ +container = $container; + $this->jobs = $jobs; + } + + /** + * Add jobs to the batch. + * + * @param array $jobs + * @return $this + */ + public function add($jobs) + { + $this->jobs->push($jobs); + + return $this; + } + + /** + * Add a callback to be executed after all jobs in the batch have executed successfully. + * + * @param callable $callback + * @return $this + */ + public function then($callback) + { + $this->options['then'][] = $callback instanceof Closure + ? new SerializableClosure($callback) + : $callback; + + return $this; + } + + /** + * Get the "then" callbacks that have been registered with the pending batch. + * + * @return array + */ + public function thenCallbacks() + { + return $this->options['then'] ?? []; + } + + /** + * Add a callback to be executed after the first failing job in the batch. + * + * @param callable $callback + * @return $this + */ + public function catch($callback) + { + $this->options['catch'][] = $callback instanceof Closure + ? new SerializableClosure($callback) + : $callback; + + return $this; + } + + /** + * Get the "catch" callbacks that have been registered with the pending batch. + * + * @return array + */ + public function catchCallbacks() + { + return $this->options['catch'] ?? []; + } + + /** + * Add a callback to be executed after the batch has finished executing. + * + * @param callable $callback + * @return $this + */ + public function finally($callback) + { + $this->options['finally'][] = $callback instanceof Closure + ? new SerializableClosure($callback) + : $callback; + + return $this; + } + + /** + * Get the "finally" callbacks that have been registered with the pending batch. + * + * @return array + */ + public function finallyCallbacks() + { + return $this->options['finally'] ?? []; + } + + /** + * Indicate that the batch should not be cancelled when a job within the batch fails. + * + * @param bool $allowFailures + * @return $this + */ + public function allowFailures($allowFailures = true) + { + $this->options['allowFailures'] = $allowFailures; + + return $this; + } + + /** + * Determine if the pending batch allows jobs to fail without cancelling the batch. + * + * @return bool + */ + public function allowsFailures() + { + return Arr::get($this->options, 'allowFailures', false) === true; + } + + /** + * Set the name for the batch. + * + * @param string $name + * @return $this + */ + public function name(string $name) + { + $this->name = $name; + + return $this; + } + + /** + * Specify the queue connection that the batched jobs should run on. + * + * @param string $connection + * @return $this + */ + public function onConnection(string $connection) + { + $this->options['connection'] = $connection; + + return $this; + } + + /** + * Get the connection used by the pending batch. + * + * @return string|null + */ + public function connection() + { + return $this->options['connection'] ?? null; + } + + /** + * Specify the queue that the batched jobs should run on. + * + * @param string $queue + * @return $this + */ + public function onQueue(string $queue) + { + $this->options['queue'] = $queue; + + return $this; + } + + /** + * Get the queue used by the pending batch. + * + * @return string|null + */ + public function queue() + { + return $this->options['queue'] ?? null; + } + + /** + * Dispatch the batch. + * + * @return \Illuminate\Bus\Batch + * + * @throws \Throwable + */ + public function dispatch() + { + $repository = $this->container->make(BatchRepository::class); + + try { + $batch = $repository->store($this); + + $batch = $batch->add($this->jobs); + } catch (Throwable $e) { + if (isset($batch)) { + $repository->delete($batch->id); + } + + throw $e; + } + + $this->container->make(EventDispatcher::class)->dispatch( + new BatchDispatched($batch) + ); + + return $batch; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Bus/PrunableBatchRepository.php b/vendor/laravel/framework/src/Illuminate/Bus/PrunableBatchRepository.php new file mode 100644 index 000000000..3f972553b --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Bus/PrunableBatchRepository.php @@ -0,0 +1,16 @@ +afterCommit = true; + + return $this; + } + + /** + * Indicate that the job should not wait until database transactions have been committed before dispatching. + * + * @return $this + */ + public function beforeCommit() + { + $this->afterCommit = false; + + return $this; + } + /** * Specify the middleware the job should be dispatched through. * @@ -158,6 +197,8 @@ trait Queueable * * @param mixed $job * @return string + * + * @throws \RuntimeException */ protected function serializeJob($job) { @@ -190,7 +231,21 @@ trait Queueable $next->chainConnection = $this->chainConnection; $next->chainQueue = $this->chainQueue; + $next->chainCatchCallbacks = $this->chainCatchCallbacks; })); } } + + /** + * Invoke all of the chain's failed job callbacks. + * + * @param \Throwable $e + * @return void + */ + public function invokeChainCatchCallbacks($e) + { + collect($this->chainCatchCallbacks)->each(function ($callback) use ($e) { + $callback instanceof SerializableClosure ? $callback->__invoke($e) : call_user_func($callback, $e); + }); + } } diff --git a/vendor/laravel/framework/src/Illuminate/Bus/UpdatedBatchJobCounts.php b/vendor/laravel/framework/src/Illuminate/Bus/UpdatedBatchJobCounts.php new file mode 100644 index 000000000..83d33a44f --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Bus/UpdatedBatchJobCounts.php @@ -0,0 +1,43 @@ +pendingJobs = $pendingJobs; + $this->failedJobs = $failedJobs; + } + + /** + * Determine if all jobs have run exactly once. + * + * @return bool + */ + public function allJobsHaveRanExactlyOnce() + { + return ($this->pendingJobs - $this->failedJobs) === 0; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Bus/composer.json b/vendor/laravel/framework/src/Illuminate/Bus/composer.json index 7d4a72d3d..12713a61c 100644 --- a/vendor/laravel/framework/src/Illuminate/Bus/composer.json +++ b/vendor/laravel/framework/src/Illuminate/Bus/composer.json @@ -14,10 +14,11 @@ } ], "require": { - "php": "^7.2.5|^8.0", - "illuminate/contracts": "^7.0", - "illuminate/pipeline": "^7.0", - "illuminate/support": "^7.0" + "php": "^7.3|^8.0", + "illuminate/collections": "^8.0", + "illuminate/contracts": "^8.0", + "illuminate/pipeline": "^8.0", + "illuminate/support": "^8.0" }, "autoload": { "psr-4": { @@ -26,7 +27,7 @@ }, "extra": { "branch-alias": { - "dev-master": "7.x-dev" + "dev-master": "8.x-dev" } }, "suggest": { diff --git a/vendor/laravel/framework/src/Illuminate/Cache/CacheLock.php b/vendor/laravel/framework/src/Illuminate/Cache/CacheLock.php new file mode 100644 index 000000000..310d9fb5d --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Cache/CacheLock.php @@ -0,0 +1,85 @@ +store = $store; + } + + /** + * Attempt to acquire the lock. + * + * @return bool + */ + public function acquire() + { + if (method_exists($this->store, 'add') && $this->seconds > 0) { + return $this->store->add( + $this->name, $this->owner, $this->seconds + ); + } + + if (! is_null($this->store->get($this->name))) { + return false; + } + + return ($this->seconds > 0) + ? $this->store->put($this->name, $this->owner, $this->seconds) + : $this->store->forever($this->name, $this->owner, $this->seconds); + } + + /** + * Release the lock. + * + * @return bool + */ + public function release() + { + if ($this->isOwnedByCurrentProcess()) { + return $this->store->forget($this->name); + } + + return false; + } + + /** + * Releases this lock regardless of ownership. + * + * @return void + */ + public function forceRelease() + { + $this->store->forget($this->name); + } + + /** + * Returns the owner value written into the driver for this lock. + * + * @return mixed + */ + protected function getCurrentOwner() + { + return $this->store->get($this->name); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Cache/CacheManager.php b/vendor/laravel/framework/src/Illuminate/Cache/CacheManager.php index 73f4acc35..145b3e617 100755 --- a/vendor/laravel/framework/src/Illuminate/Cache/CacheManager.php +++ b/vendor/laravel/framework/src/Illuminate/Cache/CacheManager.php @@ -199,7 +199,11 @@ class CacheManager implements FactoryContract $connection = $config['connection'] ?? 'default'; - return $this->repository(new RedisStore($redis, $this->getPrefix($config), $connection)); + $store = new RedisStore($redis, $this->getPrefix($config), $connection); + + return $this->repository( + $store->setLockConnection($config['lock_connection'] ?? $connection) + ); } /** @@ -212,15 +216,17 @@ class CacheManager implements FactoryContract { $connection = $this->app['db']->connection($config['connection'] ?? null); - return $this->repository( - new DatabaseStore( - $connection, - $config['table'], - $this->getPrefix($config), - $config['lock_table'] ?? 'cache_locks', - $config['lock_lottery'] ?? [2, 100] - ) + $store = new DatabaseStore( + $connection, + $config['table'], + $this->getPrefix($config), + $config['lock_table'] ?? 'cache_locks', + $config['lock_lottery'] ?? [2, 100] ); + + return $this->repository($store->setLockConnection( + $this->app['db']->connection($config['lock_connection'] ?? $config['connection'] ?? null) + )); } /** @@ -231,21 +237,11 @@ class CacheManager implements FactoryContract */ protected function createDynamodbDriver(array $config) { - $dynamoConfig = [ - 'region' => $config['region'], - 'version' => 'latest', - 'endpoint' => $config['endpoint'] ?? null, - ]; - - if ($config['key'] && $config['secret']) { - $dynamoConfig['credentials'] = Arr::only( - $config, ['key', 'secret', 'token'] - ); - } + $client = $this->newDynamodbClient($config); return $this->repository( new DynamoDbStore( - new DynamoDbClient($dynamoConfig), + $client, $config['table'], $config['attributes']['key'] ?? 'key', $config['attributes']['value'] ?? 'value', @@ -255,6 +251,28 @@ class CacheManager implements FactoryContract ); } + /** + * Create new DynamoDb Client instance. + * + * @return DynamoDbClient + */ + protected function newDynamodbClient(array $config) + { + $dynamoConfig = [ + 'region' => $config['region'], + 'version' => 'latest', + 'endpoint' => $config['endpoint'] ?? null, + ]; + + if (isset($config['key']) && isset($config['secret'])) { + $dynamoConfig['credentials'] = Arr::only( + $config, ['key', 'secret', 'token'] + ); + } + + return new DynamoDbClient($dynamoConfig); + } + /** * Create a new cache repository with the given implementation. * @@ -314,7 +332,11 @@ class CacheManager implements FactoryContract */ protected function getConfig($name) { - return $this->app['config']["cache.stores.{$name}"]; + if (! is_null($name) && $name !== 'null') { + return $this->app['config']["cache.stores.{$name}"]; + } + + return ['driver' => 'null']; } /** @@ -357,6 +379,19 @@ class CacheManager implements FactoryContract return $this; } + /** + * Disconnect the given driver and remove from local cache. + * + * @param string|null $name + * @return void + */ + public function purge($name = null) + { + $name = $name ?? $this->getDefaultDriver(); + + unset($this->stores[$name]); + } + /** * Register a custom driver creator Closure. * diff --git a/vendor/laravel/framework/src/Illuminate/Cache/CacheServiceProvider.php b/vendor/laravel/framework/src/Illuminate/Cache/CacheServiceProvider.php index 46fa0ae26..e0616768e 100755 --- a/vendor/laravel/framework/src/Illuminate/Cache/CacheServiceProvider.php +++ b/vendor/laravel/framework/src/Illuminate/Cache/CacheServiceProvider.php @@ -30,6 +30,8 @@ class CacheServiceProvider extends ServiceProvider implements DeferrableProvider $this->app->singleton('memcached.connector', function () { return new MemcachedConnector; }); + + $this->app->singleton(RateLimiter::class); } /** @@ -40,7 +42,7 @@ class CacheServiceProvider extends ServiceProvider implements DeferrableProvider public function provides() { return [ - 'cache', 'cache.store', 'cache.psr6', 'memcached.connector', + 'cache', 'cache.store', 'cache.psr6', 'memcached.connector', RateLimiter::class, ]; } } diff --git a/vendor/laravel/framework/src/Illuminate/Cache/Console/ClearCommand.php b/vendor/laravel/framework/src/Illuminate/Cache/Console/ClearCommand.php index aa88964d7..8a37b8b29 100755 --- a/vendor/laravel/framework/src/Illuminate/Cache/Console/ClearCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Cache/Console/ClearCommand.php @@ -116,7 +116,7 @@ class ClearCommand extends Command */ protected function tags() { - return array_filter(explode(',', $this->option('tags'))); + return array_filter(explode(',', $this->option('tags') ?? '')); } /** diff --git a/vendor/laravel/framework/src/Illuminate/Cache/DatabaseLock.php b/vendor/laravel/framework/src/Illuminate/Cache/DatabaseLock.php index 296f973bd..7fd05c191 100644 --- a/vendor/laravel/framework/src/Illuminate/Cache/DatabaseLock.php +++ b/vendor/laravel/framework/src/Illuminate/Cache/DatabaseLock.php @@ -136,4 +136,14 @@ class DatabaseLock extends Lock { return optional($this->connection->table($this->table)->where('key', $this->name)->first())->owner; } + + /** + * Get the name of the database connection being used to manage the lock. + * + * @return string + */ + public function getConnectionName() + { + return $this->connection->getName(); + } } diff --git a/vendor/laravel/framework/src/Illuminate/Cache/DatabaseStore.php b/vendor/laravel/framework/src/Illuminate/Cache/DatabaseStore.php index c868b145e..32d7a9fc0 100755 --- a/vendor/laravel/framework/src/Illuminate/Cache/DatabaseStore.php +++ b/vendor/laravel/framework/src/Illuminate/Cache/DatabaseStore.php @@ -23,6 +23,13 @@ class DatabaseStore implements LockProvider, Store */ protected $connection; + /** + * The database connection instance that should be used to manage locks. + * + * @var \Illuminate\Database\ConnectionInterface + */ + protected $lockConnection; + /** * The name of the cache table. * @@ -155,8 +162,6 @@ class DatabaseStore implements LockProvider, Store 'expiration' => $expiration, ]) >= 1; } - - return false; } /** @@ -267,7 +272,7 @@ class DatabaseStore implements LockProvider, Store public function lock($name, $seconds = 0, $owner = null) { return new DatabaseLock( - $this->connection, + $this->lockConnection ?? $this->connection, $this->lockTable, $this->prefix.$name, $seconds, @@ -333,6 +338,19 @@ class DatabaseStore implements LockProvider, Store return $this->connection; } + /** + * Specify the name of the connection that should be used to manage locks. + * + * @param \Illuminate\Database\ConnectionInterface $connection + * @return $this + */ + public function setLockConnection($connection) + { + $this->lockConnection = $connection; + + return $this; + } + /** * Get the cache key prefix. * diff --git a/vendor/laravel/framework/src/Illuminate/Cache/DynamoDbStore.php b/vendor/laravel/framework/src/Illuminate/Cache/DynamoDbStore.php index 4e663db41..aa28a789f 100644 --- a/vendor/laravel/framework/src/Illuminate/Cache/DynamoDbStore.php +++ b/vendor/laravel/framework/src/Illuminate/Cache/DynamoDbStore.php @@ -525,4 +525,14 @@ class DynamoDbStore implements LockProvider, Store { $this->prefix = ! empty($prefix) ? $prefix.':' : ''; } + + /** + * Get the DynamoDb Client instance. + * + * @return DynamoDbClient + */ + public function getClient() + { + return $this->dynamo; + } } diff --git a/vendor/laravel/framework/src/Illuminate/Cache/FileStore.php b/vendor/laravel/framework/src/Illuminate/Cache/FileStore.php index 7295d9e6d..c3d0bc9c3 100755 --- a/vendor/laravel/framework/src/Illuminate/Cache/FileStore.php +++ b/vendor/laravel/framework/src/Illuminate/Cache/FileStore.php @@ -3,13 +3,16 @@ namespace Illuminate\Cache; use Exception; +use Illuminate\Contracts\Cache\LockProvider; use Illuminate\Contracts\Cache\Store; +use Illuminate\Contracts\Filesystem\LockTimeoutException; use Illuminate\Filesystem\Filesystem; +use Illuminate\Filesystem\LockableFile; use Illuminate\Support\InteractsWithTime; -class FileStore implements Store +class FileStore implements Store, LockProvider { - use InteractsWithTime, RetrievesMultipleKeys; + use InteractsWithTime, HasCacheLock, RetrievesMultipleKeys; /** * The Illuminate Filesystem instance. @@ -83,6 +86,45 @@ class FileStore implements Store return false; } + /** + * Store an item in the cache if the key doesn't exist. + * + * @param string $key + * @param mixed $value + * @param int $seconds + * @return bool + */ + public function add($key, $value, $seconds) + { + $this->ensureCacheDirectoryExists($path = $this->path($key)); + + $file = new LockableFile($path, 'c+'); + + try { + $file->getExclusiveLock(); + } catch (LockTimeoutException $e) { + $file->close(); + + return false; + } + + $expire = $file->read(10); + + if (empty($expire) || $this->currentTime() >= $expire) { + $file->truncate() + ->write($this->expiration($seconds).serialize($value)) + ->close(); + + $this->ensureFileHasCorrectPermissions($path); + + return true; + } + + $file->close(); + + return false; + } + /** * Create the file cache directory if necessary. * diff --git a/vendor/laravel/framework/src/Illuminate/Cache/HasCacheLock.php b/vendor/laravel/framework/src/Illuminate/Cache/HasCacheLock.php new file mode 100644 index 000000000..82ad9c2b3 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Cache/HasCacheLock.php @@ -0,0 +1,31 @@ +lock($name, 0, $owner); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Cache/Lock.php b/vendor/laravel/framework/src/Illuminate/Cache/Lock.php index 271cba50f..bed170507 100644 --- a/vendor/laravel/framework/src/Illuminate/Cache/Lock.php +++ b/vendor/laravel/framework/src/Illuminate/Cache/Lock.php @@ -105,7 +105,7 @@ abstract class Lock implements LockContract * * @param int $seconds * @param callable|null $callback - * @return bool + * @return mixed * * @throws \Illuminate\Contracts\Cache\LockTimeoutException */ @@ -153,7 +153,7 @@ abstract class Lock implements LockContract } /** - * Specify the number of milliseconds to sleep in between blocked lock aquisition attempts. + * Specify the number of milliseconds to sleep in between blocked lock acquisition attempts. * * @param int $milliseconds * @return $this diff --git a/vendor/laravel/framework/src/Illuminate/Cache/NoLock.php b/vendor/laravel/framework/src/Illuminate/Cache/NoLock.php new file mode 100644 index 000000000..68560f8f8 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Cache/NoLock.php @@ -0,0 +1,46 @@ +owner; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Cache/NullStore.php b/vendor/laravel/framework/src/Illuminate/Cache/NullStore.php index 43231b492..0fe4268f7 100755 --- a/vendor/laravel/framework/src/Illuminate/Cache/NullStore.php +++ b/vendor/laravel/framework/src/Illuminate/Cache/NullStore.php @@ -2,7 +2,9 @@ namespace Illuminate\Cache; -class NullStore extends TaggableStore +use Illuminate\Contracts\Cache\LockProvider; + +class NullStore extends TaggableStore implements LockProvider { use RetrievesMultipleKeys; @@ -66,6 +68,31 @@ class NullStore extends TaggableStore return false; } + /** + * Get a lock instance. + * + * @param string $name + * @param int $seconds + * @param string|null $owner + * @return \Illuminate\Contracts\Cache\Lock + */ + public function lock($name, $seconds = 0, $owner = null) + { + return new NoLock($name, $seconds, $owner); + } + + /** + * Restore a lock instance using the owner identifier. + * + * @param string $name + * @param string $owner + * @return \Illuminate\Contracts\Cache\Lock + */ + public function restoreLock($name, $owner) + { + return $this->lock($name, 0, $owner); + } + /** * Remove an item from the cache. * diff --git a/vendor/laravel/framework/src/Illuminate/Cache/PhpRedisLock.php b/vendor/laravel/framework/src/Illuminate/Cache/PhpRedisLock.php new file mode 100644 index 000000000..abb8f67ba --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Cache/PhpRedisLock.php @@ -0,0 +1,112 @@ +redis->eval( + LuaScripts::releaseLock(), + 1, + $this->name, + $this->serializedAndCompressedOwner() + ); + } + + /** + * Get the owner key, serialized and compressed. + * + * @return string + * + * @throws \UnexpectedValueException + */ + protected function serializedAndCompressedOwner(): string + { + $client = $this->redis->client(); + + $owner = $client->_serialize($this->owner); + + // https://github.com/phpredis/phpredis/issues/1938 + if ($this->compressed()) { + if ($this->lzfCompressed()) { + $owner = \lzf_compress($owner); + } elseif ($this->zstdCompressed()) { + $owner = \zstd_compress($owner, $client->getOption(Redis::OPT_COMPRESSION_LEVEL)); + } elseif ($this->lz4Compressed()) { + $owner = \lz4_compress($owner, $client->getOption(Redis::OPT_COMPRESSION_LEVEL)); + } else { + throw new UnexpectedValueException(sprintf( + 'Unknown phpredis compression in use [%d]. Unable to release lock.', + $client->getOption(Redis::OPT_COMPRESSION) + )); + } + } + + return $owner; + } + + /** + * Determine if compression is enabled. + * + * @return bool + */ + protected function compressed(): bool + { + return $this->redis->client()->getOption(Redis::OPT_COMPRESSION) !== Redis::COMPRESSION_NONE; + } + + /** + * Determine if LZF compression is enabled. + * + * @return bool + */ + protected function lzfCompressed(): bool + { + return defined('Redis::COMPRESSION_LZF') && + $this->redis->client()->getOption(Redis::OPT_COMPRESSION) === Redis::COMPRESSION_LZF; + } + + /** + * Determine if ZSTD compression is enabled. + * + * @return bool + */ + protected function zstdCompressed(): bool + { + return defined('Redis::COMPRESSION_ZSTD') && + $this->redis->client()->getOption(Redis::OPT_COMPRESSION) === Redis::COMPRESSION_ZSTD; + } + + /** + * Determine if LZ4 compression is enabled. + * + * @return bool + */ + protected function lz4Compressed(): bool + { + return defined('Redis::COMPRESSION_LZ4') && + $this->redis->client()->getOption(Redis::OPT_COMPRESSION) === Redis::COMPRESSION_LZ4; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Cache/RateLimiter.php b/vendor/laravel/framework/src/Illuminate/Cache/RateLimiter.php index efa83d4fc..dbe94b117 100644 --- a/vendor/laravel/framework/src/Illuminate/Cache/RateLimiter.php +++ b/vendor/laravel/framework/src/Illuminate/Cache/RateLimiter.php @@ -2,6 +2,7 @@ namespace Illuminate\Cache; +use Closure; use Illuminate\Contracts\Cache\Repository as Cache; use Illuminate\Support\InteractsWithTime; @@ -16,6 +17,13 @@ class RateLimiter */ protected $cache; + /** + * The configured limit object resolvers. + * + * @var array + */ + protected $limiters = []; + /** * Create a new rate limiter instance. * @@ -27,6 +35,31 @@ class RateLimiter $this->cache = $cache; } + /** + * Register a named limiter configuration. + * + * @param string $name + * @param \Closure $callback + * @return $this + */ + public function for(string $name, Closure $callback) + { + $this->limiters[$name] = $callback; + + return $this; + } + + /** + * Get the given named rate limiter. + * + * @param string $name + * @return \Closure + */ + public function limiter(string $name) + { + return $this->limiters[$name] ?? null; + } + /** * Determine if the given key has been "accessed" too many times. * diff --git a/vendor/laravel/framework/src/Illuminate/Cache/RateLimiting/GlobalLimit.php b/vendor/laravel/framework/src/Illuminate/Cache/RateLimiting/GlobalLimit.php new file mode 100644 index 000000000..4f084eb10 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Cache/RateLimiting/GlobalLimit.php @@ -0,0 +1,18 @@ +key = $key; + $this->maxAttempts = $maxAttempts; + $this->decayMinutes = $decayMinutes; + } + + /** + * Create a new rate limit. + * + * @param int $maxAttempts + * @return static + */ + public static function perMinute($maxAttempts) + { + return new static('', $maxAttempts); + } + + /** + * Create a new rate limit using minutes as decay time. + * + * @param int $decayMinutes + * @param int $maxAttempts + * @return static + */ + public static function perMinutes($decayMinutes, $maxAttempts) + { + return new static('', $maxAttempts, $decayMinutes); + } + + /** + * Create a new rate limit using hours as decay time. + * + * @param int $maxAttempts + * @param int $decayHours + * @return static + */ + public static function perHour($maxAttempts, $decayHours = 1) + { + return new static('', $maxAttempts, 60 * $decayHours); + } + + /** + * Create a new rate limit using days as decay time. + * + * @param int $maxAttempts + * @param int $decayDays + * @return static + */ + public static function perDay($maxAttempts, $decayDays = 1) + { + return new static('', $maxAttempts, 60 * 24 * $decayDays); + } + + /** + * Create a new unlimited rate limit. + * + * @return static + */ + public static function none() + { + return new Unlimited; + } + + /** + * Set the key of the rate limit. + * + * @param string $key + * @return $this + */ + public function by($key) + { + $this->key = $key; + + return $this; + } + + /** + * Set the callback that should generate the response when the limit is exceeded. + * + * @param callable $callback + * @return $this + */ + public function response(callable $callback) + { + $this->responseCallback = $callback; + + return $this; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Cache/RateLimiting/Unlimited.php b/vendor/laravel/framework/src/Illuminate/Cache/RateLimiting/Unlimited.php new file mode 100644 index 000000000..fcfaa3178 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Cache/RateLimiting/Unlimited.php @@ -0,0 +1,16 @@ +redis->get($this->name); } + + /** + * Get the name of the Redis connection being used to manage the lock. + * + * @return string + */ + public function getConnectionName() + { + return $this->redis->getName(); + } } diff --git a/vendor/laravel/framework/src/Illuminate/Cache/RedisStore.php b/vendor/laravel/framework/src/Illuminate/Cache/RedisStore.php index f3aa8a3dc..4896c9183 100755 --- a/vendor/laravel/framework/src/Illuminate/Cache/RedisStore.php +++ b/vendor/laravel/framework/src/Illuminate/Cache/RedisStore.php @@ -4,6 +4,7 @@ namespace Illuminate\Cache; use Illuminate\Contracts\Cache\LockProvider; use Illuminate\Contracts\Redis\Factory as Redis; +use Illuminate\Redis\Connections\PhpRedisConnection; class RedisStore extends TaggableStore implements LockProvider { @@ -22,12 +23,19 @@ class RedisStore extends TaggableStore implements LockProvider protected $prefix; /** - * The Redis connection that should be used. + * The Redis connection instance that should be used to manage locks. * * @var string */ protected $connection; + /** + * The name of the connection that should be used for locks. + * + * @var string + */ + protected $lockConnection; + /** * Create a new Redis store. * @@ -181,7 +189,15 @@ class RedisStore extends TaggableStore implements LockProvider */ public function lock($name, $seconds = 0, $owner = null) { - return new RedisLock($this->connection(), $this->prefix.$name, $seconds, $owner); + $lockName = $this->prefix.$name; + + $lockConnection = $this->lockConnection(); + + if ($lockConnection instanceof PhpRedisConnection) { + return new PhpRedisLock($lockConnection, $lockName, $seconds, $owner); + } + + return new RedisLock($lockConnection, $lockName, $seconds, $owner); } /** @@ -243,7 +259,17 @@ class RedisStore extends TaggableStore implements LockProvider } /** - * Set the connection name to be used. + * Get the Redis connection instance that should be used to manage locks. + * + * @return \Illuminate\Redis\Connections\Connection + */ + public function lockConnection() + { + return $this->redis->connection($this->lockConnection ?? $this->connection); + } + + /** + * Specify the name of the connection that should be used to store data. * * @param string $connection * @return void @@ -253,6 +279,19 @@ class RedisStore extends TaggableStore implements LockProvider $this->connection = $connection; } + /** + * Specify the name of the connection that should be used to manage locks. + * + * @param string $connection + * @return $this + */ + public function setLockConnection($connection) + { + $this->lockConnection = $connection; + + return $this; + } + /** * Get the Redis database instance. * diff --git a/vendor/laravel/framework/src/Illuminate/Cache/RedisTaggedCache.php b/vendor/laravel/framework/src/Illuminate/Cache/RedisTaggedCache.php index ad50ce9ad..8b131c0fc 100644 --- a/vendor/laravel/framework/src/Illuminate/Cache/RedisTaggedCache.php +++ b/vendor/laravel/framework/src/Illuminate/Cache/RedisTaggedCache.php @@ -10,6 +10,7 @@ class RedisTaggedCache extends TaggedCache * @var string */ const REFERENCE_KEY_FOREVER = 'forever_ref'; + /** * Standard reference key. * @@ -41,13 +42,13 @@ class RedisTaggedCache extends TaggedCache * * @param string $key * @param mixed $value - * @return void + * @return int|bool */ public function increment($key, $value = 1) { $this->pushStandardKeys($this->tags->getNamespace(), $key); - parent::increment($key, $value); + return parent::increment($key, $value); } /** @@ -55,13 +56,13 @@ class RedisTaggedCache extends TaggedCache * * @param string $key * @param mixed $value - * @return void + * @return int|bool */ public function decrement($key, $value = 1) { $this->pushStandardKeys($this->tags->getNamespace(), $key); - parent::decrement($key, $value); + return parent::decrement($key, $value); } /** diff --git a/vendor/laravel/framework/src/Illuminate/Cache/Repository.php b/vendor/laravel/framework/src/Illuminate/Cache/Repository.php index a242e8afc..00cd39b01 100755 --- a/vendor/laravel/framework/src/Illuminate/Cache/Repository.php +++ b/vendor/laravel/framework/src/Illuminate/Cache/Repository.php @@ -292,8 +292,12 @@ class Repository implements ArrayAccess, CacheContract */ public function add($key, $value, $ttl = null) { + $seconds = null; + if ($ttl !== null) { - if ($this->getSeconds($ttl) <= 0) { + $seconds = $this->getSeconds($ttl); + + if ($seconds <= 0) { return false; } @@ -301,8 +305,6 @@ class Repository implements ArrayAccess, CacheContract // has a chance to override this logic. Some drivers better support the way // this operation should work with a total "atomic" implementation of it. if (method_exists($this->store, 'add')) { - $seconds = $this->getSeconds($ttl); - return $this->store->add( $this->itemKey($key), $value, $seconds ); @@ -313,7 +315,7 @@ class Repository implements ArrayAccess, CacheContract // so it exists for subsequent requests. Then, we will return true so it is // easy to know if the value gets added. Otherwise, we will return false. if (is_null($this->get($key))) { - return $this->put($key, $value, $ttl); + return $this->put($key, $value, $seconds); } return false; @@ -477,7 +479,7 @@ class Repository implements ArrayAccess, CacheContract */ public function tags($names) { - if (! method_exists($this->store, 'tags')) { + if (! $this->supportsTags()) { throw new BadMethodCallException('This cache store does not support tagging.'); } @@ -501,6 +503,33 @@ class Repository implements ArrayAccess, CacheContract return $key; } + /** + * Calculate the number of seconds for the given TTL. + * + * @param \DateTimeInterface|\DateInterval|int $ttl + * @return int + */ + protected function getSeconds($ttl) + { + $duration = $this->parseDateInterval($ttl); + + if ($duration instanceof DateTimeInterface) { + $duration = Carbon::now()->diffInRealSeconds($duration, false); + } + + return (int) $duration > 0 ? $duration : 0; + } + + /** + * Determine if the current store supports tags. + * + * @return bool + */ + public function supportsTags() + { + return method_exists($this->store, 'tags'); + } + /** * Get the default cache time. * @@ -613,23 +642,6 @@ class Repository implements ArrayAccess, CacheContract $this->forget($key); } - /** - * Calculate the number of seconds for the given TTL. - * - * @param \DateTimeInterface|\DateInterval|int $ttl - * @return int - */ - protected function getSeconds($ttl) - { - $duration = $this->parseDateInterval($ttl); - - if ($duration instanceof DateTimeInterface) { - $duration = Carbon::now()->diffInRealSeconds($duration, false); - } - - return (int) $duration > 0 ? $duration : 0; - } - /** * Handle dynamic calls into macros or pass missing methods to the store. * diff --git a/vendor/laravel/framework/src/Illuminate/Cache/RetrievesMultipleKeys.php b/vendor/laravel/framework/src/Illuminate/Cache/RetrievesMultipleKeys.php index 5dd41edb5..7db7a0aa5 100644 --- a/vendor/laravel/framework/src/Illuminate/Cache/RetrievesMultipleKeys.php +++ b/vendor/laravel/framework/src/Illuminate/Cache/RetrievesMultipleKeys.php @@ -16,8 +16,12 @@ trait RetrievesMultipleKeys { $return = []; - foreach ($keys as $key) { - $return[$key] = $this->get($key); + $keys = collect($keys)->mapWithKeys(function ($value, $key) { + return [is_string($key) ? $key : $value => is_string($key) ? $value : null]; + })->all(); + + foreach ($keys as $key => $default) { + $return[$key] = $this->get($key, $default); } return $return; diff --git a/vendor/laravel/framework/src/Illuminate/Cache/TaggedCache.php b/vendor/laravel/framework/src/Illuminate/Cache/TaggedCache.php index 01e483b6e..e36f21d43 100644 --- a/vendor/laravel/framework/src/Illuminate/Cache/TaggedCache.php +++ b/vendor/laravel/framework/src/Illuminate/Cache/TaggedCache.php @@ -52,11 +52,11 @@ class TaggedCache extends Repository * * @param string $key * @param mixed $value - * @return void + * @return int|bool */ public function increment($key, $value = 1) { - $this->store->increment($this->itemKey($key), $value); + return $this->store->increment($this->itemKey($key), $value); } /** @@ -64,11 +64,11 @@ class TaggedCache extends Repository * * @param string $key * @param mixed $value - * @return void + * @return int|bool */ public function decrement($key, $value = 1) { - $this->store->decrement($this->itemKey($key), $value); + return $this->store->decrement($this->itemKey($key), $value); } /** diff --git a/vendor/laravel/framework/src/Illuminate/Cache/composer.json b/vendor/laravel/framework/src/Illuminate/Cache/composer.json index adce54e6a..b9ef4881b 100755 --- a/vendor/laravel/framework/src/Illuminate/Cache/composer.json +++ b/vendor/laravel/framework/src/Illuminate/Cache/composer.json @@ -14,9 +14,11 @@ } ], "require": { - "php": "^7.2.5|^8.0", - "illuminate/contracts": "^7.0", - "illuminate/support": "^7.0" + "php": "^7.3|^8.0", + "illuminate/collections": "^8.0", + "illuminate/contracts": "^8.0", + "illuminate/macroable": "^8.0", + "illuminate/support": "^8.0" }, "autoload": { "psr-4": { @@ -25,15 +27,15 @@ }, "extra": { "branch-alias": { - "dev-master": "7.x-dev" + "dev-master": "8.x-dev" } }, "suggest": { "ext-memcached": "Required to use the memcache cache driver.", - "illuminate/database": "Required to use the database cache driver (^7.0).", - "illuminate/filesystem": "Required to use the file cache driver (^7.0).", - "illuminate/redis": "Required to use the redis cache driver (^7.0).", - "symfony/cache": "Required to PSR-6 cache bridge (^5.0)." + "illuminate/database": "Required to use the database cache driver (^8.0).", + "illuminate/filesystem": "Required to use the file cache driver (^8.0).", + "illuminate/redis": "Required to use the redis cache driver (^8.0).", + "symfony/cache": "Required to PSR-6 cache bridge (^5.1.4)." }, "config": { "sort-packages": true diff --git a/vendor/laravel/framework/src/Illuminate/Support/Arr.php b/vendor/laravel/framework/src/Illuminate/Collections/Arr.php old mode 100755 new mode 100644 similarity index 93% rename from vendor/laravel/framework/src/Illuminate/Support/Arr.php rename to vendor/laravel/framework/src/Illuminate/Collections/Arr.php index 8681e98a2..9d08ae2c8 --- a/vendor/laravel/framework/src/Illuminate/Support/Arr.php +++ b/vendor/laravel/framework/src/Illuminate/Collections/Arr.php @@ -144,6 +144,10 @@ class Arr */ public static function exists($array, $key) { + if ($array instanceof Enumerable) { + return $array->has($key); + } + if ($array instanceof ArrayAccess) { return $array->offsetExists($key); } @@ -405,7 +409,7 @@ class Arr * Pluck an array of values from an array. * * @param iterable $array - * @param string|array $value + * @param string|array|int|null $value * @param string|array|null $key * @return array */ @@ -463,7 +467,7 @@ class Arr */ public static function prepend($array, $value, $key = null) { - if (is_null($key)) { + if (func_num_args() == 2) { array_unshift($array, $value); } else { $array = [$key => $value] + $array; @@ -494,11 +498,12 @@ class Arr * * @param array $array * @param int|null $number + * @param bool|false $preserveKeys * @return mixed * * @throws \InvalidArgumentException */ - public static function random($array, $number = null) + public static function random($array, $number = null, $preserveKeys = false) { $requested = is_null($number) ? 1 : $number; @@ -522,8 +527,14 @@ class Arr $results = []; - foreach ((array) $keys as $key) { - $results[] = $array[$key]; + if ($preserveKeys) { + foreach ((array) $keys as $key) { + $results[$key] = $array[$key]; + } + } else { + foreach ((array) $keys as $key) { + $results[] = $array[$key]; + } } return $results; @@ -593,7 +604,7 @@ class Arr * Sort the array using the given callback or "dot" notation. * * @param array $array - * @param callable|string|null $callback + * @param callable|array|string|null $callback * @return array */ public static function sort($array, $callback = null) @@ -605,20 +616,26 @@ class Arr * Recursively sort an array by keys and values. * * @param array $array + * @param int $options + * @param bool $descending * @return array */ - public static function sortRecursive($array) + public static function sortRecursive($array, $options = SORT_REGULAR, $descending = false) { foreach ($array as &$value) { if (is_array($value)) { - $value = static::sortRecursive($value); + $value = static::sortRecursive($value, $options, $descending); } } if (static::isAssoc($array)) { - ksort($array); + $descending + ? krsort($array, $options) + : ksort($array, $options); } else { - sort($array); + $descending + ? rsort($array, $options) + : sort($array, $options); } return $array; diff --git a/vendor/laravel/framework/src/Illuminate/Support/Collection.php b/vendor/laravel/framework/src/Illuminate/Collections/Collection.php similarity index 89% rename from vendor/laravel/framework/src/Illuminate/Support/Collection.php rename to vendor/laravel/framework/src/Illuminate/Collections/Collection.php index 4fe58afe2..74e5f9d50 100644 --- a/vendor/laravel/framework/src/Illuminate/Support/Collection.php +++ b/vendor/laravel/framework/src/Illuminate/Collections/Collection.php @@ -4,6 +4,8 @@ namespace Illuminate\Support; use ArrayAccess; use ArrayIterator; +use Illuminate\Collections\ItemNotFoundException; +use Illuminate\Collections\MultipleItemsFoundException; use Illuminate\Support\Traits\EnumeratesValues; use Illuminate\Support\Traits\Macroable; use stdClass; @@ -31,23 +33,15 @@ class Collection implements ArrayAccess, Enumerable } /** - * Create a new collection by invoking the callback a given amount of times. + * Create a collection with the given range. * - * @param int $number - * @param callable|null $callback + * @param int $from + * @param int $to * @return static */ - public static function times($number, callable $callback = null) + public static function range($from, $to) { - if ($number < 1) { - return new static; - } - - if (is_null($callback)) { - return new static(range(1, $number)); - } - - return (new static(range(1, $number)))->map($callback); + return new static(range($from, $to)); } /** @@ -135,7 +129,7 @@ class Collection implements ArrayAccess, Enumerable $collection = isset($key) ? $this->pluck($key) : $this; - $counts = new self; + $counts = new static; $collection->each(function ($value) use ($counts) { $counts[$value] = isset($counts[$value]) ? $counts[$value] + 1 : 1; @@ -268,7 +262,7 @@ class Collection implements ArrayAccess, Enumerable /** * Retrieve duplicate items from the collection. * - * @param callable|null $callback + * @param callable|string|null $callback * @param bool $strict * @return static */ @@ -296,7 +290,7 @@ class Collection implements ArrayAccess, Enumerable /** * Retrieve duplicate items from the collection using strict comparison. * - * @param callable|null $callback + * @param callable|string|null $callback * @return static */ public function duplicatesStrict($callback = null) @@ -412,7 +406,7 @@ class Collection implements ArrayAccess, Enumerable */ public function get($key, $default = null) { - if ($this->offsetExists($key)) { + if (array_key_exists($key, $this->items)) { return $this->items[$key]; } @@ -501,7 +495,7 @@ class Collection implements ArrayAccess, Enumerable $keys = is_array($key) ? $key : func_get_args(); foreach ($keys as $value) { - if (! $this->offsetExists($value)) { + if (! array_key_exists($value, $this->items)) { return false; } } @@ -520,11 +514,11 @@ class Collection implements ArrayAccess, Enumerable { $first = $this->first(); - if (is_array($first) || is_object($first)) { - return implode($glue, $this->pluck($value)->all()); + if (is_array($first) || (is_object($first) && ! $first instanceof Stringable)) { + return implode($glue ?? '', $this->pluck($value)->all()); } - return implode($value, $this->items); + return implode($value ?? '', $this->items); } /** @@ -561,6 +555,16 @@ class Collection implements ArrayAccess, Enumerable return empty($this->items); } + /** + * Determine if the collection contains a single item. + * + * @return bool + */ + public function containsOneItem() + { + return $this->count() === 1; + } + /** * Join all items from the collection using a string. The final items can use a separate glue string. * @@ -616,7 +620,7 @@ class Collection implements ArrayAccess, Enumerable /** * Get the values of a given key. * - * @param string|array $value + * @param string|array|int|null $value * @param string|null $key * @return static */ @@ -800,7 +804,7 @@ class Collection implements ArrayAccess, Enumerable */ public function prepend($value, $key = null) { - $this->items = Arr::prepend($this->items, $value, $key); + $this->items = Arr::prepend($this->items, ...func_get_args()); return $this; } @@ -880,18 +884,6 @@ class Collection implements ArrayAccess, Enumerable return new static(Arr::random($this->items, $number)); } - /** - * Reduce the collection to a single value. - * - * @param callable $callback - * @param mixed $initial - * @return mixed - */ - public function reduce(callable $callback, $initial = null) - { - return array_reduce($this->items, $callback, $initial); - } - /** * Replace the collection items with the given items. * @@ -1049,6 +1041,47 @@ class Collection implements ArrayAccess, Enumerable return $groups; } + /** + * Split a collection into a certain number of groups, and fill the first groups completely. + * + * @param int $numberOfGroups + * @return static + */ + public function splitIn($numberOfGroups) + { + return $this->chunk(ceil($this->count() / $numberOfGroups)); + } + + /** + * Get the first item in the collection, but only if exactly one item exists. Otherwise, throw an exception. + * + * @param mixed $key + * @param mixed $operator + * @param mixed $value + * @return mixed + * + * @throws \Illuminate\Collections\ItemNotFoundException + * @throws \Illuminate\Collections\MultipleItemsFoundException + */ + public function sole($key = null, $operator = null, $value = null) + { + $filter = func_num_args() > 1 + ? $this->operatorForWhere(...func_get_args()) + : $key; + + $items = $this->when($filter)->filter($filter); + + if ($items->isEmpty()) { + throw new ItemNotFoundException; + } + + if ($items->count() > 1) { + throw new MultipleItemsFoundException; + } + + return $items->first(); + } + /** * Chunk the collection into chunks of the given size. * @@ -1070,6 +1103,19 @@ class Collection implements ArrayAccess, Enumerable return new static($chunks); } + /** + * Chunk the collection into chunks with a callback. + * + * @param callable $callback + * @return static + */ + public function chunkWhile(callable $callback) + { + return new static( + $this->lazy()->chunkWhile($callback)->mapInto(static::class) + ); + } + /** * Sort through each item with a callback. * @@ -1082,7 +1128,7 @@ class Collection implements ArrayAccess, Enumerable $callback && is_callable($callback) ? uasort($items, $callback) - : asort($items, $callback); + : asort($items, $callback ?? SORT_REGULAR); return new static($items); } @@ -1105,13 +1151,17 @@ class Collection implements ArrayAccess, Enumerable /** * Sort the collection using the given callback. * - * @param callable|string $callback + * @param callable|array|string $callback * @param int $options * @param bool $descending * @return static */ public function sortBy($callback, $options = SORT_REGULAR, $descending = false) { + if (is_array($callback) && ! is_callable($callback)) { + return $this->sortByMany($callback); + } + $results = []; $callback = $this->valueRetriever($callback); @@ -1136,6 +1186,50 @@ class Collection implements ArrayAccess, Enumerable return new static($results); } + /** + * Sort the collection using multiple comparisons. + * + * @param array $comparisons + * @return static + */ + protected function sortByMany(array $comparisons = []) + { + $items = $this->items; + + usort($items, function ($a, $b) use ($comparisons) { + foreach ($comparisons as $comparison) { + $comparison = Arr::wrap($comparison); + + $prop = $comparison[0]; + + $ascending = Arr::get($comparison, 1, true) === true || + Arr::get($comparison, 1, true) === 'asc'; + + $result = 0; + + if (is_callable($prop)) { + $result = $prop($a, $b); + } else { + $values = [data_get($a, $prop), data_get($b, $prop)]; + + if (! $ascending) { + $values = array_reverse($values); + } + + $result = $values[0] <=> $values[1]; + } + + if ($result === 0) { + continue; + } + + return $result; + } + }); + + return new static($items); + } + /** * Sort the collection in descending order using the given callback. * @@ -1348,7 +1442,7 @@ class Collection implements ArrayAccess, Enumerable */ public function offsetExists($key) { - return array_key_exists($key, $this->items); + return isset($this->items[$key]); } /** diff --git a/vendor/laravel/framework/src/Illuminate/Support/Enumerable.php b/vendor/laravel/framework/src/Illuminate/Collections/Enumerable.php similarity index 90% rename from vendor/laravel/framework/src/Illuminate/Support/Enumerable.php rename to vendor/laravel/framework/src/Illuminate/Collections/Enumerable.php index 5c512e46d..261a0c856 100644 --- a/vendor/laravel/framework/src/Illuminate/Support/Enumerable.php +++ b/vendor/laravel/framework/src/Illuminate/Collections/Enumerable.php @@ -27,6 +27,15 @@ interface Enumerable extends Arrayable, Countable, IteratorAggregate, Jsonable, */ public static function times($number, callable $callback = null); + /** + * Create a collection with the given range. + * + * @param int $from + * @param int $to + * @return static + */ + public static function range($from, $to); + /** * Wrap the given value in a collection if applicable. * @@ -43,6 +52,13 @@ interface Enumerable extends Arrayable, Countable, IteratorAggregate, Jsonable, */ public static function unwrap($value); + /** + * Create a new instance with no items. + * + * @return static + */ + public static function empty(); + /** * Get all items in the enumerable. * @@ -118,6 +134,14 @@ interface Enumerable extends Arrayable, Countable, IteratorAggregate, Jsonable, */ public function contains($key, $operator = null, $value = null); + /** + * Cross join with the given lists, returning all possible permutations. + * + * @param mixed ...$lists + * @return static + */ + public function crossJoin(...$lists); + /** * Dump the collection and end the script. * @@ -187,7 +211,7 @@ interface Enumerable extends Arrayable, Countable, IteratorAggregate, Jsonable, /** * Retrieve duplicate items. * - * @param callable|null $callback + * @param callable|string|null $callback * @param bool $strict * @return static */ @@ -196,7 +220,7 @@ interface Enumerable extends Arrayable, Countable, IteratorAggregate, Jsonable, /** * Retrieve duplicate items using strict comparison. * - * @param callable|null $callback + * @param callable|string|null $callback * @return static */ public function duplicatesStrict($callback = null); @@ -309,6 +333,22 @@ interface Enumerable extends Arrayable, Countable, IteratorAggregate, Jsonable, */ public function where($key, $operator = null, $value = null); + /** + * Filter items where the value for the given key is null. + * + * @param string|null $key + * @return static + */ + public function whereNull($key = null); + + /** + * Filter items where the value for the given key is not null. + * + * @param string|null $key + * @return static + */ + public function whereNotNull($key = null); + /** * Filter items by the given key value pair using strict comparison. * @@ -375,9 +415,9 @@ interface Enumerable extends Arrayable, Countable, IteratorAggregate, Jsonable, public function whereNotInStrict($key, $values); /** - * Filter the items, removing any items that don't match the given type. + * Filter the items, removing any items that don't match the given type(s). * - * @param string $type + * @param string|string[] $type * @return static */ public function whereInstanceOf($type); @@ -401,6 +441,14 @@ interface Enumerable extends Arrayable, Countable, IteratorAggregate, Jsonable, */ public function firstWhere($key, $operator = null, $value = null); + /** + * Get a flattened array of the items in the collection. + * + * @param int $depth + * @return static + */ + public function flatten($depth = INF); + /** * Flip the values with their keys. * @@ -727,6 +775,22 @@ interface Enumerable extends Arrayable, Countable, IteratorAggregate, Jsonable, */ public function skip($count); + /** + * Skip items in the collection until the given condition is met. + * + * @param mixed $value + * @return static + */ + public function skipUntil($value); + + /** + * Skip items in the collection while the given condition is met. + * + * @param mixed $value + * @return static + */ + public function skipWhile($value); + /** * Get a slice of items from the enumerable. * @@ -752,6 +816,14 @@ interface Enumerable extends Arrayable, Countable, IteratorAggregate, Jsonable, */ public function chunk($size); + /** + * Chunk the collection into chunks with a callback. + * + * @param callable $callback + * @return static + */ + public function chunkWhile(callable $callback); + /** * Sort through each item with a callback. * @@ -820,6 +892,22 @@ interface Enumerable extends Arrayable, Countable, IteratorAggregate, Jsonable, */ public function take($limit); + /** + * Take items in the collection until the given condition is met. + * + * @param mixed $value + * @return static + */ + public function takeUntil($value); + + /** + * Take items in the collection while the given condition is met. + * + * @param mixed $value + * @return static + */ + public function takeWhile($value); + /** * Pass the collection to the given callback and then return it. * @@ -894,6 +982,17 @@ interface Enumerable extends Arrayable, Countable, IteratorAggregate, Jsonable, */ public function countBy($callback = null); + /** + * Zip the collection together with one or more arrays. + * + * e.g. new Collection([1, 2, 3])->zip([4, 5, 6]); + * => [[1, 4], [2, 5], [3, 6]] + * + * @param mixed ...$items + * @return static + */ + public function zip($items); + /** * Collect the values into a collection. * diff --git a/vendor/laravel/framework/src/Illuminate/Support/HigherOrderCollectionProxy.php b/vendor/laravel/framework/src/Illuminate/Collections/HigherOrderCollectionProxy.php similarity index 100% rename from vendor/laravel/framework/src/Illuminate/Support/HigherOrderCollectionProxy.php rename to vendor/laravel/framework/src/Illuminate/Collections/HigherOrderCollectionProxy.php diff --git a/vendor/laravel/framework/src/Illuminate/Support/HigherOrderWhenProxy.php b/vendor/laravel/framework/src/Illuminate/Collections/HigherOrderWhenProxy.php similarity index 100% rename from vendor/laravel/framework/src/Illuminate/Support/HigherOrderWhenProxy.php rename to vendor/laravel/framework/src/Illuminate/Collections/HigherOrderWhenProxy.php diff --git a/vendor/laravel/framework/src/Illuminate/Collections/ItemNotFoundException.php b/vendor/laravel/framework/src/Illuminate/Collections/ItemNotFoundException.php new file mode 100644 index 000000000..8f9c17f0e --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Collections/ItemNotFoundException.php @@ -0,0 +1,9 @@ +map($callback); - } - - /** - * Create an enumerable with the given range. + * Create a collection with the given range. * * @param int $from * @param int $to @@ -79,8 +48,14 @@ class LazyCollection implements Enumerable public static function range($from, $to) { return new static(function () use ($from, $to) { - for (; $from <= $to; $from++) { - yield $from; + if ($from <= $to) { + for (; $from <= $to; $from++) { + yield $from; + } + } else { + for (; $from >= $to; $from--) { + yield $from; + } } }); } @@ -341,7 +316,7 @@ class LazyCollection implements Enumerable /** * Retrieve duplicate items. * - * @param callable|null $callback + * @param callable|string|null $callback * @param bool $strict * @return static */ @@ -353,7 +328,7 @@ class LazyCollection implements Enumerable /** * Retrieve duplicate items using strict comparison. * - * @param callable|null $callback + * @param callable|string|null $callback * @return static */ public function duplicatesStrict($callback = null) @@ -572,7 +547,7 @@ class LazyCollection implements Enumerable } /** - * Determine if the items is empty or not. + * Determine if the items are empty or not. * * @return bool */ @@ -581,6 +556,16 @@ class LazyCollection implements Enumerable return ! $this->getIterator()->valid(); } + /** + * Determine if the collection contains a single item. + * + * @return bool + */ + public function containsOneItem() + { + return $this->take(2)->count() === 1; + } + /** * Join all items from the collection using a string. The final items can use a separate glue string. * @@ -852,24 +837,6 @@ class LazyCollection implements Enumerable return is_null($number) ? $result : new static($result); } - /** - * Reduce the collection to a single value. - * - * @param callable $callback - * @param mixed $initial - * @return mixed - */ - public function reduce(callable $callback, $initial = null) - { - $result = $initial; - - foreach ($this as $value) { - $result = $callback($result, $value); - } - - return $result; - } - /** * Replace the collection items with the given items. * @@ -1043,6 +1010,31 @@ class LazyCollection implements Enumerable return $this->passthru('split', func_get_args()); } + /** + * Get the first item in the collection, but only if exactly one item exists. Otherwise, throw an exception. + * + * @param mixed $key + * @param mixed $operator + * @param mixed $value + * @return mixed + * + * @throws \Illuminate\Collections\ItemNotFoundException + * @throws \Illuminate\Collections\MultipleItemsFoundException + */ + public function sole($key = null, $operator = null, $value = null) + { + $filter = func_num_args() > 1 + ? $this->operatorForWhere(...func_get_args()) + : $key; + + return $this + ->when($filter) + ->filter($filter) + ->take(2) + ->collect() + ->sole(); + } + /** * Chunk the collection into chunks of the given size. * @@ -1082,6 +1074,54 @@ class LazyCollection implements Enumerable }); } + /** + * Split a collection into a certain number of groups, and fill the first groups completely. + * + * @param int $numberOfGroups + * @return static + */ + public function splitIn($numberOfGroups) + { + return $this->chunk(ceil($this->count() / $numberOfGroups)); + } + + /** + * Chunk the collection into chunks with a callback. + * + * @param callable $callback + * @return static + */ + public function chunkWhile(callable $callback) + { + return new static(function () use ($callback) { + $iterator = $this->getIterator(); + + $chunk = new Collection; + + if ($iterator->valid()) { + $chunk[$iterator->key()] = $iterator->current(); + + $iterator->next(); + } + + while ($iterator->valid()) { + if (! $callback($iterator->current(), $iterator->key(), $chunk)) { + yield new static($chunk); + + $chunk = new Collection; + } + + $chunk[$iterator->key()] = $iterator->current(); + + $iterator->next(); + } + + if ($chunk->isNotEmpty()) { + yield new static($chunk); + } + }); + } + /** * Sort through each item with a callback. * @@ -1202,6 +1242,21 @@ class LazyCollection implements Enumerable }); } + /** + * Take items in the collection until a given point in time. + * + * @param \DateTimeInterface $timeout + * @return static + */ + public function takeUntilTimeout(DateTimeInterface $timeout) + { + $timeout = $timeout->getTimestamp(); + + return $this->takeWhile(function () use ($timeout) { + return $this->now() < $timeout; + }); + } + /** * Take items in the collection while the given condition is met. * @@ -1212,7 +1267,9 @@ class LazyCollection implements Enumerable { $callback = $this->useAsCallable($value) ? $value : $this->equality($value); - return $this->takeUntil($this->negate($callback)); + return $this->takeUntil(function ($item, $key) use ($callback) { + return ! $callback($item, $key); + }); } /** @@ -1372,4 +1429,14 @@ class LazyCollection implements Enumerable yield from $this->collect()->$method(...$params); }); } + + /** + * Get the current time. + * + * @return int + */ + protected function now() + { + return time(); + } } diff --git a/vendor/laravel/framework/src/Illuminate/Collections/MultipleItemsFoundException.php b/vendor/laravel/framework/src/Illuminate/Collections/MultipleItemsFoundException.php new file mode 100644 index 000000000..e1ead7639 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Collections/MultipleItemsFoundException.php @@ -0,0 +1,9 @@ +all() : $value; } + /** + * Create a new instance with no items. + * + * @return static + */ + public static function empty() + { + return new static([]); + } + + /** + * Create a new collection by invoking the callback a given amount of times. + * + * @param int $number + * @param callable|null $callback + * @return static + */ + public static function times($number, callable $callback = null) + { + if ($number < 1) { + return new static; + } + + return static::range(1, $number) + ->when($callback) + ->map($callback); + } + /** * Alias for the "avg" method. * @@ -519,7 +551,7 @@ trait EnumeratesValues } /** - * Filter items where the given key is not null. + * Filter items where the value for the given key is null. * * @param string|null $key * @return static @@ -530,7 +562,7 @@ trait EnumeratesValues } /** - * Filter items where the given key is null. + * Filter items where the value for the given key is not null. * * @param string|null $key * @return static @@ -637,14 +669,24 @@ trait EnumeratesValues } /** - * Filter the items, removing any items that don't match the given type. + * Filter the items, removing any items that don't match the given type(s). * - * @param string $type + * @param string|string[] $type * @return static */ public function whereInstanceOf($type) { return $this->filter(function ($value) use ($type) { + if (is_array($type)) { + foreach ($type as $classType) { + if ($value instanceof $classType) { + return true; + } + } + + return false; + } + return $value instanceof $type; }); } @@ -660,6 +702,17 @@ trait EnumeratesValues return $callback($this); } + /** + * Pass the collection into a new class. + * + * @param string $class + * @return mixed + */ + public function pipeInto($class) + { + return new $class($this); + } + /** * Pass the collection to the given callback and then return it. * @@ -673,6 +726,36 @@ trait EnumeratesValues return $this; } + /** + * Reduce the collection to a single value. + * + * @param callable $callback + * @param mixed $initial + * @return mixed + */ + public function reduce(callable $callback, $initial = null) + { + $result = $initial; + + foreach ($this as $key => $value) { + $result = $callback($result, $value, $key); + } + + return $result; + } + + /** + * Reduce an associative collection to a single value. + * + * @param callable $callback + * @param mixed $initial + * @return mixed + */ + public function reduceWithKeys(callable $callback, $initial = null) + { + return $this->reduce($callback, $initial); + } + /** * Create a collection of all elements that do not pass a given truth test. * @@ -723,21 +806,6 @@ trait EnumeratesValues return $this->unique($key, true); } - /** - * Take items in the collection until the given condition is met. - * - * This is an alias to the "takeUntil" method. - * - * @param mixed $value - * @return static - * - * @deprecated Use the "takeUntil" method directly. - */ - public function until($value) - { - return $this->takeUntil($value); - } - /** * Collect the values into a collection. * diff --git a/vendor/laravel/framework/src/Illuminate/Collections/composer.json b/vendor/laravel/framework/src/Illuminate/Collections/composer.json new file mode 100644 index 000000000..cb23d3e49 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Collections/composer.json @@ -0,0 +1,41 @@ +{ + "name": "illuminate/collections", + "description": "The Illuminate Collections package.", + "license": "MIT", + "homepage": "https://laravel.com", + "support": { + "issues": "https://github.com/laravel/framework/issues", + "source": "https://github.com/laravel/framework" + }, + "authors": [ + { + "name": "Taylor Otwell", + "email": "taylor@laravel.com" + } + ], + "require": { + "php": "^7.3|^8.0", + "illuminate/contracts": "^8.0", + "illuminate/macroable": "^8.0" + }, + "autoload": { + "psr-4": { + "Illuminate\\Support\\": "" + }, + "files": [ + "helpers.php" + ] + }, + "extra": { + "branch-alias": { + "dev-master": "8.x-dev" + } + }, + "suggest": { + "symfony/var-dumper": "Required to use the dump method (^5.1.4)." + }, + "config": { + "sort-packages": true + }, + "minimum-stability": "dev" +} diff --git a/vendor/laravel/framework/src/Illuminate/Collections/helpers.php b/vendor/laravel/framework/src/Illuminate/Collections/helpers.php new file mode 100644 index 000000000..67669e5ce --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Collections/helpers.php @@ -0,0 +1,186 @@ + $segment) { + unset($key[$i]); + + if (is_null($segment)) { + return $target; + } + + if ($segment === '*') { + if ($target instanceof Collection) { + $target = $target->all(); + } elseif (! is_array($target)) { + return value($default); + } + + $result = []; + + foreach ($target as $item) { + $result[] = data_get($item, $key); + } + + return in_array('*', $key) ? Arr::collapse($result) : $result; + } + + if (Arr::accessible($target) && Arr::exists($target, $segment)) { + $target = $target[$segment]; + } elseif (is_object($target) && isset($target->{$segment})) { + $target = $target->{$segment}; + } else { + return value($default); + } + } + + return $target; + } +} + +if (! function_exists('data_set')) { + /** + * Set an item on an array or object using dot notation. + * + * @param mixed $target + * @param string|array $key + * @param mixed $value + * @param bool $overwrite + * @return mixed + */ + function data_set(&$target, $key, $value, $overwrite = true) + { + $segments = is_array($key) ? $key : explode('.', $key); + + if (($segment = array_shift($segments)) === '*') { + if (! Arr::accessible($target)) { + $target = []; + } + + if ($segments) { + foreach ($target as &$inner) { + data_set($inner, $segments, $value, $overwrite); + } + } elseif ($overwrite) { + foreach ($target as &$inner) { + $inner = $value; + } + } + } elseif (Arr::accessible($target)) { + if ($segments) { + if (! Arr::exists($target, $segment)) { + $target[$segment] = []; + } + + data_set($target[$segment], $segments, $value, $overwrite); + } elseif ($overwrite || ! Arr::exists($target, $segment)) { + $target[$segment] = $value; + } + } elseif (is_object($target)) { + if ($segments) { + if (! isset($target->{$segment})) { + $target->{$segment} = []; + } + + data_set($target->{$segment}, $segments, $value, $overwrite); + } elseif ($overwrite || ! isset($target->{$segment})) { + $target->{$segment} = $value; + } + } else { + $target = []; + + if ($segments) { + data_set($target[$segment], $segments, $value, $overwrite); + } elseif ($overwrite) { + $target[$segment] = $value; + } + } + + return $target; + } +} + +if (! function_exists('head')) { + /** + * Get the first element of an array. Useful for method chaining. + * + * @param array $array + * @return mixed + */ + function head($array) + { + return reset($array); + } +} + +if (! function_exists('last')) { + /** + * Get the last element from an array. + * + * @param array $array + * @return mixed + */ + function last($array) + { + return end($array); + } +} + +if (! function_exists('value')) { + /** + * Return the default value of the given value. + * + * @param mixed $value + * @return mixed + */ + function value($value, ...$args) + { + return $value instanceof Closure ? $value(...$args) : $value; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Config/composer.json b/vendor/laravel/framework/src/Illuminate/Config/composer.json index 3446109f2..9d577bb46 100755 --- a/vendor/laravel/framework/src/Illuminate/Config/composer.json +++ b/vendor/laravel/framework/src/Illuminate/Config/composer.json @@ -14,9 +14,9 @@ } ], "require": { - "php": "^7.2.5|^8.0", - "illuminate/contracts": "^7.0", - "illuminate/support": "^7.0" + "php": "^7.3|^8.0", + "illuminate/collections": "^8.0", + "illuminate/contracts": "^8.0" }, "autoload": { "psr-4": { @@ -25,7 +25,7 @@ }, "extra": { "branch-alias": { - "dev-master": "7.x-dev" + "dev-master": "8.x-dev" } }, "config": { diff --git a/vendor/laravel/framework/src/Illuminate/Console/Application.php b/vendor/laravel/framework/src/Illuminate/Console/Application.php index 7066c8485..345ab9411 100755 --- a/vendor/laravel/framework/src/Illuminate/Console/Application.php +++ b/vendor/laravel/framework/src/Illuminate/Console/Application.php @@ -19,7 +19,6 @@ use Symfony\Component\Console\Input\InputInterface; use Symfony\Component\Console\Input\InputOption; use Symfony\Component\Console\Input\StringInput; use Symfony\Component\Console\Output\BufferedOutput; -use Symfony\Component\Console\Output\ConsoleOutput; use Symfony\Component\Console\Output\OutputInterface; use Symfony\Component\Process\PhpExecutableFinder; @@ -86,7 +85,7 @@ class Application extends SymfonyApplication implements ApplicationContract $this->events->dispatch( new CommandStarting( - $commandName, $input, $output = $output ?: new ConsoleOutput + $commandName, $input, $output = $output ?: new BufferedConsoleOutput ) ); diff --git a/vendor/laravel/framework/src/Illuminate/Console/BufferedConsoleOutput.php b/vendor/laravel/framework/src/Illuminate/Console/BufferedConsoleOutput.php new file mode 100644 index 000000000..4bb5ca228 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Console/BufferedConsoleOutput.php @@ -0,0 +1,41 @@ +buffer, function () { + $this->buffer = ''; + }); + } + + /** + * {@inheritdoc} + */ + protected function doWrite(string $message, bool $newline) + { + $this->buffer .= $message; + + if ($newline) { + $this->buffer .= \PHP_EOL; + } + + return parent::doWrite($message, $newline); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Console/Command.php b/vendor/laravel/framework/src/Illuminate/Console/Command.php index d5836c00e..4ad47351e 100755 --- a/vendor/laravel/framework/src/Illuminate/Console/Command.php +++ b/vendor/laravel/framework/src/Illuminate/Console/Command.php @@ -38,14 +38,14 @@ class Command extends SymfonyCommand /** * The console command description. * - * @var string|null + * @var string */ protected $description; /** * The console command help text. * - * @var string|null + * @var string */ protected $help; @@ -131,7 +131,9 @@ class Command extends SymfonyCommand */ protected function execute(InputInterface $input, OutputInterface $output) { - return (int) $this->laravel->call([$this, 'handle']); + $method = method_exists($this, 'handle') ? 'handle' : '__invoke'; + + return (int) $this->laravel->call([$this, $method]); } /** diff --git a/vendor/laravel/framework/src/Illuminate/Console/Concerns/CallsCommands.php b/vendor/laravel/framework/src/Illuminate/Console/Concerns/CallsCommands.php index e060c5562..7e69b9b78 100644 --- a/vendor/laravel/framework/src/Illuminate/Console/Concerns/CallsCommands.php +++ b/vendor/laravel/framework/src/Illuminate/Console/Concerns/CallsCommands.php @@ -29,7 +29,7 @@ trait CallsCommands } /** - * Call another console command silently. + * Call another console command without output. * * @param \Symfony\Component\Console\Command\Command|string $command * @param array $arguments @@ -40,6 +40,18 @@ trait CallsCommands return $this->runCommand($command, $arguments, new NullOutput); } + /** + * Call another console command without output. + * + * @param \Symfony\Component\Console\Command\Command|string $command + * @param array $arguments + * @return int + */ + public function callSilently($command, array $arguments = []) + { + return $this->callSilent($command, $arguments); + } + /** * Run the given the console command. * diff --git a/vendor/laravel/framework/src/Illuminate/Console/Concerns/InteractsWithIO.php b/vendor/laravel/framework/src/Illuminate/Console/Concerns/InteractsWithIO.php index e61ef5604..69d295c1e 100644 --- a/vendor/laravel/framework/src/Illuminate/Console/Concerns/InteractsWithIO.php +++ b/vendor/laravel/framework/src/Illuminate/Console/Concerns/InteractsWithIO.php @@ -2,6 +2,7 @@ namespace Illuminate\Console\Concerns; +use Closure; use Illuminate\Console\OutputStyle; use Illuminate\Contracts\Support\Arrayable; use Illuminate\Support\Str; @@ -237,6 +238,38 @@ trait InteractsWithIO $table->render(); } + /** + * Execute a given callback while advancing a progress bar. + * + * @param iterable|int $totalSteps + * @param \Closure $callback + * @return mixed|void + */ + public function withProgressBar($totalSteps, Closure $callback) + { + $bar = $this->output->createProgressBar( + is_iterable($totalSteps) ? count($totalSteps) : $totalSteps + ); + + $bar->start(); + + if (is_iterable($totalSteps)) { + foreach ($totalSteps as $value) { + $callback($value, $bar); + + $bar->advance(); + } + } else { + $callback($bar); + } + + $bar->finish(); + + if (is_iterable($totalSteps)) { + return $totalSteps; + } + } + /** * Write a string as information output. * @@ -332,7 +365,18 @@ trait InteractsWithIO $this->comment('* '.$string.' *'); $this->comment(str_repeat('*', $length)); - $this->output->newLine(); + $this->newLine(); + } + + /** + * Write a blank line. + * + * @param int $count + * @return void + */ + public function newLine($count = 1) + { + $this->output->newLine($count); } /** diff --git a/vendor/laravel/framework/src/Illuminate/Console/Events/ScheduledBackgroundTaskFinished.php b/vendor/laravel/framework/src/Illuminate/Console/Events/ScheduledBackgroundTaskFinished.php new file mode 100644 index 000000000..d9e63c2e5 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Console/Events/ScheduledBackgroundTaskFinished.php @@ -0,0 +1,26 @@ +task = $task; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Console/Events/ScheduledTaskFailed.php b/vendor/laravel/framework/src/Illuminate/Console/Events/ScheduledTaskFailed.php index 992d339f1..46857ad84 100644 --- a/vendor/laravel/framework/src/Illuminate/Console/Events/ScheduledTaskFailed.php +++ b/vendor/laravel/framework/src/Illuminate/Console/Events/ScheduledTaskFailed.php @@ -24,8 +24,9 @@ class ScheduledTaskFailed /** * Create a new event instance. * - * @param \Illuminate\Console\Scheduling\Event $task - * @param \Throwable $exception + * @param \Illuminate\Console\Scheduling\Event $task + * @param \Throwable $exception + * @return void */ public function __construct(Event $task, Throwable $exception) { diff --git a/vendor/laravel/framework/src/Illuminate/Console/GeneratorCommand.php b/vendor/laravel/framework/src/Illuminate/Console/GeneratorCommand.php index 8af456b1f..e426c9f16 100644 --- a/vendor/laravel/framework/src/Illuminate/Console/GeneratorCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Console/GeneratorCommand.php @@ -25,7 +25,7 @@ abstract class GeneratorCommand extends Command /** * Reserved names that cannot be used for generation. * - * @var array + * @var string[] */ protected $reservedNames = [ '__halt_compiler', @@ -171,19 +171,42 @@ abstract class GeneratorCommand extends Command { $name = ltrim($name, '\\/'); + $name = str_replace('/', '\\', $name); + $rootNamespace = $this->rootNamespace(); if (Str::startsWith($name, $rootNamespace)) { return $name; } - $name = str_replace('/', '\\', $name); - return $this->qualifyClass( $this->getDefaultNamespace(trim($rootNamespace, '\\')).'\\'.$name ); } + /** + * Qualify the given model class base name. + * + * @param string $model + * @return string + */ + protected function qualifyModel(string $model) + { + $model = ltrim($model, '\\/'); + + $model = str_replace('/', '\\', $model); + + $rootNamespace = $this->rootNamespace(); + + if (Str::startsWith($model, $rootNamespace)) { + return $model; + } + + return is_dir(app_path('Models')) + ? $rootNamespace.'Models\\'.$model + : $rootNamespace.$model; + } + /** * Get the default namespace for the class. * diff --git a/vendor/laravel/framework/src/Illuminate/Console/Scheduling/CallbackEvent.php b/vendor/laravel/framework/src/Illuminate/Console/Scheduling/CallbackEvent.php index 6af680d99..dde5d7dea 100644 --- a/vendor/laravel/framework/src/Illuminate/Console/Scheduling/CallbackEvent.php +++ b/vendor/laravel/framework/src/Illuminate/Console/Scheduling/CallbackEvent.php @@ -6,6 +6,7 @@ use Illuminate\Contracts\Container\Container; use Illuminate\Support\Reflector; use InvalidArgumentException; use LogicException; +use Throwable; class CallbackEvent extends Event { @@ -77,6 +78,12 @@ class CallbackEvent extends Event $response = is_object($this->callback) ? $container->call([$this->callback, '__invoke'], $this->parameters) : $container->call($this->callback, $this->parameters); + + $this->exitCode = $response === false ? 1 : 0; + } catch (Throwable $e) { + $this->exitCode = 1; + + throw $e; } finally { $this->removeMutex(); diff --git a/vendor/laravel/framework/src/Illuminate/Console/Scheduling/CommandBuilder.php b/vendor/laravel/framework/src/Illuminate/Console/Scheduling/CommandBuilder.php index bc833bd27..ee13c5ee3 100644 --- a/vendor/laravel/framework/src/Illuminate/Console/Scheduling/CommandBuilder.php +++ b/vendor/laravel/framework/src/Illuminate/Console/Scheduling/CommandBuilder.php @@ -52,7 +52,7 @@ class CommandBuilder $finished = Application::formatCommandString('schedule:finish').' "'.$event->mutexName().'"'; if (windows_os()) { - return 'start /b cmd /c "('.$event->command.' & '.$finished.' "%errorlevel%")'.$redirect.$output.' 2>&1"'; + return 'start /b cmd /v:on /c "('.$event->command.' & '.$finished.' ^!ERRORLEVEL^!)'.$redirect.$output.' 2>&1"'; } return $this->ensureCorrectUser($event, diff --git a/vendor/laravel/framework/src/Illuminate/Console/Scheduling/Event.php b/vendor/laravel/framework/src/Illuminate/Console/Scheduling/Event.php index dfb505045..b3ab9b2db 100644 --- a/vendor/laravel/framework/src/Illuminate/Console/Scheduling/Event.php +++ b/vendor/laravel/framework/src/Illuminate/Console/Scheduling/Event.php @@ -13,6 +13,7 @@ use Illuminate\Support\Arr; use Illuminate\Support\Carbon; use Illuminate\Support\Facades\Date; use Illuminate\Support\Reflector; +use Illuminate\Support\Stringable; use Illuminate\Support\Traits\Macroable; use Illuminate\Support\Traits\ReflectsClosures; use Psr\Http\Client\ClientExceptionInterface; @@ -86,7 +87,7 @@ class Event public $expiresAt = 1440; /** - * Indicates if the command should run in background. + * Indicates if the command should run in the background. * * @var bool */ @@ -327,7 +328,7 @@ class Event $date->setTimezone($this->timezone); } - return CronExpression::factory($this->expression)->isDue($date->toDateTimeString()); + return (new CronExpression($this->expression))->isDue($date->toDateTimeString()); } /** @@ -475,7 +476,7 @@ class Event */ protected function emailOutput(Mailer $mailer, $addresses, $onlyIfOutputExists = false) { - $text = file_exists($this->output) ? file_get_contents($this->output) : ''; + $text = is_file($this->output) ? file_get_contents($this->output) : ''; if ($onlyIfOutputExists && empty($text)) { return; @@ -586,7 +587,7 @@ class Event } /** - * State that the command should run in background. + * State that the command should run in the background. * * @return $this */ @@ -728,6 +729,12 @@ class Event */ public function then(Closure $callback) { + $parameters = $this->closureParameterTypes($callback); + + if (Arr::get($parameters, 'output') === Stringable::class) { + return $this->thenWithOutput($callback); + } + $this->afterCallbacks[] = $callback; return $this; @@ -755,6 +762,12 @@ class Event */ public function onSuccess(Closure $callback) { + $parameters = $this->closureParameterTypes($callback); + + if (Arr::get($parameters, 'output') === Stringable::class) { + return $this->onSuccessWithOutput($callback); + } + return $this->then(function (Container $container) use ($callback) { if (0 === $this->exitCode) { $container->call($callback); @@ -784,6 +797,12 @@ class Event */ public function onFailure(Closure $callback) { + $parameters = $this->closureParameterTypes($callback); + + if (Arr::get($parameters, 'output') === Stringable::class) { + return $this->onFailureWithOutput($callback); + } + return $this->then(function (Container $container) use ($callback) { if (0 !== $this->exitCode) { $container->call($callback); @@ -815,11 +834,11 @@ class Event protected function withOutputCallback(Closure $callback, $onlyIfOutputExists = false) { return function (Container $container) use ($callback, $onlyIfOutputExists) { - $output = $this->output && file_exists($this->output) ? file_get_contents($this->output) : ''; + $output = $this->output && is_file($this->output) ? file_get_contents($this->output) : ''; return $onlyIfOutputExists && empty($output) ? null - : $container->call($callback, ['output' => $output]); + : $container->call($callback, ['output' => new Stringable($output)]); }; } @@ -871,9 +890,8 @@ class Event */ public function nextRunDate($currentTime = 'now', $nth = 0, $allowCurrentDate = false) { - return Date::instance(CronExpression::factory( - $this->getExpression() - )->getNextRunDate($currentTime, $nth, $allowCurrentDate, $this->timezone)); + return Date::instance((new CronExpression($this->getExpression())) + ->getNextRunDate($currentTime, $nth, $allowCurrentDate, $this->timezone)); } /** diff --git a/vendor/laravel/framework/src/Illuminate/Console/Scheduling/ManagesFrequencies.php b/vendor/laravel/framework/src/Illuminate/Console/Scheduling/ManagesFrequencies.php index 6972642c0..7e1cdf17c 100644 --- a/vendor/laravel/framework/src/Illuminate/Console/Scheduling/ManagesFrequencies.php +++ b/vendor/laravel/framework/src/Illuminate/Console/Scheduling/ManagesFrequencies.php @@ -276,7 +276,7 @@ trait ManagesFrequencies */ public function weekdays() { - return $this->spliceIntoPosition(5, '1-5'); + return $this->days(Schedule::MONDAY.'-'.Schedule::FRIDAY); } /** @@ -286,7 +286,7 @@ trait ManagesFrequencies */ public function weekends() { - return $this->spliceIntoPosition(5, '0,6'); + return $this->days(Schedule::SATURDAY.','.Schedule::SUNDAY); } /** @@ -296,7 +296,7 @@ trait ManagesFrequencies */ public function mondays() { - return $this->days(1); + return $this->days(Schedule::MONDAY); } /** @@ -306,7 +306,7 @@ trait ManagesFrequencies */ public function tuesdays() { - return $this->days(2); + return $this->days(Schedule::TUESDAY); } /** @@ -316,7 +316,7 @@ trait ManagesFrequencies */ public function wednesdays() { - return $this->days(3); + return $this->days(Schedule::WEDNESDAY); } /** @@ -326,7 +326,7 @@ trait ManagesFrequencies */ public function thursdays() { - return $this->days(4); + return $this->days(Schedule::THURSDAY); } /** @@ -336,7 +336,7 @@ trait ManagesFrequencies */ public function fridays() { - return $this->days(5); + return $this->days(Schedule::FRIDAY); } /** @@ -346,7 +346,7 @@ trait ManagesFrequencies */ public function saturdays() { - return $this->days(6); + return $this->days(Schedule::SATURDAY); } /** @@ -356,7 +356,7 @@ trait ManagesFrequencies */ public function sundays() { - return $this->days(0); + return $this->days(Schedule::SUNDAY); } /** @@ -374,15 +374,15 @@ trait ManagesFrequencies /** * Schedule the event to run weekly on a given day and time. * - * @param int $day + * @param int $dayOfWeek * @param string $time * @return $this */ - public function weeklyOn($day, $time = '0:0') + public function weeklyOn($dayOfWeek, $time = '0:0') { $this->dailyAt($time); - return $this->spliceIntoPosition(5, $day); + return $this->days($dayOfWeek); } /** @@ -400,15 +400,15 @@ trait ManagesFrequencies /** * Schedule the event to run monthly on a given day and time. * - * @param int $day + * @param int $dayOfMonth * @param string $time * @return $this */ - public function monthlyOn($day = 1, $time = '0:0') + public function monthlyOn($dayOfMonth = 1, $time = '0:0') { $this->dailyAt($time); - return $this->spliceIntoPosition(3, $day); + return $this->spliceIntoPosition(3, $dayOfMonth); } /** @@ -421,13 +421,11 @@ trait ManagesFrequencies */ public function twiceMonthly($first = 1, $second = 16, $time = '0:0') { - $days = $first.','.$second; + $daysOfMonth = $first.','.$second; $this->dailyAt($time); - return $this->spliceIntoPosition(1, 0) - ->spliceIntoPosition(2, 0) - ->spliceIntoPosition(3, $days); + return $this->spliceIntoPosition(3, $daysOfMonth); } /** @@ -469,6 +467,22 @@ trait ManagesFrequencies ->spliceIntoPosition(4, 1); } + /** + * Schedule the event to run yearly on a given month, day, and time. + * + * @param int $month + * @param int|string $dayOfMonth + * @param string $time + * @return $this + */ + public function yearlyOn($month = 1, $dayOfMonth = 1, $time = '0:0') + { + $this->dailyAt($time); + + return $this->spliceIntoPosition(3, $dayOfMonth) + ->spliceIntoPosition(4, $month); + } + /** * Set the days of the week the command should run on. * diff --git a/vendor/laravel/framework/src/Illuminate/Console/Scheduling/Schedule.php b/vendor/laravel/framework/src/Illuminate/Console/Scheduling/Schedule.php index 89ad97209..3c915ead7 100644 --- a/vendor/laravel/framework/src/Illuminate/Console/Scheduling/Schedule.php +++ b/vendor/laravel/framework/src/Illuminate/Console/Scheduling/Schedule.php @@ -19,6 +19,14 @@ class Schedule { use Macroable; + const SUNDAY = 0; + const MONDAY = 1; + const TUESDAY = 2; + const WEDNESDAY = 3; + const THURSDAY = 4; + const FRIDAY = 5; + const SATURDAY = 6; + /** * All of the events on the schedule. * @@ -59,6 +67,8 @@ class Schedule * * @param \DateTimeZone|string|null $timezone * @return void + * + * @throws \RuntimeException */ public function __construct($timezone = null) { @@ -143,6 +153,8 @@ class Schedule * @param string|null $queue * @param string|null $connection * @return void + * + * @throws \RuntimeException */ protected function dispatchToQueue($job, $queue, $connection) { @@ -293,6 +305,8 @@ class Schedule * Get the job dispatcher, if available. * * @return \Illuminate\Contracts\Bus\Dispatcher + * + * @throws \RuntimeException */ protected function getDispatcher() { diff --git a/vendor/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleFinishCommand.php b/vendor/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleFinishCommand.php index c19381f08..4857d695c 100644 --- a/vendor/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleFinishCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleFinishCommand.php @@ -3,6 +3,8 @@ namespace Illuminate\Console\Scheduling; use Illuminate\Console\Command; +use Illuminate\Console\Events\ScheduledBackgroundTaskFinished; +use Illuminate\Contracts\Events\Dispatcher; class ScheduleFinishCommand extends Command { @@ -37,6 +39,10 @@ class ScheduleFinishCommand extends Command { collect($schedule->events())->filter(function ($value) { return $value->mutexName() == $this->argument('id'); - })->each->callAfterCallbacksWithExitCode($this->laravel, $this->argument('code')); + })->each(function ($event) { + $event->callafterCallbacksWithExitCode($this->laravel, $this->argument('code')); + + $this->laravel->make(Dispatcher::class)->dispatch(new ScheduledBackgroundTaskFinished($event)); + }); } } diff --git a/vendor/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleListCommand.php b/vendor/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleListCommand.php new file mode 100644 index 000000000..29819c6e5 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleListCommand.php @@ -0,0 +1,53 @@ +events() as $event) { + $rows[] = [ + $event->command, + $event->expression, + $event->description, + (new CronExpression($event->expression)) + ->getNextRunDate(Carbon::now()->setTimezone($event->timezone)) + ->setTimezone($this->option('timezone', config('app.timezone'))) + ->format('Y-m-d H:i:s P'), + ]; + } + + $this->table([ + 'Command', + 'Interval', + 'Description', + 'Next Due', + ], $rows ?? []); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleTestCommand.php b/vendor/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleTestCommand.php new file mode 100644 index 000000000..2d15888bb --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleTestCommand.php @@ -0,0 +1,47 @@ +events(); + + $commandNames = []; + + foreach ($commands as $command) { + $commandNames[] = $command->command; + } + + $index = array_search($this->choice('Which command would you like to run?', $commandNames), $commandNames); + + $event = $commands[$index]; + + $this->line('Running scheduled command: '.$event->getSummaryForDisplay()); + + $event->run($this->laravel); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleWorkCommand.php b/vendor/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleWorkCommand.php new file mode 100644 index 000000000..f30a2f0c9 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Console/Scheduling/ScheduleWorkCommand.php @@ -0,0 +1,68 @@ +info('Schedule worker started successfully.'); + + [$lastExecutionStartedAt, $keyOfLastExecutionWithOutput, $executions] = [null, null, []]; + + while (true) { + usleep(100 * 1000); + + if (Carbon::now()->second === 0 && + ! Carbon::now()->startOfMinute()->equalTo($lastExecutionStartedAt)) { + $executions[] = $execution = new Process([PHP_BINARY, 'artisan', 'schedule:run']); + + $execution->start(); + + $lastExecutionStartedAt = Carbon::now()->startOfMinute(); + } + + foreach ($executions as $key => $execution) { + $output = trim($execution->getIncrementalOutput()). + trim($execution->getIncrementalErrorOutput()); + + if (! empty($output)) { + if ($key !== $keyOfLastExecutionWithOutput) { + $this->info(PHP_EOL.'['.date('c').'] Execution #'.($key + 1).' output:'); + + $keyOfLastExecutionWithOutput = $key; + } + + $this->output->writeln($output); + } + + if (! $execution->isRunning()) { + unset($executions[$key]); + } + } + } + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Console/composer.json b/vendor/laravel/framework/src/Illuminate/Console/composer.json index 41e0bad13..46aaada73 100755 --- a/vendor/laravel/framework/src/Illuminate/Console/composer.json +++ b/vendor/laravel/framework/src/Illuminate/Console/composer.json @@ -14,11 +14,13 @@ } ], "require": { - "php": "^7.2.5|^8.0", - "illuminate/contracts": "^7.0", - "illuminate/support": "^7.0", - "symfony/console": "^5.0", - "symfony/process": "^5.0" + "php": "^7.3|^8.0", + "illuminate/collections": "^8.0", + "illuminate/contracts": "^8.0", + "illuminate/macroable": "^8.0", + "illuminate/support": "^8.0", + "symfony/console": "^5.1.4", + "symfony/process": "^5.1.4" }, "autoload": { "psr-4": { @@ -27,16 +29,16 @@ }, "extra": { "branch-alias": { - "dev-master": "7.x-dev" + "dev-master": "8.x-dev" } }, "suggest": { - "dragonmantank/cron-expression": "Required to use scheduler (^2.3.1).", - "guzzlehttp/guzzle": "Required to use the ping methods on schedules (^6.3.1|^7.0.1).", - "illuminate/bus": "Required to use the scheduled job dispatcher (^7.0).", - "illuminate/container": "Required to use the scheduler (^7.0).", - "illuminate/filesystem": "Required to use the generator command (^7.0).", - "illuminate/queue": "Required to use closures for scheduled jobs (^7.0)." + "dragonmantank/cron-expression": "Required to use scheduler (^3.0.2).", + "guzzlehttp/guzzle": "Required to use the ping methods on schedules (^6.5.5|^7.0.1).", + "illuminate/bus": "Required to use the scheduled job dispatcher (^8.0).", + "illuminate/container": "Required to use the scheduler (^8.0).", + "illuminate/filesystem": "Required to use the generator command (^8.0).", + "illuminate/queue": "Required to use closures for scheduled jobs (^8.0)." }, "config": { "sort-packages": true diff --git a/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php b/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php index c617bf797..3a614720f 100644 --- a/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php +++ b/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php @@ -156,6 +156,8 @@ class BoundMethod * @param array $parameters * @param array $dependencies * @return void + * + * @throws \Illuminate\Contracts\Container\BindingResolutionException */ protected static function addDependencyForCallParameter($container, $parameter, array &$parameters, &$dependencies) diff --git a/vendor/laravel/framework/src/Illuminate/Container/Container.php b/vendor/laravel/framework/src/Illuminate/Container/Container.php index 1eb489a4f..f7049d84c 100755 --- a/vendor/laravel/framework/src/Illuminate/Container/Container.php +++ b/vendor/laravel/framework/src/Illuminate/Container/Container.php @@ -6,11 +6,13 @@ use ArrayAccess; use Closure; use Exception; use Illuminate\Contracts\Container\BindingResolutionException; +use Illuminate\Contracts\Container\CircularDependencyException; use Illuminate\Contracts\Container\Container as ContainerContract; use LogicException; use ReflectionClass; use ReflectionException; use ReflectionParameter; +use TypeError; class Container implements ArrayAccess, ContainerContract { @@ -105,6 +107,13 @@ class Container implements ArrayAccess, ContainerContract */ protected $reboundCallbacks = []; + /** + * All of the global before resolving callbacks. + * + * @var \Closure[] + */ + protected $globalBeforeResolvingCallbacks = []; + /** * All of the global resolving callbacks. * @@ -119,6 +128,13 @@ class Container implements ArrayAccess, ContainerContract */ protected $globalAfterResolvingCallbacks = []; + /** + * All of the before resolving callbacks by class type. + * + * @var array[] + */ + protected $beforeResolvingCallbacks = []; + /** * All of the resolving callbacks by class type. * @@ -218,6 +234,8 @@ class Container implements ArrayAccess, ContainerContract * @param \Closure|string|null $concrete * @param bool $shared * @return void + * + * @throws \TypeError */ public function bind($abstract, $concrete = null, $shared = false) { @@ -235,7 +253,7 @@ class Container implements ArrayAccess, ContainerContract // up inside its own Closure to give us more convenience when extending. if (! $concrete instanceof Closure) { if (! is_string($concrete)) { - throw new \TypeError(self::class.'::bind(): Argument #2 ($concrete) must be of type Closure|string|null'); + throw new TypeError(self::class.'::bind(): Argument #2 ($concrete) must be of type Closure|string|null'); } $concrete = $this->getClosure($abstract, $concrete); @@ -612,7 +630,7 @@ class Container implements ArrayAccess, ContainerContract /** * An alias function name for make(). * - * @param string $abstract + * @param string|callable $abstract * @param array $parameters * @return mixed * @@ -626,7 +644,7 @@ class Container implements ArrayAccess, ContainerContract /** * Resolve the given type from the container. * - * @param string $abstract + * @param string|callable $abstract * @param array $parameters * @return mixed * @@ -645,7 +663,7 @@ class Container implements ArrayAccess, ContainerContract try { return $this->resolve($id); } catch (Exception $e) { - if ($this->has($id)) { + if ($this->has($id) || $e instanceof CircularDependencyException) { throw $e; } @@ -656,17 +674,25 @@ class Container implements ArrayAccess, ContainerContract /** * Resolve the given type from the container. * - * @param string $abstract + * @param string|callable $abstract * @param array $parameters * @param bool $raiseEvents * @return mixed * * @throws \Illuminate\Contracts\Container\BindingResolutionException + * @throws \Illuminate\Contracts\Container\CircularDependencyException */ protected function resolve($abstract, $parameters = [], $raiseEvents = true) { $abstract = $this->getAlias($abstract); + // First we'll fire any event handlers which handle the "before" resolving of + // specific types. This gives some hooks the chance to add various extends + // calls to change the resolution of objects that they're interested in. + if ($raiseEvents) { + $this->fireBeforeResolvingCallbacks($abstract, $parameters); + } + $concrete = $this->getContextualConcrete($abstract); $needsContextualBuild = ! empty($parameters) || ! is_null($concrete); @@ -724,7 +750,7 @@ class Container implements ArrayAccess, ContainerContract /** * Get the concrete type for a given abstract. * - * @param string $abstract + * @param string|callable $abstract * @return mixed */ protected function getConcrete($abstract) @@ -742,7 +768,7 @@ class Container implements ArrayAccess, ContainerContract /** * Get the contextual concrete binding for the given abstract. * - * @param string $abstract + * @param string|callable $abstract * @return \Closure|string|array|null */ protected function getContextualConcrete($abstract) @@ -768,7 +794,7 @@ class Container implements ArrayAccess, ContainerContract /** * Find the concrete binding for the given abstract in the contextual binding array. * - * @param string $abstract + * @param string|callable $abstract * @return \Closure|string|null */ protected function findInContextualBindings($abstract) @@ -795,6 +821,7 @@ class Container implements ArrayAccess, ContainerContract * @return mixed * * @throws \Illuminate\Contracts\Container\BindingResolutionException + * @throws \Illuminate\Contracts\Container\CircularDependencyException */ public function build($concrete) { @@ -818,6 +845,10 @@ class Container implements ArrayAccess, ContainerContract return $this->notInstantiable($concrete); } + // if (in_array($concrete, $this->buildStack)) { + // throw new CircularDependencyException("Circular dependency detected while resolving [{$concrete}]."); + // } + $this->buildStack[] = $concrete; $constructor = $reflector->getConstructor(); @@ -964,10 +995,14 @@ class Container implements ArrayAccess, ContainerContract // the value of the dependency, similarly to how we do this with scalars. catch (BindingResolutionException $e) { if ($parameter->isDefaultValueAvailable()) { + array_pop($this->with); + return $parameter->getDefaultValue(); } if ($parameter->isVariadic()) { + array_pop($this->with); + return []; } @@ -1032,6 +1067,26 @@ class Container implements ArrayAccess, ContainerContract throw new BindingResolutionException($message); } + /** + * Register a new before resolving callback for all types. + * + * @param \Closure|string $abstract + * @param \Closure|null $callback + * @return void + */ + public function beforeResolving($abstract, Closure $callback = null) + { + if (is_string($abstract)) { + $abstract = $this->getAlias($abstract); + } + + if ($abstract instanceof Closure && is_null($callback)) { + $this->globalBeforeResolvingCallbacks[] = $abstract; + } else { + $this->beforeResolvingCallbacks[$abstract][] = $callback; + } + } + /** * Register a new resolving callback. * @@ -1072,6 +1127,39 @@ class Container implements ArrayAccess, ContainerContract } } + /** + * Fire all of the before resolving callbacks. + * + * @param string $abstract + * @param array $parameters + * @return void + */ + protected function fireBeforeResolvingCallbacks($abstract, $parameters = []) + { + $this->fireBeforeCallbackArray($abstract, $parameters, $this->globalBeforeResolvingCallbacks); + + foreach ($this->beforeResolvingCallbacks as $type => $callbacks) { + if ($type === $abstract || is_subclass_of($abstract, $type)) { + $this->fireBeforeCallbackArray($abstract, $parameters, $callbacks); + } + } + } + + /** + * Fire an array of callbacks with an object. + * + * @param string $abstract + * @param array $parameters + * @param array $callbacks + * @return void + */ + protected function fireBeforeCallbackArray($abstract, $parameters, array $callbacks) + { + foreach ($callbacks as $callback) { + $callback($abstract, $parameters, $this); + } + } + /** * Fire all of the resolving callbacks. * @@ -1160,11 +1248,9 @@ class Container implements ArrayAccess, ContainerContract */ public function getAlias($abstract) { - if (! isset($this->aliases[$abstract])) { - return $abstract; - } - - return $this->getAlias($this->aliases[$abstract]); + return isset($this->aliases[$abstract]) + ? $this->getAlias($this->aliases[$abstract]) + : $abstract; } /** @@ -1175,9 +1261,7 @@ class Container implements ArrayAccess, ContainerContract */ protected function getExtenders($abstract) { - $abstract = $this->getAlias($abstract); - - return $this->extenders[$abstract] ?? []; + return $this->extenders[$this->getAlias($abstract)] ?? []; } /** diff --git a/vendor/laravel/framework/src/Illuminate/Container/ContextualBindingBuilder.php b/vendor/laravel/framework/src/Illuminate/Container/ContextualBindingBuilder.php index 5da6ccab3..1d15dcd3d 100644 --- a/vendor/laravel/framework/src/Illuminate/Container/ContextualBindingBuilder.php +++ b/vendor/laravel/framework/src/Illuminate/Container/ContextualBindingBuilder.php @@ -81,4 +81,18 @@ class ContextualBindingBuilder implements ContextualBindingBuilderContract return is_array($taggedServices) ? $taggedServices : iterator_to_array($taggedServices); }); } + + /** + * Specify the configuration item to bind as a primitive. + * + * @param string $key + * @param ?string $default + * @return void + */ + public function giveConfig($key, $default = null) + { + $this->give(function ($container) use ($key, $default) { + return $container->get('config')->get($key, $default); + }); + } } diff --git a/vendor/laravel/framework/src/Illuminate/Container/Util.php b/vendor/laravel/framework/src/Illuminate/Container/Util.php index 0b4bb1283..8180a45a5 100644 --- a/vendor/laravel/framework/src/Illuminate/Container/Util.php +++ b/vendor/laravel/framework/src/Illuminate/Container/Util.php @@ -5,6 +5,9 @@ namespace Illuminate\Container; use Closure; use ReflectionNamedType; +/** + * @internal + */ class Util { /** diff --git a/vendor/laravel/framework/src/Illuminate/Container/composer.json b/vendor/laravel/framework/src/Illuminate/Container/composer.json index e65b8b84d..cf9316099 100755 --- a/vendor/laravel/framework/src/Illuminate/Container/composer.json +++ b/vendor/laravel/framework/src/Illuminate/Container/composer.json @@ -14,8 +14,8 @@ } ], "require": { - "php": "^7.2.5|^8.0", - "illuminate/contracts": "^7.0", + "php": "^7.3|^8.0", + "illuminate/contracts": "^8.0", "psr/container": "^1.0" }, "provide": { @@ -28,7 +28,7 @@ }, "extra": { "branch-alias": { - "dev-master": "7.x-dev" + "dev-master": "8.x-dev" } }, "config": { diff --git a/vendor/laravel/framework/src/Illuminate/Contracts/Auth/PasswordBroker.php b/vendor/laravel/framework/src/Illuminate/Contracts/Auth/PasswordBroker.php index 6bca9f36b..bbbe9b508 100644 --- a/vendor/laravel/framework/src/Illuminate/Contracts/Auth/PasswordBroker.php +++ b/vendor/laravel/framework/src/Illuminate/Contracts/Auth/PasswordBroker.php @@ -45,9 +45,10 @@ interface PasswordBroker * Send a password reset link to a user. * * @param array $credentials + * @param \Closure|null $callback * @return string */ - public function sendResetLink(array $credentials); + public function sendResetLink(array $credentials, Closure $callback = null); /** * Reset the password for the given token. diff --git a/vendor/laravel/framework/src/Illuminate/Contracts/Auth/StatefulGuard.php b/vendor/laravel/framework/src/Illuminate/Contracts/Auth/StatefulGuard.php index eb6f8ddb3..faf1497d5 100644 --- a/vendor/laravel/framework/src/Illuminate/Contracts/Auth/StatefulGuard.php +++ b/vendor/laravel/framework/src/Illuminate/Contracts/Auth/StatefulGuard.php @@ -35,7 +35,7 @@ interface StatefulGuard extends Guard * * @param mixed $id * @param bool $remember - * @return \Illuminate\Contracts\Auth\Authenticatable + * @return \Illuminate\Contracts\Auth\Authenticatable|bool */ public function loginUsingId($id, $remember = false); diff --git a/vendor/laravel/framework/src/Illuminate/Contracts/Bus/Dispatcher.php b/vendor/laravel/framework/src/Illuminate/Contracts/Bus/Dispatcher.php index 12ed2226b..5cbbd9295 100644 --- a/vendor/laravel/framework/src/Illuminate/Contracts/Bus/Dispatcher.php +++ b/vendor/laravel/framework/src/Illuminate/Contracts/Bus/Dispatcher.php @@ -12,6 +12,17 @@ interface Dispatcher */ public function dispatch($command); + /** + * Dispatch a command to its appropriate handler in the current process. + * + * Queueable jobs will be dispatched to the "sync" queue. + * + * @param mixed $command + * @param mixed $handler + * @return mixed + */ + public function dispatchSync($command, $handler = null); + /** * Dispatch a command to its appropriate handler in the current process. * diff --git a/vendor/laravel/framework/src/Illuminate/Contracts/Bus/QueueingDispatcher.php b/vendor/laravel/framework/src/Illuminate/Contracts/Bus/QueueingDispatcher.php index e99f7ebc2..ff84e2752 100644 --- a/vendor/laravel/framework/src/Illuminate/Contracts/Bus/QueueingDispatcher.php +++ b/vendor/laravel/framework/src/Illuminate/Contracts/Bus/QueueingDispatcher.php @@ -4,6 +4,22 @@ namespace Illuminate\Contracts\Bus; interface QueueingDispatcher extends Dispatcher { + /** + * Attempt to find the batch with the given ID. + * + * @param string $batchId + * @return \Illuminate\Bus\Batch|null + */ + public function findBatch(string $batchId); + + /** + * Create a new batch of queueable jobs. + * + * @param \Illuminate\Support\Collection|array $jobs + * @return \Illuminate\Bus\PendingBatch + */ + public function batch($jobs); + /** * Dispatch a command to its appropriate handler behind a queue. * diff --git a/vendor/laravel/framework/src/Illuminate/Contracts/Cache/Lock.php b/vendor/laravel/framework/src/Illuminate/Contracts/Cache/Lock.php index 7f01b1be3..03f633a07 100644 --- a/vendor/laravel/framework/src/Illuminate/Contracts/Cache/Lock.php +++ b/vendor/laravel/framework/src/Illuminate/Contracts/Cache/Lock.php @@ -17,7 +17,7 @@ interface Lock * * @param int $seconds * @param callable|null $callback - * @return bool + * @return mixed */ public function block($seconds, $callback = null); diff --git a/vendor/laravel/framework/src/Illuminate/Contracts/Console/Kernel.php b/vendor/laravel/framework/src/Illuminate/Contracts/Console/Kernel.php index a7423af3a..842f5a6a9 100644 --- a/vendor/laravel/framework/src/Illuminate/Contracts/Console/Kernel.php +++ b/vendor/laravel/framework/src/Illuminate/Contracts/Console/Kernel.php @@ -4,6 +4,13 @@ namespace Illuminate\Contracts\Console; interface Kernel { + /** + * Bootstrap the application for artisan commands. + * + * @return void + */ + public function bootstrap(); + /** * Handle an incoming console command. * diff --git a/vendor/laravel/framework/src/Illuminate/Contracts/Container/CircularDependencyException.php b/vendor/laravel/framework/src/Illuminate/Contracts/Container/CircularDependencyException.php new file mode 100644 index 000000000..6c90381cc --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Contracts/Container/CircularDependencyException.php @@ -0,0 +1,11 @@ +queued[$cookie->getName()][$cookie->getPath()] = $cookie; } + /** + * Queue a cookie to expire with the next response. + * + * @param string $name + * @param string|null $path + * @param string|null $domain + * @return void + */ + public function expire($name, $path = null, $domain = null) + { + $this->queue($this->forget($name, $path, $domain)); + } + /** * Remove a cookie from the queue. * @@ -214,4 +227,16 @@ class CookieJar implements JarContract { return Arr::flatten($this->queued); } + + /** + * Flush the cookies which have been queued for the next request. + * + * @return $this + */ + public function flushQueuedCookies() + { + $this->queued = []; + + return $this; + } } diff --git a/vendor/laravel/framework/src/Illuminate/Cookie/Middleware/EncryptCookies.php b/vendor/laravel/framework/src/Illuminate/Cookie/Middleware/EncryptCookies.php index c28658847..4a116cfb3 100644 --- a/vendor/laravel/framework/src/Illuminate/Cookie/Middleware/EncryptCookies.php +++ b/vendor/laravel/framework/src/Illuminate/Cookie/Middleware/EncryptCookies.php @@ -76,7 +76,7 @@ class EncryptCookies protected function decrypt(Request $request) { foreach ($request->cookies as $key => $cookie) { - if ($this->isDisabled($key)) { + if ($this->isDisabled($key) || is_array($cookie)) { continue; } diff --git a/vendor/laravel/framework/src/Illuminate/Cookie/composer.json b/vendor/laravel/framework/src/Illuminate/Cookie/composer.json index 6e3cb7208..d90265905 100755 --- a/vendor/laravel/framework/src/Illuminate/Cookie/composer.json +++ b/vendor/laravel/framework/src/Illuminate/Cookie/composer.json @@ -14,11 +14,13 @@ } ], "require": { - "php": "^7.2.5|^8.0", - "illuminate/contracts": "^7.0", - "illuminate/support": "^7.0", - "symfony/http-foundation": "^5.0", - "symfony/http-kernel": "^5.0" + "php": "^7.3|^8.0", + "illuminate/collections": "^8.0", + "illuminate/contracts": "^8.0", + "illuminate/macroable": "^8.0", + "illuminate/support": "^8.0", + "symfony/http-foundation": "^5.1.4", + "symfony/http-kernel": "^5.1.4" }, "autoload": { "psr-4": { @@ -27,7 +29,7 @@ }, "extra": { "branch-alias": { - "dev-master": "7.x-dev" + "dev-master": "8.x-dev" } }, "config": { diff --git a/vendor/laravel/framework/src/Illuminate/Database/Concerns/BuildsQueries.php b/vendor/laravel/framework/src/Illuminate/Database/Concerns/BuildsQueries.php index d8ec45c0c..3e97b7d0d 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Concerns/BuildsQueries.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Concerns/BuildsQueries.php @@ -3,8 +3,15 @@ namespace Illuminate\Database\Concerns; use Illuminate\Container\Container; +use Illuminate\Database\MultipleRecordsFoundException; +use Illuminate\Database\RecordsNotFoundException; +use Illuminate\Pagination\CursorPaginator; use Illuminate\Pagination\LengthAwarePaginator; use Illuminate\Pagination\Paginator; +use Illuminate\Support\Collection; +use Illuminate\Support\LazyCollection; +use InvalidArgumentException; +use RuntimeException; trait BuildsQueries { @@ -48,12 +55,34 @@ trait BuildsQueries return true; } + /** + * Run a map over each item while chunking. + * + * @param callable $callback + * @param int $count + * @return \Illuminate\Support\Collection + */ + public function chunkMap(callable $callback, $count = 1000) + { + $collection = Collection::make(); + + $this->chunk($count, function ($items) use ($collection, $callback) { + $items->each(function ($item) use ($collection, $callback) { + $collection->push($callback($item)); + }); + }); + + return $collection; + } + /** * Execute a callback over each item while chunking. * * @param callable $callback * @param int $count * @return bool + * + * @throws \RuntimeException */ public function each(callable $callback, $count = 1000) { @@ -83,6 +112,8 @@ trait BuildsQueries $lastId = null; + $page = 1; + do { $clone = clone $this; @@ -100,13 +131,19 @@ trait BuildsQueries // On each chunk result set, we will pass them to the callback and then let the // developer take care of everything within the callback, which allows us to // keep the memory low for spinning through large result sets for working. - if ($callback($results) === false) { + if ($callback($results, $page) === false) { return false; } $lastId = $results->last()->{$alias}; + if ($lastId === null) { + throw new RuntimeException("The chunkById operation was aborted because the [{$alias}] column is not present in the query result."); + } + unset($results); + + $page++; } while ($countResults == $count); return true; @@ -123,15 +160,89 @@ trait BuildsQueries */ public function eachById(callable $callback, $count = 1000, $column = null, $alias = null) { - return $this->chunkById($count, function ($results) use ($callback) { + return $this->chunkById($count, function ($results, $page) use ($callback, $count) { foreach ($results as $key => $value) { - if ($callback($value, $key) === false) { + if ($callback($value, (($page - 1) * $count) + $key) === false) { return false; } } }, $column, $alias); } + /** + * Query lazily, by chunks of the given size. + * + * @param int $chunkSize + * @return \Illuminate\Support\LazyCollection + * + * @throws \InvalidArgumentException + */ + public function lazy($chunkSize = 1000) + { + if ($chunkSize < 1) { + throw new InvalidArgumentException('The chunk size should be at least 1'); + } + + $this->enforceOrderBy(); + + return LazyCollection::make(function () use ($chunkSize) { + $page = 1; + + while (true) { + $results = $this->forPage($page++, $chunkSize)->get(); + + foreach ($results as $result) { + yield $result; + } + + if ($results->count() < $chunkSize) { + return; + } + } + }); + } + + /** + * Query lazily, by chunking the results of a query by comparing IDs. + * + * @param int $count + * @param string|null $column + * @param string|null $alias + * @return \Illuminate\Support\LazyCollection + * + * @throws \InvalidArgumentException + */ + public function lazyById($chunkSize = 1000, $column = null, $alias = null) + { + if ($chunkSize < 1) { + throw new InvalidArgumentException('The chunk size should be at least 1'); + } + + $column = $column ?? $this->defaultKeyName(); + + $alias = $alias ?? $column; + + return LazyCollection::make(function () use ($chunkSize, $column, $alias) { + $lastId = null; + + while (true) { + $clone = clone $this; + + $results = $clone->forPageAfterId($chunkSize, $lastId, $column)->get(); + + foreach ($results as $result) { + yield $result; + } + + if ($results->count() < $chunkSize) { + return; + } + + $lastId = $results->last()->{$alias}; + } + }); + } + /** * Execute the query and get the first result. * @@ -143,6 +254,30 @@ trait BuildsQueries return $this->take(1)->get($columns)->first(); } + /** + * Execute the query and get the first result if it's the sole matching record. + * + * @param array|string $columns + * @return \Illuminate\Database\Eloquent\Model|object|static|null + * + * @throws \Illuminate\Database\RecordsNotFoundException + * @throws \Illuminate\Database\MultipleRecordsFoundException + */ + public function sole($columns = ['*']) + { + $result = $this->take(2)->get($columns); + + if ($result->isEmpty()) { + throw new RecordsNotFoundException; + } + + if ($result->count() > 1) { + throw new MultipleRecordsFoundException; + } + + return $result->first(); + } + /** * Apply the callback's query changes if the given "value" is true. * @@ -224,4 +359,20 @@ trait BuildsQueries 'items', 'perPage', 'currentPage', 'options' )); } + + /** + * Create a new cursor paginator instance. + * + * @param \Illuminate\Support\Collection $items + * @param int $perPage + * @param \Illuminate\Pagination\Cursor $cursor + * @param array $options + * @return \Illuminate\Pagination\Paginator + */ + protected function cursorPaginator($items, $perPage, $cursor, $options) + { + return Container::getInstance()->makeWith(CursorPaginator::class, compact( + 'items', 'perPage', 'cursor', 'options' + )); + } } diff --git a/vendor/laravel/framework/src/Illuminate/Database/Concerns/ExplainsQueries.php b/vendor/laravel/framework/src/Illuminate/Database/Concerns/ExplainsQueries.php new file mode 100644 index 000000000..7168de1e5 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Concerns/ExplainsQueries.php @@ -0,0 +1,24 @@ +toSql(); + + $bindings = $this->getBindings(); + + $explanation = $this->getConnection()->select('EXPLAIN '.$sql, $bindings); + + return new Collection($explanation); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Concerns/ManagesTransactions.php b/vendor/laravel/framework/src/Illuminate/Database/Concerns/ManagesTransactions.php index 1dd447529..fac70295d 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Concerns/ManagesTransactions.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Concerns/ManagesTransactions.php @@ -3,6 +3,7 @@ namespace Illuminate\Database\Concerns; use Closure; +use RuntimeException; use Throwable; trait ManagesTransactions @@ -45,6 +46,10 @@ trait ManagesTransactions } $this->transactions = max(0, $this->transactions - 1); + + if ($this->transactions == 0) { + optional($this->transactionsManager)->commit($this->getName()); + } } catch (Throwable $e) { $this->handleCommitTransactionException( $e, $currentAttempt, $attempts @@ -78,6 +83,10 @@ trait ManagesTransactions $this->transactions > 1) { $this->transactions--; + optional($this->transactionsManager)->rollback( + $this->getName(), $this->transactions + ); + throw $e; } @@ -107,6 +116,10 @@ trait ManagesTransactions $this->transactions++; + optional($this->transactionsManager)->begin( + $this->getName(), $this->transactions + ); + $this->fireConnectionEvent('beganTransaction'); } @@ -180,6 +193,10 @@ trait ManagesTransactions $this->transactions = max(0, $this->transactions - 1); + if ($this->transactions == 0) { + optional($this->transactionsManager)->commit($this->getName()); + } + $this->fireConnectionEvent('committed'); } @@ -241,6 +258,10 @@ trait ManagesTransactions $this->transactions = $toLevel; + optional($this->transactionsManager)->rollback( + $this->getName(), $this->transactions + ); + $this->fireConnectionEvent('rollingBack'); } @@ -275,6 +296,10 @@ trait ManagesTransactions { if ($this->causedByLostConnection($e)) { $this->transactions = 0; + + optional($this->transactionsManager)->rollback( + $this->getName(), $this->transactions + ); } throw $e; @@ -289,4 +314,21 @@ trait ManagesTransactions { return $this->transactions; } + + /** + * Execute the callback after a transaction commits. + * + * @param callable $callback + * @return void + * + * @throws \RuntimeException + */ + public function afterCommit($callback) + { + if ($this->transactionsManager) { + return $this->transactionsManager->addCallback($callback); + } + + throw new RuntimeException('Transactions Manager has not been set.'); + } } diff --git a/vendor/laravel/framework/src/Illuminate/Database/Connection.php b/vendor/laravel/framework/src/Illuminate/Database/Connection.php index 6c7569225..71efec09d 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Connection.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Connection.php @@ -49,6 +49,13 @@ class Connection implements ConnectionInterface */ protected $database; + /** + * The type of the connection. + * + * @var string|null + */ + protected $type; + /** * The table prefix for the connection. * @@ -112,6 +119,13 @@ class Connection implements ConnectionInterface */ protected $transactions = 0; + /** + * The transaction manager instance. + * + * @var \Illuminate\Database\DatabaseTransactionsManager + */ + protected $transactionsManager; + /** * Indicates if changes have been made to the database. * @@ -860,6 +874,16 @@ class Connection implements ConnectionInterface } } + /** + * Reset the record modification state. + * + * @return void + */ + public function forgetRecordModificationState() + { + $this->recordsModified = false; + } + /** * Is Doctrine available? * @@ -891,7 +915,13 @@ class Connection implements ConnectionInterface */ public function getDoctrineSchemaManager() { - return $this->getDoctrineDriver()->getSchemaManager($this->getDoctrineConnection()); + $connection = $this->getDoctrineConnection(); + + // Doctrine v2 expects one parameter while v3 expects two. 2nd will be ignored on v2... + return $this->getDoctrineDriver()->getSchemaManager( + $connection, + $connection->getDatabasePlatform() + ); } /** @@ -907,7 +937,7 @@ class Connection implements ConnectionInterface $this->doctrineConnection = new DoctrineConnection(array_filter([ 'pdo' => $this->getPdo(), 'dbname' => $this->getDatabaseName(), - 'driver' => $driver->getName(), + 'driver' => method_exists($driver, 'getName') ? $driver->getName() : null, 'serverVersion' => $this->getConfig('server_version'), ]), $driver); } @@ -1022,6 +1052,16 @@ class Connection implements ConnectionInterface return $this->getConfig('name'); } + /** + * Get the database connection full name. + * + * @return string|null + */ + public function getNameWithReadWriteType() + { + return $this->getName().($this->readWriteType ? '::'.$this->readWriteType : ''); + } + /** * Get an option from the configuration options. * @@ -1145,6 +1185,29 @@ class Connection implements ConnectionInterface $this->events = null; } + /** + * Set the transaction manager instance on the connection. + * + * @param \Illuminate\Database\DatabaseTransactionsManager $manager + * @return $this + */ + public function setTransactionManager($manager) + { + $this->transactionsManager = $manager; + + return $this; + } + + /** + * Unset the transaction manager for this connection. + * + * @return void + */ + public function unsetTransactionManager() + { + $this->transactionsManager = null; + } + /** * Determine if the connection is in a "dry run". * @@ -1228,6 +1291,19 @@ class Connection implements ConnectionInterface return $this; } + /** + * Set the read / write type of the connection. + * + * @param string|null $readWriteType + * @return $this + */ + public function setReadWriteType($readWriteType) + { + $this->readWriteType = $readWriteType; + + return $this; + } + /** * Get the table prefix for the connection. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/ConnectionInterface.php b/vendor/laravel/framework/src/Illuminate/Database/ConnectionInterface.php index c7e24b1ab..00b23952a 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/ConnectionInterface.php +++ b/vendor/laravel/framework/src/Illuminate/Database/ConnectionInterface.php @@ -160,4 +160,11 @@ interface ConnectionInterface * @return array */ public function pretend(Closure $callback); + + /** + * Get the name of the connected database. + * + * @return string + */ + public function getDatabaseName(); } diff --git a/vendor/laravel/framework/src/Illuminate/Database/Console/DbCommand.php b/vendor/laravel/framework/src/Illuminate/Database/Console/DbCommand.php new file mode 100644 index 000000000..3aee98e2b --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Console/DbCommand.php @@ -0,0 +1,203 @@ +getConnection(); + + (new Process( + array_merge([$this->getCommand($connection)], $this->commandArguments($connection)), + null, + $this->commandEnvironment($connection) + ))->setTimeout(null)->setTty(true)->mustRun(function ($type, $buffer) { + $this->output->write($buffer); + }); + + return 0; + } + + /** + * Get the database connection configuration. + * + * @return array + * + * @throws \UnexpectedValueException + */ + public function getConnection() + { + $connection = $this->laravel['config']['database.connections.'. + (($db = $this->argument('connection')) ?? $this->laravel['config']['database.default']) + ]; + + if (empty($connection)) { + throw new UnexpectedValueException("Invalid database connection [{$db}]."); + } + + if (! empty($connection['url'])) { + $connection = (new ConfigurationUrlParser)->parseConfiguration($connection); + } + + return $connection; + } + + /** + * Get the arguments for the database client command. + * + * @param array $connection + * @return array + */ + public function commandArguments(array $connection) + { + $driver = ucfirst($connection['driver']); + + return $this->{"get{$driver}Arguments"}($connection); + } + + /** + * Get the environment variables for the database client command. + * + * @param array $connection + * @return array|null + */ + public function commandEnvironment(array $connection) + { + $driver = ucfirst($connection['driver']); + + if (method_exists($this, "get{$driver}Environment")) { + return $this->{"get{$driver}Environment"}($connection); + } + + return null; + } + + /** + * Get the database client command to run. + * + * @param array $connection + * @return string + */ + public function getCommand(array $connection) + { + return [ + 'mysql' => 'mysql', + 'pgsql' => 'psql', + 'sqlite' => 'sqlite3', + 'sqlsrv' => 'sqlcmd', + ][$connection['driver']]; + } + + /** + * Get the arguments for the MySQL CLI. + * + * @param array $connection + * @return array + */ + protected function getMysqlArguments(array $connection) + { + return array_merge([ + '--host='.$connection['host'], + '--port='.$connection['port'], + '--user='.$connection['username'], + ], $this->getOptionalArguments([ + 'password' => '--password='.$connection['password'], + 'unix_socket' => '--socket='.$connection['unix_socket'], + 'charset' => '--default-character-set='.$connection['charset'], + ], $connection), [$connection['database']]); + } + + /** + * Get the arguments for the Postgres CLI. + * + * @param array $connection + * @return array + */ + protected function getPgsqlArguments(array $connection) + { + return [$connection['database']]; + } + + /** + * Get the arguments for the SQLite CLI. + * + * @param array $connection + * @return array + */ + protected function getSqliteArguments(array $connection) + { + return [$connection['database']]; + } + + /** + * Get the arguments for the SQL Server CLI. + * + * @param array $connection + * @return array + */ + protected function getSqlsrvArguments(array $connection) + { + return array_merge(...$this->getOptionalArguments([ + 'database' => ['-d', $connection['database']], + 'username' => ['-U', $connection['username']], + 'password' => ['-P', $connection['password']], + 'host' => ['-S', 'tcp:'.$connection['host'] + .($connection['port'] ? ','.$connection['port'] : ''), ], + ], $connection)); + } + + /** + * Get the environment variables for the Postgres CLI. + * + * @param array $connection + * @return array|null + */ + protected function getPgsqlEnvironment(array $connection) + { + return array_merge(...$this->getOptionalArguments([ + 'username' => ['PGUSER' => $connection['username']], + 'host' => ['PGHOST' => $connection['host']], + 'port' => ['PGPORT' => $connection['port']], + 'password' => ['PGPASSWORD' => $connection['password']], + ], $connection)); + } + + /** + * Get the optional arguments based on the connection configuration. + * + * @param array $args + * @param array $connection + * @return array + */ + protected function getOptionalArguments(array $args, array $connection) + { + return array_values(array_filter($args, function ($key) use ($connection) { + return ! empty($connection[$key]); + }, ARRAY_FILTER_USE_KEY)); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Console/DumpCommand.php b/vendor/laravel/framework/src/Illuminate/Database/Console/DumpCommand.php new file mode 100644 index 000000000..fe73fb2af --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Console/DumpCommand.php @@ -0,0 +1,86 @@ +connection($database = $this->input->getOption('database')); + + $this->schemaState($connection)->dump( + $connection, $path = $this->path($connection) + ); + + $dispatcher->dispatch(new SchemaDumped($connection, $path)); + + $this->info('Database schema dumped successfully.'); + + if ($this->option('prune')) { + (new Filesystem)->deleteDirectory( + database_path('migrations'), $preserve = false + ); + + $this->info('Migrations pruned successfully.'); + } + } + + /** + * Create a schema state instance for the given connection. + * + * @param \Illuminate\Database\Connection $connection + * @return mixed + */ + protected function schemaState(Connection $connection) + { + return $connection->getSchemaState() + ->withMigrationTable($connection->getTablePrefix().Config::get('database.migrations', 'migrations')) + ->handleOutputUsing(function ($type, $buffer) { + $this->output->write($buffer); + }); + } + + /** + * Get the path that the dump should be written to. + * + * @param \Illuminate\Database\Connection $connection + */ + protected function path(Connection $connection) + { + return tap($this->option('path') ?: database_path('schema/'.$connection->getName().'-schema.dump'), function ($path) { + (new Filesystem)->ensureDirectoryExists(dirname($path)); + }); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Console/Factories/FactoryMakeCommand.php b/vendor/laravel/framework/src/Illuminate/Database/Console/Factories/FactoryMakeCommand.php index 3c0951588..6233fe29f 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Console/Factories/FactoryMakeCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Console/Factories/FactoryMakeCommand.php @@ -3,6 +3,7 @@ namespace Illuminate\Database\Console\Factories; use Illuminate\Console\GeneratorCommand; +use Illuminate\Support\Str; use Symfony\Component\Console\Input\InputOption; class FactoryMakeCommand extends GeneratorCommand @@ -59,19 +60,30 @@ class FactoryMakeCommand extends GeneratorCommand */ protected function buildClass($name) { + $factory = class_basename(Str::ucfirst(str_replace('Factory', '', $name))); + $namespaceModel = $this->option('model') - ? $this->qualifyClass($this->option('model')) - : trim($this->rootNamespace(), '\\').'\\Model'; + ? $this->qualifyModel($this->option('model')) + : $this->qualifyModel($this->guessModelName($name)); $model = class_basename($namespaceModel); + if (Str::startsWith($namespaceModel, $this->rootNamespace().'Models')) { + $namespace = Str::beforeLast('Database\\Factories\\'.Str::after($namespaceModel, $this->rootNamespace().'Models\\'), '\\'); + } else { + $namespace = 'Database\\Factories'; + } + $replace = [ + '{{ factoryNamespace }}' => $namespace, 'NamespacedDummyModel' => $namespaceModel, '{{ namespacedModel }}' => $namespaceModel, '{{namespacedModel}}' => $namespaceModel, 'DummyModel' => $model, '{{ model }}' => $model, '{{model}}' => $model, + '{{ factory }}' => $factory, + '{{factory}}' => $factory, ]; return str_replace( @@ -87,11 +99,34 @@ class FactoryMakeCommand extends GeneratorCommand */ protected function getPath($name) { - $name = str_replace( - ['\\', '/'], '', $this->argument('name') - ); + $name = (string) Str::of($name)->replaceFirst($this->rootNamespace(), '')->finish('Factory'); - return $this->laravel->databasePath()."/factories/{$name}.php"; + return $this->laravel->databasePath().'/factories/'.str_replace('\\', '/', $name).'.php'; + } + + /** + * Guess the model name from the Factory name or return a default model name. + * + * @param string $name + * @return string + */ + protected function guessModelName($name) + { + if (Str::endsWith($name, 'Factory')) { + $name = substr($name, 0, -7); + } + + $modelName = $this->qualifyModel(Str::after($name, $this->rootNamespace())); + + if (class_exists($modelName)) { + return $modelName; + } + + if (is_dir(app_path('Models/'))) { + return $this->rootNamespace().'Models\Model'; + } + + return $this->rootNamespace().'Model'; } /** diff --git a/vendor/laravel/framework/src/Illuminate/Database/Console/Factories/stubs/factory.stub b/vendor/laravel/framework/src/Illuminate/Database/Console/Factories/stubs/factory.stub index 5e1b10245..f7a898c9f 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Console/Factories/stubs/factory.stub +++ b/vendor/laravel/framework/src/Illuminate/Database/Console/Factories/stubs/factory.stub @@ -1,12 +1,28 @@ define({{ model }}::class, function (Faker $faker) { - return [ - // - ]; -}); +class {{ factory }}Factory extends Factory +{ + /** + * The name of the factory's corresponding model. + * + * @var string + */ + protected $model = {{ model }}::class; + + /** + * Define the model's default state. + * + * @return array + */ + public function definition() + { + return [ + // + ]; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Console/Migrations/FreshCommand.php b/vendor/laravel/framework/src/Illuminate/Database/Console/Migrations/FreshCommand.php index 29021e0c3..7bfba0d78 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Console/Migrations/FreshCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Console/Migrations/FreshCommand.php @@ -4,6 +4,8 @@ namespace Illuminate\Database\Console\Migrations; use Illuminate\Console\Command; use Illuminate\Console\ConfirmableTrait; +use Illuminate\Contracts\Events\Dispatcher; +use Illuminate\Database\Events\DatabaseRefreshed; use Symfony\Component\Console\Input\InputOption; class FreshCommand extends Command @@ -48,10 +50,17 @@ class FreshCommand extends Command '--database' => $database, '--path' => $this->input->getOption('path'), '--realpath' => $this->input->getOption('realpath'), + '--schema-path' => $this->input->getOption('schema-path'), '--force' => true, '--step' => $this->option('step'), ])); + if ($this->laravel->bound(Dispatcher::class)) { + $this->laravel[Dispatcher::class]->dispatch( + new DatabaseRefreshed + ); + } + if ($this->needsSeeding()) { $this->runSeeder($database); } @@ -79,7 +88,7 @@ class FreshCommand extends Command { $this->call('db:seed', array_filter([ '--database' => $database, - '--class' => $this->option('seeder') ?: 'DatabaseSeeder', + '--class' => $this->option('seeder') ?: 'Database\\Seeders\\DatabaseSeeder', '--force' => true, ])); } @@ -98,6 +107,7 @@ class FreshCommand extends Command ['force', null, InputOption::VALUE_NONE, 'Force the operation to run when in production'], ['path', null, InputOption::VALUE_OPTIONAL | InputOption::VALUE_IS_ARRAY, 'The path(s) to the migrations files to be executed'], ['realpath', null, InputOption::VALUE_NONE, 'Indicate any provided migration file paths are pre-resolved absolute paths'], + ['schema-path', null, InputOption::VALUE_OPTIONAL, 'The path to a schema dump file'], ['seed', null, InputOption::VALUE_NONE, 'Indicates if the seed task should be re-run'], ['seeder', null, InputOption::VALUE_OPTIONAL, 'The class name of the root seeder'], ['step', null, InputOption::VALUE_NONE, 'Force the migrations to be run so they can be rolled back individually'], diff --git a/vendor/laravel/framework/src/Illuminate/Database/Console/Migrations/MigrateCommand.php b/vendor/laravel/framework/src/Illuminate/Database/Console/Migrations/MigrateCommand.php index 688b67da8..ec35f8fed 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Console/Migrations/MigrateCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Console/Migrations/MigrateCommand.php @@ -3,7 +3,10 @@ namespace Illuminate\Database\Console\Migrations; use Illuminate\Console\ConfirmableTrait; +use Illuminate\Contracts\Events\Dispatcher; +use Illuminate\Database\Events\SchemaLoaded; use Illuminate\Database\Migrations\Migrator; +use Illuminate\Database\SqlServerConnection; class MigrateCommand extends BaseCommand { @@ -18,6 +21,7 @@ class MigrateCommand extends BaseCommand {--force : Force the operation to run when in production} {--path=* : The path(s) to the migrations files to be executed} {--realpath : Indicate any provided migration file paths are pre-resolved absolute paths} + {--schema-path= : The path to a schema dump file} {--pretend : Dump the SQL queries that would be run} {--seed : Indicates if the seed task should be re-run} {--step : Force the migrations to be run so they can be rolled back individually}'; @@ -36,17 +40,26 @@ class MigrateCommand extends BaseCommand */ protected $migrator; + /** + * The event dispatcher instance. + * + * @var \Illuminate\Contracts\Events\Dispatcher + */ + protected $dispatcher; + /** * Create a new migration command instance. * * @param \Illuminate\Database\Migrations\Migrator $migrator + * @param \Illuminate\Contracts\Events\Dispatcher $dispatcher * @return void */ - public function __construct(Migrator $migrator) + public function __construct(Migrator $migrator, Dispatcher $dispatcher) { parent::__construct(); $this->migrator = $migrator; + $this->dispatcher = $dispatcher; } /** @@ -95,5 +108,70 @@ class MigrateCommand extends BaseCommand '--database' => $this->option('database'), ])); } + + if (! $this->migrator->hasRunAnyMigrations() && ! $this->option('pretend')) { + $this->loadSchemaState(); + } + } + + /** + * Load the schema state to seed the initial database schema structure. + * + * @return void + */ + protected function loadSchemaState() + { + $connection = $this->migrator->resolveConnection($this->option('database')); + + // First, we will make sure that the connection supports schema loading and that + // the schema file exists before we proceed any further. If not, we will just + // continue with the standard migration operation as normal without errors. + if ($connection instanceof SqlServerConnection || + ! is_file($path = $this->schemaPath($connection))) { + return; + } + + $this->line('Loading stored database schema: '.$path); + + $startTime = microtime(true); + + // Since the schema file will create the "migrations" table and reload it to its + // proper state, we need to delete it here so we don't get an error that this + // table already exists when the stored database schema file gets executed. + $this->migrator->deleteRepository(); + + $connection->getSchemaState()->handleOutputUsing(function ($type, $buffer) { + $this->output->write($buffer); + })->load($path); + + $runTime = number_format((microtime(true) - $startTime) * 1000, 2); + + // Finally, we will fire an event that this schema has been loaded so developers + // can perform any post schema load tasks that are necessary in listeners for + // this event, which may seed the database tables with some necessary data. + $this->dispatcher->dispatch( + new SchemaLoaded($connection, $path) + ); + + $this->line('Loaded stored database schema. ('.$runTime.'ms)'); + } + + /** + * Get the path to the stored schema for the given connection. + * + * @param \Illuminate\Database\Connection $connection + * @return string + */ + protected function schemaPath($connection) + { + if ($this->option('schema-path')) { + return $this->option('schema-path'); + } + + if (file_exists($path = database_path('schema/'.$connection->getName().'-schema.dump'))) { + return $path; + } + + return database_path('schema/'.$connection->getName().'-schema.sql'); } } diff --git a/vendor/laravel/framework/src/Illuminate/Database/Console/Migrations/MigrateMakeCommand.php b/vendor/laravel/framework/src/Illuminate/Database/Console/Migrations/MigrateMakeCommand.php index 2c2a71155..95c3a206e 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Console/Migrations/MigrateMakeCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Console/Migrations/MigrateMakeCommand.php @@ -132,14 +132,4 @@ class MigrateMakeCommand extends BaseCommand return parent::getMigrationPath(); } - - /** - * Determine if the given path(s) are pre-resolved "real" paths. - * - * @return bool - */ - protected function usingRealPath() - { - return $this->input->hasOption('realpath') && $this->option('realpath'); - } } diff --git a/vendor/laravel/framework/src/Illuminate/Database/Console/Migrations/RefreshCommand.php b/vendor/laravel/framework/src/Illuminate/Database/Console/Migrations/RefreshCommand.php index 9a799c521..2073cd997 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Console/Migrations/RefreshCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Console/Migrations/RefreshCommand.php @@ -4,6 +4,8 @@ namespace Illuminate\Database\Console\Migrations; use Illuminate\Console\Command; use Illuminate\Console\ConfirmableTrait; +use Illuminate\Contracts\Events\Dispatcher; +use Illuminate\Database\Events\DatabaseRefreshed; use Symfony\Component\Console\Input\InputOption; class RefreshCommand extends Command @@ -63,6 +65,12 @@ class RefreshCommand extends Command '--force' => true, ])); + if ($this->laravel->bound(Dispatcher::class)) { + $this->laravel[Dispatcher::class]->dispatch( + new DatabaseRefreshed + ); + } + if ($this->needsSeeding()) { $this->runSeeder($database); } @@ -126,7 +134,7 @@ class RefreshCommand extends Command { $this->call('db:seed', array_filter([ '--database' => $database, - '--class' => $this->option('seeder') ?: 'DatabaseSeeder', + '--class' => $this->option('seeder') ?: 'Database\\Seeders\\DatabaseSeeder', '--force' => true, ])); } diff --git a/vendor/laravel/framework/src/Illuminate/Database/Console/Migrations/ResetCommand.php b/vendor/laravel/framework/src/Illuminate/Database/Console/Migrations/ResetCommand.php index 21b532979..1f2babbc8 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Console/Migrations/ResetCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Console/Migrations/ResetCommand.php @@ -67,8 +67,6 @@ class ResetCommand extends BaseCommand $this->getMigrationPaths(), $this->option('pretend') ); }); - - return 0; } /** diff --git a/vendor/laravel/framework/src/Illuminate/Database/Console/Seeds/SeedCommand.php b/vendor/laravel/framework/src/Illuminate/Database/Console/Seeds/SeedCommand.php index 2e4fdd709..058e545c2 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Console/Seeds/SeedCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Console/Seeds/SeedCommand.php @@ -6,6 +6,7 @@ use Illuminate\Console\Command; use Illuminate\Console\ConfirmableTrait; use Illuminate\Database\ConnectionResolverInterface as Resolver; use Illuminate\Database\Eloquent\Model; +use Symfony\Component\Console\Input\InputArgument; use Symfony\Component\Console\Input\InputOption; class SeedCommand extends Command @@ -81,9 +82,20 @@ class SeedCommand extends Command */ protected function getSeeder() { - $class = $this->laravel->make($this->input->getOption('class')); + $class = $this->input->getArgument('class') ?? $this->input->getOption('class'); - return $class->setContainer($this->laravel)->setCommand($this); + if (strpos($class, '\\') === false) { + $class = 'Database\\Seeders\\'.$class; + } + + if ($class === 'Database\\Seeders\\DatabaseSeeder' && + ! class_exists($class)) { + $class = 'DatabaseSeeder'; + } + + return $this->laravel->make($class) + ->setContainer($this->laravel) + ->setCommand($this); } /** @@ -98,6 +110,18 @@ class SeedCommand extends Command return $database ?: $this->laravel['config']['database.default']; } + /** + * Get the console command arguments. + * + * @return array + */ + protected function getArguments() + { + return [ + ['class', InputArgument::OPTIONAL, 'The class name of the root seeder', null], + ]; + } + /** * Get the console command options. * @@ -106,10 +130,8 @@ class SeedCommand extends Command protected function getOptions() { return [ - ['class', null, InputOption::VALUE_OPTIONAL, 'The class name of the root seeder', 'DatabaseSeeder'], - + ['class', null, InputOption::VALUE_OPTIONAL, 'The class name of the root seeder', 'Database\\Seeders\\DatabaseSeeder'], ['database', null, InputOption::VALUE_OPTIONAL, 'The database connection to seed'], - ['force', null, InputOption::VALUE_NONE, 'Force the operation to run when in production'], ]; } diff --git a/vendor/laravel/framework/src/Illuminate/Database/Console/Seeds/SeederMakeCommand.php b/vendor/laravel/framework/src/Illuminate/Database/Console/Seeds/SeederMakeCommand.php index 62ec1d46a..aef7a77e6 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Console/Seeds/SeederMakeCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Console/Seeds/SeederMakeCommand.php @@ -3,8 +3,6 @@ namespace Illuminate\Database\Console\Seeds; use Illuminate\Console\GeneratorCommand; -use Illuminate\Filesystem\Filesystem; -use Illuminate\Support\Composer; class SeederMakeCommand extends GeneratorCommand { @@ -29,27 +27,6 @@ class SeederMakeCommand extends GeneratorCommand */ protected $type = 'Seeder'; - /** - * The Composer instance. - * - * @var \Illuminate\Support\Composer - */ - protected $composer; - - /** - * Create a new command instance. - * - * @param \Illuminate\Filesystem\Filesystem $files - * @param \Illuminate\Support\Composer $composer - * @return void - */ - public function __construct(Filesystem $files, Composer $composer) - { - parent::__construct($files); - - $this->composer = $composer; - } - /** * Execute the console command. * @@ -58,8 +35,6 @@ class SeederMakeCommand extends GeneratorCommand public function handle() { parent::handle(); - - $this->composer->dumpAutoloads(); } /** @@ -80,7 +55,7 @@ class SeederMakeCommand extends GeneratorCommand */ protected function resolveStubPath($stub) { - return file_exists($customPath = $this->laravel->basePath(trim($stub, '/'))) + return is_file($customPath = $this->laravel->basePath(trim($stub, '/'))) ? $customPath : __DIR__.$stub; } @@ -93,7 +68,11 @@ class SeederMakeCommand extends GeneratorCommand */ protected function getPath($name) { - return $this->laravel->databasePath().'/seeds/'.$name.'.php'; + if (is_dir($this->laravel->databasePath().'/seeds')) { + return $this->laravel->databasePath().'/seeds/'.$name.'.php'; + } else { + return $this->laravel->databasePath().'/seeders/'.$name.'.php'; + } } /** diff --git a/vendor/laravel/framework/src/Illuminate/Database/Console/Seeds/stubs/seeder.stub b/vendor/laravel/framework/src/Illuminate/Database/Console/Seeds/stubs/seeder.stub index ee4d85d51..5662969c7 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Console/Seeds/stubs/seeder.stub +++ b/vendor/laravel/framework/src/Illuminate/Database/Console/Seeds/stubs/seeder.stub @@ -1,5 +1,7 @@ getName(); + + switch ($name) { + case 'mysql': + case 'mysql2': + return $this->getMySqlPlatformSQLDeclaration($fieldDeclaration); + + case 'postgresql': + case 'pgsql': + case 'postgres': + return $this->getPostgresPlatformSQLDeclaration($fieldDeclaration); + + case 'mssql': + return $this->getSqlServerPlatformSQLDeclaration($fieldDeclaration); + + case 'sqlite': + case 'sqlite3': + return $this->getSQLitePlatformSQLDeclaration($fieldDeclaration); + + default: + throw new DBALException('Invalid platform: '.$name); + } + } + + /** + * Get the SQL declaration for MySQL. + * + * @param array $fieldDeclaration + * @return string + */ + protected function getMySqlPlatformSQLDeclaration(array $fieldDeclaration) + { + $columnType = 'TIMESTAMP'; + + if ($fieldDeclaration['precision']) { + $columnType = 'TIMESTAMP('.$fieldDeclaration['precision'].')'; + } + + $notNull = $fieldDeclaration['notnull'] ?? false; + + if (! $notNull) { + return $columnType.' NULL'; + } + + return $columnType; + } + + /** + * Get the SQL declaration for PostgreSQL. + * + * @param array $fieldDeclaration + * @return string + */ + protected function getPostgresPlatformSQLDeclaration(array $fieldDeclaration) + { + return 'TIMESTAMP('.(int) $fieldDeclaration['precision'].')'; + } + + /** + * Get the SQL declaration for SQL Server. + * + * @param array $fieldDeclaration + * @return string + */ + protected function getSqlServerPlatformSQLDeclaration(array $fieldDeclaration) + { + return $fieldDeclaration['precision'] ?? false + ? 'DATETIME2('.$fieldDeclaration['precision'].')' + : 'DATETIME'; + } + + /** + * Get the SQL declaration for SQLite. + * + * @param array $fieldDeclaration + * @return string + */ + protected function getSQLitePlatformSQLDeclaration(array $fieldDeclaration) + { + return 'DATETIME'; + } + + /** + * {@inheritdoc} + */ + public function getName() + { + return 'timestamp'; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/DatabaseManager.php b/vendor/laravel/framework/src/Illuminate/Database/DatabaseManager.php index d558d1665..5d2f7cdcb 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/DatabaseManager.php +++ b/vendor/laravel/framework/src/Illuminate/Database/DatabaseManager.php @@ -62,7 +62,7 @@ class DatabaseManager implements ConnectionResolverInterface $this->factory = $factory; $this->reconnector = function ($connection) { - $this->reconnect($connection->getName()); + $this->reconnect($connection->getNameWithReadWriteType()); }; } @@ -165,7 +165,7 @@ class DatabaseManager implements ConnectionResolverInterface */ protected function configure(Connection $connection, $type) { - $connection = $this->setPdoForType($connection, $type); + $connection = $this->setPdoForType($connection, $type)->setReadWriteType($type); // First we'll set the fetch mode and a few other dependencies of the database // connection. This method basically just configures and prepares it to get @@ -174,6 +174,10 @@ class DatabaseManager implements ConnectionResolverInterface $connection->setEventDispatcher($this->app['events']); } + if ($this->app->bound('db.transactions')) { + $connection->setTransactionManager($this->app['db.transactions']); + } + // Here we'll set a reconnector callback. This reconnector can be any callable // so we will set a Closure to reconnect from this manager with the name of // the connection, which will allow us to reconnect from the connections. @@ -271,11 +275,15 @@ class DatabaseManager implements ConnectionResolverInterface */ protected function refreshPdoConnections($name) { - $fresh = $this->makeConnection($name); + [$database, $type] = $this->parseConnectionName($name); + + $fresh = $this->configure( + $this->makeConnection($database), $type + ); return $this->connections[$name] - ->setPdo($fresh->getRawPdo()) - ->setReadPdo($fresh->getRawReadPdo()); + ->setPdo($fresh->getRawPdo()) + ->setReadPdo($fresh->getRawReadPdo()); } /** @@ -355,6 +363,19 @@ class DatabaseManager implements ConnectionResolverInterface $this->reconnector = $reconnector; } + /** + * Set the application instance used by the manager. + * + * @param \Illuminate\Contracts\Foundation\Application $app + * @return $this + */ + public function setApplication($app) + { + $this->app = $app; + + return $this; + } + /** * Dynamically pass methods to the default connection. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/DatabaseServiceProvider.php b/vendor/laravel/framework/src/Illuminate/Database/DatabaseServiceProvider.php index 3008e5b6b..9f2ab1850 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/DatabaseServiceProvider.php +++ b/vendor/laravel/framework/src/Illuminate/Database/DatabaseServiceProvider.php @@ -2,11 +2,11 @@ namespace Illuminate\Database; +use Doctrine\DBAL\Types\Type; use Faker\Factory as FakerFactory; use Faker\Generator as FakerGenerator; use Illuminate\Contracts\Queue\EntityResolver; use Illuminate\Database\Connectors\ConnectionFactory; -use Illuminate\Database\Eloquent\Factory as EloquentFactory; use Illuminate\Database\Eloquent\Model; use Illuminate\Database\Eloquent\QueueEntityResolver; use Illuminate\Support\ServiceProvider; @@ -42,10 +42,9 @@ class DatabaseServiceProvider extends ServiceProvider Model::clearBootedModels(); $this->registerConnectionServices(); - $this->registerEloquentFactory(); - $this->registerQueueableEntityResolver(); + $this->registerDoctrineTypes(); } /** @@ -72,6 +71,10 @@ class DatabaseServiceProvider extends ServiceProvider $this->app->bind('db.connection', function ($app) { return $app['db']->connection(); }); + + $this->app->singleton('db.transactions', function ($app) { + return new DatabaseTransactionsManager; + }); } /** @@ -92,12 +95,6 @@ class DatabaseServiceProvider extends ServiceProvider return static::$fakers[$locale]; }); - - $this->app->singleton(EloquentFactory::class, function ($app) { - return EloquentFactory::construct( - $app->make(FakerGenerator::class), $this->app->databasePath('factories') - ); - }); } /** @@ -111,4 +108,24 @@ class DatabaseServiceProvider extends ServiceProvider return new QueueEntityResolver; }); } + + /** + * Register custom types with the Doctrine DBAL library. + * + * @return void + */ + protected function registerDoctrineTypes() + { + if (! class_exists(Type::class)) { + return; + } + + $types = $this->app['config']->get('database.dbal.types', []); + + foreach ($types as $name => $class) { + if (! Type::hasType($name)) { + Type::addType($name, $class); + } + } + } } diff --git a/vendor/laravel/framework/src/Illuminate/Database/DatabaseTransactionRecord.php b/vendor/laravel/framework/src/Illuminate/Database/DatabaseTransactionRecord.php new file mode 100755 index 000000000..3259552dc --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/DatabaseTransactionRecord.php @@ -0,0 +1,73 @@ +connection = $connection; + $this->level = $level; + } + + /** + * Register a callback to be executed after committing. + * + * @param callable $callback + * @return void + */ + public function addCallback($callback) + { + $this->callbacks[] = $callback; + } + + /** + * Execute all of the callbacks. + * + * @return void + */ + public function executeCallbacks() + { + foreach ($this->callbacks as $callback) { + call_user_func($callback); + } + } + + /** + * Get all of the callbacks. + * + * @return array + */ + public function getCallbacks() + { + return $this->callbacks; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/DatabaseTransactionsManager.php b/vendor/laravel/framework/src/Illuminate/Database/DatabaseTransactionsManager.php new file mode 100755 index 000000000..156514de6 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/DatabaseTransactionsManager.php @@ -0,0 +1,96 @@ +transactions = collect(); + } + + /** + * Start a new database transaction. + * + * @param string $connection + * @param int $level + * @return void + */ + public function begin($connection, $level) + { + $this->transactions->push( + new DatabaseTransactionRecord($connection, $level) + ); + } + + /** + * Rollback the active database transaction. + * + * @param string $connection + * @param int $level + * @return void + */ + public function rollback($connection, $level) + { + $this->transactions = $this->transactions->reject(function ($transaction) use ($connection, $level) { + return $transaction->connection == $connection && + $transaction->level > $level; + })->values(); + } + + /** + * Commit the active database transaction. + * + * @param string $connection + * @return void + */ + public function commit($connection) + { + $this->transactions = $this->transactions->reject(function ($transaction) use ($connection) { + if ($transaction->connection == $connection) { + $transaction->executeCallbacks(); + + return true; + } + + return false; + })->values(); + } + + /** + * Register a transaction callback. + * + * @param callable $callback + * @return void + */ + public function addCallback($callback) + { + if ($current = $this->transactions->last()) { + return $current->addCallback($callback); + } + + call_user_func($callback); + } + + /** + * Get all the transactions. + * + * @return \Illuminate\Support\Collection + */ + public function getTransactions() + { + return $this->transactions; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/DetectsLostConnections.php b/vendor/laravel/framework/src/Illuminate/Database/DetectsLostConnections.php index 07630c590..93be53b2f 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/DetectsLostConnections.php +++ b/vendor/laravel/framework/src/Illuminate/Database/DetectsLostConnections.php @@ -49,6 +49,11 @@ trait DetectsLostConnections 'SQLSTATE[HY000] [2002] Connection timed out', 'SSL: Connection timed out', 'SQLSTATE[HY000]: General error: 1105 The last transaction was aborted due to Seamless Scaling. Please retry.', + 'Temporary failure in name resolution', + 'SSL: Broken pipe', + 'SQLSTATE[08S01]: Communication link failure', + 'SQLSTATE[08006] [7] could not connect to server: Connection refused Is the server running on host', + 'SQLSTATE[HY000]: General error: 7 SSL SYSCALL error: No route to host', ]); } } diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Builder.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Builder.php index 66cd2ded4..49df237b5 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Builder.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Builder.php @@ -7,9 +7,13 @@ use Closure; use Exception; use Illuminate\Contracts\Support\Arrayable; use Illuminate\Database\Concerns\BuildsQueries; +use Illuminate\Database\Concerns\ExplainsQueries; use Illuminate\Database\Eloquent\Relations\BelongsToMany; use Illuminate\Database\Eloquent\Relations\Relation; use Illuminate\Database\Query\Builder as QueryBuilder; +use Illuminate\Database\RecordsNotFoundException; +use Illuminate\Pagination\CursorPaginationException; +use Illuminate\Pagination\CursorPaginator; use Illuminate\Pagination\Paginator; use Illuminate\Support\Arr; use Illuminate\Support\Str; @@ -24,7 +28,10 @@ use ReflectionMethod; */ class Builder { - use BuildsQueries, Concerns\QueriesRelationships, ForwardsCalls; + use Concerns\QueriesRelationships, ExplainsQueries, ForwardsCalls; + use BuildsQueries { + sole as baseSole; + } /** * The base query builder instance. @@ -71,11 +78,28 @@ class Builder /** * The methods that should be returned from query builder. * - * @var array + * @var string[] */ protected $passthru = [ - 'insert', 'insertOrIgnore', 'insertGetId', 'insertUsing', 'getBindings', 'toSql', 'dump', 'dd', - 'exists', 'doesntExist', 'count', 'min', 'max', 'avg', 'average', 'sum', 'getConnection', 'raw', 'getGrammar', + 'average', + 'avg', + 'count', + 'dd', + 'doesntExist', + 'dump', + 'exists', + 'getBindings', + 'getConnection', + 'getGrammar', + 'insert', + 'insertGetId', + 'insertOrIgnore', + 'insertUsing', + 'max', + 'min', + 'raw', + 'sum', + 'toSql', ]; /** @@ -188,6 +212,10 @@ class Builder */ public function whereKey($id) { + if ($id instanceof Model) { + $id = $id->getKey(); + } + if (is_array($id) || $id instanceof Arrayable) { $this->query->whereIn($this->model->getQualifiedKeyName(), $id); @@ -209,6 +237,10 @@ class Builder */ public function whereKeyNot($id) { + if ($id instanceof Model) { + $id = $id->getKey(); + } + if (is_array($id) || $id instanceof Arrayable) { $this->query->whereNotIn($this->model->getQualifiedKeyName(), $id); @@ -319,8 +351,14 @@ class Builder { $instance = $this->newModelInstance(); - return $instance->newCollection(array_map(function ($item) use ($instance) { - return $instance->newFromBuilder($item); + return $instance->newCollection(array_map(function ($item) use ($items, $instance) { + $model = $instance->newFromBuilder($item); + + if (count($items) > 1) { + $model->preventsLazyLoading = Model::preventsLazyLoading(); + } + + return $model; }, $items)); } @@ -439,7 +477,7 @@ class Builder * @param array $values * @return \Illuminate\Database\Eloquent\Model|static */ - public function firstOrCreate(array $attributes, array $values = []) + public function firstOrCreate(array $attributes = [], array $values = []) { if (! is_null($instance = $this->where($attributes)->first())) { return $instance; @@ -503,6 +541,24 @@ class Builder return $callback(); } + /** + * Execute the query and get the first result if it's the sole matching record. + * + * @param array|string $columns + * @return \Illuminate\Database\Eloquent\Model + * + * @throws \Illuminate\Database\Eloquent\ModelNotFoundException + * @throws \Illuminate\Database\MultipleRecordsFoundException + */ + public function sole($columns = ['*']) + { + try { + return $this->baseSole($columns); + } catch (RecordsNotFoundException $exception) { + throw (new ModelNotFoundException)->setModel(get_class($this->model)); + } + } + /** * Get a single column's value from the first result of a query. * @@ -764,6 +820,78 @@ class Builder ]); } + /** + * Paginate the given query into a cursor paginator. + * + * @param int|null $perPage + * @param array $columns + * @param string $cursorName + * @param string|null $cursor + * @return \Illuminate\Contracts\Pagination\Paginator + * @throws \Illuminate\Pagination\CursorPaginationException + */ + public function cursorPaginate($perPage = null, $columns = ['*'], $cursorName = 'cursor', $cursor = null) + { + $cursor = $cursor ?: CursorPaginator::resolveCurrentCursor($cursorName); + + $perPage = $perPage ?: $this->model->getPerPage(); + + $orders = $this->ensureOrderForCursorPagination(! is_null($cursor) && $cursor->pointsToPreviousItems()); + + $orderDirection = $orders->first()['direction'] ?? 'asc'; + + $comparisonOperator = $orderDirection === 'asc' ? '>' : '<'; + + $parameters = $orders->pluck('column')->toArray(); + + if (! is_null($cursor)) { + if (count($parameters) === 1) { + $this->where($column = $parameters[0], $comparisonOperator, $cursor->parameter($column)); + } elseif (count($parameters) > 1) { + $this->whereRowValues($parameters, $comparisonOperator, $cursor->parameters($parameters)); + } + } + + $this->take($perPage + 1); + + return $this->cursorPaginator($this->get($columns), $perPage, $cursor, [ + 'path' => Paginator::resolveCurrentPath(), + 'cursorName' => $cursorName, + 'parameters' => $parameters, + ]); + } + + /** + * Ensure the proper order by required for cursor pagination. + * + * @param bool $shouldReverse + * @return \Illuminate\Support\Collection + * + * @throws \Illuminate\Pagination\CursorPaginationException + */ + protected function ensureOrderForCursorPagination($shouldReverse = false) + { + $orderDirections = collect($this->query->orders)->pluck('direction')->unique(); + + if ($orderDirections->count() > 1) { + throw new CursorPaginationException('Only a single order by direction is supported when using cursor pagination.'); + } + + if ($orderDirections->count() === 0) { + $this->enforceOrderBy(); + } + + if ($shouldReverse) { + $this->query->orders = collect($this->query->orders)->map(function ($order) { + $order['direction'] = $order['direction'] === 'asc' ? 'desc' : 'asc'; + + return $order; + })->toArray(); + } + + return collect($this->query->orders); + } + /** * Save a new model and return the instance. * @@ -791,7 +919,7 @@ class Builder } /** - * Update a record in the database. + * Update records in the database. * * @param array $values * @return int @@ -801,6 +929,35 @@ class Builder return $this->toBase()->update($this->addUpdatedAtColumn($values)); } + /** + * Insert new records or update the existing ones. + * + * @param array $values + * @param array|string $uniqueBy + * @param array|null $update + * @return int + */ + public function upsert(array $values, $uniqueBy, $update = null) + { + if (empty($values)) { + return 0; + } + + if (! is_array(reset($values))) { + $values = [$values]; + } + + if (is_null($update)) { + $update = array_keys(reset($values)); + } + + return $this->toBase()->upsert( + $this->addTimestampsToUpsertValues($values), + $uniqueBy, + $this->addUpdatedAtToUpsertColumns($update) + ); + } + /** * Increment a column's value by a given amount. * @@ -863,7 +1020,58 @@ class Builder } /** - * Delete a record from the database. + * Add timestamps to the inserted values. + * + * @param array $values + * @return array + */ + protected function addTimestampsToUpsertValues(array $values) + { + if (! $this->model->usesTimestamps()) { + return $values; + } + + $timestamp = $this->model->freshTimestampString(); + + $columns = array_filter([ + $this->model->getCreatedAtColumn(), + $this->model->getUpdatedAtColumn(), + ]); + + foreach ($columns as $column) { + foreach ($values as &$row) { + $row = array_merge([$column => $timestamp], $row); + } + } + + return $values; + } + + /** + * Add the "updated at" column to the updated columns. + * + * @param array $update + * @return array + */ + protected function addUpdatedAtToUpsertColumns(array $update) + { + if (! $this->model->usesTimestamps()) { + return $update; + } + + $column = $this->model->getUpdatedAtColumn(); + + if (! is_null($column) && + ! array_key_exists($column, $update) && + ! in_array($column, $update)) { + $update[] = $column; + } + + return $update; + } + + /** + * Delete records from the database. * * @return mixed */ @@ -1084,12 +1292,17 @@ class Builder /** * Set the relationships that should be eager loaded. * - * @param mixed $relations + * @param string|array $relations + * @param string|\Closure|null $callback * @return $this */ - public function with($relations) + public function with($relations, $callback = null) { - $eagerLoad = $this->parseWithRelations(is_string($relations) ? func_get_args() : $relations); + if ($callback instanceof Closure) { + $eagerLoad = $this->parseWithRelations([$relations => $callback]); + } else { + $eagerLoad = $this->parseWithRelations(is_string($relations) ? func_get_args() : $relations); + } $this->eagerLoad = array_merge($this->eagerLoad, $eagerLoad); @@ -1111,6 +1324,19 @@ class Builder return $this; } + /** + * Set the relationships that should be eager loaded while removing any previously added eager loading specifications. + * + * @param mixed $relations + * @return $this + */ + public function withOnly($relations) + { + $this->eagerLoad = []; + + return $this->with($relations); + } + /** * Create a new instance of the model being queried. * @@ -1483,6 +1709,16 @@ class Builder } } + /** + * Clone the Eloquent query builder. + * + * @return static + */ + public function clone() + { + return clone $this; + } + /** * Force a clone of the underlying query builder when cloning. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Casts/ArrayObject.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Casts/ArrayObject.php new file mode 100644 index 000000000..596ed8360 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Casts/ArrayObject.php @@ -0,0 +1,40 @@ +getArrayCopy()); + } + + /** + * Get the instance as an array. + * + * @return array + */ + public function toArray() + { + return $this->getArrayCopy(); + } + + /** + * Get the array that should be JSON serialized. + * + * @return array + */ + public function jsonSerialize() + { + return $this->getArrayCopy(); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsArrayObject.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsArrayObject.php new file mode 100644 index 000000000..db9a21b46 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsArrayObject.php @@ -0,0 +1,36 @@ + json_encode($value)]; + } + + public function serialize($model, string $key, $value, array $attributes) + { + return $value->getArrayCopy(); + } + }; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsCollection.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsCollection.php new file mode 100644 index 000000000..585b6cfc7 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsCollection.php @@ -0,0 +1,32 @@ + json_encode($value)]; + } + }; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsEncryptedArrayObject.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsEncryptedArrayObject.php new file mode 100644 index 000000000..5918bc1b2 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsEncryptedArrayObject.php @@ -0,0 +1,37 @@ + Crypt::encryptString(json_encode($value))]; + } + + public function serialize($model, string $key, $value, array $attributes) + { + return $value->getArrayCopy(); + } + }; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsEncryptedCollection.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsEncryptedCollection.php new file mode 100644 index 000000000..ad11b1787 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Casts/AsEncryptedCollection.php @@ -0,0 +1,33 @@ + Crypt::encryptString(json_encode($value))]; + } + }; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Collection.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Collection.php index 17199e8b3..e8435ce3d 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Collection.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Collection.php @@ -64,12 +64,14 @@ class Collection extends BaseCollection implements QueueableCollection } /** - * Load a set of relationship counts onto the collection. + * Load a set of aggregations over relationship's column onto the collection. * * @param array|string $relations + * @param string $column + * @param string $function * @return $this */ - public function loadCount($relations) + public function loadAggregate($relations, $column, $function = null) { if ($this->isEmpty()) { return $this; @@ -78,7 +80,7 @@ class Collection extends BaseCollection implements QueueableCollection $models = $this->first()->newModelQuery() ->whereKey($this->modelKeys()) ->select($this->first()->getKeyName()) - ->withCount(...func_get_args()) + ->withAggregate($relations, $column, $function) ->get() ->keyBy($this->first()->getKeyName()); @@ -96,6 +98,76 @@ class Collection extends BaseCollection implements QueueableCollection return $this; } + /** + * Load a set of relationship counts onto the collection. + * + * @param array|string $relations + * @return $this + */ + public function loadCount($relations) + { + return $this->loadAggregate($relations, '*', 'count'); + } + + /** + * Load a set of relationship's max column values onto the collection. + * + * @param array|string $relations + * @param string $column + * @return $this + */ + public function loadMax($relations, $column) + { + return $this->loadAggregate($relations, $column, 'max'); + } + + /** + * Load a set of relationship's min column values onto the collection. + * + * @param array|string $relations + * @param string $column + * @return $this + */ + public function loadMin($relations, $column) + { + return $this->loadAggregate($relations, $column, 'min'); + } + + /** + * Load a set of relationship's column summations onto the collection. + * + * @param array|string $relations + * @param string $column + * @return $this + */ + public function loadSum($relations, $column) + { + return $this->loadAggregate($relations, $column, 'sum'); + } + + /** + * Load a set of relationship's average column values onto the collection. + * + * @param array|string $relations + * @param string $column + * @return $this + */ + public function loadAvg($relations, $column) + { + return $this->loadAggregate($relations, $column, 'avg'); + } + + /** + * Load a set of related existences onto the collection. + * + * @param array|string $relations + * @return $this + */ + public function loadExists($relations) + { + return $this->loadAggregate($relations, '*', 'exists'); + } + /** * Load a set of relationships onto the collection if they are not already eager loaded. * @@ -317,9 +389,11 @@ class Collection extends BaseCollection implements QueueableCollection ->get() ->getDictionary(); - return $this->map(function ($model) use ($freshModels) { - return $model->exists && isset($freshModels[$model->getKey()]) - ? $freshModels[$model->getKey()] : null; + return $this->filter(function ($model) use ($freshModels) { + return $model->exists && isset($freshModels[$model->getKey()]); + }) + ->map(function ($model) use ($freshModels) { + return $freshModels[$model->getKey()]; }); } diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/GuardsAttributes.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/GuardsAttributes.php index d7e4ac8a4..60b510ced 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/GuardsAttributes.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/GuardsAttributes.php @@ -9,14 +9,14 @@ trait GuardsAttributes /** * The attributes that are mass assignable. * - * @var array + * @var string[] */ protected $fillable = []; /** * The attributes that aren't mass assignable. * - * @var array + * @var string[]|bool */ protected $guarded = ['*']; @@ -77,7 +77,9 @@ trait GuardsAttributes */ public function getGuarded() { - return $this->guarded; + return $this->guarded === false + ? [] + : $this->guarded; } /** @@ -128,7 +130,7 @@ trait GuardsAttributes } /** - * Determine if current state is "unguarded". + * Determine if the current state is "unguarded". * * @return bool */ diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HasAttributes.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HasAttributes.php index 498e87195..56b52971a 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HasAttributes.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HasAttributes.php @@ -7,13 +7,17 @@ use DateTimeInterface; use Illuminate\Contracts\Database\Eloquent\Castable; use Illuminate\Contracts\Database\Eloquent\CastsInboundAttributes; use Illuminate\Contracts\Support\Arrayable; +use Illuminate\Database\Eloquent\InvalidCastException; use Illuminate\Database\Eloquent\JsonEncodingException; use Illuminate\Database\Eloquent\Relations\Relation; +use Illuminate\Database\LazyLoadingViolationException; use Illuminate\Support\Arr; use Illuminate\Support\Carbon; use Illuminate\Support\Collection as BaseCollection; +use Illuminate\Support\Facades\Crypt; use Illuminate\Support\Facades\Date; use Illuminate\Support\Str; +use InvalidArgumentException; use LogicException; trait HasAttributes @@ -56,7 +60,7 @@ trait HasAttributes /** * The built-in, primitive cast types supported by Eloquent. * - * @var array + * @var string[] */ protected static $primitiveCastTypes = [ 'array', @@ -68,6 +72,11 @@ trait HasAttributes 'datetime', 'decimal', 'double', + 'encrypted', + 'encrypted:array', + 'encrypted:collection', + 'encrypted:json', + 'encrypted:object', 'float', 'int', 'integer', @@ -81,6 +90,8 @@ trait HasAttributes /** * The attributes that should be mutated to dates. * + * @deprecated Use the "casts" property + * * @var array */ protected $dates = []; @@ -113,6 +124,13 @@ trait HasAttributes */ protected static $mutatorCache = []; + /** + * The encrypter instance that is used to encrypt attributes. + * + * @var \Illuminate\Contracts\Encryption\Encrypter + */ + public static $encrypter; + /** * Convert the model's attributes to an array. * @@ -236,6 +254,10 @@ trait HasAttributes $attributes[$key] = $this->serializeDate($attributes[$key]); } + if ($attributes[$key] && $this->isClassSerializable($key)) { + $attributes[$key] = $this->serializeClassCastableAttribute($key, $attributes[$key]); + } + if ($attributes[$key] instanceof Arrayable) { $attributes[$key] = $attributes[$key]->toArray(); } @@ -412,13 +434,45 @@ trait HasAttributes return $this->relations[$key]; } + if (! $this->isRelation($key)) { + return; + } + + if ($this->preventsLazyLoading) { + $this->handleLazyLoadingViolation($key); + } + // If the "attribute" exists as a method on the model, we will just assume // it is a relationship and will load and return results from the query // and hydrate the relationship's value on the "relationships" array. - if (method_exists($this, $key) || - (static::$relationResolvers[get_class($this)][$key] ?? null)) { - return $this->getRelationshipFromMethod($key); + return $this->getRelationshipFromMethod($key); + } + + /** + * Determine if the given key is a relationship method on the model. + * + * @param string $key + * @return bool + */ + public function isRelation($key) + { + return method_exists($this, $key) || + (static::$relationResolvers[get_class($this)][$key] ?? null); + } + + /** + * Handle a lazy loading violation. + * + * @param string $key + * @return mixed + */ + protected function handleLazyLoadingViolation($key) + { + if (isset(static::$lazyLoadingViolationCallback)) { + return call_user_func(static::$lazyLoadingViolationCallback, $this, $key); } + + throw new LazyLoadingViolationException($this, $key); } /** @@ -493,11 +547,13 @@ trait HasAttributes * Merge new casts with existing casts on the model. * * @param array $casts - * @return void + * @return $this */ public function mergeCasts($casts) { $this->casts = array_merge($this->casts, $casts); + + return $this; } /** @@ -515,6 +571,15 @@ trait HasAttributes return $value; } + // If the key is one of the encrypted castable types, we'll first decrypt + // the value and update the cast type so we may leverage the following + // logic for casting this value to any additionally specified types. + if ($this->isEncryptedCastable($key)) { + $value = $this->fromEncryptedString($value); + + $castType = Str::after($castType, 'encrypted:'); + } + switch ($castType) { case 'int': case 'integer': @@ -600,6 +665,35 @@ trait HasAttributes return trim(strtolower($this->getCasts()[$key])); } + /** + * Increment or decrement the given attribute using the custom cast class. + * + * @param string $method + * @param string $key + * @param mixed $value + * @return mixed + */ + protected function deviateClassCastableAttribute($method, $key, $value) + { + return $this->resolveCasterClass($key)->{$method}( + $this, $key, $value, $this->attributes + ); + } + + /** + * Serialize the given attribute using the custom cast class. + * + * @param string $key + * @param mixed $value + * @return mixed + */ + protected function serializeClassCastableAttribute($key, $value) + { + return $this->resolveCasterClass($key)->serialize( + $this, $key, $value, $this->attributes + ); + } + /** * Determine if the cast type is a custom date time cast. * @@ -634,7 +728,7 @@ trait HasAttributes { // First we will check for the presence of a mutator for the set operation // which simply lets the developers tweak the attribute as it is set on - // the model, such as "json_encoding" an listing of data for storage. + // this model, such as "json_encoding" a listing of data for storage. if ($this->hasSetMutator($key)) { return $this->setMutatedAttributeValue($key, $value); } @@ -652,7 +746,7 @@ trait HasAttributes return $this; } - if ($this->isJsonCastable($key) && ! is_null($value)) { + if (! is_null($value) && $this->isJsonCastable($key)) { $value = $this->castAttributeAsJson($key, $value); } @@ -663,6 +757,10 @@ trait HasAttributes return $this->fillJsonAttribute($key, $value); } + if (! is_null($value) && $this->isEncryptedCastable($key)) { + $value = $this->castAttributeAsEncryptedString($key, $value); + } + $this->attributes[$key] = $value; return $this; @@ -700,7 +798,7 @@ trait HasAttributes protected function isDateAttribute($key) { return in_array($key, $this->getDates(), true) || - $this->isDateCastable($key); + $this->isDateCastable($key); } /** @@ -714,10 +812,14 @@ trait HasAttributes { [$key, $path] = explode('->', $key, 2); - $this->attributes[$key] = $this->asJson($this->getArrayAttributeWithValue( + $value = $this->asJson($this->getArrayAttributeWithValue( $path, $key, $value )); + $this->attributes[$key] = $this->isEncryptedCastable($key) + ? $this->castAttributeAsEncryptedString($key, $value) + : $value; + return $this; } @@ -779,8 +881,15 @@ trait HasAttributes */ protected function getArrayAttributeByKey($key) { - return isset($this->attributes[$key]) ? - $this->fromJson($this->attributes[$key]) : []; + if (! isset($this->attributes[$key])) { + return []; + } + + return $this->fromJson( + $this->isEncryptedCastable($key) + ? $this->fromEncryptedString($this->attributes[$key]) + : $this->attributes[$key] + ); } /** @@ -826,6 +935,40 @@ trait HasAttributes return json_decode($value, ! $asObject); } + /** + * Decrypt the given encrypted string. + * + * @param string $value + * @return mixed + */ + public function fromEncryptedString($value) + { + return (static::$encrypter ?? Crypt::getFacadeRoot())->decrypt($value, false); + } + + /** + * Cast the given attribute to an encrypted string. + * + * @param string $key + * @param mixed $value + * @return string + */ + protected function castAttributeAsEncryptedString($key, $value) + { + return (static::$encrypter ?? Crypt::getFacadeRoot())->encrypt($value, false); + } + + /** + * Set the encrypter instance that will be used to encrypt attributes. + * + * @param \Illuminate\Contracts\Encryption\Encrypter $encrypter + * @return void + */ + public static function encryptUsing($encrypter) + { + static::$encrypter = $encrypter; + } + /** * Decode the given float. * @@ -912,11 +1055,13 @@ trait HasAttributes // Finally, we will just assume this date is in the format used by default on // the database connection and use that format to create the Carbon object // that is returned back out to the developers after we convert it here. - if (Date::hasFormat($value, $format)) { - return Date::createFromFormat($format, $value); + try { + $date = Date::createFromFormat($format, $value); + } catch (InvalidArgumentException $e) { + $date = false; } - return Date::parse($value); + return $date ?: Date::parse($value); } /** @@ -1056,7 +1201,18 @@ trait HasAttributes */ protected function isJsonCastable($key) { - return $this->hasCast($key, ['array', 'json', 'object', 'collection']); + return $this->hasCast($key, ['array', 'json', 'object', 'collection', 'encrypted:array', 'encrypted:collection', 'encrypted:json', 'encrypted:object']); + } + + /** + * Determine whether a value is an encrypted castable for inbound manipulation. + * + * @param string $key + * @return bool + */ + protected function isEncryptedCastable($key) + { + return $this->hasCast($key, ['encrypted', 'encrypted:array', 'encrypted:collection', 'encrypted:json', 'encrypted:object']); } /** @@ -1064,12 +1220,55 @@ trait HasAttributes * * @param string $key * @return bool + * + * @throws \Illuminate\Database\Eloquent\InvalidCastException */ protected function isClassCastable($key) { - return array_key_exists($key, $this->getCasts()) && - class_exists($class = $this->parseCasterClass($this->getCasts()[$key])) && - ! in_array($class, static::$primitiveCastTypes); + if (! array_key_exists($key, $this->getCasts())) { + return false; + } + + $castType = $this->parseCasterClass($this->getCasts()[$key]); + + if (in_array($castType, static::$primitiveCastTypes)) { + return false; + } + + if (class_exists($castType)) { + return true; + } + + throw new InvalidCastException($this->getModel(), $key, $castType); + } + + /** + * Determine if the key is deviable using a custom class. + * + * @param string $key + * @return bool + * + * @throws \Illuminate\Database\Eloquent\InvalidCastException + */ + protected function isClassDeviable($key) + { + return $this->isClassCastable($key) && + method_exists($castType = $this->parseCasterClass($this->getCasts()[$key]), 'increment') && + method_exists($castType, 'decrement'); + } + + /** + * Determine if the key is serializable using a custom class. + * + * @param string $key + * @return bool + * + * @throws \Illuminate\Database\Eloquent\InvalidCastException + */ + protected function isClassSerializable($key) + { + return $this->isClassCastable($key) && + method_exists($this->parseCasterClass($this->getCasts()[$key]), 'serialize'); } /** @@ -1092,7 +1291,7 @@ trait HasAttributes } if (is_subclass_of($castType, Castable::class)) { - $castType = $castType::castUsing(); + $castType = $castType::castUsing($arguments); } if (is_object($castType)) { @@ -1158,6 +1357,16 @@ trait HasAttributes return $this->attributes; } + /** + * Get all of the current attributes on the model for an insert operation. + * + * @return array + */ + protected function getAttributesForInsert() + { + return $this->getAttributes(); + } + /** * Set the array of model attributes. No checking is done. * @@ -1361,7 +1570,7 @@ trait HasAttributes } /** - * Get the attributes that have been changed since last sync. + * Get the attributes that have been changed since the last sync. * * @return array */ diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HasRelationships.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HasRelationships.php index 3406fe51e..5262d4305 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HasRelationships.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HasRelationships.php @@ -39,7 +39,7 @@ trait HasRelationships /** * The many to many relationship methods. * - * @var array + * @var string[] */ public static $manyMethods = [ 'belongsToMany', 'morphToMany', 'morphedByMany', @@ -256,7 +256,7 @@ trait HasRelationships // If the type value is null it is probably safe to assume we're eager loading // the relationship. In this case we'll just pass in a dummy query where we // need to remove any eager loads that may already be defined on a model. - return is_null($class = $this->{$type}) || $class === '' + return is_null($class = $this->getAttributeFromArray($type)) || $class === '' ? $this->morphEagerTo($name, $type, $id, $ownerKey) : $this->morphInstanceTo($class, $name, $type, $id, $ownerKey); } diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HasTimestamps.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HasTimestamps.php index b9c049b36..13ebd3174 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HasTimestamps.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HasTimestamps.php @@ -34,7 +34,7 @@ trait HasTimestamps * * @return void */ - protected function updateTimestamps() + public function updateTimestamps() { $time = $this->freshTimestamp(); @@ -130,7 +130,7 @@ trait HasTimestamps /** * Get the fully qualified "created at" column. * - * @return string + * @return string|null */ public function getQualifiedCreatedAtColumn() { @@ -140,7 +140,7 @@ trait HasTimestamps /** * Get the fully qualified "updated at" column. * - * @return string + * @return string|null */ public function getQualifiedUpdatedAtColumn() { diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HidesAttributes.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HidesAttributes.php index 7f6ebfdbc..065d48a8d 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HidesAttributes.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HidesAttributes.php @@ -94,9 +94,7 @@ trait HidesAttributes */ public function makeVisibleIf($condition, $attributes) { - $condition = $condition instanceof Closure ? $condition($this) : $condition; - - return $condition ? $this->makeVisible($attributes) : $this; + return value($condition, $this) ? $this->makeVisible($attributes) : $this; } /** @@ -123,8 +121,6 @@ trait HidesAttributes */ public function makeHiddenIf($condition, $attributes) { - $condition = $condition instanceof Closure ? $condition($this) : $condition; - - return value($condition) ? $this->makeHidden($attributes) : $this; + return value($condition, $this) ? $this->makeHidden($attributes) : $this; } } diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/QueriesRelationships.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/QueriesRelationships.php index c97c40330..b310c5304 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/QueriesRelationships.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/QueriesRelationships.php @@ -9,7 +9,6 @@ use Illuminate\Database\Eloquent\Relations\Relation; use Illuminate\Database\Query\Builder as QueryBuilder; use Illuminate\Database\Query\Expression; use Illuminate\Support\Str; -use RuntimeException; trait QueriesRelationships { @@ -36,7 +35,7 @@ trait QueriesRelationships } if ($relation instanceof MorphTo) { - throw new RuntimeException('Please use whereHasMorph() for MorphTo relationships.'); + return $this->hasMorph($relation, ['*'], $operator, $count, $boolean, $callback); } // If we only need to check for the existence of the relation, then we can optimize @@ -189,7 +188,7 @@ trait QueriesRelationships /** * Add a polymorphic relationship count / exists condition to the query. * - * @param string $relation + * @param \Illuminate\Database\Eloquent\Relations\MorphTo|string $relation * @param string|array $types * @param string $operator * @param int $count @@ -199,7 +198,9 @@ trait QueriesRelationships */ public function hasMorph($relation, $types, $operator = '>=', $count = 1, $boolean = 'and', Closure $callback = null) { - $relation = $this->getRelationWithoutConstraints($relation); + if (is_string($relation)) { + $relation = $this->getRelationWithoutConstraints($relation); + } $types = (array) $types; @@ -222,7 +223,7 @@ trait QueriesRelationships }; } - $query->where($this->query->from.'.'.$relation->getMorphType(), '=', (new $type)->getMorphClass()) + $query->where($this->qualifyColumn($relation->getMorphType()), '=', (new $type)->getMorphClass()) ->whereHas($belongsTo, $callback, $operator, $count); }); } @@ -254,7 +255,7 @@ trait QueriesRelationships /** * Add a polymorphic relationship count / exists condition to the query with an "or". * - * @param string $relation + * @param \Illuminate\Database\Eloquent\Relations\MorphTo|string $relation * @param string|array $types * @param string $operator * @param int $count @@ -268,7 +269,7 @@ trait QueriesRelationships /** * Add a polymorphic relationship count / exists condition to the query. * - * @param string $relation + * @param \Illuminate\Database\Eloquent\Relations\MorphTo|string $relation * @param string|array $types * @param string $boolean * @param \Closure|null $callback @@ -282,7 +283,7 @@ trait QueriesRelationships /** * Add a polymorphic relationship count / exists condition to the query with an "or". * - * @param string $relation + * @param \Illuminate\Database\Eloquent\Relations\MorphTo|string $relation * @param string|array $types * @return \Illuminate\Database\Eloquent\Builder|static */ @@ -294,7 +295,7 @@ trait QueriesRelationships /** * Add a polymorphic relationship count / exists condition to the query with where clauses. * - * @param string $relation + * @param \Illuminate\Database\Eloquent\Relations\MorphTo|string $relation * @param string|array $types * @param \Closure|null $callback * @param string $operator @@ -309,7 +310,7 @@ trait QueriesRelationships /** * Add a polymorphic relationship count / exists condition to the query with where clauses and an "or". * - * @param string $relation + * @param \Illuminate\Database\Eloquent\Relations\MorphTo|string $relation * @param string|array $types * @param \Closure|null $callback * @param string $operator @@ -324,7 +325,7 @@ trait QueriesRelationships /** * Add a polymorphic relationship count / exists condition to the query with where clauses. * - * @param string $relation + * @param \Illuminate\Database\Eloquent\Relations\MorphTo|string $relation * @param string|array $types * @param \Closure|null $callback * @return \Illuminate\Database\Eloquent\Builder|static @@ -337,7 +338,7 @@ trait QueriesRelationships /** * Add a polymorphic relationship count / exists condition to the query with where clauses and an "or". * - * @param string $relation + * @param \Illuminate\Database\Eloquent\Relations\MorphTo|string $relation * @param string|array $types * @param \Closure|null $callback * @return \Illuminate\Database\Eloquent\Builder|static @@ -348,12 +349,14 @@ trait QueriesRelationships } /** - * Add subselect queries to count the relations. + * Add subselect queries to include an aggregate value for a relationship. * * @param mixed $relations + * @param string $column + * @param string $function * @return $this */ - public function withCount($relations) + public function withAggregate($relations, $column, $function = null) { if (empty($relations)) { return $this; @@ -363,12 +366,12 @@ trait QueriesRelationships $this->query->select([$this->query->from.'.*']); } - $relations = is_array($relations) ? $relations : func_get_args(); + $relations = is_array($relations) ? $relations : [$relations]; foreach ($this->parseWithRelations($relations) as $name => $constraints) { // First we will determine if the name has been aliased using an "as" clause on the name // and if it has we will extract the actual relationship name and the desired name of - // the resulting column. This allows multiple counts on the same relationship name. + // the resulting column. This allows multiple aggregates on the same relationships. $segments = explode(' ', $name); unset($alias); @@ -379,38 +382,135 @@ trait QueriesRelationships $relation = $this->getRelationWithoutConstraints($name); - // Here we will get the relationship count query and prepare to add it to the main query + if ($function) { + $hashedColumn = $this->getQuery()->from === $relation->getQuery()->getQuery()->from + ? "{$relation->getRelationCountHash(false)}.$column" + : $column; + + $wrappedColumn = $this->getQuery()->getGrammar()->wrap( + $column === '*' ? $column : $relation->getRelated()->qualifyColumn($hashedColumn) + ); + + $expression = $function === 'exists' ? $wrappedColumn : sprintf('%s(%s)', $function, $wrappedColumn); + } else { + $expression = $column; + } + + // Here, we will grab the relationship sub-query and prepare to add it to the main query // as a sub-select. First, we'll get the "has" query and use that to get the relation - // count query. We will normalize the relation name then append _count as the name. - $query = $relation->getRelationExistenceCountQuery( - $relation->getRelated()->newQuery(), $this - ); + // sub-query. We'll format this relationship name and append this column if needed. + $query = $relation->getRelationExistenceQuery( + $relation->getRelated()->newQuery(), $this, new Expression($expression) + )->setBindings([], 'select'); $query->callScope($constraints); $query = $query->mergeConstraintsFrom($relation->getQuery())->toBase(); + // If the query contains certain elements like orderings / more than one column selected + // then we will remove those elements from the query so that it will execute properly + // when given to the database. Otherwise, we may receive SQL errors or poor syntax. $query->orders = null; - $query->setBindings([], 'order'); if (count($query->columns) > 1) { $query->columns = [$query->columns[0]]; - $query->bindings['select'] = []; } - // Finally we will add the proper result column alias to the query and run the subselect - // statement against the query builder. Then we will return the builder instance back - // to the developer for further constraint chaining that needs to take place on it. - $column = $alias ?? Str::snake($name.'_count'); + // Finally, we will make the proper column alias to the query and run this sub-select on + // the query builder. Then, we will return the builder instance back to the developer + // for further constraint chaining that needs to take place on the query as needed. + $alias = $alias ?? Str::snake( + preg_replace('/[^[:alnum:][:space:]_]/u', '', "$name $function $column") + ); - $this->selectSub($query, $column); + if ($function === 'exists') { + $this->selectRaw( + sprintf('exists(%s) as %s', $query->toSql(), $this->getQuery()->grammar->wrap($alias)), + $query->getBindings() + )->withCasts([$alias => 'bool']); + } else { + $this->selectSub( + $function ? $query : $query->limit(1), + $alias + ); + } } return $this; } + /** + * Add subselect queries to count the relations. + * + * @param mixed $relations + * @return $this + */ + public function withCount($relations) + { + return $this->withAggregate(is_array($relations) ? $relations : func_get_args(), '*', 'count'); + } + + /** + * Add subselect queries to include the max of the relation's column. + * + * @param string|array $relation + * @param string $column + * @return $this + */ + public function withMax($relation, $column) + { + return $this->withAggregate($relation, $column, 'max'); + } + + /** + * Add subselect queries to include the min of the relation's column. + * + * @param string|array $relation + * @param string $column + * @return $this + */ + public function withMin($relation, $column) + { + return $this->withAggregate($relation, $column, 'min'); + } + + /** + * Add subselect queries to include the sum of the relation's column. + * + * @param string|array $relation + * @param string $column + * @return $this + */ + public function withSum($relation, $column) + { + return $this->withAggregate($relation, $column, 'sum'); + } + + /** + * Add subselect queries to include the average of the relation's column. + * + * @param string|array $relation + * @param string $column + * @return $this + */ + public function withAvg($relation, $column) + { + return $this->withAggregate($relation, $column, 'avg'); + } + + /** + * Add subselect queries to include the existence of related models. + * + * @param string|array $relation + * @return $this + */ + public function withExists($relation) + { + return $this->withAggregate($relation, '*', 'exists'); + } + /** * Add the "has" condition where clause to the query. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/BelongsToManyRelationship.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/BelongsToManyRelationship.php new file mode 100644 index 000000000..e0c42c4c6 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/BelongsToManyRelationship.php @@ -0,0 +1,61 @@ +factory = $factory; + $this->pivot = $pivot; + $this->relationship = $relationship; + } + + /** + * Create the attached relationship for the given model. + * + * @param \Illuminate\Database\Eloquent\Model $model + * @return void + */ + public function createFor(Model $model) + { + Collection::wrap($this->factory instanceof Factory ? $this->factory->create([], $model) : $this->factory)->each(function ($attachable) use ($model) { + $model->{$this->relationship}()->attach( + $attachable, + is_callable($this->pivot) ? call_user_func($this->pivot, $model) : $this->pivot + ); + }); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/BelongsToRelationship.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/BelongsToRelationship.php new file mode 100644 index 000000000..55747fdc6 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/BelongsToRelationship.php @@ -0,0 +1,80 @@ +factory = $factory; + $this->relationship = $relationship; + } + + /** + * Get the parent model attributes and resolvers for the given child model. + * + * @param \Illuminate\Database\Eloquent\Model $model + * @return array + */ + public function attributesFor(Model $model) + { + $relationship = $model->{$this->relationship}(); + + return $relationship instanceof MorphTo ? [ + $relationship->getMorphType() => $this->factory instanceof Factory ? $this->factory->newModel()->getMorphClass() : $this->factory->getMorphClass(), + $relationship->getForeignKeyName() => $this->resolver($relationship->getOwnerKeyName()), + ] : [ + $relationship->getForeignKeyName() => $this->resolver($relationship->getOwnerKeyName()), + ]; + } + + /** + * Get the deferred resolver for this relationship's parent ID. + * + * @param string|null $key + * @return \Closure + */ + protected function resolver($key) + { + return function () use ($key) { + if (! $this->resolved) { + $instance = $this->factory instanceof Factory ? $this->factory->create() : $this->factory; + + return $this->resolved = $key ? $instance->{$key} : $instance->getKey(); + } + + return $this->resolved; + }; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/Factory.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/Factory.php new file mode 100644 index 000000000..6a890646c --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/Factory.php @@ -0,0 +1,782 @@ +count = $count; + $this->states = $states ?: new Collection; + $this->has = $has ?: new Collection; + $this->for = $for ?: new Collection; + $this->afterMaking = $afterMaking ?: new Collection; + $this->afterCreating = $afterCreating ?: new Collection; + $this->connection = $connection; + $this->faker = $this->withFaker(); + } + + /** + * Define the model's default state. + * + * @return array + */ + abstract public function definition(); + + /** + * Get a new factory instance for the given attributes. + * + * @param callable|array $attributes + * @return static + */ + public static function new($attributes = []) + { + return (new static)->state($attributes)->configure(); + } + + /** + * Get a new factory instance for the given number of models. + * + * @param int $count + * @return static + */ + public static function times(int $count) + { + return static::new()->count($count); + } + + /** + * Configure the factory. + * + * @return $this + */ + public function configure() + { + return $this; + } + + /** + * Get the raw attributes generated by the factory. + * + * @param array $attributes + * @param \Illuminate\Database\Eloquent\Model|null $parent + * @return array + */ + public function raw($attributes = [], ?Model $parent = null) + { + if ($this->count === null) { + return $this->state($attributes)->getExpandedAttributes($parent); + } + + return array_map(function () use ($attributes, $parent) { + return $this->state($attributes)->getExpandedAttributes($parent); + }, range(1, $this->count)); + } + + /** + * Create a single model and persist it to the database. + * + * @param array $attributes + * @return \Illuminate\Database\Eloquent\Model + */ + public function createOne($attributes = []) + { + return $this->count(null)->create($attributes); + } + + /** + * Create a collection of models and persist them to the database. + * + * @param iterable $records + * @return \Illuminate\Database\Eloquent\Collection|mixed + */ + public function createMany(iterable $records) + { + return new EloquentCollection( + array_map(function ($record) { + return $this->state($record)->create(); + }, $records) + ); + } + + /** + * Create a collection of models and persist them to the database. + * + * @param array $attributes + * @param \Illuminate\Database\Eloquent\Model|null $parent + * @return \Illuminate\Database\Eloquent\Collection|\Illuminate\Database\Eloquent\Model|mixed + */ + public function create($attributes = [], ?Model $parent = null) + { + if (! empty($attributes)) { + return $this->state($attributes)->create([], $parent); + } + + $results = $this->make($attributes, $parent); + + if ($results instanceof Model) { + $this->store(collect([$results])); + + $this->callAfterCreating(collect([$results]), $parent); + } else { + $this->store($results); + + $this->callAfterCreating($results, $parent); + } + + return $results; + } + + /** + * Create a callback that persists a model in the database when invoked. + * + * @param array $attributes + * @param \Illuminate\Database\Eloquent\Model|null $parent + * @return \Closure + */ + public function lazy(array $attributes = [], ?Model $parent = null) + { + return function () use ($attributes, $parent) { + return $this->create($attributes, $parent); + }; + } + + /** + * Set the connection name on the results and store them. + * + * @param \Illuminate\Support\Collection $results + * @return void + */ + protected function store(Collection $results) + { + $results->each(function ($model) { + if (! isset($this->connection)) { + $model->setConnection($model->newQueryWithoutScopes()->getConnection()->getName()); + } + + $model->save(); + + $this->createChildren($model); + }); + } + + /** + * Create the children for the given model. + * + * @param \Illuminate\Database\Eloquent\Model $model + * @return void + */ + protected function createChildren(Model $model) + { + Model::unguarded(function () use ($model) { + $this->has->each(function ($has) use ($model) { + $has->createFor($model); + }); + }); + } + + /** + * Make a single instance of the model. + * + * @param callable|array $attributes + * @return \Illuminate\Database\Eloquent\Model + */ + public function makeOne($attributes = []) + { + return $this->count(null)->make($attributes); + } + + /** + * Create a collection of models. + * + * @param array $attributes + * @param \Illuminate\Database\Eloquent\Model|null $parent + * @return \Illuminate\Database\Eloquent\Collection|\Illuminate\Database\Eloquent\Model|mixed + */ + public function make($attributes = [], ?Model $parent = null) + { + if (! empty($attributes)) { + return $this->state($attributes)->make([], $parent); + } + + if ($this->count === null) { + return tap($this->makeInstance($parent), function ($instance) { + $this->callAfterMaking(collect([$instance])); + }); + } + + if ($this->count < 1) { + return $this->newModel()->newCollection(); + } + + $instances = $this->newModel()->newCollection(array_map(function () use ($parent) { + return $this->makeInstance($parent); + }, range(1, $this->count))); + + $this->callAfterMaking($instances); + + return $instances; + } + + /** + * Make an instance of the model with the given attributes. + * + * @param \Illuminate\Database\Eloquent\Model|null $parent + * @return \Illuminate\Database\Eloquent\Model + */ + protected function makeInstance(?Model $parent) + { + return Model::unguarded(function () use ($parent) { + return tap($this->newModel($this->getExpandedAttributes($parent)), function ($instance) { + if (isset($this->connection)) { + $instance->setConnection($this->connection); + } + }); + }); + } + + /** + * Get a raw attributes array for the model. + * + * @param \Illuminate\Database\Eloquent\Model|null $parent + * @return mixed + */ + protected function getExpandedAttributes(?Model $parent) + { + return $this->expandAttributes($this->getRawAttributes($parent)); + } + + /** + * Get the raw attributes for the model as an array. + * + * @param \Illuminate\Database\Eloquent\Model|null $parent + * @return array + */ + protected function getRawAttributes(?Model $parent) + { + return $this->states->pipe(function ($states) { + return $this->for->isEmpty() ? $states : new Collection(array_merge([function () { + return $this->parentResolvers(); + }], $states->all())); + })->reduce(function ($carry, $state) use ($parent) { + if ($state instanceof Closure) { + $state = $state->bindTo($this); + } + + return array_merge($carry, $state($carry, $parent)); + }, $this->definition()); + } + + /** + * Create the parent relationship resolvers (as deferred Closures). + * + * @return array + */ + protected function parentResolvers() + { + $model = $this->newModel(); + + return $this->for->map(function (BelongsToRelationship $for) use ($model) { + return $for->attributesFor($model); + })->collapse()->all(); + } + + /** + * Expand all attributes to their underlying values. + * + * @param array $definition + * @return array + */ + protected function expandAttributes(array $definition) + { + return collect($definition)->map(function ($attribute, $key) use (&$definition) { + if (is_callable($attribute) && ! is_string($attribute) && ! is_array($attribute)) { + $attribute = $attribute($definition); + } + + if ($attribute instanceof self) { + $attribute = $attribute->create()->getKey(); + } elseif ($attribute instanceof Model) { + $attribute = $attribute->getKey(); + } + + $definition[$key] = $attribute; + + return $attribute; + })->all(); + } + + /** + * Add a new state transformation to the model definition. + * + * @param callable|array $state + * @return static + */ + public function state($state) + { + return $this->newInstance([ + 'states' => $this->states->concat([ + is_callable($state) ? $state : function () use ($state) { + return $state; + }, + ]), + ]); + } + + /** + * Add a new sequenced state transformation to the model definition. + * + * @param array $sequence + * @return static + */ + public function sequence(...$sequence) + { + return $this->state(new Sequence(...$sequence)); + } + + /** + * Define a child relationship for the model. + * + * @param \Illuminate\Database\Eloquent\Factories\Factory $factory + * @param string|null $relationship + * @return static + */ + public function has(self $factory, $relationship = null) + { + return $this->newInstance([ + 'has' => $this->has->concat([new Relationship( + $factory, $relationship ?: $this->guessRelationship($factory->modelName()) + )]), + ]); + } + + /** + * Attempt to guess the relationship name for a "has" relationship. + * + * @param string $related + * @return string + */ + protected function guessRelationship(string $related) + { + $guess = Str::camel(Str::plural(class_basename($related))); + + return method_exists($this->modelName(), $guess) ? $guess : Str::singular($guess); + } + + /** + * Define an attached relationship for the model. + * + * @param \Illuminate\Database\Eloquent\Factories\Factory|\Illuminate\Support\Collection|\Illuminate\Database\Eloquent\Model $factory + * @param callable|array $pivot + * @param string|null $relationship + * @return static + */ + public function hasAttached($factory, $pivot = [], $relationship = null) + { + return $this->newInstance([ + 'has' => $this->has->concat([new BelongsToManyRelationship( + $factory, + $pivot, + $relationship ?: Str::camel(Str::plural(class_basename( + $factory instanceof Factory + ? $factory->modelName() + : Collection::wrap($factory)->first() + ))) + )]), + ]); + } + + /** + * Define a parent relationship for the model. + * + * @param \Illuminate\Database\Eloquent\Factories\Factory|\Illuminate\Database\Eloquent\Model $factory + * @param string|null $relationship + * @return static + */ + public function for($factory, $relationship = null) + { + return $this->newInstance(['for' => $this->for->concat([new BelongsToRelationship( + $factory, + $relationship ?: Str::camel(class_basename( + $factory instanceof Factory ? $factory->modelName() : $factory + )) + )])]); + } + + /** + * Add a new "after making" callback to the model definition. + * + * @param \Closure $callback + * @return static + */ + public function afterMaking(Closure $callback) + { + return $this->newInstance(['afterMaking' => $this->afterMaking->concat([$callback])]); + } + + /** + * Add a new "after creating" callback to the model definition. + * + * @param \Closure $callback + * @return static + */ + public function afterCreating(Closure $callback) + { + return $this->newInstance(['afterCreating' => $this->afterCreating->concat([$callback])]); + } + + /** + * Call the "after making" callbacks for the given model instances. + * + * @param \Illuminate\Support\Collection $instances + * @return void + */ + protected function callAfterMaking(Collection $instances) + { + $instances->each(function ($model) { + $this->afterMaking->each(function ($callback) use ($model) { + $callback($model); + }); + }); + } + + /** + * Call the "after creating" callbacks for the given model instances. + * + * @param \Illuminate\Support\Collection $instances + * @param \Illuminate\Database\Eloquent\Model|null $parent + * @return void + */ + protected function callAfterCreating(Collection $instances, ?Model $parent = null) + { + $instances->each(function ($model) use ($parent) { + $this->afterCreating->each(function ($callback) use ($model, $parent) { + $callback($model, $parent); + }); + }); + } + + /** + * Specify how many models should be generated. + * + * @param int|null $count + * @return static + */ + public function count(?int $count) + { + return $this->newInstance(['count' => $count]); + } + + /** + * Specify the database connection that should be used to generate models. + * + * @param string $connection + * @return static + */ + public function connection(string $connection) + { + return $this->newInstance(['connection' => $connection]); + } + + /** + * Create a new instance of the factory builder with the given mutated properties. + * + * @param array $arguments + * @return static + */ + protected function newInstance(array $arguments = []) + { + return new static(...array_values(array_merge([ + 'count' => $this->count, + 'states' => $this->states, + 'has' => $this->has, + 'for' => $this->for, + 'afterMaking' => $this->afterMaking, + 'afterCreating' => $this->afterCreating, + 'connection' => $this->connection, + ], $arguments))); + } + + /** + * Get a new model instance. + * + * @param array $attributes + * @return \Illuminate\Database\Eloquent\Model + */ + public function newModel(array $attributes = []) + { + $model = $this->modelName(); + + return new $model($attributes); + } + + /** + * Get the name of the model that is generated by the factory. + * + * @return string + */ + public function modelName() + { + $resolver = static::$modelNameResolver ?: function (self $factory) { + $factoryBasename = Str::replaceLast('Factory', '', class_basename($factory)); + + $appNamespace = static::appNamespace(); + + return class_exists($appNamespace.'Models\\'.$factoryBasename) + ? $appNamespace.'Models\\'.$factoryBasename + : $appNamespace.$factoryBasename; + }; + + return $this->model ?: $resolver($this); + } + + /** + * Specify the callback that should be invoked to guess model names based on factory names. + * + * @param callable $callback + * @return void + */ + public static function guessModelNamesUsing(callable $callback) + { + static::$modelNameResolver = $callback; + } + + /** + * Specify the default namespace that contains the application's model factories. + * + * @param string $namespace + * @return void + */ + public static function useNamespace(string $namespace) + { + static::$namespace = $namespace; + } + + /** + * Get a new factory instance for the given model name. + * + * @param string $modelName + * @return static + */ + public static function factoryForModel(string $modelName) + { + $factory = static::resolveFactoryName($modelName); + + return $factory::new(); + } + + /** + * Specify the callback that should be invoked to guess factory names based on dynamic relationship names. + * + * @param callable $callback + * @return void + */ + public static function guessFactoryNamesUsing(callable $callback) + { + static::$factoryNameResolver = $callback; + } + + /** + * Get a new Faker instance. + * + * @return \Faker\Generator + */ + protected function withFaker() + { + return Container::getInstance()->make(Generator::class); + } + + /** + * Get the factory name for the given model name. + * + * @param string $modelName + * @return string + */ + public static function resolveFactoryName(string $modelName) + { + $resolver = static::$factoryNameResolver ?: function (string $modelName) { + $appNamespace = static::appNamespace(); + + $modelName = Str::startsWith($modelName, $appNamespace.'Models\\') + ? Str::after($modelName, $appNamespace.'Models\\') + : Str::after($modelName, $appNamespace); + + return static::$namespace.$modelName.'Factory'; + }; + + return $resolver($modelName); + } + + /** + * Get the application namespace for the application. + * + * @return string + */ + protected static function appNamespace() + { + try { + return Container::getInstance() + ->make(Application::class) + ->getNamespace(); + } catch (Throwable $e) { + return 'App\\'; + } + } + + /** + * Proxy dynamic factory methods onto their proper methods. + * + * @param string $method + * @param array $parameters + * @return mixed + */ + public function __call($method, $parameters) + { + if (static::hasMacro($method)) { + return $this->macroCall($method, $parameters); + } + + if (! Str::startsWith($method, ['for', 'has'])) { + static::throwBadMethodCallException($method); + } + + $relationship = Str::camel(Str::substr($method, 3)); + + $relatedModel = get_class($this->newModel()->{$relationship}()->getRelated()); + + if (method_exists($relatedModel, 'newFactory')) { + $factory = $relatedModel::newFactory() ?: static::factoryForModel($relatedModel); + } else { + $factory = static::factoryForModel($relatedModel); + } + + if (Str::startsWith($method, 'for')) { + return $this->for($factory->state($parameters[0] ?? []), $relationship); + } elseif (Str::startsWith($method, 'has')) { + return $this->has( + $factory + ->count(is_numeric($parameters[0] ?? null) ? $parameters[0] : 1) + ->state((is_callable($parameters[0] ?? null) || is_array($parameters[0] ?? null)) ? $parameters[0] : ($parameters[1] ?? [])), + $relationship + ); + } + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/HasFactory.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/HasFactory.php new file mode 100644 index 000000000..7d2be2205 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/HasFactory.php @@ -0,0 +1,31 @@ +count(is_numeric($parameters[0] ?? null) ? $parameters[0] : null) + ->state(is_array($parameters[0] ?? null) ? $parameters[0] : ($parameters[1] ?? [])); + } + + /** + * Create a new factory instance for the model. + * + * @return \Illuminate\Database\Eloquent\Factories\Factory + */ + protected static function newFactory() + { + // + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/Relationship.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/Relationship.php new file mode 100644 index 000000000..788f6bc82 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/Relationship.php @@ -0,0 +1,62 @@ +factory = $factory; + $this->relationship = $relationship; + } + + /** + * Create the child relationship for the given parent model. + * + * @param \Illuminate\Database\Eloquent\Model $parent + * @return void + */ + public function createFor(Model $parent) + { + $relationship = $parent->{$this->relationship}(); + + if ($relationship instanceof MorphOneOrMany) { + $this->factory->state([ + $relationship->getMorphType() => $relationship->getMorphClass(), + $relationship->getForeignKeyName() => $relationship->getParentKey(), + ])->create([], $parent); + } elseif ($relationship instanceof HasOneOrMany) { + $this->factory->state([ + $relationship->getForeignKeyName() => $relationship->getParentKey(), + ])->create([], $parent); + } elseif ($relationship instanceof BelongsToMany) { + $relationship->attach($this->factory->create([], $parent)); + } + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/Sequence.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/Sequence.php new file mode 100644 index 000000000..5efa73c10 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/Sequence.php @@ -0,0 +1,55 @@ +sequence = $sequence; + $this->count = count($sequence); + } + + /** + * Get the next value in the sequence. + * + * @return mixed + */ + public function __invoke() + { + if ($this->index >= $this->count) { + $this->index = 0; + } + + return tap(value($this->sequence[$this->index]), function () { + $this->index = $this->index + 1; + }); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factory.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factory.php deleted file mode 100644 index 6c41bac58..000000000 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factory.php +++ /dev/null @@ -1,271 +0,0 @@ -faker = $faker; - } - - /** - * Create a new factory container. - * - * @param \Faker\Generator $faker - * @param string|null $pathToFactories - * @return static - */ - public static function construct(Faker $faker, $pathToFactories = null) - { - $pathToFactories = $pathToFactories ?: database_path('factories'); - - return (new static($faker))->load($pathToFactories); - } - - /** - * Define a class with a given set of attributes. - * - * @param string $class - * @param callable $attributes - * @return $this - */ - public function define($class, callable $attributes) - { - $this->definitions[$class] = $attributes; - - return $this; - } - - /** - * Define a state with a given set of attributes. - * - * @param string $class - * @param string $state - * @param callable|array $attributes - * @return $this - */ - public function state($class, $state, $attributes) - { - $this->states[$class][$state] = $attributes; - - return $this; - } - - /** - * Define a callback to run after making a model. - * - * @param string $class - * @param callable $callback - * @param string $name - * @return $this - */ - public function afterMaking($class, callable $callback, $name = 'default') - { - $this->afterMaking[$class][$name][] = $callback; - - return $this; - } - - /** - * Define a callback to run after making a model with given state. - * - * @param string $class - * @param string $state - * @param callable $callback - * @return $this - */ - public function afterMakingState($class, $state, callable $callback) - { - return $this->afterMaking($class, $callback, $state); - } - - /** - * Define a callback to run after creating a model. - * - * @param string $class - * @param callable $callback - * @param string $name - * @return $this - */ - public function afterCreating($class, callable $callback, $name = 'default') - { - $this->afterCreating[$class][$name][] = $callback; - - return $this; - } - - /** - * Define a callback to run after creating a model with given state. - * - * @param string $class - * @param string $state - * @param callable $callback - * @return $this - */ - public function afterCreatingState($class, $state, callable $callback) - { - return $this->afterCreating($class, $callback, $state); - } - - /** - * Create an instance of the given model and persist it to the database. - * - * @param string $class - * @param array $attributes - * @return mixed - */ - public function create($class, array $attributes = []) - { - return $this->of($class)->create($attributes); - } - - /** - * Create an instance of the given model. - * - * @param string $class - * @param array $attributes - * @return mixed - */ - public function make($class, array $attributes = []) - { - return $this->of($class)->make($attributes); - } - - /** - * Get the raw attribute array for a given model. - * - * @param string $class - * @param array $attributes - * @return array - */ - public function raw($class, array $attributes = []) - { - return array_merge( - call_user_func($this->definitions[$class], $this->faker), $attributes - ); - } - - /** - * Create a builder for the given model. - * - * @param string $class - * @return \Illuminate\Database\Eloquent\FactoryBuilder - */ - public function of($class) - { - return new FactoryBuilder( - $class, $this->definitions, $this->states, - $this->afterMaking, $this->afterCreating, $this->faker - ); - } - - /** - * Load factories from path. - * - * @param string $path - * @return $this - */ - public function load($path) - { - $factory = $this; - - if (is_dir($path)) { - foreach (Finder::create()->files()->name('*.php')->in($path) as $file) { - require $file->getRealPath(); - } - } - - return $factory; - } - - /** - * Determine if the given offset exists. - * - * @param string $offset - * @return bool - */ - public function offsetExists($offset) - { - return isset($this->definitions[$offset]); - } - - /** - * Get the value of the given offset. - * - * @param string $offset - * @return mixed - */ - public function offsetGet($offset) - { - return $this->make($offset); - } - - /** - * Set the given offset to the given value. - * - * @param string $offset - * @param callable $value - * @return void - */ - public function offsetSet($offset, $value) - { - $this->define($offset, $value); - } - - /** - * Unset the value at the given offset. - * - * @param string $offset - * @return void - */ - public function offsetUnset($offset) - { - unset($this->definitions[$offset]); - } -} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/FactoryBuilder.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/FactoryBuilder.php deleted file mode 100644 index ccd82bf15..000000000 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/FactoryBuilder.php +++ /dev/null @@ -1,449 +0,0 @@ -class = $class; - $this->faker = $faker; - $this->states = $states; - $this->definitions = $definitions; - $this->afterMaking = $afterMaking; - $this->afterCreating = $afterCreating; - } - - /** - * Set the amount of models you wish to create / make. - * - * @param int $amount - * @return $this - */ - public function times($amount) - { - $this->amount = $amount; - - return $this; - } - - /** - * Set the state to be applied to the model. - * - * @param string $state - * @return $this - */ - public function state($state) - { - return $this->states([$state]); - } - - /** - * Set the states to be applied to the model. - * - * @param array|mixed $states - * @return $this - */ - public function states($states) - { - $this->activeStates = is_array($states) ? $states : func_get_args(); - - return $this; - } - - /** - * Set the database connection on which the model instance should be persisted. - * - * @param string $name - * @return $this - */ - public function connection($name) - { - $this->connection = $name; - - return $this; - } - - /** - * Create a model and persist it in the database if requested. - * - * @param array $attributes - * @return \Closure - */ - public function lazy(array $attributes = []) - { - return function () use ($attributes) { - return $this->create($attributes); - }; - } - - /** - * Create a collection of models and persist them to the database. - * - * @param array $attributes - * @return \Illuminate\Database\Eloquent\Collection|\Illuminate\Database\Eloquent\Model|mixed - */ - public function create(array $attributes = []) - { - $results = $this->make($attributes); - - if ($results instanceof Model) { - $this->store(collect([$results])); - - $this->callAfterCreating(collect([$results])); - } else { - $this->store($results); - - $this->callAfterCreating($results); - } - - return $results; - } - - /** - * Create a collection of models and persist them to the database. - * - * @param iterable $records - * @return \Illuminate\Database\Eloquent\Collection|mixed - */ - public function createMany(iterable $records) - { - return (new $this->class)->newCollection(array_map(function ($attribute) { - return $this->create($attribute); - }, $records)); - } - - /** - * Set the connection name on the results and store them. - * - * @param \Illuminate\Support\Collection $results - * @return void - */ - protected function store($results) - { - $results->each(function ($model) { - if (! isset($this->connection)) { - $model->setConnection($model->newQueryWithoutScopes()->getConnection()->getName()); - } - - $model->save(); - }); - } - - /** - * Create a collection of models. - * - * @param array $attributes - * @return \Illuminate\Database\Eloquent\Collection|\Illuminate\Database\Eloquent\Model|mixed - */ - public function make(array $attributes = []) - { - if ($this->amount === null) { - return tap($this->makeInstance($attributes), function ($instance) { - $this->callAfterMaking(collect([$instance])); - }); - } - - if ($this->amount < 1) { - return (new $this->class)->newCollection(); - } - - $instances = (new $this->class)->newCollection(array_map(function () use ($attributes) { - return $this->makeInstance($attributes); - }, range(1, $this->amount))); - - $this->callAfterMaking($instances); - - return $instances; - } - - /** - * Create an array of raw attribute arrays. - * - * @param array $attributes - * @return mixed - */ - public function raw(array $attributes = []) - { - if ($this->amount === null) { - return $this->getRawAttributes($attributes); - } - - if ($this->amount < 1) { - return []; - } - - return array_map(function () use ($attributes) { - return $this->getRawAttributes($attributes); - }, range(1, $this->amount)); - } - - /** - * Get a raw attributes array for the model. - * - * @param array $attributes - * @return mixed - * - * @throws \InvalidArgumentException - */ - protected function getRawAttributes(array $attributes = []) - { - if (! isset($this->definitions[$this->class])) { - throw new InvalidArgumentException("Unable to locate factory for [{$this->class}]."); - } - - $definition = call_user_func( - $this->definitions[$this->class], - $this->faker, $attributes - ); - - return $this->expandAttributes( - array_merge($this->applyStates($definition, $attributes), $attributes) - ); - } - - /** - * Make an instance of the model with the given attributes. - * - * @param array $attributes - * @return \Illuminate\Database\Eloquent\Model - */ - protected function makeInstance(array $attributes = []) - { - return Model::unguarded(function () use ($attributes) { - $instance = new $this->class( - $this->getRawAttributes($attributes) - ); - - if (isset($this->connection)) { - $instance->setConnection($this->connection); - } - - return $instance; - }); - } - - /** - * Apply the active states to the model definition array. - * - * @param array $definition - * @param array $attributes - * @return array - * - * @throws \InvalidArgumentException - */ - protected function applyStates(array $definition, array $attributes = []) - { - foreach ($this->activeStates as $state) { - if (! isset($this->states[$this->class][$state])) { - if ($this->stateHasAfterCallback($state)) { - continue; - } - - throw new InvalidArgumentException("Unable to locate [{$state}] state for [{$this->class}]."); - } - - $definition = array_merge( - $definition, - $this->stateAttributes($state, $attributes) - ); - } - - return $definition; - } - - /** - * Get the state attributes. - * - * @param string $state - * @param array $attributes - * @return array - */ - protected function stateAttributes($state, array $attributes) - { - $stateAttributes = $this->states[$this->class][$state]; - - if (! is_callable($stateAttributes)) { - return $stateAttributes; - } - - return $stateAttributes($this->faker, $attributes); - } - - /** - * Expand all attributes to their underlying values. - * - * @param array $attributes - * @return array - */ - protected function expandAttributes(array $attributes) - { - foreach ($attributes as &$attribute) { - if (is_callable($attribute) && ! is_string($attribute) && ! is_array($attribute)) { - $attribute = $attribute($attributes); - } - - if ($attribute instanceof static) { - $attribute = $attribute->create()->getKey(); - } - - if ($attribute instanceof Model) { - $attribute = $attribute->getKey(); - } - } - - return $attributes; - } - - /** - * Run after making callbacks on a collection of models. - * - * @param \Illuminate\Support\Collection $models - * @return void - */ - public function callAfterMaking($models) - { - $this->callAfter($this->afterMaking, $models); - } - - /** - * Run after creating callbacks on a collection of models. - * - * @param \Illuminate\Support\Collection $models - * @return void - */ - public function callAfterCreating($models) - { - $this->callAfter($this->afterCreating, $models); - } - - /** - * Call after callbacks for each model and state. - * - * @param array $afterCallbacks - * @param \Illuminate\Support\Collection $models - * @return void - */ - protected function callAfter(array $afterCallbacks, $models) - { - $states = array_merge(['default'], $this->activeStates); - - $models->each(function ($model) use ($states, $afterCallbacks) { - foreach ($states as $state) { - $this->callAfterCallbacks($afterCallbacks, $model, $state); - } - }); - } - - /** - * Call after callbacks for each model and state. - * - * @param array $afterCallbacks - * @param \Illuminate\Database\Eloquent\Model $model - * @param string $state - * @return void - */ - protected function callAfterCallbacks(array $afterCallbacks, $model, $state) - { - if (! isset($afterCallbacks[$this->class][$state])) { - return; - } - - foreach ($afterCallbacks[$this->class][$state] as $callback) { - $callback($model, $this->faker); - } - } - - /** - * Determine if the given state has an "after" callback. - * - * @param string $state - * @return bool - */ - protected function stateHasAfterCallback($state) - { - return isset($this->afterMaking[$this->class][$state]) || - isset($this->afterCreating[$this->class][$state]); - } -} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/InvalidCastException.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/InvalidCastException.php new file mode 100644 index 000000000..9d00eb3e4 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/InvalidCastException.php @@ -0,0 +1,48 @@ +model = $class; + $this->column = $column; + $this->castType = $castType; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Model.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Model.php index 9b9d72642..fdcceedac 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Model.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Model.php @@ -3,13 +3,13 @@ namespace Illuminate\Database\Eloquent; use ArrayAccess; -use Exception; use Illuminate\Contracts\Queue\QueueableCollection; use Illuminate\Contracts\Queue\QueueableEntity; use Illuminate\Contracts\Routing\UrlRoutable; use Illuminate\Contracts\Support\Arrayable; use Illuminate\Contracts\Support\Jsonable; use Illuminate\Database\ConnectionResolverInterface as Resolver; +use Illuminate\Database\Eloquent\Collection as EloquentCollection; use Illuminate\Database\Eloquent\Relations\BelongsToMany; use Illuminate\Database\Eloquent\Relations\Concerns\AsPivot; use Illuminate\Database\Eloquent\Relations\HasManyThrough; @@ -19,6 +19,7 @@ use Illuminate\Support\Collection as BaseCollection; use Illuminate\Support\Str; use Illuminate\Support\Traits\ForwardsCalls; use JsonSerializable; +use LogicException; abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializable, QueueableEntity, UrlRoutable { @@ -80,6 +81,13 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab */ protected $withCount = []; + /** + * Indicates whether lazy loading will be prevented on this model. + * + * @var bool + */ + public $preventsLazyLoading = false; + /** * The number of models to return for pagination. * @@ -143,6 +151,20 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab */ protected static $ignoreOnTouch = []; + /** + * Indicates whether lazy loading should be restricted on all models. + * + * @var bool + */ + protected static $modelsShouldPreventLazyLoading = false; + + /** + * The callback that is responsible for handling lazy loading violations. + * + * @var callable|null + */ + protected static $lazyLoadingViolationCallback; + /** * The name of the "created at" column. * @@ -332,6 +354,28 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab return false; } + /** + * Prevent model relationships from being lazy loaded. + * + * @param bool $value + * @return void + */ + public static function preventLazyLoading($value = true) + { + static::$modelsShouldPreventLazyLoading = $value; + } + + /** + * Register a callback that is responsible for handling lazy loading violations. + * + * @param callable $callback + * @return void + */ + public static function handleLazyLoadingViolationUsing(callable $callback) + { + static::$lazyLoadingViolationCallback = $callback; + } + /** * Fill the model with an array of attributes. * @@ -345,8 +389,6 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab $totallyGuarded = $this->totallyGuarded(); foreach ($this->fillableFromArray($attributes) as $key => $value) { - $key = $this->removeTableFromKey($key); - // The developers may choose to place some attributes in the "fillable" array // which means only those attributes may be set through mass assignment to // the model, and all others will just get ignored for security reasons. @@ -391,19 +433,6 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab return $this->getTable().'.'.$column; } - /** - * Remove the table name from a given key. - * - * @param string $key - * @return string - * - * @deprecated This method is deprecated and will be removed in a future Laravel version. - */ - protected function removeTableFromKey($key) - { - return $key; - } - /** * Create a new instance of the given model. * @@ -531,6 +560,10 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab */ public function loadMorph($relation, $relations) { + if (! $this->{$relation}) { + return $this; + } + $className = get_class($this->{$relation}); $this->{$relation}->load($relations[$className] ?? []); @@ -553,6 +586,21 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab return $this; } + /** + * Eager load relation's column aggregations on the model. + * + * @param array|string $relations + * @param string $column + * @param string $function + * @return $this + */ + public function loadAggregate($relations, $column, $function = null) + { + $this->newCollection([$this])->loadAggregate($relations, $column, $function); + + return $this; + } + /** * Eager load relation counts on the model. * @@ -563,7 +611,86 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab { $relations = is_string($relations) ? func_get_args() : $relations; - $this->newCollection([$this])->loadCount($relations); + return $this->loadAggregate($relations, '*', 'count'); + } + + /** + * Eager load relation max column values on the model. + * + * @param array|string $relations + * @param string $column + * @return $this + */ + public function loadMax($relations, $column) + { + return $this->loadAggregate($relations, $column, 'max'); + } + + /** + * Eager load relation min column values on the model. + * + * @param array|string $relations + * @param string $column + * @return $this + */ + public function loadMin($relations, $column) + { + return $this->loadAggregate($relations, $column, 'min'); + } + + /** + * Eager load relation's column summations on the model. + * + * @param array|string $relations + * @param string $column + * @return $this + */ + public function loadSum($relations, $column) + { + return $this->loadAggregate($relations, $column, 'sum'); + } + + /** + * Eager load relation average column values on the model. + * + * @param array|string $relations + * @param string $column + * @return $this + */ + public function loadAvg($relations, $column) + { + return $this->loadAggregate($relations, $column, 'avg'); + } + + /** + * Eager load related model existence values on the model. + * + * @param array|string $relations + * @return $this + */ + public function loadExists($relations) + { + return $this->loadAggregate($relations, '*', 'exists'); + } + + /** + * Eager load relationship column aggregation on the polymorphic relation of a model. + * + * @param string $relation + * @param array $relations + * @param string $column + * @param string $function + * @return $this + */ + public function loadMorphAggregate($relation, $relations, $column, $function = null) + { + if (! $this->{$relation}) { + return $this; + } + + $className = get_class($this->{$relation}); + + $this->{$relation}->loadAggregate($relations[$className] ?? [], $column, $function); return $this; } @@ -577,11 +704,59 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab */ public function loadMorphCount($relation, $relations) { - $className = get_class($this->{$relation}); + return $this->loadMorphAggregate($relation, $relations, '*', 'count'); + } - $this->{$relation}->loadCount($relations[$className] ?? []); + /** + * Eager load relationship max column values on the polymorphic relation of a model. + * + * @param string $relation + * @param array $relations + * @param string $column + * @return $this + */ + public function loadMorphMax($relation, $relations, $column) + { + return $this->loadMorphAggregate($relation, $relations, $column, 'max'); + } - return $this; + /** + * Eager load relationship min column values on the polymorphic relation of a model. + * + * @param string $relation + * @param array $relations + * @param string $column + * @return $this + */ + public function loadMorphMin($relation, $relations, $column) + { + return $this->loadMorphAggregate($relation, $relations, $column, 'min'); + } + + /** + * Eager load relationship column summations on the polymorphic relation of a model. + * + * @param string $relation + * @param array $relations + * @param string $column + * @return $this + */ + public function loadMorphSum($relation, $relations, $column) + { + return $this->loadMorphAggregate($relation, $relations, $column, 'sum'); + } + + /** + * Eager load relationship average column values on the polymorphic relation of a model. + * + * @param string $relation + * @param array $relations + * @param string $column + * @return $this + */ + public function loadMorphAvg($relation, $relations, $column) + { + return $this->loadMorphAggregate($relation, $relations, $column, 'avg'); } /** @@ -627,29 +802,23 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab return $query->{$method}($column, $amount, $extra); } - $this->incrementOrDecrementAttributeValue($column, $amount, $extra, $method); - - return $query->where( - $this->getKeyName(), $this->getKey() - )->{$method}($column, $amount, $extra); - } - - /** - * Increment the underlying attribute value and sync with original. - * - * @param string $column - * @param float|int $amount - * @param array $extra - * @param string $method - * @return void - */ - protected function incrementOrDecrementAttributeValue($column, $amount, $extra, $method) - { - $this->{$column} = $this->{$column} + ($method === 'increment' ? $amount : $amount * -1); + $this->{$column} = $this->isClassDeviable($column) + ? $this->deviateClassCastableAttribute($method, $column, $amount) + : $this->{$column} + ($method === 'increment' ? $amount : $amount * -1); $this->forceFill($extra); - $this->syncOriginalAttribute($column); + if ($this->fireModelEvent('updating') === false) { + return false; + } + + return tap($this->setKeysForSaveQuery($query)->{$method}($column, $amount, $extra), function () use ($column) { + $this->syncChanges(); + + $this->fireModelEvent('updated', false); + + $this->syncOriginalAttribute($column); + }); } /** @@ -668,6 +837,22 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab return $this->fill($attributes)->save($options); } + /** + * Update the model in the database without raising any events. + * + * @param array $attributes + * @param array $options + * @return bool + */ + public function updateQuietly(array $attributes = [], array $options = []) + { + if (! $this->exists) { + return false; + } + + return $this->fill($attributes)->saveQuietly($options); + } + /** * Save the model and all of its relationships. * @@ -696,6 +881,19 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab return true; } + /** + * Save the model to the database without raising any events. + * + * @param array $options + * @return bool + */ + public function saveQuietly(array $options = []) + { + return static::withoutEvents(function () use ($options) { + return $this->save($options); + }); + } + /** * Save the model to the database. * @@ -815,13 +1013,36 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab return true; } + /** + * Set the keys for a select query. + * + * @param \Illuminate\Database\Eloquent\Builder $query + * @return \Illuminate\Database\Eloquent\Builder + */ + protected function setKeysForSelectQuery($query) + { + $query->where($this->getKeyName(), '=', $this->getKeyForSelectQuery()); + + return $query; + } + + /** + * Get the primary key value for a select query. + * + * @return mixed + */ + protected function getKeyForSelectQuery() + { + return $this->original[$this->getKeyName()] ?? $this->getKey(); + } + /** * Set the keys for a save update query. * * @param \Illuminate\Database\Eloquent\Builder $query * @return \Illuminate\Database\Eloquent\Builder */ - protected function setKeysForSaveQuery(Builder $query) + protected function setKeysForSaveQuery($query) { $query->where($this->getKeyName(), '=', $this->getKeyForSaveQuery()); @@ -835,8 +1056,7 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab */ protected function getKeyForSaveQuery() { - return $this->original[$this->getKeyName()] - ?? $this->getKey(); + return $this->original[$this->getKeyName()] ?? $this->getKey(); } /** @@ -861,7 +1081,7 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab // If the model has an incrementing key, we can use the "insertGetId" method on // the query builder, which will give us back the final inserted ID for this // table from the database. Not all tables have to be incrementing though. - $attributes = $this->getAttributes(); + $attributes = $this->getAttributesForInsert(); if ($this->getIncrementing()) { $this->insertAndSetId($query, $attributes); @@ -912,10 +1132,9 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab */ public static function destroy($ids) { - // We'll initialize a count here so we will return the total number of deletes - // for the operation. The developers can then check this number as a boolean - // type value or get this total count of records deleted for logging, etc. - $count = 0; + if ($ids instanceof EloquentCollection) { + $ids = $ids->modelKeys(); + } if ($ids instanceof BaseCollection) { $ids = $ids->all(); @@ -923,11 +1142,17 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab $ids = is_array($ids) ? $ids : func_get_args(); + if (count($ids) === 0) { + return 0; + } + // We will actually pull the models from the database table and call delete on // each of them individually so that their events get fired properly with a // correct set of attributes in case the developers wants to check these. $key = ($instance = new static)->getKeyName(); + $count = 0; + foreach ($instance->whereIn($key, $ids)->get() as $model) { if ($model->delete()) { $count++; @@ -942,14 +1167,14 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab * * @return bool|null * - * @throws \Exception + * @throws \LogicException */ public function delete() { $this->mergeAttributesFromClassCasts(); if (is_null($this->getKeyName())) { - throw new Exception('No primary key defined on model.'); + throw new LogicException('No primary key defined on model.'); } // If the model doesn't exist, there is nothing to delete so we'll just return @@ -981,7 +1206,7 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab /** * Force a hard delete on a soft deleted model. * - * This method protects developers from running forceDelete when trait is missing. + * This method protects developers from running forceDelete when the trait is missing. * * @return bool|null */ @@ -1217,9 +1442,8 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab return; } - return static::newQueryWithoutScopes() + return $this->setKeysForSelectQuery($this->newQueryWithoutScopes()) ->with(is_string($with) ? func_get_args() : $with) - ->where($this->getKeyName(), $this->getKey()) ->first(); } @@ -1235,7 +1459,7 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab } $this->setRawAttributes( - static::newQueryWithoutScopes()->findOrFail($this->getKey())->attributes + $this->setKeysForSelectQuery($this->newQueryWithoutScopes())->firstOrFail()->attributes ); $this->load(collect($this->relations)->reject(function ($relation) { @@ -1626,6 +1850,16 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab return $this; } + /** + * Determine if lazy loading is disabled. + * + * @return bool + */ + public static function preventsLazyLoading() + { + return static::$modelsShouldPreventLazyLoading; + } + /** * Dynamically retrieve attributes on the model. * @@ -1780,5 +2014,7 @@ abstract class Model implements Arrayable, ArrayAccess, Jsonable, JsonSerializab public function __wakeup() { $this->bootIfNotBooted(); + + $this->initializeTraits(); } } diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/ModelNotFoundException.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/ModelNotFoundException.php index 2795b934b..c35598bdb 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/ModelNotFoundException.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/ModelNotFoundException.php @@ -2,10 +2,10 @@ namespace Illuminate\Database\Eloquent; +use Illuminate\Database\RecordsNotFoundException; use Illuminate\Support\Arr; -use RuntimeException; -class ModelNotFoundException extends RuntimeException +class ModelNotFoundException extends RecordsNotFoundException { /** * Name of the affected Eloquent model. diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/BelongsTo.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/BelongsTo.php index 5ec2c315b..a98cba0ad 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/BelongsTo.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/BelongsTo.php @@ -5,11 +5,15 @@ namespace Illuminate\Database\Eloquent\Relations; use Illuminate\Database\Eloquent\Builder; use Illuminate\Database\Eloquent\Collection; use Illuminate\Database\Eloquent\Model; +use Illuminate\Database\Eloquent\Relations\Concerns\ComparesRelatedModels; +use Illuminate\Database\Eloquent\Relations\Concerns\InteractsWithDictionary; use Illuminate\Database\Eloquent\Relations\Concerns\SupportsDefaultModels; class BelongsTo extends Relation { - use SupportsDefaultModels; + use ComparesRelatedModels, + InteractsWithDictionary, + SupportsDefaultModels; /** * The child model instance of the relation. @@ -39,13 +43,6 @@ class BelongsTo extends Relation */ protected $relationName; - /** - * The count of self joins. - * - * @var int - */ - protected static $selfJoinCount = 0; - /** * Create a new belongs to relationship instance. * @@ -180,15 +177,19 @@ class BelongsTo extends Relation $dictionary = []; foreach ($results as $result) { - $dictionary[$result->getAttribute($owner)] = $result; + $attribute = $this->getDictionaryKey($result->getAttribute($owner)); + + $dictionary[$attribute] = $result; } // Once we have the dictionary constructed, we can loop through all the parents // and match back onto their children using these keys of the dictionary and // the primary key of the children to map them onto the correct instances. foreach ($models as $model) { - if (isset($dictionary[$model->{$foreign}])) { - $model->setRelation($relation, $dictionary[$model->{$foreign}]); + $attribute = $this->getDictionaryKey($model->{$foreign}); + + if (isset($dictionary[$attribute])) { + $model->setRelation($relation, $dictionary[$attribute]); } } @@ -228,6 +229,16 @@ class BelongsTo extends Relation return $this->child->setRelation($this->relationName, null); } + /** + * Alias of "dissociate" method. + * + * @return \Illuminate\Database\Eloquent\Model + */ + public function disassociate() + { + return $this->dissociate(); + } + /** * Add the constraints for a relationship query. * @@ -268,16 +279,6 @@ class BelongsTo extends Relation ); } - /** - * Get a relationship join table hash. - * - * @return string - */ - public function getRelationCountHash() - { - return 'laravel_reserved_'.static::$selfJoinCount++; - } - /** * Determine if the related model has an auto-incrementing ID. * @@ -330,6 +331,16 @@ class BelongsTo extends Relation return $this->child->qualifyColumn($this->foreignKey); } + /** + * Get the key value of the child's foreign key. + * + * @return mixed + */ + public function getParentKey() + { + return $this->child->{$this->foreignKey}; + } + /** * Get the associated key of the relationship. * @@ -350,6 +361,17 @@ class BelongsTo extends Relation return $this->related->qualifyColumn($this->ownerKey); } + /** + * Get the value of the model's associated key. + * + * @param \Illuminate\Database\Eloquent\Model $model + * @return mixed + */ + protected function getRelatedKeyFrom(Model $model) + { + return $model->{$this->ownerKey}; + } + /** * Get the name of the relationship. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/BelongsToMany.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/BelongsToMany.php index 45bfbc2de..d85030b9a 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/BelongsToMany.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/BelongsToMany.php @@ -7,12 +7,15 @@ use Illuminate\Database\Eloquent\Builder; use Illuminate\Database\Eloquent\Collection; use Illuminate\Database\Eloquent\Model; use Illuminate\Database\Eloquent\ModelNotFoundException; +use Illuminate\Database\Eloquent\Relations\Concerns\AsPivot; +use Illuminate\Database\Eloquent\Relations\Concerns\InteractsWithDictionary; +use Illuminate\Database\Eloquent\Relations\Concerns\InteractsWithPivotTable; use Illuminate\Support\Str; use InvalidArgumentException; class BelongsToMany extends Relation { - use Concerns\InteractsWithPivotTable; + use InteractsWithDictionary, InteractsWithPivotTable; /** * The intermediate table for the relation. @@ -126,13 +129,6 @@ class BelongsToMany extends Relation */ protected $accessor = 'pivot'; - /** - * The count of self joins. - * - * @var int - */ - protected static $selfJoinCount = 0; - /** * Create a new belongs to many relationship instance. * @@ -177,7 +173,7 @@ class BelongsToMany extends Relation return $table; } - if ($model instanceof Pivot) { + if (in_array(AsPivot::class, class_uses_recursive($model))) { $this->using($table); } @@ -211,11 +207,12 @@ class BelongsToMany extends Relation // We need to join to the intermediate table on the related model's primary // key column with the intermediate table's foreign key for the related // model instance. Then we can set the "where" for the parent models. - $baseTable = $this->related->getTable(); - - $key = $baseTable.'.'.$this->relatedKey; - - $query->join($this->table, $key, '=', $this->getQualifiedRelatedPivotKeyName()); + $query->join( + $this->table, + $this->getQualifiedRelatedKeyName(), + '=', + $this->getQualifiedRelatedPivotKeyName() + ); return $this; } @@ -282,7 +279,9 @@ class BelongsToMany extends Relation // children back to their parent using the dictionary and the keys on the // the parent models. Then we will return the hydrated models back out. foreach ($models as $model) { - if (isset($dictionary[$key = $model->{$this->parentKey}])) { + $key = $this->getDictionaryKey($model->{$this->parentKey}); + + if (isset($dictionary[$key])) { $model->setRelation( $relation, $this->related->newCollection($dictionary[$key]) ); @@ -306,7 +305,9 @@ class BelongsToMany extends Relation $dictionary = []; foreach ($results as $result) { - $dictionary[$result->{$this->accessor}->{$this->foreignPivotKey}][] = $result; + $value = $this->getDictionaryKey($result->{$this->accessor}->{$this->foreignPivotKey}); + + $dictionary[$value][] = $result; } return $dictionary; @@ -361,7 +362,7 @@ class BelongsToMany extends Relation { $this->pivotWheres[] = func_get_args(); - return $this->where($this->table.'.'.$column, $operator, $value, $boolean); + return $this->where($this->qualifyPivotColumn($column), $operator, $value, $boolean); } /** @@ -375,7 +376,7 @@ class BelongsToMany extends Relation */ public function wherePivotBetween($column, array $values, $boolean = 'and', $not = false) { - return $this->whereBetween($this->table.'.'.$column, $values, $boolean, $not); + return $this->whereBetween($this->qualifyPivotColumn($column), $values, $boolean, $not); } /** @@ -428,7 +429,7 @@ class BelongsToMany extends Relation { $this->pivotWhereIns[] = func_get_args(); - return $this->whereIn($this->table.'.'.$column, $values, $boolean, $not); + return $this->whereIn($this->qualifyPivotColumn($column), $values, $boolean, $not); } /** @@ -523,7 +524,7 @@ class BelongsToMany extends Relation { $this->pivotWhereNulls[] = func_get_args(); - return $this->whereNull($this->table.'.'.$column, $boolean, $not); + return $this->whereNull($this->qualifyPivotColumn($column), $boolean, $not); } /** @@ -562,7 +563,19 @@ class BelongsToMany extends Relation } /** - * Find a related model by its primary key or return new instance of the related model. + * Add an "order by" clause for a pivot table column. + * + * @param string $column + * @param string $direction + * @return $this + */ + public function orderByPivot($column, $direction = 'asc') + { + return $this->orderBy($this->qualifyPivotColumn($column), $direction); + } + + /** + * Find a related model by its primary key or return a new instance of the related model. * * @param mixed $id * @param array $columns @@ -809,7 +822,7 @@ class BelongsToMany extends Relation $defaults = [$this->foreignPivotKey, $this->relatedPivotKey]; return collect(array_merge($defaults, $this->pivotColumns))->map(function ($column) { - return $this->table.'.'.$column.' as pivot_'.$column; + return $this->qualifyPivotColumn($column).' as pivot_'.$column; })->unique()->all(); } @@ -858,12 +871,10 @@ class BelongsToMany extends Relation */ public function chunk($count, callable $callback) { - $this->query->addSelect($this->shouldSelect()); - - return $this->query->chunk($count, function ($results) use ($callback) { + return $this->prepareQueryBuilder()->chunk($count, function ($results, $page) use ($callback) { $this->hydratePivotRelation($results->all()); - return $callback($results); + return $callback($results, $page); }); } @@ -878,7 +889,7 @@ class BelongsToMany extends Relation */ public function chunkById($count, callable $callback, $column = null, $alias = null) { - $this->query->addSelect($this->shouldSelect()); + $this->prepareQueryBuilder(); $column = $column ?? $this->getRelated()->qualifyColumn( $this->getRelatedKeyName() @@ -911,6 +922,44 @@ class BelongsToMany extends Relation }); } + /** + * Query lazily, by chunks of the given size. + * + * @param int $chunkSize + * @return \Illuminate\Support\LazyCollection + */ + public function lazy($chunkSize = 1000) + { + return $this->prepareQueryBuilder()->lazy($chunkSize)->map(function ($model) { + $this->hydratePivotRelation([$model]); + + return $model; + }); + } + + /** + * Query lazily, by chunking the results of a query by comparing IDs. + * + * @param int $count + * @param string|null $column + * @param string|null $alias + * @return \Illuminate\Support\LazyCollection + */ + public function lazyById($chunkSize = 1000, $column = null, $alias = null) + { + $column = $column ?? $this->getRelated()->qualifyColumn( + $this->getRelatedKeyName() + ); + + $alias = $alias ?? $this->getRelatedKeyName(); + + return $this->prepareQueryBuilder()->lazyById($chunkSize, $column, $alias)->map(function ($model) { + $this->hydratePivotRelation([$model]); + + return $model; + }); + } + /** * Get a lazy collection for the given query. * @@ -918,15 +967,23 @@ class BelongsToMany extends Relation */ public function cursor() { - $this->query->addSelect($this->shouldSelect()); - - return $this->query->cursor()->map(function ($model) { + return $this->prepareQueryBuilder()->cursor()->map(function ($model) { $this->hydratePivotRelation([$model]); return $model; }); } + /** + * Prepare the query builder for query execution. + * + * @return \Illuminate\Database\Eloquent\Builder + */ + protected function prepareQueryBuilder() + { + return $this->query->addSelect($this->shouldSelect()); + } + /** * Hydrate the pivot table relationship on the models. * @@ -1165,16 +1222,6 @@ class BelongsToMany extends Relation return $this->getQualifiedForeignPivotKeyName(); } - /** - * Get a relationship join table hash. - * - * @return string - */ - public function getRelationCountHash() - { - return 'laravel_reserved_'.static::$selfJoinCount++; - } - /** * Specify that the pivot table has creation and update timestamps. * @@ -1229,7 +1276,7 @@ class BelongsToMany extends Relation */ public function getQualifiedForeignPivotKeyName() { - return $this->table.'.'.$this->foreignPivotKey; + return $this->qualifyPivotColumn($this->foreignPivotKey); } /** @@ -1249,7 +1296,7 @@ class BelongsToMany extends Relation */ public function getQualifiedRelatedPivotKeyName() { - return $this->table.'.'.$this->relatedPivotKey; + return $this->qualifyPivotColumn($this->relatedPivotKey); } /** @@ -1282,6 +1329,16 @@ class BelongsToMany extends Relation return $this->relatedKey; } + /** + * Get the fully qualified related key name for the relation. + * + * @return string + */ + public function getQualifiedRelatedKeyName() + { + return $this->related->qualifyColumn($this->relatedKey); + } + /** * Get the intermediate table for the relationship. * @@ -1321,4 +1378,17 @@ class BelongsToMany extends Relation { return $this->pivotColumns; } + + /** + * Qualify the given column name by the pivot table. + * + * @param string $column + * @return string + */ + public function qualifyPivotColumn($column) + { + return Str::contains($column, '.') + ? $column + : $this->table.'.'.$column; + } } diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/AsPivot.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/AsPivot.php index d7de34e2c..af9defb74 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/AsPivot.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/AsPivot.php @@ -83,15 +83,15 @@ trait AsPivot } /** - * Set the keys for a save update query. + * Set the keys for a select query. * * @param \Illuminate\Database\Eloquent\Builder $query * @return \Illuminate\Database\Eloquent\Builder */ - protected function setKeysForSaveQuery(Builder $query) + protected function setKeysForSelectQuery($query) { if (isset($this->attributes[$this->getKeyName()])) { - return parent::setKeysForSaveQuery($query); + return parent::setKeysForSelectQuery($query); } $query->where($this->foreignKey, $this->getOriginal( @@ -103,6 +103,17 @@ trait AsPivot )); } + /** + * Set the keys for a save update query. + * + * @param \Illuminate\Database\Eloquent\Builder $query + * @return \Illuminate\Database\Eloquent\Builder + */ + protected function setKeysForSaveQuery($query) + { + return $this->setKeysForSelectQuery($query); + } + /** * Delete the pivot model record from the database. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/CanBeOneOfMany.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/CanBeOneOfMany.php new file mode 100644 index 000000000..0a2c6fac7 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/CanBeOneOfMany.php @@ -0,0 +1,302 @@ +isOneOfMany = true; + + $this->relationName = $relation ?: $this->getDefaultOneOfManyJoinAlias( + $this->guessRelationship() + ); + + $keyName = $this->query->getModel()->getKeyName(); + + $columns = is_string($columns = $column) ? [ + $column => $aggregate, + $keyName => $aggregate, + ] : $column; + + if (! array_key_exists($keyName, $columns)) { + $columns[$keyName] = 'MAX'; + } + + if ($aggregate instanceof Closure) { + $closure = $aggregate; + } + + foreach ($columns as $column => $aggregate) { + if (! in_array(strtolower($aggregate), ['min', 'max'])) { + throw new InvalidArgumentException("Invalid aggregate [{$aggregate}] used within ofMany relation. Available aggregates: MIN, MAX"); + } + + $subQuery = $this->newOneOfManySubQuery( + $this->getOneOfManySubQuerySelectColumns(), + $column, $aggregate + ); + + if (isset($previous)) { + $this->addOneOfManyJoinSubQuery($subQuery, $previous['subQuery'], $previous['column']); + } elseif (isset($closure)) { + $closure($subQuery); + } + + if (! isset($previous)) { + $this->oneOfManySubQuery = $subQuery; + } + + if (array_key_last($columns) == $column) { + $this->addOneOfManyJoinSubQuery($this->query, $subQuery, $column); + } + + $previous = [ + 'subQuery' => $subQuery, + 'column' => $column, + ]; + } + + $this->addConstraints(); + + return $this; + } + + /** + * Indicate that the relation is the latest single result of a larger one-to-many relationship. + * + * @param string|array|null $column + * @param string|Closure|null $aggregate + * @param string|null $relation + * @return $this + */ + public function latestOfMany($column = 'id', $relation = null) + { + return $this->ofMany(collect(Arr::wrap($column))->mapWithKeys(function ($column) { + return [$column => 'MAX']; + })->all(), 'MAX', $relation ?: $this->guessRelationship()); + } + + /** + * Indicate that the relation is the oldest single result of a larger one-to-many relationship. + * + * @param string|array|null $column + * @param string|Closure|null $aggregate + * @param string|null $relation + * @return $this + */ + public function oldestOfMany($column = 'id', $relation = null) + { + return $this->ofMany(collect(Arr::wrap($column))->mapWithKeys(function ($column) { + return [$column => 'MIN']; + })->all(), 'MIN', $relation ?: $this->guessRelationship()); + } + + /** + * Get the default alias for the one of many inner join clause. + * + * @param string $relation + * @return string + */ + protected function getDefaultOneOfManyJoinAlias($relation) + { + return $relation == $this->query->getModel()->getTable() + ? $relation.'_of_many' + : $relation; + } + + /** + * Get a new query for the related model, grouping the query by the given column, often the foreign key of the relationship. + * + * @param string|array $groupBy + * @param string|null $column + * @param string|null $aggregate + * @return \Illuminate\Database\Eloquent\Builder + */ + protected function newOneOfManySubQuery($groupBy, $column = null, $aggregate = null) + { + $subQuery = $this->query->getModel() + ->newQuery(); + + foreach (Arr::wrap($groupBy) as $group) { + $subQuery->groupBy($this->qualifyRelatedColumn($group)); + } + + if (! is_null($column)) { + $subQuery->selectRaw($aggregate.'('.$column.') as '.$column); + } + + $this->addOneOfManySubQueryConstraints($subQuery, $groupBy, $column, $aggregate); + + return $subQuery; + } + + /** + * Add the join subquery to the given query on the given column and the relationship's foreign key. + * + * @param \Illuminate\Database\Eloquent\Builder $parent + * @param \Illuminate\Database\Eloquent\Builder $subQuery + * @param string $on + * @return void + */ + protected function addOneOfManyJoinSubQuery(Builder $parent, Builder $subQuery, $on) + { + $parent->beforeQuery(function ($parent) use ($subQuery, $on) { + $parent->joinSub($subQuery, $this->relationName, function ($join) use ($on) { + $join->on($this->qualifySubSelectColumn($on), '=', $this->qualifyRelatedColumn($on)); + + $this->addOneOfManyJoinSubQueryConstraints($join, $on); + }); + }); + } + + /** + * Merge the relationship query joins to the given query builder. + * + * @param \Illuminate\Database\Eloquent\Builder $builder + * @return void + */ + protected function mergeOneOfManyJoinsTo(Builder $query) + { + $query->getQuery()->beforeQueryCallbacks = $this->query->getQuery()->beforeQueryCallbacks; + + $query->applyBeforeQueryCallbacks(); + } + + /** + * Get the query builder that will contain the relationship constraints. + * + * @return \Illuminate\Database\Eloquent\Builder + */ + protected function getRelationQuery() + { + return $this->isOneOfMany() + ? $this->oneOfManySubQuery + : $this->query; + } + + /** + * Get the one of many inner join subselect builder instance. + * + * @return \Illuminate\Database\Eloquent\Builder|void + */ + public function getOneOfManySubQuery() + { + return $this->oneOfManySubQuery; + } + + /** + * Get the qualified column name for the one-of-many relationship using the subselect join query's alias. + * + * @param string $column + * @return string + */ + public function qualifySubSelectColumn($column) + { + return $this->getRelationName().'.'.last(explode('.', $column)); + } + + /** + * Qualify related column using the related table name if it is not already qualified. + * + * @param string $column + * @return string + */ + protected function qualifyRelatedColumn($column) + { + return Str::contains($column, '.') ? $column : $this->query->getModel()->getTable().'.'.$column; + } + + /** + * Guess the "hasOne" relationship's name via backtrace. + * + * @return string + */ + protected function guessRelationship() + { + return debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS, 3)[2]['function']; + } + + /** + * Determine whether the relationship is a one-of-many relationship. + * + * @return bool + */ + public function isOneOfMany() + { + return $this->isOneOfMany; + } + + /** + * Get the name of the relationship. + * + * @return string + */ + public function getRelationName() + { + return $this->relationName; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/ComparesRelatedModels.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/ComparesRelatedModels.php new file mode 100644 index 000000000..ca0669887 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/ComparesRelatedModels.php @@ -0,0 +1,77 @@ +compareKeys($this->getParentKey(), $this->getRelatedKeyFrom($model)) && + $this->related->getTable() === $model->getTable() && + $this->related->getConnectionName() === $model->getConnectionName(); + + if ($match && $this instanceof SupportsPartialRelations && $this->isOneOfMany()) { + return $this->query + ->whereKey($model->getKey()) + ->exists(); + } + + return $match; + } + + /** + * Determine if the model is not the related instance of the relationship. + * + * @param \Illuminate\Database\Eloquent\Model|null $model + * @return bool + */ + public function isNot($model) + { + return ! $this->is($model); + } + + /** + * Get the value of the parent model's key. + * + * @return mixed + */ + abstract public function getParentKey(); + + /** + * Get the value of the model's related key. + * + * @param \Illuminate\Database\Eloquent\Model $model + * @return mixed + */ + abstract protected function getRelatedKeyFrom(Model $model); + + /** + * Compare the parent key with the related key. + * + * @param mixed $parentKey + * @param mixed $relatedKey + * @return bool + */ + protected function compareKeys($parentKey, $relatedKey) + { + if (empty($parentKey) || empty($relatedKey)) { + return false; + } + + if (is_int($parentKey) || is_int($relatedKey)) { + return (int) $parentKey === (int) $relatedKey; + } + + return $parentKey === $relatedKey; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/InteractsWithDictionary.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/InteractsWithDictionary.php new file mode 100644 index 000000000..abdfdd6a5 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/InteractsWithDictionary.php @@ -0,0 +1,29 @@ +__toString(); + } + + throw new InvalidArgumentException('Model attribute value is an object but does not have a __toString method.'); + } + + return $attribute; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/InteractsWithPivotTable.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/InteractsWithPivotTable.php index df39c1169..512ddd0ca 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/InteractsWithPivotTable.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Concerns/InteractsWithPivotTable.php @@ -123,6 +123,21 @@ trait InteractsWithPivotTable return $changes; } + /** + * Sync the intermediate tables with a list of IDs or collection of models with the given pivot values. + * + * @param \Illuminate\Support\Collection|\Illuminate\Database\Eloquent\Model|array $ids + * @param array $values + * @param bool $detaching + * @return array + */ + public function syncWithPivotValues($ids, array $values, bool $detaching = true) + { + return $this->sync(collect($this->parseIds($ids))->mapWithKeys(function ($id) use ($values) { + return [$id => $values]; + }), $detaching); + } + /** * Format the sync / toggle record list so that it is keyed by ID. * @@ -431,7 +446,7 @@ trait InteractsWithPivotTable return 0; } - $query->whereIn($this->relatedPivotKey, (array) $ids); + $query->whereIn($this->getQualifiedRelatedPivotKeyName(), (array) $ids); } // Once we have all of the conditions set on the statement, we are ready @@ -475,7 +490,7 @@ trait InteractsWithPivotTable protected function getCurrentlyAttachedPivots() { return $this->newPivotQuery()->get()->map(function ($record) { - $class = $this->using ? $this->using : Pivot::class; + $class = $this->using ?: Pivot::class; $pivot = $class::fromRawAttributes($this->parent, (array) $record, $this->getTable(), true); @@ -552,7 +567,7 @@ trait InteractsWithPivotTable $query->whereNull(...$arguments); } - return $query->where($this->foreignPivotKey, $this->parent->{$this->parentKey}); + return $query->where($this->getQualifiedForeignPivotKeyName(), $this->parent->{$this->parentKey}); } /** diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/HasManyThrough.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/HasManyThrough.php index b0b568b25..9ea307562 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/HasManyThrough.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/HasManyThrough.php @@ -7,10 +7,13 @@ use Illuminate\Database\Eloquent\Builder; use Illuminate\Database\Eloquent\Collection; use Illuminate\Database\Eloquent\Model; use Illuminate\Database\Eloquent\ModelNotFoundException; +use Illuminate\Database\Eloquent\Relations\Concerns\InteractsWithDictionary; use Illuminate\Database\Eloquent\SoftDeletes; class HasManyThrough extends Relation { + use InteractsWithDictionary; + /** * The "through" parent model instance. * @@ -53,13 +56,6 @@ class HasManyThrough extends Relation */ protected $secondLocalKey; - /** - * The count of self joins. - * - * @var int - */ - protected static $selfJoinCount = 0; - /** * Create a new has many through relationship instance. * @@ -200,7 +196,7 @@ class HasManyThrough extends Relation // link them up with their children using the keyed dictionary to make the // matching very convenient and easy work. Then we'll just return them. foreach ($models as $model) { - if (isset($dictionary[$key = $model->getAttribute($this->localKey)])) { + if (isset($dictionary[$key = $this->getDictionaryKey($model->getAttribute($this->localKey))])) { $model->setRelation( $relation, $this->related->newCollection($dictionary[$key]) ); @@ -508,6 +504,34 @@ class HasManyThrough extends Relation }); } + /** + * Query lazily, by chunks of the given size. + * + * @param int $chunkSize + * @return \Illuminate\Support\LazyCollection + */ + public function lazy($chunkSize = 1000) + { + return $this->prepareQueryBuilder()->lazy($chunkSize); + } + + /** + * Query lazily, by chunking the results of a query by comparing IDs. + * + * @param int $count + * @param string|null $column + * @param string|null $alias + * @return \Illuminate\Support\LazyCollection + */ + public function lazyById($chunkSize = 1000, $column = null, $alias = null) + { + $column = $column ?? $this->getRelated()->getQualifiedKeyName(); + + $alias = $alias ?? $this->getRelated()->getKeyName(); + + return $this->prepareQueryBuilder()->lazyById($chunkSize, $column, $alias); + } + /** * Prepare the query builder for query execution. * @@ -596,16 +620,6 @@ class HasManyThrough extends Relation ); } - /** - * Get a relationship join table hash. - * - * @return string - */ - public function getRelationCountHash() - { - return 'laravel_reserved_'.static::$selfJoinCount++; - } - /** * Get the qualified foreign key on the related model. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/HasOne.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/HasOne.php index 1d9e008fd..15c735c32 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/HasOne.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/HasOne.php @@ -2,13 +2,18 @@ namespace Illuminate\Database\Eloquent\Relations; +use Illuminate\Contracts\Database\Eloquent\SupportsPartialRelations; +use Illuminate\Database\Eloquent\Builder; use Illuminate\Database\Eloquent\Collection; use Illuminate\Database\Eloquent\Model; +use Illuminate\Database\Eloquent\Relations\Concerns\CanBeOneOfMany; +use Illuminate\Database\Eloquent\Relations\Concerns\ComparesRelatedModels; use Illuminate\Database\Eloquent\Relations\Concerns\SupportsDefaultModels; +use Illuminate\Database\Query\JoinClause; -class HasOne extends HasOneOrMany +class HasOne extends HasOneOrMany implements SupportsPartialRelations { - use SupportsDefaultModels; + use ComparesRelatedModels, CanBeOneOfMany, SupportsDefaultModels; /** * Get the results of the relationship. @@ -53,6 +58,59 @@ class HasOne extends HasOneOrMany return $this->matchOne($models, $results, $relation); } + /** + * Add the constraints for an internal relationship existence query. + * + * Essentially, these queries compare on column names like "whereColumn". + * + * @param \Illuminate\Database\Eloquent\Builder $query + * @param \Illuminate\Database\Eloquent\Builder $parentQuery + * @param array|mixed $columns + * @return \Illuminate\Database\Eloquent\Builder + */ + public function getRelationExistenceQuery(Builder $query, Builder $parentQuery, $columns = ['*']) + { + if ($this->isOneOfMany()) { + $this->mergeOneOfManyJoinsTo($query); + } + + return parent::getRelationExistenceQuery($query, $parentQuery, $columns); + } + + /** + * Add constraints for inner join subselect for one of many relationships. + * + * @param \Illuminate\Database\Eloquent\Builder $query + * @param string|null $column + * @param string|null $aggregate + * @return void + */ + public function addOneOfManySubQueryConstraints(Builder $query, $column = null, $aggregate = null) + { + $query->addSelect($this->foreignKey); + } + + /** + * Get the columns that should be selected by the one of many subquery. + * + * @return array|string + */ + public function getOneOfManySubQuerySelectColumns() + { + return $this->foreignKey; + } + + /** + * Add join query constraints for one of many relationships. + * + * @param \Illuminate\Database\Eloquent\JoinClause $join + * @return void + */ + public function addOneOfManyJoinSubQueryConstraints(JoinClause $join) + { + $join->on($this->qualifySubSelectColumn($this->foreignKey), '=', $this->qualifyRelatedColumn($this->foreignKey)); + } + /** * Make a new related instance for the given model. * @@ -65,4 +123,15 @@ class HasOne extends HasOneOrMany $this->getForeignKeyName(), $parent->{$this->localKey} ); } + + /** + * Get the value of the model's foreign key. + * + * @param \Illuminate\Database\Eloquent\Model $model + * @return mixed + */ + protected function getRelatedKeyFrom(Model $model) + { + return $model->getAttribute($this->getForeignKeyName()); + } } diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/HasOneOrMany.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/HasOneOrMany.php index d015c863b..f3a50501f 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/HasOneOrMany.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/HasOneOrMany.php @@ -5,9 +5,12 @@ namespace Illuminate\Database\Eloquent\Relations; use Illuminate\Database\Eloquent\Builder; use Illuminate\Database\Eloquent\Collection; use Illuminate\Database\Eloquent\Model; +use Illuminate\Database\Eloquent\Relations\Concerns\InteractsWithDictionary; abstract class HasOneOrMany extends Relation { + use InteractsWithDictionary; + /** * The foreign key of the parent model. * @@ -22,13 +25,6 @@ abstract class HasOneOrMany extends Relation */ protected $localKey; - /** - * The count of self joins. - * - * @var int - */ - protected static $selfJoinCount = 0; - /** * Create a new has one or many relationship instance. * @@ -60,7 +56,7 @@ abstract class HasOneOrMany extends Relation } /** - * Create and return an un-saved instances of the related models. + * Create and return an un-saved instance of the related models. * * @param iterable $records * @return \Illuminate\Database\Eloquent\Collection @@ -84,9 +80,11 @@ abstract class HasOneOrMany extends Relation public function addConstraints() { if (static::$constraints) { - $this->query->where($this->foreignKey, '=', $this->getParentKey()); + $query = $this->getRelationQuery(); - $this->query->whereNotNull($this->foreignKey); + $query->where($this->foreignKey, '=', $this->getParentKey()); + + $query->whereNotNull($this->foreignKey); } } @@ -100,7 +98,7 @@ abstract class HasOneOrMany extends Relation { $whereIn = $this->whereInMethod($this->parent, $this->localKey); - $this->query->{$whereIn}( + $this->getRelationQuery()->{$whereIn}( $this->foreignKey, $this->getKeys($models, $this->localKey) ); } @@ -148,7 +146,7 @@ abstract class HasOneOrMany extends Relation // link them up with their children using the keyed dictionary to make the // matching very convenient and easy work. Then we'll just return them. foreach ($models as $model) { - if (isset($dictionary[$key = $model->getAttribute($this->localKey)])) { + if (isset($dictionary[$key = $this->getDictionaryKey($model->getAttribute($this->localKey))])) { $model->setRelation( $relation, $this->getRelationValue($dictionary, $key, $type) ); @@ -184,12 +182,12 @@ abstract class HasOneOrMany extends Relation $foreign = $this->getForeignKeyName(); return $results->mapToDictionary(function ($result) use ($foreign) { - return [$result->{$foreign} => $result]; + return [$this->getDictionaryKey($result->{$foreign}) => $result]; })->all(); } /** - * Find a model by its primary key or return new instance of the related model. + * Find a model by its primary key or return a new instance of the related model. * * @param mixed $id * @param array $columns @@ -213,7 +211,7 @@ abstract class HasOneOrMany extends Relation * @param array $values * @return \Illuminate\Database\Eloquent\Model */ - public function firstOrNew(array $attributes, array $values = []) + public function firstOrNew(array $attributes = [], array $values = []) { if (is_null($instance = $this->where($attributes)->first())) { $instance = $this->related->newInstance($attributes + $values); @@ -231,7 +229,7 @@ abstract class HasOneOrMany extends Relation * @param array $values * @return \Illuminate\Database\Eloquent\Model */ - public function firstOrCreate(array $attributes, array $values = []) + public function firstOrCreate(array $attributes = [], array $values = []) { if (is_null($instance = $this->where($attributes)->first())) { $instance = $this->create($attributes + $values); @@ -363,16 +361,6 @@ abstract class HasOneOrMany extends Relation ); } - /** - * Get a relationship join table hash. - * - * @return string - */ - public function getRelationCountHash() - { - return 'laravel_reserved_'.static::$selfJoinCount++; - } - /** * Get the key for comparing against the parent key in "has" query. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/HasOneThrough.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/HasOneThrough.php index a48c31862..ed9c7baa4 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/HasOneThrough.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/HasOneThrough.php @@ -4,11 +4,12 @@ namespace Illuminate\Database\Eloquent\Relations; use Illuminate\Database\Eloquent\Collection; use Illuminate\Database\Eloquent\Model; +use Illuminate\Database\Eloquent\Relations\Concerns\InteractsWithDictionary; use Illuminate\Database\Eloquent\Relations\Concerns\SupportsDefaultModels; class HasOneThrough extends HasManyThrough { - use SupportsDefaultModels; + use InteractsWithDictionary, SupportsDefaultModels; /** * Get the results of the relationship. @@ -52,7 +53,7 @@ class HasOneThrough extends HasManyThrough // link them up with their children using the keyed dictionary to make the // matching very convenient and easy work. Then we'll just return them. foreach ($models as $model) { - if (isset($dictionary[$key = $model->getAttribute($this->localKey)])) { + if (isset($dictionary[$key = $this->getDictionaryKey($model->getAttribute($this->localKey))])) { $value = $dictionary[$key]; $model->setRelation( $relation, reset($value) diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/MorphOne.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/MorphOne.php index 5f8da14f1..ff526842e 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/MorphOne.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/MorphOne.php @@ -2,13 +2,18 @@ namespace Illuminate\Database\Eloquent\Relations; +use Illuminate\Contracts\Database\Eloquent\SupportsPartialRelations; +use Illuminate\Database\Eloquent\Builder; use Illuminate\Database\Eloquent\Collection; use Illuminate\Database\Eloquent\Model; +use Illuminate\Database\Eloquent\Relations\Concerns\CanBeOneOfMany; +use Illuminate\Database\Eloquent\Relations\Concerns\ComparesRelatedModels; use Illuminate\Database\Eloquent\Relations\Concerns\SupportsDefaultModels; +use Illuminate\Database\Query\JoinClause; -class MorphOne extends MorphOneOrMany +class MorphOne extends MorphOneOrMany implements SupportsPartialRelations { - use SupportsDefaultModels; + use CanBeOneOfMany, ComparesRelatedModels, SupportsDefaultModels; /** * Get the results of the relationship. @@ -53,6 +58,59 @@ class MorphOne extends MorphOneOrMany return $this->matchOne($models, $results, $relation); } + /** + * Get the relationship query. + * + * @param \Illuminate\Database\Eloquent\Builder $query + * @param \Illuminate\Database\Eloquent\Builder $parentQuery + * @param array|mixed $columns + * @return \Illuminate\Database\Eloquent\Builder + */ + public function getRelationExistenceQuery(Builder $query, Builder $parentQuery, $columns = ['*']) + { + if ($this->isOneOfMany()) { + $this->mergeOneOfManyJoinsTo($query); + } + + return parent::getRelationExistenceQuery($query, $parentQuery, $columns); + } + + /** + * Add constraints for inner join subselect for one of many relationships. + * + * @param \Illuminate\Database\Eloquent\Builder $query + * @param string|null $column + * @param string|null $aggregate + * @return void + */ + public function addOneOfManySubQueryConstraints(Builder $query, $column = null, $aggregate = null) + { + $query->addSelect($this->foreignKey, $this->morphType); + } + + /** + * Get the columns that should be selected by the one of many subquery. + * + * @return array|string + */ + public function getOneOfManySubQuerySelectColumns() + { + return [$this->foreignKey, $this->morphType]; + } + + /** + * Add join query constraints for one of many relationships. + * + * @param \Illuminate\Database\Eloquent\JoinClause $join + * @return void + */ + public function addOneOfManyJoinSubQueryConstraints(JoinClause $join) + { + $join + ->on($this->qualifySubSelectColumn($this->morphType), '=', $this->qualifyRelatedColumn($this->morphType)) + ->on($this->qualifySubSelectColumn($this->foreignKey), '=', $this->qualifyRelatedColumn($this->foreignKey)); + } + /** * Make a new related instance for the given model. * @@ -65,4 +123,15 @@ class MorphOne extends MorphOneOrMany ->setAttribute($this->getForeignKeyName(), $parent->{$this->localKey}) ->setAttribute($this->getMorphType(), $this->morphClass); } + + /** + * Get the value of the model's foreign key. + * + * @param \Illuminate\Database\Eloquent\Model $model + * @return mixed + */ + protected function getRelatedKeyFrom(Model $model) + { + return $model->getAttribute($this->getForeignKeyName()); + } } diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/MorphOneOrMany.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/MorphOneOrMany.php index 887ebe247..ff58ef972 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/MorphOneOrMany.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/MorphOneOrMany.php @@ -50,7 +50,7 @@ abstract class MorphOneOrMany extends HasOneOrMany if (static::$constraints) { parent::addConstraints(); - $this->query->where($this->morphType, $this->morphClass); + $this->getRelationQuery()->where($this->morphType, $this->morphClass); } } @@ -64,7 +64,7 @@ abstract class MorphOneOrMany extends HasOneOrMany { parent::addEagerConstraints($models); - $this->query->where($this->morphType, $this->morphClass); + $this->getRelationQuery()->where($this->morphType, $this->morphClass); } /** diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/MorphPivot.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/MorphPivot.php index 68489265f..7fbe484aa 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/MorphPivot.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/MorphPivot.php @@ -2,7 +2,6 @@ namespace Illuminate\Database\Eloquent\Relations; -use Illuminate\Database\Eloquent\Builder; use Illuminate\Support\Str; class MorphPivot extends Pivot @@ -31,13 +30,26 @@ class MorphPivot extends Pivot * @param \Illuminate\Database\Eloquent\Builder $query * @return \Illuminate\Database\Eloquent\Builder */ - protected function setKeysForSaveQuery(Builder $query) + protected function setKeysForSaveQuery($query) { $query->where($this->morphType, $this->morphClass); return parent::setKeysForSaveQuery($query); } + /** + * Set the keys for a select query. + * + * @param \Illuminate\Database\Eloquent\Builder $query + * @return \Illuminate\Database\Eloquent\Builder + */ + protected function setKeysForSelectQuery($query) + { + $query->where($this->morphType, $this->morphClass); + + return parent::setKeysForSelectQuery($query); + } + /** * Delete the pivot model record from the database. * @@ -62,6 +74,16 @@ class MorphPivot extends Pivot }); } + /** + * Get the morph type for the pivot. + * + * @return string + */ + public function getMorphType() + { + return $this->morphType; + } + /** * Set the morph type for the pivot. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/MorphTo.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/MorphTo.php index 22d1d4d2c..262741f30 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/MorphTo.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/MorphTo.php @@ -6,9 +6,12 @@ use BadMethodCallException; use Illuminate\Database\Eloquent\Builder; use Illuminate\Database\Eloquent\Collection; use Illuminate\Database\Eloquent\Model; +use Illuminate\Database\Eloquent\Relations\Concerns\InteractsWithDictionary; class MorphTo extends BelongsTo { + use InteractsWithDictionary; + /** * The type of the polymorphic relation. * @@ -51,6 +54,13 @@ class MorphTo extends BelongsTo */ protected $morphableEagerLoadCounts = []; + /** + * A map of constraints to apply for each individual morph type. + * + * @var array + */ + protected $morphableConstraints = []; + /** * Create a new morph to relationship instance. * @@ -90,7 +100,10 @@ class MorphTo extends BelongsTo { foreach ($models as $model) { if ($model->{$this->morphType}) { - $this->dictionary[$model->{$this->morphType}][$model->{$this->foreignKey}][] = $model; + $morphTypeKey = $this->getDictionaryKey($model->{$this->morphType}); + $foreignKeyKey = $this->getDictionaryKey($model->{$this->foreignKey}); + + $this->dictionary[$morphTypeKey][$foreignKeyKey][] = $model; } } } @@ -133,10 +146,14 @@ class MorphTo extends BelongsTo (array) ($this->morphableEagerLoadCounts[get_class($instance)] ?? []) ); + if ($callback = ($this->morphableConstraints[get_class($instance)] ?? null)) { + $callback($query); + } + $whereIn = $this->whereInMethod($instance, $ownerKey); return $query->{$whereIn}( - $instance->getTable().'.'.$ownerKey, $this->gatherKeysByType($type) + $instance->getTable().'.'.$ownerKey, $this->gatherKeysByType($type, $instance->getKeyType()) )->get(); } @@ -144,11 +161,16 @@ class MorphTo extends BelongsTo * Gather all of the foreign keys for a given type. * * @param string $type + * @param string $keyType * @return array */ - protected function gatherKeysByType($type) + protected function gatherKeysByType($type, $keyType) { - return array_keys($this->dictionary[$type]); + return $keyType !== 'string' + ? array_keys($this->dictionary[$type]) + : array_map(function ($modelId) { + return (string) $modelId; + }, array_filter(array_keys($this->dictionary[$type]))); } /** @@ -191,7 +213,7 @@ class MorphTo extends BelongsTo protected function matchToMorphParents($type, Collection $results) { foreach ($results as $result) { - $ownerKey = ! is_null($this->ownerKey) ? $result->{$this->ownerKey} : $result->getKey(); + $ownerKey = ! is_null($this->ownerKey) ? $this->getDictionaryKey($result->{$this->ownerKey}) : $result->getKey(); if (isset($this->dictionary[$type][$ownerKey])) { foreach ($this->dictionary[$type][$ownerKey] as $model) { @@ -209,8 +231,14 @@ class MorphTo extends BelongsTo */ public function associate($model) { + if ($model instanceof Model) { + $foreignKey = $this->ownerKey && $model->{$this->ownerKey} + ? $this->ownerKey + : $model->getKeyName(); + } + $this->parent->setAttribute( - $this->foreignKey, $model instanceof Model ? $model->getKey() : null + $this->foreignKey, $model instanceof Model ? $model->{$foreignKey} : null ); $this->parent->setAttribute( @@ -307,6 +335,21 @@ class MorphTo extends BelongsTo return $this; } + /** + * Specify constraints on the query for a given morph type. + * + * @param array $callbacks + * @return \Illuminate\Database\Eloquent\Relations\MorphTo + */ + public function constrain(array $callbacks) + { + $this->morphableConstraints = array_merge( + $this->morphableConstraints, $callbacks + ); + + return $this; + } + /** * Replay stored macro calls on the actual related instance. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/MorphToMany.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/MorphToMany.php index 0adf385e1..c2d574558 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/MorphToMany.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/MorphToMany.php @@ -68,7 +68,7 @@ class MorphToMany extends BelongsToMany { parent::addWhereConstraints(); - $this->query->where($this->table.'.'.$this->morphType, $this->morphClass); + $this->query->where($this->qualifyPivotColumn($this->morphType), $this->morphClass); return $this; } @@ -83,7 +83,7 @@ class MorphToMany extends BelongsToMany { parent::addEagerConstraints($models); - $this->query->where($this->table.'.'.$this->morphType, $this->morphClass); + $this->query->where($this->qualifyPivotColumn($this->morphType), $this->morphClass); } /** @@ -111,7 +111,7 @@ class MorphToMany extends BelongsToMany public function getRelationExistenceQuery(Builder $query, Builder $parentQuery, $columns = ['*']) { return parent::getRelationExistenceQuery($query, $parentQuery, $columns)->where( - $this->table.'.'.$this->morphType, $this->morphClass + $this->qualifyPivotColumn($this->morphType), $this->morphClass ); } @@ -173,7 +173,7 @@ class MorphToMany extends BelongsToMany $defaults = [$this->foreignPivotKey, $this->relatedPivotKey, $this->morphType]; return collect(array_merge($defaults, $this->pivotColumns))->map(function ($column) { - return $this->table.'.'.$column.' as pivot_'.$column; + return $this->qualifyPivotColumn($column).' as pivot_'.$column; })->unique()->all(); } diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Relation.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Relation.php index 6bdb6f7a7..7fe9f3e9f 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Relation.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Relation.php @@ -6,6 +6,8 @@ use Closure; use Illuminate\Database\Eloquent\Builder; use Illuminate\Database\Eloquent\Collection; use Illuminate\Database\Eloquent\Model; +use Illuminate\Database\Eloquent\ModelNotFoundException; +use Illuminate\Database\MultipleRecordsFoundException; use Illuminate\Database\Query\Expression; use Illuminate\Support\Arr; use Illuminate\Support\Traits\ForwardsCalls; @@ -49,12 +51,19 @@ abstract class Relation protected static $constraints = true; /** - * An array to map class names to their morph names in database. + * An array to map class names to their morph names in the database. * * @var array */ public static $morphMap = []; + /** + * The count of self joins. + * + * @var int + */ + protected static $selfJoinCount = 0; + /** * Create a new relation instance. * @@ -144,6 +153,30 @@ abstract class Relation return $this->get(); } + /** + * Execute the query and get the first result if it's the sole matching record. + * + * @param array|string $columns + * @return \Illuminate\Database\Eloquent\Model + * + * @throws \Illuminate\Database\Eloquent\ModelNotFoundException + * @throws \Illuminate\Database\MultipleRecordsFoundException + */ + public function sole($columns = ['*']) + { + $result = $this->take(2)->get($columns); + + if ($result->isEmpty()) { + throw (new ModelNotFoundException)->setModel(get_class($this->related)); + } + + if ($result->count() > 1) { + throw new MultipleRecordsFoundException; + } + + return $result->first(); + } + /** * Execute the query as a "select" statement. * @@ -213,6 +246,17 @@ abstract class Relation ); } + /** + * Get a relationship join table hash. + * + * @param bool $incrementJoinCount + * @return string + */ + public function getRelationCountHash($incrementJoinCount = true) + { + return 'laravel_reserved_'.($incrementJoinCount ? static::$selfJoinCount++ : static::$selfJoinCount); + } + /** * Get all of the primary keys for an array of models. * @@ -227,6 +271,16 @@ abstract class Relation })->values()->unique(null, true)->sort()->all(); } + /** + * Get the query builder that will contain the relationship constraints. + * + * @return \Illuminate\Database\Eloquent\Builder + */ + protected function getRelationQuery() + { + return $this->query; + } + /** * Get the underlying query for the relation. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/SoftDeletes.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/SoftDeletes.php index f50eba85f..c1a3b04c7 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/SoftDeletes.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/SoftDeletes.php @@ -3,7 +3,7 @@ namespace Illuminate\Database\Eloquent; /** - * @method static static|\Illuminate\Database\Eloquent\Builder|\Illuminate\Database\Query\Builder withTrashed() + * @method static static|\Illuminate\Database\Eloquent\Builder|\Illuminate\Database\Query\Builder withTrashed(bool $withTrashed = true) * @method static static|\Illuminate\Database\Eloquent\Builder|\Illuminate\Database\Query\Builder onlyTrashed() * @method static static|\Illuminate\Database\Eloquent\Builder|\Illuminate\Database\Query\Builder withoutTrashed() */ @@ -33,7 +33,9 @@ trait SoftDeletes */ public function initializeSoftDeletes() { - $this->dates[] = $this->getDeletedAtColumn(); + if (! isset($this->casts[$this->getDeletedAtColumn()])) { + $this->casts[$this->getDeletedAtColumn()] = 'datetime'; + } } /** diff --git a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/SoftDeletingScope.php b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/SoftDeletingScope.php index 0d5169662..7528964c1 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Eloquent/SoftDeletingScope.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Eloquent/SoftDeletingScope.php @@ -7,7 +7,7 @@ class SoftDeletingScope implements Scope /** * All of the extensions to be added to the builder. * - * @var array + * @var string[] */ protected $extensions = ['Restore', 'WithTrashed', 'WithoutTrashed', 'OnlyTrashed']; diff --git a/vendor/laravel/framework/src/Illuminate/Database/Events/DatabaseRefreshed.php b/vendor/laravel/framework/src/Illuminate/Database/Events/DatabaseRefreshed.php new file mode 100644 index 000000000..5b1fb4585 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Events/DatabaseRefreshed.php @@ -0,0 +1,10 @@ +connection = $connection; + $this->connectionName = $connection->getName(); + $this->path = $path; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Events/SchemaLoaded.php b/vendor/laravel/framework/src/Illuminate/Database/Events/SchemaLoaded.php new file mode 100644 index 000000000..061a079a9 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Events/SchemaLoaded.php @@ -0,0 +1,41 @@ +connection = $connection; + $this->connectionName = $connection->getName(); + $this->path = $path; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/LazyLoadingViolationException.php b/vendor/laravel/framework/src/Illuminate/Database/LazyLoadingViolationException.php new file mode 100644 index 000000000..1bcd40c95 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/LazyLoadingViolationException.php @@ -0,0 +1,39 @@ +model = $class; + $this->relation = $relation; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/MigrationServiceProvider.php b/vendor/laravel/framework/src/Illuminate/Database/MigrationServiceProvider.php index 9b1f355d1..9ae768577 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/MigrationServiceProvider.php +++ b/vendor/laravel/framework/src/Illuminate/Database/MigrationServiceProvider.php @@ -2,6 +2,7 @@ namespace Illuminate\Database; +use Illuminate\Contracts\Events\Dispatcher; use Illuminate\Contracts\Support\DeferrableProvider; use Illuminate\Database\Console\Migrations\FreshCommand; use Illuminate\Database\Console\Migrations\InstallCommand; @@ -116,7 +117,7 @@ class MigrationServiceProvider extends ServiceProvider implements DeferrableProv protected function registerMigrateCommand() { $this->app->singleton('command.migrate', function ($app) { - return new MigrateCommand($app['migrator']); + return new MigrateCommand($app['migrator'], $app[Dispatcher::class]); }); } diff --git a/vendor/laravel/framework/src/Illuminate/Database/Migrations/DatabaseMigrationRepository.php b/vendor/laravel/framework/src/Illuminate/Database/Migrations/DatabaseMigrationRepository.php index 1ace1a6ff..ed42756b1 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Migrations/DatabaseMigrationRepository.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Migrations/DatabaseMigrationRepository.php @@ -169,6 +169,18 @@ class DatabaseMigrationRepository implements MigrationRepositoryInterface return $schema->hasTable($this->table); } + /** + * Delete the migration repository data store. + * + * @return void + */ + public function deleteRepository() + { + $schema = $this->getConnection()->getSchemaBuilder(); + + $schema->drop($this->table); + } + /** * Get a query builder for the migration table. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Migrations/MigrationCreator.php b/vendor/laravel/framework/src/Illuminate/Database/Migrations/MigrationCreator.php index fca9ed81b..a79039a7a 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Migrations/MigrationCreator.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Migrations/MigrationCreator.php @@ -63,9 +63,12 @@ class MigrationCreator // various place-holders, save the file, and run the post create event. $stub = $this->getStub($table, $create); + $path = $this->getPath($name, $path); + + $this->files->ensureDirectoryExists(dirname($path)); + $this->files->put( - $path = $this->getPath($name, $path), - $this->populateStub($name, $stub, $table) + $path, $this->populateStub($name, $stub, $table) ); // Next, we will fire any hooks that are supposed to fire after a migration is diff --git a/vendor/laravel/framework/src/Illuminate/Database/Migrations/MigrationRepositoryInterface.php b/vendor/laravel/framework/src/Illuminate/Database/Migrations/MigrationRepositoryInterface.php index 410326a9b..840a5e1df 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Migrations/MigrationRepositoryInterface.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Migrations/MigrationRepositoryInterface.php @@ -12,7 +12,7 @@ interface MigrationRepositoryInterface public function getRan(); /** - * Get list of migrations. + * Get the list of migrations. * * @param int $steps * @return array @@ -71,6 +71,13 @@ interface MigrationRepositoryInterface */ public function repositoryExists(); + /** + * Delete the migration repository data store. + * + * @return void + */ + public function deleteRepository(); + /** * Set the information source to gather data. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Migrations/Migrator.php b/vendor/laravel/framework/src/Illuminate/Database/Migrations/Migrator.php index d334e0b56..31df31700 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Migrations/Migrator.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Migrations/Migrator.php @@ -13,6 +13,7 @@ use Illuminate\Filesystem\Filesystem; use Illuminate\Support\Arr; use Illuminate\Support\Collection; use Illuminate\Support\Str; +use ReflectionClass; use Symfony\Component\Console\Output\OutputInterface; class Migrator @@ -185,9 +186,9 @@ class Migrator // First we will resolve a "real" instance of the migration class from this // migration file name. Once we have the instances we can run the actual // command such as "up" or "down", or we can just simulate the action. - $migration = $this->resolve( - $name = $this->getMigrationName($file) - ); + $migration = $this->resolvePath($file); + + $name = $this->getMigrationName($file); if ($pretend) { return $this->pretendToRun($migration, 'up'); @@ -199,14 +200,14 @@ class Migrator $this->runMigration($migration, 'up'); - $runTime = round(microtime(true) - $startTime, 2); + $runTime = number_format((microtime(true) - $startTime) * 1000, 2); // Once we have run a migrations class, we will log that it was run in this // repository so that we don't try to run it next time we do a migration // in the application. A migration repository keeps the migrate order. $this->repository->log($name, $batch); - $this->note("Migrated: {$name} ({$runTime} seconds)"); + $this->note("Migrated: {$name} ({$runTime}ms)"); } /** @@ -348,9 +349,9 @@ class Migrator // First we will get the file name of the migration so we can resolve out an // instance of the migration. Once we get an instance we can either run a // pretend execution of the migration or we can run the real migration. - $instance = $this->resolve( - $name = $this->getMigrationName($file) - ); + $instance = $this->resolvePath($file); + + $name = $this->getMigrationName($file); $this->note("Rolling back: {$name}"); @@ -362,14 +363,14 @@ class Migrator $this->runMigration($instance, 'down'); - $runTime = round(microtime(true) - $startTime, 2); + $runTime = number_format((microtime(true) - $startTime) * 1000, 2); // Once we have successfully run the migration "down" we will remove it from // the migration repository so it will be considered to have not been run // by the application then will be able to fire by any later operation. $this->repository->delete($migration); - $this->note("Rolled back: {$name} ({$runTime} seconds)"); + $this->note("Rolled back: {$name} ({$runTime}ms)"); } /** @@ -413,6 +414,12 @@ class Migrator foreach ($this->getQueries($migration, $method) as $query) { $name = get_class($migration); + $reflectionClass = new ReflectionClass($migration); + + if ($reflectionClass->isAnonymous()) { + $name = $this->getMigrationName($reflectionClass->getFileName()); + } + $this->note("{$name}: {$query['query']}"); } } @@ -448,11 +455,41 @@ class Migrator */ public function resolve($file) { - $class = Str::studly(implode('_', array_slice(explode('_', $file), 4))); + $class = $this->getMigrationClass($file); return new $class; } + /** + * Resolve a migration instance from a migration path. + * + * @param string $path + * @return object + */ + protected function resolvePath(string $path) + { + $class = $this->getMigrationClass($this->getMigrationName($path)); + + if (class_exists($class) && realpath($path) == (new ReflectionClass($class))->getFileName()) { + return new $class; + } + + $migration = $this->files->getRequire($path); + + return is_object($migration) ? $migration : new $class; + } + + /** + * Generate a migration class name based on the migration file name. + * + * @param string $migrationName + * @return string + */ + protected function getMigrationClass(string $migrationName): string + { + return Str::studly(implode('_', array_slice(explode('_', $migrationName), 4))); + } + /** * Get all of the migration files in a given path. * @@ -608,6 +645,26 @@ class Migrator return $this->repository->repositoryExists(); } + /** + * Determine if any migrations have been run. + * + * @return bool + */ + public function hasRunAnyMigrations() + { + return $this->repositoryExists() && count($this->repository->getRan()) > 0; + } + + /** + * Delete the migration repository data store. + * + * @return void + */ + public function deleteRepository() + { + return $this->repository->deleteRepository(); + } + /** * Get the file system instance. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/MultipleRecordsFoundException.php b/vendor/laravel/framework/src/Illuminate/Database/MultipleRecordsFoundException.php new file mode 100755 index 000000000..cccb7e417 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/MultipleRecordsFoundException.php @@ -0,0 +1,10 @@ +getPdo()->getAttribute(PDO::ATTR_SERVER_VERSION), 'MariaDB') !== false; + } + /** * Get the default query grammar instance. * @@ -44,6 +59,18 @@ class MySqlConnection extends Connection return $this->withTablePrefix(new SchemaGrammar); } + /** + * Get the schema state for the connection. + * + * @param \Illuminate\Filesystem\Filesystem|null $files + * @param callable|null $processFactory + * @return \Illuminate\Database\Schema\MySqlSchemaState + */ + public function getSchemaState(Filesystem $files = null, callable $processFactory = null) + { + return new MySqlSchemaState($this, $files, $processFactory); + } + /** * Get the default post processor instance. * @@ -57,10 +84,10 @@ class MySqlConnection extends Connection /** * Get the Doctrine DBAL driver. * - * @return \Doctrine\DBAL\Driver\PDOMySql\Driver + * @return \Doctrine\DBAL\Driver\PDOMySql\Driver|\Illuminate\Database\PDO\MySqlDriver */ protected function getDoctrineDriver() { - return new DoctrineDriver; + return class_exists(Version::class) ? new DoctrineDriver : new MySqlDriver; } } diff --git a/vendor/laravel/framework/src/Illuminate/Database/PDO/Concerns/ConnectsToDatabase.php b/vendor/laravel/framework/src/Illuminate/Database/PDO/Concerns/ConnectsToDatabase.php new file mode 100644 index 000000000..84c333801 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/PDO/Concerns/ConnectsToDatabase.php @@ -0,0 +1,27 @@ +connection = $connection; + } + + /** + * Execute an SQL statement. + * + * @param string $statement + * @return int + */ + public function exec(string $statement): int + { + try { + $result = $this->connection->exec($statement); + + \assert($result !== false); + + return $result; + } catch (PDOException $exception) { + throw Exception::new($exception); + } + } + + /** + * Prepare a new SQL statement. + * + * @param string $sql + * @return \Doctrine\DBAL\Driver\Statement + */ + public function prepare(string $sql): StatementInterface + { + try { + return $this->createStatement( + $this->connection->prepare($sql) + ); + } catch (PDOException $exception) { + throw Exception::new($exception); + } + } + + /** + * Execute a new query against the connection. + * + * @param string $sql + * @return \Doctrine\DBAL\Driver\Result + */ + public function query(string $sql): ResultInterface + { + try { + $stmt = $this->connection->query($sql); + + \assert($stmt instanceof PDOStatement); + + return new Result($stmt); + } catch (PDOException $exception) { + throw Exception::new($exception); + } + } + + /** + * Get the last insert ID. + * + * @param string|null $name + * @return mixed + */ + public function lastInsertId($name = null) + { + try { + if ($name === null) { + return $this->connection->lastInsertId(); + } + + return $this->connection->lastInsertId($name); + } catch (PDOException $exception) { + throw Exception::new($exception); + } + } + + /** + * Create a new statement instance. + * + * @param \PDOStatement + * @return \Doctrine\DBAL\Driver\PDO\Statement + */ + protected function createStatement(PDOStatement $stmt): Statement + { + return new Statement($stmt); + } + + /** + * Begin a new database transaction. + * + * @return void + */ + public function beginTransaction() + { + return $this->connection->beginTransaction(); + } + + /** + * Commit a database transaction. + * + * @return void + */ + public function commit() + { + return $this->connection->commit(); + } + + /** + * Rollback a database transaction. + * + * @return void + */ + public function rollBack() + { + return $this->connection->rollBack(); + } + + /** + * Wrap quotes around the given input. + * + * @param string $input + * @param string $type + * @return string + */ + public function quote($input, $type = ParameterType::STRING) + { + return $this->connection->quote($input, $type); + } + + /** + * Get the server version for the connection. + * + * @return string + */ + public function getServerVersion() + { + return $this->connection->getAttribute(PDO::ATTR_SERVER_VERSION); + } + + /** + * Get the wrapped PDO connection. + * + * @return \PDO + */ + public function getWrappedConnection(): PDO + { + return $this->connection; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/PDO/MySqlDriver.php b/vendor/laravel/framework/src/Illuminate/Database/PDO/MySqlDriver.php new file mode 100644 index 000000000..5f68c6fab --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/PDO/MySqlDriver.php @@ -0,0 +1,11 @@ +connection = $connection; + } + + /** + * Prepare a new SQL statement. + * + * @param string $sql + * @return \Doctrine\DBAL\Driver\Statement + */ + public function prepare(string $sql): StatementInterface + { + return new Statement( + $this->connection->prepare($sql) + ); + } + + /** + * Execute a new query against the connection. + * + * @param string $sql + * @return \Doctrine\DBAL\Driver\Result + */ + public function query(string $sql): Result + { + return $this->connection->query($sql); + } + + /** + * Execute an SQL statement. + * + * @param string $statement + * @return int + */ + public function exec(string $statement): int + { + return $this->connection->exec($statement); + } + + /** + * Get the last insert ID. + * + * @param string|null $name + * @return mixed + */ + public function lastInsertId($name = null) + { + if ($name === null) { + return $this->connection->lastInsertId($name); + } + + return $this->prepare('SELECT CONVERT(VARCHAR(MAX), current_value) FROM sys.sequences WHERE name = ?') + ->execute([$name]) + ->fetchOne(); + } + + /** + * Begin a new database transaction. + * + * @return void + */ + public function beginTransaction() + { + return $this->connection->beginTransaction(); + } + + /** + * Commit a database transaction. + * + * @return void + */ + public function commit() + { + return $this->connection->commit(); + } + + /** + * Rollback a database transaction. + * + * @return void + */ + public function rollBack() + { + return $this->connection->rollBack(); + } + + /** + * Wrap quotes around the given input. + * + * @param string $value + * @param int $type + * @return string + */ + public function quote($value, $type = ParameterType::STRING) + { + $val = $this->connection->quote($value, $type); + + // Fix for a driver version terminating all values with null byte... + if (\is_string($val) && \strpos($val, "\0") !== false) { + $val = \substr($val, 0, -1); + } + + return $val; + } + + /** + * Get the server version for the connection. + * + * @return string + */ + public function getServerVersion() + { + return $this->connection->getServerVersion(); + } + + /** + * Get the wrapped PDO connection. + * + * @return \PDO + */ + public function getWrappedConnection(): PDO + { + return $this->connection->getWrappedConnection(); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/PDO/SqlServerDriver.php b/vendor/laravel/framework/src/Illuminate/Database/PDO/SqlServerDriver.php new file mode 100644 index 000000000..bbb3bbd32 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/PDO/SqlServerDriver.php @@ -0,0 +1,15 @@ +withTablePrefix(new SchemaGrammar); } + /** + * Get the schema state for the connection. + * + * @param \Illuminate\Filesystem\Filesystem|null $files + * @param callable|null $processFactory + * @return \Illuminate\Database\Schema\PostgresSchemaState + */ + public function getSchemaState(Filesystem $files = null, callable $processFactory = null) + { + return new PostgresSchemaState($this, $files, $processFactory); + } + /** * Get the default post processor instance. * @@ -84,10 +100,10 @@ class PostgresConnection extends Connection /** * Get the Doctrine DBAL driver. * - * @return \Doctrine\DBAL\Driver\PDOPgSql\Driver + * @return \Doctrine\DBAL\Driver\PDOPgSql\Driver|\Illuminate\Database\PDO\PostgresDriver */ protected function getDoctrineDriver() { - return new DoctrineDriver; + return class_exists(Version::class) ? new DoctrineDriver : new PostgresDriver; } } diff --git a/vendor/laravel/framework/src/Illuminate/Database/Query/Builder.php b/vendor/laravel/framework/src/Illuminate/Database/Query/Builder.php index adb8a8d5b..0ef10ac1c 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Query/Builder.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Query/Builder.php @@ -6,11 +6,14 @@ use Closure; use DateTimeInterface; use Illuminate\Contracts\Support\Arrayable; use Illuminate\Database\Concerns\BuildsQueries; +use Illuminate\Database\Concerns\ExplainsQueries; use Illuminate\Database\ConnectionInterface; use Illuminate\Database\Eloquent\Builder as EloquentBuilder; use Illuminate\Database\Eloquent\Relations\Relation; use Illuminate\Database\Query\Grammars\Grammar; use Illuminate\Database\Query\Processors\Processor; +use Illuminate\Pagination\CursorPaginationException; +use Illuminate\Pagination\CursorPaginator; use Illuminate\Pagination\Paginator; use Illuminate\Support\Arr; use Illuminate\Support\Collection; @@ -23,7 +26,7 @@ use RuntimeException; class Builder { - use BuildsQueries, ForwardsCalls, Macroable { + use BuildsQueries, ExplainsQueries, ForwardsCalls, Macroable { __call as macroCall; } @@ -180,10 +183,17 @@ class Builder public $lock; /** - * All of the available clause operators. + * The callbacks that should be invoked before the query is executed. * * @var array */ + public $beforeQueryCallbacks = []; + + /** + * All of the available clause operators. + * + * @var string[] + */ public $operators = [ '=', '<', '>', '<=', '>=', '<>', '!=', '<=>', 'like', 'like binary', 'not like', 'ilike', @@ -194,7 +204,7 @@ class Builder ]; /** - * Whether use write pdo for select. + * Whether to use write pdo for the select. * * @var bool */ @@ -243,7 +253,7 @@ class Builder /** * Add a subselect expression to the query. * - * @param \Closure|$this|string $query + * @param \Closure|\Illuminate\Database\Query\Builder|\Illuminate\Database\Eloquent\Builder|string $query * @param string $as * @return $this * @@ -339,6 +349,8 @@ class Builder protected function parseSub($query) { if ($query instanceof self || $query instanceof EloquentBuilder || $query instanceof Relation) { + $query = $this->prependDatabaseNameIfCrossDatabaseQuery($query); + return [$query->toSql(), $query->getBindings()]; } elseif (is_string($query)) { return [$query, []]; @@ -349,6 +361,26 @@ class Builder } } + /** + * Prepend the database name if the given query is on another database. + * + * @param mixed $query + * @return mixed + */ + protected function prependDatabaseNameIfCrossDatabaseQuery($query) + { + if ($query->getConnection()->getDatabaseName() !== + $this->getConnection()->getDatabaseName()) { + $databaseName = $query->getConnection()->getDatabaseName(); + + if (strpos($query->from, $databaseName) !== 0 && strpos($query->from, '.') === false) { + $query->from($databaseName.'.'.$query->from); + } + } + + return $query; + } + /** * Add a new select column to the query. * @@ -468,7 +500,7 @@ class Builder /** * Add a subquery join clause to the query. * - * @param \Closure|\Illuminate\Database\Query\Builder|string $query + * @param \Closure|\Illuminate\Database\Query\Builder|\Illuminate\Database\Eloquent\Builder|string $query * @param string $as * @param \Closure|string $first * @param string|null $operator @@ -521,7 +553,7 @@ class Builder /** * Add a subquery left join to the query. * - * @param \Closure|\Illuminate\Database\Query\Builder|string $query + * @param \Closure|\Illuminate\Database\Query\Builder|\Illuminate\Database\Eloquent\Builder|string $query * @param string $as * @param \Closure|string $first * @param string|null $operator @@ -564,7 +596,7 @@ class Builder /** * Add a subquery right join to the query. * - * @param \Closure|\Illuminate\Database\Query\Builder|string $query + * @param \Closure|\Illuminate\Database\Query\Builder|\Illuminate\Database\Eloquent\Builder|string $query * @param string $as * @param \Closure|string $first * @param string|null $operator @@ -596,6 +628,26 @@ class Builder return $this; } + /** + * Add a subquery cross join to the query. + * + * @param \Closure|\Illuminate\Database\Query\Builder|string $query + * @param string $as + * @return $this + */ + public function crossJoinSub($query, $as) + { + [$query, $bindings] = $this->createSub($query); + + $expression = '('.$query.') as '.$this->grammar->wrapTable($as); + + $this->addBinding($bindings, 'join'); + + $this->joins[] = $this->newJoinClause($this, 'cross', new Expression($expression)); + + return $this; + } + /** * Get a new join clause. * @@ -1066,7 +1118,7 @@ class Builder /** * Add a where between statement to the query. * - * @param string $column + * @param string|\Illuminate\Database\Query\Expression $column * @param array $values * @param string $boolean * @param bool $not @@ -2022,7 +2074,7 @@ class Builder { $property = $this->unions ? 'unionOffset' : 'offset'; - $this->$property = max(0, $value); + $this->$property = max(0, (int) $value); return $this; } @@ -2211,6 +2263,33 @@ class Builder return $this->lock(false); } + /** + * Register a closure to be invoked before the query is executed. + * + * @param callable $callback + * @return $this + */ + public function beforeQuery(callable $callback) + { + $this->beforeQueryCallbacks[] = $callback; + + return $this; + } + + /** + * Invoke the "before query" modification callbacks. + * + * @return void + */ + public function applyBeforeQueryCallbacks() + { + foreach ($this->beforeQueryCallbacks as $callback) { + $callback($this); + } + + $this->beforeQueryCallbacks = []; + } + /** * Get the SQL representation of the query. * @@ -2218,6 +2297,8 @@ class Builder */ public function toSql() { + $this->applyBeforeQueryCallbacks(); + return $this->grammar->compileSelect($this); } @@ -2317,6 +2398,75 @@ class Builder ]); } + /** + * Get a paginator only supporting simple next and previous links. + * + * This is more efficient on larger data-sets, etc. + * + * @param int|null $perPage + * @param array $columns + * @param string $cursorName + * @param string|null $cursor + * @return \Illuminate\Contracts\Pagination\Paginator + * @throws \Illuminate\Pagination\CursorPaginationException + */ + public function cursorPaginate($perPage = 15, $columns = ['*'], $cursorName = 'cursor', $cursor = null) + { + $cursor = $cursor ?: CursorPaginator::resolveCurrentCursor($cursorName); + + $orders = $this->ensureOrderForCursorPagination(! is_null($cursor) && $cursor->pointsToPreviousItems()); + + $orderDirection = $orders->first()['direction'] ?? 'asc'; + + $comparisonOperator = $orderDirection === 'asc' ? '>' : '<'; + + $parameters = $orders->pluck('column')->toArray(); + + if (! is_null($cursor)) { + if (count($parameters) === 1) { + $this->where($column = $parameters[0], $comparisonOperator, $cursor->parameter($column)); + } elseif (count($parameters) > 1) { + $this->whereRowValues($parameters, $comparisonOperator, $cursor->parameters($parameters)); + } + } + + $this->limit($perPage + 1); + + return $this->cursorPaginator($this->get($columns), $perPage, $cursor, [ + 'path' => Paginator::resolveCurrentPath(), + 'cursorName' => $cursorName, + 'parameters' => $parameters, + ]); + } + + /** + * Ensure the proper order by required for cursor pagination. + * + * @param bool $shouldReverse + * @return \Illuminate\Support\Collection + * @throws \Illuminate\Pagination\CursorPaginationException + */ + protected function ensureOrderForCursorPagination($shouldReverse = false) + { + $this->enforceOrderBy(); + + $orderDirections = collect($this->orders)->pluck('direction')->unique(); + + if ($orderDirections->count() > 1) { + throw new CursorPaginationException('Only a single order by direction is supported when using cursor pagination.'); + } + + if ($shouldReverse) { + $this->orders = collect($this->orders)->map(function ($order) { + $order['direction'] = $order['direction'] === 'asc' ? 'desc' : 'asc'; + + return $order; + })->toArray(); + } + + return collect($this->orders); + } + /** * Get the count of the total records for the paginator. * @@ -2549,6 +2699,8 @@ class Builder */ public function exists() { + $this->applyBeforeQueryCallbacks(); + $results = $this->connection->select( $this->grammar->compileExists($this), $this->getBindings(), ! $this->useWritePdo ); @@ -2674,8 +2826,8 @@ class Builder */ public function aggregate($function, $columns = ['*']) { - $results = $this->cloneWithout($this->unions ? [] : ['columns']) - ->cloneWithoutBindings($this->unions ? [] : ['select']) + $results = $this->cloneWithout($this->unions || $this->havings ? [] : ['columns']) + ->cloneWithoutBindings($this->unions || $this->havings ? [] : ['select']) ->setAggregate($function, $columns) ->get($columns); @@ -2758,7 +2910,7 @@ class Builder } /** - * Insert a new record into the database. + * Insert new records into the database. * * @param array $values * @return bool @@ -2787,6 +2939,8 @@ class Builder } } + $this->applyBeforeQueryCallbacks(); + // Finally, we will run this query against the database connection and return // the results. We will need to also flatten these bindings before running // the query so they are all in one huge, flattened array for execution. @@ -2797,7 +2951,7 @@ class Builder } /** - * Insert a new record into the database while ignoring errors. + * Insert new records into the database while ignoring errors. * * @param array $values * @return int @@ -2817,6 +2971,8 @@ class Builder } } + $this->applyBeforeQueryCallbacks(); + return $this->connection->affectingStatement( $this->grammar->compileInsertOrIgnore($this, $values), $this->cleanBindings(Arr::flatten($values, 1)) @@ -2832,6 +2988,8 @@ class Builder */ public function insertGetId(array $values, $sequence = null) { + $this->applyBeforeQueryCallbacks(); + $sql = $this->grammar->compileInsertGetId($this, $values, $sequence); $values = $this->cleanBindings($values); @@ -2848,6 +3006,8 @@ class Builder */ public function insertUsing(array $columns, $query) { + $this->applyBeforeQueryCallbacks(); + [$sql, $bindings] = $this->createSub($query); return $this->connection->affectingStatement( @@ -2857,13 +3017,15 @@ class Builder } /** - * Update a record in the database. + * Update records in the database. * * @param array $values * @return int */ public function update(array $values) { + $this->applyBeforeQueryCallbacks(); + $sql = $this->grammar->compileUpdate($this, $values); return $this->connection->update($sql, $this->cleanBindings( @@ -2891,6 +3053,51 @@ class Builder return (bool) $this->limit(1)->update($values); } + /** + * Insert new records or update the existing ones. + * + * @param array $values + * @param array|string $uniqueBy + * @param array|null $update + * @return int + */ + public function upsert(array $values, $uniqueBy, $update = null) + { + if (empty($values)) { + return 0; + } elseif ($update === []) { + return (int) $this->insert($values); + } + + if (! is_array(reset($values))) { + $values = [$values]; + } else { + foreach ($values as $key => $value) { + ksort($value); + + $values[$key] = $value; + } + } + + if (is_null($update)) { + $update = array_keys(reset($values)); + } + + $this->applyBeforeQueryCallbacks(); + + $bindings = $this->cleanBindings(array_merge( + Arr::flatten($values, 1), + collect($update)->reject(function ($value, $key) { + return is_int($key); + })->all() + )); + + return $this->connection->affectingStatement( + $this->grammar->compileUpsert($this, $values, (array) $uniqueBy, $update), + $bindings + ); + } + /** * Increment a column's value by a given amount. * @@ -2938,7 +3145,7 @@ class Builder } /** - * Delete a record from the database. + * Delete records from the database. * * @param mixed $id * @return int @@ -2952,6 +3159,8 @@ class Builder $this->where($this->from.'.id', '=', $id); } + $this->applyBeforeQueryCallbacks(); + return $this->connection->delete( $this->grammar->compileDelete($this), $this->cleanBindings( $this->grammar->prepareBindingsForDelete($this->bindings) @@ -2966,6 +3175,8 @@ class Builder */ public function truncate() { + $this->applyBeforeQueryCallbacks(); + foreach ($this->grammar->compileTruncate($this) as $sql => $bindings) { $this->connection->statement($sql, $bindings); } @@ -3085,7 +3296,7 @@ class Builder * @param array $bindings * @return array */ - protected function cleanBindings(array $bindings) + public function cleanBindings(array $bindings) { return array_values(array_filter($bindings, function ($binding) { return ! $binding instanceof Expression; @@ -3169,6 +3380,16 @@ class Builder $value instanceof Closure; } + /** + * Clone the query. + * + * @return static + */ + public function clone() + { + return clone $this; + } + /** * Clone the query without the given properties. * @@ -3177,7 +3398,7 @@ class Builder */ public function cloneWithout(array $properties) { - return tap(clone $this, function ($clone) use ($properties) { + return tap($this->clone(), function ($clone) use ($properties) { foreach ($properties as $property) { $clone->{$property} = null; } @@ -3192,7 +3413,7 @@ class Builder */ public function cloneWithoutBindings(array $except) { - return tap(clone $this, function ($clone) use ($except) { + return tap($this->clone(), function ($clone) use ($except) { foreach ($except as $type) { $clone->bindings[$type] = []; } diff --git a/vendor/laravel/framework/src/Illuminate/Database/Query/Grammars/Grammar.php b/vendor/laravel/framework/src/Illuminate/Database/Query/Grammars/Grammar.php index fa9e962d1..d7bc534da 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Query/Grammars/Grammar.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Query/Grammars/Grammar.php @@ -21,7 +21,7 @@ class Grammar extends BaseGrammar /** * The components that make up a select clause. * - * @var array + * @var string[] */ protected $selectComponents = [ 'aggregate', @@ -45,7 +45,7 @@ class Grammar extends BaseGrammar */ public function compileSelect(Builder $query) { - if ($query->unions && $query->aggregate) { + if (($query->unions || $query->havings) && $query->aggregate) { return $this->compileUnionAggregate($query); } @@ -181,7 +181,7 @@ class Grammar extends BaseGrammar * @param \Illuminate\Database\Query\Builder $query * @return string */ - protected function compileWheres(Builder $query) + public function compileWheres(Builder $query) { // Each type of where clauses has its own compiler function which is responsible // for actually creating the where clauses SQL. This helps keep the code nice @@ -250,7 +250,9 @@ class Grammar extends BaseGrammar { $value = $this->parameter($where['value']); - return $this->wrap($where['column']).' '.$where['operator'].' '.$value; + $operator = str_replace('?', '??', $where['operator']); + + return $this->wrap($where['column']).' '.$operator.' '.$value; } /** @@ -457,7 +459,7 @@ class Grammar extends BaseGrammar } /** - * Compile a where clause comparing two columns.. + * Compile a where clause comparing two columns. * * @param \Illuminate\Database\Query\Builder $query * @param array $where @@ -993,6 +995,22 @@ class Grammar extends BaseGrammar return "update {$table} {$joins} set {$columns} {$where}"; } + /** + * Compile an "upsert" statement into SQL. + * + * @param \Illuminate\Database\Query\Builder $query + * @param array $values + * @param array $uniqueBy + * @param array $update + * @return string + * + * @throws \RuntimeException + */ + public function compileUpsert(Builder $query, array $values, array $uniqueBy, array $update) + { + throw new RuntimeException('This database engine does not support upserts.'); + } + /** * Prepare the bindings for an update statement. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Query/Grammars/MySqlGrammar.php b/vendor/laravel/framework/src/Illuminate/Database/Query/Grammars/MySqlGrammar.php index 494018803..17b1aff01 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Query/Grammars/MySqlGrammar.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Query/Grammars/MySqlGrammar.php @@ -10,17 +10,16 @@ class MySqlGrammar extends Grammar /** * The grammar specific operators. * - * @var array + * @var string[] */ protected $operators = ['sounds like']; /** * Add a "where null" clause to the query. * - * @param string|array $columns - * @param string $boolean - * @param bool $not - * @return $this + * @param \Illuminate\Database\Query\Builder $query + * @param array $where + * @return string */ protected function whereNull(Builder $query, $where) { @@ -36,9 +35,9 @@ class MySqlGrammar extends Grammar /** * Add a "where not null" clause to the query. * - * @param string|array $columns - * @param string $boolean - * @return $this + * @param \Illuminate\Database\Query\Builder $query + * @param array $where + * @return string */ protected function whereNotNull(Builder $query, $where) { @@ -153,6 +152,28 @@ class MySqlGrammar extends Grammar })->implode(', '); } + /** + * Compile an "upsert" statement into SQL. + * + * @param \Illuminate\Database\Query\Builder $query + * @param array $values + * @param array $uniqueBy + * @param array $update + * @return string + */ + public function compileUpsert(Builder $query, array $values, array $uniqueBy, array $update) + { + $sql = $this->compileInsert($query, $values).' on duplicate key update '; + + $columns = collect($update)->map(function ($value, $key) { + return is_numeric($key) + ? $this->wrap($value).' = values('.$this->wrap($value).')' + : $this->wrap($key).' = '.$this->parameter($value); + })->implode(', '); + + return $sql.$columns; + } + /** * Prepare a JSON column being updated using the JSON_SET function. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Query/Grammars/PostgresGrammar.php b/vendor/laravel/framework/src/Illuminate/Database/Query/Grammars/PostgresGrammar.php index 46420bb6a..f0896a35a 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Query/Grammars/PostgresGrammar.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Query/Grammars/PostgresGrammar.php @@ -11,13 +11,13 @@ class PostgresGrammar extends Grammar /** * All of the available clause operators. * - * @var array + * @var string[] */ protected $operators = [ '=', '<', '>', '<=', '>=', '<>', '!=', 'like', 'not like', 'between', 'ilike', 'not ilike', '~', '&', '|', '#', '<<', '>>', '<<=', '>>=', - '&&', '@>', '<@', '?', '?|', '?&', '||', '-', '-', '#-', + '&&', '@>', '<@', '?', '?|', '?&', '||', '-', '@?', '@@', '#-', 'is distinct from', 'is not distinct from', ]; @@ -218,6 +218,30 @@ class PostgresGrammar extends Grammar })->implode(', '); } + /** + * Compile an "upsert" statement into SQL. + * + * @param \Illuminate\Database\Query\Builder $query + * @param array $values + * @param array $uniqueBy + * @param array $update + * @return string + */ + public function compileUpsert(Builder $query, array $values, array $uniqueBy, array $update) + { + $sql = $this->compileInsert($query, $values); + + $sql .= ' on conflict ('.$this->columnize($uniqueBy).') do update set '; + + $columns = collect($update)->map(function ($value, $key) { + return is_numeric($key) + ? $this->wrap($value).' = '.$this->wrapValue('excluded').'.'.$this->wrap($value) + : $this->wrap($key).' = '.$this->parameter($value); + })->implode(', '); + + return $sql.$columns; + } + /** * Prepares a JSON column being updated using the JSONB_SET function. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Query/Grammars/SQLiteGrammar.php b/vendor/laravel/framework/src/Illuminate/Database/Query/Grammars/SQLiteGrammar.php index 2c27ddf3c..29a379686 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Query/Grammars/SQLiteGrammar.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Query/Grammars/SQLiteGrammar.php @@ -11,7 +11,7 @@ class SQLiteGrammar extends Grammar /** * All of the available clause operators. * - * @var array + * @var string[] */ protected $operators = [ '=', '<', '>', '<=', '>=', '<>', '!=', @@ -182,6 +182,30 @@ class SQLiteGrammar extends Grammar })->implode(', '); } + /** + * Compile an "upsert" statement into SQL. + * + * @param \Illuminate\Database\Query\Builder $query + * @param array $values + * @param array $uniqueBy + * @param array $update + * @return string + */ + public function compileUpsert(Builder $query, array $values, array $uniqueBy, array $update) + { + $sql = $this->compileInsert($query, $values); + + $sql .= ' on conflict ('.$this->columnize($uniqueBy).') do update set '; + + $columns = collect($update)->map(function ($value, $key) { + return is_numeric($key) + ? $this->wrap($value).' = '.$this->wrapValue('excluded').'.'.$this->wrap($value) + : $this->wrap($key).' = '.$this->parameter($value); + })->implode(', '); + + return $sql.$columns; + } + /** * Group the nested JSON columns. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Query/Grammars/SqlServerGrammar.php b/vendor/laravel/framework/src/Illuminate/Database/Query/Grammars/SqlServerGrammar.php index 9dfc22939..62b9aaaea 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Query/Grammars/SqlServerGrammar.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Query/Grammars/SqlServerGrammar.php @@ -11,7 +11,7 @@ class SqlServerGrammar extends Grammar /** * All of the available clause operators. * - * @var array + * @var string[] */ protected $operators = [ '=', '<', '>', '<=', '>=', '!<', '!>', '<>', '!=', @@ -61,8 +61,8 @@ class SqlServerGrammar extends Grammar // If there is a limit on the query, but not an offset, we will add the top // clause to the query, which serves as a "limit" type clause within the // SQL Server system similar to the limit keywords available in MySQL. - if ($query->limit > 0 && $query->offset <= 0) { - $select .= 'top '.$query->limit.' '; + if (is_numeric($query->limit) && $query->limit > 0 && $query->offset <= 0) { + $select .= 'top '.((int) $query->limit).' '; } return $select.$this->columnize($columns); @@ -222,10 +222,10 @@ class SqlServerGrammar extends Grammar */ protected function compileRowConstraint($query) { - $start = $query->offset + 1; + $start = (int) $query->offset + 1; if ($query->limit > 0) { - $finish = $query->offset + $query->limit; + $finish = (int) $query->offset + (int) $query->limit; return "between {$start} and {$finish}"; } @@ -341,6 +341,48 @@ class SqlServerGrammar extends Grammar return "update {$alias} set {$columns} from {$table} {$joins} {$where}"; } + /** + * Compile an "upsert" statement into SQL. + * + * @param \Illuminate\Database\Query\Builder $query + * @param array $values + * @param array $uniqueBy + * @param array $update + * @return string + */ + public function compileUpsert(Builder $query, array $values, array $uniqueBy, array $update) + { + $columns = $this->columnize(array_keys(reset($values))); + + $sql = 'merge '.$this->wrapTable($query->from).' '; + + $parameters = collect($values)->map(function ($record) { + return '('.$this->parameterize($record).')'; + })->implode(', '); + + $sql .= 'using (values '.$parameters.') '.$this->wrapTable('laravel_source').' ('.$columns.') '; + + $on = collect($uniqueBy)->map(function ($column) use ($query) { + return $this->wrap('laravel_source.'.$column).' = '.$this->wrap($query->from.'.'.$column); + })->implode(' and '); + + $sql .= 'on '.$on.' '; + + if ($update) { + $update = collect($update)->map(function ($value, $key) { + return is_numeric($key) + ? $this->wrap($value).' = '.$this->wrap('laravel_source.'.$value) + : $this->wrap($key).' = '.$this->parameter($value); + })->implode(', '); + + $sql .= 'when matched then update set '.$update.' '; + } + + $sql .= 'when not matched then insert ('.$columns.') values ('.$columns.');'; + + return $sql; + } + /** * Prepare the bindings for an update statement. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/RecordsNotFoundException.php b/vendor/laravel/framework/src/Illuminate/Database/RecordsNotFoundException.php new file mode 100755 index 000000000..3e0d95575 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/RecordsNotFoundException.php @@ -0,0 +1,10 @@ +withTablePrefix(new SchemaGrammar); } + /** + * Get the schema state for the connection. + * + * @param \Illuminate\Filesystem\Filesystem|null $files + * @param callable|null $processFactory + * + * @throws \RuntimeException + */ + public function getSchemaState(Filesystem $files = null, callable $processFactory = null) + { + return new SqliteSchemaState($this, $files, $processFactory); + } + /** * Get the default post processor instance. * @@ -81,11 +98,11 @@ class SQLiteConnection extends Connection /** * Get the Doctrine DBAL driver. * - * @return \Doctrine\DBAL\Driver\PDOSqlite\Driver + * @return \Doctrine\DBAL\Driver\PDOSqlite\Driver|\Illuminate\Database\PDO\SQLiteDriver */ protected function getDoctrineDriver() { - return new DoctrineDriver; + return class_exists(Version::class) ? new DoctrineDriver : new SQLiteDriver; } /** diff --git a/vendor/laravel/framework/src/Illuminate/Database/Schema/Blueprint.php b/vendor/laravel/framework/src/Illuminate/Database/Schema/Blueprint.php index f01603f76..e2b968ab6 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Schema/Blueprint.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Schema/Blueprint.php @@ -71,6 +71,13 @@ class Blueprint */ public $temporary = false; + /** + * The column to add new columns after. + * + * @var string + */ + public $after; + /** * Create a new schema blueprint. * @@ -255,7 +262,7 @@ class Blueprint * * @return bool */ - protected function creating() + public function creating() { return collect($this->commands)->contains(function ($command) { return $command->name === 'create'; @@ -382,6 +389,19 @@ class Blueprint return $this->dropIndexCommand('dropForeign', 'foreign', $index); } + /** + * Indicate that the given column and foreign key should be dropped. + * + * @param string $column + * @return \Illuminate\Support\Fluent + */ + public function dropConstrainedForeignId($column) + { + $this->dropForeign([$column]); + + return $this->dropColumn($column); + } + /** * Indicate that the given indexes should be renamed. * @@ -657,6 +677,17 @@ class Blueprint return $this->addColumn('string', $column, compact('length')); } + /** + * Create a new tiny text column on the table. + * + * @param string $column + * @return \Illuminate\Database\Schema\ColumnDefinition + */ + public function tinyText($column) + { + return $this->addColumn('tinyText', $column); + } + /** * Create a new text column on the table. * @@ -823,14 +854,30 @@ class Blueprint */ public function foreignId($column) { - $this->columns[] = $column = new ForeignIdColumnDefinition($this, [ + return $this->addColumnDefinition(new ForeignIdColumnDefinition($this, [ 'type' => 'bigInteger', 'name' => $column, 'autoIncrement' => false, 'unsigned' => true, - ]); + ])); + } - return $column; + /** + * Create a foreign ID column for the given model. + * + * @param \Illuminate\Database\Eloquent\Model|string $model + * @param string|null $column + * @return \Illuminate\Database\Schema\ForeignIdColumnDefinition + */ + public function foreignIdFor($model, $column = null) + { + if (is_string($model)) { + $model = new $model; + } + + return $model->getKeyType() === 'int' && $model->getIncrementing() + ? $this->foreignId($column ?: $model->getForeignKey()) + : $this->foreignUuid($column ?: $model->getForeignKey()); } /** @@ -1158,10 +1205,10 @@ class Blueprint */ public function foreignUuid($column) { - return $this->columns[] = new ForeignIdColumnDefinition($this, [ + return $this->addColumnDefinition(new ForeignIdColumnDefinition($this, [ 'type' => 'uuid', 'name' => $column, - ]); + ])); } /** @@ -1307,11 +1354,11 @@ class Blueprint */ public function morphs($name, $indexName = null) { - $this->string("{$name}_type"); - - $this->unsignedBigInteger("{$name}_id"); - - $this->index(["{$name}_type", "{$name}_id"], $indexName); + if (Builder::$defaultMorphKeyType === 'uuid') { + $this->uuidMorphs($name, $indexName); + } else { + $this->numericMorphs($name, $indexName); + } } /** @@ -1322,6 +1369,38 @@ class Blueprint * @return void */ public function nullableMorphs($name, $indexName = null) + { + if (Builder::$defaultMorphKeyType === 'uuid') { + $this->nullableUuidMorphs($name, $indexName); + } else { + $this->nullableNumericMorphs($name, $indexName); + } + } + + /** + * Add the proper columns for a polymorphic table using numeric IDs (incremental). + * + * @param string $name + * @param string|null $indexName + * @return void + */ + public function numericMorphs($name, $indexName = null) + { + $this->string("{$name}_type"); + + $this->unsignedBigInteger("{$name}_id"); + + $this->index(["{$name}_type", "{$name}_id"], $indexName); + } + + /** + * Add nullable columns for a polymorphic table using numeric IDs (incremental). + * + * @param string $name + * @param string|null $indexName + * @return void + */ + public function nullableNumericMorphs($name, $indexName = null) { $this->string("{$name}_type")->nullable(); @@ -1441,11 +1520,44 @@ class Blueprint */ public function addColumn($type, $name, array $parameters = []) { - $this->columns[] = $column = new ColumnDefinition( + return $this->addColumnDefinition(new ColumnDefinition( array_merge(compact('type', 'name'), $parameters) - ); + )); + } - return $column; + /** + * Add a new column definition to the blueprint. + * + * @param \Illuminate\Database\Schema\ColumnDefinition $definition + * @return \Illuminate\Database\Schema\ColumnDefinition + */ + protected function addColumnDefinition($definition) + { + $this->columns[] = $definition; + + if ($this->after) { + $definition->after($this->after); + + $this->after = $definition->name; + } + + return $definition; + } + + /** + * Add the columns from the callback after the given column. + * + * @param string $column + * @param \Closure $callback + * @return void + */ + public function after($column, Closure $callback) + { + $this->after = $column; + + $callback($this); + + $this->after = null; } /** @@ -1542,4 +1654,34 @@ class Blueprint return (bool) $column->change; }); } + + /** + * Determine if the blueprint has auto-increment columns. + * + * @return bool + */ + public function hasAutoIncrementColumn() + { + return ! is_null(collect($this->getAddedColumns())->first(function ($column) { + return $column->autoIncrement === true; + })); + } + + /** + * Get the auto-increment column starting values. + * + * @return array + */ + public function autoIncrementingStartingValues() + { + if (! $this->hasAutoIncrementColumn()) { + return []; + } + + return collect($this->getAddedColumns())->mapWithKeys(function ($column) { + return $column->autoIncrement === true + ? [$column->name => $column->get('startingValue', $column->get('from'))] + : [$column->name => null]; + })->filter()->all(); + } } diff --git a/vendor/laravel/framework/src/Illuminate/Database/Schema/Builder.php b/vendor/laravel/framework/src/Illuminate/Database/Schema/Builder.php index 93571b2c4..c919d1705 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Schema/Builder.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Schema/Builder.php @@ -5,6 +5,7 @@ namespace Illuminate\Database\Schema; use Closure; use Doctrine\DBAL\Types\Type; use Illuminate\Database\Connection; +use InvalidArgumentException; use LogicException; use RuntimeException; @@ -38,6 +39,13 @@ class Builder */ public static $defaultStringLength = 255; + /** + * The default relationship morph key type. + * + * @var string + */ + public static $defaultMorphKeyType = 'int'; + /** * Create a new database Schema manager. * @@ -61,6 +69,59 @@ class Builder static::$defaultStringLength = $length; } + /** + * Set the default morph key type for migrations. + * + * @param string $type + * @return void + * + * @throws \InvalidArgumentException + */ + public static function defaultMorphKeyType(string $type) + { + if (! in_array($type, ['int', 'uuid'])) { + throw new InvalidArgumentException("Morph key type must be 'int' or 'uuid'."); + } + + static::$defaultMorphKeyType = $type; + } + + /** + * Set the default morph key type for migrations to UUIDs. + * + * @return void + */ + public static function morphUsingUuids() + { + return static::defaultMorphKeyType('uuid'); + } + + /** + * Create a database in the schema. + * + * @param string $name + * @return bool + * + * @throws \LogicException + */ + public function createDatabase($name) + { + throw new LogicException('This database driver does not support creating databases.'); + } + + /** + * Drop a database from the schema if the database exists. + * + * @param string $name + * @return bool + * + * @throws \LogicException + */ + public function dropDatabaseIfExists($name) + { + throw new LogicException('This database driver does not support dropping databases.'); + } + /** * Determine if the given table exists. * @@ -193,6 +254,20 @@ class Builder })); } + /** + * Drop columns from a table schema. + * + * @param string $table + * @param string|array $columns + * @return void + */ + public function dropColumns($table, $columns) + { + $this->table($table, function (Blueprint $blueprint) use ($columns) { + $blueprint->dropColumn($columns); + }); + } + /** * Drop all tables from the database. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Schema/ColumnDefinition.php b/vendor/laravel/framework/src/Illuminate/Database/Schema/ColumnDefinition.php index c13e69ea9..e2fd9cc78 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Schema/ColumnDefinition.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Schema/ColumnDefinition.php @@ -2,7 +2,6 @@ namespace Illuminate\Database\Schema; -use Illuminate\Database\Query\Expression; use Illuminate\Support\Fluent; /** @@ -12,7 +11,7 @@ use Illuminate\Support\Fluent; * @method $this change() Change the column * @method $this charset(string $charset) Specify a character set for the column (MySQL) * @method $this collation(string $collation) Specify a collation for the column (MySQL/PostgreSQL/SQL Server) - * @method $this comment(string $comment) Add a comment to the column (MySQL) + * @method $this comment(string $comment) Add a comment to the column (MySQL/PostgreSQL) * @method $this default(mixed $value) Specify a "default" value for the column * @method $this first() Place the column "first" in the table (MySQL) * @method $this generatedAs(string|Expression $expression = null) Create a SQL compliant identity column (PostgreSQL) @@ -21,12 +20,14 @@ use Illuminate\Support\Fluent; * @method $this persisted() Mark the computed generated column as persistent (SQL Server) * @method $this primary() Add a primary index * @method $this spatialIndex() Add a spatial index - * @method $this storedAs(string $expression) Create a stored generated column (MySQL) + * @method $this startingValue(int $startingValue) Set the starting value of an auto-incrementing field (MySQL/PostgreSQL) + * @method $this storedAs(string $expression) Create a stored generated column (MySQL/PostgreSQL/SQLite) * @method $this type(string $type) Specify a type for the column * @method $this unique(string $indexName = null) Add a unique index * @method $this unsigned() Set the INTEGER column as UNSIGNED (MySQL) * @method $this useCurrent() Set the TIMESTAMP column to use CURRENT_TIMESTAMP as default value - * @method $this virtualAs(string $expression) Create a virtual generated column (MySQL) + * @method $this useCurrentOnUpdate() Set the TIMESTAMP column to use CURRENT_TIMESTAMP when updating (MySQL) + * @method $this virtualAs(string $expression) Create a virtual generated column (MySQL/PostgreSQL/SQLite) */ class ColumnDefinition extends Fluent { diff --git a/vendor/laravel/framework/src/Illuminate/Database/Schema/ForeignKeyDefinition.php b/vendor/laravel/framework/src/Illuminate/Database/Schema/ForeignKeyDefinition.php index 6fe970608..0354cc924 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Schema/ForeignKeyDefinition.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Schema/ForeignKeyDefinition.php @@ -34,6 +34,16 @@ class ForeignKeyDefinition extends Fluent return $this->onDelete('cascade'); } + /** + * Indicate that deletes should be restricted. + * + * @return $this + */ + public function restrictOnDelete() + { + return $this->onDelete('restrict'); + } + /** * Indicate that deletes should set the foreign key value to null. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Schema/Grammars/Grammar.php b/vendor/laravel/framework/src/Illuminate/Database/Schema/Grammars/Grammar.php index b60dfe817..2acaa76a8 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Schema/Grammars/Grammar.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Schema/Grammars/Grammar.php @@ -9,6 +9,7 @@ use Illuminate\Database\Grammar as BaseGrammar; use Illuminate\Database\Query\Expression; use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Fluent; +use LogicException; use RuntimeException; abstract class Grammar extends BaseGrammar @@ -27,6 +28,33 @@ abstract class Grammar extends BaseGrammar */ protected $fluentCommands = []; + /** + * Compile a create database command. + * + * @param string $name + * @param \Illuminate\Database\Connection $connection + * @return void + * + * @throws \LogicException + */ + public function compileCreateDatabase($name, $connection) + { + throw new LogicException('This database driver does not support creating databases.'); + } + + /** + * Compile a drop database if exists command. + * + * @param string $name + * @return void + * + * @throws \LogicException + */ + public function compileDropDatabaseIfExists($name) + { + throw new LogicException('This database driver does not support dropping databases.'); + } + /** * Compile a rename column command. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Schema/Grammars/MySqlGrammar.php b/vendor/laravel/framework/src/Illuminate/Database/Schema/Grammars/MySqlGrammar.php index 30afde966..b6e4e3568 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Schema/Grammars/MySqlGrammar.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Schema/Grammars/MySqlGrammar.php @@ -12,7 +12,7 @@ class MySqlGrammar extends Grammar /** * The possible column modifiers. * - * @var array + * @var string[] */ protected $modifiers = [ 'Unsigned', 'Charset', 'Collate', 'VirtualAs', 'StoredAs', 'Nullable', @@ -22,10 +22,41 @@ class MySqlGrammar extends Grammar /** * The possible column serials. * - * @var array + * @var string[] */ protected $serials = ['bigInteger', 'integer', 'mediumInteger', 'smallInteger', 'tinyInteger']; + /** + * Compile a create database command. + * + * @param string $name + * @param \Illuminate\Database\Connection $connection + * @return string + */ + public function compileCreateDatabase($name, $connection) + { + return sprintf( + 'create database %s default character set %s default collate %s', + $this->wrapValue($name), + $this->wrapValue($connection->getConfig('charset')), + $this->wrapValue($connection->getConfig('collation')), + ); + } + + /** + * Compile a drop database if exists command. + * + * @param string $name + * @return string + */ + public function compileDropDatabaseIfExists($name) + { + return sprintf( + 'drop database if exists %s', + $this->wrapValue($name) + ); + } + /** * Compile the query to determine the list of tables. * @@ -52,7 +83,7 @@ class MySqlGrammar extends Grammar * @param \Illuminate\Database\Schema\Blueprint $blueprint * @param \Illuminate\Support\Fluent $command * @param \Illuminate\Database\Connection $connection - * @return string + * @return array */ public function compileCreate(Blueprint $blueprint, Fluent $command, Connection $connection) { @@ -70,9 +101,9 @@ class MySqlGrammar extends Grammar // Finally, we will append the engine configuration onto this SQL statement as // the final thing we do before returning this finished SQL. Once this gets // added the query will be ready to execute against the real connections. - return $this->compileCreateEngine( + return array_values(array_filter(array_merge([$this->compileCreateEngine( $sql, $connection, $blueprint - ); + )], $this->compileAutoIncrementStartingValues($blueprint)))); } /** @@ -81,15 +112,15 @@ class MySqlGrammar extends Grammar * @param \Illuminate\Database\Schema\Blueprint $blueprint * @param \Illuminate\Support\Fluent $command * @param \Illuminate\Database\Connection $connection - * @return string + * @return array */ protected function compileCreateTable($blueprint, $command, $connection) { - return sprintf('%s table %s (%s)', + return trim(sprintf('%s table %s (%s)', $blueprint->temporary ? 'create temporary' : 'create', $this->wrapTable($blueprint), implode(', ', $this->getColumns($blueprint)) - ); + )); } /** @@ -147,13 +178,29 @@ class MySqlGrammar extends Grammar * * @param \Illuminate\Database\Schema\Blueprint $blueprint * @param \Illuminate\Support\Fluent $command - * @return string + * @return array */ public function compileAdd(Blueprint $blueprint, Fluent $command) { $columns = $this->prefixArray('add', $this->getColumns($blueprint)); - return 'alter table '.$this->wrapTable($blueprint).' '.implode(', ', $columns); + return array_values(array_merge( + ['alter table '.$this->wrapTable($blueprint).' '.implode(', ', $columns)], + $this->compileAutoIncrementStartingValues($blueprint) + )); + } + + /** + * Compile the auto-incrementing column starting values. + * + * @param \Illuminate\Database\Schema\Blueprint $blueprint + * @return array + */ + public function compileAutoIncrementStartingValues(Blueprint $blueprint) + { + return collect($blueprint->autoIncrementingStartingValues())->map(function ($value, $column) use ($blueprint) { + return 'alter table '.$this->wrapTable($blueprint->getTable()).' auto_increment = '.$value; + })->all(); } /** @@ -443,6 +490,17 @@ class MySqlGrammar extends Grammar return "varchar({$column->length})"; } + /** + * Create the column definition for a tiny text type. + * + * @param \Illuminate\Support\Fluent $column + * @return string + */ + protected function typeTinyText(Fluent $column) + { + return 'tinytext'; + } + /** * Create the column definition for a text type. * @@ -644,7 +702,11 @@ class MySqlGrammar extends Grammar { $columnType = $column->precision ? "datetime($column->precision)" : 'datetime'; - return $column->useCurrent ? "$columnType default CURRENT_TIMESTAMP" : $columnType; + $current = $column->precision ? "CURRENT_TIMESTAMP($column->precision)" : 'CURRENT_TIMESTAMP'; + + $columnType = $column->useCurrent ? "$columnType default $current" : $columnType; + + return $column->useCurrentOnUpdate ? "$columnType on update $current" : $columnType; } /** @@ -690,9 +752,11 @@ class MySqlGrammar extends Grammar { $columnType = $column->precision ? "timestamp($column->precision)" : 'timestamp'; - $defaultCurrent = $column->precision ? "CURRENT_TIMESTAMP($column->precision)" : 'CURRENT_TIMESTAMP'; + $current = $column->precision ? "CURRENT_TIMESTAMP($column->precision)" : 'CURRENT_TIMESTAMP'; - return $column->useCurrent ? "$columnType default $defaultCurrent" : $columnType; + $columnType = $column->useCurrent ? "$columnType default $current" : $columnType; + + return $column->useCurrentOnUpdate ? "$columnType on update $current" : $columnType; } /** diff --git a/vendor/laravel/framework/src/Illuminate/Database/Schema/Grammars/PostgresGrammar.php b/vendor/laravel/framework/src/Illuminate/Database/Schema/Grammars/PostgresGrammar.php index 0c1dd2e59..133da288f 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Schema/Grammars/PostgresGrammar.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Schema/Grammars/PostgresGrammar.php @@ -17,24 +17,54 @@ class PostgresGrammar extends Grammar /** * The possible column modifiers. * - * @var array + * @var string[] */ protected $modifiers = ['Collate', 'Increment', 'Nullable', 'Default', 'VirtualAs', 'StoredAs']; /** * The columns available as serials. * - * @var array + * @var string[] */ protected $serials = ['bigInteger', 'integer', 'mediumInteger', 'smallInteger', 'tinyInteger']; /** * The commands to be executed outside of create or alter command. * - * @var array + * @var string[] */ protected $fluentCommands = ['Comment']; + /** + * Compile a create database command. + * + * @param string $name + * @param \Illuminate\Database\Connection $connection + * @return string + */ + public function compileCreateDatabase($name, $connection) + { + return sprintf( + 'create database %s encoding %s', + $this->wrapValue($name), + $this->wrapValue($connection->getConfig('charset')), + ); + } + + /** + * Compile a drop database if exists command. + * + * @param string $name + * @return string + */ + public function compileDropDatabaseIfExists($name) + { + return sprintf( + 'drop database if exists %s', + $this->wrapValue($name) + ); + } + /** * Compile the query to determine if a table exists. * @@ -60,15 +90,15 @@ class PostgresGrammar extends Grammar * * @param \Illuminate\Database\Schema\Blueprint $blueprint * @param \Illuminate\Support\Fluent $command - * @return string + * @return array */ public function compileCreate(Blueprint $blueprint, Fluent $command) { - return sprintf('%s table %s (%s)', + return array_values(array_filter(array_merge([sprintf('%s table %s (%s)', $blueprint->temporary ? 'create temporary' : 'create', $this->wrapTable($blueprint), implode(', ', $this->getColumns($blueprint)) - ); + )], $this->compileAutoIncrementStartingValues($blueprint)))); } /** @@ -80,10 +110,23 @@ class PostgresGrammar extends Grammar */ public function compileAdd(Blueprint $blueprint, Fluent $command) { - return sprintf('alter table %s %s', + return array_values(array_filter(array_merge([sprintf('alter table %s %s', $this->wrapTable($blueprint), implode(', ', $this->prefixArray('add column', $this->getColumns($blueprint))) - ); + )], $this->compileAutoIncrementStartingValues($blueprint)))); + } + + /** + * Compile the auto-incrementing column starting values. + * + * @param \Illuminate\Database\Schema\Blueprint $blueprint + * @return array + */ + public function compileAutoIncrementStartingValues(Blueprint $blueprint) + { + return collect($blueprint->autoIncrementingStartingValues())->map(function ($value, $column) use ($blueprint) { + return 'alter sequence '.$blueprint->getTable().'_'.$column.'_seq restart with '.$value; + })->all(); } /** @@ -429,6 +472,17 @@ class PostgresGrammar extends Grammar return "varchar({$column->length})"; } + /** + * Create the column definition for a tiny text type. + * + * @param \Illuminate\Support\Fluent $column + * @return string + */ + protected function typeTinyText(Fluent $column) + { + return 'varchar(255)'; + } + /** * Create the column definition for a text type. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Schema/Grammars/SQLiteGrammar.php b/vendor/laravel/framework/src/Illuminate/Database/Schema/Grammars/SQLiteGrammar.php index edb075485..b7e406f57 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Schema/Grammars/SQLiteGrammar.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Schema/Grammars/SQLiteGrammar.php @@ -14,14 +14,14 @@ class SQLiteGrammar extends Grammar /** * The possible column modifiers. * - * @var array + * @var string[] */ - protected $modifiers = ['Nullable', 'Default', 'Increment']; + protected $modifiers = ['VirtualAs', 'StoredAs', 'Nullable', 'Default', 'Increment']; /** * The columns available as serials. * - * @var array + * @var string[] */ protected $serials = ['bigInteger', 'integer', 'mediumInteger', 'smallInteger', 'tinyInteger']; @@ -137,7 +137,9 @@ class SQLiteGrammar extends Grammar { $columns = $this->prefixArray('add column', $this->getColumns($blueprint)); - return collect($columns)->map(function ($column) use ($blueprint) { + return collect($columns)->reject(function ($column) { + return preg_match('/as \(.*\) stored/', $column) > 0; + })->map(function ($column) use ($blueprint) { return 'alter table '.$this->wrapTable($blueprint).' '.$column; })->all(); } @@ -430,6 +432,17 @@ class SQLiteGrammar extends Grammar return 'varchar'; } + /** + * Create the column definition for a tiny text type. + * + * @param \Illuminate\Support\Fluent $column + * @return string + */ + protected function typeTinyText(Fluent $column) + { + return 'text'; + } + /** * Create the column definition for a text type. * @@ -822,6 +835,47 @@ class SQLiteGrammar extends Grammar return 'multipolygon'; } + /** + * Create the column definition for a generated, computed column type. + * + * @param \Illuminate\Support\Fluent $column + * @return void + * + * @throws \RuntimeException + */ + protected function typeComputed(Fluent $column) + { + throw new RuntimeException('This database driver requires a type, see the virtualAs / storedAs modifiers.'); + } + + /** + * Get the SQL for a generated virtual column modifier. + * + * @param \Illuminate\Database\Schema\Blueprint $blueprint + * @param \Illuminate\Support\Fluent $column + * @return string|null + */ + protected function modifyVirtualAs(Blueprint $blueprint, Fluent $column) + { + if (! is_null($column->virtualAs)) { + return " as ({$column->virtualAs})"; + } + } + + /** + * Get the SQL for a generated stored column modifier. + * + * @param \Illuminate\Database\Schema\Blueprint $blueprint + * @param \Illuminate\Support\Fluent $column + * @return string|null + */ + protected function modifyStoredAs(Blueprint $blueprint, Fluent $column) + { + if (! is_null($column->storedAs)) { + return " as ({$column->storedAs}) stored"; + } + } + /** * Get the SQL for a nullable column modifier. * @@ -831,7 +885,13 @@ class SQLiteGrammar extends Grammar */ protected function modifyNullable(Blueprint $blueprint, Fluent $column) { - return $column->nullable ? ' null' : ' not null'; + if (is_null($column->virtualAs) && is_null($column->storedAs)) { + return $column->nullable ? '' : ' not null'; + } + + if ($column->nullable === false) { + return ' not null'; + } } /** @@ -843,7 +903,7 @@ class SQLiteGrammar extends Grammar */ protected function modifyDefault(Blueprint $blueprint, Fluent $column) { - if (! is_null($column->default)) { + if (! is_null($column->default) && is_null($column->virtualAs) && is_null($column->storedAs)) { return ' default '.$this->getDefaultValue($column->default); } } diff --git a/vendor/laravel/framework/src/Illuminate/Database/Schema/Grammars/SqlServerGrammar.php b/vendor/laravel/framework/src/Illuminate/Database/Schema/Grammars/SqlServerGrammar.php index 43d3b7d05..caec02040 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Schema/Grammars/SqlServerGrammar.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Schema/Grammars/SqlServerGrammar.php @@ -17,17 +17,46 @@ class SqlServerGrammar extends Grammar /** * The possible column modifiers. * - * @var array + * @var string[] */ protected $modifiers = ['Increment', 'Collate', 'Nullable', 'Default', 'Persisted']; /** * The columns available as serials. * - * @var array + * @var string[] */ protected $serials = ['tinyInteger', 'smallInteger', 'mediumInteger', 'integer', 'bigInteger']; + /** + * Compile a create database command. + * + * @param string $name + * @param \Illuminate\Database\Connection $connection + * @return string + */ + public function compileCreateDatabase($name, $connection) + { + return sprintf( + 'create database %s', + $this->wrapValue($name), + ); + } + + /** + * Compile a drop database if exists command. + * + * @param string $name + * @return string + */ + public function compileDropDatabaseIfExists($name) + { + return sprintf( + 'drop database if exists %s', + $this->wrapValue($name) + ); + } + /** * Compile the query to determine if a table exists. * @@ -35,7 +64,7 @@ class SqlServerGrammar extends Grammar */ public function compileTableExists() { - return "select * from sysobjects where type = 'U' and name = ?"; + return "select * from sys.sysobjects where id = object_id(?) and xtype in ('U', 'V')"; } /** @@ -46,9 +75,7 @@ class SqlServerGrammar extends Grammar */ public function compileColumnListing($table) { - return "select col.name from sys.columns as col - join sys.objects as obj on col.object_id = obj.object_id - where obj.type = 'U' and obj.object_id = object_id('$table')"; + return "select name from sys.columns where object_id = object_id('$table')"; } /** @@ -165,7 +192,7 @@ class SqlServerGrammar extends Grammar */ public function compileDropIfExists(Blueprint $blueprint, Fluent $command) { - return sprintf('if exists (select * from INFORMATION_SCHEMA.TABLES where TABLE_NAME = %s) drop table %s', + return sprintf('if exists (select * from sys.sysobjects where id = object_id(%s, \'U\')) drop table %s', "'".str_replace("'", "''", $this->getTablePrefix().$blueprint->getTable())."'", $this->wrapTable($blueprint) ); @@ -388,6 +415,17 @@ class SqlServerGrammar extends Grammar return "nvarchar({$column->length})"; } + /** + * Create the column definition for a tiny text type. + * + * @param \Illuminate\Support\Fluent $column + * @return string + */ + protected function typeTinyText(Fluent $column) + { + return 'nvarchar(255)'; + } + /** * Create the column definition for a text type. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Schema/MySqlBuilder.php b/vendor/laravel/framework/src/Illuminate/Database/Schema/MySqlBuilder.php index f07946c85..699b41d5f 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Schema/MySqlBuilder.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Schema/MySqlBuilder.php @@ -4,6 +4,32 @@ namespace Illuminate\Database\Schema; class MySqlBuilder extends Builder { + /** + * Create a database in the schema. + * + * @param string $name + * @return bool + */ + public function createDatabase($name) + { + return $this->connection->statement( + $this->grammar->compileCreateDatabase($name, $this->connection) + ); + } + + /** + * Drop a database from the schema if the database exists. + * + * @param string $name + * @return bool + */ + public function dropDatabaseIfExists($name) + { + return $this->connection->statement( + $this->grammar->compileDropDatabaseIfExists($name) + ); + } + /** * Determine if the given table exists. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Schema/MySqlSchemaState.php b/vendor/laravel/framework/src/Illuminate/Database/Schema/MySqlSchemaState.php new file mode 100644 index 000000000..e772fb686 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Schema/MySqlSchemaState.php @@ -0,0 +1,163 @@ +executeDumpProcess($this->makeProcess( + $this->baseDumpCommand().' --routines --result-file="${:LARAVEL_LOAD_PATH}" --no-data' + ), $this->output, array_merge($this->baseVariables($this->connection->getConfig()), [ + 'LARAVEL_LOAD_PATH' => $path, + ])); + + $this->removeAutoIncrementingState($path); + + $this->appendMigrationData($path); + } + + /** + * Remove the auto-incrementing state from the given schema dump. + * + * @param string $path + * @return void + */ + protected function removeAutoIncrementingState(string $path) + { + $this->files->put($path, preg_replace( + '/\s+AUTO_INCREMENT=[0-9]+/iu', + '', + $this->files->get($path) + )); + } + + /** + * Append the migration data to the schema dump. + * + * @param string $path + * @return void + */ + protected function appendMigrationData(string $path) + { + $process = $this->executeDumpProcess($this->makeProcess( + $this->baseDumpCommand().' '.$this->migrationTable.' --no-create-info --skip-extended-insert --skip-routines --compact' + ), null, array_merge($this->baseVariables($this->connection->getConfig()), [ + // + ])); + + $this->files->append($path, $process->getOutput()); + } + + /** + * Load the given schema file into the database. + * + * @param string $path + * @return void + */ + public function load($path) + { + $command = 'mysql '.$this->connectionString().' --database="${:LARAVEL_LOAD_DATABASE}" < "${:LARAVEL_LOAD_PATH}"'; + + $process = $this->makeProcess($command)->setTimeout(null); + + $process->mustRun(null, array_merge($this->baseVariables($this->connection->getConfig()), [ + 'LARAVEL_LOAD_PATH' => $path, + ])); + } + + /** + * Get the base dump command arguments for MySQL as a string. + * + * @return string + */ + protected function baseDumpCommand() + { + $command = 'mysqldump '.$this->connectionString().' --skip-add-locks --skip-comments --skip-set-charset --tz-utc'; + + if (! $this->connection->isMaria()) { + $command .= ' --column-statistics=0 --set-gtid-purged=OFF'; + } + + return $command.' "${:LARAVEL_LOAD_DATABASE}"'; + } + + /** + * Generate a basic connection string (--socket, --host, --port, --user, --password) for the database. + * + * @return string + */ + protected function connectionString() + { + $value = ' --user="${:LARAVEL_LOAD_USER}" --password="${:LARAVEL_LOAD_PASSWORD}"'; + + $value .= $this->connection->getConfig()['unix_socket'] ?? false + ? ' --socket="${:LARAVEL_LOAD_SOCKET}"' + : ' --host="${:LARAVEL_LOAD_HOST}" --port="${:LARAVEL_LOAD_PORT}"'; + + return $value; + } + + /** + * Get the base variables for a dump / load command. + * + * @param array $config + * @return array + */ + protected function baseVariables(array $config) + { + $config['host'] = $config['host'] ?? ''; + + return [ + 'LARAVEL_LOAD_SOCKET' => $config['unix_socket'] ?? '', + 'LARAVEL_LOAD_HOST' => is_array($config['host']) ? $config['host'][0] : $config['host'], + 'LARAVEL_LOAD_PORT' => $config['port'] ?? '', + 'LARAVEL_LOAD_USER' => $config['username'], + 'LARAVEL_LOAD_PASSWORD' => $config['password'] ?? '', + 'LARAVEL_LOAD_DATABASE' => $config['database'], + ]; + } + + /** + * Execute the given dump process. + * + * @param \Symfony\Component\Process\Process $process + * @param callable $output + * @param array $variables + * @return \Symfony\Component\Process\Process + */ + protected function executeDumpProcess(Process $process, $output, array $variables) + { + try { + $process->setTimeout(null)->mustRun($output, $variables); + } catch (Exception $e) { + if (Str::contains($e->getMessage(), ['column-statistics', 'column_statistics'])) { + return $this->executeDumpProcess(Process::fromShellCommandLine( + str_replace(' --column-statistics=0', '', $process->getCommandLine()) + ), $output, $variables); + } + + if (Str::contains($e->getMessage(), ['set-gtid-purged'])) { + return $this->executeDumpProcess(Process::fromShellCommandLine( + str_replace(' --set-gtid-purged=OFF', '', $process->getCommandLine()) + ), $output, $variables); + } + + throw $e; + } + + return $process; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Schema/PostgresBuilder.php b/vendor/laravel/framework/src/Illuminate/Database/Schema/PostgresBuilder.php index 76673a719..ce1b5770a 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Schema/PostgresBuilder.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Schema/PostgresBuilder.php @@ -4,6 +4,32 @@ namespace Illuminate\Database\Schema; class PostgresBuilder extends Builder { + /** + * Create a database in the schema. + * + * @param string $name + * @return bool + */ + public function createDatabase($name) + { + return $this->connection->statement( + $this->grammar->compileCreateDatabase($name, $this->connection) + ); + } + + /** + * Drop a database from the schema if the database exists. + * + * @param string $name + * @return bool + */ + public function dropDatabaseIfExists($name) + { + return $this->connection->statement( + $this->grammar->compileDropDatabaseIfExists($name) + ); + } + /** * Determine if the given table exists. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Schema/PostgresSchemaState.php b/vendor/laravel/framework/src/Illuminate/Database/Schema/PostgresSchemaState.php new file mode 100644 index 000000000..3e2f5666e --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Schema/PostgresSchemaState.php @@ -0,0 +1,83 @@ +getSchemaBuilder()->getAllTables()) + ->map->tablename + ->reject(function ($table) { + return $table === $this->migrationTable; + })->map(function ($table) { + return '--exclude-table-data="*.'.$table.'"'; + })->implode(' '); + + $this->makeProcess( + $this->baseDumpCommand().' --file="${:LARAVEL_LOAD_PATH}" '.$excludedTables + )->mustRun($this->output, array_merge($this->baseVariables($this->connection->getConfig()), [ + 'LARAVEL_LOAD_PATH' => $path, + ])); + } + + /** + * Load the given schema file into the database. + * + * @param string $path + * @return void + */ + public function load($path) + { + $command = 'pg_restore --no-owner --no-acl --clean --if-exists --host="${:LARAVEL_LOAD_HOST}" --port="${:LARAVEL_LOAD_PORT}" --username="${:LARAVEL_LOAD_USER}" --dbname="${:LARAVEL_LOAD_DATABASE}" "${:LARAVEL_LOAD_PATH}"'; + + if (Str::endsWith($path, '.sql')) { + $command = 'psql --file="${:LARAVEL_LOAD_PATH}" --host="${:LARAVEL_LOAD_HOST}" --port="${:LARAVEL_LOAD_PORT}" --username="${:LARAVEL_LOAD_USER}" --dbname="${:LARAVEL_LOAD_DATABASE}"'; + } + + $process = $this->makeProcess($command); + + $process->mustRun(null, array_merge($this->baseVariables($this->connection->getConfig()), [ + 'LARAVEL_LOAD_PATH' => $path, + ])); + } + + /** + * Get the base dump command arguments for PostgreSQL as a string. + * + * @return string + */ + protected function baseDumpCommand() + { + return 'pg_dump --no-owner --no-acl -Fc --host="${:LARAVEL_LOAD_HOST}" --port="${:LARAVEL_LOAD_PORT}" --username="${:LARAVEL_LOAD_USER}" --dbname="${:LARAVEL_LOAD_DATABASE}"'; + } + + /** + * Get the base variables for a dump / load command. + * + * @param array $config + * @return array + */ + protected function baseVariables(array $config) + { + $config['host'] = $config['host'] ?? ''; + + return [ + 'LARAVEL_LOAD_HOST' => is_array($config['host']) ? $config['host'][0] : $config['host'], + 'LARAVEL_LOAD_PORT' => $config['port'], + 'LARAVEL_LOAD_USER' => $config['username'], + 'PGPASSWORD' => $config['password'], + 'LARAVEL_LOAD_DATABASE' => $config['database'], + ]; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Schema/SQLiteBuilder.php b/vendor/laravel/framework/src/Illuminate/Database/Schema/SQLiteBuilder.php index 78b6b9c78..3bc1275c6 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Schema/SQLiteBuilder.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Schema/SQLiteBuilder.php @@ -2,8 +2,34 @@ namespace Illuminate\Database\Schema; +use Illuminate\Support\Facades\File; + class SQLiteBuilder extends Builder { + /** + * Create a database in the schema. + * + * @param string $name + * @return bool + */ + public function createDatabase($name) + { + return File::put($name, '') !== false; + } + + /** + * Drop a database from the schema if the database exists. + * + * @param string $name + * @return bool + */ + public function dropDatabaseIfExists($name) + { + return File::exists($name) + ? File::delete($name) + : true; + } + /** * Drop all tables from the database. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Schema/SchemaState.php b/vendor/laravel/framework/src/Illuminate/Database/Schema/SchemaState.php new file mode 100644 index 000000000..5629a7aa3 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Schema/SchemaState.php @@ -0,0 +1,122 @@ +connection = $connection; + + $this->files = $files ?: new Filesystem; + + $this->processFactory = $processFactory ?: function (...$arguments) { + return Process::fromShellCommandline(...$arguments); + }; + + $this->handleOutputUsing(function () { + // + }); + } + + /** + * Dump the database's schema into a file. + * + * @param \Illuminate\Database\Connection $connection + * @param string $path + * @return void + */ + abstract public function dump(Connection $connection, $path); + + /** + * Load the given schema file into the database. + * + * @param string $path + * @return void + */ + abstract public function load($path); + + /** + * Create a new process instance. + * + * @param array $arguments + * @return \Symfony\Component\Process\Process + */ + public function makeProcess(...$arguments) + { + return call_user_func($this->processFactory, ...$arguments); + } + + /** + * Specify the name of the application's migration table. + * + * @param string $table + * @return $this + */ + public function withMigrationTable(string $table) + { + $this->migrationTable = $table; + + return $this; + } + + /** + * Specify the callback that should be used to handle process output. + * + * @param callable $output + * @return $this + */ + public function handleOutputUsing(callable $output) + { + $this->output = $output; + + return $this; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Schema/SqlServerBuilder.php b/vendor/laravel/framework/src/Illuminate/Database/Schema/SqlServerBuilder.php index 0b3e47bec..93da1cb86 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/Schema/SqlServerBuilder.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Schema/SqlServerBuilder.php @@ -4,6 +4,32 @@ namespace Illuminate\Database\Schema; class SqlServerBuilder extends Builder { + /** + * Create a database in the schema. + * + * @param string $name + * @return bool + */ + public function createDatabase($name) + { + return $this->connection->statement( + $this->grammar->compileCreateDatabase($name, $this->connection) + ); + } + + /** + * Drop a database from the schema if the database exists. + * + * @param string $name + * @return bool + */ + public function dropDatabaseIfExists($name) + { + return $this->connection->statement( + $this->grammar->compileDropDatabaseIfExists($name) + ); + } + /** * Drop all tables from the database. * diff --git a/vendor/laravel/framework/src/Illuminate/Database/Schema/SqliteSchemaState.php b/vendor/laravel/framework/src/Illuminate/Database/Schema/SqliteSchemaState.php new file mode 100644 index 000000000..42652baa4 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Database/Schema/SqliteSchemaState.php @@ -0,0 +1,93 @@ +makeProcess( + $this->baseCommand().' .schema' + ))->setTimeout(null)->mustRun(null, array_merge($this->baseVariables($this->connection->getConfig()), [ + // + ])); + + $migrations = collect(preg_split("/\r\n|\n|\r/", $process->getOutput()))->filter(function ($line) { + return stripos($line, 'sqlite_sequence') === false && + strlen($line) > 0; + })->all(); + + $this->files->put($path, implode(PHP_EOL, $migrations).PHP_EOL); + + $this->appendMigrationData($path); + } + + /** + * Append the migration data to the schema dump. + * + * @param string $path + * @return void + */ + protected function appendMigrationData(string $path) + { + with($process = $this->makeProcess( + $this->baseCommand().' ".dump \''.$this->migrationTable.'\'"' + ))->mustRun(null, array_merge($this->baseVariables($this->connection->getConfig()), [ + // + ])); + + $migrations = collect(preg_split("/\r\n|\n|\r/", $process->getOutput()))->filter(function ($line) { + return preg_match('/^\s*(--|INSERT\s)/iu', $line) === 1 && + strlen($line) > 0; + })->all(); + + $this->files->append($path, implode(PHP_EOL, $migrations).PHP_EOL); + } + + /** + * Load the given schema file into the database. + * + * @param string $path + * @return void + */ + public function load($path) + { + $process = $this->makeProcess($this->baseCommand().' < "${:LARAVEL_LOAD_PATH}"'); + + $process->mustRun(null, array_merge($this->baseVariables($this->connection->getConfig()), [ + 'LARAVEL_LOAD_PATH' => $path, + ])); + } + + /** + * Get the base sqlite command arguments as a string. + * + * @return string + */ + protected function baseCommand() + { + return 'sqlite3 "${:LARAVEL_LOAD_DATABASE}"'; + } + + /** + * Get the base variables for a dump / load command. + * + * @param array $config + * @return array + */ + protected function baseVariables(array $config) + { + return [ + 'LARAVEL_LOAD_DATABASE' => $config['database'], + ]; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Database/Seeder.php b/vendor/laravel/framework/src/Illuminate/Database/Seeder.php index 2facfd7de..441fa27d6 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/Seeder.php +++ b/vendor/laravel/framework/src/Illuminate/Database/Seeder.php @@ -24,13 +24,14 @@ abstract class Seeder protected $command; /** - * Seed the given connection from the given path. + * Run the given seeder class. * * @param array|string $class * @param bool $silent + * @param array $parameters * @return $this */ - public function call($class, $silent = false) + public function call($class, $silent = false, array $parameters = []) { $classes = Arr::wrap($class); @@ -45,12 +46,12 @@ abstract class Seeder $startTime = microtime(true); - $seeder->__invoke(); + $seeder->__invoke($parameters); - $runTime = round(microtime(true) - $startTime, 2); + $runTime = number_format((microtime(true) - $startTime) * 1000, 2); if ($silent === false && isset($this->command)) { - $this->command->getOutput()->writeln("Seeded: {$name} ({$runTime} seconds)"); + $this->command->getOutput()->writeln("Seeded: {$name} ({$runTime}ms)"); } } @@ -58,14 +59,27 @@ abstract class Seeder } /** - * Silently seed the given connection from the given path. + * Run the given seeder class. * * @param array|string $class + * @param array $parameters * @return void */ - public function callSilent($class) + public function callWith($class, array $parameters = []) { - $this->call($class, true); + $this->call($class, false, $parameters); + } + + /** + * Silently run the given seeder class. + * + * @param array|string $class + * @param array $parameters + * @return void + */ + public function callSilent($class, array $parameters = []) + { + $this->call($class, true, $parameters); } /** @@ -120,18 +134,19 @@ abstract class Seeder /** * Run the database seeds. * + * @param array $parameters * @return mixed * * @throws \InvalidArgumentException */ - public function __invoke() + public function __invoke(array $parameters = []) { if (! method_exists($this, 'run')) { throw new InvalidArgumentException('Method [run] missing from '.get_class($this)); } return isset($this->container) - ? $this->container->call([$this, 'run']) - : $this->run(); + ? $this->container->call([$this, 'run'], $parameters) + : $this->run(...$parameters); } } diff --git a/vendor/laravel/framework/src/Illuminate/Database/SqlServerConnection.php b/vendor/laravel/framework/src/Illuminate/Database/SqlServerConnection.php index c5f0c19cf..87628b99c 100755 --- a/vendor/laravel/framework/src/Illuminate/Database/SqlServerConnection.php +++ b/vendor/laravel/framework/src/Illuminate/Database/SqlServerConnection.php @@ -4,10 +4,14 @@ namespace Illuminate\Database; use Closure; use Doctrine\DBAL\Driver\PDOSqlsrv\Driver as DoctrineDriver; +use Doctrine\DBAL\Version; +use Illuminate\Database\PDO\SqlServerDriver; use Illuminate\Database\Query\Grammars\SqlServerGrammar as QueryGrammar; use Illuminate\Database\Query\Processors\SqlServerProcessor; use Illuminate\Database\Schema\Grammars\SqlServerGrammar as SchemaGrammar; use Illuminate\Database\Schema\SqlServerBuilder; +use Illuminate\Filesystem\Filesystem; +use RuntimeException; use Throwable; class SqlServerConnection extends Connection @@ -39,7 +43,7 @@ class SqlServerConnection extends Connection $this->getPdo()->exec('COMMIT TRAN'); } - // If we catch an exception, we will roll back so nothing gets messed + // If we catch an exception, we will rollback so nothing gets messed // up in the database. Then we'll re-throw the exception so it can // be handled how the developer sees fit for their applications. catch (Throwable $e) { @@ -86,6 +90,19 @@ class SqlServerConnection extends Connection return $this->withTablePrefix(new SchemaGrammar); } + /** + * Get the schema state for the connection. + * + * @param \Illuminate\Filesystem\Filesystem|null $files + * @param callable|null $processFactory + * + * @throws \RuntimeException + */ + public function getSchemaState(Filesystem $files = null, callable $processFactory = null) + { + throw new RuntimeException('Schema dumping is not supported when using SQL Server.'); + } + /** * Get the default post processor instance. * @@ -99,10 +116,10 @@ class SqlServerConnection extends Connection /** * Get the Doctrine DBAL driver. * - * @return \Doctrine\DBAL\Driver\PDOSqlsrv\Driver + * @return \Doctrine\DBAL\Driver\PDOSqlsrv\Driver|\Illuminate\Database\PDO\SqlServerDriver */ protected function getDoctrineDriver() { - return new DoctrineDriver; + return class_exists(Version::class) ? new DoctrineDriver : new SqlServerDriver; } } diff --git a/vendor/laravel/framework/src/Illuminate/Database/composer.json b/vendor/laravel/framework/src/Illuminate/Database/composer.json index 38d7d371a..0a7cda072 100644 --- a/vendor/laravel/framework/src/Illuminate/Database/composer.json +++ b/vendor/laravel/framework/src/Illuminate/Database/composer.json @@ -15,12 +15,14 @@ } ], "require": { - "php": "^7.2.5|^8.0", + "php": "^7.3|^8.0", "ext-json": "*", - "illuminate/container": "^7.0", - "illuminate/contracts": "^7.0", - "illuminate/support": "^7.0", - "symfony/console": "^5.0" + "illuminate/collections": "^8.0", + "illuminate/container": "^8.0", + "illuminate/contracts": "^8.0", + "illuminate/macroable": "^8.0", + "illuminate/support": "^8.0", + "symfony/console": "^5.1.4" }, "autoload": { "psr-4": { @@ -29,17 +31,17 @@ }, "extra": { "branch-alias": { - "dev-master": "7.x-dev" + "dev-master": "8.x-dev" } }, "suggest": { - "doctrine/dbal": "Required to rename columns and drop SQLite columns (^2.6).", + "doctrine/dbal": "Required to rename columns and drop SQLite columns (^2.6|^3.0).", "fakerphp/faker": "Required to use the eloquent factory builder (^1.9.1).", - "illuminate/console": "Required to use the database commands (^7.0).", - "illuminate/events": "Required to use the observers with Eloquent (^7.0).", - "illuminate/filesystem": "Required to use the migrations (^7.0).", - "illuminate/pagination": "Required to paginate the result set (^7.0).", - "symfony/finder": "Required to use Eloquent model factories (^5.0)." + "illuminate/console": "Required to use the database commands (^8.0).", + "illuminate/events": "Required to use the observers with Eloquent (^8.0).", + "illuminate/filesystem": "Required to use the migrations (^8.0).", + "illuminate/pagination": "Required to paginate the result set (^8.0).", + "symfony/finder": "Required to use Eloquent model factories (^5.1.4)." }, "config": { "sort-packages": true diff --git a/vendor/laravel/framework/src/Illuminate/Encryption/Encrypter.php b/vendor/laravel/framework/src/Illuminate/Encryption/Encrypter.php index 6c5d4826c..c0e5e50b8 100755 --- a/vendor/laravel/framework/src/Illuminate/Encryption/Encrypter.php +++ b/vendor/laravel/framework/src/Illuminate/Encryption/Encrypter.php @@ -5,9 +5,10 @@ namespace Illuminate\Encryption; use Illuminate\Contracts\Encryption\DecryptException; use Illuminate\Contracts\Encryption\Encrypter as EncrypterContract; use Illuminate\Contracts\Encryption\EncryptException; +use Illuminate\Contracts\Encryption\StringEncrypter; use RuntimeException; -class Encrypter implements EncrypterContract +class Encrypter implements EncrypterContract, StringEncrypter { /** * The encryption key. @@ -222,24 +223,8 @@ class Encrypter implements EncrypterContract */ protected function validMac(array $payload) { - $calculated = $this->calculateMac($payload, $bytes = random_bytes(16)); - return hash_equals( - hash_hmac('sha256', $payload['mac'], $bytes, true), $calculated - ); - } - - /** - * Calculate the hash of the given payload. - * - * @param array $payload - * @param string $bytes - * @return string - */ - protected function calculateMac($payload, $bytes) - { - return hash_hmac( - 'sha256', $this->hash($payload['iv'], $payload['value']), $bytes, true + $this->hash($payload['iv'], $payload['value']), $payload['mac'] ); } diff --git a/vendor/laravel/framework/src/Illuminate/Encryption/EncryptionServiceProvider.php b/vendor/laravel/framework/src/Illuminate/Encryption/EncryptionServiceProvider.php index cd590f12d..ba19cc102 100755 --- a/vendor/laravel/framework/src/Illuminate/Encryption/EncryptionServiceProvider.php +++ b/vendor/laravel/framework/src/Illuminate/Encryption/EncryptionServiceProvider.php @@ -5,7 +5,6 @@ namespace Illuminate\Encryption; use Illuminate\Support\ServiceProvider; use Illuminate\Support\Str; use Opis\Closure\SerializableClosure; -use RuntimeException; class EncryptionServiceProvider extends ServiceProvider { @@ -71,15 +70,13 @@ class EncryptionServiceProvider extends ServiceProvider * @param array $config * @return string * - * @throws \RuntimeException + * @throws \Illuminate\Encryption\MissingAppKeyException */ protected function key(array $config) { return tap($config['key'], function ($key) { if (empty($key)) { - throw new RuntimeException( - 'No application encryption key has been specified.' - ); + throw new MissingAppKeyException; } }); } diff --git a/vendor/laravel/framework/src/Illuminate/Encryption/MissingAppKeyException.php b/vendor/laravel/framework/src/Illuminate/Encryption/MissingAppKeyException.php new file mode 100644 index 000000000..d8ffcd184 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Encryption/MissingAppKeyException.php @@ -0,0 +1,19 @@ +listen($this->firstClosureParameterType($events), $events); + } elseif ($events instanceof QueuedClosure) { + return $this->listen($this->firstClosureParameterType($events->closure), $events->resolve()); + } elseif ($listener instanceof QueuedClosure) { + $listener = $listener->resolve(); + } + foreach ((array) $events as $event) { if (Str::contains($event, '*')) { $this->setupWildcardListen($event, $listener); @@ -275,7 +286,7 @@ class Dispatcher implements DispatcherContract } /** - * Check if event should be broadcasted by condition. + * Check if the event should be broadcasted by the condition. * * @param mixed $event * @return bool @@ -414,11 +425,19 @@ class Dispatcher implements DispatcherContract ? $listener : $this->parseClassCallable($listener); + if (! method_exists($class, $method)) { + $method = '__invoke'; + } + if ($this->handlerShouldBeQueued($class)) { return $this->createQueuedHandlerCallable($class, $method); } - return [$this->container->make($class), $method]; + $listener = $this->container->make($class); + + return $this->handlerShouldBeDispatchedAfterDatabaseTransactions($listener) + ? $this->createCallbackForListenerRunningAfterCommits($listener, $method) + : [$listener, $method]; } /** @@ -469,6 +488,37 @@ class Dispatcher implements DispatcherContract }; } + /** + * Determine if the given event handler should be dispatched after all database transactions have committed. + * + * @param object|mixed $listener + * @return bool + */ + protected function handlerShouldBeDispatchedAfterDatabaseTransactions($listener) + { + return ($listener->afterCommit ?? null) && $this->container->bound('db.transactions'); + } + + /** + * Create a callable for dispatching a listener after database transactions. + * + * @param mixed $listener + * @param string $method + * @return \Closure + */ + protected function createCallbackForListenerRunningAfterCommits($listener, $method) + { + return function () use ($method, $listener) { + $payload = func_get_args(); + + $this->container->make('db.transactions')->addCallback( + function () use ($listener, $method, $payload) { + $listener->$method(...$payload); + } + ); + }; + } + /** * Determine if the event handler wants to be queued. * @@ -540,11 +590,21 @@ class Dispatcher implements DispatcherContract { return tap($job, function ($job) use ($listener) { $job->tries = $listener->tries ?? null; - $job->retryAfter = method_exists($listener, 'retryAfter') - ? $listener->retryAfter() : ($listener->retryAfter ?? null); + + $job->maxExceptions = $listener->maxExceptions ?? null; + + $job->backoff = method_exists($listener, 'backoff') + ? $listener->backoff() : ($listener->backoff ?? null); + $job->timeout = $listener->timeout ?? null; - $job->timeoutAt = method_exists($listener, 'retryUntil') + + $job->afterCommit = property_exists($listener, 'afterCommit') + ? $listener->afterCommit : null; + + $job->retryUntil = method_exists($listener, 'retryUntil') ? $listener->retryUntil() : null; + + $job->shouldBeEncrypted = $listener instanceof ShouldBeEncrypted; }); } diff --git a/vendor/laravel/framework/src/Illuminate/Events/InvokeQueuedClosure.php b/vendor/laravel/framework/src/Illuminate/Events/InvokeQueuedClosure.php new file mode 100644 index 000000000..caabe4577 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Events/InvokeQueuedClosure.php @@ -0,0 +1,34 @@ +getClosure(), ...$arguments); + } + + /** + * Handle a job failure. + * + * @param \Illuminate\Queue\SerializableClosure $closure + * @param array $arguments + * @param array $catchCallbacks + * @param \Throwable $exception + * @return void + */ + public function failed($closure, array $arguments, array $catchCallbacks, $exception) + { + $arguments[] = $exception; + + collect($catchCallbacks)->each->__invoke(...$arguments); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Events/NullDispatcher.php b/vendor/laravel/framework/src/Illuminate/Events/NullDispatcher.php index 793ef1e19..5c539d53a 100644 --- a/vendor/laravel/framework/src/Illuminate/Events/NullDispatcher.php +++ b/vendor/laravel/framework/src/Illuminate/Events/NullDispatcher.php @@ -12,7 +12,7 @@ class NullDispatcher implements DispatcherContract /** * The underlying event dispatcher instance. * - * @var \Illuminate\Contracts\Bus\Dispatcher + * @var \Illuminate\Contracts\Events\Dispatcher */ protected $dispatcher; @@ -37,6 +37,7 @@ class NullDispatcher implements DispatcherContract */ public function dispatch($event, $payload = [], $halt = false) { + // } /** @@ -48,6 +49,7 @@ class NullDispatcher implements DispatcherContract */ public function push($event, $payload = []) { + // } /** @@ -59,16 +61,17 @@ class NullDispatcher implements DispatcherContract */ public function until($event, $payload = []) { + // } /** * Register an event listener with the dispatcher. * - * @param string|array $events - * @param \Closure|string $listener + * @param \Closure|string|array $events + * @param \Closure|string|array|null $listener * @return void */ - public function listen($events, $listener) + public function listen($events, $listener = null) { $this->dispatcher->listen($events, $listener); } diff --git a/vendor/laravel/framework/src/Illuminate/Events/QueuedClosure.php b/vendor/laravel/framework/src/Illuminate/Events/QueuedClosure.php new file mode 100644 index 000000000..1d640959d --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Events/QueuedClosure.php @@ -0,0 +1,125 @@ +closure = $closure; + } + + /** + * Set the desired connection for the job. + * + * @param string|null $connection + * @return $this + */ + public function onConnection($connection) + { + $this->connection = $connection; + + return $this; + } + + /** + * Set the desired queue for the job. + * + * @param string|null $queue + * @return $this + */ + public function onQueue($queue) + { + $this->queue = $queue; + + return $this; + } + + /** + * Set the desired delay for the job. + * + * @param \DateTimeInterface|\DateInterval|int|null $delay + * @return $this + */ + public function delay($delay) + { + $this->delay = $delay; + + return $this; + } + + /** + * Specify a callback that should be invoked if the queued listener job fails. + * + * @param \Closure $closure + * @return $this + */ + public function catch(Closure $closure) + { + $this->catchCallbacks[] = $closure; + + return $this; + } + + /** + * Resolve the actual event listener callback. + * + * @return \Closure + */ + public function resolve() + { + return function (...$arguments) { + dispatch(new CallQueuedListener(InvokeQueuedClosure::class, 'handle', [ + 'closure' => new SerializableClosure($this->closure), + 'arguments' => $arguments, + 'catch' => collect($this->catchCallbacks)->map(function ($callback) { + return new SerializableClosure($callback); + })->all(), + ]))->onConnection($this->connection)->onQueue($this->queue)->delay($this->delay); + }; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Events/composer.json b/vendor/laravel/framework/src/Illuminate/Events/composer.json index c93a0320c..b77ba2c89 100755 --- a/vendor/laravel/framework/src/Illuminate/Events/composer.json +++ b/vendor/laravel/framework/src/Illuminate/Events/composer.json @@ -14,19 +14,25 @@ } ], "require": { - "php": "^7.2.5|^8.0", - "illuminate/container": "^7.0", - "illuminate/contracts": "^7.0", - "illuminate/support": "^7.0" + "php": "^7.3|^8.0", + "illuminate/bus": "^8.0", + "illuminate/collections": "^8.0", + "illuminate/container": "^8.0", + "illuminate/contracts": "^8.0", + "illuminate/macroable": "^8.0", + "illuminate/support": "^8.0" }, "autoload": { "psr-4": { "Illuminate\\Events\\": "" - } + }, + "files": [ + "functions.php" + ] }, "extra": { "branch-alias": { - "dev-master": "7.x-dev" + "dev-master": "8.x-dev" } }, "config": { diff --git a/vendor/laravel/framework/src/Illuminate/Events/functions.php b/vendor/laravel/framework/src/Illuminate/Events/functions.php new file mode 100644 index 000000000..df1b0febf --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Events/functions.php @@ -0,0 +1,18 @@ +isFile($path)) { - return require $path; + $__path = $path; + $__data = $data; + + return (static function () use ($__path, $__data) { + extract($__data, EXTR_SKIP); + + return require $__path; + })(); } throw new FileNotFoundException("File does not exist at path {$path}."); @@ -103,12 +114,53 @@ class Filesystem /** * Require the given file once. * - * @param string $file + * @param string $path + * @param array $data * @return mixed + * + * @throws \Illuminate\Contracts\Filesystem\FileNotFoundException */ - public function requireOnce($file) + public function requireOnce($path, array $data = []) { - require_once $file; + if ($this->isFile($path)) { + $__path = $path; + $__data = $data; + + return (static function () use ($__path, $__data) { + extract($__data, EXTR_SKIP); + + return require_once $__path; + })(); + } + + throw new FileNotFoundException("File does not exist at path {$path}."); + } + + /** + * Get the contents of a file one line at a time. + * + * @param string $path + * @return \Illuminate\Support\LazyCollection + * + * @throws \Illuminate\Contracts\Filesystem\FileNotFoundException + */ + public function lines($path) + { + if (! $this->isFile($path)) { + throw new FileNotFoundException( + "File does not exist at path {$path}." + ); + } + + return LazyCollection::make(function () use ($path) { + $file = new SplFileObject($path); + + $file->setFlags(SplFileObject::DROP_NEW_LINE); + + while (! $file->eof()) { + yield $file->fgets(); + } + }); } /** @@ -270,6 +322,28 @@ class Filesystem exec("mklink /{$mode} ".escapeshellarg($link).' '.escapeshellarg($target)); } + /** + * Create a relative symlink to the target file or directory. + * + * @param string $target + * @param string $link + * @return void + * + * @throws \RuntimeException + */ + public function relativeLink($target, $link) + { + if (! class_exists(SymfonyFilesystem::class)) { + throw new RuntimeException( + 'To enable support for relative links, please install the symfony/filesystem package.' + ); + } + + $relativeTarget = (new SymfonyFilesystem)->makePathRelative($target, dirname($link)); + + $this->link($relativeTarget, $link); + } + /** * Extract the file name from a file path. * @@ -319,6 +393,8 @@ class Filesystem * * @param string $path * @return string|null + * + * @throws \RuntimeException */ public function guessExtension($path) { diff --git a/vendor/laravel/framework/src/Illuminate/Filesystem/FilesystemAdapter.php b/vendor/laravel/framework/src/Illuminate/Filesystem/FilesystemAdapter.php index fb3ffdc39..1e0f3a7db 100644 --- a/vendor/laravel/framework/src/Illuminate/Filesystem/FilesystemAdapter.php +++ b/vendor/laravel/framework/src/Illuminate/Filesystem/FilesystemAdapter.php @@ -20,8 +20,10 @@ use League\Flysystem\Cached\CachedAdapter; use League\Flysystem\FileExistsException; use League\Flysystem\FileNotFoundException; use League\Flysystem\FilesystemInterface; +use League\Flysystem\Sftp\SftpAdapter as Sftp; use PHPUnit\Framework\Assert as PHPUnit; use Psr\Http\Message\StreamInterface; +use Psr\Http\Message\UriInterface; use RuntimeException; use Symfony\Component\HttpFoundation\StreamedResponse; @@ -52,9 +54,10 @@ class FilesystemAdapter implements CloudFilesystemContract * Assert that the given file exists. * * @param string|array $path + * @param string|null $content * @return $this */ - public function assertExists($path) + public function assertExists($path, $content = null) { $paths = Arr::wrap($path); @@ -62,6 +65,16 @@ class FilesystemAdapter implements CloudFilesystemContract PHPUnit::assertTrue( $this->exists($path), "Unable to find a file at path [{$path}]." ); + + if (! is_null($content)) { + $actual = $this->get($path); + + PHPUnit::assertSame( + $content, + $actual, + "File [{$path}] was found, but content [{$actual}] does not match [{$content}]." + ); + } } return $this; @@ -438,7 +451,7 @@ class FilesystemAdapter implements CloudFilesystemContract return $this->driver->getUrl($path); } elseif ($adapter instanceof AwsS3Adapter) { return $this->getAwsUrl($adapter, $path); - } elseif ($adapter instanceof Ftp) { + } elseif ($adapter instanceof Ftp || $adapter instanceof Sftp) { return $this->getFtpUrl($path); } elseif ($adapter instanceof LocalAdapter) { return $this->getLocalUrl($path); @@ -581,9 +594,18 @@ class FilesystemAdapter implements CloudFilesystemContract 'Key' => $adapter->getPathPrefix().$path, ], $options)); - return (string) $client->createPresignedRequest( + $uri = $client->createPresignedRequest( $command, $expiration )->getUri(); + + // If an explicit base URL has been set on the disk configuration then we will use + // it as the base URL instead of the default path. This allows the developer to + // have full control over the base path for this filesystem's generated URLs. + if (! is_null($url = $this->driver->getConfig()->get('temporary_url'))) { + $uri = $this->replaceBaseUrl($uri, $url); + } + + return (string) $uri; } /** @@ -598,6 +620,23 @@ class FilesystemAdapter implements CloudFilesystemContract return rtrim($url, '/').'/'.ltrim($path, '/'); } + /** + * Replace the scheme, host and port of the given UriInterface with values from the given URL. + * + * @param \Psr\Http\Message\UriInterface $uri + * @param string $url + * @return \Psr\Http\Message\UriInterface + */ + protected function replaceBaseUrl($uri, $url) + { + $parsed = parse_url($url); + + return $uri + ->withScheme($parsed['scheme']) + ->withHost($parsed['host']) + ->withPort($parsed['port'] ?? null); + } + /** * Get an array of all files in a directory. * diff --git a/vendor/laravel/framework/src/Illuminate/Filesystem/FilesystemManager.php b/vendor/laravel/framework/src/Illuminate/Filesystem/FilesystemManager.php index 6003ac6b9..14924de3c 100644 --- a/vendor/laravel/framework/src/Illuminate/Filesystem/FilesystemManager.php +++ b/vendor/laravel/framework/src/Illuminate/Filesystem/FilesystemManager.php @@ -125,11 +125,11 @@ class FilesystemManager implements FactoryContract $driverMethod = 'create'.ucfirst($name).'Driver'; - if (method_exists($this, $driverMethod)) { - return $this->{$driverMethod}($config); - } else { + if (! method_exists($this, $driverMethod)) { throw new InvalidArgumentException("Driver [{$name}] is not supported."); } + + return $this->{$driverMethod}($config); } /** @@ -243,7 +243,7 @@ class FilesystemManager implements FactoryContract { $cache = Arr::pull($config, 'cache'); - $config = Arr::only($config, ['visibility', 'disable_asserts', 'url']); + $config = Arr::only($config, ['visibility', 'disable_asserts', 'url', 'temporary_url']); if ($cache) { $adapter = new CachedAdapter($adapter, $this->createCacheStore($cache)); @@ -326,7 +326,7 @@ class FilesystemManager implements FactoryContract */ public function getDefaultCloudDriver() { - return $this->app['config']['filesystems.cloud']; + return $this->app['config']['filesystems.cloud'] ?? 's3'; } /** @@ -344,6 +344,19 @@ class FilesystemManager implements FactoryContract return $this; } + /** + * Disconnect the given disk and remove from local cache. + * + * @param string|null $name + * @return void + */ + public function purge($name = null) + { + $name = $name ?? $this->getDefaultDriver(); + + unset($this->disks[$name]); + } + /** * Register a custom driver creator Closure. * diff --git a/vendor/laravel/framework/src/Illuminate/Filesystem/LockableFile.php b/vendor/laravel/framework/src/Illuminate/Filesystem/LockableFile.php new file mode 100644 index 000000000..58bd934f3 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Filesystem/LockableFile.php @@ -0,0 +1,194 @@ +path = $path; + + $this->ensureDirectoryExists($path); + $this->createResource($path, $mode); + } + + /** + * Create the file's directory if necessary. + * + * @param string $path + * @return void + */ + protected function ensureDirectoryExists($path) + { + if (! file_exists(dirname($path))) { + @mkdir(dirname($path), 0777, true); + } + } + + /** + * Create the file resource. + * + * @param string $path + * @param string $mode + * @return void + * + * @throws \Exception + */ + protected function createResource($path, $mode) + { + $this->handle = @fopen($path, $mode); + + if (! $this->handle) { + throw new Exception('Unable to create lockable file: '.$path.'. Please ensure you have permission to create files in this location.'); + } + } + + /** + * Read the file contents. + * + * @param int|null $length + * @return string + */ + public function read($length = null) + { + clearstatcache(true, $this->path); + + return fread($this->handle, $length ?? ($this->size() ?: 1)); + } + + /** + * Get the file size. + * + * @return int + */ + public function size() + { + return filesize($this->path); + } + + /** + * Write to the file. + * + * @param string $contents + * @return string + */ + public function write($contents) + { + fwrite($this->handle, $contents); + + fflush($this->handle); + + return $this; + } + + /** + * Truncate the file. + * + * @return $this + */ + public function truncate() + { + rewind($this->handle); + + ftruncate($this->handle, 0); + + return $this; + } + + /** + * Get a shared lock on the file. + * + * @param bool $block + * @return $this + * + * @throws \Illuminate\Contracts\Filesystem\LockTimeoutException + */ + public function getSharedLock($block = false) + { + if (! flock($this->handle, LOCK_SH | ($block ? 0 : LOCK_NB))) { + throw new LockTimeoutException("Unable to acquire file lock at path [{$this->path}]."); + } + + $this->isLocked = true; + + return $this; + } + + /** + * Get an exclusive lock on the file. + * + * @param bool $block + * @return bool + * + * @throws \Illuminate\Contracts\Filesystem\LockTimeoutException + */ + public function getExclusiveLock($block = false) + { + if (! flock($this->handle, LOCK_EX | ($block ? 0 : LOCK_NB))) { + throw new LockTimeoutException("Unable to acquire file lock at path [{$this->path}]."); + } + + $this->isLocked = true; + + return $this; + } + + /** + * Release the lock on the file. + * + * @return $this + */ + public function releaseLock() + { + flock($this->handle, LOCK_UN); + + $this->isLocked = false; + + return $this; + } + + /** + * Close the file. + * + * @return bool + */ + public function close() + { + if ($this->isLocked) { + $this->releaseLock(); + } + + return fclose($this->handle); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Filesystem/composer.json b/vendor/laravel/framework/src/Illuminate/Filesystem/composer.json index f1a48239e..16cb3b6d2 100644 --- a/vendor/laravel/framework/src/Illuminate/Filesystem/composer.json +++ b/vendor/laravel/framework/src/Illuminate/Filesystem/composer.json @@ -14,10 +14,12 @@ } ], "require": { - "php": "^7.2.5|^8.0", - "illuminate/contracts": "^7.0", - "illuminate/support": "^7.0", - "symfony/finder": "^5.0" + "php": "^7.3|^8.0", + "illuminate/collections": "^8.0", + "illuminate/contracts": "^8.0", + "illuminate/macroable": "^8.0", + "illuminate/support": "^8.0", + "symfony/finder": "^5.1.4" }, "autoload": { "psr-4": { @@ -26,7 +28,7 @@ }, "extra": { "branch-alias": { - "dev-master": "7.x-dev" + "dev-master": "8.x-dev" } }, "suggest": { @@ -37,7 +39,8 @@ "league/flysystem-cached-adapter": "Required to use the Flysystem cache (^1.0).", "league/flysystem-sftp": "Required to use the Flysystem SFTP driver (^1.0).", "psr/http-message": "Required to allow Storage::put to accept a StreamInterface (^1.0).", - "symfony/mime": "Required to enable support for guessing extensions (^5.0)." + "symfony/filesystem": "Required to enable support for relative symbolic links (^5.1.4).", + "symfony/mime": "Required to enable support for guessing extensions (^5.1.4)." }, "config": { "sort-packages": true diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/AliasLoader.php b/vendor/laravel/framework/src/Illuminate/Foundation/AliasLoader.php index b8765339f..0f12b6c74 100755 --- a/vendor/laravel/framework/src/Illuminate/Foundation/AliasLoader.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/AliasLoader.php @@ -100,7 +100,7 @@ class AliasLoader */ protected function ensureFacadeExists($alias) { - if (file_exists($path = storage_path('framework/cache/facade-'.sha1($alias).'.php'))) { + if (is_file($path = storage_path('framework/cache/facade-'.sha1($alias).'.php'))) { return $path; } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Application.php b/vendor/laravel/framework/src/Illuminate/Foundation/Application.php index 142bc4b2d..24b7d7b14 100755 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Application.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Application.php @@ -33,7 +33,7 @@ class Application extends Container implements ApplicationContract, CachesConfig * * @var string */ - const VERSION = '7.30.4'; + const VERSION = '8.44.0'; /** * The base path for the Laravel installation. @@ -112,6 +112,13 @@ class Application extends Container implements ApplicationContract, CachesConfig */ protected $databasePath; + /** + * The custom language file path defined by the developer. + * + * @var string + */ + protected $langPath; + /** * The custom storage path defined by the developer. * @@ -150,7 +157,7 @@ class Application extends Container implements ApplicationContract, CachesConfig /** * The prefixes of absolute cache paths for use during normalization. * - * @var array + * @var string[] */ protected $absoluteCachePathPrefixes = ['/', '\\']; @@ -407,7 +414,30 @@ class Application extends Container implements ApplicationContract, CachesConfig */ public function langPath() { - return $this->resourcePath().DIRECTORY_SEPARATOR.'lang'; + if ($this->langPath) { + return $this->langPath; + } + + if (is_dir($path = $this->resourcePath().DIRECTORY_SEPARATOR.'lang')) { + return $path; + } + + return $this->basePath().DIRECTORY_SEPARATOR.'lang'; + } + + /** + * Set the language file directory. + * + * @param string $path + * @return $this + */ + public function useLangPath($path) + { + $this->langPath = $path; + + $this->instance('path.lang', $path); + + return $this; } /** @@ -456,6 +486,21 @@ class Application extends Container implements ApplicationContract, CachesConfig return $this->basePath.DIRECTORY_SEPARATOR.'resources'.($path ? DIRECTORY_SEPARATOR.$path : $path); } + /** + * Get the path to the views directory. + * + * This method returns the first configured path in the array of view paths. + * + * @param string $path + * @return string + */ + public function viewPath($path = '') + { + $basePath = $this['config']->get('view.paths')[0]; + + return rtrim($basePath, DIRECTORY_SEPARATOR).($path ? DIRECTORY_SEPARATOR.$path : $path); + } + /** * Get the path to the environment file directory. * @@ -530,7 +575,7 @@ class Application extends Container implements ApplicationContract, CachesConfig } /** - * Determine if application is in local environment. + * Determine if the application is in the local environment. * * @return bool */ @@ -540,7 +585,7 @@ class Application extends Container implements ApplicationContract, CachesConfig } /** - * Determine if application is in production environment. + * Determine if the application is in the production environment. * * @return bool */ @@ -859,13 +904,17 @@ class Application extends Container implements ApplicationContract, CachesConfig * Boot the given service provider. * * @param \Illuminate\Support\ServiceProvider $provider - * @return mixed + * @return void */ protected function bootProvider(ServiceProvider $provider) { + $provider->callBootingCallbacks(); + if (method_exists($provider, 'boot')) { - return $this->call([$provider, 'boot']); + $this->call([$provider, 'boot']); } + + $provider->callBootedCallbacks(); } /** @@ -953,7 +1002,7 @@ class Application extends Container implements ApplicationContract, CachesConfig */ public function configurationIsCached() { - return file_exists($this->getCachedConfigPath()); + return is_file($this->getCachedConfigPath()); } /** @@ -1177,6 +1226,16 @@ class Application extends Container implements ApplicationContract, CachesConfig return $this['config']->get('app.locale'); } + /** + * Get the current application locale. + * + * @return string + */ + public function currentLocale() + { + return $this->getLocale(); + } + /** * Get the current application fallback locale. * @@ -1216,7 +1275,7 @@ class Application extends Container implements ApplicationContract, CachesConfig } /** - * Determine if application locale is the given locale. + * Determine if the application locale is the given locale. * * @param string $locale * @return bool @@ -1243,9 +1302,9 @@ class Application extends Container implements ApplicationContract, CachesConfig 'cache.psr6' => [\Symfony\Component\Cache\Adapter\Psr16Adapter::class, \Symfony\Component\Cache\Adapter\AdapterInterface::class, \Psr\Cache\CacheItemPoolInterface::class], 'config' => [\Illuminate\Config\Repository::class, \Illuminate\Contracts\Config\Repository::class], 'cookie' => [\Illuminate\Cookie\CookieJar::class, \Illuminate\Contracts\Cookie\Factory::class, \Illuminate\Contracts\Cookie\QueueingFactory::class], - 'encrypter' => [\Illuminate\Encryption\Encrypter::class, \Illuminate\Contracts\Encryption\Encrypter::class], 'db' => [\Illuminate\Database\DatabaseManager::class, \Illuminate\Database\ConnectionResolverInterface::class], 'db.connection' => [\Illuminate\Database\Connection::class, \Illuminate\Database\ConnectionInterface::class], + 'encrypter' => [\Illuminate\Encryption\Encrypter::class, \Illuminate\Contracts\Encryption\Encrypter::class, \Illuminate\Contracts\Encryption\StringEncrypter::class], 'events' => [\Illuminate\Events\Dispatcher::class, \Illuminate\Contracts\Events\Dispatcher::class], 'files' => [\Illuminate\Filesystem\Filesystem::class], 'filesystem' => [\Illuminate\Filesystem\FilesystemManager::class, \Illuminate\Contracts\Filesystem\Factory::class], @@ -1297,8 +1356,11 @@ class Application extends Container implements ApplicationContract, CachesConfig $this->serviceProviders = []; $this->resolvingCallbacks = []; $this->terminatingCallbacks = []; + $this->beforeResolvingCallbacks = []; $this->afterResolvingCallbacks = []; + $this->globalBeforeResolvingCallbacks = []; $this->globalResolvingCallbacks = []; + $this->globalAfterResolvingCallbacks = []; } /** diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Auth/Access/Authorizable.php b/vendor/laravel/framework/src/Illuminate/Foundation/Auth/Access/Authorizable.php index dd0ba609f..d8cf50dbc 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Auth/Access/Authorizable.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Auth/Access/Authorizable.php @@ -18,6 +18,18 @@ trait Authorizable return app(Gate::class)->forUser($this)->check($abilities, $arguments); } + /** + * Determine if the entity has any of the given abilities. + * + * @param iterable|string $abilities + * @param array|mixed $arguments + * @return bool + */ + public function canAny($abilities, $arguments = []) + { + return app(Gate::class)->forUser($this)->any($abilities, $arguments); + } + /** * Determine if the entity does not have the given abilities. * diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Auth/EmailVerificationRequest.php b/vendor/laravel/framework/src/Illuminate/Foundation/Auth/EmailVerificationRequest.php new file mode 100644 index 000000000..c9c43046e --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Auth/EmailVerificationRequest.php @@ -0,0 +1,66 @@ +route('id'), + (string) $this->user()->getKey())) { + return false; + } + + if (! hash_equals((string) $this->route('hash'), + sha1($this->user()->getEmailForVerification()))) { + return false; + } + + return true; + } + + /** + * Get the validation rules that apply to the request. + * + * @return array + */ + public function rules() + { + return [ + // + ]; + } + + /** + * Fulfill the email verification request. + * + * @return void + */ + public function fulfill() + { + if (! $this->user()->hasVerifiedEmail()) { + $this->user()->markEmailAsVerified(); + + event(new Verified($this->user())); + } + } + + /** + * Configure the validator instance. + * + * @param \Illuminate\Validation\Validator $validator + * @return void + */ + public function withValidator($validator) + { + return $validator; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/LoadConfiguration.php b/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/LoadConfiguration.php index 501a1eea4..babbcd3b8 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/LoadConfiguration.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/LoadConfiguration.php @@ -24,7 +24,7 @@ class LoadConfiguration // First we will see if we have a cache configuration file. If we do, we'll load // the configuration items from that file so that it is very quick. Otherwise // we will need to spin through every configuration file and load them all. - if (file_exists($cached = $app->getCachedConfigPath())) { + if (is_file($cached = $app->getCachedConfigPath())) { $items = require $cached; $loadedFromCache = true; diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/LoadEnvironmentVariables.php b/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/LoadEnvironmentVariables.php index 60dd3707f..5549a50a1 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/LoadEnvironmentVariables.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/LoadEnvironmentVariables.php @@ -68,7 +68,7 @@ class LoadEnvironmentVariables */ protected function setEnvironmentFilePath($app, $file) { - if (file_exists($app->environmentPath().'/'.$file)) { + if (is_file($app->environmentPath().'/'.$file)) { $app->loadEnvironmentFrom($file); return true; diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Bus/Dispatchable.php b/vendor/laravel/framework/src/Illuminate/Foundation/Bus/Dispatchable.php index f088497c2..210574809 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Bus/Dispatchable.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Bus/Dispatchable.php @@ -21,6 +21,7 @@ trait Dispatchable * Dispatch the job with the given arguments if the given truth test passes. * * @param bool $boolean + * @param mixed ...$arguments * @return \Illuminate\Foundation\Bus\PendingDispatch|\Illuminate\Support\Fluent */ public static function dispatchIf($boolean, ...$arguments) @@ -34,6 +35,7 @@ trait Dispatchable * Dispatch the job with the given arguments unless the given truth test passes. * * @param bool $boolean + * @param mixed ...$arguments * @return \Illuminate\Foundation\Bus\PendingDispatch|\Illuminate\Support\Fluent */ public static function dispatchUnless($boolean, ...$arguments) @@ -46,8 +48,22 @@ trait Dispatchable /** * Dispatch a command to its appropriate handler in the current process. * + * Queueable jobs will be dispatched to the "sync" queue. + * * @return mixed */ + public static function dispatchSync() + { + return app(Dispatcher::class)->dispatchSync(new static(...func_get_args())); + } + + /** + * Dispatch a command to its appropriate handler in the current process. + * + * @return mixed + * + * @deprecated Will be removed in a future Laravel version. + */ public static function dispatchNow() { return app(Dispatcher::class)->dispatchNow(new static(...func_get_args())); diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Bus/DispatchesJobs.php b/vendor/laravel/framework/src/Illuminate/Foundation/Bus/DispatchesJobs.php index 46d6e5b4d..b1744031d 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Bus/DispatchesJobs.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Bus/DispatchesJobs.php @@ -22,9 +22,24 @@ trait DispatchesJobs * * @param mixed $job * @return mixed + * + * @deprecated Will be removed in a future Laravel version. */ public function dispatchNow($job) { return app(Dispatcher::class)->dispatchNow($job); } + + /** + * Dispatch a command to its appropriate handler in the current process. + * + * Queueable jobs will be dispatched to the "sync" queue. + * + * @param mixed $job + * @return mixed + */ + public function dispatchSync($job) + { + return app(Dispatcher::class)->dispatchSync($job); + } } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Bus/PendingChain.php b/vendor/laravel/framework/src/Illuminate/Foundation/Bus/PendingChain.php index 090e44d4c..5931fb320 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Bus/PendingChain.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Bus/PendingChain.php @@ -3,7 +3,9 @@ namespace Illuminate\Foundation\Bus; use Closure; +use Illuminate\Contracts\Bus\Dispatcher; use Illuminate\Queue\CallQueuedClosure; +use Illuminate\Queue\SerializableClosure; class PendingChain { @@ -21,6 +23,34 @@ class PendingChain */ public $chain; + /** + * The name of the connection the chain should be sent to. + * + * @var string|null + */ + public $connection; + + /** + * The name of the queue the chain should be sent to. + * + * @var string|null + */ + public $queue; + + /** + * The number of seconds before the chain should be made available. + * + * @var \DateTimeInterface|\DateInterval|int|null + */ + public $delay; + + /** + * The callbacks to be executed on failure. + * + * @var array + */ + public $catchCallbacks = []; + /** * Create a new PendingChain instance. * @@ -34,6 +64,70 @@ class PendingChain $this->chain = $chain; } + /** + * Set the desired connection for the job. + * + * @param string|null $connection + * @return $this + */ + public function onConnection($connection) + { + $this->connection = $connection; + + return $this; + } + + /** + * Set the desired queue for the job. + * + * @param string|null $queue + * @return $this + */ + public function onQueue($queue) + { + $this->queue = $queue; + + return $this; + } + + /** + * Set the desired delay for the chain. + * + * @param \DateTimeInterface|\DateInterval|int|null $delay + * @return $this + */ + public function delay($delay) + { + $this->delay = $delay; + + return $this; + } + + /** + * Add a callback to be executed on job failure. + * + * @param callable $callback + * @return $this + */ + public function catch($callback) + { + $this->catchCallbacks[] = $callback instanceof Closure + ? new SerializableClosure($callback) + : $callback; + + return $this; + } + + /** + * Get the "catch" callbacks that have been registered. + * + * @return array + */ + public function catchCallbacks() + { + return $this->catchCallbacks ?? []; + } + /** * Dispatch the job with the given arguments. * @@ -49,6 +143,23 @@ class PendingChain $firstJob = $this->job; } - return (new PendingDispatch($firstJob))->chain($this->chain); + if ($this->connection) { + $firstJob->chainConnection = $this->connection; + $firstJob->connection = $firstJob->connection ?: $this->connection; + } + + if ($this->queue) { + $firstJob->chainQueue = $this->queue; + $firstJob->queue = $firstJob->queue ?: $this->queue; + } + + if ($this->delay) { + $firstJob->delay = ! is_null($firstJob->delay) ? $firstJob->delay : $this->delay; + } + + $firstJob->chain($this->chain); + $firstJob->chainCatchCallbacks = $this->catchCallbacks(); + + return app(Dispatcher::class)->dispatch($firstJob); } } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Bus/PendingClosureDispatch.php b/vendor/laravel/framework/src/Illuminate/Foundation/Bus/PendingClosureDispatch.php new file mode 100644 index 000000000..84cc14a77 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Bus/PendingClosureDispatch.php @@ -0,0 +1,21 @@ +job->onFailure($callback); + + return $this; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Bus/PendingDispatch.php b/vendor/laravel/framework/src/Illuminate/Foundation/Bus/PendingDispatch.php index 89329515e..8ac443231 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Bus/PendingDispatch.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Bus/PendingDispatch.php @@ -2,7 +2,10 @@ namespace Illuminate\Foundation\Bus; +use Illuminate\Container\Container; use Illuminate\Contracts\Bus\Dispatcher; +use Illuminate\Contracts\Cache\Repository as Cache; +use Illuminate\Contracts\Queue\ShouldBeUnique; class PendingDispatch { @@ -96,6 +99,30 @@ class PendingDispatch return $this; } + /** + * Indicate that the job should be dispatched after all database transactions have committed. + * + * @return $this + */ + public function afterCommit() + { + $this->job->afterCommit(); + + return $this; + } + + /** + * Indicate that the job should not wait until database transactions have been committed before dispatching. + * + * @return $this + */ + public function beforeCommit() + { + $this->job->beforeCommit(); + + return $this; + } + /** * Set the jobs that should run if this job is successful. * @@ -121,6 +148,45 @@ class PendingDispatch return $this; } + /** + * Determine if the job should be dispatched. + * + * @return bool + */ + protected function shouldDispatch() + { + if (! $this->job instanceof ShouldBeUnique) { + return true; + } + + $uniqueId = method_exists($this->job, 'uniqueId') + ? $this->job->uniqueId() + : ($this->job->uniqueId ?? ''); + + $cache = method_exists($this->job, 'uniqueVia') + ? $this->job->uniqueVia() + : Container::getInstance()->make(Cache::class); + + return (bool) $cache->lock( + $key = 'laravel_unique_job:'.get_class($this->job).$uniqueId, + $this->job->uniqueFor ?? 0 + )->get(); + } + + /** + * Dynamically proxy methods to the underlying job. + * + * @param string $method + * @param array $parameters + * @return $this + */ + public function __call($method, $parameters) + { + $this->job->{$method}(...$parameters); + + return $this; + } + /** * Handle the object's destruction. * @@ -128,7 +194,9 @@ class PendingDispatch */ public function __destruct() { - if ($this->afterResponse) { + if (! $this->shouldDispatch()) { + return; + } elseif ($this->afterResponse) { app(Dispatcher::class)->dispatchAfterResponse($this->job); } else { app(Dispatcher::class)->dispatch($this->job); diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/ComposerScripts.php b/vendor/laravel/framework/src/Illuminate/Foundation/ComposerScripts.php index fcda187fd..6a5f0df49 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/ComposerScripts.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/ComposerScripts.php @@ -54,11 +54,11 @@ class ComposerScripts { $laravel = new Application(getcwd()); - if (file_exists($servicesPath = $laravel->getCachedServicesPath())) { + if (is_file($servicesPath = $laravel->getCachedServicesPath())) { @unlink($servicesPath); } - if (file_exists($packagesPath = $laravel->getCachedPackagesPath())) { + if (is_file($packagesPath = $laravel->getCachedPackagesPath())) { @unlink($packagesPath); } } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Console/CastMakeCommand.php b/vendor/laravel/framework/src/Illuminate/Foundation/Console/CastMakeCommand.php index fd390de10..3fa3a667f 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Console/CastMakeCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Console/CastMakeCommand.php @@ -34,7 +34,20 @@ class CastMakeCommand extends GeneratorCommand */ protected function getStub() { - return __DIR__.'/stubs/cast.stub'; + return $this->resolveStubPath('/stubs/cast.stub'); + } + + /** + * Resolve the fully-qualified path to the stub. + * + * @param string $stub + * @return string + */ + protected function resolveStubPath($stub) + { + return file_exists($customPath = $this->laravel->basePath(trim($stub, '/'))) + ? $customPath + : __DIR__.$stub; } /** diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Console/ClearCompiledCommand.php b/vendor/laravel/framework/src/Illuminate/Foundation/Console/ClearCompiledCommand.php index 399a44dc5..87ea044b8 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Console/ClearCompiledCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Console/ClearCompiledCommand.php @@ -27,11 +27,11 @@ class ClearCompiledCommand extends Command */ public function handle() { - if (file_exists($servicesPath = $this->laravel->getCachedServicesPath())) { + if (is_file($servicesPath = $this->laravel->getCachedServicesPath())) { @unlink($servicesPath); } - if (file_exists($packagesPath = $this->laravel->getCachedPackagesPath())) { + if (is_file($packagesPath = $this->laravel->getCachedPackagesPath())) { @unlink($packagesPath); } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Console/ClosureCommand.php b/vendor/laravel/framework/src/Illuminate/Foundation/Console/ClosureCommand.php index 88ab48002..4cd54e8e4 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Console/ClosureCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Console/ClosureCommand.php @@ -56,6 +56,17 @@ class ClosureCommand extends Command ); } + /** + * Set the description for the command. + * + * @param string $description + * @return $this + */ + public function purpose($description) + { + return $this->describe($description); + } + /** * Set the description for the command. * diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Console/ComponentMakeCommand.php b/vendor/laravel/framework/src/Illuminate/Foundation/Console/ComponentMakeCommand.php index 8ab3e8eee..b0f649089 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Console/ComponentMakeCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Console/ComponentMakeCommand.php @@ -54,15 +54,21 @@ class ComponentMakeCommand extends GeneratorCommand protected function writeView() { $path = $this->viewPath( - str_replace('.', '/', 'components.'.$this->getView()) + str_replace('.', '/', 'components.'.$this->getView()).'.blade.php' ); if (! $this->files->isDirectory(dirname($path))) { $this->files->makeDirectory(dirname($path), 0777, true, true); } + if ($this->files->exists($path) && ! $this->option('force')) { + $this->error('View already exists!'); + + return; + } + file_put_contents( - $path.'.blade.php', + $path, '
' diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Console/DownCommand.php b/vendor/laravel/framework/src/Illuminate/Foundation/Console/DownCommand.php index af2f6eb95..a11445184 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Console/DownCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Console/DownCommand.php @@ -4,27 +4,29 @@ namespace Illuminate\Foundation\Console; use Exception; use Illuminate\Console\Command; -use Illuminate\Support\InteractsWithTime; +use Illuminate\Foundation\Exceptions\RegisterErrorViewPaths; +use Illuminate\Support\Facades\View; class DownCommand extends Command { - use InteractsWithTime; - /** * The console command signature. * * @var string */ - protected $signature = 'down {--message= : The message for the maintenance mode} + protected $signature = 'down {--redirect= : The path that users should be redirected to} + {--render= : The view that should be prerendered for display during maintenance mode} {--retry= : The number of seconds after which the request may be retried} - {--allow=* : IP or networks allowed to access the application while in maintenance mode}'; + {--refresh= : The number of seconds after which the browser may refresh} + {--secret= : The secret phrase that may be used to bypass maintenance mode} + {--status=503 : The status code that should be used when returning the maintenance mode response}'; /** * The console command description. * * @var string */ - protected $description = 'Put the application into maintenance mode'; + protected $description = 'Put the application into maintenance / demo mode'; /** * Execute the console command. @@ -34,15 +36,21 @@ class DownCommand extends Command public function handle() { try { - if (file_exists(storage_path('framework/down'))) { + if (is_file(storage_path('framework/down'))) { $this->comment('Application is already down.'); - return true; + return 0; } - file_put_contents(storage_path('framework/down'), - json_encode($this->getDownFilePayload(), - JSON_PRETTY_PRINT)); + file_put_contents( + storage_path('framework/down'), + json_encode($this->getDownFilePayload(), JSON_PRETTY_PRINT) + ); + + file_put_contents( + storage_path('framework/maintenance.php'), + file_get_contents(__DIR__.'/stubs/maintenance-mode.stub') + ); $this->comment('Application is now in maintenance mode.'); } catch (Exception $e) { @@ -62,13 +70,43 @@ class DownCommand extends Command protected function getDownFilePayload() { return [ - 'time' => $this->currentTime(), - 'message' => $this->option('message'), + 'redirect' => $this->redirectPath(), 'retry' => $this->getRetryTime(), - 'allowed' => $this->option('allow'), + 'refresh' => $this->option('refresh'), + 'secret' => $this->option('secret'), + 'status' => (int) $this->option('status', 503), + 'template' => $this->option('render') ? $this->prerenderView() : null, ]; } + /** + * Get the path that users should be redirected to. + * + * @return string + */ + protected function redirectPath() + { + if ($this->option('redirect') && $this->option('redirect') !== '/') { + return '/'.trim($this->option('redirect'), '/'); + } + + return $this->option('redirect'); + } + + /** + * Prerender the specified view so that it can be rendered even before loading Composer. + * + * @return string + */ + protected function prerenderView() + { + (new RegisterErrorViewPaths)(); + + return view($this->option('render'), [ + 'retryAfter' => $this->option('retry'), + ])->render(); + } + /** * Get the number of seconds the client should wait before retrying their request. * diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Console/Kernel.php b/vendor/laravel/framework/src/Illuminate/Foundation/Console/Kernel.php index e6b079849..6a8eeb0c8 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Console/Kernel.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Console/Kernel.php @@ -57,7 +57,7 @@ class Kernel implements KernelContract /** * The bootstrap classes for the application. * - * @var array + * @var string[] */ protected $bootstrappers = [ \Illuminate\Foundation\Bootstrap\LoadEnvironmentVariables::class, @@ -111,7 +111,7 @@ class Kernel implements KernelContract */ protected function scheduleCache() { - return Env::get('SCHEDULE_CACHE_DRIVER'); + return $this->app['config']->get('cache.schedule_store', Env::get('SCHEDULE_CACHE_DRIVER')); } /** @@ -223,7 +223,7 @@ class Kernel implements KernelContract $command = $namespace.str_replace( ['/', '.php'], ['\\', ''], - Str::after($command->getPathname(), realpath(app_path()).DIRECTORY_SEPARATOR) + Str::after($command->getRealPath(), realpath(app_path()).DIRECTORY_SEPARATOR) ); if (is_subclass_of($command, Command::class) && diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Console/ModelMakeCommand.php b/vendor/laravel/framework/src/Illuminate/Foundation/Console/ModelMakeCommand.php index 9500e4b04..95209bba0 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Console/ModelMakeCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Console/ModelMakeCommand.php @@ -72,7 +72,7 @@ class ModelMakeCommand extends GeneratorCommand */ protected function createFactory() { - $factory = Str::studly(class_basename($this->argument('name'))); + $factory = Str::studly($this->argument('name')); $this->call('make:factory', [ 'name' => "{$factory}Factory", @@ -108,7 +108,7 @@ class ModelMakeCommand extends GeneratorCommand { $seeder = Str::studly(class_basename($this->argument('name'))); - $this->call('make:seed', [ + $this->call('make:seeder', [ 'name' => "{$seeder}Seeder", ]); } @@ -156,6 +156,17 @@ class ModelMakeCommand extends GeneratorCommand : __DIR__.$stub; } + /** + * Get the default namespace for the class. + * + * @param string $rootNamespace + * @return string + */ + protected function getDefaultNamespace($rootNamespace) + { + return is_dir(app_path('Models')) ? $rootNamespace.'\\Models' : $rootNamespace; + } + /** * Get the console command options. * diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Console/ObserverMakeCommand.php b/vendor/laravel/framework/src/Illuminate/Foundation/Console/ObserverMakeCommand.php index b1f1346a5..a2661f3fa 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Console/ObserverMakeCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Console/ObserverMakeCommand.php @@ -3,7 +3,7 @@ namespace Illuminate\Foundation\Console; use Illuminate\Console\GeneratorCommand; -use Illuminate\Support\Str; +use InvalidArgumentException; use Symfony\Component\Console\Input\InputOption; class ObserverMakeCommand extends GeneratorCommand @@ -44,18 +44,6 @@ class ObserverMakeCommand extends GeneratorCommand return $model ? $this->replaceModel($stub, $model) : $stub; } - /** - * Get the stub file for the generator. - * - * @return string - */ - protected function getStub() - { - return $this->option('model') - ? __DIR__.'/stubs/observer.stub' - : __DIR__.'/stubs/observer.plain.stub'; - } - /** * Replace the model for the given stub. * @@ -65,27 +53,65 @@ class ObserverMakeCommand extends GeneratorCommand */ protected function replaceModel($stub, $model) { - $model = str_replace('/', '\\', $model); + $modelClass = $this->parseModel($model); - $namespaceModel = $this->laravel->getNamespace().$model; + $replace = [ + 'DummyFullModelClass' => $modelClass, + '{{ namespacedModel }}' => $modelClass, + '{{namespacedModel}}' => $modelClass, + 'DummyModelClass' => class_basename($modelClass), + '{{ model }}' => class_basename($modelClass), + '{{model}}' => class_basename($modelClass), + 'DummyModelVariable' => lcfirst(class_basename($modelClass)), + '{{ modelVariable }}' => lcfirst(class_basename($modelClass)), + '{{modelVariable}}' => lcfirst(class_basename($modelClass)), + ]; - if (Str::startsWith($model, '\\')) { - $stub = str_replace('NamespacedDummyModel', trim($model, '\\'), $stub); - } else { - $stub = str_replace('NamespacedDummyModel', $namespaceModel, $stub); + return str_replace( + array_keys($replace), array_values($replace), $stub + ); + } + + /** + * Get the fully-qualified model class name. + * + * @param string $model + * @return string + * + * @throws \InvalidArgumentException + */ + protected function parseModel($model) + { + if (preg_match('([^A-Za-z0-9_/\\\\])', $model)) { + throw new InvalidArgumentException('Model name contains invalid characters.'); } - $stub = str_replace( - "use {$namespaceModel};\nuse {$namespaceModel};", "use {$namespaceModel};", $stub - ); + return $this->qualifyModel($model); + } - $model = class_basename(trim($model, '\\')); + /** + * Get the stub file for the generator. + * + * @return string + */ + protected function getStub() + { + return $this->option('model') + ? $this->resolveStubPath('/stubs/observer.stub') + : $this->resolveStubPath('/stubs/observer.plain.stub'); + } - $stub = str_replace('DocDummyModel', Str::snake($model, ' '), $stub); - - $stub = str_replace('DummyModel', $model, $stub); - - return str_replace('dummyModel', Str::camel($model), $stub); + /** + * Resolve the fully-qualified path to the stub. + * + * @param string $stub + * @return string + */ + protected function resolveStubPath($stub) + { + return file_exists($customPath = $this->laravel->basePath(trim($stub, '/'))) + ? $customPath + : __DIR__.$stub; } /** diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Console/PolicyMakeCommand.php b/vendor/laravel/framework/src/Illuminate/Foundation/Console/PolicyMakeCommand.php index 8b6380ca9..aad094212 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Console/PolicyMakeCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Console/PolicyMakeCommand.php @@ -4,6 +4,7 @@ namespace Illuminate\Foundation\Console; use Illuminate\Console\GeneratorCommand; use Illuminate\Support\Str; +use LogicException; use Symfony\Component\Console\Input\InputOption; class PolicyMakeCommand extends GeneratorCommand @@ -71,6 +72,8 @@ class PolicyMakeCommand extends GeneratorCommand * Get the model for the guard's user provider. * * @return string|null + * + * @throws \LogicException */ protected function userProviderModel() { @@ -78,8 +81,12 @@ class PolicyMakeCommand extends GeneratorCommand $guard = $this->option('guard') ?: $config->get('auth.defaults.guard'); + if (is_null($guardProvider = $config->get('auth.guards.'.$guard.'.provider'))) { + throw new LogicException('The ['.$guard.'] guard is not defined in your "auth" configuration file.'); + } + return $config->get( - 'auth.providers.'.$config->get('auth.guards.'.$guard.'.provider').'.model' + 'auth.providers.'.$guardProvider.'.model' ); } @@ -97,7 +104,7 @@ class PolicyMakeCommand extends GeneratorCommand if (Str::startsWith($model, '\\')) { $namespacedModel = trim($model, '\\'); } else { - $namespacedModel = $this->laravel->getNamespace().$model; + $namespacedModel = $this->qualifyModel($model); } $model = class_basename(trim($model, '\\')); @@ -126,8 +133,13 @@ class PolicyMakeCommand extends GeneratorCommand array_keys($replace), array_values($replace), $stub ); - return str_replace( - "use {$namespacedModel};\nuse {$namespacedModel};", "use {$namespacedModel};", $stub + return preg_replace( + vsprintf('/use %s;[\r\n]+use %s;/', [ + preg_quote($namespacedModel, '/'), + preg_quote($namespacedModel, '/'), + ]), + "use {$namespacedModel};", + $stub ); } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Console/RouteListCommand.php b/vendor/laravel/framework/src/Illuminate/Foundation/Console/RouteListCommand.php index dca0156ab..8a24c5dfb 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Console/RouteListCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Console/RouteListCommand.php @@ -36,14 +36,14 @@ class RouteListCommand extends Command /** * The table headers for the command. * - * @var array + * @var string[] */ protected $headers = ['Domain', 'Method', 'URI', 'Name', 'Action', 'Middleware']; /** * The columns to display when using the "compact" flag. * - * @var array + * @var string[] */ protected $compactColumns = ['method', 'uri', 'action']; @@ -67,6 +67,8 @@ class RouteListCommand extends Command */ public function handle() { + $this->router->flushMiddlewareGroups(); + if (empty($this->router->getRoutes())) { return $this->error("Your application doesn't have any routes."); } @@ -163,7 +165,7 @@ class RouteListCommand extends Command } /** - * Get before filters. + * Get the middleware for the route. * * @param \Illuminate\Routing\Route $route * @return string @@ -189,6 +191,14 @@ class RouteListCommand extends Command return; } + if ($this->option('except-path')) { + foreach (explode(',', $this->option('except-path')) as $path) { + if (Str::contains($route['uri'], $path)) { + return; + } + } + } + return $route; } @@ -256,7 +266,8 @@ class RouteListCommand extends Command ['json', null, InputOption::VALUE_NONE, 'Output the route list as JSON'], ['method', null, InputOption::VALUE_OPTIONAL, 'Filter the routes by method'], ['name', null, InputOption::VALUE_OPTIONAL, 'Filter the routes by name'], - ['path', null, InputOption::VALUE_OPTIONAL, 'Filter the routes by path'], + ['path', null, InputOption::VALUE_OPTIONAL, 'Only show routes matching the given path pattern'], + ['except-path', null, InputOption::VALUE_OPTIONAL, 'Do not display the routes matching the given path pattern'], ['reverse', 'r', InputOption::VALUE_NONE, 'Reverse the ordering of the routes'], ['sort', null, InputOption::VALUE_OPTIONAL, 'The column (domain, method, uri, name, action, middleware) to sort by', 'uri'], ]; diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Console/ServeCommand.php b/vendor/laravel/framework/src/Illuminate/Foundation/Console/ServeCommand.php index b931ea227..16997fd69 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Console/ServeCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Console/ServeCommand.php @@ -4,9 +4,9 @@ namespace Illuminate\Foundation\Console; use Illuminate\Console\Command; use Illuminate\Support\Env; -use Illuminate\Support\ProcessUtils; use Symfony\Component\Console\Input\InputOption; use Symfony\Component\Process\PhpExecutableFinder; +use Symfony\Component\Process\Process; class ServeCommand extends Command { @@ -42,9 +42,41 @@ class ServeCommand extends Command { chdir(public_path()); - $this->line("Laravel development server started: http://{$this->host()}:{$this->port()}"); + $this->line("Starting Laravel development server: http://{$this->host()}:{$this->port()}"); - passthru($this->serverCommand(), $status); + $environmentFile = $this->option('env') + ? base_path('.env').'.'.$this->option('env') + : base_path('.env'); + + $hasEnvironment = file_exists($environmentFile); + + $environmentLastModified = $hasEnvironment + ? filemtime($environmentFile) + : now()->addDays(30)->getTimestamp(); + + $process = $this->startProcess($hasEnvironment); + + while ($process->isRunning()) { + if ($hasEnvironment) { + clearstatcache(false, $environmentFile); + } + + if (! $this->option('no-reload') && + $hasEnvironment && + filemtime($environmentFile) > $environmentLastModified) { + $environmentLastModified = filemtime($environmentFile); + + $this->comment('Environment modified. Restarting server...'); + + $process->stop(5); + + $process = $this->startProcess($hasEnvironment); + } + + usleep(500 * 1000); + } + + $status = $process->getExitCode(); if ($status && $this->canTryAnotherPort()) { $this->portOffset += 1; @@ -55,19 +87,44 @@ class ServeCommand extends Command return $status; } + /** + * Start a new server process. + * + * @param bool $hasEnvironment + * @return \Symfony\Component\Process\Process + */ + protected function startProcess($hasEnvironment) + { + $process = new Process($this->serverCommand(), null, collect($_ENV)->mapWithKeys(function ($value, $key) use ($hasEnvironment) { + if ($this->option('no-reload') || ! $hasEnvironment) { + return [$key => $value]; + } + + return in_array($key, ['APP_ENV', 'LARAVEL_SAIL']) + ? [$key => $value] + : [$key => false]; + })->all()); + + $process->start(function ($type, $buffer) { + $this->output->write($buffer); + }); + + return $process; + } + /** * Get the full server command. * - * @return string + * @return array */ protected function serverCommand() { - return sprintf('%s -S %s:%s %s', - ProcessUtils::escapeArgument((new PhpExecutableFinder)->find(false)), - $this->host(), - $this->port(), - ProcessUtils::escapeArgument(base_path('server.php')) - ); + return [ + (new PhpExecutableFinder)->find(false), + '-S', + $this->host().':'.$this->port(), + base_path('server.php'), + ]; } /** @@ -93,7 +150,7 @@ class ServeCommand extends Command } /** - * Check if command has reached its max amount of port tries. + * Check if the command has reached its max amount of port tries. * * @return bool */ @@ -112,10 +169,9 @@ class ServeCommand extends Command { return [ ['host', null, InputOption::VALUE_OPTIONAL, 'The host address to serve the application on', '127.0.0.1'], - ['port', null, InputOption::VALUE_OPTIONAL, 'The port to serve the application on', Env::get('SERVER_PORT')], - ['tries', null, InputOption::VALUE_OPTIONAL, 'The max number of ports to attempt to serve from', 10], + ['no-reload', null, InputOption::VALUE_NONE, 'Do not reload the development server on .env file changes'], ]; } } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Console/StorageLinkCommand.php b/vendor/laravel/framework/src/Illuminate/Foundation/Console/StorageLinkCommand.php index 81f7a1762..9c0251d84 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Console/StorageLinkCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Console/StorageLinkCommand.php @@ -3,8 +3,6 @@ namespace Illuminate\Foundation\Console; use Illuminate\Console\Command; -use RuntimeException; -use Symfony\Component\Filesystem\Filesystem as SymfonyFilesystem; class StorageLinkCommand extends Command { @@ -13,7 +11,9 @@ class StorageLinkCommand extends Command * * @var string */ - protected $signature = 'storage:link {--relative : Create the symbolic link using relative paths}'; + protected $signature = 'storage:link + {--relative : Create the symbolic link using relative paths} + {--force : Recreate existing symbolic links}'; /** * The console command description. @@ -29,18 +29,25 @@ class StorageLinkCommand extends Command */ public function handle() { + $relative = $this->option('relative'); + foreach ($this->links() as $link => $target) { - if (file_exists($link)) { + if (file_exists($link) && ! $this->removableSymlink($link, $this->option('force'))) { $this->error("The [$link] link already exists."); - } else { - if ($this->option('relative')) { - $target = $this->getRelativeTarget($link, $target); - } - - $this->laravel->make('files')->link($target, $link); - - $this->info("The [$link] link has been connected to [$target]."); + continue; } + + if (is_link($link)) { + $this->laravel->make('files')->delete($link); + } + + if ($relative) { + $this->laravel->make('files')->relativeLink($target, $link); + } else { + $this->laravel->make('files')->link($target, $link); + } + + $this->info("The [$link] link has been connected to [$target]."); } $this->info('The links have been created.'); @@ -58,18 +65,14 @@ class StorageLinkCommand extends Command } /** - * Get the relative path to the target. + * Determine if the provided path is a symlink that can be removed. * * @param string $link - * @param string $target - * @return string + * @param bool $force + * @return bool */ - protected function getRelativeTarget($link, $target) + protected function removableSymlink(string $link, bool $force): bool { - if (! class_exists(SymfonyFilesystem::class)) { - throw new RuntimeException('To enable support for relative links, please install the symfony/filesystem package.'); - } - - return (new SymfonyFilesystem)->makePathRelative($target, dirname($link)); + return is_link($link) && $force; } } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Console/StubPublishCommand.php b/vendor/laravel/framework/src/Illuminate/Foundation/Console/StubPublishCommand.php index 55e86a958..4f3f087d4 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Console/StubPublishCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Console/StubPublishCommand.php @@ -33,10 +33,13 @@ class StubPublishCommand extends Command } $files = [ + __DIR__.'/stubs/cast.stub' => $stubsPath.'/cast.stub', __DIR__.'/stubs/job.queued.stub' => $stubsPath.'/job.queued.stub', __DIR__.'/stubs/job.stub' => $stubsPath.'/job.stub', __DIR__.'/stubs/model.pivot.stub' => $stubsPath.'/model.pivot.stub', __DIR__.'/stubs/model.stub' => $stubsPath.'/model.stub', + __DIR__.'/stubs/observer.stub' => $stubsPath.'/observer.stub', + __DIR__.'/stubs/observer.plain.stub' => $stubsPath.'/observer.plain.stub', __DIR__.'/stubs/request.stub' => $stubsPath.'/request.stub', __DIR__.'/stubs/resource.stub' => $stubsPath.'/resource.stub', __DIR__.'/stubs/resource-collection.stub' => $stubsPath.'/resource-collection.stub', diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Console/TestMakeCommand.php b/vendor/laravel/framework/src/Illuminate/Foundation/Console/TestMakeCommand.php index 0a176cbab..10814a0b0 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Console/TestMakeCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Console/TestMakeCommand.php @@ -4,6 +4,7 @@ namespace Illuminate\Foundation\Console; use Illuminate\Console\GeneratorCommand; use Illuminate\Support\Str; +use Symfony\Component\Console\Input\InputOption; class TestMakeCommand extends GeneratorCommand { @@ -12,7 +13,7 @@ class TestMakeCommand extends GeneratorCommand * * @var string */ - protected $signature = 'make:test {name : The name of the class} {--unit : Create a unit test}'; + protected $name = 'make:test'; /** * The console command description. @@ -90,4 +91,16 @@ class TestMakeCommand extends GeneratorCommand { return 'Tests'; } + + /** + * Get the console command options. + * + * @return array + */ + protected function getOptions() + { + return [ + ['unit', 'u', InputOption::VALUE_NONE, 'Create a unit test.'], + ]; + } } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Console/UpCommand.php b/vendor/laravel/framework/src/Illuminate/Foundation/Console/UpCommand.php index 9f6599208..e81329c25 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Console/UpCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Console/UpCommand.php @@ -29,14 +29,18 @@ class UpCommand extends Command public function handle() { try { - if (! file_exists(storage_path('framework/down'))) { + if (! is_file(storage_path('framework/down'))) { $this->comment('Application is already up.'); - return true; + return 0; } unlink(storage_path('framework/down')); + if (is_file(storage_path('framework/maintenance.php'))) { + unlink(storage_path('framework/maintenance.php')); + } + $this->info('Application is now live.'); } catch (Exception $e) { $this->error('Failed to disable maintenance mode.'); diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Console/VendorPublishCommand.php b/vendor/laravel/framework/src/Illuminate/Foundation/Console/VendorPublishCommand.php index 17a459e72..501142f0d 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Console/VendorPublishCommand.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Console/VendorPublishCommand.php @@ -4,6 +4,7 @@ namespace Illuminate\Foundation\Console; use Illuminate\Console\Command; use Illuminate\Filesystem\Filesystem; +use Illuminate\Foundation\Events\VendorTagPublished; use Illuminate\Support\Arr; use Illuminate\Support\ServiceProvider; use League\Flysystem\Adapter\Local as LocalAdapter; @@ -159,7 +160,9 @@ class VendorPublishCommand extends Command { $published = false; - foreach ($this->pathsToPublish($tag) as $from => $to) { + $pathsToPublish = $this->pathsToPublish($tag); + + foreach ($pathsToPublish as $from => $to) { $this->publishItem($from, $to); $published = true; @@ -167,6 +170,8 @@ class VendorPublishCommand extends Command if ($published === false) { $this->error('Unable to locate publishable resources.'); + } else { + $this->laravel['events']->dispatch(new VendorTagPublished($tag, $pathsToPublish)); } } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Console/stubs/cast.stub b/vendor/laravel/framework/src/Illuminate/Foundation/Console/stubs/cast.stub index 26bfd985e..a496e5acc 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Console/stubs/cast.stub +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Console/stubs/cast.stub @@ -1,10 +1,10 @@ = time()) { + return; + } +} + +// Redirect to the proper path if necessary... +if (isset($data['redirect']) && $_SERVER['REQUEST_URI'] !== $data['redirect']) { + http_response_code(302); + header('Location: '.$data['redirect']); + + exit; +} + +// Output the prerendered template... +http_response_code($data['status'] ?? 503); + +if (isset($data['retry'])) { + header('Retry-After: '.$data['retry']); +} + +echo $data['template']; + +exit; diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Console/stubs/model.stub b/vendor/laravel/framework/src/Illuminate/Foundation/Console/stubs/model.stub index 279313ea1..2956d090e 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Console/stubs/model.stub +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Console/stubs/model.stub @@ -2,9 +2,10 @@ namespace {{ namespace }}; +use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; class {{ class }} extends Model { - // + use HasFactory; } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Console/stubs/observer.plain.stub b/vendor/laravel/framework/src/Illuminate/Foundation/Console/stubs/observer.plain.stub index daae325c7..e2506b709 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Console/stubs/observer.plain.stub +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Console/stubs/observer.plain.stub @@ -1,8 +1,8 @@ get('/'); diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Console/stubs/test.unit.stub b/vendor/laravel/framework/src/Illuminate/Foundation/Console/stubs/test.unit.stub index 98af65293..b6816aa72 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Console/stubs/test.unit.stub +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Console/stubs/test.unit.stub @@ -11,7 +11,7 @@ class {{ class }} extends TestCase * * @return void */ - public function testExample() + public function test_example() { $this->assertTrue(true); } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Console/stubs/view-component.stub b/vendor/laravel/framework/src/Illuminate/Foundation/Console/stubs/view-component.stub index 20cdaa2a8..22eae518c 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Console/stubs/view-component.stub +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Console/stubs/view-component.stub @@ -19,7 +19,7 @@ class DummyClass extends Component /** * Get the view / contents that represent the component. * - * @return \Illuminate\View\View|string + * @return \Illuminate\Contracts\View\View|\Closure|string */ public function render() { diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Events/Dispatchable.php b/vendor/laravel/framework/src/Illuminate/Foundation/Events/Dispatchable.php index c2acd7759..ff633150f 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Events/Dispatchable.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Events/Dispatchable.php @@ -18,6 +18,7 @@ trait Dispatchable * Dispatch the event with the given arguments if the given truth test passes. * * @param bool $boolean + * @param mixed ...$arguments * @return void */ public static function dispatchIf($boolean, ...$arguments) @@ -31,6 +32,7 @@ trait Dispatchable * Dispatch the event with the given arguments unless the given truth test passes. * * @param bool $boolean + * @param mixed ...$arguments * @return void */ public static function dispatchUnless($boolean, ...$arguments) diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Events/VendorTagPublished.php b/vendor/laravel/framework/src/Illuminate/Foundation/Events/VendorTagPublished.php new file mode 100644 index 000000000..084c1293f --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Events/VendorTagPublished.php @@ -0,0 +1,33 @@ +tag = $tag; + $this->paths = $paths; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/Handler.php b/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/Handler.php index 923e6c6d1..46a514c8f 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/Handler.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/Handler.php @@ -2,6 +2,7 @@ namespace Illuminate\Foundation\Exceptions; +use Closure; use Exception; use Illuminate\Auth\Access\AuthorizationException; use Illuminate\Auth\AuthenticationException; @@ -10,6 +11,8 @@ use Illuminate\Contracts\Container\Container; use Illuminate\Contracts\Debug\ExceptionHandler as ExceptionHandlerContract; use Illuminate\Contracts\Support\Responsable; use Illuminate\Database\Eloquent\ModelNotFoundException; +use Illuminate\Database\MultipleRecordsFoundException; +use Illuminate\Database\RecordsNotFoundException; use Illuminate\Http\Exceptions\HttpResponseException; use Illuminate\Http\JsonResponse; use Illuminate\Http\RedirectResponse; @@ -18,10 +21,11 @@ use Illuminate\Routing\Router; use Illuminate\Session\TokenMismatchException; use Illuminate\Support\Arr; use Illuminate\Support\Facades\Auth; -use Illuminate\Support\Facades\View; use Illuminate\Support\Reflector; +use Illuminate\Support\Traits\ReflectsClosures; use Illuminate\Support\ViewErrorBag; use Illuminate\Validation\ValidationException; +use InvalidArgumentException; use Psr\Log\LoggerInterface; use Symfony\Component\Console\Application as ConsoleApplication; use Symfony\Component\ErrorHandler\ErrorRenderer\HtmlErrorRenderer; @@ -38,6 +42,8 @@ use Whoops\Run as Whoops; class Handler implements ExceptionHandlerContract { + use ReflectsClosures; + /** * The container implementation. * @@ -48,14 +54,35 @@ class Handler implements ExceptionHandlerContract /** * A list of the exception types that are not reported. * - * @var array + * @var string[] */ protected $dontReport = []; + /** + * The callbacks that should be used during reporting. + * + * @var \Illuminate\Foundation\Exceptions\ReportableHandler[] + */ + protected $reportCallbacks = []; + + /** + * The callbacks that should be used during rendering. + * + * @var \Closure[] + */ + protected $renderCallbacks = []; + + /** + * The registered exception mappings. + * + * @var array + */ + protected $exceptionMap = []; + /** * A list of the internal exception types that should not be reported. * - * @var array + * @var string[] */ protected $internalDontReport = [ AuthenticationException::class, @@ -63,6 +90,8 @@ class Handler implements ExceptionHandlerContract HttpException::class, HttpResponseException::class, ModelNotFoundException::class, + MultipleRecordsFoundException::class, + RecordsNotFoundException::class, SuspiciousOperationException::class, TokenMismatchException::class, ValidationException::class, @@ -71,9 +100,10 @@ class Handler implements ExceptionHandlerContract /** * A list of the inputs that are never flashed for validation exceptions. * - * @var array + * @var string[] */ protected $dontFlash = [ + 'current_password', 'password', 'password_confirmation', ]; @@ -87,6 +117,95 @@ class Handler implements ExceptionHandlerContract public function __construct(Container $container) { $this->container = $container; + + $this->register(); + } + + /** + * Register the exception handling callbacks for the application. + * + * @return void + */ + public function register() + { + // + } + + /** + * Register a reportable callback. + * + * @param callable $reportUsing + * @return \Illuminate\Foundation\Exceptions\ReportableHandler + */ + public function reportable(callable $reportUsing) + { + if (! $reportUsing instanceof Closure) { + $reportUsing = Closure::fromCallable($reportUsing); + } + + return tap(new ReportableHandler($reportUsing), function ($callback) { + $this->reportCallbacks[] = $callback; + }); + } + + /** + * Register a renderable callback. + * + * @param callable $renderUsing + * @return $this + */ + public function renderable(callable $renderUsing) + { + if (! $renderUsing instanceof Closure) { + $renderUsing = Closure::fromCallable($renderUsing); + } + + $this->renderCallbacks[] = $renderUsing; + + return $this; + } + + /** + * Register a new exception mapping. + * + * @param \Closure|string $from + * @param \Closure|string|null $to + * @return $this + * + * @throws \InvalidArgumentException + */ + public function map($from, $to = null) + { + if (is_string($to)) { + $to = function ($exception) use ($to) { + return new $to('', 0, $exception); + }; + } + + if (is_callable($from) && is_null($to)) { + $from = $this->firstClosureParameterType($to = $from); + } + + if (! is_string($from) || ! $to instanceof Closure) { + throw new InvalidArgumentException('Invalid exception mapping.'); + } + + $this->exceptionMap[$from] = $to; + + return $this; + } + + /** + * Indicate that the given exception type should not be reported. + * + * @param string $class + * @return $this + */ + protected function ignore(string $class) + { + $this->dontReport[] = $class; + + return $this; } /** @@ -99,14 +218,24 @@ class Handler implements ExceptionHandlerContract */ public function report(Throwable $e) { + $e = $this->mapException($e); + if ($this->shouldntReport($e)) { return; } if (Reflector::isCallable($reportCallable = [$e, 'report'])) { - $this->container->call($reportCallable); + if ($this->container->call($reportCallable) !== false) { + return; + } + } - return; + foreach ($this->reportCallbacks as $reportCallback) { + if ($reportCallback->handles($e)) { + if ($reportCallback($e) === false) { + return; + } + } } try { @@ -159,6 +288,10 @@ class Handler implements ExceptionHandlerContract */ protected function exceptionContext(Throwable $e) { + if (method_exists($e, 'context')) { + return $e->context(); + } + return []; } @@ -196,7 +329,17 @@ class Handler implements ExceptionHandlerContract return $e->toResponse($request); } - $e = $this->prepareException($e); + $e = $this->prepareException($this->mapException($e)); + + foreach ($this->renderCallbacks as $renderCallback) { + if (is_a($e, $this->firstClosureParameterType($renderCallback))) { + $response = $renderCallback($e, $request); + + if (! is_null($response)) { + return $response; + } + } + } if ($e instanceof HttpResponseException) { return $e->getResponse(); @@ -211,6 +354,23 @@ class Handler implements ExceptionHandlerContract : $this->prepareResponse($request, $e); } + /** + * Map the exception using a registered mapper if possible. + * + * @param \Throwable $e + * @return \Throwable + */ + protected function mapException(Throwable $e) + { + foreach ($this->exceptionMap as $class => $mapper) { + if (is_a($e, $class)) { + return $mapper($e); + } + } + + return $e; + } + /** * Prepare exception for rendering. * @@ -227,6 +387,8 @@ class Handler implements ExceptionHandlerContract $e = new HttpException(419, $e->getMessage(), $e); } elseif ($e instanceof SuspiciousOperationException) { $e = new NotFoundHttpException('Bad hostname provided.', $e); + } elseif ($e instanceof RecordsNotFoundException) { + $e = new NotFoundHttpException('Not found.', $e); } return $e; @@ -275,7 +437,7 @@ class Handler implements ExceptionHandlerContract { return redirect($exception->redirectTo ?? url()->previous()) ->withInput(Arr::except($request->input(), $this->dontFlash)) - ->withErrors($exception->errors(), $exception->errorBag); + ->withErrors($exception->errors(), $request->input('_error_bag', $exception->errorBag)); } /** @@ -419,11 +581,7 @@ class Handler implements ExceptionHandlerContract */ protected function registerErrorViewPaths() { - $paths = collect(config('view.paths')); - - View::replaceNamespace('errors', $paths->map(function ($path) { - return "{$path}/errors"; - })->push(__DIR__.'/views')->all()); + (new RegisterErrorViewPaths)(); } /** diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/RegisterErrorViewPaths.php b/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/RegisterErrorViewPaths.php new file mode 100644 index 000000000..c88f3261a --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/RegisterErrorViewPaths.php @@ -0,0 +1,20 @@ +map(function ($path) { + return "{$path}/errors"; + })->push(__DIR__.'/views')->all()); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/ReportableHandler.php b/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/ReportableHandler.php new file mode 100644 index 000000000..3664bc6be --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/ReportableHandler.php @@ -0,0 +1,76 @@ +callback = $callback; + } + + /** + * Invoke the handler. + * + * @param \Throwable $e + * @return bool + */ + public function __invoke(Throwable $e) + { + $result = call_user_func($this->callback, $e); + + if ($result === false) { + return false; + } + + return ! $this->shouldStop; + } + + /** + * Determine if the callback handles the given exception. + * + * @param \Throwable $e + * @return bool + */ + public function handles(Throwable $e) + { + return is_a($e, $this->firstClosureParameterType($this->callback)); + } + + /** + * Indicate that report handling should stop after invoking this callback. + * + * @return $this + */ + public function stop() + { + $this->shouldStop = true; + + return $this; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/views/503.blade.php b/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/views/503.blade.php index acd38100a..c5a9dde14 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/views/503.blade.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/views/503.blade.php @@ -2,4 +2,4 @@ @section('title', __('Service Unavailable')) @section('code', '503') -@section('message', __($exception->getMessage() ?: 'Service Unavailable')) +@section('message', __('Service Unavailable')) diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/views/illustrated-layout.blade.php b/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/views/illustrated-layout.blade.php index 64eb7cbb8..2e5b8240b 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/views/illustrated-layout.blade.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/views/illustrated-layout.blade.php @@ -7,8 +7,8 @@ @yield('title') - - + + + + - -
-
- @yield('code') -
+ +
+
+
+
+ @yield('code') +
-
- @yield('message') +
+ @yield('message') +
+
diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Http/Exceptions/MaintenanceModeException.php b/vendor/laravel/framework/src/Illuminate/Foundation/Http/Exceptions/MaintenanceModeException.php index 9fe9ffd68..5553fde62 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Http/Exceptions/MaintenanceModeException.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Http/Exceptions/MaintenanceModeException.php @@ -7,6 +7,9 @@ use Illuminate\Support\Facades\Date; use Symfony\Component\HttpKernel\Exception\ServiceUnavailableHttpException; use Throwable; +/** + * @deprecated Will be removed in a future Laravel version. + */ class MaintenanceModeException extends ServiceUnavailableHttpException { /** diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Http/FormRequest.php b/vendor/laravel/framework/src/Illuminate/Foundation/Http/FormRequest.php index 96169f3ce..8c2da9699 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Http/FormRequest.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Http/FormRequest.php @@ -58,6 +58,13 @@ class FormRequest extends Request implements ValidatesWhenResolved */ protected $errorBag = 'default'; + /** + * Indicates whether validation should stop after the first rule failure. + * + * @var bool + */ + protected $stopOnFirstFailure = false; + /** * The validator instance. * @@ -104,7 +111,7 @@ class FormRequest extends Request implements ValidatesWhenResolved return $factory->make( $this->validationData(), $this->container->call([$this, 'rules']), $this->messages(), $this->attributes() - ); + )->stopOnFirstFailure($this->stopOnFirstFailure); } /** diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php b/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php index 38f2fd6c0..adb11d008 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php @@ -31,7 +31,7 @@ class Kernel implements KernelContract /** * The bootstrap classes for the application. * - * @var array + * @var string[] */ protected $bootstrappers = [ \Illuminate\Foundation\Bootstrap\LoadEnvironmentVariables::class, @@ -68,9 +68,10 @@ class Kernel implements KernelContract * * Forces non-global middleware to always be in the given order. * - * @var array + * @var string[] */ protected $middlewarePriority = [ + \Illuminate\Cookie\Middleware\EncryptCookies::class, \Illuminate\Session\Middleware\StartSession::class, \Illuminate\View\Middleware\ShareErrorsFromSession::class, \Illuminate\Contracts\Auth\Middleware\AuthenticatesRequests::class, @@ -253,7 +254,7 @@ class Kernel implements KernelContract } /** - * Add a new middleware to beginning of the stack if it does not already exist. + * Add a new middleware to the beginning of the stack if it does not already exist. * * @param string $middleware * @return $this @@ -382,6 +383,16 @@ class Kernel implements KernelContract } } + /** + * Get the priority-sorted list of middleware. + * + * @return array + */ + public function getMiddlewarePriority() + { + return $this->middlewarePriority; + } + /** * Get the bootstrap classes for the application. * @@ -444,4 +455,17 @@ class Kernel implements KernelContract { return $this->app; } + + /** + * Set the Laravel application instance. + * + * @param \Illuminate\Contracts\Foundation\Application + * @return $this + */ + public function setApplication(Application $app) + { + $this->app = $app; + + return $this; + } } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Http/MaintenanceModeBypassCookie.php b/vendor/laravel/framework/src/Illuminate/Foundation/Http/MaintenanceModeBypassCookie.php new file mode 100644 index 000000000..e566ac86d --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Http/MaintenanceModeBypassCookie.php @@ -0,0 +1,43 @@ +addHours(12); + + return new Cookie('laravel_maintenance', base64_encode(json_encode([ + 'expires_at' => $expiresAt->getTimestamp(), + 'mac' => hash_hmac('SHA256', $expiresAt->getTimestamp(), $key), + ])), $expiresAt); + } + + /** + * Determine if the given maintenance mode bypass cookie is valid. + * + * @param string $cookie + * @param string $key + * @return bool + */ + public static function isValid(string $cookie, string $key) + { + $payload = json_decode(base64_decode($cookie), true); + + return is_array($payload) && + is_numeric($payload['expires_at'] ?? null) && + isset($payload['mac']) && + hash_equals(hash_hmac('SHA256', $payload['expires_at'], $key), $payload['mac']) && + (int) $payload['expires_at'] >= Carbon::now()->getTimestamp(); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/CheckForMaintenanceMode.php b/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/CheckForMaintenanceMode.php index 5a34d1860..01a14b44b 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/CheckForMaintenanceMode.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/CheckForMaintenanceMode.php @@ -2,85 +2,7 @@ namespace Illuminate\Foundation\Http\Middleware; -use Closure; -use Illuminate\Contracts\Foundation\Application; -use Illuminate\Foundation\Http\Exceptions\MaintenanceModeException; -use Symfony\Component\HttpFoundation\IpUtils; - -class CheckForMaintenanceMode +class CheckForMaintenanceMode extends PreventRequestsDuringMaintenance { - /** - * The application implementation. - * - * @var \Illuminate\Contracts\Foundation\Application - */ - protected $app; - - /** - * The URIs that should be accessible while maintenance mode is enabled. - * - * @var array - */ - protected $except = []; - - /** - * Create a new middleware instance. - * - * @param \Illuminate\Contracts\Foundation\Application $app - * @return void - */ - public function __construct(Application $app) - { - $this->app = $app; - } - - /** - * Handle an incoming request. - * - * @param \Illuminate\Http\Request $request - * @param \Closure $next - * @return mixed - * - * @throws \Symfony\Component\HttpKernel\Exception\HttpException - * @throws \Illuminate\Foundation\Http\Exceptions\MaintenanceModeException - */ - public function handle($request, Closure $next) - { - if ($this->app->isDownForMaintenance()) { - $data = json_decode(file_get_contents($this->app->storagePath().'/framework/down'), true); - - if (isset($data['allowed']) && IpUtils::checkIp($request->ip(), (array) $data['allowed'])) { - return $next($request); - } - - if ($this->inExceptArray($request)) { - return $next($request); - } - - throw new MaintenanceModeException($data['time'], $data['retry'], $data['message']); - } - - return $next($request); - } - - /** - * Determine if the request has a URI that should be accessible in maintenance mode. - * - * @param \Illuminate\Http\Request $request - * @return bool - */ - protected function inExceptArray($request) - { - foreach ($this->except as $except) { - if ($except !== '/') { - $except = trim($except, '/'); - } - - if ($request->fullUrlIs($except) || $request->is($except)) { - return true; - } - } - - return false; - } + // } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ConvertEmptyStringsToNull.php b/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ConvertEmptyStringsToNull.php index 813c9cf12..d19a07fa4 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ConvertEmptyStringsToNull.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ConvertEmptyStringsToNull.php @@ -2,8 +2,35 @@ namespace Illuminate\Foundation\Http\Middleware; +use Closure; + class ConvertEmptyStringsToNull extends TransformsRequest { + /** + * All of the registered skip callbacks. + * + * @var array + */ + protected static $skipCallbacks = []; + + /** + * Handle an incoming request. + * + * @param \Illuminate\Http\Request $request + * @param \Closure $next + * @return mixed + */ + public function handle($request, Closure $next) + { + foreach (static::$skipCallbacks as $callback) { + if ($callback($request)) { + return $next($request); + } + } + + return parent::handle($request, $next); + } + /** * Transform the given value. * @@ -15,4 +42,15 @@ class ConvertEmptyStringsToNull extends TransformsRequest { return is_string($value) && $value === '' ? null : $value; } + + /** + * Register a callback that instructs the middleware to be skipped. + * + * @param \Closure $callback + * @return void + */ + public static function skipWhen(Closure $callback) + { + static::$skipCallbacks[] = $callback; + } } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/PreventRequestsDuringMaintenance.php b/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/PreventRequestsDuringMaintenance.php new file mode 100644 index 000000000..c65629d0a --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/PreventRequestsDuringMaintenance.php @@ -0,0 +1,156 @@ +app = $app; + } + + /** + * Handle an incoming request. + * + * @param \Illuminate\Http\Request $request + * @param \Closure $next + * @return mixed + * + * @throws \Symfony\Component\HttpKernel\Exception\HttpException + */ + public function handle($request, Closure $next) + { + if ($this->app->isDownForMaintenance()) { + $data = json_decode(file_get_contents($this->app->storagePath().'/framework/down'), true); + + if (isset($data['secret']) && $request->path() === $data['secret']) { + return $this->bypassResponse($data['secret']); + } + + if ($this->hasValidBypassCookie($request, $data) || + $this->inExceptArray($request)) { + return $next($request); + } + + if (isset($data['redirect'])) { + $path = $data['redirect'] === '/' + ? $data['redirect'] + : trim($data['redirect'], '/'); + + if ($request->path() !== $path) { + return redirect($path); + } + } + + if (isset($data['template'])) { + return response( + $data['template'], + $data['status'] ?? 503, + $this->getHeaders($data) + ); + } + + throw new HttpException( + $data['status'] ?? 503, + 'Service Unavailable', + null, + $this->getHeaders($data) + ); + } + + return $next($request); + } + + /** + * Determine if the incoming request has a maintenance mode bypass cookie. + * + * @param \Illuminate\Http\Request $request + * @param array $data + * @return bool + */ + protected function hasValidBypassCookie($request, array $data) + { + return isset($data['secret']) && + $request->cookie('laravel_maintenance') && + MaintenanceModeBypassCookie::isValid( + $request->cookie('laravel_maintenance'), + $data['secret'] + ); + } + + /** + * Determine if the request has a URI that should be accessible in maintenance mode. + * + * @param \Illuminate\Http\Request $request + * @return bool + */ + protected function inExceptArray($request) + { + foreach ($this->except as $except) { + if ($except !== '/') { + $except = trim($except, '/'); + } + + if ($request->fullUrlIs($except) || $request->is($except)) { + return true; + } + } + + return false; + } + + /** + * Redirect the user back to the root of the application with a maintenance mode bypass cookie. + * + * @param string $secret + * @return \Illuminate\Http\RedirectResponse + */ + protected function bypassResponse(string $secret) + { + return redirect('/')->withCookie( + MaintenanceModeBypassCookie::create($secret) + ); + } + + /** + * Get the headers that should be sent with the response. + * + * @param array $data + * @return array + */ + protected function getHeaders($data) + { + $headers = isset($data['retry']) ? ['Retry-After' => $data['retry']] : []; + + if (isset($data['refresh'])) { + $headers['Refresh'] = $data['refresh']; + } + + return $headers; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php b/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php index a61a1bd72..fca34f837 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php @@ -58,9 +58,11 @@ class TransformsRequest */ protected function cleanArray(array $data, $keyPrefix = '') { - return collect($data)->map(function ($value, $key) use ($keyPrefix) { - return $this->cleanValue($keyPrefix.$key, $value); - })->all(); + foreach ($data as $key => $value) { + $data[$key] = $this->cleanValue($keyPrefix.$key, $value); + } + + return collect($data)->all(); } /** diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TrimStrings.php b/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TrimStrings.php index 4c8d1ddba..fe8f8f872 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TrimStrings.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TrimStrings.php @@ -2,8 +2,17 @@ namespace Illuminate\Foundation\Http\Middleware; +use Closure; + class TrimStrings extends TransformsRequest { + /** + * All of the registered skip callbacks. + * + * @var array + */ + protected static $skipCallbacks = []; + /** * The attributes that should not be trimmed. * @@ -13,6 +22,24 @@ class TrimStrings extends TransformsRequest // ]; + /** + * Handle an incoming request. + * + * @param \Illuminate\Http\Request $request + * @param \Closure $next + * @return mixed + */ + public function handle($request, Closure $next) + { + foreach (static::$skipCallbacks as $callback) { + if ($callback($request)) { + return $next($request); + } + } + + return parent::handle($request, $next); + } + /** * Transform the given value. * @@ -28,4 +55,15 @@ class TrimStrings extends TransformsRequest return is_string($value) ? trim($value) : $value; } + + /** + * Register a callback that instructs the middleware to be skipped. + * + * @param \Closure $callback + * @return void + */ + public static function skipWhen(Closure $callback) + { + static::$skipCallbacks[] = $callback; + } } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Inspiring.php b/vendor/laravel/framework/src/Illuminate/Foundation/Inspiring.php index 6023f5635..a7e7524e1 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Inspiring.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Inspiring.php @@ -45,6 +45,11 @@ class Inspiring 'Waste no more time arguing what a good man should be, be one. - Marcus Aurelius', 'Well begun is half done. - Aristotle', 'When there is no desire, all things are at peace. - Laozi', + 'Walk as if you are kissing the Earth with your feet. - Thich Nhat Hanh', + 'Because you are alive, everything is possible. - Thich Nhat Hanh', + 'Breathing in, I calm body and mind. Breathing out, I smile. - Thich Nhat Hanh', + 'Life is available only in the present moment. - Thich Nhat Hanh', + 'The best way to take care of the future is to take care of the present moment. - Thich Nhat Hanh', ])->random(); } } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Mix.php b/vendor/laravel/framework/src/Illuminate/Foundation/Mix.php index 271d7dbd6..9a1eb7c95 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Mix.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Mix.php @@ -29,7 +29,7 @@ class Mix $manifestDirectory = "/{$manifestDirectory}"; } - if (file_exists(public_path($manifestDirectory.'/hot'))) { + if (is_file(public_path($manifestDirectory.'/hot'))) { $url = rtrim(file_get_contents(public_path($manifestDirectory.'/hot'))); if (Str::startsWith($url, ['http://', 'https://'])) { @@ -42,7 +42,7 @@ class Mix $manifestPath = public_path($manifestDirectory.'/mix-manifest.json'); if (! isset($manifests[$manifestPath])) { - if (! file_exists($manifestPath)) { + if (! is_file($manifestPath)) { throw new Exception('The Mix manifest does not exist.'); } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/PackageManifest.php b/vendor/laravel/framework/src/Illuminate/Foundation/PackageManifest.php index 9356cef02..202a8beb2 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/PackageManifest.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/PackageManifest.php @@ -102,11 +102,11 @@ class PackageManifest return $this->manifest; } - if (! file_exists($this->manifestPath)) { + if (! is_file($this->manifestPath)) { $this->build(); } - return $this->manifest = file_exists($this->manifestPath) ? + return $this->manifest = is_file($this->manifestPath) ? $this->files->getRequire($this->manifestPath) : []; } @@ -154,7 +154,7 @@ class PackageManifest */ protected function packagesToIgnore() { - if (! file_exists($this->basePath.'/composer.json')) { + if (! is_file($this->basePath.'/composer.json')) { return []; } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Providers/ArtisanServiceProvider.php b/vendor/laravel/framework/src/Illuminate/Foundation/Providers/ArtisanServiceProvider.php index c76251739..a0dd7067b 100755 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Providers/ArtisanServiceProvider.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Providers/ArtisanServiceProvider.php @@ -7,8 +7,13 @@ use Illuminate\Cache\Console\CacheTableCommand; use Illuminate\Cache\Console\ClearCommand as CacheClearCommand; use Illuminate\Cache\Console\ForgetCommand as CacheForgetCommand; use Illuminate\Console\Scheduling\ScheduleFinishCommand; +use Illuminate\Console\Scheduling\ScheduleListCommand; use Illuminate\Console\Scheduling\ScheduleRunCommand; +use Illuminate\Console\Scheduling\ScheduleTestCommand; +use Illuminate\Console\Scheduling\ScheduleWorkCommand; use Illuminate\Contracts\Support\DeferrableProvider; +use Illuminate\Database\Console\DbCommand; +use Illuminate\Database\Console\DumpCommand; use Illuminate\Database\Console\Factories\FactoryMakeCommand; use Illuminate\Database\Console\Seeds\SeedCommand; use Illuminate\Database\Console\Seeds\SeederMakeCommand; @@ -55,12 +60,16 @@ use Illuminate\Foundation\Console\VendorPublishCommand; use Illuminate\Foundation\Console\ViewCacheCommand; use Illuminate\Foundation\Console\ViewClearCommand; use Illuminate\Notifications\Console\NotificationTableCommand; +use Illuminate\Queue\Console\BatchesTableCommand; +use Illuminate\Queue\Console\ClearCommand as QueueClearCommand; use Illuminate\Queue\Console\FailedTableCommand; use Illuminate\Queue\Console\FlushFailedCommand as FlushFailedQueueCommand; use Illuminate\Queue\Console\ForgetFailedCommand as ForgetFailedQueueCommand; use Illuminate\Queue\Console\ListenCommand as QueueListenCommand; use Illuminate\Queue\Console\ListFailedCommand as ListFailedQueueCommand; +use Illuminate\Queue\Console\PruneBatchesCommand as PruneBatchesQueueCommand; use Illuminate\Queue\Console\RestartCommand as QueueRestartCommand; +use Illuminate\Queue\Console\RetryBatchCommand as QueueRetryBatchCommand; use Illuminate\Queue\Console\RetryCommand as QueueRetryCommand; use Illuminate\Queue\Console\TableCommand; use Illuminate\Queue\Console\WorkCommand as QueueWorkCommand; @@ -83,6 +92,7 @@ class ArtisanServiceProvider extends ServiceProvider implements DeferrableProvid 'ClearResets' => 'command.auth.resets.clear', 'ConfigCache' => 'command.config.cache', 'ConfigClear' => 'command.config.clear', + 'Db' => DbCommand::class, 'DbWipe' => 'command.db.wipe', 'Down' => 'command.down', 'Environment' => 'command.environment', @@ -93,19 +103,26 @@ class ArtisanServiceProvider extends ServiceProvider implements DeferrableProvid 'Optimize' => 'command.optimize', 'OptimizeClear' => 'command.optimize.clear', 'PackageDiscover' => 'command.package.discover', + 'QueueClear' => 'command.queue.clear', 'QueueFailed' => 'command.queue.failed', 'QueueFlush' => 'command.queue.flush', 'QueueForget' => 'command.queue.forget', 'QueueListen' => 'command.queue.listen', + 'QueuePruneBatches' => 'command.queue.prune-batches', 'QueueRestart' => 'command.queue.restart', 'QueueRetry' => 'command.queue.retry', + 'QueueRetryBatch' => 'command.queue.retry-batch', 'QueueWork' => 'command.queue.work', 'RouteCache' => 'command.route.cache', 'RouteClear' => 'command.route.clear', 'RouteList' => 'command.route.list', + 'SchemaDump' => 'command.schema.dump', 'Seed' => 'command.seed', 'ScheduleFinish' => ScheduleFinishCommand::class, + 'ScheduleList' => ScheduleListCommand::class, 'ScheduleRun' => ScheduleRunCommand::class, + 'ScheduleTest' => ScheduleTestCommand::class, + 'ScheduleWork' => ScheduleWorkCommand::class, 'StorageLink' => 'command.storage.link', 'Up' => 'command.up', 'ViewCache' => 'command.view.cache', @@ -140,6 +157,7 @@ class ArtisanServiceProvider extends ServiceProvider implements DeferrableProvid 'ProviderMake' => 'command.provider.make', 'QueueFailedTable' => 'command.queue.failed-table', 'QueueTable' => 'command.queue.table', + 'QueueBatchesTable' => 'command.queue.batches-table', 'RequestMake' => 'command.request.make', 'ResourceMake' => 'command.resource.make', 'RuleMake' => 'command.rule.make', @@ -322,6 +340,16 @@ class ArtisanServiceProvider extends ServiceProvider implements DeferrableProvid }); } + /** + * Register the command. + * + * @return void + */ + protected function registerDbCommand() + { + $this->app->singleton(DbCommand::class); + } + /** * Register the command. * @@ -438,7 +466,7 @@ class ArtisanServiceProvider extends ServiceProvider implements DeferrableProvid protected function registerEventListCommand() { $this->app->singleton('command.event.list', function () { - return new EventListCommand(); + return new EventListCommand; }); } @@ -658,6 +686,18 @@ class ArtisanServiceProvider extends ServiceProvider implements DeferrableProvid }); } + /** + * Register the command. + * + * @return void + */ + protected function registerQueuePruneBatchesCommand() + { + $this->app->singleton('command.queue.prune-batches', function () { + return new PruneBatchesQueueCommand; + }); + } + /** * Register the command. * @@ -682,6 +722,18 @@ class ArtisanServiceProvider extends ServiceProvider implements DeferrableProvid }); } + /** + * Register the command. + * + * @return void + */ + protected function registerQueueRetryBatchCommand() + { + $this->app->singleton('command.queue.retry-batch', function () { + return new QueueRetryBatchCommand; + }); + } + /** * Register the command. * @@ -694,6 +746,18 @@ class ArtisanServiceProvider extends ServiceProvider implements DeferrableProvid }); } + /** + * Register the command. + * + * @return void + */ + protected function registerQueueClearCommand() + { + $this->app->singleton('command.queue.clear', function () { + return new QueueClearCommand; + }); + } + /** * Register the command. * @@ -718,6 +782,18 @@ class ArtisanServiceProvider extends ServiceProvider implements DeferrableProvid }); } + /** + * Register the command. + * + * @return void + */ + protected function registerQueueBatchesTableCommand() + { + $this->app->singleton('command.queue.batches-table', function ($app) { + return new BatchesTableCommand($app['files'], $app['composer']); + }); + } + /** * Register the command. * @@ -826,6 +902,18 @@ class ArtisanServiceProvider extends ServiceProvider implements DeferrableProvid }); } + /** + * Register the command. + * + * @return void + */ + protected function registerSchemaDumpCommand() + { + $this->app->singleton('command.schema.dump', function () { + return new DumpCommand; + }); + } + /** * Register the command. * @@ -848,6 +936,16 @@ class ArtisanServiceProvider extends ServiceProvider implements DeferrableProvid $this->app->singleton(ScheduleFinishCommand::class); } + /** + * Register the command. + * + * @return void + */ + protected function registerScheduleListCommand() + { + $this->app->singleton(ScheduleListCommand::class); + } + /** * Register the command. * @@ -858,6 +956,26 @@ class ArtisanServiceProvider extends ServiceProvider implements DeferrableProvid $this->app->singleton(ScheduleRunCommand::class); } + /** + * Register the command. + * + * @return void + */ + protected function registerScheduleTestCommand() + { + $this->app->singleton(ScheduleTestCommand::class); + } + + /** + * Register the command. + * + * @return void + */ + protected function registerScheduleWorkCommand() + { + $this->app->singleton(ScheduleWorkCommand::class); + } + /** * Register the command. * diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Providers/ConsoleSupportServiceProvider.php b/vendor/laravel/framework/src/Illuminate/Foundation/Providers/ConsoleSupportServiceProvider.php index b23f18731..f6131ca5e 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Providers/ConsoleSupportServiceProvider.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Providers/ConsoleSupportServiceProvider.php @@ -11,7 +11,7 @@ class ConsoleSupportServiceProvider extends AggregateServiceProvider implements /** * The provider class names. * - * @var array + * @var string[] */ protected $providers = [ ArtisanServiceProvider::class, diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Providers/FoundationServiceProvider.php b/vendor/laravel/framework/src/Illuminate/Foundation/Providers/FoundationServiceProvider.php index b9d844965..f5ffb3365 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Providers/FoundationServiceProvider.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Providers/FoundationServiceProvider.php @@ -5,6 +5,7 @@ namespace Illuminate\Foundation\Providers; use Illuminate\Http\Request; use Illuminate\Support\AggregateServiceProvider; use Illuminate\Support\Facades\URL; +use Illuminate\Testing\ParallelTestingServiceProvider; use Illuminate\Validation\ValidationException; class FoundationServiceProvider extends AggregateServiceProvider @@ -12,10 +13,11 @@ class FoundationServiceProvider extends AggregateServiceProvider /** * The provider class names. * - * @var array + * @var string[] */ protected $providers = [ FormRequestServiceProvider::class, + ParallelTestingServiceProvider::class, ]; /** @@ -79,5 +81,9 @@ class FoundationServiceProvider extends AggregateServiceProvider Request::macro('hasValidSignature', function ($absolute = true) { return URL::hasValidSignature($this, $absolute); }); + + Request::macro('hasValidRelativeSignature', function () { + return URL::hasValidSignature($this, $absolute = false); + }); } } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Support/Providers/EventServiceProvider.php b/vendor/laravel/framework/src/Illuminate/Foundation/Support/Providers/EventServiceProvider.php index 11e63a8d0..70ea3086e 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Support/Providers/EventServiceProvider.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Support/Providers/EventServiceProvider.php @@ -27,19 +27,31 @@ class EventServiceProvider extends ServiceProvider * * @return void */ + public function register() + { + $this->booting(function () { + $events = $this->getEvents(); + + foreach ($events as $event => $listeners) { + foreach (array_unique($listeners) as $listener) { + Event::listen($event, $listener); + } + } + + foreach ($this->subscribe as $subscriber) { + Event::subscribe($subscriber); + } + }); + } + + /** + * Boot any application services. + * + * @return void + */ public function boot() { - $events = $this->getEvents(); - - foreach ($events as $event => $listeners) { - foreach (array_unique($listeners) as $listener) { - Event::listen($event, $listener); - } - } - - foreach ($this->subscribe as $subscriber) { - Event::subscribe($subscriber); - } + // } /** @@ -107,7 +119,7 @@ class EventServiceProvider extends ServiceProvider ->reduce(function ($discovered, $directory) { return array_merge_recursive( $discovered, - DiscoverEvents::within($directory, base_path()) + DiscoverEvents::within($directory, $this->eventDiscoveryBasePath()) ); }, []); } @@ -123,4 +135,14 @@ class EventServiceProvider extends ServiceProvider $this->app->path('Listeners'), ]; } + + /** + * Get the base path to be used during event discovery. + * + * @return string + */ + protected function eventDiscoveryBasePath() + { + return base_path(); + } } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Support/Providers/RouteServiceProvider.php b/vendor/laravel/framework/src/Illuminate/Foundation/Support/Providers/RouteServiceProvider.php index b281da1a5..c8679e51e 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Support/Providers/RouteServiceProvider.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Support/Providers/RouteServiceProvider.php @@ -2,6 +2,7 @@ namespace Illuminate\Foundation\Support\Providers; +use Closure; use Illuminate\Contracts\Routing\UrlGenerator; use Illuminate\Routing\Router; use Illuminate\Support\ServiceProvider; @@ -21,6 +22,36 @@ class RouteServiceProvider extends ServiceProvider */ protected $namespace; + /** + * The callback that should be used to load the application's routes. + * + * @var \Closure|null + */ + protected $loadRoutesUsing; + + /** + * Register any application services. + * + * @return void + */ + public function register() + { + $this->booted(function () { + $this->setRootControllerNamespace(); + + if ($this->routesAreCached()) { + $this->loadCachedRoutes(); + } else { + $this->loadRoutes(); + + $this->app->booted(function () { + $this->app['router']->getRoutes()->refreshNameLookups(); + $this->app['router']->getRoutes()->refreshActionLookups(); + }); + } + }); + } + /** * Bootstrap any application services. * @@ -28,18 +59,20 @@ class RouteServiceProvider extends ServiceProvider */ public function boot() { - $this->setRootControllerNamespace(); + // + } - if ($this->routesAreCached()) { - $this->loadCachedRoutes(); - } else { - $this->loadRoutes(); + /** + * Register the callback that will be used to load the application's routes. + * + * @param \Closure $routesCallback + * @return $this + */ + protected function routes(Closure $routesCallback) + { + $this->loadRoutesUsing = $routesCallback; - $this->app->booted(function () { - $this->app['router']->getRoutes()->refreshNameLookups(); - $this->app['router']->getRoutes()->refreshActionLookups(); - }); - } + return $this; } /** @@ -83,7 +116,9 @@ class RouteServiceProvider extends ServiceProvider */ protected function loadRoutes() { - if (method_exists($this, 'map')) { + if (! is_null($this->loadRoutesUsing)) { + $this->app->call($this->loadRoutesUsing); + } elseif (method_exists($this, 'map')) { $this->app->call([$this, 'map']); } } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithAuthentication.php b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithAuthentication.php index 404a8bfb6..9e8c0f587 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithAuthentication.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithAuthentication.php @@ -10,30 +10,30 @@ trait InteractsWithAuthentication * Set the currently logged in user for the application. * * @param \Illuminate\Contracts\Auth\Authenticatable $user - * @param string|null $driver + * @param string|null $guard * @return $this */ - public function actingAs(UserContract $user, $driver = null) + public function actingAs(UserContract $user, $guard = null) { - return $this->be($user, $driver); + return $this->be($user, $guard); } /** * Set the currently logged in user for the application. * * @param \Illuminate\Contracts\Auth\Authenticatable $user - * @param string|null $driver + * @param string|null $guard * @return $this */ - public function be(UserContract $user, $driver = null) + public function be(UserContract $user, $guard = null) { if (isset($user->wasRecentlyCreated) && $user->wasRecentlyCreated) { $user->wasRecentlyCreated = false; } - $this->app['auth']->guard($driver)->setUser($user); + $this->app['auth']->guard($guard)->setUser($user); - $this->app['auth']->shouldUse($driver); + $this->app['auth']->shouldUse($guard); return $this; } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithConsole.php b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithConsole.php index b34777910..38409d3d6 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithConsole.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithConsole.php @@ -23,7 +23,14 @@ trait InteractsWithConsole public $expectedOutput = []; /** - * All of the expected ouput tables. + * All of the output lines that aren't expected to be displayed. + * + * @var array + */ + public $unexpectedOutput = []; + + /** + * All of the expected output tables. * * @var array */ diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithDatabase.php b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithDatabase.php index 10efb827b..86da0dcfd 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithDatabase.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithDatabase.php @@ -2,9 +2,11 @@ namespace Illuminate\Foundation\Testing\Concerns; +use Illuminate\Contracts\Support\Jsonable; use Illuminate\Database\Eloquent\Model; use Illuminate\Database\Eloquent\SoftDeletes; use Illuminate\Support\Arr; +use Illuminate\Support\Facades\DB; use Illuminate\Testing\Constraints\CountInDatabase; use Illuminate\Testing\Constraints\HasInDatabase; use Illuminate\Testing\Constraints\SoftDeletedInDatabase; @@ -15,7 +17,7 @@ trait InteractsWithDatabase /** * Assert that a given where condition exists in the database. * - * @param string $table + * @param \Illuminate\Database\Eloquent\Model|string $table * @param array $data * @param string|null $connection * @return $this @@ -23,7 +25,7 @@ trait InteractsWithDatabase protected function assertDatabaseHas($table, array $data, $connection = null) { $this->assertThat( - $table, new HasInDatabase($this->getConnection($connection), $data) + $this->getTable($table), new HasInDatabase($this->getConnection($connection), $data) ); return $this; @@ -32,7 +34,7 @@ trait InteractsWithDatabase /** * Assert that a given where condition does not exist in the database. * - * @param string $table + * @param \Illuminate\Database\Eloquent\Model|string $table * @param array $data * @param string|null $connection * @return $this @@ -43,7 +45,7 @@ trait InteractsWithDatabase new HasInDatabase($this->getConnection($connection), $data) ); - $this->assertThat($table, $constraint); + $this->assertThat($this->getTable($table), $constraint); return $this; } @@ -51,7 +53,7 @@ trait InteractsWithDatabase /** * Assert the count of table entries. * - * @param string $table + * @param \Illuminate\Database\Eloquent\Model|string $table * @param int $count * @param string|null $connection * @return $this @@ -59,7 +61,7 @@ trait InteractsWithDatabase protected function assertDatabaseCount($table, int $count, $connection = null) { $this->assertThat( - $table, new CountInDatabase($this->getConnection($connection), $count) + $this->getTable($table), new CountInDatabase($this->getConnection($connection), $count) ); return $this; @@ -79,7 +81,7 @@ trait InteractsWithDatabase return $this->assertDatabaseMissing($table->getTable(), [$table->getKeyName() => $table->getKey()], $table->getConnectionName()); } - $this->assertDatabaseMissing($table, $data, $connection); + $this->assertDatabaseMissing($this->getTable($table), $data, $connection); return $this; } @@ -100,7 +102,7 @@ trait InteractsWithDatabase } $this->assertThat( - $table, new SoftDeletedInDatabase($this->getConnection($connection), $data, $deletedAtColumn) + $this->getTable($table), new SoftDeletedInDatabase($this->getConnection($connection), $data, $deletedAtColumn) ); return $this; @@ -118,6 +120,23 @@ trait InteractsWithDatabase && in_array(SoftDeletes::class, class_uses_recursive($model)); } + /** + * Cast a JSON string to a database compatible type. + * + * @param array|string $value + * @return \Illuminate\Database\Query\Expression + */ + public function castAsJson($value) + { + if ($value instanceof Jsonable) { + $value = $value->toJson(); + } elseif (is_array($value)) { + $value = json_encode($value); + } + + return DB::raw("CAST('$value' AS JSON)"); + } + /** * Get the database connection. * @@ -133,13 +152,24 @@ trait InteractsWithDatabase return $database->connection($connection); } + /** + * Get the table name from the given model or string. + * + * @param \Illuminate\Database\Eloquent\Model|string $table + * @return string + */ + protected function getTable($table) + { + return is_subclass_of($table, Model::class) ? (new $table)->getTable() : $table; + } + /** * Seed a given database connection. * * @param array|string $class * @return $this */ - public function seed($class = 'DatabaseSeeder') + public function seed($class = 'Database\\Seeders\\DatabaseSeeder') { foreach (Arr::wrap($class) as $class) { $this->artisan('db:seed', ['--class' => $class, '--no-interaction' => true]); diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithExceptionHandling.php b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithExceptionHandling.php index 40e3d777f..5ce5686d6 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithExceptionHandling.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithExceptionHandling.php @@ -64,7 +64,8 @@ trait InteractsWithExceptionHandling $this->originalExceptionHandler = app(ExceptionHandler::class); } - $this->app->instance(ExceptionHandler::class, new class($this->originalExceptionHandler, $except) implements ExceptionHandler { + $this->app->instance(ExceptionHandler::class, new class($this->originalExceptionHandler, $except) implements ExceptionHandler + { protected $except; protected $originalHandler; @@ -124,7 +125,7 @@ trait InteractsWithExceptionHandling if ($e instanceof NotFoundHttpException) { throw new NotFoundHttpException( - "{$request->method()} {$request->url()}", null, $e->getCode() + "{$request->method()} {$request->url()}", $e, $e->getCode() ); } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithRedis.php b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithRedis.php index a68995b05..6b17a72d8 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithRedis.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithRedis.php @@ -36,14 +36,10 @@ trait InteractsWithRedis if (! extension_loaded('redis')) { $this->markTestSkipped('The redis extension is not installed. Please install the extension to enable '.__CLASS__); - - return; } if (static::$connectionFailedOnceWithDefaultsSkip) { $this->markTestSkipped('Trying default host/port failed, please set environment variable REDIS_HOST & REDIS_PORT to enable '.__CLASS__); - - return; } foreach ($this->redisDriverProvider() as $driver) { @@ -57,6 +53,7 @@ trait InteractsWithRedis 'port' => $port, 'database' => 5, 'timeout' => 0.5, + 'name' => 'default', ], ]); } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithTime.php b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithTime.php new file mode 100644 index 000000000..184a2441c --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/InteractsWithTime.php @@ -0,0 +1,49 @@ +getPaths())) { + ViewFacade::addLocation(sys_get_temp_dir()); + } + + $tempFileInfo = pathinfo(tempnam($tempDirectory, 'laravel-blade')); + + $tempFile = $tempFileInfo['dirname'].'/'.$tempFileInfo['filename'].'.blade.php'; + + file_put_contents($tempFile, $template); + + return new TestView(view($tempFileInfo['filename'], $data)); + } + + /** + * Render the given view component. + * + * @param string $componentClass + * @param \Illuminate\Contracts\Support\Arrayable|array $data + * @return \Illuminate\Testing\TestView + */ + protected function component(string $componentClass, array $data = []) + { + $component = $this->app->make($componentClass, $data); + + $view = value($component->resolveView(), $data); + + return $view instanceof View + ? new TestView($view->with($component->data())) + : new TestView(view($view, $component->data())); + } + + /** + * Populate the shared view error bag with the given errors. + * + * @param array $errors + * @param string $key + * @return $this + */ + protected function withViewErrors(array $errors, $key = 'default') + { + ViewFacade::share('errors', (new ViewErrorBag)->put($key, new MessageBag($errors))); + + return $this; + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/MakesHttpRequests.php b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/MakesHttpRequests.php index 10e55aab1..eece007a3 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/MakesHttpRequests.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/MakesHttpRequests.php @@ -142,7 +142,8 @@ trait MakesHttpRequests } foreach ((array) $middleware as $abstract) { - $this->app->instance($abstract, new class { + $this->app->instance($abstract, new class + { public function handle($request, $next) { return $next($request); @@ -508,12 +509,12 @@ trait MakesHttpRequests $request = Request::createFromBase($symfonyRequest) ); + $kernel->terminate($request, $response); + if ($this->followRedirects) { $response = $this->followRedirects($response); } - $kernel->terminate($request, $response); - return $this->createTestResponse($response); } @@ -623,12 +624,12 @@ trait MakesHttpRequests */ protected function followRedirects($response) { + $this->followRedirects = false; + while ($response->isRedirect()) { $response = $this->get($response->headers->get('Location')); } - $this->followRedirects = false; - return $response; } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/MocksApplicationServices.php b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/MocksApplicationServices.php index 7fc360e76..66622950c 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/MocksApplicationServices.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/MocksApplicationServices.php @@ -8,6 +8,9 @@ use Illuminate\Contracts\Notifications\Dispatcher as NotificationDispatcher; use Illuminate\Support\Facades\Event; use Mockery; +/** + * @deprecated Will be removed in a future Laravel version. + */ trait MocksApplicationServices { /** diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/DatabaseTransactions.php b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/DatabaseTransactions.php index 9870153bb..7204d9be1 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/DatabaseTransactions.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/DatabaseTransactions.php @@ -14,14 +14,22 @@ trait DatabaseTransactions $database = $this->app->make('db'); foreach ($this->connectionsToTransact() as $name) { - $database->connection($name)->beginTransaction(); + $connection = $database->connection($name); + $dispatcher = $connection->getEventDispatcher(); + + $connection->unsetEventDispatcher(); + $connection->beginTransaction(); + $connection->setEventDispatcher($dispatcher); } $this->beforeApplicationDestroyed(function () use ($database) { foreach ($this->connectionsToTransact() as $name) { $connection = $database->connection($name); + $dispatcher = $connection->getEventDispatcher(); - $connection->rollBack(); + $connection->unsetEventDispatcher(); + $connection->rollback(); + $connection->setEventDispatcher($dispatcher); $connection->disconnect(); } }); diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/RefreshDatabase.php b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/RefreshDatabase.php index 0cbeea12d..d66fd0f94 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/RefreshDatabase.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/RefreshDatabase.php @@ -49,7 +49,9 @@ trait RefreshDatabase */ protected function migrateUsing() { - return []; + return [ + '--seed' => $this->shouldSeed(), + ]; } /** @@ -77,10 +79,15 @@ trait RefreshDatabase */ protected function migrateFreshUsing() { - return [ - '--drop-views' => $this->shouldDropViews(), - '--drop-types' => $this->shouldDropTypes(), - ]; + $seeder = $this->seeder(); + + return array_merge( + [ + '--drop-views' => $this->shouldDropViews(), + '--drop-types' => $this->shouldDropTypes(), + ], + $seeder ? ['--seeder' => $seeder] : ['--seed' => $this->shouldSeed()] + ); } /** @@ -132,8 +139,7 @@ trait RefreshDatabase */ protected function shouldDropViews() { - return property_exists($this, 'dropViews') - ? $this->dropViews : false; + return property_exists($this, 'dropViews') ? $this->dropViews : false; } /** @@ -143,7 +149,26 @@ trait RefreshDatabase */ protected function shouldDropTypes() { - return property_exists($this, 'dropTypes') - ? $this->dropTypes : false; + return property_exists($this, 'dropTypes') ? $this->dropTypes : false; + } + + /** + * Determine if the seed task should be run when refreshing the database. + * + * @return bool + */ + protected function shouldSeed() + { + return property_exists($this, 'seed') ? $this->seed : false; + } + + /** + * Determine the specific seeder class that should be used when refreshing the database. + * + * @return mixed + */ + protected function seeder() + { + return property_exists($this, 'seeder') ? $this->seeder : false; } } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/TestCase.php b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/TestCase.php index 3bcd3f026..ee19a864b 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/TestCase.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/TestCase.php @@ -6,7 +6,9 @@ use Carbon\Carbon; use Carbon\CarbonImmutable; use Illuminate\Console\Application as Artisan; use Illuminate\Database\Eloquent\Model; +use Illuminate\Queue\Queue; use Illuminate\Support\Facades\Facade; +use Illuminate\Support\Facades\ParallelTesting; use Illuminate\Support\Str; use Mockery; use Mockery\Exception\InvalidCountException; @@ -22,6 +24,8 @@ abstract class TestCase extends BaseTestCase Concerns\InteractsWithDatabase, Concerns\InteractsWithExceptionHandling, Concerns\InteractsWithSession, + Concerns\InteractsWithTime, + Concerns\InteractsWithViews, Concerns\MocksApplicationServices; /** @@ -79,6 +83,8 @@ abstract class TestCase extends BaseTestCase if (! $this->app) { $this->refreshApplication(); + + ParallelTesting::callSetUpTestCaseCallbacks($this); } $this->setUpTraits(); @@ -150,6 +156,8 @@ abstract class TestCase extends BaseTestCase if ($this->app) { $this->callBeforeApplicationDestroyedCallbacks(); + ParallelTesting::callTearDownTestCaseCallbacks($this); + $this->app->flush(); $this->app = null; @@ -192,6 +200,8 @@ abstract class TestCase extends BaseTestCase Artisan::forgetBootstrappers(); + Queue::createPayloadUsing(null); + if ($this->callbackException) { throw $this->callbackException; } diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Wormhole.php b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Wormhole.php new file mode 100644 index 000000000..6258f6de2 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Wormhole.php @@ -0,0 +1,157 @@ +value = $value; + } + + /** + * Travel forward the given number of milliseconds. + * + * @param callable|null $callback + * @return mixed + */ + public function milliseconds($callback = null) + { + Carbon::setTestNow(Carbon::now()->addMilliseconds($this->value)); + + return $this->handleCallback($callback); + } + + /** + * Travel forward the given number of seconds. + * + * @param callable|null $callback + * @return mixed + */ + public function seconds($callback = null) + { + Carbon::setTestNow(Carbon::now()->addSeconds($this->value)); + + return $this->handleCallback($callback); + } + + /** + * Travel forward the given number of minutes. + * + * @param callable|null $callback + * @return mixed + */ + public function minutes($callback = null) + { + Carbon::setTestNow(Carbon::now()->addMinutes($this->value)); + + return $this->handleCallback($callback); + } + + /** + * Travel forward the given number of hours. + * + * @param callable|null $callback + * @return mixed + */ + public function hours($callback = null) + { + Carbon::setTestNow(Carbon::now()->addHours($this->value)); + + return $this->handleCallback($callback); + } + + /** + * Travel forward the given number of days. + * + * @param callable|null $callback + * @return mixed + */ + public function days($callback = null) + { + Carbon::setTestNow(Carbon::now()->addDays($this->value)); + + return $this->handleCallback($callback); + } + + /** + * Travel forward the given number of weeks. + * + * @param callable|null $callback + * @return mixed + */ + public function weeks($callback = null) + { + Carbon::setTestNow(Carbon::now()->addWeeks($this->value)); + + return $this->handleCallback($callback); + } + + /** + * Travel forward the given number of months. + * + * @param callable|null $callback + * @return mixed + */ + public function months($callback = null) + { + Carbon::setTestNow(Carbon::now()->addMonths($this->value)); + + return $this->handleCallback($callback); + } + + /** + * Travel forward the given number of years. + * + * @param callable|null $callback + * @return mixed + */ + public function years($callback = null) + { + Carbon::setTestNow(Carbon::now()->addYears($this->value)); + + return $this->handleCallback($callback); + } + + /** + * Travel back to the current time. + * + * @return \DateTimeInterface + */ + public static function back() + { + Carbon::setTestNow(); + + return Carbon::now(); + } + + /** + * Handle the given optional execution callback. + * + * @param callable|null $callback + * @return mixed + */ + protected function handleCallback($callback) + { + if ($callback) { + return tap($callback(), function () { + Carbon::setTestNow(); + }); + } + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Foundation/helpers.php b/vendor/laravel/framework/src/Illuminate/Foundation/helpers.php index 5fbc613ac..5f5a71168 100644 --- a/vendor/laravel/framework/src/Illuminate/Foundation/helpers.php +++ b/vendor/laravel/framework/src/Illuminate/Foundation/helpers.php @@ -12,7 +12,7 @@ use Illuminate\Contracts\Routing\UrlGenerator; use Illuminate\Contracts\Support\Responsable; use Illuminate\Contracts\Validation\Factory as ValidationFactory; use Illuminate\Contracts\View\Factory as ViewFactory; -use Illuminate\Database\Eloquent\Factory as EloquentFactory; +use Illuminate\Foundation\Bus\PendingClosureDispatch; use Illuminate\Foundation\Bus\PendingDispatch; use Illuminate\Foundation\Mix; use Illuminate\Http\Exceptions\HttpResponseException; @@ -384,11 +384,25 @@ if (! function_exists('dispatch')) { */ function dispatch($job) { - if ($job instanceof Closure) { - $job = CallQueuedClosure::create($job); - } + return $job instanceof Closure + ? new PendingClosureDispatch(CallQueuedClosure::create($job)) + : new PendingDispatch($job); + } +} - return new PendingDispatch($job); +if (! function_exists('dispatch_sync')) { + /** + * Dispatch a command to its appropriate handler in the current process. + * + * Queueable jobs will be dispatched to the "sync" queue. + * + * @param mixed $job + * @param mixed $handler + * @return mixed + */ + function dispatch_sync($job, $handler = null) + { + return app(Dispatcher::class)->dispatchSync($job, $handler); } } @@ -399,6 +413,8 @@ if (! function_exists('dispatch_now')) { * @param mixed $job * @param mixed $handler * @return mixed + * + * @deprecated Will be removed in a future Laravel version. */ function dispatch_now($job, $handler = null) { @@ -406,48 +422,6 @@ if (! function_exists('dispatch_now')) { } } -if (! function_exists('elixir')) { - /** - * Get the path to a versioned Elixir file. - * - * @param string $file - * @param string $buildDirectory - * @return string - * - * @throws \InvalidArgumentException - * - * @deprecated Use Laravel Mix instead. - */ - function elixir($file, $buildDirectory = 'build') - { - static $manifest = []; - static $manifestPath; - - if (empty($manifest) || $manifestPath !== $buildDirectory) { - $path = public_path($buildDirectory.'/rev-manifest.json'); - - if (file_exists($path)) { - $manifest = json_decode(file_get_contents($path), true); - $manifestPath = $buildDirectory; - } - } - - $file = ltrim($file, '/'); - - if (isset($manifest[$file])) { - return '/'.trim($buildDirectory.'/'.$manifest[$file], '/'); - } - - $unversioned = public_path($file); - - if (file_exists($unversioned)) { - return '/'.trim($file, '/'); - } - - throw new InvalidArgumentException("File {$file} not defined in asset manifest."); - } -} - if (! function_exists('encrypt')) { /** * Encrypt the given value. @@ -477,26 +451,6 @@ if (! function_exists('event')) { } } -if (! function_exists('factory')) { - /** - * Create a model factory builder for a given class and amount. - * - * @param string $class - * @param int $amount - * @return \Illuminate\Database\Eloquent\FactoryBuilder - */ - function factory($class, $amount = null) - { - $factory = app(EloquentFactory::class); - - if (isset($amount) && is_int($amount)) { - return $factory->of($class)->times($amount); - } - - return $factory->of($class); - } -} - if (! function_exists('info')) { /** * Write some information to the log. @@ -650,11 +604,15 @@ if (! function_exists('report')) { /** * Report an exception. * - * @param \Throwable $exception + * @param \Throwable|string $exception * @return void */ - function report(Throwable $exception) + function report($exception) { + if (is_string($exception)) { + $exception = new Exception($exception); + } + app(ExceptionHandler::class)->report($exception); } } @@ -665,7 +623,7 @@ if (! function_exists('request')) { * * @param array|string|null $key * @param mixed $default - * @return \Illuminate\Http\Request|string|array + * @return \Illuminate\Http\Request|string|array|null */ function request($key = null, $default = null) { @@ -701,7 +659,7 @@ if (! function_exists('rescue')) { report($e); } - return $rescue instanceof Closure ? $rescue($e) : $rescue; + return value($rescue, $e); } } } @@ -737,7 +695,7 @@ if (! function_exists('response')) { /** * Return a new response from the application. * - * @param \Illuminate\View\View|string|array|null $content + * @param \Illuminate\Contracts\View\View|string|array|null $content * @param int $status * @param array $headers * @return \Illuminate\Http\Response|\Illuminate\Contracts\Routing\ResponseFactory @@ -948,7 +906,7 @@ if (! function_exists('view')) { * @param string|null $view * @param \Illuminate\Contracts\Support\Arrayable|array $data * @param array $mergeData - * @return \Illuminate\View\View|\Illuminate\Contracts\View\Factory + * @return \Illuminate\Contracts\View\View|\Illuminate\Contracts\View\Factory */ function view($view = null, $data = [], $mergeData = []) { diff --git a/vendor/laravel/framework/src/Illuminate/Hashing/ArgonHasher.php b/vendor/laravel/framework/src/Illuminate/Hashing/ArgonHasher.php index 41109c9b0..ea3a2f34c 100644 --- a/vendor/laravel/framework/src/Illuminate/Hashing/ArgonHasher.php +++ b/vendor/laravel/framework/src/Illuminate/Hashing/ArgonHasher.php @@ -180,7 +180,7 @@ class ArgonHasher extends AbstractHasher implements HasherContract } /** - * Extract the threads value from the options array. + * Extract the thread's value from the options array. * * @param array $options * @return int diff --git a/vendor/laravel/framework/src/Illuminate/Hashing/composer.json b/vendor/laravel/framework/src/Illuminate/Hashing/composer.json index c264eb493..6ad3411c7 100755 --- a/vendor/laravel/framework/src/Illuminate/Hashing/composer.json +++ b/vendor/laravel/framework/src/Illuminate/Hashing/composer.json @@ -14,9 +14,9 @@ } ], "require": { - "php": "^7.2.5|^8.0", - "illuminate/contracts": "^7.0", - "illuminate/support": "^7.0" + "php": "^7.3|^8.0", + "illuminate/contracts": "^8.0", + "illuminate/support": "^8.0" }, "autoload": { "psr-4": { @@ -25,7 +25,7 @@ }, "extra": { "branch-alias": { - "dev-master": "7.x-dev" + "dev-master": "8.x-dev" } }, "config": { diff --git a/vendor/laravel/framework/src/Illuminate/Http/Client/Factory.php b/vendor/laravel/framework/src/Illuminate/Http/Client/Factory.php index 1749de8a5..f6256f16a 100644 --- a/vendor/laravel/framework/src/Illuminate/Http/Client/Factory.php +++ b/vendor/laravel/framework/src/Illuminate/Http/Client/Factory.php @@ -3,12 +3,51 @@ namespace Illuminate\Http\Client; use Closure; -use function GuzzleHttp\Promise\promise_for; use GuzzleHttp\Psr7\Response as Psr7Response; use Illuminate\Support\Str; use Illuminate\Support\Traits\Macroable; use PHPUnit\Framework\Assert as PHPUnit; +/** + * @method \Illuminate\Http\Client\PendingRequest accept(string $contentType) + * @method \Illuminate\Http\Client\PendingRequest acceptJson() + * @method \Illuminate\Http\Client\PendingRequest asForm() + * @method \Illuminate\Http\Client\PendingRequest asJson() + * @method \Illuminate\Http\Client\PendingRequest asMultipart() + * @method \Illuminate\Http\Client\PendingRequest async() + * @method \Illuminate\Http\Client\PendingRequest attach(string|array $name, string $contents = '', string|null $filename = null, array $headers = []) + * @method \Illuminate\Http\Client\PendingRequest baseUrl(string $url) + * @method \Illuminate\Http\Client\PendingRequest beforeSending(callable $callback) + * @method \Illuminate\Http\Client\PendingRequest bodyFormat(string $format) + * @method \Illuminate\Http\Client\PendingRequest contentType(string $contentType) + * @method \Illuminate\Http\Client\PendingRequest dd() + * @method \Illuminate\Http\Client\PendingRequest dump() + * @method \Illuminate\Http\Client\PendingRequest retry(int $times, int $sleep = 0) + * @method \Illuminate\Http\Client\PendingRequest sink(string|resource $to) + * @method \Illuminate\Http\Client\PendingRequest stub(callable $callback) + * @method \Illuminate\Http\Client\PendingRequest timeout(int $seconds) + * @method \Illuminate\Http\Client\PendingRequest withBasicAuth(string $username, string $password) + * @method \Illuminate\Http\Client\PendingRequest withBody(resource|string $content, string $contentType) + * @method \Illuminate\Http\Client\PendingRequest withCookies(array $cookies, string $domain) + * @method \Illuminate\Http\Client\PendingRequest withDigestAuth(string $username, string $password) + * @method \Illuminate\Http\Client\PendingRequest withHeaders(array $headers) + * @method \Illuminate\Http\Client\PendingRequest withMiddleware(callable $middleware) + * @method \Illuminate\Http\Client\PendingRequest withOptions(array $options) + * @method \Illuminate\Http\Client\PendingRequest withToken(string $token, string $type = 'Bearer') + * @method \Illuminate\Http\Client\PendingRequest withUserAgent(string $userAgent) + * @method \Illuminate\Http\Client\PendingRequest withoutRedirecting() + * @method \Illuminate\Http\Client\PendingRequest withoutVerifying() + * @method array pool(callable $callback) + * @method \Illuminate\Http\Client\Response delete(string $url, array $data = []) + * @method \Illuminate\Http\Client\Response get(string $url, array|string|null $query = null) + * @method \Illuminate\Http\Client\Response head(string $url, array|string|null $query = null) + * @method \Illuminate\Http\Client\Response patch(string $url, array $data = []) + * @method \Illuminate\Http\Client\Response post(string $url, array $data = []) + * @method \Illuminate\Http\Client\Response put(string $url, array $data = []) + * @method \Illuminate\Http\Client\Response send(string $method, string $url, array $options = []) + * + * @see \Illuminate\Http\Client\PendingRequest + */ class Factory { use Macroable { @@ -69,7 +108,11 @@ class Factory $headers['Content-Type'] = 'application/json'; } - return promise_for(new Psr7Response($status, $headers, $body)); + $response = new Psr7Response($status, $headers, $body); + + return class_exists(GuzzleHttp\Promise\Create::class) + ? \GuzzleHttp\Promise\Create::promiseFor($response) + : \GuzzleHttp\Promise\promise_for($response); } /** @@ -191,6 +234,28 @@ class Factory ); } + /** + * Assert that the given request was sent in the given order. + * + * @param array $callbacks + * @return void + */ + public function assertSentInOrder($callbacks) + { + $this->assertSentCount(count($callbacks)); + + foreach ($callbacks as $index => $url) { + $callback = is_callable($url) ? $url : function ($request) use ($url) { + return $request->url() == $url; + }; + + PHPUnit::assertTrue($callback( + $this->recorded[$index][0], + $this->recorded[$index][1] + ), 'An expected request (#'.($index + 1).') was not recorded.'); + } + } + /** * Assert that a request / response pair was not recorded matching a given truth test. * @@ -250,7 +315,7 @@ class Factory * @param callable $callback * @return \Illuminate\Support\Collection */ - public function recorded($callback) + public function recorded($callback = null) { if (empty($this->recorded)) { return collect(); @@ -265,6 +330,16 @@ class Factory }); } + /** + * Create a new pending request instance for this factory. + * + * @return \Illuminate\Http\Client\PendingRequest + */ + protected function newPendingRequest() + { + return new PendingRequest($this); + } + /** * Execute a method against a new pending request instance. * @@ -278,7 +353,7 @@ class Factory return $this->macroCall($method, $parameters); } - return tap(new PendingRequest($this), function ($request) { + return tap($this->newPendingRequest(), function ($request) { $request->stub($this->stubCallbacks); })->{$method}(...$parameters); } diff --git a/vendor/laravel/framework/src/Illuminate/Http/Client/PendingRequest.php b/vendor/laravel/framework/src/Illuminate/Http/Client/PendingRequest.php index 304151cac..eb139f272 100644 --- a/vendor/laravel/framework/src/Illuminate/Http/Client/PendingRequest.php +++ b/vendor/laravel/framework/src/Illuminate/Http/Client/PendingRequest.php @@ -5,10 +5,14 @@ namespace Illuminate\Http\Client; use GuzzleHttp\Client; use GuzzleHttp\Cookie\CookieJar; use GuzzleHttp\Exception\ConnectException; +use GuzzleHttp\Exception\RequestException; +use GuzzleHttp\Exception\TransferException; use GuzzleHttp\HandlerStack; use Illuminate\Support\Collection; use Illuminate\Support\Str; use Illuminate\Support\Traits\Macroable; +use Psr\Http\Message\MessageInterface; +use Symfony\Component\VarDumper\VarDumper; class PendingRequest { @@ -21,6 +25,13 @@ class PendingRequest */ protected $factory; + /** + * The Guzzle client instance. + * + * @var \GuzzleHttp\Client + */ + protected $client; + /** * The base URL for the request. * @@ -105,6 +116,20 @@ class PendingRequest */ protected $middleware; + /** + * Whether the requests should be asynchronous. + * + * @var bool + */ + protected $async = false; + + /** + * The pending request promise. + * + * @var \GuzzleHttp\Promise\PromiseInterface + */ + protected $promise; + /** * Create a new HTTP Client instance. * @@ -181,14 +206,22 @@ class PendingRequest /** * Attach a file to the request. * - * @param string $name + * @param string|array $name * @param string $contents * @param string|null $filename * @param array $headers * @return $this */ - public function attach($name, $contents, $filename = null, array $headers = []) + public function attach($name, $contents = '', $filename = null, array $headers = []) { + if (is_array($name)) { + foreach ($name as $file) { + $this->attach(...$file); + } + + return $this; + } + $this->asMultipart(); $this->pendingFiles[] = array_filter([ @@ -313,6 +346,17 @@ class PendingRequest }); } + /** + * Specify the user agent for the request. + * + * @param string $userAgent + * @return $this + */ + public function withUserAgent($userAgent) + { + return $this->withHeaders(['User-Agent' => $userAgent]); + } + /** * Specify the cookies that should be included with the request. * @@ -433,6 +477,40 @@ class PendingRequest }); } + /** + * Dump the request before sending. + * + * @return $this + */ + public function dump() + { + $values = func_get_args(); + + return $this->beforeSending(function (Request $request, array $options) use ($values) { + foreach (array_merge($values, [$request, $options]) as $value) { + VarDumper::dump($value); + } + }); + } + + /** + * Dump the request before sending and end the script. + * + * @return $this + */ + public function dd() + { + $values = func_get_args(); + + return $this->beforeSending(function (Request $request, array $options) use ($values) { + foreach (array_merge($values, [$request, $options]) as $value) { + VarDumper::dump($value); + } + + exit(1); + }); + } + /** * Issue a GET request to the given URL. * @@ -517,6 +595,27 @@ class PendingRequest ]); } + /** + * Send a pool of asynchronous requests concurrently. + * + * @param callable $callback + * @return array + */ + public function pool(callable $callback) + { + $results = []; + + $requests = tap(new Pool($this->factory), $callback)->getRequests(); + + foreach ($requests as $key => $item) { + $results[$key] = $item instanceof static ? $item->getPromise()->wait() : $item->wait(); + } + + ksort($results); + + return $results; + } + /** * Send the request to the given URL. * @@ -543,22 +642,20 @@ class PendingRequest $options[$this->bodyFormat], $this->pendingFiles ); } + } else { + $options[$this->bodyFormat] = $this->pendingBody; } [$this->pendingBody, $this->pendingFiles] = [null, []]; + if ($this->async) { + return $this->makePromise($method, $url, $options); + } + return retry($this->tries ?? 1, function () use ($method, $url, $options) { try { - $laravelData = $this->parseRequestData($method, $url, $options); - - return tap(new Response($this->buildClient()->request($method, $url, $this->mergeOptions([ - 'laravel_data' => $laravelData, - 'on_stats' => function ($transferStats) { - $this->transferStats = $transferStats; - }, - ], $options))), function ($response) { - $response->cookies = $this->cookies; - $response->transferStats = $this->transferStats; + return tap(new Response($this->sendRequest($method, $url, $options)), function ($response) { + $this->populateResponse($response); if ($this->tries > 1 && ! $response->successful()) { $response->throw(); @@ -583,6 +680,49 @@ class PendingRequest })->values()->all(); } + /** + * Send an asynchronous request to the given URL. + * + * @param string $method + * @param string $url + * @param array $options + * @return \GuzzleHttp\Promise\PromiseInterface + */ + protected function makePromise(string $method, string $url, array $options = []) + { + return $this->promise = $this->sendRequest($method, $url, $options) + ->then(function (MessageInterface $message) { + return $this->populateResponse(new Response($message)); + }) + ->otherwise(function (TransferException $e) { + return $e instanceof RequestException ? $this->populateResponse(new Response($e->getResponse())) : $e; + }); + } + + /** + * Send a request either synchronously or asynchronously. + * + * @param string $method + * @param string $url + * @param array $options + * @return \Psr\Http\Message\MessageInterface|\GuzzleHttp\Promise\PromiseInterface + * + * @throws \Exception + */ + protected function sendRequest(string $method, string $url, array $options = []) + { + $clientMethod = $this->async ? 'requestAsync' : 'request'; + + $laravelData = $this->parseRequestData($method, $url, $options); + + return $this->buildClient()->$clientMethod($method, $url, $this->mergeOptions([ + 'laravel_data' => $laravelData, + 'on_stats' => function ($transferStats) { + $this->transferStats = $transferStats; + }, + ], $options)); + } + /** * Get the request data as an array so that we can attach it to the request for convenient assertions. * @@ -610,6 +750,21 @@ class PendingRequest return $laravelData; } + /** + * Populate the given response with additional data. + * + * @param \Illuminate\Http\Client\Response $response + * @return \Illuminate\Http\Client\Response + */ + protected function populateResponse(Response $response) + { + $response->cookies = $this->cookies; + + $response->transferStats = $this->transferStats; + + return $response; + } + /** * Build the Guzzle client. * @@ -617,7 +772,7 @@ class PendingRequest */ public function buildClient() { - return new Client([ + return $this->client = $this->client ?: new Client([ 'handler' => $this->buildHandlerStack(), 'cookies' => true, ]); @@ -664,7 +819,7 @@ class PendingRequest { return function ($handler) { return function ($request, $options) use ($handler) { - $promise = $handler($this->runBeforeSendingCallbacks($request, $options), $options); + $promise = $handler($request, $options); return $promise->then(function ($response) use ($request, $options) { optional($this->factory)->recordRequestResponsePair( @@ -772,4 +927,40 @@ class PendingRequest return $this; } + + /** + * Toggle asynchronicity in requests. + * + * @param bool $async + * @return $this + */ + public function async(bool $async = true) + { + $this->async = $async; + + return $this; + } + + /** + * Retrieve the pending request promise. + * + * @return \GuzzleHttp\Promise\PromiseInterface|null + */ + public function getPromise() + { + return $this->promise; + } + + /** + * Set the client instance. + * + * @param \GuzzleHttp\Client $client + * @return $this + */ + public function setClient(Client $client) + { + $this->client = $client; + + return $this; + } } diff --git a/vendor/laravel/framework/src/Illuminate/Http/Client/Pool.php b/vendor/laravel/framework/src/Illuminate/Http/Client/Pool.php new file mode 100644 index 000000000..23ae75e9b --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Http/Client/Pool.php @@ -0,0 +1,86 @@ +factory = $factory ?: new Factory(); + + $this->client = $this->factory->buildClient(); + } + + /** + * Add a request to the pool with a key. + * + * @param string $key + * @return \Illuminate\Http\Client\PendingRequest + */ + public function as(string $key) + { + return $this->pool[$key] = $this->asyncRequest(); + } + + /** + * Retrieve a new async pending request. + * + * @return \Illuminate\Http\Client\PendingRequest + */ + protected function asyncRequest() + { + return $this->factory->setClient($this->client)->async(); + } + + /** + * Retrieve the requests in the pool. + * + * @return array + */ + public function getRequests() + { + return $this->pool; + } + + /** + * Add a request to the pool with a numeric index. + * + * @param string $method + * @param array $parameters + * @return \Illuminate\Http\Client\PendingRequest + */ + public function __call($method, $parameters) + { + return $this->pool[] = $this->asyncRequest()->$method(...$parameters); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Http/Client/RequestException.php b/vendor/laravel/framework/src/Illuminate/Http/Client/RequestException.php index 09909db7e..fa4f41839 100644 --- a/vendor/laravel/framework/src/Illuminate/Http/Client/RequestException.php +++ b/vendor/laravel/framework/src/Illuminate/Http/Client/RequestException.php @@ -19,8 +19,25 @@ class RequestException extends HttpClientException */ public function __construct(Response $response) { - parent::__construct("HTTP request returned status code {$response->status()}.", $response->status()); + parent::__construct($this->prepareMessage($response), $response->status()); $this->response = $response; } + + /** + * Prepare the exception message. + * + * @param \Illuminate\Http\Client\Response $response + * @return string + */ + protected function prepareMessage(Response $response) + { + $message = "HTTP request returned status code {$response->status()}"; + + $summary = class_exists(\GuzzleHttp\Psr7\Message::class) + ? \GuzzleHttp\Psr7\Message::bodySummary($response->toPsrResponse()) + : \GuzzleHttp\Psr7\get_message_body_summary($response->toPsrResponse()); + + return is_null($summary) ? $message : $message .= ":\n{$summary}\n"; + } } diff --git a/vendor/laravel/framework/src/Illuminate/Http/Client/Response.php b/vendor/laravel/framework/src/Illuminate/Http/Client/Response.php index 991705d96..1b2fc5fb7 100644 --- a/vendor/laravel/framework/src/Illuminate/Http/Client/Response.php +++ b/vendor/laravel/framework/src/Illuminate/Http/Client/Response.php @@ -3,6 +3,7 @@ namespace Illuminate\Http\Client; use ArrayAccess; +use Illuminate\Support\Collection; use Illuminate\Support\Traits\Macroable; use LogicException; @@ -50,15 +51,21 @@ class Response implements ArrayAccess /** * Get the JSON decoded body of the response as an array or scalar value. * + * @param string|null $key + * @param mixed $default * @return mixed */ - public function json() + public function json($key = null, $default = null) { if (! $this->decoded) { $this->decoded = json_decode($this->body(), true); } - return $this->decoded; + if (is_null($key)) { + return $this->decoded; + } + + return data_get($this->decoded, $key, $default); } /** @@ -71,6 +78,17 @@ class Response implements ArrayAccess return json_decode($this->body(), false); } + /** + * Get the JSON decoded body of the response as a collection. + * + * @param string|null $key + * @return \Illuminate\Support\Collection + */ + public function collect($key = null) + { + return Collection::make($this->json($key)); + } + /** * Get a header from the response. * @@ -174,6 +192,21 @@ class Response implements ArrayAccess return $this->status() >= 500; } + /** + * Execute the given callback if there was a server or client error. + * + * @param \Closure|callable $callback + * @return $this + */ + public function onError(callable $callback) + { + if ($this->failed()) { + $callback($this); + } + + return $this; + } + /** * Get the response cookies. * @@ -184,6 +217,16 @@ class Response implements ArrayAccess return $this->cookies; } + /** + * Get the handler stats of the response. + * + * @return array + */ + public function handlerStats() + { + return $this->transferStats->getHandlerStats(); + } + /** * Get the underlying PSR response for the response. * @@ -194,17 +237,36 @@ class Response implements ArrayAccess return $this->response; } + /** + * Create an exception if a server or client error occurred. + * + * @return \Illuminate\Http\Client\RequestException|null + */ + public function toException() + { + if ($this->failed()) { + return new RequestException($this); + } + } + /** * Throw an exception if a server or client error occurred. * + * @param \Closure|null $callback * @return $this * * @throws \Illuminate\Http\Client\RequestException */ public function throw() { - if ($this->serverError() || $this->clientError()) { - throw new RequestException($this); + $callback = func_get_args()[0] ?? null; + + if ($this->failed()) { + throw tap($this->toException(), function ($exception) use ($callback) { + if ($callback && is_callable($callback)) { + $callback($this, $exception); + } + }); } return $this; diff --git a/vendor/laravel/framework/src/Illuminate/Http/Client/ResponseSequence.php b/vendor/laravel/framework/src/Illuminate/Http/Client/ResponseSequence.php index 66d0ec6bb..dcf8633a3 100644 --- a/vendor/laravel/framework/src/Illuminate/Http/Client/ResponseSequence.php +++ b/vendor/laravel/framework/src/Illuminate/Http/Client/ResponseSequence.php @@ -2,10 +2,13 @@ namespace Illuminate\Http\Client; +use Illuminate\Support\Traits\Macroable; use OutOfBoundsException; class ResponseSequence { + use Macroable; + /** * The responses in the sequence. * @@ -137,6 +140,8 @@ class ResponseSequence * Get the next response in the sequence. * * @return mixed + * + * @throws \OutOfBoundsException */ public function __invoke() { diff --git a/vendor/laravel/framework/src/Illuminate/Http/Concerns/InteractsWithContentTypes.php b/vendor/laravel/framework/src/Illuminate/Http/Concerns/InteractsWithContentTypes.php index 25d6ec1e9..faf25d92e 100644 --- a/vendor/laravel/framework/src/Illuminate/Http/Concerns/InteractsWithContentTypes.php +++ b/vendor/laravel/framework/src/Illuminate/Http/Concerns/InteractsWithContentTypes.php @@ -6,24 +6,6 @@ use Illuminate\Support\Str; trait InteractsWithContentTypes { - /** - * Determine if the given content types match. - * - * @param string $actual - * @param string $type - * @return bool - */ - public static function matchesType($actual, $type) - { - if ($actual === $type) { - return true; - } - - $split = explode('/', $actual); - - return isset($split[1]) && preg_match('#'.preg_quote($split[0], '#').'/.+\+'.preg_quote($split[1], '#').'#', $type); - } - /** * Determine if the request is sending JSON. * @@ -152,6 +134,24 @@ trait InteractsWithContentTypes return $this->accepts('text/html'); } + /** + * Determine if the given content types match. + * + * @param string $actual + * @param string $type + * @return bool + */ + public static function matchesType($actual, $type) + { + if ($actual === $type) { + return true; + } + + $split = explode('/', $actual); + + return isset($split[1]) && preg_match('#'.preg_quote($split[0], '#').'/.+\+'.preg_quote($split[1], '#').'#', $type); + } + /** * Get the data format expected in the response. * diff --git a/vendor/laravel/framework/src/Illuminate/Http/Concerns/InteractsWithFlashData.php b/vendor/laravel/framework/src/Illuminate/Http/Concerns/InteractsWithFlashData.php index 25e11a954..6682e5427 100644 --- a/vendor/laravel/framework/src/Illuminate/Http/Concerns/InteractsWithFlashData.php +++ b/vendor/laravel/framework/src/Illuminate/Http/Concerns/InteractsWithFlashData.php @@ -9,7 +9,7 @@ trait InteractsWithFlashData * * @param string|null $key * @param string|array|null $default - * @return string|array + * @return string|array|null */ public function old($key = null, $default = null) { diff --git a/vendor/laravel/framework/src/Illuminate/Http/Concerns/InteractsWithInput.php b/vendor/laravel/framework/src/Illuminate/Http/Concerns/InteractsWithInput.php index 4550271b0..69b00672d 100644 --- a/vendor/laravel/framework/src/Illuminate/Http/Concerns/InteractsWithInput.php +++ b/vendor/laravel/framework/src/Illuminate/Http/Concerns/InteractsWithInput.php @@ -7,6 +7,7 @@ use Illuminate\Support\Arr; use Illuminate\Support\Str; use SplFileInfo; use stdClass; +use Symfony\Component\VarDumper\VarDumper; trait InteractsWithInput { @@ -462,4 +463,34 @@ trait InteractsWithInput return $this->$source->get($key, $default); } + + /** + * Dump the request items and end the script. + * + * @param array|mixed $keys + * @return void + */ + public function dd(...$keys) + { + $keys = is_array($keys) ? $keys : func_get_args(); + + call_user_func_array([$this, 'dump'], $keys); + + exit(1); + } + + /** + * Dump the items. + * + * @param array $keys + * @return $this + */ + public function dump($keys = []) + { + $keys = is_array($keys) ? $keys : func_get_args(); + + VarDumper::dump(count($keys) > 0 ? $this->only($keys) : $this->all()); + + return $this; + } } diff --git a/vendor/laravel/framework/src/Illuminate/Http/JsonResponse.php b/vendor/laravel/framework/src/Illuminate/Http/JsonResponse.php index 9f87e6c31..5b103480a 100755 --- a/vendor/laravel/framework/src/Illuminate/Http/JsonResponse.php +++ b/vendor/laravel/framework/src/Illuminate/Http/JsonResponse.php @@ -22,13 +22,22 @@ class JsonResponse extends BaseJsonResponse * @param int $status * @param array $headers * @param int $options + * @param bool $json * @return void */ - public function __construct($data = null, $status = 200, $headers = [], $options = 0) + public function __construct($data = null, $status = 200, $headers = [], $options = 0, $json = false) { $this->encodingOptions = $options; - parent::__construct($data, $status, $headers); + parent::__construct($data, $status, $headers, $json); + } + + /** + * {@inheritdoc} + */ + public static function fromJsonString(?string $data = null, int $status = 200, array $headers = []) + { + return new static($data, $status, $headers, 0, true); } /** diff --git a/vendor/laravel/framework/src/Illuminate/Http/RedirectResponse.php b/vendor/laravel/framework/src/Illuminate/Http/RedirectResponse.php index 7f256a399..32bb5fcff 100755 --- a/vendor/laravel/framework/src/Illuminate/Http/RedirectResponse.php +++ b/vendor/laravel/framework/src/Illuminate/Http/RedirectResponse.php @@ -145,6 +145,21 @@ class RedirectResponse extends BaseRedirectResponse return $this; } + /** + * Parse the given errors into an appropriate value. + * + * @param \Illuminate\Contracts\Support\MessageProvider|array|string $provider + * @return \Illuminate\Support\MessageBag + */ + protected function parseErrors($provider) + { + if ($provider instanceof MessageProvider) { + return $provider->getMessageBag(); + } + + return new MessageBag((array) $provider); + } + /** * Add a fragment identifier to the URL. * @@ -167,21 +182,6 @@ class RedirectResponse extends BaseRedirectResponse return $this->setTargetUrl(Str::before($this->getTargetUrl(), '#')); } - /** - * Parse the given errors into an appropriate value. - * - * @param \Illuminate\Contracts\Support\MessageProvider|array|string $provider - * @return \Illuminate\Support\MessageBag - */ - protected function parseErrors($provider) - { - if ($provider instanceof MessageProvider) { - return $provider->getMessageBag(); - } - - return new MessageBag((array) $provider); - } - /** * Get the original response content. * diff --git a/vendor/laravel/framework/src/Illuminate/Http/Request.php b/vendor/laravel/framework/src/Illuminate/Http/Request.php index cf6b90cb1..06f143c60 100644 --- a/vendor/laravel/framework/src/Illuminate/Http/Request.php +++ b/vendor/laravel/framework/src/Illuminate/Http/Request.php @@ -142,7 +142,7 @@ class Request extends SymfonyRequest implements Arrayable, ArrayAccess { $pattern = trim($this->getPathInfo(), '/'); - return $pattern == '' ? '/' : $pattern; + return $pattern === '' ? '/' : $pattern; } /** @@ -212,7 +212,7 @@ class Request extends SymfonyRequest implements Arrayable, ArrayAccess } /** - * Determine if the current request URL and query string matches a pattern. + * Determine if the current request URL and query string match a pattern. * * @param mixed ...$patterns * @return bool @@ -241,7 +241,7 @@ class Request extends SymfonyRequest implements Arrayable, ArrayAccess } /** - * Determine if the request is the result of an PJAX call. + * Determine if the request is the result of a PJAX call. * * @return bool */ @@ -251,14 +251,14 @@ class Request extends SymfonyRequest implements Arrayable, ArrayAccess } /** - * Determine if the request is the result of an prefetch call. + * Determine if the request is the result of a prefetch call. * * @return bool */ public function prefetch() { - return strcasecmp($this->server->get('HTTP_X_MOZ'), 'prefetch') === 0 || - strcasecmp($this->headers->get('Purpose'), 'prefetch') === 0; + return strcasecmp($this->server->get('HTTP_X_MOZ') ?? '', 'prefetch') === 0 || + strcasecmp($this->headers->get('Purpose') ?? '', 'prefetch') === 0; } /** diff --git a/vendor/laravel/framework/src/Illuminate/Http/Resources/CollectsResources.php b/vendor/laravel/framework/src/Illuminate/Http/Resources/CollectsResources.php index a5531f7a0..00209dfc1 100644 --- a/vendor/laravel/framework/src/Illuminate/Http/Resources/CollectsResources.php +++ b/vendor/laravel/framework/src/Illuminate/Http/Resources/CollectsResources.php @@ -2,6 +2,7 @@ namespace Illuminate\Http\Resources; +use Illuminate\Pagination\AbstractCursorPaginator; use Illuminate\Pagination\AbstractPaginator; use Illuminate\Support\Collection; use Illuminate\Support\Str; @@ -30,7 +31,7 @@ trait CollectsResources ? $resource->mapInto($collects) : $resource->toBase(); - return $resource instanceof AbstractPaginator + return ($resource instanceof AbstractPaginator || $resource instanceof AbstractCursorPaginator) ? $resource->setCollection($this->collection) : $this->collection; } @@ -47,7 +48,8 @@ trait CollectsResources } if (Str::endsWith(class_basename($this), 'Collection') && - class_exists($class = Str::replaceLast('Collection', '', get_class($this)))) { + (class_exists($class = Str::replaceLast('Collection', '', get_class($this))) || + class_exists($class = Str::replaceLast('Collection', 'Resource', get_class($this))))) { return $class; } } diff --git a/vendor/laravel/framework/src/Illuminate/Http/Resources/Json/JsonResource.php b/vendor/laravel/framework/src/Illuminate/Http/Resources/Json/JsonResource.php index 808aa234d..0470104ea 100644 --- a/vendor/laravel/framework/src/Illuminate/Http/Resources/Json/JsonResource.php +++ b/vendor/laravel/framework/src/Illuminate/Http/Resources/Json/JsonResource.php @@ -42,7 +42,7 @@ class JsonResource implements ArrayAccess, JsonSerializable, Responsable, UrlRou /** * The "data" wrapper that should be applied. * - * @var string + * @var string|null */ public static $wrap = 'data'; @@ -69,7 +69,7 @@ class JsonResource implements ArrayAccess, JsonSerializable, Responsable, UrlRou } /** - * Create new anonymous resource collection. + * Create a new anonymous resource collection. * * @param mixed $resource * @return \Illuminate\Http\Resources\Json\AnonymousResourceCollection diff --git a/vendor/laravel/framework/src/Illuminate/Http/Resources/Json/ResourceCollection.php b/vendor/laravel/framework/src/Illuminate/Http/Resources/Json/ResourceCollection.php index 2931fd646..aa7de80f4 100644 --- a/vendor/laravel/framework/src/Illuminate/Http/Resources/Json/ResourceCollection.php +++ b/vendor/laravel/framework/src/Illuminate/Http/Resources/Json/ResourceCollection.php @@ -4,6 +4,7 @@ namespace Illuminate\Http\Resources\Json; use Countable; use Illuminate\Http\Resources\CollectsResources; +use Illuminate\Pagination\AbstractCursorPaginator; use Illuminate\Pagination\AbstractPaginator; use IteratorAggregate; @@ -108,7 +109,7 @@ class ResourceCollection extends JsonResource implements Countable, IteratorAggr */ public function toResponse($request) { - if ($this->resource instanceof AbstractPaginator) { + if ($this->resource instanceof AbstractPaginator || $this->resource instanceof AbstractCursorPaginator) { return $this->preparePaginatedResponse($request); } diff --git a/vendor/laravel/framework/src/Illuminate/Http/Resources/MergeValue.php b/vendor/laravel/framework/src/Illuminate/Http/Resources/MergeValue.php index ee557e8f3..fb6880fb7 100644 --- a/vendor/laravel/framework/src/Illuminate/Http/Resources/MergeValue.php +++ b/vendor/laravel/framework/src/Illuminate/Http/Resources/MergeValue.php @@ -15,7 +15,7 @@ class MergeValue public $data; /** - * Create new merge value instance. + * Create a new merge value instance. * * @param \Illuminate\Support\Collection|\JsonSerializable|array $data * @return void diff --git a/vendor/laravel/framework/src/Illuminate/Http/Response.php b/vendor/laravel/framework/src/Illuminate/Http/Response.php index f8bc37899..8599a8e53 100755 --- a/vendor/laravel/framework/src/Illuminate/Http/Response.php +++ b/vendor/laravel/framework/src/Illuminate/Http/Response.php @@ -7,6 +7,7 @@ use Illuminate\Contracts\Support\Arrayable; use Illuminate\Contracts\Support\Jsonable; use Illuminate\Contracts\Support\Renderable; use Illuminate\Support\Traits\Macroable; +use InvalidArgumentException; use JsonSerializable; use Symfony\Component\HttpFoundation\Response as SymfonyResponse; use Symfony\Component\HttpFoundation\ResponseHeaderBag; @@ -41,6 +42,8 @@ class Response extends SymfonyResponse * * @param mixed $content * @return $this + * + * @throws \InvalidArgumentException */ public function setContent($content) { @@ -53,6 +56,10 @@ class Response extends SymfonyResponse $this->header('Content-Type', 'application/json'); $content = $this->morphToJson($content); + + if ($content === false) { + throw new InvalidArgumentException(json_last_error_msg()); + } } // If this content implements the "Renderable" interface then we will call the diff --git a/vendor/laravel/framework/src/Illuminate/Http/ResponseTrait.php b/vendor/laravel/framework/src/Illuminate/Http/ResponseTrait.php index 46936fb6c..a255bcf93 100644 --- a/vendor/laravel/framework/src/Illuminate/Http/ResponseTrait.php +++ b/vendor/laravel/framework/src/Illuminate/Http/ResponseTrait.php @@ -116,6 +116,25 @@ trait ResponseTrait return $this; } + /** + * Expire a cookie when sending the response. + * + * @param \Symfony\Component\HttpFoundation\Cookie|mixed $cookie + * @param string|null $path + * @param string|null $domain + * @return $this + */ + public function withoutCookie($cookie, $path = null, $domain = null) + { + if (is_string($cookie) && function_exists('cookie')) { + $cookie = cookie($cookie, null, -2628000, $path, $domain); + } + + $this->headers->setCookie($cookie); + + return $this; + } + /** * Get the callback of the response. * diff --git a/vendor/laravel/framework/src/Illuminate/Http/Testing/MimeType.php b/vendor/laravel/framework/src/Illuminate/Http/Testing/MimeType.php index aff03d4bb..d188a4be3 100644 --- a/vendor/laravel/framework/src/Illuminate/Http/Testing/MimeType.php +++ b/vendor/laravel/framework/src/Illuminate/Http/Testing/MimeType.php @@ -22,7 +22,7 @@ class MimeType public static function getMimeTypes() { if (self::$mime === null) { - self::$mime = new MimeTypes(); + self::$mime = new MimeTypes; } return self::$mime; diff --git a/vendor/laravel/framework/src/Illuminate/Http/UploadedFile.php b/vendor/laravel/framework/src/Illuminate/Http/UploadedFile.php index 4e9f6f65b..7779683e4 100644 --- a/vendor/laravel/framework/src/Illuminate/Http/UploadedFile.php +++ b/vendor/laravel/framework/src/Illuminate/Http/UploadedFile.php @@ -91,7 +91,7 @@ class UploadedFile extends SymfonyUploadedFile /** * Get the contents of the uploaded file. * - * @return bool|string + * @return false|string * * @throws \Illuminate\Contracts\Filesystem\FileNotFoundException */ diff --git a/vendor/laravel/framework/src/Illuminate/Http/composer.json b/vendor/laravel/framework/src/Illuminate/Http/composer.json index c85bcc734..8bf355434 100755 --- a/vendor/laravel/framework/src/Illuminate/Http/composer.json +++ b/vendor/laravel/framework/src/Illuminate/Http/composer.json @@ -14,13 +14,15 @@ } ], "require": { - "php": "^7.2.5|^8.0", + "php": "^7.3|^8.0", "ext-json": "*", - "illuminate/session": "^7.0", - "illuminate/support": "^7.0", - "symfony/http-foundation": "^5.0", - "symfony/http-kernel": "^5.0", - "symfony/mime": "^5.0" + "illuminate/collections": "^8.0", + "illuminate/macroable": "^8.0", + "illuminate/session": "^8.0", + "illuminate/support": "^8.0", + "symfony/http-foundation": "^5.1.4", + "symfony/http-kernel": "^5.1.4", + "symfony/mime": "^5.1.4" }, "autoload": { "psr-4": { @@ -29,11 +31,11 @@ }, "suggest": { "ext-gd": "Required to use Illuminate\\Http\\Testing\\FileFactory::image().", - "guzzlehttp/guzzle": "Required to use the HTTP Client (^6.3.1|^7.0.1)." + "guzzlehttp/guzzle": "Required to use the HTTP Client (^6.5.5|^7.0.1)." }, "extra": { "branch-alias": { - "dev-master": "7.x-dev" + "dev-master": "8.x-dev" } }, "config": { diff --git a/vendor/laravel/framework/src/Illuminate/Log/LogManager.php b/vendor/laravel/framework/src/Illuminate/Log/LogManager.php index ab9bf51a1..f5d0ac486 100644 --- a/vendor/laravel/framework/src/Illuminate/Log/LogManager.php +++ b/vendor/laravel/framework/src/Illuminate/Log/LogManager.php @@ -237,15 +237,23 @@ class LogManager implements LoggerInterface */ protected function createStackDriver(array $config) { + if (is_string($config['channels'])) { + $config['channels'] = explode(',', $config['channels']); + } + $handlers = collect($config['channels'])->flatMap(function ($channel) { return $this->channel($channel)->getHandlers(); })->all(); + $processors = collect($config['channels'])->flatMap(function ($channel) { + return $this->channel($channel)->getProcessors(); + })->all(); + if ($config['ignore_exceptions'] ?? false) { $handlers = [new WhatFailureGroupHandler($handlers)]; } - return new Monolog($this->parseChannel($config), $handlers); + return new Monolog($this->parseChannel($config), $handlers, $processors); } /** diff --git a/vendor/laravel/framework/src/Illuminate/Log/composer.json b/vendor/laravel/framework/src/Illuminate/Log/composer.json index 53ebba890..1fd148d9a 100755 --- a/vendor/laravel/framework/src/Illuminate/Log/composer.json +++ b/vendor/laravel/framework/src/Illuminate/Log/composer.json @@ -14,9 +14,9 @@ } ], "require": { - "php": "^7.2.5|^8.0", - "illuminate/contracts": "^7.0", - "illuminate/support": "^7.0", + "php": "^7.3|^8.0", + "illuminate/contracts": "^8.0", + "illuminate/support": "^8.0", "monolog/monolog": "^2.0" }, "autoload": { @@ -26,7 +26,7 @@ }, "extra": { "branch-alias": { - "dev-master": "7.x-dev" + "dev-master": "8.x-dev" } }, "config": { diff --git a/vendor/laravel/framework/src/Illuminate/Macroable/LICENSE.md b/vendor/laravel/framework/src/Illuminate/Macroable/LICENSE.md new file mode 100644 index 000000000..79810c848 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Macroable/LICENSE.md @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) Taylor Otwell + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vendor/laravel/framework/src/Illuminate/Support/Traits/Macroable.php b/vendor/laravel/framework/src/Illuminate/Macroable/Traits/Macroable.php similarity index 100% rename from vendor/laravel/framework/src/Illuminate/Support/Traits/Macroable.php rename to vendor/laravel/framework/src/Illuminate/Macroable/Traits/Macroable.php diff --git a/vendor/laravel/framework/src/Illuminate/Macroable/composer.json b/vendor/laravel/framework/src/Illuminate/Macroable/composer.json new file mode 100644 index 000000000..dfa5c62be --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Macroable/composer.json @@ -0,0 +1,33 @@ +{ + "name": "illuminate/macroable", + "description": "The Illuminate Macroable package.", + "license": "MIT", + "homepage": "https://laravel.com", + "support": { + "issues": "https://github.com/laravel/framework/issues", + "source": "https://github.com/laravel/framework" + }, + "authors": [ + { + "name": "Taylor Otwell", + "email": "taylor@laravel.com" + } + ], + "require": { + "php": "^7.3|^8.0" + }, + "autoload": { + "psr-4": { + "Illuminate\\Support\\": "" + } + }, + "extra": { + "branch-alias": { + "dev-master": "8.x-dev" + } + }, + "config": { + "sort-packages": true + }, + "minimum-stability": "dev" +} diff --git a/vendor/laravel/framework/src/Illuminate/Mail/MailManager.php b/vendor/laravel/framework/src/Illuminate/Mail/MailManager.php index 4c70e9a12..036a0d3c0 100644 --- a/vendor/laravel/framework/src/Illuminate/Mail/MailManager.php +++ b/vendor/laravel/framework/src/Illuminate/Mail/MailManager.php @@ -63,7 +63,7 @@ class MailManager implements FactoryContract * Get a mailer instance by name. * * @param string|null $name - * @return \Illuminate\Mail\Mailer + * @return \Illuminate\Contracts\Mail\Mailer */ public function mailer($name = null) { @@ -156,6 +156,8 @@ class MailManager implements FactoryContract * * @param array $config * @return \Swift_Transport + * + * @throws \InvalidArgumentException */ public function createTransport(array $config) { @@ -168,7 +170,7 @@ class MailManager implements FactoryContract return call_user_func($this->customCreators[$transport], $config); } - if (trim($transport) === '' || ! method_exists($this, $method = 'create'.ucfirst($transport).'Transport')) { + if (trim($transport ?? '') === '' || ! method_exists($this, $method = 'create'.ucfirst($transport).'Transport')) { throw new InvalidArgumentException("Unsupported mail transport [{$transport}]."); } @@ -327,10 +329,15 @@ class MailManager implements FactoryContract */ protected function createPostmarkTransport(array $config) { + $headers = isset($config['message_stream_id']) ? [ + 'X-PM-Message-Stream' => $config['message_stream_id'], + ] : []; + return tap(new PostmarkTransport( - $config['token'] ?? $this->app['config']->get('services.postmark.token') + $config['token'] ?? $this->app['config']->get('services.postmark.token'), + $headers ), function ($transport) { - $transport->registerPlugin(new ThrowExceptionOnFailurePlugin()); + $transport->registerPlugin(new ThrowExceptionOnFailurePlugin); }); } @@ -440,6 +447,19 @@ class MailManager implements FactoryContract $this->app['config']['mail.default'] = $name; } + /** + * Disconnect the given mailer and remove from local cache. + * + * @param string|null $name + * @return void + */ + public function purge($name = null) + { + $name = $name ?: $this->getDefaultDriver(); + + unset($this->mailers[$name]); + } + /** * Register a custom transport creator Closure. * @@ -454,6 +474,41 @@ class MailManager implements FactoryContract return $this; } + /** + * Get the application instance used by the manager. + * + * @return \Illuminate\Contracts\Foundation\Application + */ + public function getApplication() + { + return $this->app; + } + + /** + * Set the application instance used by the manager. + * + * @param \Illuminate\Contracts\Foundation\Application $app + * @return $this + */ + public function setApplication($app) + { + $this->app = $app; + + return $this; + } + + /** + * Forget all of the resolved mailer instances. + * + * @return $this + */ + public function forgetMailers() + { + $this->mailers = []; + + return $this; + } + /** * Dynamically call the default driver instance. * diff --git a/vendor/laravel/framework/src/Illuminate/Mail/Mailable.php b/vendor/laravel/framework/src/Illuminate/Mail/Mailable.php index 6876ba487..903bd5f5f 100644 --- a/vendor/laravel/framework/src/Illuminate/Mail/Mailable.php +++ b/vendor/laravel/framework/src/Illuminate/Mail/Mailable.php @@ -7,12 +7,14 @@ use Illuminate\Contracts\Filesystem\Factory as FilesystemFactory; use Illuminate\Contracts\Mail\Factory as MailFactory; use Illuminate\Contracts\Mail\Mailable as MailableContract; use Illuminate\Contracts\Queue\Factory as Queue; +use Illuminate\Contracts\Support\Htmlable; use Illuminate\Contracts\Support\Renderable; use Illuminate\Support\Collection; use Illuminate\Support\HtmlString; use Illuminate\Support\Str; use Illuminate\Support\Traits\ForwardsCalls; use Illuminate\Support\Traits\Localizable; +use PHPUnit\Framework\Assert as PHPUnit; use ReflectionClass; use ReflectionProperty; @@ -146,6 +148,13 @@ class Mailable implements MailableContract, Renderable */ public $mailer; + /** + * The rendered mailable views for testing / assertions. + * + * @var array + */ + protected $assertionableRenderStrings; + /** * The callback that should be invoked while building the view data. * @@ -161,7 +170,7 @@ class Mailable implements MailableContract, Renderable */ public function send($mailer) { - return $this->withLocale($this->locale, function () use ($mailer) { + $this->withLocale($this->locale, function () use ($mailer) { Container::getInstance()->call([$this, 'build']); $mailer = $mailer instanceof MailFactory @@ -844,6 +853,106 @@ class Mailable implements MailableContract, Renderable return $this; } + /** + * Assert that the given text is present in the HTML email body. + * + * @param string $string + * @return void + */ + public function assertSeeInHtml($string) + { + [$html, $text] = $this->renderForAssertions(); + + PHPUnit::assertTrue( + Str::contains($html, $string), + "Did not see expected text [{$string}] within email body." + ); + } + + /** + * Assert that the given text is not present in the HTML email body. + * + * @param string $string + * @return void + */ + public function assertDontSeeInHtml($string) + { + [$html, $text] = $this->renderForAssertions(); + + PHPUnit::assertFalse( + Str::contains($html, $string), + "Saw unexpected text [{$string}] within email body." + ); + } + + /** + * Assert that the given text is present in the plain-text email body. + * + * @param string $string + * @return void + */ + public function assertSeeInText($string) + { + [$html, $text] = $this->renderForAssertions(); + + PHPUnit::assertTrue( + Str::contains($text, $string), + "Did not see expected text [{$string}] within text email body." + ); + } + + /** + * Assert that the given text is not present in the plain-text email body. + * + * @param string $string + * @return void + */ + public function assertDontSeeInText($string) + { + [$html, $text] = $this->renderForAssertions(); + + PHPUnit::assertFalse( + Str::contains($text, $string), + "Saw unexpected text [{$string}] within text email body." + ); + } + + /** + * Render the HTML and plain-text version of the mailable into views for assertions. + * + * @return array + * + * @throws \ReflectionException + */ + protected function renderForAssertions() + { + if ($this->assertionableRenderStrings) { + return $this->assertionableRenderStrings; + } + + return $this->assertionableRenderStrings = $this->withLocale($this->locale, function () { + Container::getInstance()->call([$this, 'build']); + + $html = Container::getInstance()->make('mailer')->render( + $view = $this->buildView(), $this->buildViewData() + ); + + if (is_array($view) && isset($view[1])) { + $text = $view[1]; + } + + $text = $text ?? $view['text'] ?? ''; + + if (! empty($text) && ! $text instanceof Htmlable) { + $text = Container::getInstance()->make('mailer')->render( + $text, $this->buildViewData() + ); + } + + return [(string) $html, (string) $text]; + }); + } + /** * Set the name of the mailer that should send the message. * diff --git a/vendor/laravel/framework/src/Illuminate/Mail/Mailer.php b/vendor/laravel/framework/src/Illuminate/Mail/Mailer.php index 668d68baa..128f211f7 100755 --- a/vendor/laravel/framework/src/Illuminate/Mail/Mailer.php +++ b/vendor/laravel/framework/src/Illuminate/Mail/Mailer.php @@ -197,7 +197,7 @@ class Mailer implements MailerContract, MailQueueContract */ public function html($html, $callback) { - return $this->send(['html' => new HtmlString($html)], [], $callback); + $this->send(['html' => new HtmlString($html)], [], $callback); } /** @@ -209,7 +209,7 @@ class Mailer implements MailerContract, MailQueueContract */ public function raw($text, $callback) { - return $this->send(['raw' => $text], [], $callback); + $this->send(['raw' => $text], [], $callback); } /** @@ -222,7 +222,7 @@ class Mailer implements MailerContract, MailQueueContract */ public function plain($view, array $data, $callback) { - return $this->send(['text' => $view], $data, $callback); + $this->send(['text' => $view], $data, $callback); } /** diff --git a/vendor/laravel/framework/src/Illuminate/Mail/Markdown.php b/vendor/laravel/framework/src/Illuminate/Mail/Markdown.php index 65b6bdeb9..9a1706d38 100644 --- a/vendor/laravel/framework/src/Illuminate/Mail/Markdown.php +++ b/vendor/laravel/framework/src/Illuminate/Mail/Markdown.php @@ -63,9 +63,13 @@ class Markdown 'mail', $this->htmlComponentPaths() )->make($view, $data)->render(); - $theme = Str::contains($this->theme, '::') - ? $this->theme - : 'mail::themes.'.$this->theme; + if ($this->view->exists($customTheme = Str::start($this->theme, 'mail.'))) { + $theme = $customTheme; + } else { + $theme = Str::contains($this->theme, '::') + ? $this->theme + : 'mail::themes.'.$this->theme; + } return new HtmlString(($inliner ?: new CssToInlineStyles)->convert( $contents, $this->view->make($theme, $data)->render() @@ -170,4 +174,14 @@ class Markdown return $this; } + + /** + * Get the theme currently being used by the renderer. + * + * @return string + */ + public function getTheme() + { + return $this->theme; + } } diff --git a/vendor/laravel/framework/src/Illuminate/Mail/Message.php b/vendor/laravel/framework/src/Illuminate/Mail/Message.php index d701fba9f..cab6c026d 100755 --- a/vendor/laravel/framework/src/Illuminate/Mail/Message.php +++ b/vendor/laravel/framework/src/Illuminate/Mail/Message.php @@ -137,7 +137,7 @@ class Message } /** - * Add a reply to address to the message. + * Add a "reply to" address to the message. * * @param string|array $address * @param string|null $name diff --git a/vendor/laravel/framework/src/Illuminate/Mail/PendingMail.php b/vendor/laravel/framework/src/Illuminate/Mail/PendingMail.php index d040f7906..10d76cb6a 100644 --- a/vendor/laravel/framework/src/Illuminate/Mail/PendingMail.php +++ b/vendor/laravel/framework/src/Illuminate/Mail/PendingMail.php @@ -114,23 +114,11 @@ class PendingMail * Send a new mailable message instance. * * @param \Illuminate\Contracts\Mail\Mailable $mailable - * @return mixed + * @return void */ public function send(MailableContract $mailable) { - return $this->mailer->send($this->fill($mailable)); - } - - /** - * Send a mailable message immediately. - * - * @param \Illuminate\Contracts\Mail\Mailable $mailable - * @return mixed - * @deprecated Use send() instead. - */ - public function sendNow(MailableContract $mailable) - { - return $this->mailer->send($this->fill($mailable)); + $this->mailer->send($this->fill($mailable)); } /** diff --git a/vendor/laravel/framework/src/Illuminate/Mail/SendQueuedMailable.php b/vendor/laravel/framework/src/Illuminate/Mail/SendQueuedMailable.php index 0747a884a..1009789b4 100644 --- a/vendor/laravel/framework/src/Illuminate/Mail/SendQueuedMailable.php +++ b/vendor/laravel/framework/src/Illuminate/Mail/SendQueuedMailable.php @@ -2,11 +2,15 @@ namespace Illuminate\Mail; +use Illuminate\Bus\Queueable; use Illuminate\Contracts\Mail\Factory as MailFactory; use Illuminate\Contracts\Mail\Mailable as MailableContract; +use Illuminate\Contracts\Queue\ShouldBeEncrypted; class SendQueuedMailable { + use Queueable; + /** * The mailable message instance. * @@ -28,6 +32,13 @@ class SendQueuedMailable */ public $timeout; + /** + * Indicates if the job should be encrypted. + * + * @var bool + */ + public $shouldBeEncrypted = false; + /** * Create a new job instance. * @@ -39,6 +50,8 @@ class SendQueuedMailable $this->mailable = $mailable; $this->tries = property_exists($mailable, 'tries') ? $mailable->tries : null; $this->timeout = property_exists($mailable, 'timeout') ? $mailable->timeout : null; + $this->afterCommit = property_exists($mailable, 'afterCommit') ? $mailable->afterCommit : null; + $this->shouldBeEncrypted = $mailable instanceof ShouldBeEncrypted; } /** @@ -76,17 +89,17 @@ class SendQueuedMailable } /** - * Get the retry delay for the mailable object. + * Get the number of seconds before a released mailable will be available. * * @return mixed */ - public function retryAfter() + public function backoff() { - if (! method_exists($this->mailable, 'retryAfter') && ! isset($this->mailable->retryAfter)) { + if (! method_exists($this->mailable, 'backoff') && ! isset($this->mailable->backoff)) { return; } - return $this->mailable->retryAfter ?? $this->mailable->retryAfter(); + return $this->mailable->backoff ?? $this->mailable->backoff(); } /** diff --git a/vendor/laravel/framework/src/Illuminate/Mail/Transport/MailgunTransport.php b/vendor/laravel/framework/src/Illuminate/Mail/Transport/MailgunTransport.php index 195c00032..1c862b1a7 100644 --- a/vendor/laravel/framework/src/Illuminate/Mail/Transport/MailgunTransport.php +++ b/vendor/laravel/framework/src/Illuminate/Mail/Transport/MailgunTransport.php @@ -72,9 +72,10 @@ class MailgunTransport extends Transport $this->payload($message, $to) ); - $message->getHeaders()->addTextHeader( - 'X-Mailgun-Message-ID', $this->getMessageId($response) - ); + $messageId = $this->getMessageId($response); + + $message->getHeaders()->addTextHeader('X-Message-ID', $messageId); + $message->getHeaders()->addTextHeader('X-Mailgun-Message-ID', $messageId); $message->setBcc($bcc); diff --git a/vendor/laravel/framework/src/Illuminate/Mail/Transport/SesTransport.php b/vendor/laravel/framework/src/Illuminate/Mail/Transport/SesTransport.php index 0dc8584a4..76eb2a8a0 100644 --- a/vendor/laravel/framework/src/Illuminate/Mail/Transport/SesTransport.php +++ b/vendor/laravel/framework/src/Illuminate/Mail/Transport/SesTransport.php @@ -52,7 +52,10 @@ class SesTransport extends Transport ) ); - $message->getHeaders()->addTextHeader('X-SES-Message-ID', $result->get('MessageId')); + $messageId = $result->get('MessageId'); + + $message->getHeaders()->addTextHeader('X-Message-ID', $messageId); + $message->getHeaders()->addTextHeader('X-SES-Message-ID', $messageId); $this->sendPerformed($message); diff --git a/vendor/laravel/framework/src/Illuminate/Mail/composer.json b/vendor/laravel/framework/src/Illuminate/Mail/composer.json index 0eb541fac..433271509 100755 --- a/vendor/laravel/framework/src/Illuminate/Mail/composer.json +++ b/vendor/laravel/framework/src/Illuminate/Mail/composer.json @@ -14,11 +14,13 @@ } ], "require": { - "php": "^7.2.5|^8.0", + "php": "^7.3|^8.0", "ext-json": "*", - "illuminate/container": "^7.0", - "illuminate/contracts": "^7.0", - "illuminate/support": "^7.0", + "illuminate/collections": "^8.0", + "illuminate/container": "^8.0", + "illuminate/contracts": "^8.0", + "illuminate/macroable": "^8.0", + "illuminate/support": "^8.0", "league/commonmark": "^1.3", "psr/log": "^1.0", "swiftmailer/swiftmailer": "^6.0", @@ -31,12 +33,12 @@ }, "extra": { "branch-alias": { - "dev-master": "7.x-dev" + "dev-master": "8.x-dev" } }, "suggest": { "aws/aws-sdk-php": "Required to use the SES mail driver (^3.155).", - "guzzlehttp/guzzle": "Required to use the Mailgun mail driver (^6.3.1|^7.0.1).", + "guzzlehttp/guzzle": "Required to use the Mailgun mail driver (^6.5.5|^7.0.1).", "wildbit/swiftmailer-postmark": "Required to use Postmark mail driver (^3.0)." }, "config": { diff --git a/vendor/laravel/framework/src/Illuminate/Mail/resources/views/html/layout.blade.php b/vendor/laravel/framework/src/Illuminate/Mail/resources/views/html/layout.blade.php index 02a54e2da..21d349b39 100644 --- a/vendor/laravel/framework/src/Illuminate/Mail/resources/views/html/layout.blade.php +++ b/vendor/laravel/framework/src/Illuminate/Mail/resources/views/html/layout.blade.php @@ -3,8 +3,8 @@ - - + + + + diff --git a/vendor/laravel/framework/src/Illuminate/Mail/resources/views/html/themes/default.css b/vendor/laravel/framework/src/Illuminate/Mail/resources/views/html/themes/default.css index 350fb838f..2483b1168 100644 --- a/vendor/laravel/framework/src/Illuminate/Mail/resources/views/html/themes/default.css +++ b/vendor/laravel/framework/src/Illuminate/Mail/resources/views/html/themes/default.css @@ -113,6 +113,7 @@ img { .logo { height: 75px; + max-height: 75px; width: 75px; } diff --git a/vendor/laravel/framework/src/Illuminate/Notifications/AnonymousNotifiable.php b/vendor/laravel/framework/src/Illuminate/Notifications/AnonymousNotifiable.php index eab959b7c..aa4d7bbc7 100644 --- a/vendor/laravel/framework/src/Illuminate/Notifications/AnonymousNotifiable.php +++ b/vendor/laravel/framework/src/Illuminate/Notifications/AnonymousNotifiable.php @@ -20,6 +20,8 @@ class AnonymousNotifiable * @param string $channel * @param mixed $route * @return $this + * + * @throws \InvalidArgumentException */ public function route($channel, $route) { diff --git a/vendor/laravel/framework/src/Illuminate/Notifications/ChannelManager.php b/vendor/laravel/framework/src/Illuminate/Notifications/ChannelManager.php index d2344ab68..8eb9c2510 100644 --- a/vendor/laravel/framework/src/Illuminate/Notifications/ChannelManager.php +++ b/vendor/laravel/framework/src/Illuminate/Notifications/ChannelManager.php @@ -34,7 +34,7 @@ class ChannelManager extends Manager implements DispatcherContract, FactoryContr */ public function send($notifiables, $notification) { - return (new NotificationSender( + (new NotificationSender( $this, $this->container->make(Bus::class), $this->container->make(Dispatcher::class), $this->locale) )->send($notifiables, $notification); } @@ -49,7 +49,7 @@ class ChannelManager extends Manager implements DispatcherContract, FactoryContr */ public function sendNow($notifiables, $notification, array $channels = null) { - return (new NotificationSender( + (new NotificationSender( $this, $this->container->make(Bus::class), $this->container->make(Dispatcher::class), $this->locale) )->sendNow($notifiables, $notification, $channels); } diff --git a/vendor/laravel/framework/src/Illuminate/Notifications/Channels/BroadcastChannel.php b/vendor/laravel/framework/src/Illuminate/Notifications/Channels/BroadcastChannel.php index d281b9b13..1389f49c6 100644 --- a/vendor/laravel/framework/src/Illuminate/Notifications/Channels/BroadcastChannel.php +++ b/vendor/laravel/framework/src/Illuminate/Notifications/Channels/BroadcastChannel.php @@ -18,7 +18,7 @@ class BroadcastChannel protected $events; /** - * Create a new database channel. + * Create a new broadcast channel. * * @param \Illuminate\Contracts\Events\Dispatcher $events * @return void diff --git a/vendor/laravel/framework/src/Illuminate/Notifications/DatabaseNotification.php b/vendor/laravel/framework/src/Illuminate/Notifications/DatabaseNotification.php index 0dfc7e530..14bc9d659 100644 --- a/vendor/laravel/framework/src/Illuminate/Notifications/DatabaseNotification.php +++ b/vendor/laravel/framework/src/Illuminate/Notifications/DatabaseNotification.php @@ -2,6 +2,7 @@ namespace Illuminate\Notifications; +use Illuminate\Database\Eloquent\Builder; use Illuminate\Database\Eloquent\Model; class DatabaseNotification extends Model @@ -98,6 +99,28 @@ class DatabaseNotification extends Model return $this->read_at === null; } + /** + * Scope a query to only include read notifications. + * + * @param \Illuminate\Database\Eloquent\Builder $query + * @return \Illuminate\Database\Eloquent\Builder + */ + public function scopeRead(Builder $query) + { + return $query->whereNotNull('read_at'); + } + + /** + * Scope a query to only include unread notifications. + * + * @param \Illuminate\Database\Eloquent\Builder $query + * @return \Illuminate\Database\Eloquent\Builder + */ + public function scopeUnread(Builder $query) + { + return $query->whereNull('read_at'); + } + /** * Create a new database notification collection instance. * diff --git a/vendor/laravel/framework/src/Illuminate/Notifications/Events/BroadcastNotificationCreated.php b/vendor/laravel/framework/src/Illuminate/Notifications/Events/BroadcastNotificationCreated.php index 77498ea39..249588527 100644 --- a/vendor/laravel/framework/src/Illuminate/Notifications/Events/BroadcastNotificationCreated.php +++ b/vendor/laravel/framework/src/Illuminate/Notifications/Events/BroadcastNotificationCreated.php @@ -92,6 +92,10 @@ class BroadcastNotificationCreated implements ShouldBroadcast */ public function broadcastWith() { + if (method_exists($this->notification, 'broadcastWith')) { + return $this->notification->broadcastWith(); + } + return array_merge($this->data, [ 'id' => $this->notification->id, 'type' => $this->broadcastType(), diff --git a/vendor/laravel/framework/src/Illuminate/Notifications/HasDatabaseNotifications.php b/vendor/laravel/framework/src/Illuminate/Notifications/HasDatabaseNotifications.php index 981d8e552..5f999da9a 100644 --- a/vendor/laravel/framework/src/Illuminate/Notifications/HasDatabaseNotifications.php +++ b/vendor/laravel/framework/src/Illuminate/Notifications/HasDatabaseNotifications.php @@ -21,7 +21,7 @@ trait HasDatabaseNotifications */ public function readNotifications() { - return $this->notifications()->whereNotNull('read_at'); + return $this->notifications()->read(); } /** @@ -31,6 +31,6 @@ trait HasDatabaseNotifications */ public function unreadNotifications() { - return $this->notifications()->whereNull('read_at'); + return $this->notifications()->unread(); } } diff --git a/vendor/laravel/framework/src/Illuminate/Notifications/Messages/MailMessage.php b/vendor/laravel/framework/src/Illuminate/Notifications/Messages/MailMessage.php index 08ee2f1f7..08e79d0fa 100644 --- a/vendor/laravel/framework/src/Illuminate/Notifications/Messages/MailMessage.php +++ b/vendor/laravel/framework/src/Illuminate/Notifications/Messages/MailMessage.php @@ -6,7 +6,6 @@ use Illuminate\Container\Container; use Illuminate\Contracts\Support\Arrayable; use Illuminate\Contracts\Support\Renderable; use Illuminate\Mail\Markdown; -use Traversable; class MailMessage extends SimpleMessage implements Renderable { @@ -297,9 +296,7 @@ class MailMessage extends SimpleMessage implements Renderable */ protected function arrayOfAddresses($address) { - return is_array($address) || - $address instanceof Arrayable || - $address instanceof Traversable; + return is_iterable($address) || $address instanceof Arrayable; } /** @@ -315,9 +312,10 @@ class MailMessage extends SimpleMessage implements Renderable ); } - return Container::getInstance() - ->make(Markdown::class) - ->render($this->markdown, $this->data()); + $markdown = Container::getInstance()->make(Markdown::class); + + return $markdown->theme($this->theme ?: $markdown->getTheme()) + ->render($this->markdown, $this->data()); } /** @@ -332,4 +330,42 @@ class MailMessage extends SimpleMessage implements Renderable return $this; } + + /** + * Apply the callback's message changes if the given "value" is true. + * + * @param mixed $value + * @param callable $callback + * @param callable|null $default + * @return mixed|$this + */ + public function when($value, $callback, $default = null) + { + if ($value) { + return $callback($this, $value) ?: $this; + } elseif ($default) { + return $default($this, $value) ?: $this; + } + + return $this; + } + + /** + * Apply the callback's message changes if the given "value" is false. + * + * @param mixed $value + * @param callable $callback + * @param callable|null $default + * @return mixed|$this + */ + public function unless($value, $callback, $default = null) + { + if (! $value) { + return $callback($this, $value) ?: $this; + } elseif ($default) { + return $default($this, $value) ?: $this; + } + + return $this; + } } diff --git a/vendor/laravel/framework/src/Illuminate/Notifications/Messages/SimpleMessage.php b/vendor/laravel/framework/src/Illuminate/Notifications/Messages/SimpleMessage.php index f90b26e99..e532aa4bf 100644 --- a/vendor/laravel/framework/src/Illuminate/Notifications/Messages/SimpleMessage.php +++ b/vendor/laravel/framework/src/Illuminate/Notifications/Messages/SimpleMessage.php @@ -192,7 +192,7 @@ class SimpleMessage return implode(' ', array_map('trim', $line)); } - return trim(implode(' ', array_map('trim', preg_split('/\\r\\n|\\r|\\n/', $line)))); + return trim(implode(' ', array_map('trim', preg_split('/\\r\\n|\\r|\\n/', $line ?? '')))); } /** @@ -239,7 +239,7 @@ class SimpleMessage 'outroLines' => $this->outroLines, 'actionText' => $this->actionText, 'actionUrl' => $this->actionUrl, - 'displayableActionUrl' => str_replace(['mailto:', 'tel:'], '', $this->actionUrl), + 'displayableActionUrl' => str_replace(['mailto:', 'tel:'], '', $this->actionUrl ?? ''), ]; } } diff --git a/vendor/laravel/framework/src/Illuminate/Notifications/NotificationSender.php b/vendor/laravel/framework/src/Illuminate/Notifications/NotificationSender.php index 15128a15e..aff36c7a5 100644 --- a/vendor/laravel/framework/src/Illuminate/Notifications/NotificationSender.php +++ b/vendor/laravel/framework/src/Illuminate/Notifications/NotificationSender.php @@ -76,7 +76,7 @@ class NotificationSender return $this->queueNotification($notifiables, $notification); } - return $this->sendNow($notifiables, $notification); + $this->sendNow($notifiables, $notification); } /** @@ -202,7 +202,10 @@ class NotificationSender (new SendQueuedNotifications($notifiable, $notification, [$channel])) ->onConnection($notification->connection) ->onQueue($queue) - ->delay($notification->delay) + ->delay(is_array($notification->delay) ? + ($notification->delay[$channel] ?? null) + : $notification->delay + ) ->through( array_merge( method_exists($notification, 'middleware') ? $notification->middleware() : [], diff --git a/vendor/laravel/framework/src/Illuminate/Notifications/SendQueuedNotifications.php b/vendor/laravel/framework/src/Illuminate/Notifications/SendQueuedNotifications.php index 7fc300e50..d83c8906e 100644 --- a/vendor/laravel/framework/src/Illuminate/Notifications/SendQueuedNotifications.php +++ b/vendor/laravel/framework/src/Illuminate/Notifications/SendQueuedNotifications.php @@ -3,6 +3,7 @@ namespace Illuminate\Notifications; use Illuminate\Bus\Queueable; +use Illuminate\Contracts\Queue\ShouldBeEncrypted; use Illuminate\Contracts\Queue\ShouldQueue; use Illuminate\Database\Eloquent\Collection as EloquentCollection; use Illuminate\Database\Eloquent\Model; @@ -49,6 +50,13 @@ class SendQueuedNotifications implements ShouldQueue */ public $timeout; + /** + * Indicates if the job should be encrypted. + * + * @var bool + */ + public $shouldBeEncrypted = false; + /** * Create a new job instance. * @@ -64,6 +72,8 @@ class SendQueuedNotifications implements ShouldQueue $this->notifiables = $this->wrapNotifiables($notifiables); $this->tries = property_exists($notification, 'tries') ? $notification->tries : null; $this->timeout = property_exists($notification, 'timeout') ? $notification->timeout : null; + $this->afterCommit = property_exists($notification, 'afterCommit') ? $notification->afterCommit : null; + $this->shouldBeEncrypted = $notification instanceof ShouldBeEncrypted; } /** @@ -118,17 +128,17 @@ class SendQueuedNotifications implements ShouldQueue } /** - * Get the retry delay for the notification. + * Get the number of seconds before a released notification will be available. * * @return mixed */ - public function retryAfter() + public function backoff() { - if (! method_exists($this->notification, 'retryAfter') && ! isset($this->notification->retryAfter)) { + if (! method_exists($this->notification, 'backoff') && ! isset($this->notification->backoff)) { return; } - return $this->notification->retryAfter ?? $this->notification->retryAfter(); + return $this->notification->backoff ?? $this->notification->backoff(); } /** @@ -138,11 +148,11 @@ class SendQueuedNotifications implements ShouldQueue */ public function retryUntil() { - if (! method_exists($this->notification, 'retryUntil') && ! isset($this->notification->timeoutAt)) { + if (! method_exists($this->notification, 'retryUntil') && ! isset($this->notification->retryUntil)) { return; } - return $this->notification->timeoutAt ?? $this->notification->retryUntil(); + return $this->notification->retryUntil ?? $this->notification->retryUntil(); } /** diff --git a/vendor/laravel/framework/src/Illuminate/Notifications/composer.json b/vendor/laravel/framework/src/Illuminate/Notifications/composer.json index 183064770..1bc673a22 100644 --- a/vendor/laravel/framework/src/Illuminate/Notifications/composer.json +++ b/vendor/laravel/framework/src/Illuminate/Notifications/composer.json @@ -14,15 +14,16 @@ } ], "require": { - "php": "^7.2.5|^8.0", - "illuminate/broadcasting": "^7.0", - "illuminate/bus": "^7.0", - "illuminate/container": "^7.0", - "illuminate/contracts": "^7.0", - "illuminate/filesystem": "^7.0", - "illuminate/mail": "^7.0", - "illuminate/queue": "^7.0", - "illuminate/support": "^7.0" + "php": "^7.3|^8.0", + "illuminate/broadcasting": "^8.0", + "illuminate/bus": "^8.0", + "illuminate/collections": "^8.0", + "illuminate/container": "^8.0", + "illuminate/contracts": "^8.0", + "illuminate/filesystem": "^8.0", + "illuminate/mail": "^8.0", + "illuminate/queue": "^8.0", + "illuminate/support": "^8.0" }, "autoload": { "psr-4": { @@ -31,11 +32,11 @@ }, "extra": { "branch-alias": { - "dev-master": "7.x-dev" + "dev-master": "8.x-dev" } }, "suggest": { - "illuminate/database": "Required to use the database transport (^7.0)." + "illuminate/database": "Required to use the database transport (^8.0)." }, "config": { "sort-packages": true diff --git a/vendor/laravel/framework/src/Illuminate/Pagination/AbstractCursorPaginator.php b/vendor/laravel/framework/src/Illuminate/Pagination/AbstractCursorPaginator.php new file mode 100644 index 000000000..49a9adc03 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Pagination/AbstractCursorPaginator.php @@ -0,0 +1,612 @@ +cursorName => $cursor->encode()]; + + if (count($this->query) > 0) { + $parameters = array_merge($this->query, $parameters); + } + + return $this->path() + .(Str::contains($this->path(), '?') ? '&' : '?') + .Arr::query($parameters) + .$this->buildFragment(); + } + + /** + * Get the URL for the previous page. + * + * @return string|null + */ + public function previousPageUrl() + { + if (is_null($previousCursor = $this->previousCursor())) { + return null; + } + + return $this->url($previousCursor); + } + + /** + * The URL for the next page, or null. + * + * @return string|null + */ + public function nextPageUrl() + { + if (is_null($nextCursor = $this->nextCursor())) { + return null; + } + + return $this->url($nextCursor); + } + + /** + * Get the "cursor" that points to the previous set of items. + * + * @return \Illuminate\Pagination\Cursor|null + */ + public function previousCursor() + { + if (is_null($this->cursor) || + ($this->cursor->pointsToPreviousItems() && ! $this->hasMore)) { + return null; + } + + return $this->getCursorForItem($this->items->first(), false); + } + + /** + * Get the "cursor" that points to the next set of items. + * + * @return \Illuminate\Pagination\Cursor|null + */ + public function nextCursor() + { + if ((is_null($this->cursor) && ! $this->hasMore) || + (! is_null($this->cursor) && $this->cursor->pointsToNextItems() && ! $this->hasMore)) { + return null; + } + + return $this->getCursorForItem($this->items->last(), true); + } + + /** + * Get a cursor instance for the given item. + * + * @param \ArrayAccess|\stdClass $item + * @param bool $isNext + * @return \Illuminate\Pagination\Cursor + */ + public function getCursorForItem($item, $isNext = true) + { + return new Cursor($this->getParametersForItem($item), $isNext); + } + + /** + * Get the cursor parameters for a given object. + * + * @param \ArrayAccess|\stdClass $item + * @return array + * + * @throws \Exception + */ + public function getParametersForItem($item) + { + return collect($this->parameters) + ->flip() + ->map(function ($_, $parameterName) use ($item) { + if ($item instanceof ArrayAccess || is_array($item)) { + return $item[$parameterName] ?? $item[Str::afterLast($parameterName, '.')]; + } elseif (is_object($item)) { + return $item->{$parameterName} ?? $item->{Str::afterLast($parameterName, '.')}; + } + + throw new Exception('Only arrays and objects are supported when cursor paginating items.'); + })->toArray(); + } + + /** + * Get / set the URL fragment to be appended to URLs. + * + * @param string|null $fragment + * @return $this|string|null + */ + public function fragment($fragment = null) + { + if (is_null($fragment)) { + return $this->fragment; + } + + $this->fragment = $fragment; + + return $this; + } + + /** + * Add a set of query string values to the paginator. + * + * @param array|string|null $key + * @param string|null $value + * @return $this + */ + public function appends($key, $value = null) + { + if (is_null($key)) { + return $this; + } + + if (is_array($key)) { + return $this->appendArray($key); + } + + return $this->addQuery($key, $value); + } + + /** + * Add an array of query string values. + * + * @param array $keys + * @return $this + */ + protected function appendArray(array $keys) + { + foreach ($keys as $key => $value) { + $this->addQuery($key, $value); + } + + return $this; + } + + /** + * Add all current query string values to the paginator. + * + * @return $this + */ + public function withQueryString() + { + if (! is_null($query = Paginator::resolveQueryString())) { + return $this->appends($query); + } + + return $this; + } + + /** + * Add a query string value to the paginator. + * + * @param string $key + * @param string $value + * @return $this + */ + protected function addQuery($key, $value) + { + if ($key !== $this->cursorName) { + $this->query[$key] = $value; + } + + return $this; + } + + /** + * Build the full fragment portion of a URL. + * + * @return string + */ + protected function buildFragment() + { + return $this->fragment ? '#'.$this->fragment : ''; + } + + /** + * Load a set of relationships onto the mixed relationship collection. + * + * @param string $relation + * @param array $relations + * @return $this + */ + public function loadMorph($relation, $relations) + { + $this->getCollection()->loadMorph($relation, $relations); + + return $this; + } + + /** + * Load a set of relationship counts onto the mixed relationship collection. + * + * @param string $relation + * @param array $relations + * @return $this + */ + public function loadMorphCount($relation, $relations) + { + $this->getCollection()->loadMorphCount($relation, $relations); + + return $this; + } + + /** + * Get the slice of items being paginated. + * + * @return array + */ + public function items() + { + return $this->items->all(); + } + + /** + * Transform each item in the slice of items using a callback. + * + * @param callable $callback + * @return $this + */ + public function through(callable $callback) + { + $this->items->transform($callback); + + return $this; + } + + /** + * Get the number of items shown per page. + * + * @return int + */ + public function perPage() + { + return $this->perPage; + } + + /** + * Get the current cursor being paginated. + * + * @return \Illuminate\Pagination\Cursor|null + */ + public function cursor() + { + return $this->cursor; + } + + /** + * Get the query string variable used to store the cursor. + * + * @return string + */ + public function getCursorName() + { + return $this->cursorName; + } + + /** + * Set the query string variable used to store the cursor. + * + * @param string $name + * @return $this + */ + public function setCursorName($name) + { + $this->cursorName = $name; + + return $this; + } + + /** + * Set the base path to assign to all URLs. + * + * @param string $path + * @return $this + */ + public function withPath($path) + { + return $this->setPath($path); + } + + /** + * Set the base path to assign to all URLs. + * + * @param string $path + * @return $this + */ + public function setPath($path) + { + $this->path = $path; + + return $this; + } + + /** + * Get the base path for paginator generated URLs. + * + * @return string|null + */ + public function path() + { + return $this->path; + } + + /** + * Resolve the current cursor or return the default value. + * + * @param string $cursorName + * @return \Illuminate\Pagination\Cursor|null + */ + public static function resolveCurrentCursor($cursorName = 'cursor', $default = null) + { + if (isset(static::$currentCursorResolver)) { + return call_user_func(static::$currentCursorResolver, $cursorName); + } + + return $default; + } + + /** + * Set the current cursor resolver callback. + * + * @param \Closure $resolver + * @return void + */ + public static function currentCursorResolver(Closure $resolver) + { + static::$currentCursorResolver = $resolver; + } + + /** + * Get an instance of the view factory from the resolver. + * + * @return \Illuminate\Contracts\View\Factory + */ + public static function viewFactory() + { + return Paginator::viewFactory(); + } + + /** + * Get an iterator for the items. + * + * @return \ArrayIterator + */ + public function getIterator() + { + return $this->items->getIterator(); + } + + /** + * Determine if the list of items is empty. + * + * @return bool + */ + public function isEmpty() + { + return $this->items->isEmpty(); + } + + /** + * Determine if the list of items is not empty. + * + * @return bool + */ + public function isNotEmpty() + { + return $this->items->isNotEmpty(); + } + + /** + * Get the number of items for the current page. + * + * @return int + */ + public function count() + { + return $this->items->count(); + } + + /** + * Get the paginator's underlying collection. + * + * @return \Illuminate\Support\Collection + */ + public function getCollection() + { + return $this->items; + } + + /** + * Set the paginator's underlying collection. + * + * @param \Illuminate\Support\Collection $collection + * @return $this + */ + public function setCollection(Collection $collection) + { + $this->items = $collection; + + return $this; + } + + /** + * Get the paginator options. + * + * @return array + */ + public function getOptions() + { + return $this->options; + } + + /** + * Determine if the given item exists. + * + * @param mixed $key + * @return bool + */ + public function offsetExists($key) + { + return $this->items->has($key); + } + + /** + * Get the item at the given offset. + * + * @param mixed $key + * @return mixed + */ + public function offsetGet($key) + { + return $this->items->get($key); + } + + /** + * Set the item at the given offset. + * + * @param mixed $key + * @param mixed $value + * @return void + */ + public function offsetSet($key, $value) + { + $this->items->put($key, $value); + } + + /** + * Unset the item at the given key. + * + * @param mixed $key + * @return void + */ + public function offsetUnset($key) + { + $this->items->forget($key); + } + + /** + * Render the contents of the paginator to HTML. + * + * @return string + */ + public function toHtml() + { + return (string) $this->render(); + } + + /** + * Make dynamic calls into the collection. + * + * @param string $method + * @param array $parameters + * @return mixed + */ + public function __call($method, $parameters) + { + return $this->forwardCallTo($this->getCollection(), $method, $parameters); + } + + /** + * Render the contents of the paginator when casting to a string. + * + * @return string + */ + public function __toString() + { + return (string) $this->render(); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Pagination/AbstractPaginator.php b/vendor/laravel/framework/src/Illuminate/Pagination/AbstractPaginator.php index c29faeac5..9684afdff 100644 --- a/vendor/laravel/framework/src/Illuminate/Pagination/AbstractPaginator.php +++ b/vendor/laravel/framework/src/Illuminate/Pagination/AbstractPaginator.php @@ -112,14 +112,14 @@ abstract class AbstractPaginator implements Htmlable * * @var string */ - public static $defaultView = 'pagination::bootstrap-4'; + public static $defaultView = 'pagination::tailwind'; /** * The default "simple" pagination view. * * @var string */ - public static $defaultSimpleView = 'pagination::simple-bootstrap-4'; + public static $defaultSimpleView = 'pagination::simple-tailwind'; /** * Determine if the given value is a valid page number. @@ -335,6 +335,19 @@ abstract class AbstractPaginator implements Htmlable return count($this->items) > 0 ? $this->firstItem() + $this->count() - 1 : null; } + /** + * Transform each item in the slice of items using a callback. + * + * @param callable $callback + * @return $this + */ + public function through(callable $callback) + { + $this->items->transform($callback); + + return $this; + } + /** * Get the number of items shown per page. * @@ -481,7 +494,7 @@ abstract class AbstractPaginator implements Htmlable public static function resolveCurrentPage($pageName = 'page', $default = 1) { if (isset(static::$currentPageResolver)) { - return call_user_func(static::$currentPageResolver, $pageName); + return (int) call_user_func(static::$currentPageResolver, $pageName); } return $default; @@ -498,6 +511,21 @@ abstract class AbstractPaginator implements Htmlable static::$currentPageResolver = $resolver; } + /** + * Resolve the query string or return the default value. + * + * @param string|array|null $default + * @return string + */ + public static function resolveQueryString($default = null) + { + if (isset(static::$queryStringResolver)) { + return (static::$queryStringResolver)(); + } + + return $default; + } + /** * Set with query string resolver callback. * @@ -563,6 +591,17 @@ abstract class AbstractPaginator implements Htmlable static::defaultSimpleView('pagination::simple-tailwind'); } + /** + * Indicate that Bootstrap 4 styling should be used for generated links. + * + * @return void + */ + public static function useBootstrap() + { + static::defaultView('pagination::bootstrap-4'); + static::defaultSimpleView('pagination::simple-bootstrap-4'); + } + /** * Indicate that Bootstrap 3 styling should be used for generated links. * @@ -715,7 +754,7 @@ abstract class AbstractPaginator implements Htmlable } /** - * Render the contents of the paginator when casting to string. + * Render the contents of the paginator when casting to a string. * * @return string */ diff --git a/vendor/laravel/framework/src/Illuminate/Pagination/Cursor.php b/vendor/laravel/framework/src/Illuminate/Pagination/Cursor.php new file mode 100644 index 000000000..e8edf6526 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Pagination/Cursor.php @@ -0,0 +1,132 @@ +parameters = $parameters; + $this->pointsToNextItems = $pointsToNextItems; + } + + /** + * Get the given parameter from the cursor. + * + * @param string $parameterName + * @return string|null + * + * @throws \UnexpectedValueException + */ + public function parameter(string $parameterName) + { + if (! array_key_exists($parameterName, $this->parameters)) { + throw new UnexpectedValueException("Unable to find parameter [{$parameterName}] in pagination item."); + } + + return $this->parameters[$parameterName]; + } + + /** + * Get the given parameters from the cursor. + * + * @param array $parameterNames + * @return array + */ + public function parameters(array $parameterNames) + { + return collect($parameterNames)->map(function ($parameterName) { + return $this->parameter($parameterName); + })->toArray(); + } + + /** + * Determine whether the cursor points to the next set of items. + * + * @return bool + */ + public function pointsToNextItems() + { + return $this->pointsToNextItems; + } + + /** + * Determine whether the cursor points to the previous set of items. + * + * @return bool + */ + public function pointsToPreviousItems() + { + return ! $this->pointsToNextItems; + } + + /** + * Get the array representation of the cursor. + * + * @return array + */ + public function toArray() + { + return array_merge($this->parameters, [ + '_pointsToNextItems' => $this->pointsToNextItems, + ]); + } + + /** + * Get the encoded string representation of the cursor to construct a URL. + * + * @return string + */ + public function encode() + { + return str_replace(['+', '/', '='], ['-', '_', ''], base64_encode(json_encode($this->toArray()))); + } + + /** + * Get a cursor instance from the encoded string representation. + * + * @param string|null $encodedString + * @return static|null + */ + public static function fromEncoded($encodedString) + { + if (is_null($encodedString) || ! is_string($encodedString)) { + return null; + } + + $parameters = json_decode(base64_decode(str_replace(['-', '_'], ['+', '/'], $encodedString)), true); + + if (json_last_error() !== JSON_ERROR_NONE) { + return null; + } + + $pointsToNextItems = $parameters['_pointsToNextItems']; + + unset($parameters['_pointsToNextItems']); + + return new static($parameters, $pointsToNextItems); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Pagination/CursorPaginationException.php b/vendor/laravel/framework/src/Illuminate/Pagination/CursorPaginationException.php new file mode 100644 index 000000000..710401751 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Pagination/CursorPaginationException.php @@ -0,0 +1,10 @@ +options = $options; + + foreach ($options as $key => $value) { + $this->{$key} = $value; + } + + $this->perPage = $perPage; + $this->cursor = $cursor; + $this->path = $this->path !== '/' ? rtrim($this->path, '/') : $this->path; + + $this->setItems($items); + } + + /** + * Set the items for the paginator. + * + * @param mixed $items + * @return void + */ + protected function setItems($items) + { + $this->items = $items instanceof Collection ? $items : Collection::make($items); + + $this->hasMore = $this->items->count() > $this->perPage; + + $this->items = $this->items->slice(0, $this->perPage); + + if (! is_null($this->cursor) && $this->cursor->pointsToPreviousItems()) { + $this->items = $this->items->reverse()->values(); + } + } + + /** + * Render the paginator using the given view. + * + * @param string|null $view + * @param array $data + * @return \Illuminate\Contracts\Support\Htmlable + */ + public function links($view = null, $data = []) + { + return $this->render($view, $data); + } + + /** + * Render the paginator using the given view. + * + * @param string|null $view + * @param array $data + * @return \Illuminate\Contracts\Support\Htmlable + */ + public function render($view = null, $data = []) + { + return static::viewFactory()->make($view ?: Paginator::$defaultSimpleView, array_merge($data, [ + 'paginator' => $this, + ])); + } + + /** + * Determine if there are more items in the data source. + * + * @return bool + */ + public function hasMorePages() + { + return (is_null($this->cursor) && $this->hasMore) || + (! is_null($this->cursor) && $this->cursor->pointsToNextItems() && $this->hasMore) || + (! is_null($this->cursor) && $this->cursor->pointsToPreviousItems()); + } + + /** + * Determine if there are enough items to split into multiple pages. + * + * @return bool + */ + public function hasPages() + { + return ! $this->onFirstPage() || $this->hasMorePages(); + } + + /** + * Determine if the paginator is on the first page. + * + * @return bool + */ + public function onFirstPage() + { + return is_null($this->cursor) || ($this->cursor->pointsToPreviousItems() && ! $this->hasMore); + } + + /** + * Get the instance as an array. + * + * @return array + */ + public function toArray() + { + return [ + 'data' => $this->items->toArray(), + 'path' => $this->path(), + 'per_page' => $this->perPage(), + 'next_page_url' => $this->nextPageUrl(), + 'prev_page_url' => $this->previousPageUrl(), + ]; + } + + /** + * Convert the object into something JSON serializable. + * + * @return array + */ + public function jsonSerialize() + { + return $this->toArray(); + } + + /** + * Convert the object to its JSON representation. + * + * @param int $options + * @return string + */ + public function toJson($options = 0) + { + return json_encode($this->jsonSerialize(), $options); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Pagination/LengthAwarePaginator.php b/vendor/laravel/framework/src/Illuminate/Pagination/LengthAwarePaginator.php index ba368cfe5..d1c6cc711 100644 --- a/vendor/laravel/framework/src/Illuminate/Pagination/LengthAwarePaginator.php +++ b/vendor/laravel/framework/src/Illuminate/Pagination/LengthAwarePaginator.php @@ -94,6 +94,36 @@ class LengthAwarePaginator extends AbstractPaginator implements Arrayable, Array ])); } + /** + * Get the paginator links as a collection (for JSON responses). + * + * @return \Illuminate\Support\Collection + */ + public function linkCollection() + { + return collect($this->elements())->flatMap(function ($item) { + if (! is_array($item)) { + return [['url' => null, 'label' => '...', 'active' => false]]; + } + + return collect($item)->map(function ($url, $page) { + return [ + 'url' => $url, + 'label' => (string) $page, + 'active' => $this->currentPage() === $page, + ]; + }); + })->prepend([ + 'url' => $this->previousPageUrl(), + 'label' => function_exists('__') ? __('pagination.previous') : 'Previous', + 'active' => false, + ])->push([ + 'url' => $this->nextPageUrl(), + 'label' => function_exists('__') ? __('pagination.next') : 'Next', + 'active' => false, + ]); + } + /** * Get the array of elements to pass to the view. * @@ -168,6 +198,7 @@ class LengthAwarePaginator extends AbstractPaginator implements Arrayable, Array 'from' => $this->firstItem(), 'last_page' => $this->lastPage(), 'last_page_url' => $this->url($this->lastPage()), + 'links' => $this->linkCollection()->toArray(), 'next_page_url' => $this->nextPageUrl(), 'path' => $this->path(), 'per_page' => $this->perPage(), diff --git a/vendor/laravel/framework/src/Illuminate/Pagination/PaginationServiceProvider.php b/vendor/laravel/framework/src/Illuminate/Pagination/PaginationServiceProvider.php index 6510f2f26..e94cebd6c 100755 --- a/vendor/laravel/framework/src/Illuminate/Pagination/PaginationServiceProvider.php +++ b/vendor/laravel/framework/src/Illuminate/Pagination/PaginationServiceProvider.php @@ -29,26 +29,6 @@ class PaginationServiceProvider extends ServiceProvider */ public function register() { - Paginator::viewFactoryResolver(function () { - return $this->app['view']; - }); - - Paginator::currentPathResolver(function () { - return $this->app['request']->url(); - }); - - Paginator::currentPageResolver(function ($pageName = 'page') { - $page = $this->app['request']->input($pageName); - - if (filter_var($page, FILTER_VALIDATE_INT) !== false && (int) $page >= 1) { - return (int) $page; - } - - return 1; - }); - - Paginator::queryStringResolver(function () { - return $this->app['request']->query(); - }); + PaginationState::resolveUsing($this->app); } } diff --git a/vendor/laravel/framework/src/Illuminate/Pagination/PaginationState.php b/vendor/laravel/framework/src/Illuminate/Pagination/PaginationState.php new file mode 100644 index 000000000..ff8150ff2 --- /dev/null +++ b/vendor/laravel/framework/src/Illuminate/Pagination/PaginationState.php @@ -0,0 +1,41 @@ +url(); + }); + + Paginator::currentPageResolver(function ($pageName = 'page') use ($app) { + $page = $app['request']->input($pageName); + + if (filter_var($page, FILTER_VALIDATE_INT) !== false && (int) $page >= 1) { + return (int) $page; + } + + return 1; + }); + + Paginator::queryStringResolver(function () use ($app) { + return $app['request']->query(); + }); + + CursorPaginator::currentCursorResolver(function ($cursorName = 'cursor') use ($app) { + return Cursor::fromEncoded($app['request']->input($cursorName)); + }); + } +} diff --git a/vendor/laravel/framework/src/Illuminate/Pagination/composer.json b/vendor/laravel/framework/src/Illuminate/Pagination/composer.json index 36de9820a..5c8a380b2 100755 --- a/vendor/laravel/framework/src/Illuminate/Pagination/composer.json +++ b/vendor/laravel/framework/src/Illuminate/Pagination/composer.json @@ -14,10 +14,11 @@ } ], "require": { - "php": "^7.2.5|^8.0", + "php": "^7.3|^8.0", "ext-json": "*", - "illuminate/contracts": "^7.0", - "illuminate/support": "^7.0" + "illuminate/collections": "^8.0", + "illuminate/contracts": "^8.0", + "illuminate/support": "^8.0" }, "autoload": { "psr-4": { @@ -26,7 +27,7 @@ }, "extra": { "branch-alias": { - "dev-master": "7.x-dev" + "dev-master": "8.x-dev" } }, "config": { diff --git a/vendor/laravel/framework/src/Illuminate/Pagination/resources/views/simple-tailwind.blade.php b/vendor/laravel/framework/src/Illuminate/Pagination/resources/views/simple-tailwind.blade.php index 1c5e52f3e..6872cca36 100644 --- a/vendor/laravel/framework/src/Illuminate/Pagination/resources/views/simple-tailwind.blade.php +++ b/vendor/laravel/framework/src/Illuminate/Pagination/resources/views/simple-tailwind.blade.php @@ -6,14 +6,14 @@ {!! __('pagination.previous') !!} @else - @endif {{-- Next Page Link --}} @if ($paginator->hasMorePages()) - @else diff --git a/vendor/laravel/framework/src/Illuminate/Pagination/resources/views/tailwind.blade.php b/vendor/laravel/framework/src/Illuminate/Pagination/resources/views/tailwind.blade.php index 4b92aaba1..2dd4d0ef3 100644 --- a/vendor/laravel/framework/src/Illuminate/Pagination/resources/views/tailwind.blade.php +++ b/vendor/laravel/framework/src/Illuminate/Pagination/resources/views/tailwind.blade.php @@ -1,18 +1,18 @@ @if ($paginator->hasPages()) - ","
"],col:[2,"","
"],tr:[2,"","
"],td:[3,"","
"],_default:[0,"",""]};function ft(t,e){var p;return p=void 0!==t.getElementsByTagName?t.getElementsByTagName(e||"*"):void 0!==t.querySelectorAll?t.querySelectorAll(e||"*"):[],void 0===e||e&&y(t,e)?R.merge([t],p):p}function Wt(t,e){for(var p=0,o=t.length;p",""]);var ht=/<|&#?\w+;/;function vt(t,e,p,o,b){for(var M,n,z,r,c,O,i=e.createDocumentFragment(),a=[],A=0,s=t.length;A-1)b&&b.push(M);else if(c=nt(M),n=ft(i.appendChild(M),"script"),c&&Wt(n),p)for(O=0;M=n[O++];)qt.test(M.type||"")&&p.push(M);return i}var Rt=/^key/,mt=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,gt=/^([^.]*)(?:\.(.+)|)/;function Bt(){return!0}function Xt(){return!1}function Lt(t,e){return t===function(){try{return f.activeElement}catch(t){}}()==("focus"===e)}function yt(t,e,p,o,b,M){var n,z;if("object"==typeof e){for(z in"string"!=typeof p&&(o=o||p,p=void 0),e)yt(t,z,p,o,e[z],M);return t}if(null==o&&null==b?(b=p,o=p=void 0):null==b&&("string"==typeof p?(b=o,o=void 0):(b=o,o=p,p=void 0)),!1===b)b=Xt;else if(!b)return t;return 1===M&&(n=b,(b=function(t){return R().off(t),n.apply(this,arguments)}).guid=n.guid||(n.guid=R.guid++)),t.each((function(){R.event.add(this,e,b,o,p)}))}function Nt(t,e,p){p?(J.set(t,e,!1),R.event.add(t,e,{namespace:!1,handler:function(t){var o,b,M=J.get(this,e);if(1&t.isTrigger&&this[e]){if(M.length)(R.event.special[e]||{}).delegateType&&t.stopPropagation();else if(M=z.call(arguments),J.set(this,e,M),o=p(this,e),this[e](),M!==(b=J.get(this,e))||o?J.set(this,e,!1):b={},M!==b)return t.stopImmediatePropagation(),t.preventDefault(),b.value}else M.length&&(J.set(this,e,{value:R.event.trigger(R.extend(M[0],R.Event.prototype),M.slice(1),this)}),t.stopImmediatePropagation())}})):void 0===J.get(t,e)&&R.event.add(t,e,Bt)}R.event={global:{},add:function(t,e,p,o,b){var M,n,z,r,c,O,i,a,A,s,d,l=J.get(t);if(Y(t))for(p.handler&&(p=(M=p).handler,b=M.selector),b&&R.find.matchesSelector(Mt,b),p.guid||(p.guid=R.guid++),(r=l.events)||(r=l.events=Object.create(null)),(n=l.handle)||(n=l.handle=function(e){return void 0!==R&&R.event.triggered!==e.type?R.event.dispatch.apply(t,arguments):void 0}),c=(e=(e||"").match(H)||[""]).length;c--;)A=d=(z=gt.exec(e[c])||[])[1],s=(z[2]||"").split(".").sort(),A&&(i=R.event.special[A]||{},A=(b?i.delegateType:i.bindType)||A,i=R.event.special[A]||{},O=R.extend({type:A,origType:d,data:o,handler:p,guid:p.guid,selector:b,needsContext:b&&R.expr.match.needsContext.test(b),namespace:s.join(".")},M),(a=r[A])||((a=r[A]=[]).delegateCount=0,i.setup&&!1!==i.setup.call(t,o,s,n)||t.addEventListener&&t.addEventListener(A,n)),i.add&&(i.add.call(t,O),O.handler.guid||(O.handler.guid=p.guid)),b?a.splice(a.delegateCount++,0,O):a.push(O),R.event.global[A]=!0)},remove:function(t,e,p,o,b){var M,n,z,r,c,O,i,a,A,s,d,l=J.hasData(t)&&J.get(t);if(l&&(r=l.events)){for(c=(e=(e||"").match(H)||[""]).length;c--;)if(A=d=(z=gt.exec(e[c])||[])[1],s=(z[2]||"").split(".").sort(),A){for(i=R.event.special[A]||{},a=r[A=(o?i.delegateType:i.bindType)||A]||[],z=z[2]&&new RegExp("(^|\\.)"+s.join("\\.(?:.*\\.|)")+"(\\.|$)"),n=M=a.length;M--;)O=a[M],!b&&d!==O.origType||p&&p.guid!==O.guid||z&&!z.test(O.namespace)||o&&o!==O.selector&&("**"!==o||!O.selector)||(a.splice(M,1),O.selector&&a.delegateCount--,i.remove&&i.remove.call(t,O));n&&!a.length&&(i.teardown&&!1!==i.teardown.call(t,s,l.handle)||R.removeEvent(t,A,l.handle),delete r[A])}else for(A in r)R.event.remove(t,A+e[c],p,o,!0);R.isEmptyObject(r)&&J.remove(t,"handle events")}},dispatch:function(t){var e,p,o,b,M,n,z=new Array(arguments.length),r=R.event.fix(t),c=(J.get(this,"events")||Object.create(null))[r.type]||[],O=R.event.special[r.type]||{};for(z[0]=r,e=1;e=1))for(;c!==this;c=c.parentNode||this)if(1===c.nodeType&&("click"!==t.type||!0!==c.disabled)){for(M=[],n={},p=0;p-1:R.find(b,this,null,[c]).length),n[b]&&M.push(o);M.length&&z.push({elem:c,handlers:M})}return c=this,r\s*$/g;function wt(t,e){return y(t,"table")&&y(11!==e.nodeType?e:e.firstChild,"tr")&&R(t).children("tbody")[0]||t}function Ct(t){return t.type=(null!==t.getAttribute("type"))+"/"+t.type,t}function St(t){return"true/"===(t.type||"").slice(0,5)?t.type=t.type.slice(5):t.removeAttribute("type"),t}function Ht(t,e){var p,o,b,M,n,z;if(1===e.nodeType){if(J.hasData(t)&&(z=J.get(t).events))for(b in J.remove(e,"handle events"),z)for(p=0,o=z[b].length;p1&&"string"==typeof s&&!l.checkClone&&Tt.test(s))return t.each((function(b){var M=t.eq(b);d&&(e[0]=s.call(this,b,M.html())),kt(M,e,p,o)}));if(a&&(M=(b=vt(e,t[0].ownerDocument,!1,t,o)).firstChild,1===b.childNodes.length&&(b=M),M||o)){for(z=(n=R.map(ft(b,"script"),Ct)).length;i0&&Wt(n,!r&&ft(t,"script")),z},cleanData:function(t){for(var e,p,o,b=R.event.special,M=0;void 0!==(p=t[M]);M++)if(Y(p)){if(e=p[J.expando]){if(e.events)for(o in e.events)b[o]?R.event.remove(p,o):R.removeEvent(p,o,e.handle);p[J.expando]=void 0}p[Q.expando]&&(p[Q.expando]=void 0)}}}),R.fn.extend({detach:function(t){return Et(this,t,!0)},remove:function(t){return Et(this,t)},text:function(t){return j(this,(function(t){return void 0===t?R.text(this):this.empty().each((function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=t)}))}),null,t,arguments.length)},append:function(){return kt(this,arguments,(function(t){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||wt(this,t).appendChild(t)}))},prepend:function(){return kt(this,arguments,(function(t){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var e=wt(this,t);e.insertBefore(t,e.firstChild)}}))},before:function(){return kt(this,arguments,(function(t){this.parentNode&&this.parentNode.insertBefore(t,this)}))},after:function(){return kt(this,arguments,(function(t){this.parentNode&&this.parentNode.insertBefore(t,this.nextSibling)}))},empty:function(){for(var t,e=0;null!=(t=this[e]);e++)1===t.nodeType&&(R.cleanData(ft(t,!1)),t.textContent="");return this},clone:function(t,e){return t=null!=t&&t,e=null==e?t:e,this.map((function(){return R.clone(this,t,e)}))},html:function(t){return j(this,(function(t){var e=this[0]||{},p=0,o=this.length;if(void 0===t&&1===e.nodeType)return e.innerHTML;if("string"==typeof t&&!_t.test(t)&&!ut[(lt.exec(t)||["",""])[1].toLowerCase()]){t=R.htmlPrefilter(t);try{for(;p3,Mt.removeChild(t)),z}}))}();var $t=["Webkit","Moz","ms"],Kt=f.createElement("div").style,Yt={};function Gt(t){var e=R.cssProps[t]||Yt[t];return e||(t in Kt?t:Yt[t]=function(t){for(var e=t[0].toUpperCase()+t.slice(1),p=$t.length;p--;)if((t=$t[p]+e)in Kt)return t}(t)||t)}var Jt=/^(none|table(?!-c[ea]).+)/,Qt=/^--/,Zt={position:"absolute",visibility:"hidden",display:"block"},te={letterSpacing:"0",fontWeight:"400"};function ee(t,e,p){var o=ot.exec(e);return o?Math.max(0,o[2]-(p||0))+(o[3]||"px"):e}function pe(t,e,p,o,b,M){var n="width"===e?1:0,z=0,r=0;if(p===(o?"border":"content"))return 0;for(;n<4;n+=2)"margin"===p&&(r+=R.css(t,p+bt[n],!0,b)),o?("content"===p&&(r-=R.css(t,"padding"+bt[n],!0,b)),"margin"!==p&&(r-=R.css(t,"border"+bt[n]+"Width",!0,b))):(r+=R.css(t,"padding"+bt[n],!0,b),"padding"!==p?r+=R.css(t,"border"+bt[n]+"Width",!0,b):z+=R.css(t,"border"+bt[n]+"Width",!0,b));return!o&&M>=0&&(r+=Math.max(0,Math.ceil(t["offset"+e[0].toUpperCase()+e.slice(1)]-M-r-z-.5))||0),r}function oe(t,e,p){var o=It(t),b=(!l.boxSizingReliable()||p)&&"border-box"===R.css(t,"boxSizing",!1,o),M=b,n=Vt(t,e,o),z="offset"+e[0].toUpperCase()+e.slice(1);if(Dt.test(n)){if(!p)return n;n="auto"}return(!l.boxSizingReliable()&&b||!l.reliableTrDimensions()&&y(t,"tr")||"auto"===n||!parseFloat(n)&&"inline"===R.css(t,"display",!1,o))&&t.getClientRects().length&&(b="border-box"===R.css(t,"boxSizing",!1,o),(M=z in t)&&(n=t[z])),(n=parseFloat(n)||0)+pe(t,e,p||(b?"border":"content"),M,o,n)+"px"}function be(t,e,p,o,b){return new be.prototype.init(t,e,p,o,b)}R.extend({cssHooks:{opacity:{get:function(t,e){if(e){var p=Vt(t,"opacity");return""===p?"1":p}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{},style:function(t,e,p,o){if(t&&3!==t.nodeType&&8!==t.nodeType&&t.style){var b,M,n,z=K(e),r=Qt.test(e),c=t.style;if(r||(e=Gt(z)),n=R.cssHooks[e]||R.cssHooks[z],void 0===p)return n&&"get"in n&&void 0!==(b=n.get(t,!1,o))?b:c[e];"string"===(M=typeof p)&&(b=ot.exec(p))&&b[1]&&(p=ct(t,e,b),M="number"),null!=p&&p==p&&("number"!==M||r||(p+=b&&b[3]||(R.cssNumber[z]?"":"px")),l.clearCloneStyle||""!==p||0!==e.indexOf("background")||(c[e]="inherit"),n&&"set"in n&&void 0===(p=n.set(t,p,o))||(r?c.setProperty(e,p):c[e]=p))}},css:function(t,e,p,o){var b,M,n,z=K(e);return Qt.test(e)||(e=Gt(z)),(n=R.cssHooks[e]||R.cssHooks[z])&&"get"in n&&(b=n.get(t,!0,p)),void 0===b&&(b=Vt(t,e,o)),"normal"===b&&e in te&&(b=te[e]),""===p||p?(M=parseFloat(b),!0===p||isFinite(M)?M||0:b):b}}),R.each(["height","width"],(function(t,e){R.cssHooks[e]={get:function(t,p,o){if(p)return!Jt.test(R.css(t,"display"))||t.getClientRects().length&&t.getBoundingClientRect().width?oe(t,e,o):Pt(t,Zt,(function(){return oe(t,e,o)}))},set:function(t,p,o){var b,M=It(t),n=!l.scrollboxSize()&&"absolute"===M.position,z=(n||o)&&"border-box"===R.css(t,"boxSizing",!1,M),r=o?pe(t,e,o,z,M):0;return z&&n&&(r-=Math.ceil(t["offset"+e[0].toUpperCase()+e.slice(1)]-parseFloat(M[e])-pe(t,e,"border",!1,M)-.5)),r&&(b=ot.exec(p))&&"px"!==(b[3]||"px")&&(t.style[e]=p,p=R.css(t,e)),ee(0,p,r)}}})),R.cssHooks.marginLeft=Ut(l.reliableMarginLeft,(function(t,e){if(e)return(parseFloat(Vt(t,"marginLeft"))||t.getBoundingClientRect().left-Pt(t,{marginLeft:0},(function(){return t.getBoundingClientRect().left})))+"px"})),R.each({margin:"",padding:"",border:"Width"},(function(t,e){R.cssHooks[t+e]={expand:function(p){for(var o=0,b={},M="string"==typeof p?p.split(" "):[p];o<4;o++)b[t+bt[o]+e]=M[o]||M[o-2]||M[0];return b}},"margin"!==t&&(R.cssHooks[t+e].set=ee)})),R.fn.extend({css:function(t,e){return j(this,(function(t,e,p){var o,b,M={},n=0;if(Array.isArray(e)){for(o=It(t),b=e.length;n1)}}),R.Tween=be,be.prototype={constructor:be,init:function(t,e,p,o,b,M){this.elem=t,this.prop=p,this.easing=b||R.easing._default,this.options=e,this.start=this.now=this.cur(),this.end=o,this.unit=M||(R.cssNumber[p]?"":"px")},cur:function(){var t=be.propHooks[this.prop];return t&&t.get?t.get(this):be.propHooks._default.get(this)},run:function(t){var e,p=be.propHooks[this.prop];return this.options.duration?this.pos=e=R.easing[this.easing](t,this.options.duration*t,0,1,this.options.duration):this.pos=e=t,this.now=(this.end-this.start)*e+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),p&&p.set?p.set(this):be.propHooks._default.set(this),this}},be.prototype.init.prototype=be.prototype,be.propHooks={_default:{get:function(t){var e;return 1!==t.elem.nodeType||null!=t.elem[t.prop]&&null==t.elem.style[t.prop]?t.elem[t.prop]:(e=R.css(t.elem,t.prop,""))&&"auto"!==e?e:0},set:function(t){R.fx.step[t.prop]?R.fx.step[t.prop](t):1!==t.elem.nodeType||!R.cssHooks[t.prop]&&null==t.elem.style[Gt(t.prop)]?t.elem[t.prop]=t.now:R.style(t.elem,t.prop,t.now+t.unit)}}},be.propHooks.scrollTop=be.propHooks.scrollLeft={set:function(t){t.elem.nodeType&&t.elem.parentNode&&(t.elem[t.prop]=t.now)}},R.easing={linear:function(t){return t},swing:function(t){return.5-Math.cos(t*Math.PI)/2},_default:"swing"},R.fx=be.prototype.init,R.fx.step={};var Me,ne,ze=/^(?:toggle|show|hide)$/,re=/queueHooks$/;function ce(){ne&&(!1===f.hidden&&p.requestAnimationFrame?p.requestAnimationFrame(ce):p.setTimeout(ce,R.fx.interval),R.fx.tick())}function Oe(){return p.setTimeout((function(){Me=void 0})),Me=Date.now()}function ie(t,e){var p,o=0,b={height:t};for(e=e?1:0;o<4;o+=2-e)b["margin"+(p=bt[o])]=b["padding"+p]=t;return e&&(b.opacity=b.width=t),b}function ae(t,e,p){for(var o,b=(Ae.tweeners[e]||[]).concat(Ae.tweeners["*"]),M=0,n=b.length;M1)},removeAttr:function(t){return this.each((function(){R.removeAttr(this,t)}))}}),R.extend({attr:function(t,e,p){var o,b,M=t.nodeType;if(3!==M&&8!==M&&2!==M)return void 0===t.getAttribute?R.prop(t,e,p):(1===M&&R.isXMLDoc(t)||(b=R.attrHooks[e.toLowerCase()]||(R.expr.match.bool.test(e)?se:void 0)),void 0!==p?null===p?void R.removeAttr(t,e):b&&"set"in b&&void 0!==(o=b.set(t,p,e))?o:(t.setAttribute(e,p+""),p):b&&"get"in b&&null!==(o=b.get(t,e))?o:null==(o=R.find.attr(t,e))?void 0:o)},attrHooks:{type:{set:function(t,e){if(!l.radioValue&&"radio"===e&&y(t,"input")){var p=t.value;return t.setAttribute("type",e),p&&(t.value=p),e}}}},removeAttr:function(t,e){var p,o=0,b=e&&e.match(H);if(b&&1===t.nodeType)for(;p=b[o++];)t.removeAttribute(p)}}),se={set:function(t,e,p){return!1===e?R.removeAttr(t,p):t.setAttribute(p,p),p}},R.each(R.expr.match.bool.source.match(/\w+/g),(function(t,e){var p=de[e]||R.find.attr;de[e]=function(t,e,o){var b,M,n=e.toLowerCase();return o||(M=de[n],de[n]=b,b=null!=p(t,e,o)?n:null,de[n]=M),b}}));var le=/^(?:input|select|textarea|button)$/i,qe=/^(?:a|area)$/i;function ue(t){return(t.match(H)||[]).join(" ")}function fe(t){return t.getAttribute&&t.getAttribute("class")||""}function We(t){return Array.isArray(t)?t:"string"==typeof t&&t.match(H)||[]}R.fn.extend({prop:function(t,e){return j(this,R.prop,t,e,arguments.length>1)},removeProp:function(t){return this.each((function(){delete this[R.propFix[t]||t]}))}}),R.extend({prop:function(t,e,p){var o,b,M=t.nodeType;if(3!==M&&8!==M&&2!==M)return 1===M&&R.isXMLDoc(t)||(e=R.propFix[e]||e,b=R.propHooks[e]),void 0!==p?b&&"set"in b&&void 0!==(o=b.set(t,p,e))?o:t[e]=p:b&&"get"in b&&null!==(o=b.get(t,e))?o:t[e]},propHooks:{tabIndex:{get:function(t){var e=R.find.attr(t,"tabindex");return e?parseInt(e,10):le.test(t.nodeName)||qe.test(t.nodeName)&&t.href?0:-1}}},propFix:{for:"htmlFor",class:"className"}}),l.optSelected||(R.propHooks.selected={get:function(t){var e=t.parentNode;return e&&e.parentNode&&e.parentNode.selectedIndex,null},set:function(t){var e=t.parentNode;e&&(e.selectedIndex,e.parentNode&&e.parentNode.selectedIndex)}}),R.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],(function(){R.propFix[this.toLowerCase()]=this})),R.fn.extend({addClass:function(t){var e,p,o,b,M,n,z,r=0;if(q(t))return this.each((function(e){R(this).addClass(t.call(this,e,fe(this)))}));if((e=We(t)).length)for(;p=this[r++];)if(b=fe(p),o=1===p.nodeType&&" "+ue(b)+" "){for(n=0;M=e[n++];)o.indexOf(" "+M+" ")<0&&(o+=M+" ");b!==(z=ue(o))&&p.setAttribute("class",z)}return this},removeClass:function(t){var e,p,o,b,M,n,z,r=0;if(q(t))return this.each((function(e){R(this).removeClass(t.call(this,e,fe(this)))}));if(!arguments.length)return this.attr("class","");if((e=We(t)).length)for(;p=this[r++];)if(b=fe(p),o=1===p.nodeType&&" "+ue(b)+" "){for(n=0;M=e[n++];)for(;o.indexOf(" "+M+" ")>-1;)o=o.replace(" "+M+" "," ");b!==(z=ue(o))&&p.setAttribute("class",z)}return this},toggleClass:function(t,e){var p=typeof t,o="string"===p||Array.isArray(t);return"boolean"==typeof e&&o?e?this.addClass(t):this.removeClass(t):q(t)?this.each((function(p){R(this).toggleClass(t.call(this,p,fe(this),e),e)})):this.each((function(){var e,b,M,n;if(o)for(b=0,M=R(this),n=We(t);e=n[b++];)M.hasClass(e)?M.removeClass(e):M.addClass(e);else void 0!==t&&"boolean"!==p||((e=fe(this))&&J.set(this,"__className__",e),this.setAttribute&&this.setAttribute("class",e||!1===t?"":J.get(this,"__className__")||""))}))},hasClass:function(t){var e,p,o=0;for(e=" "+t+" ";p=this[o++];)if(1===p.nodeType&&(" "+ue(fe(p))+" ").indexOf(e)>-1)return!0;return!1}});var he=/\r/g;R.fn.extend({val:function(t){var e,p,o,b=this[0];return arguments.length?(o=q(t),this.each((function(p){var b;1===this.nodeType&&(null==(b=o?t.call(this,p,R(this).val()):t)?b="":"number"==typeof b?b+="":Array.isArray(b)&&(b=R.map(b,(function(t){return null==t?"":t+""}))),(e=R.valHooks[this.type]||R.valHooks[this.nodeName.toLowerCase()])&&"set"in e&&void 0!==e.set(this,b,"value")||(this.value=b))}))):b?(e=R.valHooks[b.type]||R.valHooks[b.nodeName.toLowerCase()])&&"get"in e&&void 0!==(p=e.get(b,"value"))?p:"string"==typeof(p=b.value)?p.replace(he,""):null==p?"":p:void 0}}),R.extend({valHooks:{option:{get:function(t){var e=R.find.attr(t,"value");return null!=e?e:ue(R.text(t))}},select:{get:function(t){var e,p,o,b=t.options,M=t.selectedIndex,n="select-one"===t.type,z=n?null:[],r=n?M+1:b.length;for(o=M<0?r:n?M:0;o-1)&&(p=!0);return p||(t.selectedIndex=-1),M}}}}),R.each(["radio","checkbox"],(function(){R.valHooks[this]={set:function(t,e){if(Array.isArray(e))return t.checked=R.inArray(R(t).val(),e)>-1}},l.checkOn||(R.valHooks[this].get=function(t){return null===t.getAttribute("value")?"on":t.value})})),l.focusin="onfocusin"in p;var ve=/^(?:focusinfocus|focusoutblur)$/,Re=function(t){t.stopPropagation()};R.extend(R.event,{trigger:function(t,e,o,b){var M,n,z,r,c,O,i,a,s=[o||f],d=A.call(t,"type")?t.type:t,l=A.call(t,"namespace")?t.namespace.split("."):[];if(n=a=z=o=o||f,3!==o.nodeType&&8!==o.nodeType&&!ve.test(d+R.event.triggered)&&(d.indexOf(".")>-1&&(l=d.split("."),d=l.shift(),l.sort()),c=d.indexOf(":")<0&&"on"+d,(t=t[R.expando]?t:new R.Event(d,"object"==typeof t&&t)).isTrigger=b?2:3,t.namespace=l.join("."),t.rnamespace=t.namespace?new RegExp("(^|\\.)"+l.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,t.result=void 0,t.target||(t.target=o),e=null==e?[t]:R.makeArray(e,[t]),i=R.event.special[d]||{},b||!i.trigger||!1!==i.trigger.apply(o,e))){if(!b&&!i.noBubble&&!u(o)){for(r=i.delegateType||d,ve.test(r+d)||(n=n.parentNode);n;n=n.parentNode)s.push(n),z=n;z===(o.ownerDocument||f)&&s.push(z.defaultView||z.parentWindow||p)}for(M=0;(n=s[M++])&&!t.isPropagationStopped();)a=n,t.type=M>1?r:i.bindType||d,(O=(J.get(n,"events")||Object.create(null))[t.type]&&J.get(n,"handle"))&&O.apply(n,e),(O=c&&n[c])&&O.apply&&Y(n)&&(t.result=O.apply(n,e),!1===t.result&&t.preventDefault());return t.type=d,b||t.isDefaultPrevented()||i._default&&!1!==i._default.apply(s.pop(),e)||!Y(o)||c&&q(o[d])&&!u(o)&&((z=o[c])&&(o[c]=null),R.event.triggered=d,t.isPropagationStopped()&&a.addEventListener(d,Re),o[d](),t.isPropagationStopped()&&a.removeEventListener(d,Re),R.event.triggered=void 0,z&&(o[c]=z)),t.result}},simulate:function(t,e,p){var o=R.extend(new R.Event,p,{type:t,isSimulated:!0});R.event.trigger(o,null,e)}}),R.fn.extend({trigger:function(t,e){return this.each((function(){R.event.trigger(t,e,this)}))},triggerHandler:function(t,e){var p=this[0];if(p)return R.event.trigger(t,e,p,!0)}}),l.focusin||R.each({focus:"focusin",blur:"focusout"},(function(t,e){var p=function(t){R.event.simulate(e,t.target,R.event.fix(t))};R.event.special[e]={setup:function(){var o=this.ownerDocument||this.document||this,b=J.access(o,e);b||o.addEventListener(t,p,!0),J.access(o,e,(b||0)+1)},teardown:function(){var o=this.ownerDocument||this.document||this,b=J.access(o,e)-1;b?J.access(o,e,b):(o.removeEventListener(t,p,!0),J.remove(o,e))}}}));var me=p.location,ge={guid:Date.now()},Be=/\?/;R.parseXML=function(t){var e;if(!t||"string"!=typeof t)return null;try{e=(new p.DOMParser).parseFromString(t,"text/xml")}catch(t){e=void 0}return e&&!e.getElementsByTagName("parsererror").length||R.error("Invalid XML: "+t),e};var Xe=/\[\]$/,Le=/\r?\n/g,ye=/^(?:submit|button|image|reset|file)$/i,Ne=/^(?:input|select|textarea|keygen)/i;function _e(t,e,p,o){var b;if(Array.isArray(e))R.each(e,(function(e,b){p||Xe.test(t)?o(t,b):_e(t+"["+("object"==typeof b&&null!=b?e:"")+"]",b,p,o)}));else if(p||"object"!==v(e))o(t,e);else for(b in e)_e(t+"["+b+"]",e[b],p,o)}R.param=function(t,e){var p,o=[],b=function(t,e){var p=q(e)?e():e;o[o.length]=encodeURIComponent(t)+"="+encodeURIComponent(null==p?"":p)};if(null==t)return"";if(Array.isArray(t)||t.jquery&&!R.isPlainObject(t))R.each(t,(function(){b(this.name,this.value)}));else for(p in t)_e(p,t[p],e,b);return o.join("&")},R.fn.extend({serialize:function(){return R.param(this.serializeArray())},serializeArray:function(){return this.map((function(){var t=R.prop(this,"elements");return t?R.makeArray(t):this})).filter((function(){var t=this.type;return this.name&&!R(this).is(":disabled")&&Ne.test(this.nodeName)&&!ye.test(t)&&(this.checked||!dt.test(t))})).map((function(t,e){var p=R(this).val();return null==p?null:Array.isArray(p)?R.map(p,(function(t){return{name:e.name,value:t.replace(Le,"\r\n")}})):{name:e.name,value:p.replace(Le,"\r\n")}})).get()}});var Te=/%20/g,xe=/#.*$/,we=/([?&])_=[^&]*/,Ce=/^(.*?):[ \t]*([^\r\n]*)$/gm,Se=/^(?:GET|HEAD)$/,He=/^\/\//,Fe={},ke={},Ee="*/".concat("*"),De=f.createElement("a");function Ie(t){return function(e,p){"string"!=typeof e&&(p=e,e="*");var o,b=0,M=e.toLowerCase().match(H)||[];if(q(p))for(;o=M[b++];)"+"===o[0]?(o=o.slice(1)||"*",(t[o]=t[o]||[]).unshift(p)):(t[o]=t[o]||[]).push(p)}}function Pe(t,e,p,o){var b={},M=t===ke;function n(z){var r;return b[z]=!0,R.each(t[z]||[],(function(t,z){var c=z(e,p,o);return"string"!=typeof c||M||b[c]?M?!(r=c):void 0:(e.dataTypes.unshift(c),n(c),!1)})),r}return n(e.dataTypes[0])||!b["*"]&&n("*")}function je(t,e){var p,o,b=R.ajaxSettings.flatOptions||{};for(p in e)void 0!==e[p]&&((b[p]?t:o||(o={}))[p]=e[p]);return o&&R.extend(!0,t,o),t}De.href=me.href,R.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:me.href,type:"GET",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(me.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Ee,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":R.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(t,e){return e?je(je(t,R.ajaxSettings),e):je(R.ajaxSettings,t)},ajaxPrefilter:Ie(Fe),ajaxTransport:Ie(ke),ajax:function(t,e){"object"==typeof t&&(e=t,t=void 0),e=e||{};var o,b,M,n,z,r,c,O,i,a,A=R.ajaxSetup({},e),s=A.context||A,d=A.context&&(s.nodeType||s.jquery)?R(s):R.event,l=R.Deferred(),q=R.Callbacks("once memory"),u=A.statusCode||{},W={},h={},v="canceled",m={readyState:0,getResponseHeader:function(t){var e;if(c){if(!n)for(n={};e=Ce.exec(M);)n[e[1].toLowerCase()+" "]=(n[e[1].toLowerCase()+" "]||[]).concat(e[2]);e=n[t.toLowerCase()+" "]}return null==e?null:e.join(", ")},getAllResponseHeaders:function(){return c?M:null},setRequestHeader:function(t,e){return null==c&&(t=h[t.toLowerCase()]=h[t.toLowerCase()]||t,W[t]=e),this},overrideMimeType:function(t){return null==c&&(A.mimeType=t),this},statusCode:function(t){var e;if(t)if(c)m.always(t[m.status]);else for(e in t)u[e]=[u[e],t[e]];return this},abort:function(t){var e=t||v;return o&&o.abort(e),g(0,e),this}};if(l.promise(m),A.url=((t||A.url||me.href)+"").replace(He,me.protocol+"//"),A.type=e.method||e.type||A.method||A.type,A.dataTypes=(A.dataType||"*").toLowerCase().match(H)||[""],null==A.crossDomain){r=f.createElement("a");try{r.href=A.url,r.href=r.href,A.crossDomain=De.protocol+"//"+De.host!=r.protocol+"//"+r.host}catch(t){A.crossDomain=!0}}if(A.data&&A.processData&&"string"!=typeof A.data&&(A.data=R.param(A.data,A.traditional)),Pe(Fe,A,e,m),c)return m;for(i in(O=R.event&&A.global)&&0==R.active++&&R.event.trigger("ajaxStart"),A.type=A.type.toUpperCase(),A.hasContent=!Se.test(A.type),b=A.url.replace(xe,""),A.hasContent?A.data&&A.processData&&0===(A.contentType||"").indexOf("application/x-www-form-urlencoded")&&(A.data=A.data.replace(Te,"+")):(a=A.url.slice(b.length),A.data&&(A.processData||"string"==typeof A.data)&&(b+=(Be.test(b)?"&":"?")+A.data,delete A.data),!1===A.cache&&(b=b.replace(we,"$1"),a=(Be.test(b)?"&":"?")+"_="+ge.guid+++a),A.url=b+a),A.ifModified&&(R.lastModified[b]&&m.setRequestHeader("If-Modified-Since",R.lastModified[b]),R.etag[b]&&m.setRequestHeader("If-None-Match",R.etag[b])),(A.data&&A.hasContent&&!1!==A.contentType||e.contentType)&&m.setRequestHeader("Content-Type",A.contentType),m.setRequestHeader("Accept",A.dataTypes[0]&&A.accepts[A.dataTypes[0]]?A.accepts[A.dataTypes[0]]+("*"!==A.dataTypes[0]?", "+Ee+"; q=0.01":""):A.accepts["*"]),A.headers)m.setRequestHeader(i,A.headers[i]);if(A.beforeSend&&(!1===A.beforeSend.call(s,m,A)||c))return m.abort();if(v="abort",q.add(A.complete),m.done(A.success),m.fail(A.error),o=Pe(ke,A,e,m)){if(m.readyState=1,O&&d.trigger("ajaxSend",[m,A]),c)return m;A.async&&A.timeout>0&&(z=p.setTimeout((function(){m.abort("timeout")}),A.timeout));try{c=!1,o.send(W,g)}catch(t){if(c)throw t;g(-1,t)}}else g(-1,"No Transport");function g(t,e,n,r){var i,a,f,W,h,v=e;c||(c=!0,z&&p.clearTimeout(z),o=void 0,M=r||"",m.readyState=t>0?4:0,i=t>=200&&t<300||304===t,n&&(W=function(t,e,p){for(var o,b,M,n,z=t.contents,r=t.dataTypes;"*"===r[0];)r.shift(),void 0===o&&(o=t.mimeType||e.getResponseHeader("Content-Type"));if(o)for(b in z)if(z[b]&&z[b].test(o)){r.unshift(b);break}if(r[0]in p)M=r[0];else{for(b in p){if(!r[0]||t.converters[b+" "+r[0]]){M=b;break}n||(n=b)}M=M||n}if(M)return M!==r[0]&&r.unshift(M),p[M]}(A,m,n)),!i&&R.inArray("script",A.dataTypes)>-1&&(A.converters["text script"]=function(){}),W=function(t,e,p,o){var b,M,n,z,r,c={},O=t.dataTypes.slice();if(O[1])for(n in t.converters)c[n.toLowerCase()]=t.converters[n];for(M=O.shift();M;)if(t.responseFields[M]&&(p[t.responseFields[M]]=e),!r&&o&&t.dataFilter&&(e=t.dataFilter(e,t.dataType)),r=M,M=O.shift())if("*"===M)M=r;else if("*"!==r&&r!==M){if(!(n=c[r+" "+M]||c["* "+M]))for(b in c)if((z=b.split(" "))[1]===M&&(n=c[r+" "+z[0]]||c["* "+z[0]])){!0===n?n=c[b]:!0!==c[b]&&(M=z[0],O.unshift(z[1]));break}if(!0!==n)if(n&&t.throws)e=n(e);else try{e=n(e)}catch(t){return{state:"parsererror",error:n?t:"No conversion from "+r+" to "+M}}}return{state:"success",data:e}}(A,W,m,i),i?(A.ifModified&&((h=m.getResponseHeader("Last-Modified"))&&(R.lastModified[b]=h),(h=m.getResponseHeader("etag"))&&(R.etag[b]=h)),204===t||"HEAD"===A.type?v="nocontent":304===t?v="notmodified":(v=W.state,a=W.data,i=!(f=W.error))):(f=v,!t&&v||(v="error",t<0&&(t=0))),m.status=t,m.statusText=(e||v)+"",i?l.resolveWith(s,[a,v,m]):l.rejectWith(s,[m,v,f]),m.statusCode(u),u=void 0,O&&d.trigger(i?"ajaxSuccess":"ajaxError",[m,A,i?a:f]),q.fireWith(s,[m,v]),O&&(d.trigger("ajaxComplete",[m,A]),--R.active||R.event.trigger("ajaxStop")))}return m},getJSON:function(t,e,p){return R.get(t,e,p,"json")},getScript:function(t,e){return R.get(t,void 0,e,"script")}}),R.each(["get","post"],(function(t,e){R[e]=function(t,p,o,b){return q(p)&&(b=b||o,o=p,p=void 0),R.ajax(R.extend({url:t,type:e,dataType:b,data:p,success:o},R.isPlainObject(t)&&t))}})),R.ajaxPrefilter((function(t){var e;for(e in t.headers)"content-type"===e.toLowerCase()&&(t.contentType=t.headers[e]||"")})),R._evalUrl=function(t,e,p){return R.ajax({url:t,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,converters:{"text script":function(){}},dataFilter:function(t){R.globalEval(t,e,p)}})},R.fn.extend({wrapAll:function(t){var e;return this[0]&&(q(t)&&(t=t.call(this[0])),e=R(t,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&e.insertBefore(this[0]),e.map((function(){for(var t=this;t.firstElementChild;)t=t.firstElementChild;return t})).append(this)),this},wrapInner:function(t){return q(t)?this.each((function(e){R(this).wrapInner(t.call(this,e))})):this.each((function(){var e=R(this),p=e.contents();p.length?p.wrapAll(t):e.append(t)}))},wrap:function(t){var e=q(t);return this.each((function(p){R(this).wrapAll(e?t.call(this,p):t)}))},unwrap:function(t){return this.parent(t).not("body").each((function(){R(this).replaceWith(this.childNodes)})),this}}),R.expr.pseudos.hidden=function(t){return!R.expr.pseudos.visible(t)},R.expr.pseudos.visible=function(t){return!!(t.offsetWidth||t.offsetHeight||t.getClientRects().length)},R.ajaxSettings.xhr=function(){try{return new p.XMLHttpRequest}catch(t){}};var Ve={0:200,1223:204},Ue=R.ajaxSettings.xhr();l.cors=!!Ue&&"withCredentials"in Ue,l.ajax=Ue=!!Ue,R.ajaxTransport((function(t){var e,o;if(l.cors||Ue&&!t.crossDomain)return{send:function(b,M){var n,z=t.xhr();if(z.open(t.type,t.url,t.async,t.username,t.password),t.xhrFields)for(n in t.xhrFields)z[n]=t.xhrFields[n];for(n in t.mimeType&&z.overrideMimeType&&z.overrideMimeType(t.mimeType),t.crossDomain||b["X-Requested-With"]||(b["X-Requested-With"]="XMLHttpRequest"),b)z.setRequestHeader(n,b[n]);e=function(t){return function(){e&&(e=o=z.onload=z.onerror=z.onabort=z.ontimeout=z.onreadystatechange=null,"abort"===t?z.abort():"error"===t?"number"!=typeof z.status?M(0,"error"):M(z.status,z.statusText):M(Ve[z.status]||z.status,z.statusText,"text"!==(z.responseType||"text")||"string"!=typeof z.responseText?{binary:z.response}:{text:z.responseText},z.getAllResponseHeaders()))}},z.onload=e(),o=z.onerror=z.ontimeout=e("error"),void 0!==z.onabort?z.onabort=o:z.onreadystatechange=function(){4===z.readyState&&p.setTimeout((function(){e&&o()}))},e=e("abort");try{z.send(t.hasContent&&t.data||null)}catch(t){if(e)throw t}},abort:function(){e&&e()}}})),R.ajaxPrefilter((function(t){t.crossDomain&&(t.contents.script=!1)})),R.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(t){return R.globalEval(t),t}}}),R.ajaxPrefilter("script",(function(t){void 0===t.cache&&(t.cache=!1),t.crossDomain&&(t.type="GET")})),R.ajaxTransport("script",(function(t){var e,p;if(t.crossDomain||t.scriptAttrs)return{send:function(o,b){e=R(" + + diff --git a/vendor/laravel/horizon/resources/js/screens/batches/preview.vue b/vendor/laravel/horizon/resources/js/screens/batches/preview.vue new file mode 100644 index 000000000..db2e443a3 --- /dev/null +++ b/vendor/laravel/horizon/resources/js/screens/batches/preview.vue @@ -0,0 +1,199 @@ + + + diff --git a/vendor/laravel/horizon/resources/js/screens/dashboard.vue b/vendor/laravel/horizon/resources/js/screens/dashboard.vue index cccf9cbe1..0967793dd 100644 --- a/vendor/laravel/horizon/resources/js/screens/dashboard.vue +++ b/vendor/laravel/horizon/resources/js/screens/dashboard.vue @@ -210,6 +210,7 @@

{{ {running: 'Active', paused: 'Paused', inactive:'Inactive'}[stats.status] }}

+ ({{ stats.pausedMasters }} paused)
@@ -229,11 +230,12 @@
MAX WAIT TIME - ({{ stats.max_wait_queue }}) -

+

{{ stats.max_wait_time ? humanTime(stats.max_wait_time) : '-' }}

+ + ({{ stats.max_wait_queue }})
@@ -277,14 +279,29 @@ - - - {{ queue.name.replace(/,/g, ', ') }} - - {{ queue.processes ? queue.processes.toLocaleString() : 0 }} - {{ queue.length ? queue.length.toLocaleString() : 0 }} - {{ humanTime(queue.wait) }} - + @@ -293,6 +310,14 @@
{{ worker.name }}
+ + + + + + + +
@@ -310,9 +335,12 @@ - +
{{ superVisorDisplayName(supervisor.name, worker.name) }} {{ countProcesses(supervisor.processes) }} {{ supervisor.options.queue.replace(/,/g, ', ') }} + ({{ supervisor.options.balance.charAt(0).toUpperCase() + supervisor.options.balance.slice(1) }}) + (Disabled) +
diff --git a/vendor/laravel/horizon/resources/js/screens/failedJobs/index.vue b/vendor/laravel/horizon/resources/js/screens/failedJobs/index.vue index 8659c6f52..0a6177387 100644 --- a/vendor/laravel/horizon/resources/js/screens/failedJobs/index.vue +++ b/vendor/laravel/horizon/resources/js/screens/failedJobs/index.vue @@ -136,6 +136,22 @@ }, + /** + * Determine if the given job was retried. + */ + wasRetried(job) { + return job.retried_by && job.retried_by.length; + }, + + + /** + * Determine if the given job is a retry. + */ + isRetry(job) { + return job.payload.retry_of; + }, + + /** * Refresh the jobs every period of time. */ @@ -222,11 +238,24 @@ {{ jobBaseName(job.name) }} + + + Retried + +
Queue: {{job.queue}} | Attempts: {{ job.payload.attempts }} + + | Retry of + + {{ job.payload.retry_of.split('-')[0] }} + + | Tags: {{ job.payload.tags && job.payload.tags.length ? job.payload.tags.join(', ') : '' }} diff --git a/vendor/laravel/horizon/resources/js/screens/failedJobs/job.vue b/vendor/laravel/horizon/resources/js/screens/failedJobs/job.vue index 1a38ba52f..ac7848159 100644 --- a/vendor/laravel/horizon/resources/js/screens/failedJobs/job.vue +++ b/vendor/laravel/horizon/resources/js/screens/failedJobs/job.vue @@ -150,10 +150,34 @@
Queue
{{job.queue}}
+
+
Attempts
+
{{job.payload.attempts}}
+
+
+
Retries
+
{{job.retried_by.length}}
+
+
+
Retry of ID
+ +
Tags
{{ job.payload.tags && job.payload.tags.length ? job.payload.tags.join(', ') : '' }}
+
+
Batch
+
+ + {{ prettyPrintJob(job.payload.data).batchId }} + +
+
Failed At
{{readableTimestamp(job.failed_at)}}
diff --git a/vendor/laravel/horizon/resources/js/screens/monitoring/index.vue b/vendor/laravel/horizon/resources/js/screens/monitoring/index.vue index a6b388cc3..132313ebb 100644 --- a/vendor/laravel/horizon/resources/js/screens/monitoring/index.vue +++ b/vendor/laravel/horizon/resources/js/screens/monitoring/index.vue @@ -157,7 +157,7 @@ +
+
Batch
+
+ + {{ prettyPrintJob(job.payload.data).batchId }} + +
+
+
Delayed Until
{{delayed}}
@@ -111,10 +120,14 @@ // } - if (unserialized && unserialized.delay) { + if (unserialized && unserialized.delay && unserialized.delay.date) { return moment.tz(unserialized.delay.date, unserialized.delay.timezone) .local() .format('YYYY-MM-DD HH:mm:ss'); + } else if (unserialized && unserialized.delay) { + return this.formatDate(this.job.payload.pushedAt).add(unserialized.delay, 'seconds') + .local() + .format('YYYY-MM-DD HH:mm:ss'); } return null; diff --git a/vendor/laravel/horizon/resources/sass/app.scss b/vendor/laravel/horizon/resources/sass/app.scss index 1b0bd1593..39a19f19c 100644 --- a/vendor/laravel/horizon/resources/sass/app.scss +++ b/vendor/laravel/horizon/resources/sass/app.scss @@ -1,4 +1,4 @@ -$font-family-base: Nunito; +$font-family-base: Nunito, sans-serif; $font-size-base: 0.95rem; $badge-font-size: 0.95rem; diff --git a/vendor/laravel/horizon/resources/sass/base.scss b/vendor/laravel/horizon/resources/sass/base.scss index 62fa81462..8c62005ae 100644 --- a/vendor/laravel/horizon/resources/sass/base.scss +++ b/vendor/laravel/horizon/resources/sass/base.scss @@ -172,6 +172,10 @@ button:hover { } } +.info-icon { + fill: $control-action-icon-color; +} + .paginator { .btn { text-decoration: none; diff --git a/vendor/laravel/horizon/resources/sass/syntaxhighlight.scss b/vendor/laravel/horizon/resources/sass/syntaxhighlight.scss index 2078f455f..2fbc1efa9 100644 --- a/vendor/laravel/horizon/resources/sass/syntaxhighlight.scss +++ b/vendor/laravel/horizon/resources/sass/syntaxhighlight.scss @@ -1,43 +1,27 @@ -.vjs__tree { - .vjs__tree__content { - border-left: 1px dotted rgba(204, 204, 204, 0.28) !important; +.vjs-tree { + font-family: 'Monaco', 'Menlo', 'Consolas', 'Bitstream Vera Sans Mono', monospace !important; + + &.is-root { + position: relative; } - .vjs__tree__node { + .vjs-tree__content { + padding-left: 1em; + &.has-line { + border-left: 1px dotted rgba(204, 204, 204, 0.28) !important; + } + } + .vjs-tree__brackets { cursor: pointer; &:hover { color: #20a0ff; } } - .vjs-checkbox { - position: absolute; - left: -30px; - } - .vjs__value__null { + .vjs-value__null, + .vjs-value__number, + .vjs-value__boolean { color: #a291f5 !important; } - .vjs__value__number, - .vjs__value__boolean { - color: #a291f5 !important; - } - .vjs__value__string { + .vjs-value__string { color: #dacb4d !important; } } - -.hljs-keyword, -.hljs-selector-tag, -.hljs-addition { - color: #8bd72f; -} - -.hljs-string, -.hljs-meta .hljs-meta-string, -.hljs-doctag, -.hljs-regexp { - color: #dacb4d; -} - -.hljs-number, -.hljs-literal { - color: #a291f5 !important; -} diff --git a/vendor/laravel/horizon/resources/views/layout.blade.php b/vendor/laravel/horizon/resources/views/layout.blade.php index da937f326..8910b65dc 100644 --- a/vendor/laravel/horizon/resources/views/layout.blade.php +++ b/vendor/laravel/horizon/resources/views/layout.blade.php @@ -28,7 +28,8 @@ -

Laravel Horizon{{ config('app.name') ? ' - ' . config('app.name') : '' }}

+

+ Laravel Horizon{{ config('app.name') ? ' - ' . config('app.name') : '' }}

@endif + @if ($isDownForMaintenance) +
+ This application is in "maintenance mode". Queued jobs may not be processed unless your worker is using the "force" flag. +
+ @endif +
- - - + + + + + + + + diff --git a/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/file_item_branch.html.dist b/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/file_item_branch.html.dist new file mode 100644 index 000000000..d7e479f62 --- /dev/null +++ b/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/file_item_branch.html.dist @@ -0,0 +1,20 @@ + + {{name}} + {{classes_bar}} +
{{classes_tested_percent}}
+
{{classes_number}}
+ {{methods_bar}} +
{{methods_tested_percent}}
+
{{methods_number}}
+ {{crap}} + {{paths_bar}} +
{{paths_executed_percent}}
+
{{paths_number}}
+ {{branches_bar}} +
{{branches_executed_percent}}
+
{{branches_number}}
+ {{lines_bar}} +
{{lines_executed_percent}}
+
{{lines_number}}
+ + diff --git a/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/js/bootstrap.min.js b/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/js/bootstrap.min.js index c4c0d1f95..3ecf55f28 100644 --- a/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/js/bootstrap.min.js +++ b/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/js/bootstrap.min.js @@ -1,7 +1,7 @@ /*! - * Bootstrap v4.3.1 (https://getbootstrap.com/) - * Copyright 2011-2019 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors) + * Bootstrap v4.5.0 (https://getbootstrap.com/) + * Copyright 2011-2020 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors) * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) */ -!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("jquery"),require("popper.js")):"function"==typeof define&&define.amd?define(["exports","jquery","popper.js"],e):e((t=t||self).bootstrap={},t.jQuery,t.Popper)}(this,function(t,g,u){"use strict";function i(t,e){for(var n=0;nthis._items.length-1||t<0))if(this._isSliding)g(this._element).one(Q.SLID,function(){return e.to(t)});else{if(n===t)return this.pause(),void this.cycle();var i=ndocument.documentElement.clientHeight;!this._isBodyOverflowing&&t&&(this._element.style.paddingLeft=this._scrollbarWidth+"px"),this._isBodyOverflowing&&!t&&(this._element.style.paddingRight=this._scrollbarWidth+"px")},t._resetAdjustments=function(){this._element.style.paddingLeft="",this._element.style.paddingRight=""},t._checkScrollbar=function(){var t=document.body.getBoundingClientRect();this._isBodyOverflowing=t.left+t.right
',trigger:"hover focus",title:"",delay:0,html:!1,selector:!1,placement:"top",offset:0,container:!1,fallbackPlacement:"flip",boundary:"scrollParent",sanitize:!0,sanitizeFn:null,whiteList:Ee},je="show",He="out",Re={HIDE:"hide"+De,HIDDEN:"hidden"+De,SHOW:"show"+De,SHOWN:"shown"+De,INSERTED:"inserted"+De,CLICK:"click"+De,FOCUSIN:"focusin"+De,FOCUSOUT:"focusout"+De,MOUSEENTER:"mouseenter"+De,MOUSELEAVE:"mouseleave"+De},xe="fade",Fe="show",Ue=".tooltip-inner",We=".arrow",qe="hover",Me="focus",Ke="click",Qe="manual",Be=function(){function i(t,e){if("undefined"==typeof u)throw new TypeError("Bootstrap's tooltips require Popper.js (https://popper.js.org/)");this._isEnabled=!0,this._timeout=0,this._hoverState="",this._activeTrigger={},this._popper=null,this.element=t,this.config=this._getConfig(e),this.tip=null,this._setListeners()}var t=i.prototype;return t.enable=function(){this._isEnabled=!0},t.disable=function(){this._isEnabled=!1},t.toggleEnabled=function(){this._isEnabled=!this._isEnabled},t.toggle=function(t){if(this._isEnabled)if(t){var e=this.constructor.DATA_KEY,n=g(t.currentTarget).data(e);n||(n=new this.constructor(t.currentTarget,this._getDelegateConfig()),g(t.currentTarget).data(e,n)),n._activeTrigger.click=!n._activeTrigger.click,n._isWithActiveTrigger()?n._enter(null,n):n._leave(null,n)}else{if(g(this.getTipElement()).hasClass(Fe))return void this._leave(null,this);this._enter(null,this)}},t.dispose=function(){clearTimeout(this._timeout),g.removeData(this.element,this.constructor.DATA_KEY),g(this.element).off(this.constructor.EVENT_KEY),g(this.element).closest(".modal").off("hide.bs.modal"),this.tip&&g(this.tip).remove(),this._isEnabled=null,this._timeout=null,this._hoverState=null,(this._activeTrigger=null)!==this._popper&&this._popper.destroy(),this._popper=null,this.element=null,this.config=null,this.tip=null},t.show=function(){var e=this;if("none"===g(this.element).css("display"))throw new Error("Please use show on visible elements");var t=g.Event(this.constructor.Event.SHOW);if(this.isWithContent()&&this._isEnabled){g(this.element).trigger(t);var n=_.findShadowRoot(this.element),i=g.contains(null!==n?n:this.element.ownerDocument.documentElement,this.element);if(t.isDefaultPrevented()||!i)return;var o=this.getTipElement(),r=_.getUID(this.constructor.NAME);o.setAttribute("id",r),this.element.setAttribute("aria-describedby",r),this.setContent(),this.config.animation&&g(o).addClass(xe);var s="function"==typeof this.config.placement?this.config.placement.call(this,o,this.element):this.config.placement,a=this._getAttachment(s);this.addAttachmentClass(a);var l=this._getContainer();g(o).data(this.constructor.DATA_KEY,this),g.contains(this.element.ownerDocument.documentElement,this.tip)||g(o).appendTo(l),g(this.element).trigger(this.constructor.Event.INSERTED),this._popper=new u(this.element,o,{placement:a,modifiers:{offset:this._getOffset(),flip:{behavior:this.config.fallbackPlacement},arrow:{element:We},preventOverflow:{boundariesElement:this.config.boundary}},onCreate:function(t){t.originalPlacement!==t.placement&&e._handlePopperPlacementChange(t)},onUpdate:function(t){return e._handlePopperPlacementChange(t)}}),g(o).addClass(Fe),"ontouchstart"in document.documentElement&&g(document.body).children().on("mouseover",null,g.noop);var c=function(){e.config.animation&&e._fixTransition();var t=e._hoverState;e._hoverState=null,g(e.element).trigger(e.constructor.Event.SHOWN),t===He&&e._leave(null,e)};if(g(this.tip).hasClass(xe)){var h=_.getTransitionDurationFromElement(this.tip);g(this.tip).one(_.TRANSITION_END,c).emulateTransitionEnd(h)}else c()}},t.hide=function(t){var e=this,n=this.getTipElement(),i=g.Event(this.constructor.Event.HIDE),o=function(){e._hoverState!==je&&n.parentNode&&n.parentNode.removeChild(n),e._cleanTipClass(),e.element.removeAttribute("aria-describedby"),g(e.element).trigger(e.constructor.Event.HIDDEN),null!==e._popper&&e._popper.destroy(),t&&t()};if(g(this.element).trigger(i),!i.isDefaultPrevented()){if(g(n).removeClass(Fe),"ontouchstart"in document.documentElement&&g(document.body).children().off("mouseover",null,g.noop),this._activeTrigger[Ke]=!1,this._activeTrigger[Me]=!1,this._activeTrigger[qe]=!1,g(this.tip).hasClass(xe)){var r=_.getTransitionDurationFromElement(n);g(n).one(_.TRANSITION_END,o).emulateTransitionEnd(r)}else o();this._hoverState=""}},t.update=function(){null!==this._popper&&this._popper.scheduleUpdate()},t.isWithContent=function(){return Boolean(this.getTitle())},t.addAttachmentClass=function(t){g(this.getTipElement()).addClass(Ae+"-"+t)},t.getTipElement=function(){return this.tip=this.tip||g(this.config.template)[0],this.tip},t.setContent=function(){var t=this.getTipElement();this.setElementContent(g(t.querySelectorAll(Ue)),this.getTitle()),g(t).removeClass(xe+" "+Fe)},t.setElementContent=function(t,e){"object"!=typeof e||!e.nodeType&&!e.jquery?this.config.html?(this.config.sanitize&&(e=Se(e,this.config.whiteList,this.config.sanitizeFn)),t.html(e)):t.text(e):this.config.html?g(e).parent().is(t)||t.empty().append(e):t.text(g(e).text())},t.getTitle=function(){var t=this.element.getAttribute("data-original-title");return t||(t="function"==typeof this.config.title?this.config.title.call(this.element):this.config.title),t},t._getOffset=function(){var e=this,t={};return"function"==typeof this.config.offset?t.fn=function(t){return t.offsets=l({},t.offsets,e.config.offset(t.offsets,e.element)||{}),t}:t.offset=this.config.offset,t},t._getContainer=function(){return!1===this.config.container?document.body:_.isElement(this.config.container)?g(this.config.container):g(document).find(this.config.container)},t._getAttachment=function(t){return Pe[t.toUpperCase()]},t._setListeners=function(){var i=this;this.config.trigger.split(" ").forEach(function(t){if("click"===t)g(i.element).on(i.constructor.Event.CLICK,i.config.selector,function(t){return i.toggle(t)});else if(t!==Qe){var e=t===qe?i.constructor.Event.MOUSEENTER:i.constructor.Event.FOCUSIN,n=t===qe?i.constructor.Event.MOUSELEAVE:i.constructor.Event.FOCUSOUT;g(i.element).on(e,i.config.selector,function(t){return i._enter(t)}).on(n,i.config.selector,function(t){return i._leave(t)})}}),g(this.element).closest(".modal").on("hide.bs.modal",function(){i.element&&i.hide()}),this.config.selector?this.config=l({},this.config,{trigger:"manual",selector:""}):this._fixTitle()},t._fixTitle=function(){var t=typeof this.element.getAttribute("data-original-title");(this.element.getAttribute("title")||"string"!==t)&&(this.element.setAttribute("data-original-title",this.element.getAttribute("title")||""),this.element.setAttribute("title",""))},t._enter=function(t,e){var n=this.constructor.DATA_KEY;(e=e||g(t.currentTarget).data(n))||(e=new this.constructor(t.currentTarget,this._getDelegateConfig()),g(t.currentTarget).data(n,e)),t&&(e._activeTrigger["focusin"===t.type?Me:qe]=!0),g(e.getTipElement()).hasClass(Fe)||e._hoverState===je?e._hoverState=je:(clearTimeout(e._timeout),e._hoverState=je,e.config.delay&&e.config.delay.show?e._timeout=setTimeout(function(){e._hoverState===je&&e.show()},e.config.delay.show):e.show())},t._leave=function(t,e){var n=this.constructor.DATA_KEY;(e=e||g(t.currentTarget).data(n))||(e=new this.constructor(t.currentTarget,this._getDelegateConfig()),g(t.currentTarget).data(n,e)),t&&(e._activeTrigger["focusout"===t.type?Me:qe]=!1),e._isWithActiveTrigger()||(clearTimeout(e._timeout),e._hoverState=He,e.config.delay&&e.config.delay.hide?e._timeout=setTimeout(function(){e._hoverState===He&&e.hide()},e.config.delay.hide):e.hide())},t._isWithActiveTrigger=function(){for(var t in this._activeTrigger)if(this._activeTrigger[t])return!0;return!1},t._getConfig=function(t){var e=g(this.element).data();return Object.keys(e).forEach(function(t){-1!==Oe.indexOf(t)&&delete e[t]}),"number"==typeof(t=l({},this.constructor.Default,e,"object"==typeof t&&t?t:{})).delay&&(t.delay={show:t.delay,hide:t.delay}),"number"==typeof t.title&&(t.title=t.title.toString()),"number"==typeof t.content&&(t.content=t.content.toString()),_.typeCheckConfig(be,t,this.constructor.DefaultType),t.sanitize&&(t.template=Se(t.template,t.whiteList,t.sanitizeFn)),t},t._getDelegateConfig=function(){var t={};if(this.config)for(var e in this.config)this.constructor.Default[e]!==this.config[e]&&(t[e]=this.config[e]);return t},t._cleanTipClass=function(){var t=g(this.getTipElement()),e=t.attr("class").match(Ne);null!==e&&e.length&&t.removeClass(e.join(""))},t._handlePopperPlacementChange=function(t){var e=t.instance;this.tip=e.popper,this._cleanTipClass(),this.addAttachmentClass(this._getAttachment(t.placement))},t._fixTransition=function(){var t=this.getTipElement(),e=this.config.animation;null===t.getAttribute("x-placement")&&(g(t).removeClass(xe),this.config.animation=!1,this.hide(),this.show(),this.config.animation=e)},i._jQueryInterface=function(n){return this.each(function(){var t=g(this).data(Ie),e="object"==typeof n&&n;if((t||!/dispose|hide/.test(n))&&(t||(t=new i(this,e),g(this).data(Ie,t)),"string"==typeof n)){if("undefined"==typeof t[n])throw new TypeError('No method named "'+n+'"');t[n]()}})},s(i,null,[{key:"VERSION",get:function(){return"4.3.1"}},{key:"Default",get:function(){return Le}},{key:"NAME",get:function(){return be}},{key:"DATA_KEY",get:function(){return Ie}},{key:"Event",get:function(){return Re}},{key:"EVENT_KEY",get:function(){return De}},{key:"DefaultType",get:function(){return ke}}]),i}();g.fn[be]=Be._jQueryInterface,g.fn[be].Constructor=Be,g.fn[be].noConflict=function(){return g.fn[be]=we,Be._jQueryInterface};var Ve="popover",Ye="bs.popover",ze="."+Ye,Xe=g.fn[Ve],$e="bs-popover",Ge=new RegExp("(^|\\s)"+$e+"\\S+","g"),Je=l({},Be.Default,{placement:"right",trigger:"click",content:"",template:''}),Ze=l({},Be.DefaultType,{content:"(string|element|function)"}),tn="fade",en="show",nn=".popover-header",on=".popover-body",rn={HIDE:"hide"+ze,HIDDEN:"hidden"+ze,SHOW:"show"+ze,SHOWN:"shown"+ze,INSERTED:"inserted"+ze,CLICK:"click"+ze,FOCUSIN:"focusin"+ze,FOCUSOUT:"focusout"+ze,MOUSEENTER:"mouseenter"+ze,MOUSELEAVE:"mouseleave"+ze},sn=function(t){var e,n;function i(){return t.apply(this,arguments)||this}n=t,(e=i).prototype=Object.create(n.prototype),(e.prototype.constructor=e).__proto__=n;var o=i.prototype;return o.isWithContent=function(){return this.getTitle()||this._getContent()},o.addAttachmentClass=function(t){g(this.getTipElement()).addClass($e+"-"+t)},o.getTipElement=function(){return this.tip=this.tip||g(this.config.template)[0],this.tip},o.setContent=function(){var t=g(this.getTipElement());this.setElementContent(t.find(nn),this.getTitle());var e=this._getContent();"function"==typeof e&&(e=e.call(this.element)),this.setElementContent(t.find(on),e),t.removeClass(tn+" "+en)},o._getContent=function(){return this.element.getAttribute("data-content")||this.config.content},o._cleanTipClass=function(){var t=g(this.getTipElement()),e=t.attr("class").match(Ge);null!==e&&0=this._offsets[o]&&("undefined"==typeof this._offsets[o+1]||t=4)throw new Error("Bootstrap's JavaScript requires at least jQuery v1.9.1 but less than v4.0.0")}};c.jQueryDetection(),e.fn.emulateTransitionEnd=l,e.event.special[c.TRANSITION_END]={bindType:"transitionend",delegateType:"transitionend",handle:function(t){if(e(t.target).is(this))return t.handleObj.handler.apply(this,arguments)}};var h="alert",u=e.fn[h],d=function(){function t(t){this._element=t}var n=t.prototype;return n.close=function(t){var e=this._element;t&&(e=this._getRootElement(t)),this._triggerCloseEvent(e).isDefaultPrevented()||this._removeElement(e)},n.dispose=function(){e.removeData(this._element,"bs.alert"),this._element=null},n._getRootElement=function(t){var n=c.getSelectorFromElement(t),i=!1;return n&&(i=document.querySelector(n)),i||(i=e(t).closest(".alert")[0]),i},n._triggerCloseEvent=function(t){var n=e.Event("close.bs.alert");return e(t).trigger(n),n},n._removeElement=function(t){var n=this;if(e(t).removeClass("show"),e(t).hasClass("fade")){var i=c.getTransitionDurationFromElement(t);e(t).one(c.TRANSITION_END,(function(e){return n._destroyElement(t,e)})).emulateTransitionEnd(i)}else this._destroyElement(t)},n._destroyElement=function(t){e(t).detach().trigger("closed.bs.alert").remove()},t._jQueryInterface=function(n){return this.each((function(){var i=e(this),o=i.data("bs.alert");o||(o=new t(this),i.data("bs.alert",o)),"close"===n&&o[n](this)}))},t._handleDismiss=function(t){return function(e){e&&e.preventDefault(),t.close(this)}},o(t,null,[{key:"VERSION",get:function(){return"4.5.0"}}]),t}();e(document).on("click.bs.alert.data-api",'[data-dismiss="alert"]',d._handleDismiss(new d)),e.fn[h]=d._jQueryInterface,e.fn[h].Constructor=d,e.fn[h].noConflict=function(){return e.fn[h]=u,d._jQueryInterface};var f=e.fn.button,g=function(){function t(t){this._element=t}var n=t.prototype;return n.toggle=function(){var t=!0,n=!0,i=e(this._element).closest('[data-toggle="buttons"]')[0];if(i){var o=this._element.querySelector('input:not([type="hidden"])');if(o){if("radio"===o.type)if(o.checked&&this._element.classList.contains("active"))t=!1;else{var s=i.querySelector(".active");s&&e(s).removeClass("active")}t&&("checkbox"!==o.type&&"radio"!==o.type||(o.checked=!this._element.classList.contains("active")),e(o).trigger("change")),o.focus(),n=!1}}this._element.hasAttribute("disabled")||this._element.classList.contains("disabled")||(n&&this._element.setAttribute("aria-pressed",!this._element.classList.contains("active")),t&&e(this._element).toggleClass("active"))},n.dispose=function(){e.removeData(this._element,"bs.button"),this._element=null},t._jQueryInterface=function(n){return this.each((function(){var i=e(this).data("bs.button");i||(i=new t(this),e(this).data("bs.button",i)),"toggle"===n&&i[n]()}))},o(t,null,[{key:"VERSION",get:function(){return"4.5.0"}}]),t}();e(document).on("click.bs.button.data-api",'[data-toggle^="button"]',(function(t){var n=t.target,i=n;if(e(n).hasClass("btn")||(n=e(n).closest(".btn")[0]),!n||n.hasAttribute("disabled")||n.classList.contains("disabled"))t.preventDefault();else{var o=n.querySelector('input:not([type="hidden"])');if(o&&(o.hasAttribute("disabled")||o.classList.contains("disabled")))return void t.preventDefault();"LABEL"===i.tagName&&o&&"checkbox"===o.type&&t.preventDefault(),g._jQueryInterface.call(e(n),"toggle")}})).on("focus.bs.button.data-api blur.bs.button.data-api",'[data-toggle^="button"]',(function(t){var n=e(t.target).closest(".btn")[0];e(n).toggleClass("focus",/^focus(in)?$/.test(t.type))})),e(window).on("load.bs.button.data-api",(function(){for(var t=[].slice.call(document.querySelectorAll('[data-toggle="buttons"] .btn')),e=0,n=t.length;e0,this._pointerEvent=Boolean(window.PointerEvent||window.MSPointerEvent),this._addEventListeners()}var n=t.prototype;return n.next=function(){this._isSliding||this._slide("next")},n.nextWhenVisible=function(){!document.hidden&&e(this._element).is(":visible")&&"hidden"!==e(this._element).css("visibility")&&this.next()},n.prev=function(){this._isSliding||this._slide("prev")},n.pause=function(t){t||(this._isPaused=!0),this._element.querySelector(".carousel-item-next, .carousel-item-prev")&&(c.triggerTransitionEnd(this._element),this.cycle(!0)),clearInterval(this._interval),this._interval=null},n.cycle=function(t){t||(this._isPaused=!1),this._interval&&(clearInterval(this._interval),this._interval=null),this._config.interval&&!this._isPaused&&(this._interval=setInterval((document.visibilityState?this.nextWhenVisible:this.next).bind(this),this._config.interval))},n.to=function(t){var n=this;this._activeElement=this._element.querySelector(".active.carousel-item");var i=this._getItemIndex(this._activeElement);if(!(t>this._items.length-1||t<0))if(this._isSliding)e(this._element).one("slid.bs.carousel",(function(){return n.to(t)}));else{if(i===t)return this.pause(),void this.cycle();var o=t>i?"next":"prev";this._slide(o,this._items[t])}},n.dispose=function(){e(this._element).off(p),e.removeData(this._element,"bs.carousel"),this._items=null,this._config=null,this._element=null,this._interval=null,this._isPaused=null,this._isSliding=null,this._activeElement=null,this._indicatorsElement=null},n._getConfig=function(t){return t=a(a({},v),t),c.typeCheckConfig(m,t,b),t},n._handleSwipe=function(){var t=Math.abs(this.touchDeltaX);if(!(t<=40)){var e=t/this.touchDeltaX;this.touchDeltaX=0,e>0&&this.prev(),e<0&&this.next()}},n._addEventListeners=function(){var t=this;this._config.keyboard&&e(this._element).on("keydown.bs.carousel",(function(e){return t._keydown(e)})),"hover"===this._config.pause&&e(this._element).on("mouseenter.bs.carousel",(function(e){return t.pause(e)})).on("mouseleave.bs.carousel",(function(e){return t.cycle(e)})),this._config.touch&&this._addTouchEventListeners()},n._addTouchEventListeners=function(){var t=this;if(this._touchSupported){var n=function(e){t._pointerEvent&&y[e.originalEvent.pointerType.toUpperCase()]?t.touchStartX=e.originalEvent.clientX:t._pointerEvent||(t.touchStartX=e.originalEvent.touches[0].clientX)},i=function(e){t._pointerEvent&&y[e.originalEvent.pointerType.toUpperCase()]&&(t.touchDeltaX=e.originalEvent.clientX-t.touchStartX),t._handleSwipe(),"hover"===t._config.pause&&(t.pause(),t.touchTimeout&&clearTimeout(t.touchTimeout),t.touchTimeout=setTimeout((function(e){return t.cycle(e)}),500+t._config.interval))};e(this._element.querySelectorAll(".carousel-item img")).on("dragstart.bs.carousel",(function(t){return t.preventDefault()})),this._pointerEvent?(e(this._element).on("pointerdown.bs.carousel",(function(t){return n(t)})),e(this._element).on("pointerup.bs.carousel",(function(t){return i(t)})),this._element.classList.add("pointer-event")):(e(this._element).on("touchstart.bs.carousel",(function(t){return n(t)})),e(this._element).on("touchmove.bs.carousel",(function(e){return function(e){e.originalEvent.touches&&e.originalEvent.touches.length>1?t.touchDeltaX=0:t.touchDeltaX=e.originalEvent.touches[0].clientX-t.touchStartX}(e)})),e(this._element).on("touchend.bs.carousel",(function(t){return i(t)})))}},n._keydown=function(t){if(!/input|textarea/i.test(t.target.tagName))switch(t.which){case 37:t.preventDefault(),this.prev();break;case 39:t.preventDefault(),this.next()}},n._getItemIndex=function(t){return this._items=t&&t.parentNode?[].slice.call(t.parentNode.querySelectorAll(".carousel-item")):[],this._items.indexOf(t)},n._getItemByDirection=function(t,e){var n="next"===t,i="prev"===t,o=this._getItemIndex(e),s=this._items.length-1;if((i&&0===o||n&&o===s)&&!this._config.wrap)return e;var r=(o+("prev"===t?-1:1))%this._items.length;return-1===r?this._items[this._items.length-1]:this._items[r]},n._triggerSlideEvent=function(t,n){var i=this._getItemIndex(t),o=this._getItemIndex(this._element.querySelector(".active.carousel-item")),s=e.Event("slide.bs.carousel",{relatedTarget:t,direction:n,from:o,to:i});return e(this._element).trigger(s),s},n._setActiveIndicatorElement=function(t){if(this._indicatorsElement){var n=[].slice.call(this._indicatorsElement.querySelectorAll(".active"));e(n).removeClass("active");var i=this._indicatorsElement.children[this._getItemIndex(t)];i&&e(i).addClass("active")}},n._slide=function(t,n){var i,o,s,r=this,a=this._element.querySelector(".active.carousel-item"),l=this._getItemIndex(a),h=n||a&&this._getItemByDirection(t,a),u=this._getItemIndex(h),d=Boolean(this._interval);if("next"===t?(i="carousel-item-left",o="carousel-item-next",s="left"):(i="carousel-item-right",o="carousel-item-prev",s="right"),h&&e(h).hasClass("active"))this._isSliding=!1;else if(!this._triggerSlideEvent(h,s).isDefaultPrevented()&&a&&h){this._isSliding=!0,d&&this.pause(),this._setActiveIndicatorElement(h);var f=e.Event("slid.bs.carousel",{relatedTarget:h,direction:s,from:l,to:u});if(e(this._element).hasClass("slide")){e(h).addClass(o),c.reflow(h),e(a).addClass(i),e(h).addClass(i);var g=parseInt(h.getAttribute("data-interval"),10);g?(this._config.defaultInterval=this._config.defaultInterval||this._config.interval,this._config.interval=g):this._config.interval=this._config.defaultInterval||this._config.interval;var m=c.getTransitionDurationFromElement(a);e(a).one(c.TRANSITION_END,(function(){e(h).removeClass(i+" "+o).addClass("active"),e(a).removeClass("active "+o+" "+i),r._isSliding=!1,setTimeout((function(){return e(r._element).trigger(f)}),0)})).emulateTransitionEnd(m)}else e(a).removeClass("active"),e(h).addClass("active"),this._isSliding=!1,e(this._element).trigger(f);d&&this.cycle()}},t._jQueryInterface=function(n){return this.each((function(){var i=e(this).data("bs.carousel"),o=a(a({},v),e(this).data());"object"==typeof n&&(o=a(a({},o),n));var s="string"==typeof n?n:o.slide;if(i||(i=new t(this,o),e(this).data("bs.carousel",i)),"number"==typeof n)i.to(n);else if("string"==typeof s){if("undefined"==typeof i[s])throw new TypeError('No method named "'+s+'"');i[s]()}else o.interval&&o.ride&&(i.pause(),i.cycle())}))},t._dataApiClickHandler=function(n){var i=c.getSelectorFromElement(this);if(i){var o=e(i)[0];if(o&&e(o).hasClass("carousel")){var s=a(a({},e(o).data()),e(this).data()),r=this.getAttribute("data-slide-to");r&&(s.interval=!1),t._jQueryInterface.call(e(o),s),r&&e(o).data("bs.carousel").to(r),n.preventDefault()}}},o(t,null,[{key:"VERSION",get:function(){return"4.5.0"}},{key:"Default",get:function(){return v}}]),t}();e(document).on("click.bs.carousel.data-api","[data-slide], [data-slide-to]",E._dataApiClickHandler),e(window).on("load.bs.carousel.data-api",(function(){for(var t=[].slice.call(document.querySelectorAll('[data-ride="carousel"]')),n=0,i=t.length;n0&&(this._selector=r,this._triggerArray.push(s))}this._parent=this._config.parent?this._getParent():null,this._config.parent||this._addAriaAndCollapsedClass(this._element,this._triggerArray),this._config.toggle&&this.toggle()}var n=t.prototype;return n.toggle=function(){e(this._element).hasClass("show")?this.hide():this.show()},n.show=function(){var n,i,o=this;if(!this._isTransitioning&&!e(this._element).hasClass("show")&&(this._parent&&0===(n=[].slice.call(this._parent.querySelectorAll(".show, .collapsing")).filter((function(t){return"string"==typeof o._config.parent?t.getAttribute("data-parent")===o._config.parent:t.classList.contains("collapse")}))).length&&(n=null),!(n&&(i=e(n).not(this._selector).data("bs.collapse"))&&i._isTransitioning))){var s=e.Event("show.bs.collapse");if(e(this._element).trigger(s),!s.isDefaultPrevented()){n&&(t._jQueryInterface.call(e(n).not(this._selector),"hide"),i||e(n).data("bs.collapse",null));var r=this._getDimension();e(this._element).removeClass("collapse").addClass("collapsing"),this._element.style[r]=0,this._triggerArray.length&&e(this._triggerArray).removeClass("collapsed").attr("aria-expanded",!0),this.setTransitioning(!0);var a="scroll"+(r[0].toUpperCase()+r.slice(1)),l=c.getTransitionDurationFromElement(this._element);e(this._element).one(c.TRANSITION_END,(function(){e(o._element).removeClass("collapsing").addClass("collapse show"),o._element.style[r]="",o.setTransitioning(!1),e(o._element).trigger("shown.bs.collapse")})).emulateTransitionEnd(l),this._element.style[r]=this._element[a]+"px"}}},n.hide=function(){var t=this;if(!this._isTransitioning&&e(this._element).hasClass("show")){var n=e.Event("hide.bs.collapse");if(e(this._element).trigger(n),!n.isDefaultPrevented()){var i=this._getDimension();this._element.style[i]=this._element.getBoundingClientRect()[i]+"px",c.reflow(this._element),e(this._element).addClass("collapsing").removeClass("collapse show");var o=this._triggerArray.length;if(o>0)for(var s=0;s0},i._getOffset=function(){var t=this,e={};return"function"==typeof this._config.offset?e.fn=function(e){return e.offsets=a(a({},e.offsets),t._config.offset(e.offsets,t._element)||{}),e}:e.offset=this._config.offset,e},i._getPopperConfig=function(){var t={placement:this._getPlacement(),modifiers:{offset:this._getOffset(),flip:{enabled:this._config.flip},preventOverflow:{boundariesElement:this._config.boundary}}};return"static"===this._config.display&&(t.modifiers.applyStyle={enabled:!1}),a(a({},t),this._config.popperConfig)},t._jQueryInterface=function(n){return this.each((function(){var i=e(this).data("bs.dropdown");if(i||(i=new t(this,"object"==typeof n?n:null),e(this).data("bs.dropdown",i)),"string"==typeof n){if("undefined"==typeof i[n])throw new TypeError('No method named "'+n+'"');i[n]()}}))},t._clearMenus=function(n){if(!n||3!==n.which&&("keyup"!==n.type||9===n.which))for(var i=[].slice.call(document.querySelectorAll('[data-toggle="dropdown"]')),o=0,s=i.length;o0&&r--,40===n.which&&rdocument.documentElement.clientHeight;!this._isBodyOverflowing&&t&&(this._element.style.paddingLeft=this._scrollbarWidth+"px"),this._isBodyOverflowing&&!t&&(this._element.style.paddingRight=this._scrollbarWidth+"px")},n._resetAdjustments=function(){this._element.style.paddingLeft="",this._element.style.paddingRight=""},n._checkScrollbar=function(){var t=document.body.getBoundingClientRect();this._isBodyOverflowing=Math.round(t.left+t.right)
',trigger:"hover focus",title:"",delay:0,html:!1,selector:!1,placement:"top",offset:0,container:!1,fallbackPlacement:"flip",boundary:"scrollParent",sanitize:!0,sanitizeFn:null,whiteList:F,popperConfig:null},Y={HIDE:"hide.bs.tooltip",HIDDEN:"hidden.bs.tooltip",SHOW:"show.bs.tooltip",SHOWN:"shown.bs.tooltip",INSERTED:"inserted.bs.tooltip",CLICK:"click.bs.tooltip",FOCUSIN:"focusin.bs.tooltip",FOCUSOUT:"focusout.bs.tooltip",MOUSEENTER:"mouseenter.bs.tooltip",MOUSELEAVE:"mouseleave.bs.tooltip"},$=function(){function t(t,e){if("undefined"==typeof n)throw new TypeError("Bootstrap's tooltips require Popper.js (https://popper.js.org/)");this._isEnabled=!0,this._timeout=0,this._hoverState="",this._activeTrigger={},this._popper=null,this.element=t,this.config=this._getConfig(e),this.tip=null,this._setListeners()}var i=t.prototype;return i.enable=function(){this._isEnabled=!0},i.disable=function(){this._isEnabled=!1},i.toggleEnabled=function(){this._isEnabled=!this._isEnabled},i.toggle=function(t){if(this._isEnabled)if(t){var n=this.constructor.DATA_KEY,i=e(t.currentTarget).data(n);i||(i=new this.constructor(t.currentTarget,this._getDelegateConfig()),e(t.currentTarget).data(n,i)),i._activeTrigger.click=!i._activeTrigger.click,i._isWithActiveTrigger()?i._enter(null,i):i._leave(null,i)}else{if(e(this.getTipElement()).hasClass("show"))return void this._leave(null,this);this._enter(null,this)}},i.dispose=function(){clearTimeout(this._timeout),e.removeData(this.element,this.constructor.DATA_KEY),e(this.element).off(this.constructor.EVENT_KEY),e(this.element).closest(".modal").off("hide.bs.modal",this._hideModalHandler),this.tip&&e(this.tip).remove(),this._isEnabled=null,this._timeout=null,this._hoverState=null,this._activeTrigger=null,this._popper&&this._popper.destroy(),this._popper=null,this.element=null,this.config=null,this.tip=null},i.show=function(){var t=this;if("none"===e(this.element).css("display"))throw new Error("Please use show on visible elements");var i=e.Event(this.constructor.Event.SHOW);if(this.isWithContent()&&this._isEnabled){e(this.element).trigger(i);var o=c.findShadowRoot(this.element),s=e.contains(null!==o?o:this.element.ownerDocument.documentElement,this.element);if(i.isDefaultPrevented()||!s)return;var r=this.getTipElement(),a=c.getUID(this.constructor.NAME);r.setAttribute("id",a),this.element.setAttribute("aria-describedby",a),this.setContent(),this.config.animation&&e(r).addClass("fade");var l="function"==typeof this.config.placement?this.config.placement.call(this,r,this.element):this.config.placement,h=this._getAttachment(l);this.addAttachmentClass(h);var u=this._getContainer();e(r).data(this.constructor.DATA_KEY,this),e.contains(this.element.ownerDocument.documentElement,this.tip)||e(r).appendTo(u),e(this.element).trigger(this.constructor.Event.INSERTED),this._popper=new n(this.element,r,this._getPopperConfig(h)),e(r).addClass("show"),"ontouchstart"in document.documentElement&&e(document.body).children().on("mouseover",null,e.noop);var d=function(){t.config.animation&&t._fixTransition();var n=t._hoverState;t._hoverState=null,e(t.element).trigger(t.constructor.Event.SHOWN),"out"===n&&t._leave(null,t)};if(e(this.tip).hasClass("fade")){var f=c.getTransitionDurationFromElement(this.tip);e(this.tip).one(c.TRANSITION_END,d).emulateTransitionEnd(f)}else d()}},i.hide=function(t){var n=this,i=this.getTipElement(),o=e.Event(this.constructor.Event.HIDE),s=function(){"show"!==n._hoverState&&i.parentNode&&i.parentNode.removeChild(i),n._cleanTipClass(),n.element.removeAttribute("aria-describedby"),e(n.element).trigger(n.constructor.Event.HIDDEN),null!==n._popper&&n._popper.destroy(),t&&t()};if(e(this.element).trigger(o),!o.isDefaultPrevented()){if(e(i).removeClass("show"),"ontouchstart"in document.documentElement&&e(document.body).children().off("mouseover",null,e.noop),this._activeTrigger.click=!1,this._activeTrigger.focus=!1,this._activeTrigger.hover=!1,e(this.tip).hasClass("fade")){var r=c.getTransitionDurationFromElement(i);e(i).one(c.TRANSITION_END,s).emulateTransitionEnd(r)}else s();this._hoverState=""}},i.update=function(){null!==this._popper&&this._popper.scheduleUpdate()},i.isWithContent=function(){return Boolean(this.getTitle())},i.addAttachmentClass=function(t){e(this.getTipElement()).addClass("bs-tooltip-"+t)},i.getTipElement=function(){return this.tip=this.tip||e(this.config.template)[0],this.tip},i.setContent=function(){var t=this.getTipElement();this.setElementContent(e(t.querySelectorAll(".tooltip-inner")),this.getTitle()),e(t).removeClass("fade show")},i.setElementContent=function(t,n){"object"!=typeof n||!n.nodeType&&!n.jquery?this.config.html?(this.config.sanitize&&(n=H(n,this.config.whiteList,this.config.sanitizeFn)),t.html(n)):t.text(n):this.config.html?e(n).parent().is(t)||t.empty().append(n):t.text(e(n).text())},i.getTitle=function(){var t=this.element.getAttribute("data-original-title");return t||(t="function"==typeof this.config.title?this.config.title.call(this.element):this.config.title),t},i._getPopperConfig=function(t){var e=this;return a(a({},{placement:t,modifiers:{offset:this._getOffset(),flip:{behavior:this.config.fallbackPlacement},arrow:{element:".arrow"},preventOverflow:{boundariesElement:this.config.boundary}},onCreate:function(t){t.originalPlacement!==t.placement&&e._handlePopperPlacementChange(t)},onUpdate:function(t){return e._handlePopperPlacementChange(t)}}),this.config.popperConfig)},i._getOffset=function(){var t=this,e={};return"function"==typeof this.config.offset?e.fn=function(e){return e.offsets=a(a({},e.offsets),t.config.offset(e.offsets,t.element)||{}),e}:e.offset=this.config.offset,e},i._getContainer=function(){return!1===this.config.container?document.body:c.isElement(this.config.container)?e(this.config.container):e(document).find(this.config.container)},i._getAttachment=function(t){return K[t.toUpperCase()]},i._setListeners=function(){var t=this;this.config.trigger.split(" ").forEach((function(n){if("click"===n)e(t.element).on(t.constructor.Event.CLICK,t.config.selector,(function(e){return t.toggle(e)}));else if("manual"!==n){var i="hover"===n?t.constructor.Event.MOUSEENTER:t.constructor.Event.FOCUSIN,o="hover"===n?t.constructor.Event.MOUSELEAVE:t.constructor.Event.FOCUSOUT;e(t.element).on(i,t.config.selector,(function(e){return t._enter(e)})).on(o,t.config.selector,(function(e){return t._leave(e)}))}})),this._hideModalHandler=function(){t.element&&t.hide()},e(this.element).closest(".modal").on("hide.bs.modal",this._hideModalHandler),this.config.selector?this.config=a(a({},this.config),{},{trigger:"manual",selector:""}):this._fixTitle()},i._fixTitle=function(){var t=typeof this.element.getAttribute("data-original-title");(this.element.getAttribute("title")||"string"!==t)&&(this.element.setAttribute("data-original-title",this.element.getAttribute("title")||""),this.element.setAttribute("title",""))},i._enter=function(t,n){var i=this.constructor.DATA_KEY;(n=n||e(t.currentTarget).data(i))||(n=new this.constructor(t.currentTarget,this._getDelegateConfig()),e(t.currentTarget).data(i,n)),t&&(n._activeTrigger["focusin"===t.type?"focus":"hover"]=!0),e(n.getTipElement()).hasClass("show")||"show"===n._hoverState?n._hoverState="show":(clearTimeout(n._timeout),n._hoverState="show",n.config.delay&&n.config.delay.show?n._timeout=setTimeout((function(){"show"===n._hoverState&&n.show()}),n.config.delay.show):n.show())},i._leave=function(t,n){var i=this.constructor.DATA_KEY;(n=n||e(t.currentTarget).data(i))||(n=new this.constructor(t.currentTarget,this._getDelegateConfig()),e(t.currentTarget).data(i,n)),t&&(n._activeTrigger["focusout"===t.type?"focus":"hover"]=!1),n._isWithActiveTrigger()||(clearTimeout(n._timeout),n._hoverState="out",n.config.delay&&n.config.delay.hide?n._timeout=setTimeout((function(){"out"===n._hoverState&&n.hide()}),n.config.delay.hide):n.hide())},i._isWithActiveTrigger=function(){for(var t in this._activeTrigger)if(this._activeTrigger[t])return!0;return!1},i._getConfig=function(t){var n=e(this.element).data();return Object.keys(n).forEach((function(t){-1!==V.indexOf(t)&&delete n[t]})),"number"==typeof(t=a(a(a({},this.constructor.Default),n),"object"==typeof t&&t?t:{})).delay&&(t.delay={show:t.delay,hide:t.delay}),"number"==typeof t.title&&(t.title=t.title.toString()),"number"==typeof t.content&&(t.content=t.content.toString()),c.typeCheckConfig(U,t,this.constructor.DefaultType),t.sanitize&&(t.template=H(t.template,t.whiteList,t.sanitizeFn)),t},i._getDelegateConfig=function(){var t={};if(this.config)for(var e in this.config)this.constructor.Default[e]!==this.config[e]&&(t[e]=this.config[e]);return t},i._cleanTipClass=function(){var t=e(this.getTipElement()),n=t.attr("class").match(W);null!==n&&n.length&&t.removeClass(n.join(""))},i._handlePopperPlacementChange=function(t){this.tip=t.instance.popper,this._cleanTipClass(),this.addAttachmentClass(this._getAttachment(t.placement))},i._fixTransition=function(){var t=this.getTipElement(),n=this.config.animation;null===t.getAttribute("x-placement")&&(e(t).removeClass("fade"),this.config.animation=!1,this.hide(),this.show(),this.config.animation=n)},t._jQueryInterface=function(n){return this.each((function(){var i=e(this).data("bs.tooltip"),o="object"==typeof n&&n;if((i||!/dispose|hide/.test(n))&&(i||(i=new t(this,o),e(this).data("bs.tooltip",i)),"string"==typeof n)){if("undefined"==typeof i[n])throw new TypeError('No method named "'+n+'"');i[n]()}}))},o(t,null,[{key:"VERSION",get:function(){return"4.5.0"}},{key:"Default",get:function(){return X}},{key:"NAME",get:function(){return U}},{key:"DATA_KEY",get:function(){return"bs.tooltip"}},{key:"Event",get:function(){return Y}},{key:"EVENT_KEY",get:function(){return".bs.tooltip"}},{key:"DefaultType",get:function(){return z}}]),t}();e.fn[U]=$._jQueryInterface,e.fn[U].Constructor=$,e.fn[U].noConflict=function(){return e.fn[U]=M,$._jQueryInterface};var J="popover",G=e.fn[J],Z=new RegExp("(^|\\s)bs-popover\\S+","g"),tt=a(a({},$.Default),{},{placement:"right",trigger:"click",content:"",template:''}),et=a(a({},$.DefaultType),{},{content:"(string|element|function)"}),nt={HIDE:"hide.bs.popover",HIDDEN:"hidden.bs.popover",SHOW:"show.bs.popover",SHOWN:"shown.bs.popover",INSERTED:"inserted.bs.popover",CLICK:"click.bs.popover",FOCUSIN:"focusin.bs.popover",FOCUSOUT:"focusout.bs.popover",MOUSEENTER:"mouseenter.bs.popover",MOUSELEAVE:"mouseleave.bs.popover"},it=function(t){var n,i;function s(){return t.apply(this,arguments)||this}i=t,(n=s).prototype=Object.create(i.prototype),n.prototype.constructor=n,n.__proto__=i;var r=s.prototype;return r.isWithContent=function(){return this.getTitle()||this._getContent()},r.addAttachmentClass=function(t){e(this.getTipElement()).addClass("bs-popover-"+t)},r.getTipElement=function(){return this.tip=this.tip||e(this.config.template)[0],this.tip},r.setContent=function(){var t=e(this.getTipElement());this.setElementContent(t.find(".popover-header"),this.getTitle());var n=this._getContent();"function"==typeof n&&(n=n.call(this.element)),this.setElementContent(t.find(".popover-body"),n),t.removeClass("fade show")},r._getContent=function(){return this.element.getAttribute("data-content")||this.config.content},r._cleanTipClass=function(){var t=e(this.getTipElement()),n=t.attr("class").match(Z);null!==n&&n.length>0&&t.removeClass(n.join(""))},s._jQueryInterface=function(t){return this.each((function(){var n=e(this).data("bs.popover"),i="object"==typeof t?t:null;if((n||!/dispose|hide/.test(t))&&(n||(n=new s(this,i),e(this).data("bs.popover",n)),"string"==typeof t)){if("undefined"==typeof n[t])throw new TypeError('No method named "'+t+'"');n[t]()}}))},o(s,null,[{key:"VERSION",get:function(){return"4.5.0"}},{key:"Default",get:function(){return tt}},{key:"NAME",get:function(){return J}},{key:"DATA_KEY",get:function(){return"bs.popover"}},{key:"Event",get:function(){return nt}},{key:"EVENT_KEY",get:function(){return".bs.popover"}},{key:"DefaultType",get:function(){return et}}]),s}($);e.fn[J]=it._jQueryInterface,e.fn[J].Constructor=it,e.fn[J].noConflict=function(){return e.fn[J]=G,it._jQueryInterface};var ot="scrollspy",st=e.fn[ot],rt={offset:10,method:"auto",target:""},at={offset:"number",method:"string",target:"(string|element)"},lt=function(){function t(t,n){var i=this;this._element=t,this._scrollElement="BODY"===t.tagName?window:t,this._config=this._getConfig(n),this._selector=this._config.target+" .nav-link,"+this._config.target+" .list-group-item,"+this._config.target+" .dropdown-item",this._offsets=[],this._targets=[],this._activeTarget=null,this._scrollHeight=0,e(this._scrollElement).on("scroll.bs.scrollspy",(function(t){return i._process(t)})),this.refresh(),this._process()}var n=t.prototype;return n.refresh=function(){var t=this,n=this._scrollElement===this._scrollElement.window?"offset":"position",i="auto"===this._config.method?n:this._config.method,o="position"===i?this._getScrollTop():0;this._offsets=[],this._targets=[],this._scrollHeight=this._getScrollHeight(),[].slice.call(document.querySelectorAll(this._selector)).map((function(t){var n,s=c.getSelectorFromElement(t);if(s&&(n=document.querySelector(s)),n){var r=n.getBoundingClientRect();if(r.width||r.height)return[e(n)[i]().top+o,s]}return null})).filter((function(t){return t})).sort((function(t,e){return t[0]-e[0]})).forEach((function(e){t._offsets.push(e[0]),t._targets.push(e[1])}))},n.dispose=function(){e.removeData(this._element,"bs.scrollspy"),e(this._scrollElement).off(".bs.scrollspy"),this._element=null,this._scrollElement=null,this._config=null,this._selector=null,this._offsets=null,this._targets=null,this._activeTarget=null,this._scrollHeight=null},n._getConfig=function(t){if("string"!=typeof(t=a(a({},rt),"object"==typeof t&&t?t:{})).target&&c.isElement(t.target)){var n=e(t.target).attr("id");n||(n=c.getUID(ot),e(t.target).attr("id",n)),t.target="#"+n}return c.typeCheckConfig(ot,t,at),t},n._getScrollTop=function(){return this._scrollElement===window?this._scrollElement.pageYOffset:this._scrollElement.scrollTop},n._getScrollHeight=function(){return this._scrollElement.scrollHeight||Math.max(document.body.scrollHeight,document.documentElement.scrollHeight)},n._getOffsetHeight=function(){return this._scrollElement===window?window.innerHeight:this._scrollElement.getBoundingClientRect().height},n._process=function(){var t=this._getScrollTop()+this._config.offset,e=this._getScrollHeight(),n=this._config.offset+e-this._getOffsetHeight();if(this._scrollHeight!==e&&this.refresh(),t>=n){var i=this._targets[this._targets.length-1];this._activeTarget!==i&&this._activate(i)}else{if(this._activeTarget&&t0)return this._activeTarget=null,void this._clear();for(var o=this._offsets.length;o--;){this._activeTarget!==this._targets[o]&&t>=this._offsets[o]&&("undefined"==typeof this._offsets[o+1]||t li > .active":".active";i=(i=e.makeArray(e(o).find(r)))[i.length-1]}var a=e.Event("hide.bs.tab",{relatedTarget:this._element}),l=e.Event("show.bs.tab",{relatedTarget:i});if(i&&e(i).trigger(a),e(this._element).trigger(l),!l.isDefaultPrevented()&&!a.isDefaultPrevented()){s&&(n=document.querySelector(s)),this._activate(this._element,o);var h=function(){var n=e.Event("hidden.bs.tab",{relatedTarget:t._element}),o=e.Event("shown.bs.tab",{relatedTarget:i});e(i).trigger(n),e(t._element).trigger(o)};n?this._activate(n,n.parentNode,h):h()}}},n.dispose=function(){e.removeData(this._element,"bs.tab"),this._element=null},n._activate=function(t,n,i){var o=this,s=(!n||"UL"!==n.nodeName&&"OL"!==n.nodeName?e(n).children(".active"):e(n).find("> li > .active"))[0],r=i&&s&&e(s).hasClass("fade"),a=function(){return o._transitionComplete(t,s,i)};if(s&&r){var l=c.getTransitionDurationFromElement(s);e(s).removeClass("show").one(c.TRANSITION_END,a).emulateTransitionEnd(l)}else a()},n._transitionComplete=function(t,n,i){if(n){e(n).removeClass("active");var o=e(n.parentNode).find("> .dropdown-menu .active")[0];o&&e(o).removeClass("active"),"tab"===n.getAttribute("role")&&n.setAttribute("aria-selected",!1)}if(e(t).addClass("active"),"tab"===t.getAttribute("role")&&t.setAttribute("aria-selected",!0),c.reflow(t),t.classList.contains("fade")&&t.classList.add("show"),t.parentNode&&e(t.parentNode).hasClass("dropdown-menu")){var s=e(t).closest(".dropdown")[0];if(s){var r=[].slice.call(s.querySelectorAll(".dropdown-toggle"));e(r).addClass("active")}t.setAttribute("aria-expanded",!0)}i&&i()},t._jQueryInterface=function(n){return this.each((function(){var i=e(this),o=i.data("bs.tab");if(o||(o=new t(this),i.data("bs.tab",o)),"string"==typeof n){if("undefined"==typeof o[n])throw new TypeError('No method named "'+n+'"');o[n]()}}))},o(t,null,[{key:"VERSION",get:function(){return"4.5.0"}}]),t}();e(document).on("click.bs.tab.data-api",'[data-toggle="tab"], [data-toggle="pill"], [data-toggle="list"]',(function(t){t.preventDefault(),ht._jQueryInterface.call(e(this),"show")})),e.fn.tab=ht._jQueryInterface,e.fn.tab.Constructor=ht,e.fn.tab.noConflict=function(){return e.fn.tab=ct,ht._jQueryInterface};var ut=e.fn.toast,dt={animation:"boolean",autohide:"boolean",delay:"number"},ft={animation:!0,autohide:!0,delay:500},gt=function(){function t(t,e){this._element=t,this._config=this._getConfig(e),this._timeout=null,this._setListeners()}var n=t.prototype;return n.show=function(){var t=this,n=e.Event("show.bs.toast");if(e(this._element).trigger(n),!n.isDefaultPrevented()){this._config.animation&&this._element.classList.add("fade");var i=function(){t._element.classList.remove("showing"),t._element.classList.add("show"),e(t._element).trigger("shown.bs.toast"),t._config.autohide&&(t._timeout=setTimeout((function(){t.hide()}),t._config.delay))};if(this._element.classList.remove("hide"),c.reflow(this._element),this._element.classList.add("showing"),this._config.animation){var o=c.getTransitionDurationFromElement(this._element);e(this._element).one(c.TRANSITION_END,i).emulateTransitionEnd(o)}else i()}},n.hide=function(){if(this._element.classList.contains("show")){var t=e.Event("hide.bs.toast");e(this._element).trigger(t),t.isDefaultPrevented()||this._close()}},n.dispose=function(){clearTimeout(this._timeout),this._timeout=null,this._element.classList.contains("show")&&this._element.classList.remove("show"),e(this._element).off("click.dismiss.bs.toast"),e.removeData(this._element,"bs.toast"),this._element=null,this._config=null},n._getConfig=function(t){return t=a(a(a({},ft),e(this._element).data()),"object"==typeof t&&t?t:{}),c.typeCheckConfig("toast",t,this.constructor.DefaultType),t},n._setListeners=function(){var t=this;e(this._element).on("click.dismiss.bs.toast",'[data-dismiss="toast"]',(function(){return t.hide()}))},n._close=function(){var t=this,n=function(){t._element.classList.add("hide"),e(t._element).trigger("hidden.bs.toast")};if(this._element.classList.remove("show"),this._config.animation){var i=c.getTransitionDurationFromElement(this._element);e(this._element).one(c.TRANSITION_END,n).emulateTransitionEnd(i)}else n()},t._jQueryInterface=function(n){return this.each((function(){var i=e(this),o=i.data("bs.toast");if(o||(o=new t(this,"object"==typeof n&&n),i.data("bs.toast",o)),"string"==typeof n){if("undefined"==typeof o[n])throw new TypeError('No method named "'+n+'"');o[n](this)}}))},o(t,null,[{key:"VERSION",get:function(){return"4.5.0"}},{key:"DefaultType",get:function(){return dt}},{key:"Default",get:function(){return ft}}]),t}();e.fn.toast=gt._jQueryInterface,e.fn.toast.Constructor=gt,e.fn.toast.noConflict=function(){return e.fn.toast=ut,gt._jQueryInterface},t.Alert=d,t.Button=g,t.Carousel=E,t.Collapse=D,t.Dropdown=j,t.Modal=R,t.Popover=it,t.Scrollspy=lt,t.Tab=ht,t.Toast=gt,t.Tooltip=$,t.Util=c,Object.defineProperty(t,"__esModule",{value:!0})})); //# sourceMappingURL=bootstrap.min.js.map \ No newline at end of file diff --git a/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/js/jquery.min.js b/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/js/jquery.min.js index a1c07fd80..b0614034a 100644 --- a/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/js/jquery.min.js +++ b/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/js/jquery.min.js @@ -1,2 +1,2 @@ -/*! jQuery v3.4.1 | (c) JS Foundation and other contributors | jquery.org/license */ -!function(e,t){"use strict";"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(C,e){"use strict";var t=[],E=C.document,r=Object.getPrototypeOf,s=t.slice,g=t.concat,u=t.push,i=t.indexOf,n={},o=n.toString,v=n.hasOwnProperty,a=v.toString,l=a.call(Object),y={},m=function(e){return"function"==typeof e&&"number"!=typeof e.nodeType},x=function(e){return null!=e&&e===e.window},c={type:!0,src:!0,nonce:!0,noModule:!0};function b(e,t,n){var r,i,o=(n=n||E).createElement("script");if(o.text=e,t)for(r in c)(i=t[r]||t.getAttribute&&t.getAttribute(r))&&o.setAttribute(r,i);n.head.appendChild(o).parentNode.removeChild(o)}function w(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?n[o.call(e)]||"object":typeof e}var f="3.4.1",k=function(e,t){return new k.fn.init(e,t)},p=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;function d(e){var t=!!e&&"length"in e&&e.length,n=w(e);return!m(e)&&!x(e)&&("array"===n||0===t||"number"==typeof t&&0+~]|"+M+")"+M+"*"),U=new RegExp(M+"|>"),X=new RegExp($),V=new RegExp("^"+I+"$"),G={ID:new RegExp("^#("+I+")"),CLASS:new RegExp("^\\.("+I+")"),TAG:new RegExp("^("+I+"|[*])"),ATTR:new RegExp("^"+W),PSEUDO:new RegExp("^"+$),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+R+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/HTML$/i,Q=/^(?:input|select|textarea|button)$/i,J=/^h\d$/i,K=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ee=/[+~]/,te=new RegExp("\\\\([\\da-f]{1,6}"+M+"?|("+M+")|.)","ig"),ne=function(e,t,n){var r="0x"+t-65536;return r!=r||n?t:r<0?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,1023&r|56320)},re=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ie=function(e,t){return t?"\0"===e?"\ufffd":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},oe=function(){T()},ae=be(function(e){return!0===e.disabled&&"fieldset"===e.nodeName.toLowerCase()},{dir:"parentNode",next:"legend"});try{H.apply(t=O.call(m.childNodes),m.childNodes),t[m.childNodes.length].nodeType}catch(e){H={apply:t.length?function(e,t){L.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function se(t,e,n,r){var i,o,a,s,u,l,c,f=e&&e.ownerDocument,p=e?e.nodeType:9;if(n=n||[],"string"!=typeof t||!t||1!==p&&9!==p&&11!==p)return n;if(!r&&((e?e.ownerDocument||e:m)!==C&&T(e),e=e||C,E)){if(11!==p&&(u=Z.exec(t)))if(i=u[1]){if(9===p){if(!(a=e.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(f&&(a=f.getElementById(i))&&y(e,a)&&a.id===i)return n.push(a),n}else{if(u[2])return H.apply(n,e.getElementsByTagName(t)),n;if((i=u[3])&&d.getElementsByClassName&&e.getElementsByClassName)return H.apply(n,e.getElementsByClassName(i)),n}if(d.qsa&&!A[t+" "]&&(!v||!v.test(t))&&(1!==p||"object"!==e.nodeName.toLowerCase())){if(c=t,f=e,1===p&&U.test(t)){(s=e.getAttribute("id"))?s=s.replace(re,ie):e.setAttribute("id",s=k),o=(l=h(t)).length;while(o--)l[o]="#"+s+" "+xe(l[o]);c=l.join(","),f=ee.test(t)&&ye(e.parentNode)||e}try{return H.apply(n,f.querySelectorAll(c)),n}catch(e){A(t,!0)}finally{s===k&&e.removeAttribute("id")}}}return g(t.replace(B,"$1"),e,n,r)}function ue(){var r=[];return function e(t,n){return r.push(t+" ")>b.cacheLength&&delete e[r.shift()],e[t+" "]=n}}function le(e){return e[k]=!0,e}function ce(e){var t=C.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function fe(e,t){var n=e.split("|"),r=n.length;while(r--)b.attrHandle[n[r]]=t}function pe(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function de(t){return function(e){return"input"===e.nodeName.toLowerCase()&&e.type===t}}function he(n){return function(e){var t=e.nodeName.toLowerCase();return("input"===t||"button"===t)&&e.type===n}}function ge(t){return function(e){return"form"in e?e.parentNode&&!1===e.disabled?"label"in e?"label"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&ae(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function ve(a){return le(function(o){return o=+o,le(function(e,t){var n,r=a([],e.length,o),i=r.length;while(i--)e[n=r[i]]&&(e[n]=!(t[n]=e[n]))})})}function ye(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}for(e in d=se.support={},i=se.isXML=function(e){var t=e.namespaceURI,n=(e.ownerDocument||e).documentElement;return!Y.test(t||n&&n.nodeName||"HTML")},T=se.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:m;return r!==C&&9===r.nodeType&&r.documentElement&&(a=(C=r).documentElement,E=!i(C),m!==C&&(n=C.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",oe,!1):n.attachEvent&&n.attachEvent("onunload",oe)),d.attributes=ce(function(e){return e.className="i",!e.getAttribute("className")}),d.getElementsByTagName=ce(function(e){return e.appendChild(C.createComment("")),!e.getElementsByTagName("*").length}),d.getElementsByClassName=K.test(C.getElementsByClassName),d.getById=ce(function(e){return a.appendChild(e).id=k,!C.getElementsByName||!C.getElementsByName(k).length}),d.getById?(b.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute("id")===t}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n=t.getElementById(e);return n?[n]:[]}}):(b.filter.ID=function(e){var n=e.replace(te,ne);return function(e){var t="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return t&&t.value===n}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode("id"))&&n.value===e)return[o];i=t.getElementsByName(e),r=0;while(o=i[r++])if((n=o.getAttributeNode("id"))&&n.value===e)return[o]}return[]}}),b.find.TAG=d.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):d.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},b.find.CLASS=d.getElementsByClassName&&function(e,t){if("undefined"!=typeof t.getElementsByClassName&&E)return t.getElementsByClassName(e)},s=[],v=[],(d.qsa=K.test(C.querySelectorAll))&&(ce(function(e){a.appendChild(e).innerHTML="",e.querySelectorAll("[msallowcapture^='']").length&&v.push("[*^$]="+M+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||v.push("\\["+M+"*(?:value|"+R+")"),e.querySelectorAll("[id~="+k+"-]").length||v.push("~="),e.querySelectorAll(":checked").length||v.push(":checked"),e.querySelectorAll("a#"+k+"+*").length||v.push(".#.+[+~]")}),ce(function(e){e.innerHTML="";var t=C.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&v.push("name"+M+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&v.push(":enabled",":disabled"),a.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&v.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),v.push(",.*:")})),(d.matchesSelector=K.test(c=a.matches||a.webkitMatchesSelector||a.mozMatchesSelector||a.oMatchesSelector||a.msMatchesSelector))&&ce(function(e){d.disconnectedMatch=c.call(e,"*"),c.call(e,"[s!='']:x"),s.push("!=",$)}),v=v.length&&new RegExp(v.join("|")),s=s.length&&new RegExp(s.join("|")),t=K.test(a.compareDocumentPosition),y=t||K.test(a.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},D=t?function(e,t){if(e===t)return l=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!d.sortDetached&&t.compareDocumentPosition(e)===n?e===C||e.ownerDocument===m&&y(m,e)?-1:t===C||t.ownerDocument===m&&y(m,t)?1:u?P(u,e)-P(u,t):0:4&n?-1:1)}:function(e,t){if(e===t)return l=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e===C?-1:t===C?1:i?-1:o?1:u?P(u,e)-P(u,t):0;if(i===o)return pe(e,t);n=e;while(n=n.parentNode)a.unshift(n);n=t;while(n=n.parentNode)s.unshift(n);while(a[r]===s[r])r++;return r?pe(a[r],s[r]):a[r]===m?-1:s[r]===m?1:0}),C},se.matches=function(e,t){return se(e,null,null,t)},se.matchesSelector=function(e,t){if((e.ownerDocument||e)!==C&&T(e),d.matchesSelector&&E&&!A[t+" "]&&(!s||!s.test(t))&&(!v||!v.test(t)))try{var n=c.call(e,t);if(n||d.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){A(t,!0)}return 0":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(te,ne),e[3]=(e[3]||e[4]||e[5]||"").replace(te,ne),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||se.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&se.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return G.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&X.test(n)&&(t=h(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(te,ne).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=p[e+" "];return t||(t=new RegExp("(^|"+M+")"+e+"("+M+"|$)"))&&p(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(n,r,i){return function(e){var t=se.attr(e,n);return null==t?"!="===r:!r||(t+="","="===r?t===i:"!="===r?t!==i:"^="===r?i&&0===t.indexOf(i):"*="===r?i&&-1:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function j(e,n,r){return m(n)?k.grep(e,function(e,t){return!!n.call(e,t,e)!==r}):n.nodeType?k.grep(e,function(e){return e===n!==r}):"string"!=typeof n?k.grep(e,function(e){return-1)[^>]*|#([\w-]+))$/;(k.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||q,"string"==typeof e){if(!(r="<"===e[0]&&">"===e[e.length-1]&&3<=e.length?[null,e,null]:L.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof k?t[0]:t,k.merge(this,k.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:E,!0)),D.test(r[1])&&k.isPlainObject(t))for(r in t)m(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=E.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):m(e)?void 0!==n.ready?n.ready(e):e(k):k.makeArray(e,this)}).prototype=k.fn,q=k(E);var H=/^(?:parents|prev(?:Until|All))/,O={children:!0,contents:!0,next:!0,prev:!0};function P(e,t){while((e=e[t])&&1!==e.nodeType);return e}k.fn.extend({has:function(e){var t=k(e,this),n=t.length;return this.filter(function(){for(var e=0;e\x20\t\r\n\f]*)/i,he=/^$|^module$|\/(?:java|ecma)script/i,ge={option:[1,""],thead:[1,"","
"],col:[2,"","
"],tr:[2,"","
"],td:[3,"","
"],_default:[0,"",""]};function ve(e,t){var n;return n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&A(e,t)?k.merge([e],n):n}function ye(e,t){for(var n=0,r=e.length;nx",y.noCloneChecked=!!me.cloneNode(!0).lastChild.defaultValue;var Te=/^key/,Ce=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Ee=/^([^.]*)(?:\.(.+)|)/;function ke(){return!0}function Se(){return!1}function Ne(e,t){return e===function(){try{return E.activeElement}catch(e){}}()==("focus"===t)}function Ae(e,t,n,r,i,o){var a,s;if("object"==typeof t){for(s in"string"!=typeof n&&(r=r||n,n=void 0),t)Ae(e,s,n,r,t[s],o);return e}if(null==r&&null==i?(i=n,r=n=void 0):null==i&&("string"==typeof n?(i=r,r=void 0):(i=r,r=n,n=void 0)),!1===i)i=Se;else if(!i)return e;return 1===o&&(a=i,(i=function(e){return k().off(e),a.apply(this,arguments)}).guid=a.guid||(a.guid=k.guid++)),e.each(function(){k.event.add(this,t,i,r,n)})}function De(e,i,o){o?(Q.set(e,i,!1),k.event.add(e,i,{namespace:!1,handler:function(e){var t,n,r=Q.get(this,i);if(1&e.isTrigger&&this[i]){if(r.length)(k.event.special[i]||{}).delegateType&&e.stopPropagation();else if(r=s.call(arguments),Q.set(this,i,r),t=o(this,i),this[i](),r!==(n=Q.get(this,i))||t?Q.set(this,i,!1):n={},r!==n)return e.stopImmediatePropagation(),e.preventDefault(),n.value}else r.length&&(Q.set(this,i,{value:k.event.trigger(k.extend(r[0],k.Event.prototype),r.slice(1),this)}),e.stopImmediatePropagation())}})):void 0===Q.get(e,i)&&k.event.add(e,i,ke)}k.event={global:{},add:function(t,e,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Q.get(t);if(v){n.handler&&(n=(o=n).handler,i=o.selector),i&&k.find.matchesSelector(ie,i),n.guid||(n.guid=k.guid++),(u=v.events)||(u=v.events={}),(a=v.handle)||(a=v.handle=function(e){return"undefined"!=typeof k&&k.event.triggered!==e.type?k.event.dispatch.apply(t,arguments):void 0}),l=(e=(e||"").match(R)||[""]).length;while(l--)d=g=(s=Ee.exec(e[l])||[])[1],h=(s[2]||"").split(".").sort(),d&&(f=k.event.special[d]||{},d=(i?f.delegateType:f.bindType)||d,f=k.event.special[d]||{},c=k.extend({type:d,origType:g,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&k.expr.match.needsContext.test(i),namespace:h.join(".")},o),(p=u[d])||((p=u[d]=[]).delegateCount=0,f.setup&&!1!==f.setup.call(t,r,h,a)||t.addEventListener&&t.addEventListener(d,a)),f.add&&(f.add.call(t,c),c.handler.guid||(c.handler.guid=n.guid)),i?p.splice(p.delegateCount++,0,c):p.push(c),k.event.global[d]=!0)}},remove:function(e,t,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Q.hasData(e)&&Q.get(e);if(v&&(u=v.events)){l=(t=(t||"").match(R)||[""]).length;while(l--)if(d=g=(s=Ee.exec(t[l])||[])[1],h=(s[2]||"").split(".").sort(),d){f=k.event.special[d]||{},p=u[d=(r?f.delegateType:f.bindType)||d]||[],s=s[2]&&new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),a=o=p.length;while(o--)c=p[o],!i&&g!==c.origType||n&&n.guid!==c.guid||s&&!s.test(c.namespace)||r&&r!==c.selector&&("**"!==r||!c.selector)||(p.splice(o,1),c.selector&&p.delegateCount--,f.remove&&f.remove.call(e,c));a&&!p.length&&(f.teardown&&!1!==f.teardown.call(e,h,v.handle)||k.removeEvent(e,d,v.handle),delete u[d])}else for(d in u)k.event.remove(e,d+t[l],n,r,!0);k.isEmptyObject(u)&&Q.remove(e,"handle events")}},dispatch:function(e){var t,n,r,i,o,a,s=k.event.fix(e),u=new Array(arguments.length),l=(Q.get(this,"events")||{})[s.type]||[],c=k.event.special[s.type]||{};for(u[0]=s,t=1;t\x20\t\r\n\f]*)[^>]*)\/>/gi,qe=/\s*$/g;function Oe(e,t){return A(e,"table")&&A(11!==t.nodeType?t:t.firstChild,"tr")&&k(e).children("tbody")[0]||e}function Pe(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function Re(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Me(e,t){var n,r,i,o,a,s,u,l;if(1===t.nodeType){if(Q.hasData(e)&&(o=Q.access(e),a=Q.set(t,o),l=o.events))for(i in delete a.handle,a.events={},l)for(n=0,r=l[i].length;n")},clone:function(e,t,n){var r,i,o,a,s,u,l,c=e.cloneNode(!0),f=oe(e);if(!(y.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||k.isXMLDoc(e)))for(a=ve(c),r=0,i=(o=ve(e)).length;r").attr(n.scriptAttrs||{}).prop({charset:n.scriptCharset,src:n.url}).on("load error",i=function(e){r.remove(),i=null,e&&t("error"===e.type?404:200,e.type)}),E.head.appendChild(r[0])},abort:function(){i&&i()}}});var Vt,Gt=[],Yt=/(=)\?(?=&|$)|\?\?/;k.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=Gt.pop()||k.expando+"_"+kt++;return this[e]=!0,e}}),k.ajaxPrefilter("json jsonp",function(e,t,n){var r,i,o,a=!1!==e.jsonp&&(Yt.test(e.url)?"url":"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&Yt.test(e.data)&&"data");if(a||"jsonp"===e.dataTypes[0])return r=e.jsonpCallback=m(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,a?e[a]=e[a].replace(Yt,"$1"+r):!1!==e.jsonp&&(e.url+=(St.test(e.url)?"&":"?")+e.jsonp+"="+r),e.converters["script json"]=function(){return o||k.error(r+" was not called"),o[0]},e.dataTypes[0]="json",i=C[r],C[r]=function(){o=arguments},n.always(function(){void 0===i?k(C).removeProp(r):C[r]=i,e[r]&&(e.jsonpCallback=t.jsonpCallback,Gt.push(r)),o&&m(i)&&i(o[0]),o=i=void 0}),"script"}),y.createHTMLDocument=((Vt=E.implementation.createHTMLDocument("").body).innerHTML="
",2===Vt.childNodes.length),k.parseHTML=function(e,t,n){return"string"!=typeof e?[]:("boolean"==typeof t&&(n=t,t=!1),t||(y.createHTMLDocument?((r=(t=E.implementation.createHTMLDocument("")).createElement("base")).href=E.location.href,t.head.appendChild(r)):t=E),o=!n&&[],(i=D.exec(e))?[t.createElement(i[1])]:(i=we([e],t,o),o&&o.length&&k(o).remove(),k.merge([],i.childNodes)));var r,i,o},k.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(" ");return-1").append(k.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},k.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){k.fn[t]=function(e){return this.on(t,e)}}),k.expr.pseudos.animated=function(t){return k.grep(k.timers,function(e){return t===e.elem}).length},k.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l=k.css(e,"position"),c=k(e),f={};"static"===l&&(e.style.position="relative"),s=c.offset(),o=k.css(e,"top"),u=k.css(e,"left"),("absolute"===l||"fixed"===l)&&-1<(o+u).indexOf("auto")?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),m(t)&&(t=t.call(e,n,k.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),"using"in t?t.using.call(e,f):c.css(f)}},k.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){k.offset.setOffset(this,t,e)});var e,n,r=this[0];return r?r.getClientRects().length?(e=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:e.top+n.pageYOffset,left:e.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if("fixed"===k.css(r,"position"))t=r.getBoundingClientRect();else{t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;while(e&&(e===n.body||e===n.documentElement)&&"static"===k.css(e,"position"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=k(e).offset()).top+=k.css(e,"borderTopWidth",!0),i.left+=k.css(e,"borderLeftWidth",!0))}return{top:t.top-i.top-k.css(r,"marginTop",!0),left:t.left-i.left-k.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&"static"===k.css(e,"position"))e=e.offsetParent;return e||ie})}}),k.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(t,i){var o="pageYOffset"===i;k.fn[t]=function(e){return _(this,function(e,t,n){var r;if(x(e)?r=e:9===e.nodeType&&(r=e.defaultView),void 0===n)return r?r[i]:e[t];r?r.scrollTo(o?r.pageXOffset:n,o?n:r.pageYOffset):e[t]=n},t,e,arguments.length)}}),k.each(["top","left"],function(e,n){k.cssHooks[n]=ze(y.pixelPosition,function(e,t){if(t)return t=_e(e,n),$e.test(t)?k(e).position()[n]+"px":t})}),k.each({Height:"height",Width:"width"},function(a,s){k.each({padding:"inner"+a,content:s,"":"outer"+a},function(r,o){k.fn[o]=function(e,t){var n=arguments.length&&(r||"boolean"!=typeof e),i=r||(!0===e||!0===t?"margin":"border");return _(this,function(e,t,n){var r;return x(e)?0===o.indexOf("outer")?e["inner"+a]:e.document.documentElement["client"+a]:9===e.nodeType?(r=e.documentElement,Math.max(e.body["scroll"+a],r["scroll"+a],e.body["offset"+a],r["offset"+a],r["client"+a])):void 0===n?k.css(e,t,i):k.style(e,t,n,i)},s,n?e:void 0,n)}})}),k.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,n){k.fn[n]=function(e,t){return 0+~]|"+M+")"+M+"*"),U=new RegExp(M+"|>"),X=new RegExp(F),V=new RegExp("^"+I+"$"),G={ID:new RegExp("^#("+I+")"),CLASS:new RegExp("^\\.("+I+")"),TAG:new RegExp("^("+I+"|[*])"),ATTR:new RegExp("^"+W),PSEUDO:new RegExp("^"+F),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+R+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/HTML$/i,Q=/^(?:input|select|textarea|button)$/i,J=/^h\d$/i,K=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ee=/[+~]/,te=new RegExp("\\\\[\\da-fA-F]{1,6}"+M+"?|\\\\([^\\r\\n\\f])","g"),ne=function(e,t){var n="0x"+e.slice(1)-65536;return t||(n<0?String.fromCharCode(n+65536):String.fromCharCode(n>>10|55296,1023&n|56320))},re=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ie=function(e,t){return t?"\0"===e?"\ufffd":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},oe=function(){T()},ae=be(function(e){return!0===e.disabled&&"fieldset"===e.nodeName.toLowerCase()},{dir:"parentNode",next:"legend"});try{H.apply(t=O.call(p.childNodes),p.childNodes),t[p.childNodes.length].nodeType}catch(e){H={apply:t.length?function(e,t){L.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function se(t,e,n,r){var i,o,a,s,u,l,c,f=e&&e.ownerDocument,p=e?e.nodeType:9;if(n=n||[],"string"!=typeof t||!t||1!==p&&9!==p&&11!==p)return n;if(!r&&(T(e),e=e||C,E)){if(11!==p&&(u=Z.exec(t)))if(i=u[1]){if(9===p){if(!(a=e.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(f&&(a=f.getElementById(i))&&y(e,a)&&a.id===i)return n.push(a),n}else{if(u[2])return H.apply(n,e.getElementsByTagName(t)),n;if((i=u[3])&&d.getElementsByClassName&&e.getElementsByClassName)return H.apply(n,e.getElementsByClassName(i)),n}if(d.qsa&&!N[t+" "]&&(!v||!v.test(t))&&(1!==p||"object"!==e.nodeName.toLowerCase())){if(c=t,f=e,1===p&&(U.test(t)||z.test(t))){(f=ee.test(t)&&ye(e.parentNode)||e)===e&&d.scope||((s=e.getAttribute("id"))?s=s.replace(re,ie):e.setAttribute("id",s=S)),o=(l=h(t)).length;while(o--)l[o]=(s?"#"+s:":scope")+" "+xe(l[o]);c=l.join(",")}try{return H.apply(n,f.querySelectorAll(c)),n}catch(e){N(t,!0)}finally{s===S&&e.removeAttribute("id")}}}return g(t.replace($,"$1"),e,n,r)}function ue(){var r=[];return function e(t,n){return r.push(t+" ")>b.cacheLength&&delete e[r.shift()],e[t+" "]=n}}function le(e){return e[S]=!0,e}function ce(e){var t=C.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function fe(e,t){var n=e.split("|"),r=n.length;while(r--)b.attrHandle[n[r]]=t}function pe(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function de(t){return function(e){return"input"===e.nodeName.toLowerCase()&&e.type===t}}function he(n){return function(e){var t=e.nodeName.toLowerCase();return("input"===t||"button"===t)&&e.type===n}}function ge(t){return function(e){return"form"in e?e.parentNode&&!1===e.disabled?"label"in e?"label"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&ae(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function ve(a){return le(function(o){return o=+o,le(function(e,t){var n,r=a([],e.length,o),i=r.length;while(i--)e[n=r[i]]&&(e[n]=!(t[n]=e[n]))})})}function ye(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}for(e in d=se.support={},i=se.isXML=function(e){var t=e.namespaceURI,n=(e.ownerDocument||e).documentElement;return!Y.test(t||n&&n.nodeName||"HTML")},T=se.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:p;return r!=C&&9===r.nodeType&&r.documentElement&&(a=(C=r).documentElement,E=!i(C),p!=C&&(n=C.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",oe,!1):n.attachEvent&&n.attachEvent("onunload",oe)),d.scope=ce(function(e){return a.appendChild(e).appendChild(C.createElement("div")),"undefined"!=typeof e.querySelectorAll&&!e.querySelectorAll(":scope fieldset div").length}),d.attributes=ce(function(e){return e.className="i",!e.getAttribute("className")}),d.getElementsByTagName=ce(function(e){return e.appendChild(C.createComment("")),!e.getElementsByTagName("*").length}),d.getElementsByClassName=K.test(C.getElementsByClassName),d.getById=ce(function(e){return a.appendChild(e).id=S,!C.getElementsByName||!C.getElementsByName(S).length}),d.getById?(b.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute("id")===t}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n=t.getElementById(e);return n?[n]:[]}}):(b.filter.ID=function(e){var n=e.replace(te,ne);return function(e){var t="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return t&&t.value===n}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode("id"))&&n.value===e)return[o];i=t.getElementsByName(e),r=0;while(o=i[r++])if((n=o.getAttributeNode("id"))&&n.value===e)return[o]}return[]}}),b.find.TAG=d.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):d.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},b.find.CLASS=d.getElementsByClassName&&function(e,t){if("undefined"!=typeof t.getElementsByClassName&&E)return t.getElementsByClassName(e)},s=[],v=[],(d.qsa=K.test(C.querySelectorAll))&&(ce(function(e){var t;a.appendChild(e).innerHTML="",e.querySelectorAll("[msallowcapture^='']").length&&v.push("[*^$]="+M+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||v.push("\\["+M+"*(?:value|"+R+")"),e.querySelectorAll("[id~="+S+"-]").length||v.push("~="),(t=C.createElement("input")).setAttribute("name",""),e.appendChild(t),e.querySelectorAll("[name='']").length||v.push("\\["+M+"*name"+M+"*="+M+"*(?:''|\"\")"),e.querySelectorAll(":checked").length||v.push(":checked"),e.querySelectorAll("a#"+S+"+*").length||v.push(".#.+[+~]"),e.querySelectorAll("\\\f"),v.push("[\\r\\n\\f]")}),ce(function(e){e.innerHTML="";var t=C.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&v.push("name"+M+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&v.push(":enabled",":disabled"),a.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&v.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),v.push(",.*:")})),(d.matchesSelector=K.test(c=a.matches||a.webkitMatchesSelector||a.mozMatchesSelector||a.oMatchesSelector||a.msMatchesSelector))&&ce(function(e){d.disconnectedMatch=c.call(e,"*"),c.call(e,"[s!='']:x"),s.push("!=",F)}),v=v.length&&new RegExp(v.join("|")),s=s.length&&new RegExp(s.join("|")),t=K.test(a.compareDocumentPosition),y=t||K.test(a.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},D=t?function(e,t){if(e===t)return l=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)==(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!d.sortDetached&&t.compareDocumentPosition(e)===n?e==C||e.ownerDocument==p&&y(p,e)?-1:t==C||t.ownerDocument==p&&y(p,t)?1:u?P(u,e)-P(u,t):0:4&n?-1:1)}:function(e,t){if(e===t)return l=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e==C?-1:t==C?1:i?-1:o?1:u?P(u,e)-P(u,t):0;if(i===o)return pe(e,t);n=e;while(n=n.parentNode)a.unshift(n);n=t;while(n=n.parentNode)s.unshift(n);while(a[r]===s[r])r++;return r?pe(a[r],s[r]):a[r]==p?-1:s[r]==p?1:0}),C},se.matches=function(e,t){return se(e,null,null,t)},se.matchesSelector=function(e,t){if(T(e),d.matchesSelector&&E&&!N[t+" "]&&(!s||!s.test(t))&&(!v||!v.test(t)))try{var n=c.call(e,t);if(n||d.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){N(t,!0)}return 0":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(te,ne),e[3]=(e[3]||e[4]||e[5]||"").replace(te,ne),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||se.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&se.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return G.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&X.test(n)&&(t=h(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(te,ne).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=m[e+" "];return t||(t=new RegExp("(^|"+M+")"+e+"("+M+"|$)"))&&m(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(n,r,i){return function(e){var t=se.attr(e,n);return null==t?"!="===r:!r||(t+="","="===r?t===i:"!="===r?t!==i:"^="===r?i&&0===t.indexOf(i):"*="===r?i&&-1:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function D(e,n,r){return m(n)?S.grep(e,function(e,t){return!!n.call(e,t,e)!==r}):n.nodeType?S.grep(e,function(e){return e===n!==r}):"string"!=typeof n?S.grep(e,function(e){return-1)[^>]*|#([\w-]+))$/;(S.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||j,"string"==typeof e){if(!(r="<"===e[0]&&">"===e[e.length-1]&&3<=e.length?[null,e,null]:q.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof S?t[0]:t,S.merge(this,S.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:E,!0)),N.test(r[1])&&S.isPlainObject(t))for(r in t)m(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=E.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):m(e)?void 0!==n.ready?n.ready(e):e(S):S.makeArray(e,this)}).prototype=S.fn,j=S(E);var L=/^(?:parents|prev(?:Until|All))/,H={children:!0,contents:!0,next:!0,prev:!0};function O(e,t){while((e=e[t])&&1!==e.nodeType);return e}S.fn.extend({has:function(e){var t=S(e,this),n=t.length;return this.filter(function(){for(var e=0;e\x20\t\r\n\f]*)/i,he=/^$|^module$|\/(?:java|ecma)script/i;ce=E.createDocumentFragment().appendChild(E.createElement("div")),(fe=E.createElement("input")).setAttribute("type","radio"),fe.setAttribute("checked","checked"),fe.setAttribute("name","t"),ce.appendChild(fe),y.checkClone=ce.cloneNode(!0).cloneNode(!0).lastChild.checked,ce.innerHTML="",y.noCloneChecked=!!ce.cloneNode(!0).lastChild.defaultValue,ce.innerHTML="",y.option=!!ce.lastChild;var ge={thead:[1,"","
"],col:[2,"","
"],tr:[2,"","
"],td:[3,"","
"],_default:[0,"",""]};function ve(e,t){var n;return n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&A(e,t)?S.merge([e],n):n}function ye(e,t){for(var n=0,r=e.length;n",""]);var me=/<|&#?\w+;/;function xe(e,t,n,r,i){for(var o,a,s,u,l,c,f=t.createDocumentFragment(),p=[],d=0,h=e.length;d\s*$/g;function qe(e,t){return A(e,"table")&&A(11!==t.nodeType?t:t.firstChild,"tr")&&S(e).children("tbody")[0]||e}function Le(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function He(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Oe(e,t){var n,r,i,o,a,s;if(1===t.nodeType){if(Y.hasData(e)&&(s=Y.get(e).events))for(i in Y.remove(t,"handle events"),s)for(n=0,r=s[i].length;n").attr(n.scriptAttrs||{}).prop({charset:n.scriptCharset,src:n.url}).on("load error",i=function(e){r.remove(),i=null,e&&t("error"===e.type?404:200,e.type)}),E.head.appendChild(r[0])},abort:function(){i&&i()}}});var Ut,Xt=[],Vt=/(=)\?(?=&|$)|\?\?/;S.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=Xt.pop()||S.expando+"_"+Ct.guid++;return this[e]=!0,e}}),S.ajaxPrefilter("json jsonp",function(e,t,n){var r,i,o,a=!1!==e.jsonp&&(Vt.test(e.url)?"url":"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&Vt.test(e.data)&&"data");if(a||"jsonp"===e.dataTypes[0])return r=e.jsonpCallback=m(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,a?e[a]=e[a].replace(Vt,"$1"+r):!1!==e.jsonp&&(e.url+=(Et.test(e.url)?"&":"?")+e.jsonp+"="+r),e.converters["script json"]=function(){return o||S.error(r+" was not called"),o[0]},e.dataTypes[0]="json",i=C[r],C[r]=function(){o=arguments},n.always(function(){void 0===i?S(C).removeProp(r):C[r]=i,e[r]&&(e.jsonpCallback=t.jsonpCallback,Xt.push(r)),o&&m(i)&&i(o[0]),o=i=void 0}),"script"}),y.createHTMLDocument=((Ut=E.implementation.createHTMLDocument("").body).innerHTML="
",2===Ut.childNodes.length),S.parseHTML=function(e,t,n){return"string"!=typeof e?[]:("boolean"==typeof t&&(n=t,t=!1),t||(y.createHTMLDocument?((r=(t=E.implementation.createHTMLDocument("")).createElement("base")).href=E.location.href,t.head.appendChild(r)):t=E),o=!n&&[],(i=N.exec(e))?[t.createElement(i[1])]:(i=xe([e],t,o),o&&o.length&&S(o).remove(),S.merge([],i.childNodes)));var r,i,o},S.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(" ");return-1").append(S.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},S.expr.pseudos.animated=function(t){return S.grep(S.timers,function(e){return t===e.elem}).length},S.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l=S.css(e,"position"),c=S(e),f={};"static"===l&&(e.style.position="relative"),s=c.offset(),o=S.css(e,"top"),u=S.css(e,"left"),("absolute"===l||"fixed"===l)&&-1<(o+u).indexOf("auto")?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),m(t)&&(t=t.call(e,n,S.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),"using"in t?t.using.call(e,f):("number"==typeof f.top&&(f.top+="px"),"number"==typeof f.left&&(f.left+="px"),c.css(f))}},S.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){S.offset.setOffset(this,t,e)});var e,n,r=this[0];return r?r.getClientRects().length?(e=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:e.top+n.pageYOffset,left:e.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if("fixed"===S.css(r,"position"))t=r.getBoundingClientRect();else{t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;while(e&&(e===n.body||e===n.documentElement)&&"static"===S.css(e,"position"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=S(e).offset()).top+=S.css(e,"borderTopWidth",!0),i.left+=S.css(e,"borderLeftWidth",!0))}return{top:t.top-i.top-S.css(r,"marginTop",!0),left:t.left-i.left-S.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&"static"===S.css(e,"position"))e=e.offsetParent;return e||re})}}),S.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(t,i){var o="pageYOffset"===i;S.fn[t]=function(e){return $(this,function(e,t,n){var r;if(x(e)?r=e:9===e.nodeType&&(r=e.defaultView),void 0===n)return r?r[i]:e[t];r?r.scrollTo(o?r.pageXOffset:n,o?n:r.pageYOffset):e[t]=n},t,e,arguments.length)}}),S.each(["top","left"],function(e,n){S.cssHooks[n]=$e(y.pixelPosition,function(e,t){if(t)return t=Be(e,n),Me.test(t)?S(e).position()[n]+"px":t})}),S.each({Height:"height",Width:"width"},function(a,s){S.each({padding:"inner"+a,content:s,"":"outer"+a},function(r,o){S.fn[o]=function(e,t){var n=arguments.length&&(r||"boolean"!=typeof e),i=r||(!0===e||!0===t?"margin":"border");return $(this,function(e,t,n){var r;return x(e)?0===o.indexOf("outer")?e["inner"+a]:e.document.documentElement["client"+a]:9===e.nodeType?(r=e.documentElement,Math.max(e.body["scroll"+a],r["scroll"+a],e.body["offset"+a],r["offset"+a],r["client"+a])):void 0===n?S.css(e,t,i):S.style(e,t,n,i)},s,n?e:void 0,n)}})}),S.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){S.fn[t]=function(e){return this.on(t,e)}}),S.fn.extend({bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)},hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),S.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,n){S.fn[n]=function(e,t){return 0{{lineNumber}}{{lineContent}} diff --git a/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/lines.html.dist b/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/lines.html.dist new file mode 100644 index 000000000..add40e4e9 --- /dev/null +++ b/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/lines.html.dist @@ -0,0 +1,5 @@ + + +{{lines}} + +
diff --git a/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/method_item_branch.html.dist b/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/method_item_branch.html.dist new file mode 100644 index 000000000..a6a25f95e --- /dev/null +++ b/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/method_item_branch.html.dist @@ -0,0 +1,17 @@ + + {{name}} + {{methods_bar}} +
{{methods_tested_percent}}
+
{{methods_number}}
+ {{crap}} + {{paths_bar}} +
{{paths_executed_percent}}
+
{{paths_number}}
+ {{branches_bar}} +
{{branches_executed_percent}}
+
{{branches_number}}
+ {{lines_bar}} +
{{lines_executed_percent}}
+
{{lines_number}}
+ + diff --git a/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/paths.html.dist b/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/paths.html.dist new file mode 100644 index 000000000..d14b8ad9d --- /dev/null +++ b/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/paths.html.dist @@ -0,0 +1,9 @@ +
+

Paths

+

+ Below are the source code lines that represent each code path as identified by Xdebug. Please note a path is not + necessarily coterminous with a line, a line may contain multiple paths and therefore show up more than once. + Please also be aware that some paths may include implicit rather than explicit branches, e.g. an if statement + always has an else as part of its logical flow even if you didn't write one. +

+{{paths}} diff --git a/vendor/phpunit/php-code-coverage/src/Report/PHP.php b/vendor/phpunit/php-code-coverage/src/Report/PHP.php index 73e2f4ddf..8d23870dd 100644 --- a/vendor/phpunit/php-code-coverage/src/Report/PHP.php +++ b/vendor/phpunit/php-code-coverage/src/Report/PHP.php @@ -1,6 +1,6 @@ * @@ -9,56 +9,35 @@ */ namespace SebastianBergmann\CodeCoverage\Report; +use function dirname; +use function file_put_contents; +use function serialize; +use function sprintf; use SebastianBergmann\CodeCoverage\CodeCoverage; -use SebastianBergmann\CodeCoverage\RuntimeException; +use SebastianBergmann\CodeCoverage\Directory; +use SebastianBergmann\CodeCoverage\Driver\WriteOperationFailedException; -/** - * Uses var_export() to write a SebastianBergmann\CodeCoverage\CodeCoverage object to a file. - */ final class PHP { - /** - * @throws \SebastianBergmann\CodeCoverage\RuntimeException - */ public function process(CodeCoverage $coverage, ?string $target = null): string { - $filter = $coverage->filter(); - - $buffer = \sprintf( - 'setData(%s); -$coverage->setTests(%s); - -$filter = $coverage->filter(); -$filter->setWhitelistedFiles(%s); - -return $coverage;', - \var_export($coverage->getData(true), true), - \var_export($coverage->getTests(), true), - \var_export($filter->getWhitelistedFiles(), true) + $buffer = sprintf( + "createDirectory(\dirname($target))) { - throw new \RuntimeException(\sprintf('Directory "%s" was not created', \dirname($target))); - } + Directory::create(dirname($target)); - if (@\file_put_contents($target, $buffer) === false) { - throw new RuntimeException( - \sprintf( - 'Could not write to "%s', - $target - ) - ); + if (@file_put_contents($target, $buffer) === false) { + throw new WriteOperationFailedException($target); } } return $buffer; } - - private function createDirectory(string $directory): bool - { - return !(!\is_dir($directory) && !@\mkdir($directory, 0777, true) && !\is_dir($directory)); - } } diff --git a/vendor/phpunit/php-code-coverage/src/Report/Text.php b/vendor/phpunit/php-code-coverage/src/Report/Text.php index 9593a2285..b587d36a8 100644 --- a/vendor/phpunit/php-code-coverage/src/Report/Text.php +++ b/vendor/phpunit/php-code-coverage/src/Report/Text.php @@ -1,6 +1,6 @@ * @@ -9,15 +9,18 @@ */ namespace SebastianBergmann\CodeCoverage\Report; +use const PHP_EOL; +use function array_map; +use function date; +use function ksort; +use function max; +use function sprintf; +use function str_pad; +use function strlen; use SebastianBergmann\CodeCoverage\CodeCoverage; use SebastianBergmann\CodeCoverage\Node\File; -use SebastianBergmann\CodeCoverage\Util; +use SebastianBergmann\CodeCoverage\Percentage; -/** - * Generates human readable output from a code coverage object. - * - * The output gets put into a text file our written to the CLI. - */ final class Text { /** @@ -80,32 +83,46 @@ final class Text public function process(CodeCoverage $coverage, bool $showColors = false): string { - $output = \PHP_EOL . \PHP_EOL; + $hasBranchCoverage = !empty($coverage->getData(true)->functionCoverage()); + + $output = PHP_EOL . PHP_EOL; $report = $coverage->getReport(); $colors = [ - 'header' => '', - 'classes' => '', - 'methods' => '', - 'lines' => '', - 'reset' => '', - 'eol' => '', + 'header' => '', + 'classes' => '', + 'methods' => '', + 'lines' => '', + 'branches' => '', + 'paths' => '', + 'reset' => '', + 'eol' => '', ]; if ($showColors) { - $colors['classes'] = $this->getCoverageColor( - $report->getNumTestedClassesAndTraits(), - $report->getNumClassesAndTraits() + $colors['classes'] = $this->coverageColor( + $report->numberOfTestedClassesAndTraits(), + $report->numberOfClassesAndTraits() ); - $colors['methods'] = $this->getCoverageColor( - $report->getNumTestedMethods(), - $report->getNumMethods() + $colors['methods'] = $this->coverageColor( + $report->numberOfTestedMethods(), + $report->numberOfMethods() ); - $colors['lines'] = $this->getCoverageColor( - $report->getNumExecutedLines(), - $report->getNumExecutableLines() + $colors['lines'] = $this->coverageColor( + $report->numberOfExecutedLines(), + $report->numberOfExecutableLines() + ); + + $colors['branches'] = $this->coverageColor( + $report->numberOfExecutedBranches(), + $report->numberOfExecutableBranches() + ); + + $colors['paths'] = $this->coverageColor( + $report->numberOfExecutedPaths(), + $report->numberOfExecutablePaths() ); $colors['reset'] = self::COLOR_RESET; @@ -113,48 +130,70 @@ final class Text $colors['eol'] = self::COLOR_EOL; } - $classes = \sprintf( + $classes = sprintf( ' Classes: %6s (%d/%d)', - Util::percent( - $report->getNumTestedClassesAndTraits(), - $report->getNumClassesAndTraits(), - true - ), - $report->getNumTestedClassesAndTraits(), - $report->getNumClassesAndTraits() + Percentage::fromFractionAndTotal( + $report->numberOfTestedClassesAndTraits(), + $report->numberOfClassesAndTraits() + )->asString(), + $report->numberOfTestedClassesAndTraits(), + $report->numberOfClassesAndTraits() ); - $methods = \sprintf( + $methods = sprintf( ' Methods: %6s (%d/%d)', - Util::percent( - $report->getNumTestedMethods(), - $report->getNumMethods(), - true - ), - $report->getNumTestedMethods(), - $report->getNumMethods() + Percentage::fromFractionAndTotal( + $report->numberOfTestedMethods(), + $report->numberOfMethods(), + )->asString(), + $report->numberOfTestedMethods(), + $report->numberOfMethods() ); - $lines = \sprintf( + $paths = ''; + $branches = ''; + + if ($hasBranchCoverage) { + $paths = sprintf( + ' Paths: %6s (%d/%d)', + Percentage::fromFractionAndTotal( + $report->numberOfExecutedPaths(), + $report->numberOfExecutablePaths(), + )->asString(), + $report->numberOfExecutedPaths(), + $report->numberOfExecutablePaths() + ); + + $branches = sprintf( + ' Branches: %6s (%d/%d)', + Percentage::fromFractionAndTotal( + $report->numberOfExecutedBranches(), + $report->numberOfExecutableBranches(), + )->asString(), + $report->numberOfExecutedBranches(), + $report->numberOfExecutableBranches() + ); + } + + $lines = sprintf( ' Lines: %6s (%d/%d)', - Util::percent( - $report->getNumExecutedLines(), - $report->getNumExecutableLines(), - true - ), - $report->getNumExecutedLines(), - $report->getNumExecutableLines() + Percentage::fromFractionAndTotal( + $report->numberOfExecutedLines(), + $report->numberOfExecutableLines(), + )->asString(), + $report->numberOfExecutedLines(), + $report->numberOfExecutableLines() ); - $padding = \max(\array_map('strlen', [$classes, $methods, $lines])); + $padding = max(array_map('strlen', [$classes, $methods, $lines])); if ($this->showOnlySummary) { $title = 'Code Coverage Report Summary:'; - $padding = \max($padding, \strlen($title)); + $padding = max($padding, strlen($title)); $output .= $this->format($colors['header'], $padding, $title); } else { - $date = \date(' Y-m-d H:i:s', $_SERVER['REQUEST_TIME']); + $date = date(' Y-m-d H:i:s'); $title = 'Code Coverage Report:'; $output .= $this->format($colors['header'], $padding, $title); @@ -165,10 +204,15 @@ final class Text $output .= $this->format($colors['classes'], $padding, $classes); $output .= $this->format($colors['methods'], $padding, $methods); + + if ($hasBranchCoverage) { + $output .= $this->format($colors['paths'], $padding, $paths); + $output .= $this->format($colors['branches'], $padding, $branches); + } $output .= $this->format($colors['lines'], $padding, $lines); if ($this->showOnlySummary) { - return $output . \PHP_EOL; + return $output . PHP_EOL; } $classCoverage = []; @@ -178,13 +222,17 @@ final class Text continue; } - $classes = $item->getClassesAndTraits(); + $classes = $item->classesAndTraits(); foreach ($classes as $className => $class) { - $classStatements = 0; - $coveredClassStatements = 0; - $coveredMethods = 0; - $classMethods = 0; + $classExecutableLines = 0; + $classExecutedLines = 0; + $classExecutableBranches = 0; + $classExecutedBranches = 0; + $classExecutablePaths = 0; + $classExecutedPaths = 0; + $coveredMethods = 0; + $classMethods = 0; foreach ($class['methods'] as $method) { if ($method['executableLines'] == 0) { @@ -192,68 +240,77 @@ final class Text } $classMethods++; - $classStatements += $method['executableLines']; - $coveredClassStatements += $method['executedLines']; + $classExecutableLines += $method['executableLines']; + $classExecutedLines += $method['executedLines']; + $classExecutableBranches += $method['executableBranches']; + $classExecutedBranches += $method['executedBranches']; + $classExecutablePaths += $method['executablePaths']; + $classExecutedPaths += $method['executedPaths']; if ($method['coverage'] == 100) { $coveredMethods++; } } - $namespace = ''; - - if (!empty($class['package']['namespace'])) { - $namespace = '\\' . $class['package']['namespace'] . '::'; - } elseif (!empty($class['package']['fullPackage'])) { - $namespace = '@' . $class['package']['fullPackage'] . '::'; - } - - $classCoverage[$namespace . $className] = [ - 'namespace' => $namespace, - 'className ' => $className, + $classCoverage[$className] = [ + 'namespace' => $class['namespace'], + 'className' => $className, 'methodsCovered' => $coveredMethods, 'methodCount' => $classMethods, - 'statementsCovered' => $coveredClassStatements, - 'statementCount' => $classStatements, + 'statementsCovered' => $classExecutedLines, + 'statementCount' => $classExecutableLines, + 'branchesCovered' => $classExecutedBranches, + 'branchesCount' => $classExecutableBranches, + 'pathsCovered' => $classExecutedPaths, + 'pathsCount' => $classExecutablePaths, ]; } } - \ksort($classCoverage); + ksort($classCoverage); - $methodColor = ''; - $linesColor = ''; - $resetColor = ''; + $methodColor = ''; + $pathsColor = ''; + $branchesColor = ''; + $linesColor = ''; + $resetColor = ''; foreach ($classCoverage as $fullQualifiedPath => $classInfo) { if ($this->showUncoveredFiles || $classInfo['statementsCovered'] != 0) { if ($showColors) { - $methodColor = $this->getCoverageColor($classInfo['methodsCovered'], $classInfo['methodCount']); - $linesColor = $this->getCoverageColor($classInfo['statementsCovered'], $classInfo['statementCount']); - $resetColor = $colors['reset']; + $methodColor = $this->coverageColor($classInfo['methodsCovered'], $classInfo['methodCount']); + $pathsColor = $this->coverageColor($classInfo['pathsCovered'], $classInfo['pathsCount']); + $branchesColor = $this->coverageColor($classInfo['branchesCovered'], $classInfo['branchesCount']); + $linesColor = $this->coverageColor($classInfo['statementsCovered'], $classInfo['statementCount']); + $resetColor = $colors['reset']; } - $output .= \PHP_EOL . $fullQualifiedPath . \PHP_EOL - . ' ' . $methodColor . 'Methods: ' . $this->printCoverageCounts($classInfo['methodsCovered'], $classInfo['methodCount'], 2) . $resetColor . ' ' - . ' ' . $linesColor . 'Lines: ' . $this->printCoverageCounts($classInfo['statementsCovered'], $classInfo['statementCount'], 3) . $resetColor; + $output .= PHP_EOL . $fullQualifiedPath . PHP_EOL + . ' ' . $methodColor . 'Methods: ' . $this->printCoverageCounts($classInfo['methodsCovered'], $classInfo['methodCount'], 2) . $resetColor . ' '; + + if ($hasBranchCoverage) { + $output .= ' ' . $pathsColor . 'Paths: ' . $this->printCoverageCounts($classInfo['pathsCovered'], $classInfo['pathsCount'], 3) . $resetColor . ' ' + . ' ' . $branchesColor . 'Branches: ' . $this->printCoverageCounts($classInfo['branchesCovered'], $classInfo['branchesCount'], 3) . $resetColor . ' '; + } + $output .= ' ' . $linesColor . 'Lines: ' . $this->printCoverageCounts($classInfo['statementsCovered'], $classInfo['statementCount'], 3) . $resetColor; } } - return $output . \PHP_EOL; + return $output . PHP_EOL; } - private function getCoverageColor(int $numberOfCoveredElements, int $totalNumberOfElements): string + private function coverageColor(int $numberOfCoveredElements, int $totalNumberOfElements): string { - $coverage = Util::percent( + $coverage = Percentage::fromFractionAndTotal( $numberOfCoveredElements, $totalNumberOfElements ); - if ($coverage >= $this->highLowerBound) { + if ($coverage->asFloat() >= $this->highLowerBound) { return self::COLOR_GREEN; } - if ($coverage > $this->lowUpperBound) { + if ($coverage->asFloat() > $this->lowUpperBound) { return self::COLOR_YELLOW; } @@ -264,20 +321,21 @@ final class Text { $format = '%' . $precision . 's'; - return Util::percent( + return Percentage::fromFractionAndTotal( $numberOfCoveredElements, - $totalNumberOfElements, - true, - true - ) . - ' (' . \sprintf($format, $numberOfCoveredElements) . '/' . - \sprintf($format, $totalNumberOfElements) . ')'; + $totalNumberOfElements + )->asFixedWidthString() . + ' (' . sprintf($format, $numberOfCoveredElements) . '/' . + sprintf($format, $totalNumberOfElements) . ')'; } - private function format($color, $padding, $string): string + /** + * @param false|string $string + */ + private function format(string $color, int $padding, $string): string { $reset = $color ? self::COLOR_RESET : ''; - return $color . \str_pad($string, $padding) . $reset . \PHP_EOL; + return $color . str_pad((string) $string, $padding) . $reset . PHP_EOL; } } diff --git a/vendor/phpunit/php-code-coverage/src/Report/Xml/BuildInformation.php b/vendor/phpunit/php-code-coverage/src/Report/Xml/BuildInformation.php index c12a5d2cf..ebdbae612 100644 --- a/vendor/phpunit/php-code-coverage/src/Report/Xml/BuildInformation.php +++ b/vendor/phpunit/php-code-coverage/src/Report/Xml/BuildInformation.php @@ -1,6 +1,6 @@ * @@ -9,47 +9,54 @@ */ namespace SebastianBergmann\CodeCoverage\Report\Xml; +use function constant; +use function phpversion; +use DateTimeImmutable; +use DOMElement; use SebastianBergmann\Environment\Runtime; +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ final class BuildInformation { /** - * @var \DOMElement + * @var DOMElement */ private $contextNode; - public function __construct(\DOMElement $contextNode) + public function __construct(DOMElement $contextNode) { $this->contextNode = $contextNode; } public function setRuntimeInformation(Runtime $runtime): void { - $runtimeNode = $this->getNodeByName('runtime'); + $runtimeNode = $this->nodeByName('runtime'); $runtimeNode->setAttribute('name', $runtime->getName()); $runtimeNode->setAttribute('version', $runtime->getVersion()); $runtimeNode->setAttribute('url', $runtime->getVendorUrl()); - $driverNode = $this->getNodeByName('driver'); + $driverNode = $this->nodeByName('driver'); if ($runtime->hasPHPDBGCodeCoverage()) { $driverNode->setAttribute('name', 'phpdbg'); - $driverNode->setAttribute('version', \constant('PHPDBG_VERSION')); + $driverNode->setAttribute('version', constant('PHPDBG_VERSION')); } if ($runtime->hasXdebug()) { $driverNode->setAttribute('name', 'xdebug'); - $driverNode->setAttribute('version', \phpversion('xdebug')); + $driverNode->setAttribute('version', phpversion('xdebug')); } if ($runtime->hasPCOV()) { $driverNode->setAttribute('name', 'pcov'); - $driverNode->setAttribute('version', \phpversion('pcov')); + $driverNode->setAttribute('version', phpversion('pcov')); } } - public function setBuildTime(\DateTime $date): void + public function setBuildTime(DateTimeImmutable $date): void { $this->contextNode->setAttribute('time', $date->format('D M j G:i:s T Y')); } @@ -60,7 +67,7 @@ final class BuildInformation $this->contextNode->setAttribute('coverage', $coverageVersion); } - private function getNodeByName(string $name): \DOMElement + private function nodeByName(string $name): DOMElement { $node = $this->contextNode->getElementsByTagNameNS( 'https://schema.phpunit.de/coverage/1.0', diff --git a/vendor/phpunit/php-code-coverage/src/Report/Xml/Coverage.php b/vendor/phpunit/php-code-coverage/src/Report/Xml/Coverage.php index 996a6196a..215f9b932 100644 --- a/vendor/phpunit/php-code-coverage/src/Report/Xml/Coverage.php +++ b/vendor/phpunit/php-code-coverage/src/Report/Xml/Coverage.php @@ -1,6 +1,6 @@ * @@ -9,17 +9,22 @@ */ namespace SebastianBergmann\CodeCoverage\Report\Xml; -use SebastianBergmann\CodeCoverage\RuntimeException; +use DOMElement; +use SebastianBergmann\CodeCoverage\ReportAlreadyFinalizedException; +use XMLWriter; +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ final class Coverage { /** - * @var \XMLWriter + * @var XMLWriter */ private $writer; /** - * @var \DOMElement + * @var DOMElement */ private $contextNode; @@ -28,23 +33,23 @@ final class Coverage */ private $finalized = false; - public function __construct(\DOMElement $context, string $line) + public function __construct(DOMElement $context, string $line) { $this->contextNode = $context; - $this->writer = new \XMLWriter(); + $this->writer = new XMLWriter(); $this->writer->openMemory(); $this->writer->startElementNS(null, $context->nodeName, 'https://schema.phpunit.de/coverage/1.0'); $this->writer->writeAttribute('nr', $line); } /** - * @throws RuntimeException + * @throws ReportAlreadyFinalizedException */ public function addTest(string $test): void { if ($this->finalized) { - throw new RuntimeException('Coverage Report already finalized'); + throw new ReportAlreadyFinalizedException; } $this->writer->startElement('covered'); diff --git a/vendor/phpunit/php-code-coverage/src/Report/Xml/Directory.php b/vendor/phpunit/php-code-coverage/src/Report/Xml/Directory.php index b1823214c..b712953ab 100644 --- a/vendor/phpunit/php-code-coverage/src/Report/Xml/Directory.php +++ b/vendor/phpunit/php-code-coverage/src/Report/Xml/Directory.php @@ -1,6 +1,6 @@ * @@ -9,6 +9,9 @@ */ namespace SebastianBergmann\CodeCoverage\Report\Xml; +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ final class Directory extends Node { } diff --git a/vendor/phpunit/php-code-coverage/src/Report/Xml/Facade.php b/vendor/phpunit/php-code-coverage/src/Report/Xml/Facade.php index c908a1507..b4158d330 100644 --- a/vendor/phpunit/php-code-coverage/src/Report/Xml/Facade.php +++ b/vendor/phpunit/php-code-coverage/src/Report/Xml/Facade.php @@ -1,6 +1,6 @@ * @@ -9,12 +9,33 @@ */ namespace SebastianBergmann\CodeCoverage\Report\Xml; +use const DIRECTORY_SEPARATOR; +use const PHP_EOL; +use function count; +use function dirname; +use function file_get_contents; +use function file_put_contents; +use function is_array; +use function is_dir; +use function is_file; +use function is_writable; +use function libxml_clear_errors; +use function libxml_get_errors; +use function libxml_use_internal_errors; +use function sprintf; +use function strlen; +use function substr; +use DateTimeImmutable; +use DOMDocument; use SebastianBergmann\CodeCoverage\CodeCoverage; +use SebastianBergmann\CodeCoverage\Directory as DirectoryUtil; +use SebastianBergmann\CodeCoverage\Driver\PathExistsButIsNotDirectoryException; +use SebastianBergmann\CodeCoverage\Driver\WriteOperationFailedException; use SebastianBergmann\CodeCoverage\Node\AbstractNode; use SebastianBergmann\CodeCoverage\Node\Directory as DirectoryNode; use SebastianBergmann\CodeCoverage\Node\File as FileNode; -use SebastianBergmann\CodeCoverage\RuntimeException; use SebastianBergmann\CodeCoverage\Version; +use SebastianBergmann\CodeCoverage\XmlException; use SebastianBergmann\Environment\Runtime; final class Facade @@ -40,12 +61,12 @@ final class Facade } /** - * @throws RuntimeException + * @throws XmlException */ public function process(CodeCoverage $coverage, string $target): void { - if (\substr($target, -1, 1) !== \DIRECTORY_SEPARATOR) { - $target .= \DIRECTORY_SEPARATOR; + if (substr($target, -1, 1) !== DIRECTORY_SEPARATOR) { + $target .= DIRECTORY_SEPARATOR; } $this->target = $target; @@ -54,7 +75,7 @@ final class Facade $report = $coverage->getReport(); $this->project = new Project( - $coverage->getReport()->getName() + $coverage->getReport()->name() ); $this->setBuildInformation(); @@ -66,92 +87,90 @@ final class Facade private function setBuildInformation(): void { - $buildNode = $this->project->getBuildInformation(); - $buildNode->setRuntimeInformation(new Runtime()); - $buildNode->setBuildTime(\DateTime::createFromFormat('U', (string) $_SERVER['REQUEST_TIME'])); + $buildNode = $this->project->buildInformation(); + $buildNode->setRuntimeInformation(new Runtime); + $buildNode->setBuildTime(new DateTimeImmutable); $buildNode->setGeneratorVersions($this->phpUnitVersion, Version::id()); } /** - * @throws RuntimeException + * @throws PathExistsButIsNotDirectoryException + * @throws WriteOperationFailedException */ private function initTargetDirectory(string $directory): void { - if (\file_exists($directory)) { - if (!\is_dir($directory)) { - throw new RuntimeException( - "'$directory' exists but is not a directory." - ); + if (is_file($directory)) { + if (!is_dir($directory)) { + throw new PathExistsButIsNotDirectoryException($directory); } - if (!\is_writable($directory)) { - throw new RuntimeException( - "'$directory' exists but is not writable." - ); + if (!is_writable($directory)) { + throw new WriteOperationFailedException($directory); } - } elseif (!$this->createDirectory($directory)) { - throw new RuntimeException( - "'$directory' could not be created." - ); } + + DirectoryUtil::create($directory); } + /** + * @throws XmlException + */ private function processDirectory(DirectoryNode $directory, Node $context): void { - $directoryName = $directory->getName(); + $directoryName = $directory->name(); - if ($this->project->getProjectSourceDirectory() === $directoryName) { + if ($this->project->projectSourceDirectory() === $directoryName) { $directoryName = '/'; } $directoryObject = $context->addDirectory($directoryName); - $this->setTotals($directory, $directoryObject->getTotals()); + $this->setTotals($directory, $directoryObject->totals()); - foreach ($directory->getDirectories() as $node) { + foreach ($directory->directories() as $node) { $this->processDirectory($node, $directoryObject); } - foreach ($directory->getFiles() as $node) { + foreach ($directory->files() as $node) { $this->processFile($node, $directoryObject); } } /** - * @throws RuntimeException + * @throws XmlException */ private function processFile(FileNode $file, Directory $context): void { $fileObject = $context->addFile( - $file->getName(), - $file->getId() . '.xml' + $file->name(), + $file->id() . '.xml' ); - $this->setTotals($file, $fileObject->getTotals()); + $this->setTotals($file, $fileObject->totals()); - $path = \substr( - $file->getPath(), - \strlen($this->project->getProjectSourceDirectory()) + $path = substr( + $file->pathAsString(), + strlen($this->project->projectSourceDirectory()) ); $fileReport = new Report($path); - $this->setTotals($file, $fileReport->getTotals()); + $this->setTotals($file, $fileReport->totals()); - foreach ($file->getClassesAndTraits() as $unit) { + foreach ($file->classesAndTraits() as $unit) { $this->processUnit($unit, $fileReport); } - foreach ($file->getFunctions() as $function) { + foreach ($file->functions() as $function) { $this->processFunction($function, $fileReport); } - foreach ($file->getCoverageData() as $line => $tests) { - if (!\is_array($tests) || \count($tests) === 0) { + foreach ($file->lineCoverageData() as $line => $tests) { + if (!is_array($tests) || count($tests) === 0) { continue; } - $coverage = $fileReport->getLineCoverage((string) $line); + $coverage = $fileReport->lineCoverage((string) $line); foreach ($tests as $test) { $coverage->addTest($test); @@ -160,19 +179,19 @@ final class Facade $coverage->finalize(); } - $fileReport->getSource()->setSourceCode( - \file_get_contents($file->getPath()) + $fileReport->source()->setSourceCode( + file_get_contents($file->pathAsString()) ); - $this->saveDocument($fileReport->asDom(), $file->getId()); + $this->saveDocument($fileReport->asDom(), $file->id()); } private function processUnit(array $unit, Report $report): void { if (isset($unit['className'])) { - $unitObject = $report->getClassObject($unit['className']); + $unitObject = $report->classObject($unit['className']); } else { - $unitObject = $report->getTraitObject($unit['traitName']); + $unitObject = $report->traitObject($unit['traitName']); } $unitObject->setLines( @@ -182,15 +201,7 @@ final class Facade ); $unitObject->setCrap((float) $unit['crap']); - - $unitObject->setPackage( - $unit['package']['fullPackage'], - $unit['package']['package'], - $unit['package']['subpackage'], - $unit['package']['category'] - ); - - $unitObject->setNamespace($unit['package']['namespace']); + $unitObject->setNamespace($unit['namespace']); foreach ($unit['methods'] as $method) { $methodObject = $unitObject->addMethod($method['methodName']); @@ -207,7 +218,7 @@ final class Facade private function processFunction(array $function, Report $report): void { - $functionObject = $report->getFunctionObject($function['functionName']); + $functionObject = $report->functionObject($function['functionName']); $functionObject->setSignature($function['signature']); $functionObject->setLines((string) $function['startLine']); @@ -217,71 +228,88 @@ final class Facade private function processTests(array $tests): void { - $testsObject = $this->project->getTests(); + $testsObject = $this->project->tests(); foreach ($tests as $test => $result) { - if ($test === 'UNCOVERED_FILES_FROM_WHITELIST') { - continue; - } - $testsObject->addTest($test, $result); } } private function setTotals(AbstractNode $node, Totals $totals): void { - $loc = $node->getLinesOfCode(); + $loc = $node->linesOfCode(); $totals->setNumLines( - $loc['loc'], - $loc['cloc'], - $loc['ncloc'], - $node->getNumExecutableLines(), - $node->getNumExecutedLines() + $loc->linesOfCode(), + $loc->commentLinesOfCode(), + $loc->nonCommentLinesOfCode(), + $node->numberOfExecutableLines(), + $node->numberOfExecutedLines() ); $totals->setNumClasses( - $node->getNumClasses(), - $node->getNumTestedClasses() + $node->numberOfClasses(), + $node->numberOfTestedClasses() ); $totals->setNumTraits( - $node->getNumTraits(), - $node->getNumTestedTraits() + $node->numberOfTraits(), + $node->numberOfTestedTraits() ); $totals->setNumMethods( - $node->getNumMethods(), - $node->getNumTestedMethods() + $node->numberOfMethods(), + $node->numberOfTestedMethods() ); $totals->setNumFunctions( - $node->getNumFunctions(), - $node->getNumTestedFunctions() + $node->numberOfFunctions(), + $node->numberOfTestedFunctions() ); } - private function getTargetDirectory(): string + private function targetDirectory(): string { return $this->target; } /** - * @throws RuntimeException + * @throws XmlException */ - private function saveDocument(\DOMDocument $document, string $name): void + private function saveDocument(DOMDocument $document, string $name): void { - $filename = \sprintf('%s/%s.xml', $this->getTargetDirectory(), $name); + $filename = sprintf('%s/%s.xml', $this->targetDirectory(), $name); $document->formatOutput = true; $document->preserveWhiteSpace = false; - $this->initTargetDirectory(\dirname($filename)); + $this->initTargetDirectory(dirname($filename)); - $document->save($filename); + file_put_contents($filename, $this->documentAsString($document)); } - private function createDirectory(string $directory): bool + /** + * @throws XmlException + * + * @see https://bugs.php.net/bug.php?id=79191 + */ + private function documentAsString(DOMDocument $document): string { - return !(!\is_dir($directory) && !@\mkdir($directory, 0777, true) && !\is_dir($directory)); + $xmlErrorHandling = libxml_use_internal_errors(true); + $xml = $document->saveXML(); + + if ($xml === false) { + $message = 'Unable to generate the XML'; + + foreach (libxml_get_errors() as $error) { + $message .= PHP_EOL . $error->message; + } + + throw new XmlException($message); + } + + libxml_clear_errors(); + libxml_use_internal_errors($xmlErrorHandling); + + return $xml; } } diff --git a/vendor/phpunit/php-code-coverage/src/Report/Xml/File.php b/vendor/phpunit/php-code-coverage/src/Report/Xml/File.php index 02af64477..245c5cee6 100644 --- a/vendor/phpunit/php-code-coverage/src/Report/Xml/File.php +++ b/vendor/phpunit/php-code-coverage/src/Report/Xml/File.php @@ -1,6 +1,6 @@ * @@ -9,25 +9,31 @@ */ namespace SebastianBergmann\CodeCoverage\Report\Xml; +use DOMDocument; +use DOMElement; + +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ class File { /** - * @var \DOMDocument + * @var DOMDocument */ private $dom; /** - * @var \DOMElement + * @var DOMElement */ private $contextNode; - public function __construct(\DOMElement $context) + public function __construct(DOMElement $context) { $this->dom = $context->ownerDocument; $this->contextNode = $context; } - public function getTotals(): Totals + public function totals(): Totals { $totalsContainer = $this->contextNode->firstChild; @@ -43,7 +49,7 @@ class File return new Totals($totalsContainer); } - public function getLineCoverage(string $line): Coverage + public function lineCoverage(string $line): Coverage { $coverage = $this->contextNode->getElementsByTagNameNS( 'https://schema.phpunit.de/coverage/1.0', @@ -69,12 +75,12 @@ class File return new Coverage($lineNode, $line); } - protected function getContextNode(): \DOMElement + protected function contextNode(): DOMElement { return $this->contextNode; } - protected function getDomDocument(): \DOMDocument + protected function dom(): DOMDocument { return $this->dom; } diff --git a/vendor/phpunit/php-code-coverage/src/Report/Xml/Method.php b/vendor/phpunit/php-code-coverage/src/Report/Xml/Method.php index b6a7f1602..7e3009997 100644 --- a/vendor/phpunit/php-code-coverage/src/Report/Xml/Method.php +++ b/vendor/phpunit/php-code-coverage/src/Report/Xml/Method.php @@ -1,6 +1,6 @@ * @@ -9,14 +9,19 @@ */ namespace SebastianBergmann\CodeCoverage\Report\Xml; +use DOMElement; + +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ final class Method { /** - * @var \DOMElement + * @var DOMElement */ private $contextNode; - public function __construct(\DOMElement $context, string $name) + public function __construct(DOMElement $context, string $name) { $this->contextNode = $context; diff --git a/vendor/phpunit/php-code-coverage/src/Report/Xml/Node.php b/vendor/phpunit/php-code-coverage/src/Report/Xml/Node.php index d3ba223a5..159923093 100644 --- a/vendor/phpunit/php-code-coverage/src/Report/Xml/Node.php +++ b/vendor/phpunit/php-code-coverage/src/Report/Xml/Node.php @@ -1,6 +1,6 @@ * @@ -9,34 +9,40 @@ */ namespace SebastianBergmann\CodeCoverage\Report\Xml; +use DOMDocument; +use DOMElement; + +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ abstract class Node { /** - * @var \DOMDocument + * @var DOMDocument */ private $dom; /** - * @var \DOMElement + * @var DOMElement */ private $contextNode; - public function __construct(\DOMElement $context) + public function __construct(DOMElement $context) { $this->setContextNode($context); } - public function getDom(): \DOMDocument + public function dom(): DOMDocument { return $this->dom; } - public function getTotals(): Totals + public function totals(): Totals { - $totalsContainer = $this->getContextNode()->firstChild; + $totalsContainer = $this->contextNode()->firstChild; if (!$totalsContainer) { - $totalsContainer = $this->getContextNode()->appendChild( + $totalsContainer = $this->contextNode()->appendChild( $this->dom->createElementNS( 'https://schema.phpunit.de/coverage/1.0', 'totals' @@ -49,38 +55,38 @@ abstract class Node public function addDirectory(string $name): Directory { - $dirNode = $this->getDom()->createElementNS( + $dirNode = $this->dom()->createElementNS( 'https://schema.phpunit.de/coverage/1.0', 'directory' ); $dirNode->setAttribute('name', $name); - $this->getContextNode()->appendChild($dirNode); + $this->contextNode()->appendChild($dirNode); return new Directory($dirNode); } public function addFile(string $name, string $href): File { - $fileNode = $this->getDom()->createElementNS( + $fileNode = $this->dom()->createElementNS( 'https://schema.phpunit.de/coverage/1.0', 'file' ); $fileNode->setAttribute('name', $name); $fileNode->setAttribute('href', $href); - $this->getContextNode()->appendChild($fileNode); + $this->contextNode()->appendChild($fileNode); return new File($fileNode); } - protected function setContextNode(\DOMElement $context): void + protected function setContextNode(DOMElement $context): void { $this->dom = $context->ownerDocument; $this->contextNode = $context; } - protected function getContextNode(): \DOMElement + protected function contextNode(): DOMElement { return $this->contextNode; } diff --git a/vendor/phpunit/php-code-coverage/src/Report/Xml/Project.php b/vendor/phpunit/php-code-coverage/src/Report/Xml/Project.php index 5f32852f8..b566bce06 100644 --- a/vendor/phpunit/php-code-coverage/src/Report/Xml/Project.php +++ b/vendor/phpunit/php-code-coverage/src/Report/Xml/Project.php @@ -1,6 +1,6 @@ * @@ -9,6 +9,11 @@ */ namespace SebastianBergmann\CodeCoverage\Report\Xml; +use DOMDocument; + +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ final class Project extends Node { public function __construct(string $directory) @@ -17,21 +22,21 @@ final class Project extends Node $this->setProjectSourceDirectory($directory); } - public function getProjectSourceDirectory(): string + public function projectSourceDirectory(): string { - return $this->getContextNode()->getAttribute('source'); + return $this->contextNode()->getAttribute('source'); } - public function getBuildInformation(): BuildInformation + public function buildInformation(): BuildInformation { - $buildNode = $this->getDom()->getElementsByTagNameNS( + $buildNode = $this->dom()->getElementsByTagNameNS( 'https://schema.phpunit.de/coverage/1.0', 'build' )->item(0); if (!$buildNode) { - $buildNode = $this->getDom()->documentElement->appendChild( - $this->getDom()->createElementNS( + $buildNode = $this->dom()->documentElement->appendChild( + $this->dom()->createElementNS( 'https://schema.phpunit.de/coverage/1.0', 'build' ) @@ -41,16 +46,16 @@ final class Project extends Node return new BuildInformation($buildNode); } - public function getTests(): Tests + public function tests(): Tests { - $testsNode = $this->getContextNode()->getElementsByTagNameNS( + $testsNode = $this->contextNode()->getElementsByTagNameNS( 'https://schema.phpunit.de/coverage/1.0', 'tests' )->item(0); if (!$testsNode) { - $testsNode = $this->getContextNode()->appendChild( - $this->getDom()->createElementNS( + $testsNode = $this->contextNode()->appendChild( + $this->dom()->createElementNS( 'https://schema.phpunit.de/coverage/1.0', 'tests' ) @@ -60,14 +65,14 @@ final class Project extends Node return new Tests($testsNode); } - public function asDom(): \DOMDocument + public function asDom(): DOMDocument { - return $this->getDom(); + return $this->dom(); } private function init(): void { - $dom = new \DOMDocument; + $dom = new DOMDocument; $dom->loadXML(''); $this->setContextNode( @@ -80,6 +85,6 @@ final class Project extends Node private function setProjectSourceDirectory(string $name): void { - $this->getContextNode()->setAttribute('source', $name); + $this->contextNode()->setAttribute('source', $name); } } diff --git a/vendor/phpunit/php-code-coverage/src/Report/Xml/Report.php b/vendor/phpunit/php-code-coverage/src/Report/Xml/Report.php index 6ec94c100..b53b08c00 100644 --- a/vendor/phpunit/php-code-coverage/src/Report/Xml/Report.php +++ b/vendor/phpunit/php-code-coverage/src/Report/Xml/Report.php @@ -1,6 +1,6 @@ * @@ -9,11 +9,18 @@ */ namespace SebastianBergmann\CodeCoverage\Report\Xml; +use function basename; +use function dirname; +use DOMDocument; + +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ final class Report extends File { public function __construct(string $name) { - $dom = new \DOMDocument(); + $dom = new DOMDocument(); $dom->loadXML(''); $contextNode = $dom->getElementsByTagNameNS( @@ -26,15 +33,15 @@ final class Report extends File $this->setName($name); } - public function asDom(): \DOMDocument + public function asDom(): DOMDocument { - return $this->getDomDocument(); + return $this->dom(); } - public function getFunctionObject($name): Method + public function functionObject($name): Method { - $node = $this->getContextNode()->appendChild( - $this->getDomDocument()->createElementNS( + $node = $this->contextNode()->appendChild( + $this->dom()->createElementNS( 'https://schema.phpunit.de/coverage/1.0', 'function' ) @@ -43,26 +50,26 @@ final class Report extends File return new Method($node, $name); } - public function getClassObject($name): Unit + public function classObject($name): Unit { - return $this->getUnitObject('class', $name); + return $this->unitObject('class', $name); } - public function getTraitObject($name): Unit + public function traitObject($name): Unit { - return $this->getUnitObject('trait', $name); + return $this->unitObject('trait', $name); } - public function getSource(): Source + public function source(): Source { - $source = $this->getContextNode()->getElementsByTagNameNS( + $source = $this->contextNode()->getElementsByTagNameNS( 'https://schema.phpunit.de/coverage/1.0', 'source' )->item(0); if (!$source) { - $source = $this->getContextNode()->appendChild( - $this->getDomDocument()->createElementNS( + $source = $this->contextNode()->appendChild( + $this->dom()->createElementNS( 'https://schema.phpunit.de/coverage/1.0', 'source' ) @@ -72,16 +79,16 @@ final class Report extends File return new Source($source); } - private function setName($name): void + private function setName(string $name): void { - $this->getContextNode()->setAttribute('name', \basename($name)); - $this->getContextNode()->setAttribute('path', \dirname($name)); + $this->contextNode()->setAttribute('name', basename($name)); + $this->contextNode()->setAttribute('path', dirname($name)); } - private function getUnitObject($tagName, $name): Unit + private function unitObject(string $tagName, $name): Unit { - $node = $this->getContextNode()->appendChild( - $this->getDomDocument()->createElementNS( + $node = $this->contextNode()->appendChild( + $this->dom()->createElementNS( 'https://schema.phpunit.de/coverage/1.0', $tagName ) diff --git a/vendor/phpunit/php-code-coverage/src/Report/Xml/Source.php b/vendor/phpunit/php-code-coverage/src/Report/Xml/Source.php index 67bf9cb9b..8fd20f58f 100644 --- a/vendor/phpunit/php-code-coverage/src/Report/Xml/Source.php +++ b/vendor/phpunit/php-code-coverage/src/Report/Xml/Source.php @@ -1,6 +1,6 @@ * @@ -9,16 +9,20 @@ */ namespace SebastianBergmann\CodeCoverage\Report\Xml; +use DOMElement; use TheSeer\Tokenizer\NamespaceUri; use TheSeer\Tokenizer\Tokenizer; use TheSeer\Tokenizer\XMLSerializer; +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ final class Source { - /** @var \DOMElement */ + /** @var DOMElement */ private $context; - public function __construct(\DOMElement $context) + public function __construct(DOMElement $context) { $this->context = $context; } diff --git a/vendor/phpunit/php-code-coverage/src/Report/Xml/Tests.php b/vendor/phpunit/php-code-coverage/src/Report/Xml/Tests.php index c1bcd25d9..c2e56268c 100644 --- a/vendor/phpunit/php-code-coverage/src/Report/Xml/Tests.php +++ b/vendor/phpunit/php-code-coverage/src/Report/Xml/Tests.php @@ -1,6 +1,6 @@ * @@ -9,6 +9,11 @@ */ namespace SebastianBergmann\CodeCoverage\Report\Xml; +use DOMElement; + +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ final class Tests { private $contextNode; @@ -24,7 +29,7 @@ final class Tests 6 => 'WARNING', // PHPUnit_Runner_BaseTestRunner::STATUS_WARNING ]; - public function __construct(\DOMElement $context) + public function __construct(DOMElement $context) { $this->contextNode = $context; } diff --git a/vendor/phpunit/php-code-coverage/src/Report/Xml/Totals.php b/vendor/phpunit/php-code-coverage/src/Report/Xml/Totals.php index 019f348cb..17a4cb178 100644 --- a/vendor/phpunit/php-code-coverage/src/Report/Xml/Totals.php +++ b/vendor/phpunit/php-code-coverage/src/Report/Xml/Totals.php @@ -1,6 +1,6 @@ * @@ -9,41 +9,47 @@ */ namespace SebastianBergmann\CodeCoverage\Report\Xml; -use SebastianBergmann\CodeCoverage\Util; +use function sprintf; +use DOMElement; +use DOMNode; +use SebastianBergmann\CodeCoverage\Percentage; +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ final class Totals { /** - * @var \DOMNode + * @var DOMNode */ private $container; /** - * @var \DOMElement + * @var DOMElement */ private $linesNode; /** - * @var \DOMElement + * @var DOMElement */ private $methodsNode; /** - * @var \DOMElement + * @var DOMElement */ private $functionsNode; /** - * @var \DOMElement + * @var DOMElement */ private $classesNode; /** - * @var \DOMElement + * @var DOMElement */ private $traitsNode; - public function __construct(\DOMElement $container) + public function __construct(DOMElement $container) { $this->container = $container; $dom = $container->ownerDocument; @@ -80,7 +86,7 @@ final class Totals $container->appendChild($this->traitsNode); } - public function getContainer(): \DOMNode + public function container(): DOMNode { return $this->container; } @@ -94,7 +100,7 @@ final class Totals $this->linesNode->setAttribute('executed', (string) $executed); $this->linesNode->setAttribute( 'percent', - $executable === 0 ? '0' : \sprintf('%01.2F', Util::percent($executed, $executable)) + $executable === 0 ? '0' : sprintf('%01.2F', Percentage::fromFractionAndTotal($executed, $executable)->asFloat()) ); } @@ -104,7 +110,7 @@ final class Totals $this->classesNode->setAttribute('tested', (string) $tested); $this->classesNode->setAttribute( 'percent', - $count === 0 ? '0' : \sprintf('%01.2F', Util::percent($tested, $count)) + $count === 0 ? '0' : sprintf('%01.2F', Percentage::fromFractionAndTotal($tested, $count)->asFloat()) ); } @@ -114,7 +120,7 @@ final class Totals $this->traitsNode->setAttribute('tested', (string) $tested); $this->traitsNode->setAttribute( 'percent', - $count === 0 ? '0' : \sprintf('%01.2F', Util::percent($tested, $count)) + $count === 0 ? '0' : sprintf('%01.2F', Percentage::fromFractionAndTotal($tested, $count)->asFloat()) ); } @@ -124,7 +130,7 @@ final class Totals $this->methodsNode->setAttribute('tested', (string) $tested); $this->methodsNode->setAttribute( 'percent', - $count === 0 ? '0' : \sprintf('%01.2F', Util::percent($tested, $count)) + $count === 0 ? '0' : sprintf('%01.2F', Percentage::fromFractionAndTotal($tested, $count)->asFloat()) ); } @@ -134,7 +140,7 @@ final class Totals $this->functionsNode->setAttribute('tested', (string) $tested); $this->functionsNode->setAttribute( 'percent', - $count === 0 ? '0' : \sprintf('%01.2F', Util::percent($tested, $count)) + $count === 0 ? '0' : sprintf('%01.2F', Percentage::fromFractionAndTotal($tested, $count)->asFloat()) ); } } diff --git a/vendor/phpunit/php-code-coverage/src/Report/Xml/Unit.php b/vendor/phpunit/php-code-coverage/src/Report/Xml/Unit.php index c235dfb6c..d84dc481f 100644 --- a/vendor/phpunit/php-code-coverage/src/Report/Xml/Unit.php +++ b/vendor/phpunit/php-code-coverage/src/Report/Xml/Unit.php @@ -1,6 +1,6 @@ * @@ -9,14 +9,19 @@ */ namespace SebastianBergmann\CodeCoverage\Report\Xml; +use DOMElement; + +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ final class Unit { /** - * @var \DOMElement + * @var DOMElement */ private $contextNode; - public function __construct(\DOMElement $context, string $name) + public function __construct(DOMElement $context, string $name) { $this->contextNode = $context; @@ -35,28 +40,6 @@ final class Unit $this->contextNode->setAttribute('crap', (string) $crap); } - public function setPackage(string $full, string $package, string $sub, string $category): void - { - $node = $this->contextNode->getElementsByTagNameNS( - 'https://schema.phpunit.de/coverage/1.0', - 'package' - )->item(0); - - if (!$node) { - $node = $this->contextNode->appendChild( - $this->contextNode->ownerDocument->createElementNS( - 'https://schema.phpunit.de/coverage/1.0', - 'package' - ) - ); - } - - $node->setAttribute('full', $full); - $node->setAttribute('name', $package); - $node->setAttribute('sub', $sub); - $node->setAttribute('category', $category); - } - public function setNamespace(string $namespace): void { $node = $this->contextNode->getElementsByTagNameNS( diff --git a/vendor/phpunit/php-code-coverage/src/StaticAnalysis/Cache.php b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/Cache.php new file mode 100644 index 000000000..081a6530a --- /dev/null +++ b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/Cache.php @@ -0,0 +1,90 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeCoverage\StaticAnalysis; + +use const DIRECTORY_SEPARATOR; +use function file_get_contents; +use function file_put_contents; +use function filemtime; +use function hash; +use function is_file; +use function serialize; +use function unserialize; +use SebastianBergmann\CodeCoverage\Directory; + +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ +abstract class Cache +{ + /** + * @var string + */ + private $directory; + + public function __construct(string $directory) + { + Directory::create($directory); + + $this->directory = $directory; + } + + protected function has(string $filename, string $key): bool + { + $cacheFile = $this->cacheFile($filename, $key); + + if (!is_file($cacheFile)) { + return false; + } + + if (filemtime($cacheFile) < filemtime($filename)) { + return false; + } + + return true; + } + + /** + * @psalm-param list $allowedClasses + * + * @return mixed + */ + protected function read(string $filename, string $key, array $allowedClasses = []) + { + $options = ['allowed_classes' => false]; + + if (!empty($allowedClasses)) { + $options = ['allowed_classes' => $allowedClasses]; + } + + return unserialize( + file_get_contents( + $this->cacheFile($filename, $key) + ), + $options + ); + } + + /** + * @param mixed $data + */ + protected function write(string $filename, string $key, $data): void + { + file_put_contents( + $this->cacheFile($filename, $key), + serialize($data) + ); + } + + private function cacheFile(string $filename, string $key): string + { + return $this->directory . DIRECTORY_SEPARATOR . hash('sha256', $filename . $key); + } +} diff --git a/vendor/phpunit/php-code-coverage/src/StaticAnalysis/CacheWarmer.php b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/CacheWarmer.php new file mode 100644 index 000000000..93b0dbde8 --- /dev/null +++ b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/CacheWarmer.php @@ -0,0 +1,38 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeCoverage\StaticAnalysis; + +use SebastianBergmann\CodeCoverage\Filter; + +final class CacheWarmer +{ + public function warmCache(string $cacheDirectory, bool $useAnnotationsForIgnoringCode, bool $ignoreDeprecatedCode, Filter $filter): void + { + $coveredFileAnalyser = new CachingCoveredFileAnalyser( + $cacheDirectory, + new ParsingCoveredFileAnalyser( + $useAnnotationsForIgnoringCode, + $ignoreDeprecatedCode + ) + ); + + $uncoveredFileAnalyser = new CachingUncoveredFileAnalyser( + $cacheDirectory, + new ParsingUncoveredFileAnalyser + ); + + foreach ($filter->files() as $file) { + $coveredFileAnalyser->process($file); + + /* @noinspection UnusedFunctionResultInspection */ + $uncoveredFileAnalyser->executableLinesIn($file); + } + } +} diff --git a/vendor/phpunit/php-code-coverage/src/StaticAnalysis/CachingCoveredFileAnalyser.php b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/CachingCoveredFileAnalyser.php new file mode 100644 index 000000000..3fb95bd51 --- /dev/null +++ b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/CachingCoveredFileAnalyser.php @@ -0,0 +1,99 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeCoverage\StaticAnalysis; + +use SebastianBergmann\LinesOfCode\LinesOfCode; + +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ +final class CachingCoveredFileAnalyser extends Cache implements CoveredFileAnalyser +{ + /** + * @var CoveredFileAnalyser + */ + private $coveredFileAnalyser; + + /** + * @var array + */ + private $cache = []; + + public function __construct(string $directory, CoveredFileAnalyser $coveredFileAnalyser) + { + parent::__construct($directory); + + $this->coveredFileAnalyser = $coveredFileAnalyser; + } + + public function classesIn(string $filename): array + { + if (!isset($this->cache[$filename])) { + $this->process($filename); + } + + return $this->cache[$filename]['classesIn']; + } + + public function traitsIn(string $filename): array + { + if (!isset($this->cache[$filename])) { + $this->process($filename); + } + + return $this->cache[$filename]['traitsIn']; + } + + public function functionsIn(string $filename): array + { + if (!isset($this->cache[$filename])) { + $this->process($filename); + } + + return $this->cache[$filename]['functionsIn']; + } + + public function linesOfCodeFor(string $filename): LinesOfCode + { + if (!isset($this->cache[$filename])) { + $this->process($filename); + } + + return $this->cache[$filename]['linesOfCodeFor']; + } + + public function ignoredLinesFor(string $filename): array + { + if (!isset($this->cache[$filename])) { + $this->process($filename); + } + + return $this->cache[$filename]['ignoredLinesFor']; + } + + public function process(string $filename): void + { + if ($this->has($filename, __CLASS__)) { + $this->cache[$filename] = $this->read($filename, __CLASS__, [LinesOfCode::class]); + + return; + } + + $this->cache[$filename] = [ + 'classesIn' => $this->coveredFileAnalyser->classesIn($filename), + 'traitsIn' => $this->coveredFileAnalyser->traitsIn($filename), + 'functionsIn' => $this->coveredFileAnalyser->functionsIn($filename), + 'linesOfCodeFor' => $this->coveredFileAnalyser->linesOfCodeFor($filename), + 'ignoredLinesFor' => $this->coveredFileAnalyser->ignoredLinesFor($filename), + ]; + + $this->write($filename, __CLASS__, $this->cache[$filename]); + } +} diff --git a/vendor/phpunit/php-code-coverage/src/StaticAnalysis/CachingUncoveredFileAnalyser.php b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/CachingUncoveredFileAnalyser.php new file mode 100644 index 000000000..f52bb3518 --- /dev/null +++ b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/CachingUncoveredFileAnalyser.php @@ -0,0 +1,41 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeCoverage\StaticAnalysis; + +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ +final class CachingUncoveredFileAnalyser extends Cache implements UncoveredFileAnalyser +{ + /** + * @var UncoveredFileAnalyser + */ + private $uncoveredFileAnalyser; + + public function __construct(string $directory, UncoveredFileAnalyser $uncoveredFileAnalyser) + { + parent::__construct($directory); + + $this->uncoveredFileAnalyser = $uncoveredFileAnalyser; + } + + public function executableLinesIn(string $filename): array + { + if ($this->has($filename, __METHOD__)) { + return $this->read($filename, __METHOD__); + } + + $data = $this->uncoveredFileAnalyser->executableLinesIn($filename); + + $this->write($filename, __METHOD__, $data); + + return $data; + } +} diff --git a/vendor/phpunit/php-code-coverage/src/StaticAnalysis/CodeUnitFindingVisitor.php b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/CodeUnitFindingVisitor.php new file mode 100644 index 000000000..e79b59e57 --- /dev/null +++ b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/CodeUnitFindingVisitor.php @@ -0,0 +1,293 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeCoverage\StaticAnalysis; + +use function implode; +use function rtrim; +use function trim; +use PhpParser\Node; +use PhpParser\Node\Identifier; +use PhpParser\Node\Name; +use PhpParser\Node\NullableType; +use PhpParser\Node\Stmt\Class_; +use PhpParser\Node\Stmt\ClassMethod; +use PhpParser\Node\Stmt\Function_; +use PhpParser\Node\Stmt\Interface_; +use PhpParser\Node\Stmt\Trait_; +use PhpParser\Node\UnionType; +use PhpParser\NodeTraverser; +use PhpParser\NodeVisitorAbstract; +use SebastianBergmann\Complexity\CyclomaticComplexityCalculatingVisitor; + +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ +final class CodeUnitFindingVisitor extends NodeVisitorAbstract +{ + /** + * @var array + */ + private $classes = []; + + /** + * @var array + */ + private $traits = []; + + /** + * @var array + */ + private $functions = []; + + public function enterNode(Node $node) + { + if ($node instanceof Class_) { + if ($node->isAnonymous()) { + return; + } + + $this->processClass($node); + } + + if ($node instanceof Trait_) { + $this->processTrait($node); + } + + if (!$node instanceof ClassMethod && !$node instanceof Function_) { + return null; + } + + if ($node instanceof ClassMethod) { + $parentNode = $node->getAttribute('parent'); + + if ($parentNode instanceof Class_ && $parentNode->isAnonymous()) { + return; + } + + $this->processMethod($node); + + return; + } + + $this->processFunction($node); + } + + public function classes(): array + { + return $this->classes; + } + + public function traits(): array + { + return $this->traits; + } + + public function functions(): array + { + return $this->functions; + } + + /** + * @psalm-param ClassMethod|Function_ $node + */ + private function cyclomaticComplexity(Node $node): int + { + assert($node instanceof ClassMethod || $node instanceof Function_); + + $nodes = $node->getStmts(); + + if ($nodes === null) { + return 0; + } + + $traverser = new NodeTraverser; + + $cyclomaticComplexityCalculatingVisitor = new CyclomaticComplexityCalculatingVisitor; + + $traverser->addVisitor($cyclomaticComplexityCalculatingVisitor); + + /* @noinspection UnusedFunctionResultInspection */ + $traverser->traverse($nodes); + + return $cyclomaticComplexityCalculatingVisitor->cyclomaticComplexity(); + } + + /** + * @psalm-param ClassMethod|Function_ $node + */ + private function signature(Node $node): string + { + assert($node instanceof ClassMethod || $node instanceof Function_); + + $signature = ($node->returnsByRef() ? '&' : '') . $node->name->toString() . '('; + $parameters = []; + + foreach ($node->getParams() as $parameter) { + assert(isset($parameter->var->name)); + + $parameterAsString = ''; + + if ($parameter->type !== null) { + $parameterAsString = $this->type($parameter->type) . ' '; + } + + $parameterAsString .= '$' . $parameter->var->name; + + /* @todo Handle default values */ + + $parameters[] = $parameterAsString; + } + + $signature .= implode(', ', $parameters) . ')'; + + $returnType = $node->getReturnType(); + + if ($returnType !== null) { + $signature .= ': ' . $this->type($returnType); + } + + return $signature; + } + + /** + * @psalm-param Identifier|Name|NullableType|UnionType $type + */ + private function type(Node $type): string + { + assert($type instanceof Identifier || $type instanceof Name || $type instanceof NullableType || $type instanceof UnionType); + + if ($type instanceof NullableType) { + return '?' . $type->type; + } + + if ($type instanceof UnionType) { + $types = []; + + foreach ($type->types as $_type) { + $types[] = $_type->toString(); + } + + return implode('|', $types); + } + + return $type->toString(); + } + + private function visibility(ClassMethod $node): string + { + if ($node->isPrivate()) { + return 'private'; + } + + if ($node->isProtected()) { + return 'protected'; + } + + return 'public'; + } + + private function processClass(Class_ $node): void + { + $name = $node->name->toString(); + $namespacedName = $node->namespacedName->toString(); + + $this->classes[$namespacedName] = [ + 'name' => $name, + 'namespacedName' => $namespacedName, + 'namespace' => $this->namespace($namespacedName, $name), + 'startLine' => $node->getStartLine(), + 'endLine' => $node->getEndLine(), + 'methods' => [], + ]; + } + + private function processTrait(Trait_ $node): void + { + $name = $node->name->toString(); + $namespacedName = $node->namespacedName->toString(); + + $this->traits[$namespacedName] = [ + 'name' => $name, + 'namespacedName' => $namespacedName, + 'namespace' => $this->namespace($namespacedName, $name), + 'startLine' => $node->getStartLine(), + 'endLine' => $node->getEndLine(), + 'methods' => [], + ]; + } + + private function processMethod(ClassMethod $node): void + { + $parentNode = $node->getAttribute('parent'); + + if ($parentNode instanceof Interface_) { + return; + } + + assert($parentNode instanceof Class_ || $parentNode instanceof Trait_); + assert(isset($parentNode->name)); + assert(isset($parentNode->namespacedName)); + assert($parentNode->namespacedName instanceof Name); + + $parentName = $parentNode->name->toString(); + $parentNamespacedName = $parentNode->namespacedName->toString(); + + if ($parentNode instanceof Class_) { + $storage = &$this->classes; + } else { + $storage = &$this->traits; + } + + if (!isset($storage[$parentNamespacedName])) { + $storage[$parentNamespacedName] = [ + 'name' => $parentName, + 'namespacedName' => $parentNamespacedName, + 'namespace' => $this->namespace($parentNamespacedName, $parentName), + 'startLine' => $parentNode->getStartLine(), + 'endLine' => $parentNode->getEndLine(), + 'methods' => [], + ]; + } + + $storage[$parentNamespacedName]['methods'][$node->name->toString()] = [ + 'methodName' => $node->name->toString(), + 'signature' => $this->signature($node), + 'visibility' => $this->visibility($node), + 'startLine' => $node->getStartLine(), + 'endLine' => $node->getEndLine(), + 'ccn' => $this->cyclomaticComplexity($node), + ]; + } + + private function processFunction(Function_ $node): void + { + assert(isset($node->name)); + assert(isset($node->namespacedName)); + assert($node->namespacedName instanceof Name); + + $name = $node->name->toString(); + $namespacedName = $node->namespacedName->toString(); + + $this->functions[$namespacedName] = [ + 'name' => $name, + 'namespacedName' => $namespacedName, + 'namespace' => $this->namespace($namespacedName, $name), + 'signature' => $this->signature($node), + 'startLine' => $node->getStartLine(), + 'endLine' => $node->getEndLine(), + 'ccn' => $this->cyclomaticComplexity($node), + ]; + } + + private function namespace(string $namespacedName, string $name): string + { + return trim(rtrim($namespacedName, $name), '\\'); + } +} diff --git a/vendor/phpunit/php-code-coverage/src/StaticAnalysis/CoveredFileAnalyser.php b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/CoveredFileAnalyser.php new file mode 100644 index 000000000..d1d5ff482 --- /dev/null +++ b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/CoveredFileAnalyser.php @@ -0,0 +1,28 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeCoverage\StaticAnalysis; + +use SebastianBergmann\LinesOfCode\LinesOfCode; + +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ +interface CoveredFileAnalyser +{ + public function classesIn(string $filename): array; + + public function traitsIn(string $filename): array; + + public function functionsIn(string $filename): array; + + public function linesOfCodeFor(string $filename): LinesOfCode; + + public function ignoredLinesFor(string $filename): array; +} diff --git a/vendor/phpunit/php-code-coverage/src/StaticAnalysis/ExecutableLinesFindingVisitor.php b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/ExecutableLinesFindingVisitor.php new file mode 100644 index 000000000..32205692d --- /dev/null +++ b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/ExecutableLinesFindingVisitor.php @@ -0,0 +1,91 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeCoverage\StaticAnalysis; + +use function array_unique; +use function sort; +use PhpParser\Node; +use PhpParser\Node\Stmt\Break_; +use PhpParser\Node\Stmt\Case_; +use PhpParser\Node\Stmt\Catch_; +use PhpParser\Node\Stmt\Continue_; +use PhpParser\Node\Stmt\Do_; +use PhpParser\Node\Stmt\Echo_; +use PhpParser\Node\Stmt\Else_; +use PhpParser\Node\Stmt\ElseIf_; +use PhpParser\Node\Stmt\Expression; +use PhpParser\Node\Stmt\Finally_; +use PhpParser\Node\Stmt\For_; +use PhpParser\Node\Stmt\Foreach_; +use PhpParser\Node\Stmt\Goto_; +use PhpParser\Node\Stmt\If_; +use PhpParser\Node\Stmt\Return_; +use PhpParser\Node\Stmt\Switch_; +use PhpParser\Node\Stmt\Throw_; +use PhpParser\Node\Stmt\TryCatch; +use PhpParser\Node\Stmt\Unset_; +use PhpParser\Node\Stmt\While_; +use PhpParser\NodeVisitorAbstract; + +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ +final class ExecutableLinesFindingVisitor extends NodeVisitorAbstract +{ + /** + * @psalm-var list + */ + private $executableLines = []; + + public function enterNode(Node $node): void + { + if (!$this->isExecutable($node)) { + return; + } + + $this->executableLines[] = $node->getStartLine(); + } + + /** + * @psalm-return list + */ + public function executableLines(): array + { + $executableLines = array_unique($this->executableLines); + + sort($executableLines); + + return $executableLines; + } + + private function isExecutable(Node $node): bool + { + return $node instanceof Break_ || + $node instanceof Case_ || + $node instanceof Catch_ || + $node instanceof Continue_ || + $node instanceof Do_ || + $node instanceof Echo_ || + $node instanceof ElseIf_ || + $node instanceof Else_ || + $node instanceof Expression || + $node instanceof Finally_ || + $node instanceof Foreach_ || + $node instanceof For_ || + $node instanceof Goto_ || + $node instanceof If_ || + $node instanceof Return_ || + $node instanceof Switch_ || + $node instanceof Throw_ || + $node instanceof TryCatch || + $node instanceof Unset_ || + $node instanceof While_; + } +} diff --git a/vendor/phpunit/php-code-coverage/src/StaticAnalysis/IgnoredLinesFindingVisitor.php b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/IgnoredLinesFindingVisitor.php new file mode 100644 index 000000000..6800b0613 --- /dev/null +++ b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/IgnoredLinesFindingVisitor.php @@ -0,0 +1,113 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeCoverage\StaticAnalysis; + +use function array_merge; +use function range; +use function strpos; +use PhpParser\Node; +use PhpParser\Node\Stmt\Class_; +use PhpParser\Node\Stmt\ClassMethod; +use PhpParser\Node\Stmt\Function_; +use PhpParser\Node\Stmt\Interface_; +use PhpParser\Node\Stmt\Trait_; +use PhpParser\NodeTraverser; +use PhpParser\NodeVisitorAbstract; + +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ +final class IgnoredLinesFindingVisitor extends NodeVisitorAbstract +{ + /** + * @psalm-var list + */ + private $ignoredLines = []; + + /** + * @var bool + */ + private $useAnnotationsForIgnoringCode; + + /** + * @var bool + */ + private $ignoreDeprecated; + + public function __construct(bool $useAnnotationsForIgnoringCode, bool $ignoreDeprecated) + { + $this->useAnnotationsForIgnoringCode = $useAnnotationsForIgnoringCode; + $this->ignoreDeprecated = $ignoreDeprecated; + } + + public function enterNode(Node $node): ?int + { + if (!$node instanceof Class_ && + !$node instanceof Trait_ && + !$node instanceof Interface_ && + !$node instanceof ClassMethod && + !$node instanceof Function_) { + return null; + } + + if ($node instanceof Class_ && $node->isAnonymous()) { + return null; + } + + // Workaround for https://bugs.xdebug.org/view.php?id=1798 + if ($node instanceof Class_ || + $node instanceof Trait_ || + $node instanceof Interface_) { + $this->ignoredLines[] = $node->getStartLine(); + } + + if (!$this->useAnnotationsForIgnoringCode) { + return null; + } + + if ($node instanceof Interface_) { + return null; + } + + $docComment = $node->getDocComment(); + + if ($docComment === null) { + return null; + } + + if (strpos($docComment->getText(), '@codeCoverageIgnore') !== false) { + $this->ignoredLines = array_merge( + $this->ignoredLines, + range($node->getStartLine(), $node->getEndLine()) + ); + } + + if ($this->ignoreDeprecated && strpos($docComment->getText(), '@deprecated') !== false) { + $this->ignoredLines = array_merge( + $this->ignoredLines, + range($node->getStartLine(), $node->getEndLine()) + ); + } + + if ($node instanceof ClassMethod || $node instanceof Function_) { + return NodeTraverser::DONT_TRAVERSE_CHILDREN; + } + + return null; + } + + /** + * @psalm-return list + */ + public function ignoredLines(): array + { + return $this->ignoredLines; + } +} diff --git a/vendor/phpunit/php-code-coverage/src/StaticAnalysis/ParsingCoveredFileAnalyser.php b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/ParsingCoveredFileAnalyser.php new file mode 100644 index 000000000..defefb503 --- /dev/null +++ b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/ParsingCoveredFileAnalyser.php @@ -0,0 +1,226 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeCoverage\StaticAnalysis; + +use function array_unique; +use function assert; +use function file_get_contents; +use function is_array; +use function sprintf; +use function substr_count; +use function token_get_all; +use function trim; +use PhpParser\Error; +use PhpParser\Lexer; +use PhpParser\NodeTraverser; +use PhpParser\NodeVisitor\NameResolver; +use PhpParser\NodeVisitor\ParentConnectingVisitor; +use PhpParser\ParserFactory; +use SebastianBergmann\CodeCoverage\ParserException; +use SebastianBergmann\LinesOfCode\LineCountingVisitor; +use SebastianBergmann\LinesOfCode\LinesOfCode; + +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ +final class ParsingCoveredFileAnalyser implements CoveredFileAnalyser +{ + /** + * @var array + */ + private $classes = []; + + /** + * @var array + */ + private $traits = []; + + /** + * @var array + */ + private $functions = []; + + /** + * @var LinesOfCode[] + */ + private $linesOfCode = []; + + /** + * @var array + */ + private $ignoredLines = []; + + /** + * @var bool + */ + private $useAnnotationsForIgnoringCode; + + /** + * @var bool + */ + private $ignoreDeprecatedCode; + + public function __construct(bool $useAnnotationsForIgnoringCode, bool $ignoreDeprecatedCode) + { + $this->useAnnotationsForIgnoringCode = $useAnnotationsForIgnoringCode; + $this->ignoreDeprecatedCode = $ignoreDeprecatedCode; + } + + public function classesIn(string $filename): array + { + $this->analyse($filename); + + return $this->classes[$filename]; + } + + public function traitsIn(string $filename): array + { + $this->analyse($filename); + + return $this->traits[$filename]; + } + + public function functionsIn(string $filename): array + { + $this->analyse($filename); + + return $this->functions[$filename]; + } + + public function linesOfCodeFor(string $filename): LinesOfCode + { + $this->analyse($filename); + + return $this->linesOfCode[$filename]; + } + + public function ignoredLinesFor(string $filename): array + { + $this->analyse($filename); + + return $this->ignoredLines[$filename]; + } + + /** + * @throws ParserException + */ + private function analyse(string $filename): void + { + if (isset($this->classes[$filename])) { + return; + } + + $source = file_get_contents($filename); + $linesOfCode = substr_count($source, "\n"); + + if ($linesOfCode === 0 && !empty($source)) { + $linesOfCode = 1; + } + + $parser = (new ParserFactory)->create( + ParserFactory::PREFER_PHP7, + new Lexer + ); + + try { + $nodes = $parser->parse($source); + + assert($nodes !== null); + + $traverser = new NodeTraverser; + $codeUnitFindingVisitor = new CodeUnitFindingVisitor; + $lineCountingVisitor = new LineCountingVisitor($linesOfCode); + $ignoredLinesFindingVisitor = new IgnoredLinesFindingVisitor($this->useAnnotationsForIgnoringCode, $this->ignoreDeprecatedCode); + + $traverser->addVisitor(new NameResolver); + $traverser->addVisitor(new ParentConnectingVisitor); + $traverser->addVisitor($codeUnitFindingVisitor); + $traverser->addVisitor($lineCountingVisitor); + $traverser->addVisitor($ignoredLinesFindingVisitor); + + /* @noinspection UnusedFunctionResultInspection */ + $traverser->traverse($nodes); + // @codeCoverageIgnoreStart + } catch (Error $error) { + throw new ParserException( + sprintf( + 'Cannot parse %s: %s', + $filename, + $error->getMessage() + ), + (int) $error->getCode(), + $error + ); + } + // @codeCoverageIgnoreEnd + + $this->classes[$filename] = $codeUnitFindingVisitor->classes(); + $this->traits[$filename] = $codeUnitFindingVisitor->traits(); + $this->functions[$filename] = $codeUnitFindingVisitor->functions(); + $this->linesOfCode[$filename] = $lineCountingVisitor->result(); + $this->ignoredLines[$filename] = []; + + $this->findLinesIgnoredByLineBasedAnnotations($filename, $source, $this->useAnnotationsForIgnoringCode); + + $this->ignoredLines[$filename] = array_unique( + array_merge( + $this->ignoredLines[$filename], + $ignoredLinesFindingVisitor->ignoredLines() + ) + ); + + sort($this->ignoredLines[$filename]); + } + + private function findLinesIgnoredByLineBasedAnnotations(string $filename, string $source, bool $useAnnotationsForIgnoringCode): void + { + $ignore = false; + $stop = false; + + foreach (token_get_all($source) as $token) { + if (!is_array($token)) { + continue; + } + + switch ($token[0]) { + case T_COMMENT: + case T_DOC_COMMENT: + if (!$useAnnotationsForIgnoringCode) { + break; + } + + $comment = trim($token[1]); + + if ($comment === '// @codeCoverageIgnore' || + $comment === '//@codeCoverageIgnore') { + $ignore = true; + $stop = true; + } elseif ($comment === '// @codeCoverageIgnoreStart' || + $comment === '//@codeCoverageIgnoreStart') { + $ignore = true; + } elseif ($comment === '// @codeCoverageIgnoreEnd' || + $comment === '//@codeCoverageIgnoreEnd') { + $stop = true; + } + + break; + } + + if ($ignore) { + $this->ignoredLines[$filename][] = $token[2]; + + if ($stop) { + $ignore = false; + $stop = false; + } + } + } + } +} diff --git a/vendor/phpunit/php-code-coverage/src/StaticAnalysis/ParsingUncoveredFileAnalyser.php b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/ParsingUncoveredFileAnalyser.php new file mode 100644 index 000000000..0ee7055d6 --- /dev/null +++ b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/ParsingUncoveredFileAnalyser.php @@ -0,0 +1,51 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeCoverage\StaticAnalysis; + +use PhpParser\Error; +use PhpParser\Lexer; +use PhpParser\NodeTraverser; +use PhpParser\ParserFactory; + +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ +final class ParsingUncoveredFileAnalyser implements UncoveredFileAnalyser +{ + public function executableLinesIn(string $filename): array + { + $parser = (new ParserFactory)->create( + ParserFactory::PREFER_PHP7, + new Lexer + ); + + try { + $nodes = $parser->parse(file_get_contents($filename)); + + assert($nodes !== null); + + $traverser = new NodeTraverser; + $visitor = new ExecutableLinesFindingVisitor; + + $traverser->addVisitor($visitor); + + /* @noinspection UnusedFunctionResultInspection */ + $traverser->traverse($nodes); + + return $visitor->executableLines(); + + // @codeCoverageIgnoreStart + } catch (Error $error) { + } + // @codeCoverageIgnoreEnd + + return []; + } +} diff --git a/vendor/phpunit/php-code-coverage/src/StaticAnalysis/UncoveredFileAnalyser.php b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/UncoveredFileAnalyser.php new file mode 100644 index 000000000..e89f2a954 --- /dev/null +++ b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/UncoveredFileAnalyser.php @@ -0,0 +1,18 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeCoverage\StaticAnalysis; + +/** + * @internal This class is not covered by the backward compatibility promise for phpunit/php-code-coverage + */ +interface UncoveredFileAnalyser +{ + public function executableLinesIn(string $filename): array; +} diff --git a/vendor/phpunit/php-code-coverage/src/Util.php b/vendor/phpunit/php-code-coverage/src/Util.php deleted file mode 100644 index ee8894c14..000000000 --- a/vendor/phpunit/php-code-coverage/src/Util.php +++ /dev/null @@ -1,40 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\CodeCoverage; - -/** - * Utility methods. - */ -final class Util -{ - /** - * @return float|int|string - */ - public static function percent(float $a, float $b, bool $asString = false, bool $fixedWidth = false) - { - if ($asString && $b == 0) { - return ''; - } - - $percent = 100; - - if ($b > 0) { - $percent = ($a / $b) * 100; - } - - if ($asString) { - $format = $fixedWidth ? '%6.2F%%' : '%01.2F%%'; - - return \sprintf($format, $percent); - } - - return $percent; - } -} diff --git a/vendor/phpunit/php-code-coverage/src/Version.php b/vendor/phpunit/php-code-coverage/src/Version.php index 1c193fe04..9a2dd3297 100644 --- a/vendor/phpunit/php-code-coverage/src/Version.php +++ b/vendor/phpunit/php-code-coverage/src/Version.php @@ -1,6 +1,6 @@ * @@ -9,6 +9,7 @@ */ namespace SebastianBergmann\CodeCoverage; +use function dirname; use SebastianBergmann\Version as VersionId; final class Version @@ -21,8 +22,7 @@ final class Version public static function id(): string { if (self::$version === null) { - $version = new VersionId('7.0.14', \dirname(__DIR__)); - self::$version = $version->getVersion(); + self::$version = (new VersionId('9.2.6', dirname(__DIR__)))->getVersion(); } return self::$version; diff --git a/vendor/phpunit/php-code-coverage/tests/TestCase.php b/vendor/phpunit/php-code-coverage/tests/TestCase.php deleted file mode 100644 index 6a9824e88..000000000 --- a/vendor/phpunit/php-code-coverage/tests/TestCase.php +++ /dev/null @@ -1,395 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\CodeCoverage; - -use SebastianBergmann\CodeCoverage\Driver\Driver; -use SebastianBergmann\CodeCoverage\Report\Xml\Coverage; - -abstract class TestCase extends \PHPUnit\Framework\TestCase -{ - protected static $TEST_TMP_PATH; - - public static function setUpBeforeClass(): void - { - self::$TEST_TMP_PATH = TEST_FILES_PATH . 'tmp'; - } - - protected function getXdebugDataForBankAccount() - { - return [ - [ - TEST_FILES_PATH . 'BankAccount.php' => [ - 8 => 1, - 9 => -2, - 13 => -1, - 14 => -1, - 15 => -1, - 16 => -1, - 18 => -1, - 22 => -1, - 24 => -1, - 25 => -2, - 29 => -1, - 31 => -1, - 32 => -2 - ] - ], - [ - TEST_FILES_PATH . 'BankAccount.php' => [ - 8 => 1, - 13 => 1, - 16 => 1, - 29 => 1, - ] - ], - [ - TEST_FILES_PATH . 'BankAccount.php' => [ - 8 => 1, - 13 => 1, - 16 => 1, - 22 => 1, - ] - ], - [ - TEST_FILES_PATH . 'BankAccount.php' => [ - 8 => 1, - 13 => 1, - 14 => 1, - 15 => 1, - 18 => 1, - 22 => 1, - 24 => 1, - 29 => 1, - 31 => 1, - ] - ] - ]; - } - - protected function getCoverageForBankAccount(): CodeCoverage - { - $data = $this->getXdebugDataForBankAccount(); - - $stub = $this->createMock(Driver::class); - - $stub->expects($this->any()) - ->method('stop') - ->will($this->onConsecutiveCalls( - $data[0], - $data[1], - $data[2], - $data[3] - )); - - $filter = new Filter; - $filter->addFileToWhitelist(TEST_FILES_PATH . 'BankAccount.php'); - - $coverage = new CodeCoverage($stub, $filter); - - $coverage->start( - new \BankAccountTest('testBalanceIsInitiallyZero'), - true - ); - - $coverage->stop( - true, - [TEST_FILES_PATH . 'BankAccount.php' => range(6, 9)] - ); - - $coverage->start( - new \BankAccountTest('testBalanceCannotBecomeNegative') - ); - - $coverage->stop( - true, - [TEST_FILES_PATH . 'BankAccount.php' => range(27, 32)] - ); - - $coverage->start( - new \BankAccountTest('testBalanceCannotBecomeNegative2') - ); - - $coverage->stop( - true, - [TEST_FILES_PATH . 'BankAccount.php' => range(20, 25)] - ); - - $coverage->start( - new \BankAccountTest('testDepositWithdrawMoney') - ); - - $coverage->stop( - true, - [ - TEST_FILES_PATH . 'BankAccount.php' => array_merge( - range(6, 9), - range(20, 25), - range(27, 32) - ) - ] - ); - - return $coverage; - } - - protected function getCoverageForBankAccountForFirstTwoTests(): CodeCoverage - { - $data = $this->getXdebugDataForBankAccount(); - - $stub = $this->createMock(Driver::class); - - $stub->expects($this->any()) - ->method('stop') - ->will($this->onConsecutiveCalls( - $data[0], - $data[1] - )); - - $filter = new Filter; - $filter->addFileToWhitelist(TEST_FILES_PATH . 'BankAccount.php'); - - $coverage = new CodeCoverage($stub, $filter); - - $coverage->start( - new \BankAccountTest('testBalanceIsInitiallyZero'), - true - ); - - $coverage->stop( - true, - [TEST_FILES_PATH . 'BankAccount.php' => range(6, 9)] - ); - - $coverage->start( - new \BankAccountTest('testBalanceCannotBecomeNegative') - ); - - $coverage->stop( - true, - [TEST_FILES_PATH . 'BankAccount.php' => range(27, 32)] - ); - - return $coverage; - } - - protected function getCoverageForBankAccountForLastTwoTests() - { - $data = $this->getXdebugDataForBankAccount(); - - $stub = $this->createMock(Driver::class); - - $stub->expects($this->any()) - ->method('stop') - ->will($this->onConsecutiveCalls( - $data[2], - $data[3] - )); - - $filter = new Filter; - $filter->addFileToWhitelist(TEST_FILES_PATH . 'BankAccount.php'); - - $coverage = new CodeCoverage($stub, $filter); - - $coverage->start( - new \BankAccountTest('testBalanceCannotBecomeNegative2') - ); - - $coverage->stop( - true, - [TEST_FILES_PATH . 'BankAccount.php' => range(20, 25)] - ); - - $coverage->start( - new \BankAccountTest('testDepositWithdrawMoney') - ); - - $coverage->stop( - true, - [ - TEST_FILES_PATH . 'BankAccount.php' => array_merge( - range(6, 9), - range(20, 25), - range(27, 32) - ) - ] - ); - - return $coverage; - } - - protected function getExpectedDataArrayForBankAccount(): array - { - return [ - TEST_FILES_PATH . 'BankAccount.php' => [ - 8 => [ - 0 => 'BankAccountTest::testBalanceIsInitiallyZero', - 1 => 'BankAccountTest::testDepositWithdrawMoney' - ], - 9 => null, - 13 => [], - 14 => [], - 15 => [], - 16 => [], - 18 => [], - 22 => [ - 0 => 'BankAccountTest::testBalanceCannotBecomeNegative2', - 1 => 'BankAccountTest::testDepositWithdrawMoney' - ], - 24 => [ - 0 => 'BankAccountTest::testDepositWithdrawMoney', - ], - 25 => null, - 29 => [ - 0 => 'BankAccountTest::testBalanceCannotBecomeNegative', - 1 => 'BankAccountTest::testDepositWithdrawMoney' - ], - 31 => [ - 0 => 'BankAccountTest::testDepositWithdrawMoney' - ], - 32 => null - ] - ]; - } - - protected function getExpectedDataArrayForBankAccountInReverseOrder(): array - { - return [ - TEST_FILES_PATH . 'BankAccount.php' => [ - 8 => [ - 0 => 'BankAccountTest::testDepositWithdrawMoney', - 1 => 'BankAccountTest::testBalanceIsInitiallyZero' - ], - 9 => null, - 13 => [], - 14 => [], - 15 => [], - 16 => [], - 18 => [], - 22 => [ - 0 => 'BankAccountTest::testBalanceCannotBecomeNegative2', - 1 => 'BankAccountTest::testDepositWithdrawMoney' - ], - 24 => [ - 0 => 'BankAccountTest::testDepositWithdrawMoney', - ], - 25 => null, - 29 => [ - 0 => 'BankAccountTest::testDepositWithdrawMoney', - 1 => 'BankAccountTest::testBalanceCannotBecomeNegative' - ], - 31 => [ - 0 => 'BankAccountTest::testDepositWithdrawMoney' - ], - 32 => null - ] - ]; - } - - protected function getCoverageForFileWithIgnoredLines(): CodeCoverage - { - $filter = new Filter; - $filter->addFileToWhitelist(TEST_FILES_PATH . 'source_with_ignore.php'); - - $coverage = new CodeCoverage( - $this->setUpXdebugStubForFileWithIgnoredLines(), - $filter - ); - - $coverage->start('FileWithIgnoredLines', true); - $coverage->stop(); - - return $coverage; - } - - protected function setUpXdebugStubForFileWithIgnoredLines(): Driver - { - $stub = $this->createMock(Driver::class); - - $stub->expects($this->any()) - ->method('stop') - ->will($this->returnValue( - [ - TEST_FILES_PATH . 'source_with_ignore.php' => [ - 2 => 1, - 4 => -1, - 6 => -1, - 7 => 1 - ] - ] - )); - - return $stub; - } - - protected function getCoverageForClassWithAnonymousFunction(): CodeCoverage - { - $filter = new Filter; - $filter->addFileToWhitelist(TEST_FILES_PATH . 'source_with_class_and_anonymous_function.php'); - - $coverage = new CodeCoverage( - $this->setUpXdebugStubForClassWithAnonymousFunction(), - $filter - ); - - $coverage->start('ClassWithAnonymousFunction', true); - $coverage->stop(); - - return $coverage; - } - - protected function setUpXdebugStubForClassWithAnonymousFunction(): Driver - { - $stub = $this->createMock(Driver::class); - - $stub->expects($this->any()) - ->method('stop') - ->will($this->returnValue( - [ - TEST_FILES_PATH . 'source_with_class_and_anonymous_function.php' => [ - 7 => 1, - 9 => 1, - 10 => -1, - 11 => 1, - 12 => 1, - 13 => 1, - 14 => 1, - 17 => 1, - 18 => 1 - ] - ] - )); - - return $stub; - } - - protected function getCoverageForCrashParsing(): CodeCoverage - { - $filter = new Filter; - $filter->addFileToWhitelist(TEST_FILES_PATH . 'Crash.php'); - - // This is a file with invalid syntax, so it isn't executed. - return new CodeCoverage( - $this->setUpXdebugStubForCrashParsing(), - $filter - ); - } - - protected function setUpXdebugStubForCrashParsing(): Driver - { - $stub = $this->createMock(Driver::class); - - $stub->expects($this->any()) - ->method('stop') - ->will($this->returnValue([])); - return $stub; - } - -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/BankAccount-clover.xml b/vendor/phpunit/php-code-coverage/tests/_files/BankAccount-clover.xml deleted file mode 100644 index 2f11d819c..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/BankAccount-clover.xml +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/BankAccount-crap4j.xml b/vendor/phpunit/php-code-coverage/tests/_files/BankAccount-crap4j.xml deleted file mode 100644 index f2f56eabb..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/BankAccount-crap4j.xml +++ /dev/null @@ -1,59 +0,0 @@ - - - BankAccount - %s - - Method Crap Stats - 4 - 0 - 0 - 9 - 0 - - - - global - BankAccount - getBalance - getBalance() - getBalance() - 1 - 1 - 100 - 0 - - - global - BankAccount - setBalance - setBalance($balance) - setBalance($balance) - 6 - 2 - 0 - 0 - - - global - BankAccount - depositMoney - depositMoney($balance) - depositMoney($balance) - 1 - 1 - 100 - 0 - - - global - BankAccount - withdrawMoney - withdrawMoney($balance) - withdrawMoney($balance) - 1 - 1 - 100 - 0 - - - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/BankAccount-text.txt b/vendor/phpunit/php-code-coverage/tests/_files/BankAccount-text.txt deleted file mode 100644 index 892d83464..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/BankAccount-text.txt +++ /dev/null @@ -1,12 +0,0 @@ - - -Code Coverage Report: - %s - - Summary: - Classes: 0.00% (0/1) - Methods: 75.00% (3/4) - Lines: 50.00% (5/10) - -BankAccount - Methods: 75.00% ( 3/ 4) Lines: 50.00% ( 5/ 10) diff --git a/vendor/phpunit/php-code-coverage/tests/_files/BankAccount.php b/vendor/phpunit/php-code-coverage/tests/_files/BankAccount.php deleted file mode 100644 index 4238c1559..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/BankAccount.php +++ /dev/null @@ -1,33 +0,0 @@ -balance; - } - - protected function setBalance($balance) - { - if ($balance >= 0) { - $this->balance = $balance; - } else { - throw new RuntimeException; - } - } - - public function depositMoney($balance) - { - $this->setBalance($this->getBalance() + $balance); - - return $this->getBalance(); - } - - public function withdrawMoney($balance) - { - $this->setBalance($this->getBalance() - $balance); - - return $this->getBalance(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/BankAccountTest.php b/vendor/phpunit/php-code-coverage/tests/_files/BankAccountTest.php deleted file mode 100644 index 803c892ac..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/BankAccountTest.php +++ /dev/null @@ -1,66 +0,0 @@ -ba = new BankAccount; - } - - /** - * @covers BankAccount::getBalance - */ - public function testBalanceIsInitiallyZero() - { - $this->assertEquals(0, $this->ba->getBalance()); - } - - /** - * @covers BankAccount::withdrawMoney - */ - public function testBalanceCannotBecomeNegative() - { - try { - $this->ba->withdrawMoney(1); - } catch (RuntimeException $e) { - $this->assertEquals(0, $this->ba->getBalance()); - - return; - } - - $this->fail(); - } - - /** - * @covers BankAccount::depositMoney - */ - public function testBalanceCannotBecomeNegative2() - { - try { - $this->ba->depositMoney(-1); - } catch (RuntimeException $e) { - $this->assertEquals(0, $this->ba->getBalance()); - - return; - } - - $this->fail(); - } - - /** - * @covers BankAccount::getBalance - * @covers BankAccount::depositMoney - * @covers BankAccount::withdrawMoney - */ - public function testDepositWithdrawMoney() - { - $this->assertEquals(0, $this->ba->getBalance()); - $this->ba->depositMoney(1); - $this->assertEquals(1, $this->ba->getBalance()); - $this->ba->withdrawMoney(1); - $this->assertEquals(0, $this->ba->getBalance()); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageClassExtendedTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageClassExtendedTest.php deleted file mode 100644 index e6d496e4a..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageClassExtendedTest.php +++ /dev/null @@ -1,14 +0,0 @@ - - */ - public function testSomething() - { - $o = new CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageClassTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageClassTest.php deleted file mode 100644 index baa04d8c7..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageClassTest.php +++ /dev/null @@ -1,14 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageFunctionParenthesesTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageFunctionParenthesesTest.php deleted file mode 100644 index 560e38175..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageFunctionParenthesesTest.php +++ /dev/null @@ -1,13 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodParenthesesTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodParenthesesTest.php deleted file mode 100644 index b624ed95a..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodParenthesesTest.php +++ /dev/null @@ -1,14 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodParenthesesWhitespaceTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodParenthesesWhitespaceTest.php deleted file mode 100644 index 20d2e751a..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodParenthesesWhitespaceTest.php +++ /dev/null @@ -1,14 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodTest.php deleted file mode 100644 index fb7a88277..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodTest.php +++ /dev/null @@ -1,14 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageNoneTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageNoneTest.php deleted file mode 100644 index d8d9cae67..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageNoneTest.php +++ /dev/null @@ -1,11 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageNotPrivateTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageNotPrivateTest.php deleted file mode 100644 index e98efd853..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageNotPrivateTest.php +++ /dev/null @@ -1,14 +0,0 @@ - - */ - public function testSomething() - { - $o = new CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageNotProtectedTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageNotProtectedTest.php deleted file mode 100644 index 7c9c488cf..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageNotProtectedTest.php +++ /dev/null @@ -1,14 +0,0 @@ - - */ - public function testSomething() - { - $o = new CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageNotPublicTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageNotPublicTest.php deleted file mode 100644 index 202724a05..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageNotPublicTest.php +++ /dev/null @@ -1,14 +0,0 @@ - - */ - public function testSomething() - { - $o = new CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageNothingTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageNothingTest.php deleted file mode 100644 index 4e1c0d0f5..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageNothingTest.php +++ /dev/null @@ -1,15 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoveragePrivateTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoveragePrivateTest.php deleted file mode 100644 index 849c3480d..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoveragePrivateTest.php +++ /dev/null @@ -1,14 +0,0 @@ - - */ - public function testSomething() - { - $o = new CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageProtectedTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageProtectedTest.php deleted file mode 100644 index 6ae3544ca..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageProtectedTest.php +++ /dev/null @@ -1,14 +0,0 @@ - - */ - public function testSomething() - { - $o = new CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoveragePublicTest.php b/vendor/phpunit/php-code-coverage/tests/_files/CoveragePublicTest.php deleted file mode 100644 index d977090cc..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoveragePublicTest.php +++ /dev/null @@ -1,14 +0,0 @@ - - */ - public function testSomething() - { - $o = new CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoverageTwoDefaultClassAnnotations.php b/vendor/phpunit/php-code-coverage/tests/_files/CoverageTwoDefaultClassAnnotations.php deleted file mode 100644 index 06949cb7e..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoverageTwoDefaultClassAnnotations.php +++ /dev/null @@ -1,17 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } - -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoveredClass.php b/vendor/phpunit/php-code-coverage/tests/_files/CoveredClass.php deleted file mode 100644 index f382ce99b..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoveredClass.php +++ /dev/null @@ -1,36 +0,0 @@ -privateMethod(); - } - - public function publicMethod() - { - $this->protectedMethod(); - } -} - -class CoveredClass extends CoveredParentClass -{ - private function privateMethod() - { - } - - protected function protectedMethod() - { - parent::protectedMethod(); - $this->privateMethod(); - } - - public function publicMethod() - { - parent::publicMethod(); - $this->protectedMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/CoveredFunction.php b/vendor/phpunit/php-code-coverage/tests/_files/CoveredFunction.php deleted file mode 100644 index 9989eb02e..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/CoveredFunction.php +++ /dev/null @@ -1,4 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageClassTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageClassTest.php deleted file mode 100644 index 2b91f1fdd..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageClassTest.php +++ /dev/null @@ -1,14 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageCoversClassPublicTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageCoversClassPublicTest.php deleted file mode 100644 index d3bc1a93b..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageCoversClassPublicTest.php +++ /dev/null @@ -1,17 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageCoversClassTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageCoversClassTest.php deleted file mode 100644 index 67752dd9c..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageCoversClassTest.php +++ /dev/null @@ -1,22 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageMethodTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageMethodTest.php deleted file mode 100644 index f83ae5f0e..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageMethodTest.php +++ /dev/null @@ -1,14 +0,0 @@ -publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotPrivateTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotPrivateTest.php deleted file mode 100644 index b4983c747..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotPrivateTest.php +++ /dev/null @@ -1,14 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotProtectedTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotProtectedTest.php deleted file mode 100644 index ceb7b35bf..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotProtectedTest.php +++ /dev/null @@ -1,14 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotPublicTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotPublicTest.php deleted file mode 100644 index 60aff7a01..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageNotPublicTest.php +++ /dev/null @@ -1,14 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveragePrivateTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveragePrivateTest.php deleted file mode 100644 index d5eb77ec0..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveragePrivateTest.php +++ /dev/null @@ -1,14 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageProtectedTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageProtectedTest.php deleted file mode 100644 index 6a6eaca47..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoverageProtectedTest.php +++ /dev/null @@ -1,14 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveragePublicTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveragePublicTest.php deleted file mode 100644 index f32803ecf..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveragePublicTest.php +++ /dev/null @@ -1,14 +0,0 @@ - - */ - public function testSomething() - { - $o = new Foo\CoveredClass; - $o->publicMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveredClass.php b/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveredClass.php deleted file mode 100644 index 5bd0ddfb2..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveredClass.php +++ /dev/null @@ -1,38 +0,0 @@ -privateMethod(); - } - - public function publicMethod() - { - $this->protectedMethod(); - } -} - -class CoveredClass extends CoveredParentClass -{ - private function privateMethod() - { - } - - protected function protectedMethod() - { - parent::protectedMethod(); - $this->privateMethod(); - } - - public function publicMethod() - { - parent::publicMethod(); - $this->protectedMethod(); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/NotExistingCoveredElementTest.php b/vendor/phpunit/php-code-coverage/tests/_files/NotExistingCoveredElementTest.php deleted file mode 100644 index 0836a8c84..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/NotExistingCoveredElementTest.php +++ /dev/null @@ -1,26 +0,0 @@ - - */ - public function testThree() - { - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForBankAccount/BankAccount.php.html b/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForBankAccount/BankAccount.php.html deleted file mode 100644 index 467602ee9..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForBankAccount/BankAccount.php.html +++ /dev/null @@ -1,249 +0,0 @@ - - - - - Code Coverage for %s%eBankAccount.php - - - - - - - -
-
-
-
- -
-
-
-
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
 
Code Coverage
 
Classes and Traits
Functions and Methods
Lines
Total
-
- 0.00% covered (danger) -
-
-
0.00%
0 / 1
-
- 75.00% covered (warning) -
-
-
75.00%
3 / 4
CRAP
-
- 50.00% covered (danger) -
-
-
50.00%
5 / 10
BankAccount
-
- 0.00% covered (danger) -
-
-
0.00%
0 / 1
-
- 75.00% covered (warning) -
-
-
75.00%
3 / 4
8.12
-
- 50.00% covered (danger) -
-
-
50.00%
5 / 10
 getBalance
-
- 100.00% covered (success) -
-
-
100.00%
1 / 1
1
-
- 100.00% covered (success) -
-
-
100.00%
1 / 1
 setBalance
-
- 0.00% covered (danger) -
-
-
0.00%
0 / 1
6
-
- 0.00% covered (danger) -
-
-
0.00%
0 / 5
 depositMoney
-
- 100.00% covered (success) -
-
-
100.00%
1 / 1
1
-
- 100.00% covered (success) -
-
-
100.00%
2 / 2
 withdrawMoney
-
- 100.00% covered (success) -
-
-
100.00%
1 / 1
1
-
- 100.00% covered (success) -
-
-
100.00%
2 / 2
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
<?php
class BankAccount
{
    protected $balance = 0;
    public function getBalance()
    {
        return $this->balance;
    }
    protected function setBalance($balance)
    {
        if ($balance >= 0) {
            $this->balance = $balance;
        } else {
            throw new RuntimeException;
        }
    }
    public function depositMoney($balance)
    {
        $this->setBalance($this->getBalance() + $balance);
        return $this->getBalance();
    }
    public function withdrawMoney($balance)
    {
        $this->setBalance($this->getBalance() - $balance);
        return $this->getBalance();
    }
}
- -
- - - - - - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForBankAccount/dashboard.html b/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForBankAccount/dashboard.html deleted file mode 100644 index e47929fbd..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForBankAccount/dashboard.html +++ /dev/null @@ -1,287 +0,0 @@ - - - - - Dashboard for %s - - - - - - - -
-
-
-
- -
-
-
-
-
-
-
-

Classes

-
-
-
-
-

Coverage Distribution

-
- -
-
-
-

Complexity

-
- -
-
-
-
-
-

Insufficient Coverage

-
- - - - - - - - - - - -
ClassCoverage
BankAccount50%
-
-
-
-

Project Risks

-
- - - - - - - - - - - -
ClassCRAP
BankAccount8
-
-
-
-
-
-

Methods

-
-
-
-
-

Coverage Distribution

-
- -
-
-
-

Complexity

-
- -
-
-
-
-
-

Insufficient Coverage

-
- - - - - - - - - - - -
MethodCoverage
setBalance0%
-
-
-
-

Project Risks

-
- - - - - - - - - - - -
MethodCRAP
setBalance6
-
-
-
- -
- - - - - - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForBankAccount/index.html b/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForBankAccount/index.html deleted file mode 100644 index e0c9ed9d9..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForBankAccount/index.html +++ /dev/null @@ -1,118 +0,0 @@ - - - - - Code Coverage for %s - - - - - - - -
-
-
-
- -
-
-
-
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
 
Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
-
- 50.00% covered (danger) -
-
-
50.00%
5 / 10
-
- 75.00% covered (warning) -
-
-
75.00%
3 / 4
-
- 0.00% covered (danger) -
-
-
0.00%
0 / 1
BankAccount.php
-
- 50.00% covered (danger) -
-
-
50.00%
5 / 10
-
- 75.00% covered (warning) -
-
-
75.00%
3 / 4
-
- 0.00% covered (danger) -
-
-
0.00%
0 / 1
-
-
-
-

Legend

-

- Low: 0% to 50% - Medium: 50% to 90% - High: 90% to 100% -

-

- Generated by php-code-coverage %s using %s at %s. -

-
-
- - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForClassWithAnonymousFunction/dashboard.html b/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForClassWithAnonymousFunction/dashboard.html deleted file mode 100644 index 8b27809c7..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForClassWithAnonymousFunction/dashboard.html +++ /dev/null @@ -1,285 +0,0 @@ - - - - - Dashboard for %s - - - - - - - -
-
-
-
- -
-
-
-
-
-
-
-

Classes

-
-
-
-
-

Coverage Distribution

-
- -
-
-
-

Complexity

-
- -
-
-
-
-
-

Insufficient Coverage

-
- - - - - - - - - - - -
ClassCoverage
CoveredClassWithAnonymousFunctionInStaticMethod87%
-
-
-
-

Project Risks

-
- - - - - - - - - - -
ClassCRAP
-
-
-
-
-
-

Methods

-
-
-
-
-

Coverage Distribution

-
- -
-
-
-

Complexity

-
- -
-
-
-
-
-

Insufficient Coverage

-
- - - - - - - - - - - -
MethodCoverage
runAnonymous87%
-
-
-
-

Project Risks

-
- - - - - - - - - - -
MethodCRAP
-
-
-
- -
- - - - - - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForClassWithAnonymousFunction/index.html b/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForClassWithAnonymousFunction/index.html deleted file mode 100644 index 68318d055..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForClassWithAnonymousFunction/index.html +++ /dev/null @@ -1,118 +0,0 @@ - - - - - Code Coverage for %s - - - - - - - -
-
-
-
- -
-
-
-
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
 
Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
-
- 87.50% covered (warning) -
-
-
87.50%
7 / 8
-
- 0.00% covered (danger) -
-
-
0.00%
0 / 1
-
- 0.00% covered (danger) -
-
-
0.00%
0 / 1
source_with_class_and_anonymous_function.php
-
- 87.50% covered (warning) -
-
-
87.50%
7 / 8
-
- 0.00% covered (danger) -
-
-
0.00%
0 / 1
-
- 0.00% covered (danger) -
-
-
0.00%
0 / 1
-
-
-
-

Legend

-

- Low: 0% to 50% - Medium: 50% to 90% - High: 90% to 100% -

-

- Generated by php-code-coverage %s using %s at %s. -

-
-
- - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForClassWithAnonymousFunction/source_with_class_and_anonymous_function.php.html b/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForClassWithAnonymousFunction/source_with_class_and_anonymous_function.php.html deleted file mode 100644 index c261c6e1e..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForClassWithAnonymousFunction/source_with_class_and_anonymous_function.php.html +++ /dev/null @@ -1,172 +0,0 @@ - - - - - Code Coverage for %s%esource_with_class_and_anonymous_function.php - - - - - - - -
-
-
-
- -
-
-
-
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
 
Code Coverage
 
Classes and Traits
Functions and Methods
Lines
Total
-
- 0.00% covered (danger) -
-
-
0.00%
0 / 1
-
- 0.00% covered (danger) -
-
-
0.00%
0 / 1
CRAP
-
- 87.50% covered (warning) -
-
-
87.50%
7 / 8
CoveredClassWithAnonymousFunctionInStaticMethod
-
- 0.00% covered (danger) -
-
-
0.00%
0 / 1
-
- 0.00% covered (danger) -
-
-
0.00%
0 / 1
1.00
-
- 87.50% covered (warning) -
-
-
87.50%
7 / 8
 runAnonymous
-
- 0.00% covered (danger) -
-
-
0.00%
0 / 1
1.00
-
- 87.50% covered (warning) -
-
-
87.50%
7 / 8
-
- - - - - - - - - - - - - - - - - - - - - - - -
<?php
class CoveredClassWithAnonymousFunctionInStaticMethod
{
    public static function runAnonymous()
    {
        $filter = ['abc124', 'abc123', '123'];
        array_walk(
            $filter,
            function (&$val, $key) {
                $val = preg_replace('|[^0-9]|', '', $val);
            }
        );
        // Should be covered
        $extravar = true;
    }
}
- -
- - - - - - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForFileWithIgnoredLines/index.html b/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForFileWithIgnoredLines/index.html deleted file mode 100644 index 7d4cfffce..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForFileWithIgnoredLines/index.html +++ /dev/null @@ -1,108 +0,0 @@ - - - - - Code Coverage for %s - - - - - - - -
-
-
-
- -
-
-
-
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
 
Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
-
- 50.00% covered (danger) -
-
-
50.00%
1 / 2
-
- 100.00% covered (success) -
-
-
100.00%
1 / 1
n/a
0 / 0
source_with_ignore.php
-
- 50.00% covered (danger) -
-
-
50.00%
1 / 2
-
- 100.00% covered (success) -
-
-
100.00%
1 / 1
n/a
0 / 0
-
-
-
-

Legend

-

- Low: 0% to 50% - Medium: 50% to 90% - High: 90% to 100% -

-

- Generated by php-code-coverage %s using %s at %s. -

-
-
- - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForFileWithIgnoredLines/source_with_ignore.php.html b/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForFileWithIgnoredLines/source_with_ignore.php.html deleted file mode 100644 index a18a5aa56..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/Report/HTML/CoverageForFileWithIgnoredLines/source_with_ignore.php.html +++ /dev/null @@ -1,196 +0,0 @@ - - - - - Code Coverage for %s%esource_with_ignore.php - - - - - - - -
-
-
-
- -
-
-
-
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
 
Code Coverage
 
Classes and Traits
Functions and Methods
Lines
Total
n/a
0 / 0
-
- 100.00% covered (success) -
-
-
100.00%
1 / 1
CRAP
-
- 50.00% covered (danger) -
-
-
50.00%
1 / 2
baz
n/a
0 / 0
1
n/a
0 / 0
Foo
n/a
0 / 0
n/a
0 / 0
1
n/a
0 / 0
 bar
n/a
0 / 0
1
n/a
0 / 0
Bar
n/a
0 / 0
n/a
0 / 0
1
n/a
0 / 0
 foo
n/a
0 / 0
1
n/a
0 / 0
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
<?php
if ($neverHappens) {
    // @codeCoverageIgnoreStart
    print '*';
    // @codeCoverageIgnoreEnd
}
/**
 * @codeCoverageIgnore
 */
class Foo
{
    public function bar()
    {
    }
}
class Bar
{
    /**
     * @codeCoverageIgnore
     */
    public function foo()
    {
    }
}
function baz()
{
    print '*'; // @codeCoverageIgnore
}
interface Bor
{
    public function foo();
}
- -
- - - - - - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForBankAccount/BankAccount.php.xml b/vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForBankAccount/BankAccount.php.xml deleted file mode 100644 index 238548b08..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForBankAccount/BankAccount.php.xml +++ /dev/null @@ -1,262 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - <?php - - - class - - BankAccount - - - { - - - - protected - - $balance - - = - - 0 - ; - - - - - public - - function - - getBalance - ( - ) - - - - { - - - - return - - $this - -> - balance - ; - - - - } - - - - - protected - - function - - setBalance - ( - $balance - ) - - - - { - - - - if - - ( - $balance - - >= - - 0 - ) - - { - - - - $this - -> - balance - - = - - $balance - ; - - - - } - - else - - { - - - - throw - - new - - RuntimeException - ; - - - - } - - - - } - - - - - public - - function - - depositMoney - ( - $balance - ) - - - - { - - - - $this - -> - setBalance - ( - $this - -> - getBalance - ( - ) - - + - - $balance - ) - ; - - - - - return - - $this - -> - getBalance - ( - ) - ; - - - - } - - - - - public - - function - - withdrawMoney - ( - $balance - ) - - - - { - - - - $this - -> - setBalance - ( - $this - -> - getBalance - ( - ) - - - - - $balance - ) - ; - - - - - return - - $this - -> - getBalance - ( - ) - ; - - - - } - - - } - - - - - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForBankAccount/index.xml b/vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForBankAccount/index.xml deleted file mode 100644 index df433b085..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForBankAccount/index.xml +++ /dev/null @@ -1,33 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForClassWithAnonymousFunction/index.xml b/vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForClassWithAnonymousFunction/index.xml deleted file mode 100644 index c8d90baa9..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForClassWithAnonymousFunction/index.xml +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForClassWithAnonymousFunction/source_with_class_and_anonymous_function.php.xml b/vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForClassWithAnonymousFunction/source_with_class_and_anonymous_function.php.xml deleted file mode 100644 index a4131745d..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForClassWithAnonymousFunction/source_with_class_and_anonymous_function.php.xml +++ /dev/null @@ -1,161 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - <?php - - - - class - - CoveredClassWithAnonymousFunctionInStaticMethod - - - { - - - - public - - static - - function - - runAnonymous - ( - ) - - - - { - - - - $filter - - = - - [ - 'abc124' - , - - 'abc123' - , - - '123' - ] - ; - - - - - array_walk - ( - - - - $filter - , - - - - function - - ( - & - $val - , - - $key - ) - - { - - - - $val - - = - - preg_replace - ( - '|[^0-9]|' - , - - '' - , - - $val - ) - ; - - - - } - - - - ) - ; - - - - - // Should be covered - - - - $extravar - - = - - true - ; - - - - } - - - } - - - - - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForFileWithIgnoredLines/index.xml b/vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForFileWithIgnoredLines/index.xml deleted file mode 100644 index d44f97062..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForFileWithIgnoredLines/index.xml +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForFileWithIgnoredLines/source_with_ignore.php.xml b/vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForFileWithIgnoredLines/source_with_ignore.php.xml deleted file mode 100644 index 5ff1d6b82..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/Report/XML/CoverageForFileWithIgnoredLines/source_with_ignore.php.xml +++ /dev/null @@ -1,187 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - <?php - - - if - - ( - $neverHappens - ) - - { - - - - // @codeCoverageIgnoreStart - - - - print - - '*' - ; - - - - // @codeCoverageIgnoreEnd - - - } - - - - /** - - - * @codeCoverageIgnore - - - */ - - - class - - Foo - - - { - - - - public - - function - - bar - ( - ) - - - - { - - - - } - - - } - - - - class - - Bar - - - { - - - - /** - - - * @codeCoverageIgnore - - - */ - - - - public - - function - - foo - ( - ) - - - - { - - - - } - - - } - - - - function - - baz - ( - ) - - - { - - - - print - - '*' - ; - - // @codeCoverageIgnore - - - } - - - - interface - - Bor - - - { - - - - public - - function - - foo - ( - ) - ; - - - - } - - - - - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/class-with-anonymous-function-clover.xml b/vendor/phpunit/php-code-coverage/tests/_files/class-with-anonymous-function-clover.xml deleted file mode 100644 index 008db55f1..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/class-with-anonymous-function-clover.xml +++ /dev/null @@ -1,21 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/class-with-anonymous-function-crap4j.xml b/vendor/phpunit/php-code-coverage/tests/_files/class-with-anonymous-function-crap4j.xml deleted file mode 100644 index 5bd2535e1..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/class-with-anonymous-function-crap4j.xml +++ /dev/null @@ -1,26 +0,0 @@ - - - CoverageForClassWithAnonymousFunction - %s - - Method Crap Stats - 1 - 0 - 0 - 1 - 0 - - - - global - CoveredClassWithAnonymousFunctionInStaticMethod - runAnonymous - runAnonymous() - runAnonymous() - 1 - 1 - 87.5 - 0 - - - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/class-with-anonymous-function-text.txt b/vendor/phpunit/php-code-coverage/tests/_files/class-with-anonymous-function-text.txt deleted file mode 100644 index e4204cc64..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/class-with-anonymous-function-text.txt +++ /dev/null @@ -1,12 +0,0 @@ - - -Code Coverage Report: - %s - - Summary: - Classes: 0.00% (0/1) - Methods: 0.00% (0/1) - Lines: 87.50% (7/8) - -CoveredClassWithAnonymousFunctionInStaticMethod - Methods: 0.00% ( 0/ 1) Lines: 87.50% ( 7/ 8) diff --git a/vendor/phpunit/php-code-coverage/tests/_files/ignored-lines-clover.xml b/vendor/phpunit/php-code-coverage/tests/_files/ignored-lines-clover.xml deleted file mode 100644 index efd38014a..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/ignored-lines-clover.xml +++ /dev/null @@ -1,17 +0,0 @@ - - - - - - - - - - - - - - - - - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/ignored-lines-crap4j.xml b/vendor/phpunit/php-code-coverage/tests/_files/ignored-lines-crap4j.xml deleted file mode 100644 index 2607b59ac..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/ignored-lines-crap4j.xml +++ /dev/null @@ -1,37 +0,0 @@ - - - CoverageForFileWithIgnoredLines - %s - - Method Crap Stats - 2 - 0 - 0 - 2 - 0 - - - - global - Foo - bar - bar() - bar() - 1 - 1 - 100 - 0 - - - global - Bar - foo - foo() - foo() - 1 - 1 - 100 - 0 - - - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/ignored-lines-text.txt b/vendor/phpunit/php-code-coverage/tests/_files/ignored-lines-text.txt deleted file mode 100644 index 6e8e1494f..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/ignored-lines-text.txt +++ /dev/null @@ -1,10 +0,0 @@ - - -Code Coverage Report:%w - %s -%w - Summary:%w - Classes: (0/0) - Methods: (0/0) - Lines: 50.00% (1/2) - diff --git a/vendor/phpunit/php-code-coverage/tests/_files/source_with_class_and_anonymous_function.php b/vendor/phpunit/php-code-coverage/tests/_files/source_with_class_and_anonymous_function.php deleted file mode 100644 index 72aa938e9..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/source_with_class_and_anonymous_function.php +++ /dev/null @@ -1,19 +0,0 @@ - 1, 'b' => 2, 'c' => 3, 'd' => 4], - static function ($v, $k) - { - return $k === 'b' || $v === 4; - }, - ARRAY_FILTER_USE_BOTH - ); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/_files/source_without_ignore.php b/vendor/phpunit/php-code-coverage/tests/_files/source_without_ignore.php deleted file mode 100644 index be4e83641..000000000 --- a/vendor/phpunit/php-code-coverage/tests/_files/source_without_ignore.php +++ /dev/null @@ -1,4 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\CodeCoverage\Report; - -use SebastianBergmann\CodeCoverage\Node\Builder; -use SebastianBergmann\CodeCoverage\TestCase; - -class BuilderTest extends TestCase -{ - protected $factory; - - protected function setUp(): void - { - $this->factory = new Builder; - } - - public function testSomething(): void - { - $root = $this->getCoverageForBankAccount()->getReport(); - - $expectedPath = \rtrim(TEST_FILES_PATH, \DIRECTORY_SEPARATOR); - $this->assertEquals($expectedPath, $root->getName()); - $this->assertEquals($expectedPath, $root->getPath()); - $this->assertEquals(10, $root->getNumExecutableLines()); - $this->assertEquals(5, $root->getNumExecutedLines()); - $this->assertEquals(1, $root->getNumClasses()); - $this->assertEquals(0, $root->getNumTestedClasses()); - $this->assertEquals(4, $root->getNumMethods()); - $this->assertEquals(3, $root->getNumTestedMethods()); - $this->assertEquals('0.00%', $root->getTestedClassesPercent()); - $this->assertEquals('75.00%', $root->getTestedMethodsPercent()); - $this->assertEquals('50.00%', $root->getLineExecutedPercent()); - $this->assertEquals(0, $root->getNumFunctions()); - $this->assertEquals(0, $root->getNumTestedFunctions()); - $this->assertNull($root->getParent()); - $this->assertEquals([], $root->getDirectories()); - #$this->assertEquals(array(), $root->getFiles()); - #$this->assertEquals(array(), $root->getChildNodes()); - - $this->assertEquals( - [ - 'BankAccount' => [ - 'methods' => [ - 'getBalance' => [ - 'signature' => 'getBalance()', - 'startLine' => 6, - 'endLine' => 9, - 'executableLines' => 1, - 'executedLines' => 1, - 'ccn' => 1, - 'coverage' => 100, - 'crap' => '1', - 'link' => 'BankAccount.php.html#6', - 'methodName' => 'getBalance', - 'visibility' => 'public', - ], - 'setBalance' => [ - 'signature' => 'setBalance($balance)', - 'startLine' => 11, - 'endLine' => 18, - 'executableLines' => 5, - 'executedLines' => 0, - 'ccn' => 2, - 'coverage' => 0, - 'crap' => 6, - 'link' => 'BankAccount.php.html#11', - 'methodName' => 'setBalance', - 'visibility' => 'protected', - ], - 'depositMoney' => [ - 'signature' => 'depositMoney($balance)', - 'startLine' => 20, - 'endLine' => 25, - 'executableLines' => 2, - 'executedLines' => 2, - 'ccn' => 1, - 'coverage' => 100, - 'crap' => '1', - 'link' => 'BankAccount.php.html#20', - 'methodName' => 'depositMoney', - 'visibility' => 'public', - ], - 'withdrawMoney' => [ - 'signature' => 'withdrawMoney($balance)', - 'startLine' => 27, - 'endLine' => 32, - 'executableLines' => 2, - 'executedLines' => 2, - 'ccn' => 1, - 'coverage' => 100, - 'crap' => '1', - 'link' => 'BankAccount.php.html#27', - 'methodName' => 'withdrawMoney', - 'visibility' => 'public', - ], - ], - 'startLine' => 2, - 'executableLines' => 10, - 'executedLines' => 5, - 'ccn' => 5, - 'coverage' => 50, - 'crap' => '8.12', - 'package' => [ - 'namespace' => '', - 'fullPackage' => '', - 'category' => '', - 'package' => '', - 'subpackage' => '', - ], - 'link' => 'BankAccount.php.html#2', - 'className' => 'BankAccount', - ], - ], - $root->getClasses() - ); - - $this->assertEquals([], $root->getFunctions()); - } - - public function testNotCrashParsing(): void - { - $coverage = $this->getCoverageForCrashParsing(); - $root = $coverage->getReport(); - - $expectedPath = \rtrim(TEST_FILES_PATH, \DIRECTORY_SEPARATOR); - $this->assertEquals($expectedPath, $root->getName()); - $this->assertEquals($expectedPath, $root->getPath()); - $this->assertEquals(2, $root->getNumExecutableLines()); - $this->assertEquals(0, $root->getNumExecutedLines()); - $data = $coverage->getData(); - $expectedFile = $expectedPath . \DIRECTORY_SEPARATOR . 'Crash.php'; - $this->assertSame([$expectedFile => [1 => [], 2 => []]], $data); - } - - public function testBuildDirectoryStructure(): void - { - $s = \DIRECTORY_SEPARATOR; - - $method = new \ReflectionMethod( - Builder::class, - 'buildDirectoryStructure' - ); - - $method->setAccessible(true); - - $this->assertEquals( - [ - 'src' => [ - 'Money.php/f' => [], - 'MoneyBag.php/f' => [], - 'Foo' => [ - 'Bar' => [ - 'Baz' => [ - 'Foo.php/f' => [], - ], - ], - ], - ], - ], - $method->invoke( - $this->factory, - [ - "src{$s}Money.php" => [], - "src{$s}MoneyBag.php" => [], - "src{$s}Foo{$s}Bar{$s}Baz{$s}Foo.php" => [], - ] - ) - ); - } - - /** - * @dataProvider reducePathsProvider - */ - public function testReducePaths($reducedPaths, $commonPath, $paths): void - { - $method = new \ReflectionMethod( - Builder::class, - 'reducePaths' - ); - - $method->setAccessible(true); - - $_commonPath = $method->invokeArgs($this->factory, [&$paths]); - - $this->assertEquals($reducedPaths, $paths); - $this->assertEquals($commonPath, $_commonPath); - } - - public function reducePathsProvider() - { - $s = \DIRECTORY_SEPARATOR; - - yield [ - [], - '.', - [], - ]; - - $prefixes = ["C:$s", "$s"]; - - foreach ($prefixes as $p) { - yield [ - [ - 'Money.php' => [], - ], - "{$p}home{$s}sb{$s}Money{$s}", - [ - "{$p}home{$s}sb{$s}Money{$s}Money.php" => [], - ], - ]; - - yield [ - [ - 'Money.php' => [], - 'MoneyBag.php' => [], - ], - "{$p}home{$s}sb{$s}Money", - [ - "{$p}home{$s}sb{$s}Money{$s}Money.php" => [], - "{$p}home{$s}sb{$s}Money{$s}MoneyBag.php" => [], - ], - ]; - - yield [ - [ - 'Money.php' => [], - 'MoneyBag.php' => [], - "Cash.phar{$s}Cash.php" => [], - ], - "{$p}home{$s}sb{$s}Money", - [ - "{$p}home{$s}sb{$s}Money{$s}Money.php" => [], - "{$p}home{$s}sb{$s}Money{$s}MoneyBag.php" => [], - "phar://{$p}home{$s}sb{$s}Money{$s}Cash.phar{$s}Cash.php" => [], - ], - ]; - } - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/tests/CloverTest.php b/vendor/phpunit/php-code-coverage/tests/tests/CloverTest.php deleted file mode 100644 index 7fdbf7da6..000000000 --- a/vendor/phpunit/php-code-coverage/tests/tests/CloverTest.php +++ /dev/null @@ -1,48 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\CodeCoverage\Report; - -use SebastianBergmann\CodeCoverage\TestCase; - -/** - * @covers SebastianBergmann\CodeCoverage\Report\Clover - */ -class CloverTest extends TestCase -{ - public function testCloverForBankAccountTest(): void - { - $clover = new Clover; - - $this->assertStringMatchesFormatFile( - TEST_FILES_PATH . 'BankAccount-clover.xml', - $clover->process($this->getCoverageForBankAccount(), null, 'BankAccount') - ); - } - - public function testCloverForFileWithIgnoredLines(): void - { - $clover = new Clover; - - $this->assertStringMatchesFormatFile( - TEST_FILES_PATH . 'ignored-lines-clover.xml', - $clover->process($this->getCoverageForFileWithIgnoredLines()) - ); - } - - public function testCloverForClassWithAnonymousFunction(): void - { - $clover = new Clover; - - $this->assertStringMatchesFormatFile( - TEST_FILES_PATH . 'class-with-anonymous-function-clover.xml', - $clover->process($this->getCoverageForClassWithAnonymousFunction()) - ); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/tests/CodeCoverageTest.php b/vendor/phpunit/php-code-coverage/tests/tests/CodeCoverageTest.php deleted file mode 100644 index ce2471ae5..000000000 --- a/vendor/phpunit/php-code-coverage/tests/tests/CodeCoverageTest.php +++ /dev/null @@ -1,359 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\CodeCoverage; - -use SebastianBergmann\CodeCoverage\Driver\Driver; -use SebastianBergmann\Environment\Runtime; - -/** - * @covers SebastianBergmann\CodeCoverage\CodeCoverage - */ -class CodeCoverageTest extends TestCase -{ - /** - * @var CodeCoverage - */ - private $coverage; - - protected function setUp(): void - { - $runtime = new Runtime; - - if (!$runtime->canCollectCodeCoverage()) { - $this->markTestSkipped('No code coverage driver available'); - } - - $this->coverage = new CodeCoverage; - } - - public function testCannotStopWithInvalidSecondArgument(): void - { - $this->expectException(Exception::class); - - $this->coverage->stop(true, null); - } - - public function testCannotAppendWithInvalidArgument(): void - { - $this->expectException(Exception::class); - - $this->coverage->append([], null); - } - - public function testCollect(): void - { - $coverage = $this->getCoverageForBankAccount(); - - $this->assertEquals( - $this->getExpectedDataArrayForBankAccount(), - $coverage->getData() - ); - - $this->assertEquals( - [ - 'BankAccountTest::testBalanceIsInitiallyZero' => ['size' => 'unknown', 'status' => -1], - 'BankAccountTest::testBalanceCannotBecomeNegative' => ['size' => 'unknown', 'status' => -1], - 'BankAccountTest::testBalanceCannotBecomeNegative2' => ['size' => 'unknown', 'status' => -1], - 'BankAccountTest::testDepositWithdrawMoney' => ['size' => 'unknown', 'status' => -1], - ], - $coverage->getTests() - ); - } - - public function testMerge(): void - { - $coverage = $this->getCoverageForBankAccountForFirstTwoTests(); - $coverage->merge($this->getCoverageForBankAccountForLastTwoTests()); - - $this->assertEquals( - $this->getExpectedDataArrayForBankAccount(), - $coverage->getData() - ); - } - - public function testMergeReverseOrder(): void - { - $coverage = $this->getCoverageForBankAccountForLastTwoTests(); - $coverage->merge($this->getCoverageForBankAccountForFirstTwoTests()); - - $this->assertEquals( - $this->getExpectedDataArrayForBankAccountInReverseOrder(), - $coverage->getData() - ); - } - - public function testMerge2(): void - { - $coverage = new CodeCoverage( - $this->createMock(Driver::class), - new Filter - ); - - $coverage->merge($this->getCoverageForBankAccount()); - - $this->assertEquals( - $this->getExpectedDataArrayForBankAccount(), - $coverage->getData() - ); - } - - public function testGetLinesToBeIgnored(): void - { - $this->assertEquals( - [ - 1, - 3, - 4, - 5, - 7, - 8, - 9, - 10, - 11, - 12, - 13, - 14, - 15, - 16, - 17, - 18, - 19, - 20, - 21, - 22, - 23, - 24, - 25, - 26, - 27, - 28, - 30, - 32, - 33, - 34, - 35, - 36, - 37, - 38, - ], - $this->getLinesToBeIgnored()->invoke( - $this->coverage, - TEST_FILES_PATH . 'source_with_ignore.php' - ) - ); - } - - public function testGetLinesToBeIgnored2(): void - { - $this->assertEquals( - [1, 5], - $this->getLinesToBeIgnored()->invoke( - $this->coverage, - TEST_FILES_PATH . 'source_without_ignore.php' - ) - ); - } - - public function testGetLinesToBeIgnored3(): void - { - $this->assertEquals( - [ - 1, - 2, - 3, - 4, - 5, - 8, - 11, - 15, - 16, - 19, - 20, - ], - $this->getLinesToBeIgnored()->invoke( - $this->coverage, - TEST_FILES_PATH . 'source_with_class_and_anonymous_function.php' - ) - ); - } - - public function testGetLinesToBeIgnoredOneLineAnnotations(): void - { - $this->assertEquals( - [ - 1, - 2, - 3, - 4, - 5, - 6, - 7, - 8, - 9, - 10, - 11, - 14, - 15, - 16, - 18, - 20, - 21, - 23, - 24, - 25, - 27, - 28, - 29, - 30, - 31, - 32, - 33, - 34, - 37, - ], - $this->getLinesToBeIgnored()->invoke( - $this->coverage, - TEST_FILES_PATH . 'source_with_oneline_annotations.php' - ) - ); - } - - public function testGetLinesToBeIgnoredWhenIgnoreIsDisabled(): void - { - $this->coverage->setDisableIgnoredLines(true); - - $this->assertEquals( - [ - 7, - 11, - 12, - 13, - 16, - 17, - 18, - 19, - 20, - 21, - 22, - 23, - 26, - 27, - 32, - 33, - 34, - 35, - 36, - 37, - ], - $this->getLinesToBeIgnored()->invoke( - $this->coverage, - TEST_FILES_PATH . 'source_with_ignore.php' - ) - ); - } - - public function testUseStatementsAreIgnored(): void - { - $this->assertEquals( - [ - 1, - 2, - 3, - 4, - 5, - 6, - 7, - 8, - 9, - 10, - 13, - 16, - 23, - 24, - ], - $this->getLinesToBeIgnored()->invoke( - $this->coverage, - TEST_FILES_PATH . 'source_with_use_statements.php' - ) - ); - } - - public function testAppendThrowsExceptionIfCoveredCodeWasNotExecuted(): void - { - $this->coverage->filter()->addDirectoryToWhitelist(TEST_FILES_PATH); - $this->coverage->setCheckForUnexecutedCoveredCode(true); - - $data = [ - TEST_FILES_PATH . 'BankAccount.php' => [ - 29 => -1, - 31 => -1, - ], - ]; - - $linesToBeCovered = [ - TEST_FILES_PATH . 'BankAccount.php' => [ - 22, - 24, - ], - ]; - - $linesToBeUsed = []; - - $this->expectException(CoveredCodeNotExecutedException::class); - - $this->coverage->append($data, 'File1.php', true, $linesToBeCovered, $linesToBeUsed); - } - - public function testAppendThrowsExceptionIfUsedCodeWasNotExecuted(): void - { - $this->coverage->filter()->addDirectoryToWhitelist(TEST_FILES_PATH); - $this->coverage->setCheckForUnexecutedCoveredCode(true); - - $data = [ - TEST_FILES_PATH . 'BankAccount.php' => [ - 29 => -1, - 31 => -1, - ], - ]; - - $linesToBeCovered = [ - TEST_FILES_PATH . 'BankAccount.php' => [ - 29, - 31, - ], - ]; - - $linesToBeUsed = [ - TEST_FILES_PATH . 'BankAccount.php' => [ - 22, - 24, - ], - ]; - - $this->expectException(CoveredCodeNotExecutedException::class); - - $this->coverage->append($data, 'File1.php', true, $linesToBeCovered, $linesToBeUsed); - } - - /** - * @return \ReflectionMethod - */ - private function getLinesToBeIgnored() - { - $getLinesToBeIgnored = new \ReflectionMethod( - 'SebastianBergmann\CodeCoverage\CodeCoverage', - 'getLinesToBeIgnored' - ); - - $getLinesToBeIgnored->setAccessible(true); - - return $getLinesToBeIgnored; - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/tests/Crap4jTest.php b/vendor/phpunit/php-code-coverage/tests/tests/Crap4jTest.php deleted file mode 100644 index 033fe4c74..000000000 --- a/vendor/phpunit/php-code-coverage/tests/tests/Crap4jTest.php +++ /dev/null @@ -1,48 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\CodeCoverage\Report; - -use SebastianBergmann\CodeCoverage\TestCase; - -/** - * @covers SebastianBergmann\CodeCoverage\Report\Crap4j - */ -class Crap4jTest extends TestCase -{ - public function testForBankAccountTest(): void - { - $crap4j = new Crap4j; - - $this->assertStringMatchesFormatFile( - TEST_FILES_PATH . 'BankAccount-crap4j.xml', - $crap4j->process($this->getCoverageForBankAccount(), null, 'BankAccount') - ); - } - - public function testForFileWithIgnoredLines(): void - { - $crap4j = new Crap4j; - - $this->assertStringMatchesFormatFile( - TEST_FILES_PATH . 'ignored-lines-crap4j.xml', - $crap4j->process($this->getCoverageForFileWithIgnoredLines(), null, 'CoverageForFileWithIgnoredLines') - ); - } - - public function testForClassWithAnonymousFunction(): void - { - $crap4j = new Crap4j; - - $this->assertStringMatchesFormatFile( - TEST_FILES_PATH . 'class-with-anonymous-function-crap4j.xml', - $crap4j->process($this->getCoverageForClassWithAnonymousFunction(), null, 'CoverageForClassWithAnonymousFunction') - ); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/tests/Exception/UnintentionallyCoveredCodeExceptionTest.php b/vendor/phpunit/php-code-coverage/tests/tests/Exception/UnintentionallyCoveredCodeExceptionTest.php deleted file mode 100644 index dffc22741..000000000 --- a/vendor/phpunit/php-code-coverage/tests/tests/Exception/UnintentionallyCoveredCodeExceptionTest.php +++ /dev/null @@ -1,51 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\CodeCoverage\tests\Exception; - -use PHPUnit\Framework\TestCase; -use SebastianBergmann\CodeCoverage\RuntimeException; -use SebastianBergmann\CodeCoverage\UnintentionallyCoveredCodeException; - -final class UnintentionallyCoveredCodeExceptionTest extends TestCase -{ - public function testCanConstructWithEmptyArray(): void - { - $unintentionallyCoveredUnits = []; - - $exception = new UnintentionallyCoveredCodeException($unintentionallyCoveredUnits); - - $this->assertInstanceOf(RuntimeException::class, $exception); - $this->assertSame($unintentionallyCoveredUnits, $exception->getUnintentionallyCoveredUnits()); - $this->assertSame('', $exception->getMessage()); - } - - public function testCanConstructWithNonEmptyArray(): void - { - $unintentionallyCoveredUnits = [ - 'foo', - 'bar', - 'baz', - ]; - - $exception = new UnintentionallyCoveredCodeException($unintentionallyCoveredUnits); - - $this->assertInstanceOf(RuntimeException::class, $exception); - $this->assertSame($unintentionallyCoveredUnits, $exception->getUnintentionallyCoveredUnits()); - - $expected = <<assertSame($expected, $exception->getMessage()); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/tests/FilterTest.php b/vendor/phpunit/php-code-coverage/tests/tests/FilterTest.php deleted file mode 100644 index 373b34929..000000000 --- a/vendor/phpunit/php-code-coverage/tests/tests/FilterTest.php +++ /dev/null @@ -1,213 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\CodeCoverage; - -use PHPUnit\Framework\TestCase; -use SebastianBergmann\FileIterator\Facade as FileIteratorFacade; - -class FilterTest extends TestCase -{ - /** - * @var Filter - */ - private $filter; - - /** - * @var array - */ - private $files = []; - - protected function setUp(): void - { - $this->filter = \unserialize('O:37:"SebastianBergmann\CodeCoverage\Filter":0:{}'); - - $this->files = [ - TEST_FILES_PATH . 'BankAccount.php', - TEST_FILES_PATH . 'BankAccountTest.php', - TEST_FILES_PATH . 'CoverageClassExtendedTest.php', - TEST_FILES_PATH . 'CoverageClassTest.php', - TEST_FILES_PATH . 'CoverageFunctionParenthesesTest.php', - TEST_FILES_PATH . 'CoverageFunctionParenthesesWhitespaceTest.php', - TEST_FILES_PATH . 'CoverageFunctionTest.php', - TEST_FILES_PATH . 'CoverageMethodOneLineAnnotationTest.php', - TEST_FILES_PATH . 'CoverageMethodParenthesesTest.php', - TEST_FILES_PATH . 'CoverageMethodParenthesesWhitespaceTest.php', - TEST_FILES_PATH . 'CoverageMethodTest.php', - TEST_FILES_PATH . 'CoverageNoneTest.php', - TEST_FILES_PATH . 'CoverageNotPrivateTest.php', - TEST_FILES_PATH . 'CoverageNotProtectedTest.php', - TEST_FILES_PATH . 'CoverageNotPublicTest.php', - TEST_FILES_PATH . 'CoverageNothingTest.php', - TEST_FILES_PATH . 'CoveragePrivateTest.php', - TEST_FILES_PATH . 'CoverageProtectedTest.php', - TEST_FILES_PATH . 'CoveragePublicTest.php', - TEST_FILES_PATH . 'CoverageTwoDefaultClassAnnotations.php', - TEST_FILES_PATH . 'CoveredClass.php', - TEST_FILES_PATH . 'CoveredFunction.php', - TEST_FILES_PATH . 'Crash.php', - TEST_FILES_PATH . 'NamespaceCoverageClassExtendedTest.php', - TEST_FILES_PATH . 'NamespaceCoverageClassTest.php', - TEST_FILES_PATH . 'NamespaceCoverageCoversClassPublicTest.php', - TEST_FILES_PATH . 'NamespaceCoverageCoversClassTest.php', - TEST_FILES_PATH . 'NamespaceCoverageMethodTest.php', - TEST_FILES_PATH . 'NamespaceCoverageNotPrivateTest.php', - TEST_FILES_PATH . 'NamespaceCoverageNotProtectedTest.php', - TEST_FILES_PATH . 'NamespaceCoverageNotPublicTest.php', - TEST_FILES_PATH . 'NamespaceCoveragePrivateTest.php', - TEST_FILES_PATH . 'NamespaceCoverageProtectedTest.php', - TEST_FILES_PATH . 'NamespaceCoveragePublicTest.php', - TEST_FILES_PATH . 'NamespaceCoveredClass.php', - TEST_FILES_PATH . 'NotExistingCoveredElementTest.php', - TEST_FILES_PATH . 'source_with_class_and_anonymous_function.php', - TEST_FILES_PATH . 'source_with_ignore.php', - TEST_FILES_PATH . 'source_with_namespace.php', - TEST_FILES_PATH . 'source_with_oneline_annotations.php', - TEST_FILES_PATH . 'source_with_use_statements.php', - TEST_FILES_PATH . 'source_without_ignore.php', - TEST_FILES_PATH . 'source_without_namespace.php', - ]; - } - - /** - * @covers SebastianBergmann\CodeCoverage\Filter::addFileToWhitelist - * @covers SebastianBergmann\CodeCoverage\Filter::getWhitelist - */ - public function testAddingAFileToTheWhitelistWorks(): void - { - $this->filter->addFileToWhitelist($this->files[0]); - - $this->assertEquals( - [$this->files[0]], - $this->filter->getWhitelist() - ); - } - - /** - * @covers SebastianBergmann\CodeCoverage\Filter::removeFileFromWhitelist - * @covers SebastianBergmann\CodeCoverage\Filter::getWhitelist - */ - public function testRemovingAFileFromTheWhitelistWorks(): void - { - $this->filter->addFileToWhitelist($this->files[0]); - $this->filter->removeFileFromWhitelist($this->files[0]); - - $this->assertEquals([], $this->filter->getWhitelist()); - } - - /** - * @covers SebastianBergmann\CodeCoverage\Filter::addDirectoryToWhitelist - * @covers SebastianBergmann\CodeCoverage\Filter::getWhitelist - * @depends testAddingAFileToTheWhitelistWorks - */ - public function testAddingADirectoryToTheWhitelistWorks(): void - { - $this->filter->addDirectoryToWhitelist(TEST_FILES_PATH); - - $whitelist = $this->filter->getWhitelist(); - \sort($whitelist); - - $this->assertEquals($this->files, $whitelist); - } - - /** - * @covers SebastianBergmann\CodeCoverage\Filter::addFilesToWhitelist - * @covers SebastianBergmann\CodeCoverage\Filter::getWhitelist - */ - public function testAddingFilesToTheWhitelistWorks(): void - { - $facade = new FileIteratorFacade; - - $files = $facade->getFilesAsArray( - TEST_FILES_PATH, - $suffixes = '.php' - ); - - $this->filter->addFilesToWhitelist($files); - - $whitelist = $this->filter->getWhitelist(); - \sort($whitelist); - - $this->assertEquals($this->files, $whitelist); - } - - /** - * @covers SebastianBergmann\CodeCoverage\Filter::removeDirectoryFromWhitelist - * @covers SebastianBergmann\CodeCoverage\Filter::getWhitelist - * @depends testAddingADirectoryToTheWhitelistWorks - */ - public function testRemovingADirectoryFromTheWhitelistWorks(): void - { - $this->filter->addDirectoryToWhitelist(TEST_FILES_PATH); - $this->filter->removeDirectoryFromWhitelist(TEST_FILES_PATH); - - $this->assertEquals([], $this->filter->getWhitelist()); - } - - /** - * @covers SebastianBergmann\CodeCoverage\Filter::isFile - */ - public function testIsFile(): void - { - $this->assertFalse($this->filter->isFile('vfs://root/a/path')); - $this->assertFalse($this->filter->isFile('xdebug://debug-eval')); - $this->assertFalse($this->filter->isFile('eval()\'d code')); - $this->assertFalse($this->filter->isFile('runtime-created function')); - $this->assertFalse($this->filter->isFile('assert code')); - $this->assertFalse($this->filter->isFile('regexp code')); - $this->assertTrue($this->filter->isFile(__FILE__)); - } - - /** - * @covers SebastianBergmann\CodeCoverage\Filter::isFiltered - */ - public function testWhitelistedFileIsNotFiltered(): void - { - $this->filter->addFileToWhitelist($this->files[0]); - $this->assertFalse($this->filter->isFiltered($this->files[0])); - } - - /** - * @covers SebastianBergmann\CodeCoverage\Filter::isFiltered - */ - public function testNotWhitelistedFileIsFiltered(): void - { - $this->filter->addFileToWhitelist($this->files[0]); - $this->assertTrue($this->filter->isFiltered($this->files[1])); - } - - /** - * @covers SebastianBergmann\CodeCoverage\Filter::isFiltered - * @covers SebastianBergmann\CodeCoverage\Filter::isFile - */ - public function testNonFilesAreFiltered(): void - { - $this->assertTrue($this->filter->isFiltered('vfs://root/a/path')); - $this->assertTrue($this->filter->isFiltered('xdebug://debug-eval')); - $this->assertTrue($this->filter->isFiltered('eval()\'d code')); - $this->assertTrue($this->filter->isFiltered('runtime-created function')); - $this->assertTrue($this->filter->isFiltered('assert code')); - $this->assertTrue($this->filter->isFiltered('regexp code')); - } - - /** - * @covers SebastianBergmann\CodeCoverage\Filter::addFileToWhitelist - * @covers SebastianBergmann\CodeCoverage\Filter::getWhitelist - * - * @ticket https://github.com/sebastianbergmann/php-code-coverage/issues/664 - */ - public function testTryingToAddFileThatDoesNotExistDoesNotChangeFilter(): void - { - $filter = new Filter; - - $filter->addFileToWhitelist('does_not_exist'); - - $this->assertEmpty($filter->getWhitelistedFiles()); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/tests/HTMLTest.php b/vendor/phpunit/php-code-coverage/tests/tests/HTMLTest.php deleted file mode 100644 index 0ddd85d66..000000000 --- a/vendor/phpunit/php-code-coverage/tests/tests/HTMLTest.php +++ /dev/null @@ -1,102 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\CodeCoverage\Report\Html; - -use SebastianBergmann\CodeCoverage\TestCase; - -class HTMLTest extends TestCase -{ - private static $TEST_REPORT_PATH_SOURCE; - - public static function setUpBeforeClass(): void - { - parent::setUpBeforeClass(); - - self::$TEST_REPORT_PATH_SOURCE = TEST_FILES_PATH . 'Report' . \DIRECTORY_SEPARATOR . 'HTML'; - } - - protected function tearDown(): void - { - parent::tearDown(); - - $tmpFilesIterator = new \RecursiveIteratorIterator( - new \RecursiveDirectoryIterator(self::$TEST_TMP_PATH, \RecursiveDirectoryIterator::SKIP_DOTS), - \RecursiveIteratorIterator::CHILD_FIRST - ); - - foreach ($tmpFilesIterator as $path => $fileInfo) { - /* @var \SplFileInfo $fileInfo */ - $pathname = $fileInfo->getPathname(); - $fileInfo->isDir() ? \rmdir($pathname) : \unlink($pathname); - } - } - - public function testForBankAccountTest(): void - { - $expectedFilesPath = self::$TEST_REPORT_PATH_SOURCE . \DIRECTORY_SEPARATOR . 'CoverageForBankAccount'; - - $report = new Facade; - $report->process($this->getCoverageForBankAccount(), self::$TEST_TMP_PATH); - - $this->assertFilesEquals($expectedFilesPath, self::$TEST_TMP_PATH); - } - - public function testForFileWithIgnoredLines(): void - { - $expectedFilesPath = self::$TEST_REPORT_PATH_SOURCE . \DIRECTORY_SEPARATOR . 'CoverageForFileWithIgnoredLines'; - - $report = new Facade; - $report->process($this->getCoverageForFileWithIgnoredLines(), self::$TEST_TMP_PATH); - - $this->assertFilesEquals($expectedFilesPath, self::$TEST_TMP_PATH); - } - - public function testForClassWithAnonymousFunction(): void - { - $expectedFilesPath = - self::$TEST_REPORT_PATH_SOURCE . \DIRECTORY_SEPARATOR . 'CoverageForClassWithAnonymousFunction'; - - $report = new Facade; - $report->process($this->getCoverageForClassWithAnonymousFunction(), self::$TEST_TMP_PATH); - - $this->assertFilesEquals($expectedFilesPath, self::$TEST_TMP_PATH); - } - - /** - * @param string $expectedFilesPath - * @param string $actualFilesPath - */ - private function assertFilesEquals($expectedFilesPath, $actualFilesPath): void - { - $expectedFilesIterator = new \FilesystemIterator($expectedFilesPath); - $actualFilesIterator = new \RegexIterator(new \FilesystemIterator($actualFilesPath), '/.html/'); - - $this->assertEquals( - \iterator_count($expectedFilesIterator), - \iterator_count($actualFilesIterator), - 'Generated files and expected files not match' - ); - - foreach ($expectedFilesIterator as $path => $fileInfo) { - /* @var \SplFileInfo $fileInfo */ - $filename = $fileInfo->getFilename(); - - $actualFile = $actualFilesPath . \DIRECTORY_SEPARATOR . $filename; - - $this->assertFileExists($actualFile); - - $this->assertStringMatchesFormatFile( - $fileInfo->getPathname(), - \str_replace(\PHP_EOL, "\n", \file_get_contents($actualFile)), - "${filename} not match" - ); - } - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/tests/TextTest.php b/vendor/phpunit/php-code-coverage/tests/tests/TextTest.php deleted file mode 100644 index 501226f8b..000000000 --- a/vendor/phpunit/php-code-coverage/tests/tests/TextTest.php +++ /dev/null @@ -1,48 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\CodeCoverage\Report; - -use SebastianBergmann\CodeCoverage\TestCase; - -/** - * @covers SebastianBergmann\CodeCoverage\Report\Text - */ -class TextTest extends TestCase -{ - public function testTextForBankAccountTest(): void - { - $text = new Text(50, 90, false, false); - - $this->assertStringMatchesFormatFile( - TEST_FILES_PATH . 'BankAccount-text.txt', - \str_replace(\PHP_EOL, "\n", $text->process($this->getCoverageForBankAccount())) - ); - } - - public function testTextForFileWithIgnoredLines(): void - { - $text = new Text(50, 90, false, false); - - $this->assertStringMatchesFormatFile( - TEST_FILES_PATH . 'ignored-lines-text.txt', - \str_replace(\PHP_EOL, "\n", $text->process($this->getCoverageForFileWithIgnoredLines())) - ); - } - - public function testTextForClassWithAnonymousFunction(): void - { - $text = new Text(50, 90, false, false); - - $this->assertStringMatchesFormatFile( - TEST_FILES_PATH . 'class-with-anonymous-function-text.txt', - \str_replace(\PHP_EOL, "\n", $text->process($this->getCoverageForClassWithAnonymousFunction())) - ); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/tests/UtilTest.php b/vendor/phpunit/php-code-coverage/tests/tests/UtilTest.php deleted file mode 100644 index 2ebfb61e7..000000000 --- a/vendor/phpunit/php-code-coverage/tests/tests/UtilTest.php +++ /dev/null @@ -1,28 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\CodeCoverage; - -use PHPUnit\Framework\TestCase; - -/** - * @covers SebastianBergmann\CodeCoverage\Util - */ -class UtilTest extends TestCase -{ - public function testPercent(): void - { - $this->assertEquals(100, Util::percent(100, 0)); - $this->assertEquals(100, Util::percent(100, 100)); - $this->assertEquals( - '100.00%', - Util::percent(100, 100, true) - ); - } -} diff --git a/vendor/phpunit/php-code-coverage/tests/tests/XmlTest.php b/vendor/phpunit/php-code-coverage/tests/tests/XmlTest.php deleted file mode 100644 index 13045a74c..000000000 --- a/vendor/phpunit/php-code-coverage/tests/tests/XmlTest.php +++ /dev/null @@ -1,97 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\CodeCoverage\Report\Xml; - -use SebastianBergmann\CodeCoverage\TestCase; - -class XmlTest extends TestCase -{ - private static $TEST_REPORT_PATH_SOURCE; - - public static function setUpBeforeClass(): void - { - parent::setUpBeforeClass(); - - self::$TEST_REPORT_PATH_SOURCE = TEST_FILES_PATH . 'Report' . \DIRECTORY_SEPARATOR . 'XML'; - } - - protected function tearDown(): void - { - parent::tearDown(); - - $tmpFilesIterator = new \FilesystemIterator(self::$TEST_TMP_PATH); - - foreach ($tmpFilesIterator as $path => $fileInfo) { - /* @var \SplFileInfo $fileInfo */ - \unlink($fileInfo->getPathname()); - } - } - - public function testForBankAccountTest(): void - { - $expectedFilesPath = self::$TEST_REPORT_PATH_SOURCE . \DIRECTORY_SEPARATOR . 'CoverageForBankAccount'; - - $xml = new Facade('1.0.0'); - $xml->process($this->getCoverageForBankAccount(), self::$TEST_TMP_PATH); - - $this->assertFilesEquals($expectedFilesPath, self::$TEST_TMP_PATH); - } - - public function testForFileWithIgnoredLines(): void - { - $expectedFilesPath = self::$TEST_REPORT_PATH_SOURCE . \DIRECTORY_SEPARATOR . 'CoverageForFileWithIgnoredLines'; - - $xml = new Facade('1.0.0'); - $xml->process($this->getCoverageForFileWithIgnoredLines(), self::$TEST_TMP_PATH); - - $this->assertFilesEquals($expectedFilesPath, self::$TEST_TMP_PATH); - } - - public function testForClassWithAnonymousFunction(): void - { - $expectedFilesPath = self::$TEST_REPORT_PATH_SOURCE . \DIRECTORY_SEPARATOR . 'CoverageForClassWithAnonymousFunction'; - - $xml = new Facade('1.0.0'); - $xml->process($this->getCoverageForClassWithAnonymousFunction(), self::$TEST_TMP_PATH); - - $this->assertFilesEquals($expectedFilesPath, self::$TEST_TMP_PATH); - } - - /** - * @param string $expectedFilesPath - * @param string $actualFilesPath - */ - private function assertFilesEquals($expectedFilesPath, $actualFilesPath): void - { - $expectedFilesIterator = new \FilesystemIterator($expectedFilesPath); - $actualFilesIterator = new \FilesystemIterator($actualFilesPath); - - $this->assertEquals( - \iterator_count($expectedFilesIterator), - \iterator_count($actualFilesIterator), - 'Generated files and expected files not match' - ); - - foreach ($expectedFilesIterator as $path => $fileInfo) { - /* @var \SplFileInfo $fileInfo */ - $filename = $fileInfo->getFilename(); - - $actualFile = $actualFilesPath . \DIRECTORY_SEPARATOR . $filename; - - $this->assertFileExists($actualFile); - - $this->assertStringMatchesFormatFile( - $fileInfo->getPathname(), - \file_get_contents($actualFile), - "${filename} not match" - ); - } - } -} diff --git a/vendor/phpunit/php-file-iterator/.gitattributes b/vendor/phpunit/php-file-iterator/.gitattributes deleted file mode 100644 index 461090b7e..000000000 --- a/vendor/phpunit/php-file-iterator/.gitattributes +++ /dev/null @@ -1 +0,0 @@ -*.php diff=php diff --git a/vendor/phpunit/php-file-iterator/.github/stale.yml b/vendor/phpunit/php-file-iterator/.github/stale.yml deleted file mode 100644 index 4eadca327..000000000 --- a/vendor/phpunit/php-file-iterator/.github/stale.yml +++ /dev/null @@ -1,40 +0,0 @@ -# Configuration for probot-stale - https://github.com/probot/stale - -# Number of days of inactivity before an Issue or Pull Request becomes stale -daysUntilStale: 60 - -# Number of days of inactivity before a stale Issue or Pull Request is closed. -# Set to false to disable. If disabled, issues still need to be closed manually, but will remain marked as stale. -daysUntilClose: 7 - -# Issues or Pull Requests with these labels will never be considered stale. Set to `[]` to disable -exemptLabels: - - enhancement - -# Set to true to ignore issues in a project (defaults to false) -exemptProjects: false - -# Set to true to ignore issues in a milestone (defaults to false) -exemptMilestones: false - -# Label to use when marking as stale -staleLabel: stale - -# Comment to post when marking as stale. Set to `false` to disable -markComment: > - This issue has been automatically marked as stale because it has not had activity within the last 60 days. It will be closed after 7 days if no further activity occurs. Thank you for your contributions. - -# Comment to post when removing the stale label. -# unmarkComment: > -# Your comment here. - -# Comment to post when closing a stale Issue or Pull Request. -closeComment: > - This issue has been automatically closed because it has not had activity since it was marked as stale. Thank you for your contributions. - -# Limit the number of actions per hour, from 1-30. Default is 30 -limitPerRun: 30 - -# Limit to only `issues` or `pulls` -only: issues - diff --git a/vendor/phpunit/php-file-iterator/.gitignore b/vendor/phpunit/php-file-iterator/.gitignore deleted file mode 100644 index 5ad7a64f1..000000000 --- a/vendor/phpunit/php-file-iterator/.gitignore +++ /dev/null @@ -1,5 +0,0 @@ -/.idea -/vendor/ -/.php_cs -/.php_cs.cache -/composer.lock diff --git a/vendor/phpunit/php-file-iterator/.php_cs.dist b/vendor/phpunit/php-file-iterator/.php_cs.dist deleted file mode 100644 index efc649f8f..000000000 --- a/vendor/phpunit/php-file-iterator/.php_cs.dist +++ /dev/null @@ -1,168 +0,0 @@ - - -For the full copyright and license information, please view the LICENSE -file that was distributed with this source code. -EOF; - -return PhpCsFixer\Config::create() - ->setRiskyAllowed(true) - ->setRules( - [ - 'array_syntax' => ['syntax' => 'short'], - 'binary_operator_spaces' => [ - 'operators' => [ - '=' => 'align', - '=>' => 'align', - ], - ], - 'blank_line_after_namespace' => true, - 'blank_line_before_statement' => [ - 'statements' => [ - 'break', - 'continue', - 'declare', - 'do', - 'for', - 'foreach', - 'if', - 'include', - 'include_once', - 'require', - 'require_once', - 'return', - 'switch', - 'throw', - 'try', - 'while', - 'yield', - ], - ], - 'braces' => true, - 'cast_spaces' => true, - 'class_attributes_separation' => ['elements' => ['method']], - 'compact_nullable_typehint' => true, - 'concat_space' => ['spacing' => 'one'], - 'declare_equal_normalize' => ['space' => 'none'], - 'dir_constant' => true, - 'elseif' => true, - 'encoding' => true, - 'full_opening_tag' => true, - 'function_declaration' => true, - 'header_comment' => ['header' => $header, 'separate' => 'none'], - 'indentation_type' => true, - 'line_ending' => true, - 'list_syntax' => ['syntax' => 'short'], - 'lowercase_cast' => true, - 'lowercase_constants' => true, - 'lowercase_keywords' => true, - 'magic_constant_casing' => true, - 'method_argument_space' => ['ensure_fully_multiline' => true], - 'modernize_types_casting' => true, - 'native_function_casing' => true, - 'native_function_invocation' => true, - 'no_alias_functions' => true, - 'no_blank_lines_after_class_opening' => true, - 'no_blank_lines_after_phpdoc' => true, - 'no_closing_tag' => true, - 'no_empty_comment' => true, - 'no_empty_phpdoc' => true, - 'no_empty_statement' => true, - 'no_extra_blank_lines' => true, - 'no_homoglyph_names' => true, - 'no_leading_import_slash' => true, - 'no_leading_namespace_whitespace' => true, - 'no_mixed_echo_print' => ['use' => 'print'], - 'no_null_property_initialization' => true, - 'no_short_bool_cast' => true, - 'no_short_echo_tag' => true, - 'no_singleline_whitespace_before_semicolons' => true, - 'no_spaces_after_function_name' => true, - 'no_spaces_inside_parenthesis' => true, - 'no_superfluous_elseif' => true, - 'no_trailing_comma_in_list_call' => true, - 'no_trailing_comma_in_singleline_array' => true, - 'no_trailing_whitespace' => true, - 'no_trailing_whitespace_in_comment' => true, - 'no_unneeded_control_parentheses' => true, - 'no_unneeded_curly_braces' => true, - 'no_unneeded_final_method' => true, - 'no_unreachable_default_argument_value' => true, - 'no_unused_imports' => true, - 'no_useless_else' => true, - 'no_whitespace_before_comma_in_array' => true, - 'no_whitespace_in_blank_line' => true, - 'non_printable_character' => true, - 'normalize_index_brace' => true, - 'object_operator_without_whitespace' => true, - 'ordered_class_elements' => [ - 'order' => [ - 'use_trait', - 'constant_public', - 'constant_protected', - 'constant_private', - 'property_public_static', - 'property_protected_static', - 'property_private_static', - 'property_public', - 'property_protected', - 'property_private', - 'method_public_static', - 'construct', - 'destruct', - 'magic', - 'phpunit', - 'method_public', - 'method_protected', - 'method_private', - 'method_protected_static', - 'method_private_static', - ], - ], - 'ordered_imports' => true, - 'phpdoc_add_missing_param_annotation' => true, - 'phpdoc_align' => true, - 'phpdoc_annotation_without_dot' => true, - 'phpdoc_indent' => true, - 'phpdoc_no_access' => true, - 'phpdoc_no_empty_return' => true, - 'phpdoc_no_package' => true, - 'phpdoc_order' => true, - 'phpdoc_return_self_reference' => true, - 'phpdoc_scalar' => true, - 'phpdoc_separation' => true, - 'phpdoc_single_line_var_spacing' => true, - 'phpdoc_to_comment' => true, - 'phpdoc_trim' => true, - 'phpdoc_types' => true, - 'phpdoc_types_order' => true, - 'phpdoc_var_without_name' => true, - 'pow_to_exponentiation' => true, - 'protected_to_private' => true, - 'return_type_declaration' => ['space_before' => 'none'], - 'self_accessor' => true, - 'short_scalar_cast' => true, - 'simplified_null_return' => true, - 'single_blank_line_at_eof' => true, - 'single_import_per_statement' => true, - 'single_line_after_imports' => true, - 'single_quote' => true, - 'standardize_not_equals' => true, - 'ternary_to_null_coalescing' => true, - 'trim_array_spaces' => true, - 'unary_operator_spaces' => true, - 'visibility_required' => true, - 'void_return' => true, - 'whitespace_after_comma_in_array' => true, - ] - ) - ->setFinder( - PhpCsFixer\Finder::create() - ->files() - ->in(__DIR__ . '/src') - ->in(__DIR__ . '/tests') - ->notName('*.phpt') - ); diff --git a/vendor/phpunit/php-file-iterator/.travis.yml b/vendor/phpunit/php-file-iterator/.travis.yml deleted file mode 100644 index 16b399c4f..000000000 --- a/vendor/phpunit/php-file-iterator/.travis.yml +++ /dev/null @@ -1,32 +0,0 @@ -language: php - -sudo: false - -php: - - 7.1 - - 7.2 - - master - -env: - matrix: - - DEPENDENCIES="high" - - DEPENDENCIES="low" - global: - - DEFAULT_COMPOSER_FLAGS="--no-interaction --no-ansi --no-progress --no-suggest" - -before_install: - - composer self-update - - composer clear-cache - -install: - - if [[ "$DEPENDENCIES" = 'high' ]]; then travis_retry composer update $DEFAULT_COMPOSER_FLAGS; fi - - if [[ "$DEPENDENCIES" = 'low' ]]; then travis_retry composer update $DEFAULT_COMPOSER_FLAGS --prefer-lowest; fi - -script: - - ./vendor/bin/phpunit --coverage-clover=coverage.xml - -after_success: - - bash <(curl -s https://codecov.io/bash) - -notifications: - email: false diff --git a/vendor/phpunit/php-file-iterator/ChangeLog.md b/vendor/phpunit/php-file-iterator/ChangeLog.md index 635891eb0..40d3c7c7b 100644 --- a/vendor/phpunit/php-file-iterator/ChangeLog.md +++ b/vendor/phpunit/php-file-iterator/ChangeLog.md @@ -2,29 +2,59 @@ All notable changes to this project will be documented in this file. This project adheres to [Semantic Versioning](http://semver.org/). -## [2.0.3] - 2020-11-30 +## [3.0.5] - 2020-09-28 ### Changed -* Changed PHP version constraint in `composer.json` from `^7.1` to `>=7.1` +* Changed PHP version constraint in `composer.json` from `^7.3 || ^8.0` to `>=7.3` + +## [3.0.4] - 2020-07-11 + +### Fixed + +* [#67](https://github.com/sebastianbergmann/php-file-iterator/issues/67): `TypeError` in `SebastianBergmann\FileIterator\Iterator::accept()` + +## [3.0.3] - 2020-06-26 + +### Added + +* This component is now supported on PHP 8 + +## [3.0.2] - 2020-06-15 + +### Changed + +* Tests etc. are now ignored for archive exports + +## [3.0.1] - 2020-04-18 + +### Fixed + +* [#64](https://github.com/sebastianbergmann/php-file-iterator/issues/64): Release tarball contains Composer PHAR + +## [3.0.0] - 2020-02-07 + +### Removed + +* This component is no longer supported on PHP 7.1 and PHP 7.2 ## [2.0.2] - 2018-09-13 ### Fixed -* Fixed [#48](https://github.com/sebastianbergmann/php-file-iterator/issues/48): Excluding an array that contains false ends up excluding the current working directory +* [#48](https://github.com/sebastianbergmann/php-file-iterator/issues/48): Excluding an array that contains false ends up excluding the current working directory ## [2.0.1] - 2018-06-11 ### Fixed -* Fixed [#46](https://github.com/sebastianbergmann/php-file-iterator/issues/46): Regression with hidden parent directory +* [#46](https://github.com/sebastianbergmann/php-file-iterator/issues/46): Regression with hidden parent directory ## [2.0.0] - 2018-05-28 ### Fixed -* Fixed [#30](https://github.com/sebastianbergmann/php-file-iterator/issues/30): Exclude is not considered if it is a parent of the base path +* [#30](https://github.com/sebastianbergmann/php-file-iterator/issues/30): Exclude is not considered if it is a parent of the base path ### Changed @@ -38,19 +68,19 @@ All notable changes to this project will be documented in this file. This projec ### Fixed -* Fixed [#37](https://github.com/sebastianbergmann/php-file-iterator/issues/37): Regression caused by fix for [#30](https://github.com/sebastianbergmann/php-file-iterator/issues/30) +* [#37](https://github.com/sebastianbergmann/php-file-iterator/issues/37): Regression caused by fix for [#30](https://github.com/sebastianbergmann/php-file-iterator/issues/30) ## [1.4.4] - 2017-11-27 ### Fixed -* Fixed [#30](https://github.com/sebastianbergmann/php-file-iterator/issues/30): Exclude is not considered if it is a parent of the base path +* [#30](https://github.com/sebastianbergmann/php-file-iterator/issues/30): Exclude is not considered if it is a parent of the base path ## [1.4.3] - 2017-11-25 ### Fixed -* Fixed [#34](https://github.com/sebastianbergmann/php-file-iterator/issues/34): Factory should use canonical directory names +* [#34](https://github.com/sebastianbergmann/php-file-iterator/issues/34): Factory should use canonical directory names ## [1.4.2] - 2016-11-26 @@ -64,12 +94,17 @@ No changes ### Added -* [Added support for wildcards (glob) in exclude](https://github.com/sebastianbergmann/php-file-iterator/pull/23) +* [#23](https://github.com/sebastianbergmann/php-file-iterator/pull/23): Added support for wildcards (glob) in exclude -[2.0.3]: https://github.com/sebastianbergmann/php-file-iterator/compare/2.0.2...2.0.3 +[3.0.5]: https://github.com/sebastianbergmann/php-file-iterator/compare/3.0.4...3.0.5 +[3.0.4]: https://github.com/sebastianbergmann/php-file-iterator/compare/3.0.3...3.0.4 +[3.0.3]: https://github.com/sebastianbergmann/php-file-iterator/compare/3.0.2...3.0.3 +[3.0.2]: https://github.com/sebastianbergmann/php-file-iterator/compare/3.0.1...3.0.2 +[3.0.1]: https://github.com/sebastianbergmann/php-file-iterator/compare/3.0.0...3.0.1 +[3.0.0]: https://github.com/sebastianbergmann/php-file-iterator/compare/2.0.2...3.0.0 [2.0.2]: https://github.com/sebastianbergmann/php-file-iterator/compare/2.0.1...2.0.2 [2.0.1]: https://github.com/sebastianbergmann/php-file-iterator/compare/2.0.0...2.0.1 -[2.0.0]: https://github.com/sebastianbergmann/php-file-iterator/compare/1.4...master +[2.0.0]: https://github.com/sebastianbergmann/php-file-iterator/compare/1.4...2.0.0 [1.4.5]: https://github.com/sebastianbergmann/php-file-iterator/compare/1.4.4...1.4.5 [1.4.4]: https://github.com/sebastianbergmann/php-file-iterator/compare/1.4.3...1.4.4 [1.4.3]: https://github.com/sebastianbergmann/php-file-iterator/compare/1.4.2...1.4.3 diff --git a/vendor/phpunit/php-file-iterator/LICENSE b/vendor/phpunit/php-file-iterator/LICENSE index 87c3b5124..a915a5449 100644 --- a/vendor/phpunit/php-file-iterator/LICENSE +++ b/vendor/phpunit/php-file-iterator/LICENSE @@ -1,6 +1,6 @@ php-file-iterator -Copyright (c) 2009-2018, Sebastian Bergmann . +Copyright (c) 2009-2020, Sebastian Bergmann . All rights reserved. Redistribution and use in source and binary forms, with or without diff --git a/vendor/phpunit/php-file-iterator/composer.json b/vendor/phpunit/php-file-iterator/composer.json index b1717b8ad..f1b95b3f8 100644 --- a/vendor/phpunit/php-file-iterator/composer.json +++ b/vendor/phpunit/php-file-iterator/composer.json @@ -18,11 +18,19 @@ "support": { "issues": "https://github.com/sebastianbergmann/php-file-iterator/issues" }, + "config": { + "platform": { + "php": "7.3.0" + }, + "optimize-autoloader": true, + "sort-packages": true + }, + "prefer-stable": true, "require": { - "php": ">=7.1" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^8.5" + "phpunit/phpunit": "^9.3" }, "autoload": { "classmap": [ @@ -31,7 +39,7 @@ }, "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "3.0-dev" } } } diff --git a/vendor/phpunit/php-file-iterator/phpunit.xml b/vendor/phpunit/php-file-iterator/phpunit.xml deleted file mode 100644 index 3e12be416..000000000 --- a/vendor/phpunit/php-file-iterator/phpunit.xml +++ /dev/null @@ -1,21 +0,0 @@ - - - - - tests - - - - - - src - - - diff --git a/vendor/phpunit/php-file-iterator/src/Facade.php b/vendor/phpunit/php-file-iterator/src/Facade.php index 2456e16d9..87b6588dd 100644 --- a/vendor/phpunit/php-file-iterator/src/Facade.php +++ b/vendor/phpunit/php-file-iterator/src/Facade.php @@ -1,35 +1,38 @@ - * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\FileIterator; +use const DIRECTORY_SEPARATOR; +use function array_unique; +use function count; +use function dirname; +use function explode; +use function is_file; +use function is_string; +use function realpath; +use function sort; + class Facade { /** * @param array|string $paths * @param array|string $suffixes * @param array|string $prefixes - * @param array $exclude - * @param bool $commonPath - * - * @return array */ public function getFilesAsArray($paths, $suffixes = '', $prefixes = '', array $exclude = [], bool $commonPath = false): array { - if (\is_string($paths)) { + if (is_string($paths)) { $paths = [$paths]; } - $factory = new Factory; - - $iterator = $factory->getFileIterator($paths, $suffixes, $prefixes, $exclude); + $iterator = (new Factory)->getFileIterator($paths, $suffixes, $prefixes, $exclude); $files = []; @@ -42,18 +45,18 @@ class Facade } foreach ($paths as $path) { - if (\is_file($path)) { - $files[] = \realpath($path); + if (is_file($path)) { + $files[] = realpath($path); } } - $files = \array_unique($files); - \sort($files); + $files = array_unique($files); + sort($files); if ($commonPath) { return [ - 'commonPath' => $this->getCommonPath($files), - 'files' => $files + 'commonPath' => $this->getCommonPath($files), + 'files' => $files, ]; } @@ -62,20 +65,20 @@ class Facade protected function getCommonPath(array $files): string { - $count = \count($files); + $count = count($files); if ($count === 0) { return ''; } if ($count === 1) { - return \dirname($files[0]) . DIRECTORY_SEPARATOR; + return dirname($files[0]) . DIRECTORY_SEPARATOR; } $_files = []; foreach ($files as $file) { - $_files[] = $_fileParts = \explode(DIRECTORY_SEPARATOR, $file); + $_files[] = $_fileParts = explode(DIRECTORY_SEPARATOR, $file); if (empty($_fileParts[0])) { $_fileParts[0] = DIRECTORY_SEPARATOR; diff --git a/vendor/phpunit/php-file-iterator/src/Factory.php b/vendor/phpunit/php-file-iterator/src/Factory.php index 02e2f385a..2620e3ec3 100644 --- a/vendor/phpunit/php-file-iterator/src/Factory.php +++ b/vendor/phpunit/php-file-iterator/src/Factory.php @@ -1,35 +1,43 @@ - * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\FileIterator; +use const GLOB_ONLYDIR; +use function array_filter; +use function array_map; +use function array_merge; +use function glob; +use function is_dir; +use function is_string; +use function realpath; +use AppendIterator; +use RecursiveDirectoryIterator; +use RecursiveIteratorIterator; + class Factory { /** * @param array|string $paths * @param array|string $suffixes * @param array|string $prefixes - * @param array $exclude - * - * @return \AppendIterator */ - public function getFileIterator($paths, $suffixes = '', $prefixes = '', array $exclude = []): \AppendIterator + public function getFileIterator($paths, $suffixes = '', $prefixes = '', array $exclude = []): AppendIterator { - if (\is_string($paths)) { + if (is_string($paths)) { $paths = [$paths]; } $paths = $this->getPathsAfterResolvingWildcards($paths); $exclude = $this->getPathsAfterResolvingWildcards($exclude); - if (\is_string($prefixes)) { + if (is_string($prefixes)) { if ($prefixes !== '') { $prefixes = [$prefixes]; } else { @@ -37,7 +45,7 @@ class Factory } } - if (\is_string($suffixes)) { + if (is_string($suffixes)) { if ($suffixes !== '') { $suffixes = [$suffixes]; } else { @@ -45,15 +53,15 @@ class Factory } } - $iterator = new \AppendIterator; + $iterator = new AppendIterator; foreach ($paths as $path) { - if (\is_dir($path)) { + if (is_dir($path)) { $iterator->append( new Iterator( $path, - new \RecursiveIteratorIterator( - new \RecursiveDirectoryIterator($path, \RecursiveDirectoryIterator::FOLLOW_SYMLINKS | \RecursiveDirectoryIterator::SKIP_DOTS) + new RecursiveIteratorIterator( + new RecursiveDirectoryIterator($path, RecursiveDirectoryIterator::FOLLOW_SYMLINKS | RecursiveDirectoryIterator::SKIP_DOTS) ), $suffixes, $prefixes, @@ -71,13 +79,13 @@ class Factory $_paths = []; foreach ($paths as $path) { - if ($locals = \glob($path, GLOB_ONLYDIR)) { - $_paths = \array_merge($_paths, \array_map('\realpath', $locals)); + if ($locals = glob($path, GLOB_ONLYDIR)) { + $_paths = array_merge($_paths, array_map('\realpath', $locals)); } else { - $_paths[] = \realpath($path); + $_paths[] = realpath($path); } } - return \array_filter($_paths); + return array_filter($_paths); } } diff --git a/vendor/phpunit/php-file-iterator/src/Iterator.php b/vendor/phpunit/php-file-iterator/src/Iterator.php index 84882d4a7..7eb82ad68 100644 --- a/vendor/phpunit/php-file-iterator/src/Iterator.php +++ b/vendor/phpunit/php-file-iterator/src/Iterator.php @@ -1,19 +1,29 @@ - * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\FileIterator; -class Iterator extends \FilterIterator +use function array_filter; +use function array_map; +use function preg_match; +use function realpath; +use function str_replace; +use function strlen; +use function strpos; +use function substr; +use FilterIterator; + +class Iterator extends FilterIterator { - const PREFIX = 0; - const SUFFIX = 1; + public const PREFIX = 0; + + public const SUFFIX = 1; /** * @var string @@ -35,29 +45,26 @@ class Iterator extends \FilterIterator */ private $exclude = []; - /** - * @param string $basePath - * @param \Iterator $iterator - * @param array $suffixes - * @param array $prefixes - * @param array $exclude - */ public function __construct(string $basePath, \Iterator $iterator, array $suffixes = [], array $prefixes = [], array $exclude = []) { - $this->basePath = \realpath($basePath); + $this->basePath = realpath($basePath); $this->prefixes = $prefixes; $this->suffixes = $suffixes; - $this->exclude = \array_filter(\array_map('realpath', $exclude)); + $this->exclude = array_filter(array_map('realpath', $exclude)); parent::__construct($iterator); } - public function accept() + public function accept(): bool { $current = $this->getInnerIterator()->current(); $filename = $current->getFilename(); $realPath = $current->getRealPath(); + if ($realPath === false) { + return false; + } + return $this->acceptPath($realPath) && $this->acceptPrefix($filename) && $this->acceptSuffix($filename); @@ -66,12 +73,12 @@ class Iterator extends \FilterIterator private function acceptPath(string $path): bool { // Filter files in hidden directories by checking path that is relative to the base path. - if (\preg_match('=/\.[^/]*/=', \str_replace($this->basePath, '', $path))) { + if (preg_match('=/\.[^/]*/=', str_replace($this->basePath, '', $path))) { return false; } foreach ($this->exclude as $exclude) { - if (\strpos($path, $exclude) === 0) { + if (strpos($path, $exclude) === 0) { return false; } } @@ -98,9 +105,9 @@ class Iterator extends \FilterIterator $matched = false; foreach ($subStrings as $string) { - if (($type === self::PREFIX && \strpos($filename, $string) === 0) || + if (($type === self::PREFIX && strpos($filename, $string) === 0) || ($type === self::SUFFIX && - \substr($filename, -1 * \strlen($string)) === $string)) { + substr($filename, -1 * strlen($string)) === $string)) { $matched = true; break; diff --git a/vendor/phpunit/php-file-iterator/tests/FactoryTest.php b/vendor/phpunit/php-file-iterator/tests/FactoryTest.php deleted file mode 100644 index ba4bdbf26..000000000 --- a/vendor/phpunit/php-file-iterator/tests/FactoryTest.php +++ /dev/null @@ -1,50 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\FileIterator; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\FileIterator\Factory - */ -class FactoryTest extends TestCase -{ - /** - * @var string - */ - private $root; - - /** - * @var Factory - */ - private $factory; - - protected function setUp(): void - { - $this->root = __DIR__; - $this->factory = new Factory; - } - - public function testFindFilesInTestDirectory(): void - { - $iterator = $this->factory->getFileIterator($this->root, 'Test.php'); - $files = \iterator_to_array($iterator); - - $this->assertGreaterThanOrEqual(1, \count($files)); - } - - public function testFindFilesWithExcludedNonExistingSubdirectory(): void - { - $iterator = $this->factory->getFileIterator($this->root, 'Test.php', '', [$this->root . '/nonExistingDir']); - $files = \iterator_to_array($iterator); - - $this->assertGreaterThanOrEqual(1, \count($files)); - } -} diff --git a/vendor/phpunit/php-invoker/ChangeLog.md b/vendor/phpunit/php-invoker/ChangeLog.md new file mode 100644 index 000000000..15cff1f11 --- /dev/null +++ b/vendor/phpunit/php-invoker/ChangeLog.md @@ -0,0 +1,48 @@ +# ChangeLog + +All notable changes are documented in this file using the [Keep a CHANGELOG](https://keepachangelog.com/) principles. + +## [3.1.1] - 2020-09-28 + +### Changed + +* Changed PHP version constraint in `composer.json` from `^7.3 || ^8.0` to `>=7.3` + +## [3.1.0] - 2020-08-06 + +### Changed + +* [#14](https://github.com/sebastianbergmann/php-invoker/pull/14): Clear alarm in `finally` block + +## [3.0.2] - 2020-06-26 + +### Added + +* This component is now supported on PHP 8 + +## [3.0.1] - 2020-06-15 + +### Changed + +* Tests etc. are now ignored for archive exports + +## [3.0.0] - 2020-02-07 + +### Added + +* Added `canInvokeWithTimeout()` method to check requirements for the functionality provided by this component to work + +### Changed + +* Moved `"ext-pcntl": "*"` requirement from `require` to `suggest` so that this component can be installed even if `ext/pcntl` is not available +* `invoke()` now raises an exception when the requirements for the functionality provided by this component to work are not met + +### Removed + +* This component is no longer supported on PHP 7.1 and PHP 7.2 + +[3.1.1]: https://github.com/sebastianbergmann/php-invoker/compare/3.1.0...3.1.1 +[3.1.0]: https://github.com/sebastianbergmann/php-invoker/compare/3.0.2...3.1.0 +[3.0.2]: https://github.com/sebastianbergmann/php-invoker/compare/3.0.1...3.0.2 +[3.0.1]: https://github.com/sebastianbergmann/php-invoker/compare/3.0.0...3.0.1 +[3.0.0]: https://github.com/sebastianbergmann/php-invoker/compare/2.0.0...3.0.0 diff --git a/vendor/phpunit/php-token-stream/LICENSE b/vendor/phpunit/php-invoker/LICENSE similarity index 94% rename from vendor/phpunit/php-token-stream/LICENSE rename to vendor/phpunit/php-invoker/LICENSE index a6d0c8c4f..4620776e1 100644 --- a/vendor/phpunit/php-token-stream/LICENSE +++ b/vendor/phpunit/php-invoker/LICENSE @@ -1,6 +1,6 @@ -php-token-stream +php-invoker -Copyright (c) 2009-2020, Sebastian Bergmann . +Copyright (c) 2011-2020, Sebastian Bergmann . All rights reserved. Redistribution and use in source and binary forms, with or without diff --git a/vendor/phpunit/php-token-stream/README.md b/vendor/phpunit/php-invoker/README.md similarity index 50% rename from vendor/phpunit/php-token-stream/README.md rename to vendor/phpunit/php-invoker/README.md index 162de8d19..ace07e5fd 100644 --- a/vendor/phpunit/php-token-stream/README.md +++ b/vendor/phpunit/php-invoker/README.md @@ -1,18 +1,18 @@ -# phpunit/php-token-stream +# phpunit/php-invoker -[![CI Status](https://github.com/sebastianbergmann/php-token-stream/workflows/CI/badge.svg)](https://github.com/sebastianbergmann/php-token-stream/actions) -[![Type Coverage](https://shepherd.dev/github/sebastianbergmann/php-token-stream/coverage.svg)](https://shepherd.dev/github/sebastianbergmann/php-token-stream) +[![CI Status](https://github.com/sebastianbergmann/php-invoker/workflows/CI/badge.svg)](https://github.com/sebastianbergmann/php-invoker/actions) +[![Type Coverage](https://shepherd.dev/github/sebastianbergmann/php-invoker/coverage.svg)](https://shepherd.dev/github/sebastianbergmann/php-invoker) ## Installation You can add this library as a local, per-project dependency to your project using [Composer](https://getcomposer.org/): ``` -composer require phpunit/php-token-stream +composer require phpunit/php-invoker ``` If you only need this library during development, for instance to run your project's test suite, then you should add it as a development-time dependency: ``` -composer require --dev phpunit/php-token-stream +composer require --dev phpunit/php-invoker ``` diff --git a/vendor/phpunit/php-invoker/composer.json b/vendor/phpunit/php-invoker/composer.json new file mode 100644 index 000000000..6c007cd81 --- /dev/null +++ b/vendor/phpunit/php-invoker/composer.json @@ -0,0 +1,54 @@ +{ + "name": "phpunit/php-invoker", + "description": "Invoke callables with a timeout", + "type": "library", + "keywords": [ + "process" + ], + "homepage": "https://github.com/sebastianbergmann/php-invoker/", + "license": "BSD-3-Clause", + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-invoker/issues" + }, + "prefer-stable": true, + "config": { + "platform": { + "php": "7.3.0" + }, + "optimize-autoloader": true, + "sort-packages": true + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "ext-pcntl": "*", + "phpunit/phpunit": "^9.3" + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "autoload-dev": { + "classmap": [ + "tests/_fixture/" + ] + }, + "suggest": { + "ext-pcntl": "*" + }, + "extra": { + "branch-alias": { + "dev-master": "3.1-dev" + } + } +} + diff --git a/vendor/phpunit/php-invoker/src/Invoker.php b/vendor/phpunit/php-invoker/src/Invoker.php new file mode 100644 index 000000000..656f4180a --- /dev/null +++ b/vendor/phpunit/php-invoker/src/Invoker.php @@ -0,0 +1,69 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\Invoker; + +use const SIGALRM; +use function call_user_func_array; +use function function_exists; +use function pcntl_alarm; +use function pcntl_async_signals; +use function pcntl_signal; +use function sprintf; +use Throwable; + +final class Invoker +{ + /** + * @var int + */ + private $timeout; + + /** + * @throws Throwable + */ + public function invoke(callable $callable, array $arguments, int $timeout) + { + if (!$this->canInvokeWithTimeout()) { + throw new ProcessControlExtensionNotLoadedException( + 'The pcntl (process control) extension for PHP is required' + ); + } + + pcntl_signal( + SIGALRM, + function (): void { + throw new TimeoutException( + sprintf( + 'Execution aborted after %d second%s', + $this->timeout, + $this->timeout === 1 ? '' : 's' + ) + ); + }, + true + ); + + $this->timeout = $timeout; + + pcntl_async_signals(true); + pcntl_alarm($timeout); + + try { + return call_user_func_array($callable, $arguments); + } finally { + pcntl_alarm(0); + } + } + + public function canInvokeWithTimeout(): bool + { + return function_exists('pcntl_signal') && function_exists('pcntl_async_signals') && function_exists('pcntl_alarm'); + } +} diff --git a/vendor/sebastian/global-state/tests/_fixture/BlacklistedInterface.php b/vendor/phpunit/php-invoker/src/exceptions/Exception.php similarity index 62% rename from vendor/sebastian/global-state/tests/_fixture/BlacklistedInterface.php rename to vendor/phpunit/php-invoker/src/exceptions/Exception.php index f531a3aba..6ecbf5dd3 100644 --- a/vendor/sebastian/global-state/tests/_fixture/BlacklistedInterface.php +++ b/vendor/phpunit/php-invoker/src/exceptions/Exception.php @@ -1,14 +1,16 @@ * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ -namespace SebastianBergmann\GlobalState\TestFixture; +namespace SebastianBergmann\Invoker; -interface BlacklistedInterface +use Throwable; + +interface Exception extends Throwable { } diff --git a/vendor/phpunit/php-invoker/src/exceptions/ProcessControlExtensionNotLoadedException.php b/vendor/phpunit/php-invoker/src/exceptions/ProcessControlExtensionNotLoadedException.php new file mode 100644 index 000000000..ef42fd195 --- /dev/null +++ b/vendor/phpunit/php-invoker/src/exceptions/ProcessControlExtensionNotLoadedException.php @@ -0,0 +1,16 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\Invoker; + +use RuntimeException; + +final class ProcessControlExtensionNotLoadedException extends RuntimeException implements Exception +{ +} diff --git a/vendor/phpunit/php-invoker/src/exceptions/TimeoutException.php b/vendor/phpunit/php-invoker/src/exceptions/TimeoutException.php new file mode 100644 index 000000000..2f7631c0e --- /dev/null +++ b/vendor/phpunit/php-invoker/src/exceptions/TimeoutException.php @@ -0,0 +1,16 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\Invoker; + +use RuntimeException; + +final class TimeoutException extends RuntimeException implements Exception +{ +} diff --git a/vendor/phpunit/php-text-template/.gitattributes b/vendor/phpunit/php-text-template/.gitattributes deleted file mode 100644 index 461090b7e..000000000 --- a/vendor/phpunit/php-text-template/.gitattributes +++ /dev/null @@ -1 +0,0 @@ -*.php diff=php diff --git a/vendor/phpunit/php-text-template/.gitignore b/vendor/phpunit/php-text-template/.gitignore deleted file mode 100644 index c59921248..000000000 --- a/vendor/phpunit/php-text-template/.gitignore +++ /dev/null @@ -1,5 +0,0 @@ -/composer.lock -/composer.phar -/.idea -/vendor - diff --git a/vendor/phpunit/php-text-template/.psalm/baseline.xml b/vendor/phpunit/php-text-template/.psalm/baseline.xml new file mode 100644 index 000000000..77e688e07 --- /dev/null +++ b/vendor/phpunit/php-text-template/.psalm/baseline.xml @@ -0,0 +1,2 @@ + + diff --git a/vendor/phpunit/php-text-template/.psalm/config.xml b/vendor/phpunit/php-text-template/.psalm/config.xml new file mode 100644 index 000000000..2a4b16f22 --- /dev/null +++ b/vendor/phpunit/php-text-template/.psalm/config.xml @@ -0,0 +1,16 @@ + + + + + + + + + diff --git a/vendor/phpunit/php-text-template/ChangeLog.md b/vendor/phpunit/php-text-template/ChangeLog.md new file mode 100644 index 000000000..32a48a7a1 --- /dev/null +++ b/vendor/phpunit/php-text-template/ChangeLog.md @@ -0,0 +1,43 @@ +# ChangeLog + +All notable changes are documented in this file using the [Keep a CHANGELOG](http://keepachangelog.com/) principles. + +## [2.0.4] - 2020-10-26 + +### Fixed + +* `SebastianBergmann\Template\Exception` now correctly extends `\Throwable` + +## [2.0.3] - 2020-09-28 + +### Changed + +* Changed PHP version constraint in `composer.json` from `^7.3 || ^8.0` to `>=7.3` + +## [2.0.2] - 2020-06-26 + +### Added + +* This component is now supported on PHP 8 + +## [2.0.1] - 2020-06-15 + +### Changed + +* Tests etc. are now ignored for archive exports + +## [2.0.0] - 2020-02-07 + +### Changed + +* The `Text_Template` class was renamed to `SebastianBergmann\Template\Template` + +### Removed + +* Removed support for PHP 5.3, PHP 5.4, PHP 5.5, PHP 5.6, PHP 7.0, PHP 7.1, and PHP 7.2 + +[2.0.4]: https://github.com/sebastianbergmann/php-text-template/compare/2.0.3...2.0.4 +[2.0.3]: https://github.com/sebastianbergmann/php-text-template/compare/2.0.2...2.0.3 +[2.0.2]: https://github.com/sebastianbergmann/php-text-template/compare/2.0.1...2.0.2 +[2.0.1]: https://github.com/sebastianbergmann/php-text-template/compare/2.0.0...2.0.1 +[2.0.0]: https://github.com/sebastianbergmann/php-text-template/compare/1.2.1...2.0.0 diff --git a/vendor/phpunit/php-text-template/LICENSE b/vendor/phpunit/php-text-template/LICENSE index 9f9a32d9b..6db5566c8 100644 --- a/vendor/phpunit/php-text-template/LICENSE +++ b/vendor/phpunit/php-text-template/LICENSE @@ -1,6 +1,6 @@ -Text_Template +phpunit/php-text-template -Copyright (c) 2009-2015, Sebastian Bergmann . +Copyright (c) 2009-2020, Sebastian Bergmann . All rights reserved. Redistribution and use in source and binary forms, with or without diff --git a/vendor/phpunit/php-text-template/README.md b/vendor/phpunit/php-text-template/README.md index ec8f59360..b28659354 100644 --- a/vendor/phpunit/php-text-template/README.md +++ b/vendor/phpunit/php-text-template/README.md @@ -2,13 +2,11 @@ ## Installation -## Installation +You can add this library as a local, per-project dependency to your project using [Composer](https://getcomposer.org/): -To add this package as a local, per-project dependency to your project, simply add a dependency on `phpunit/php-text-template` to your project's `composer.json` file. Here is a minimal example of a `composer.json` file that just defines a dependency on Text_Template: + composer require phpunit/php-text-template - { - "require": { - "phpunit/php-text-template": "~1.2" - } - } +If you only need this library during development, for instance to run your project's test suite, then you should add it as a development-time dependency: + + composer require --dev phpunit/php-text-template diff --git a/vendor/phpunit/php-text-template/composer.json b/vendor/phpunit/php-text-template/composer.json index a5779c835..a51b34b95 100644 --- a/vendor/phpunit/php-text-template/composer.json +++ b/vendor/phpunit/php-text-template/composer.json @@ -17,13 +17,27 @@ "support": { "issues": "https://github.com/sebastianbergmann/php-text-template/issues" }, + "config": { + "platform": { + "php": "7.3.0" + }, + "optimize-autoloader": true, + "sort-packages": true + }, "require": { - "php": ">=5.3.3" + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" }, "autoload": { "classmap": [ "src/" ] + }, + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" + } } } - diff --git a/vendor/phpunit/php-text-template/src/Template.php b/vendor/phpunit/php-text-template/src/Template.php index 9eb39ad5d..25e29ea97 100644 --- a/vendor/phpunit/php-text-template/src/Template.php +++ b/vendor/phpunit/php-text-template/src/Template.php @@ -1,85 +1,76 @@ - * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ +namespace SebastianBergmann\Template; -/** - * A simple template engine. - * - * @since Class available since Release 1.0.0 - */ -class Text_Template +use function array_merge; +use function file_exists; +use function file_get_contents; +use function file_put_contents; +use function sprintf; +use function str_replace; + +final class Template { /** * @var string */ - protected $template = ''; + private $template = ''; /** * @var string */ - protected $openDelimiter = '{'; + private $openDelimiter; /** * @var string */ - protected $closeDelimiter = '}'; + private $closeDelimiter; /** * @var array */ - protected $values = array(); + private $values = []; /** - * Constructor. - * - * @param string $file * @throws InvalidArgumentException */ - public function __construct($file = '', $openDelimiter = '{', $closeDelimiter = '}') + public function __construct(string $file = '', string $openDelimiter = '{', string $closeDelimiter = '}') { $this->setFile($file); + $this->openDelimiter = $openDelimiter; $this->closeDelimiter = $closeDelimiter; } /** - * Sets the template file. - * - * @param string $file * @throws InvalidArgumentException */ - public function setFile($file) + public function setFile(string $file): void { $distFile = $file . '.dist'; if (file_exists($file)) { $this->template = file_get_contents($file); - } - - else if (file_exists($distFile)) { + } elseif (file_exists($distFile)) { $this->template = file_get_contents($distFile); - } - - else { + } else { throw new InvalidArgumentException( - 'Template file could not be loaded.' + sprintf( + 'Failed to load template "%s"', + $file + ) ); } } - /** - * Sets one or more template variables. - * - * @param array $values - * @param bool $merge - */ - public function setVar(array $values, $merge = TRUE) + public function setVar(array $values, bool $merge = true): void { if (!$merge || empty($this->values)) { $this->values = $values; @@ -88,14 +79,9 @@ class Text_Template } } - /** - * Renders the template and returns the result. - * - * @return string - */ - public function render() + public function render(): string { - $keys = array(); + $keys = []; foreach ($this->values as $key => $value) { $keys[] = $this->openDelimiter . $key . $this->closeDelimiter; @@ -105,31 +91,17 @@ class Text_Template } /** - * Renders the template and writes the result to a file. - * - * @param string $target + * @codeCoverageIgnore */ - public function renderTo($target) + public function renderTo(string $target): void { - $fp = @fopen($target, 'wt'); - - if ($fp) { - fwrite($fp, $this->render()); - fclose($fp); - } else { - $error = error_get_last(); - + if (!file_put_contents($target, $this->render())) { throw new RuntimeException( - sprintf( - 'Could not write to %s: %s', - $target, - substr( - $error['message'], - strpos($error['message'], ':') + 2 + sprintf( + 'Writing rendered result to "%s" failed', + $target ) - ) ); } } } - diff --git a/vendor/phpunit/php-text-template/src/exceptions/Exception.php b/vendor/phpunit/php-text-template/src/exceptions/Exception.php new file mode 100644 index 000000000..d7dc5cbea --- /dev/null +++ b/vendor/phpunit/php-text-template/src/exceptions/Exception.php @@ -0,0 +1,16 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\Template; + +use Throwable; + +interface Exception extends Throwable +{ +} diff --git a/vendor/phpunit/php-text-template/src/exceptions/InvalidArgumentException.php b/vendor/phpunit/php-text-template/src/exceptions/InvalidArgumentException.php new file mode 100644 index 000000000..10e1cd11f --- /dev/null +++ b/vendor/phpunit/php-text-template/src/exceptions/InvalidArgumentException.php @@ -0,0 +1,14 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\Template; + +final class InvalidArgumentException extends \InvalidArgumentException implements Exception +{ +} diff --git a/vendor/phpunit/php-text-template/src/exceptions/RuntimeException.php b/vendor/phpunit/php-text-template/src/exceptions/RuntimeException.php new file mode 100644 index 000000000..131498e61 --- /dev/null +++ b/vendor/phpunit/php-text-template/src/exceptions/RuntimeException.php @@ -0,0 +1,16 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\Template; + +use InvalidArgumentException; + +final class RuntimeException extends InvalidArgumentException implements Exception +{ +} diff --git a/vendor/phpunit/php-timer/.gitattributes b/vendor/phpunit/php-timer/.gitattributes deleted file mode 100644 index 461090b7e..000000000 --- a/vendor/phpunit/php-timer/.gitattributes +++ /dev/null @@ -1 +0,0 @@ -*.php diff=php diff --git a/vendor/phpunit/php-timer/.github/FUNDING.yml b/vendor/phpunit/php-timer/.github/FUNDING.yml deleted file mode 100644 index b19ea81a0..000000000 --- a/vendor/phpunit/php-timer/.github/FUNDING.yml +++ /dev/null @@ -1 +0,0 @@ -patreon: s_bergmann diff --git a/vendor/phpunit/php-timer/.github/stale.yml b/vendor/phpunit/php-timer/.github/stale.yml deleted file mode 100644 index 4eadca327..000000000 --- a/vendor/phpunit/php-timer/.github/stale.yml +++ /dev/null @@ -1,40 +0,0 @@ -# Configuration for probot-stale - https://github.com/probot/stale - -# Number of days of inactivity before an Issue or Pull Request becomes stale -daysUntilStale: 60 - -# Number of days of inactivity before a stale Issue or Pull Request is closed. -# Set to false to disable. If disabled, issues still need to be closed manually, but will remain marked as stale. -daysUntilClose: 7 - -# Issues or Pull Requests with these labels will never be considered stale. Set to `[]` to disable -exemptLabels: - - enhancement - -# Set to true to ignore issues in a project (defaults to false) -exemptProjects: false - -# Set to true to ignore issues in a milestone (defaults to false) -exemptMilestones: false - -# Label to use when marking as stale -staleLabel: stale - -# Comment to post when marking as stale. Set to `false` to disable -markComment: > - This issue has been automatically marked as stale because it has not had activity within the last 60 days. It will be closed after 7 days if no further activity occurs. Thank you for your contributions. - -# Comment to post when removing the stale label. -# unmarkComment: > -# Your comment here. - -# Comment to post when closing a stale Issue or Pull Request. -closeComment: > - This issue has been automatically closed because it has not had activity since it was marked as stale. Thank you for your contributions. - -# Limit the number of actions per hour, from 1-30. Default is 30 -limitPerRun: 30 - -# Limit to only `issues` or `pulls` -only: issues - diff --git a/vendor/phpunit/php-timer/.gitignore b/vendor/phpunit/php-timer/.gitignore deleted file mode 100644 index 953d2a219..000000000 --- a/vendor/phpunit/php-timer/.gitignore +++ /dev/null @@ -1,5 +0,0 @@ -/.idea -/.php_cs.cache -/vendor -/composer.lock - diff --git a/vendor/phpunit/php-timer/.php_cs.dist b/vendor/phpunit/php-timer/.php_cs.dist deleted file mode 100644 index c4422644c..000000000 --- a/vendor/phpunit/php-timer/.php_cs.dist +++ /dev/null @@ -1,197 +0,0 @@ - - -For the full copyright and license information, please view the LICENSE -file that was distributed with this source code. -EOF; - -return PhpCsFixer\Config::create() - ->setRiskyAllowed(true) - ->setRules( - [ - 'align_multiline_comment' => true, - 'array_indentation' => true, - 'array_syntax' => ['syntax' => 'short'], - 'binary_operator_spaces' => [ - 'operators' => [ - '=' => 'align', - '=>' => 'align', - ], - ], - 'blank_line_after_namespace' => true, - 'blank_line_before_statement' => [ - 'statements' => [ - 'break', - 'continue', - 'declare', - 'do', - 'for', - 'foreach', - 'if', - 'include', - 'include_once', - 'require', - 'require_once', - 'return', - 'switch', - 'throw', - 'try', - 'while', - 'yield', - ], - ], - 'braces' => true, - 'cast_spaces' => true, - 'class_attributes_separation' => ['elements' => ['const', 'method', 'property']], - 'combine_consecutive_issets' => true, - 'combine_consecutive_unsets' => true, - 'compact_nullable_typehint' => true, - 'concat_space' => ['spacing' => 'one'], - 'declare_equal_normalize' => ['space' => 'none'], - 'declare_strict_types' => true, - 'dir_constant' => true, - 'elseif' => true, - 'encoding' => true, - 'full_opening_tag' => true, - 'function_declaration' => true, - 'header_comment' => ['header' => $header, 'separate' => 'none'], - 'indentation_type' => true, - 'is_null' => true, - 'line_ending' => true, - 'list_syntax' => ['syntax' => 'short'], - 'logical_operators' => true, - 'lowercase_cast' => true, - 'lowercase_constants' => true, - 'lowercase_keywords' => true, - 'lowercase_static_reference' => true, - 'magic_constant_casing' => true, - 'method_argument_space' => ['ensure_fully_multiline' => true], - 'modernize_types_casting' => true, - 'multiline_comment_opening_closing' => true, - 'multiline_whitespace_before_semicolons' => true, - 'native_constant_invocation' => true, - 'native_function_casing' => true, - 'native_function_invocation' => true, - 'new_with_braces' => false, - 'no_alias_functions' => true, - 'no_alternative_syntax' => true, - 'no_blank_lines_after_class_opening' => true, - 'no_blank_lines_after_phpdoc' => true, - 'no_blank_lines_before_namespace' => true, - 'no_closing_tag' => true, - 'no_empty_comment' => true, - 'no_empty_phpdoc' => true, - 'no_empty_statement' => true, - 'no_extra_blank_lines' => true, - 'no_homoglyph_names' => true, - 'no_leading_import_slash' => true, - 'no_leading_namespace_whitespace' => true, - 'no_mixed_echo_print' => ['use' => 'print'], - 'no_multiline_whitespace_around_double_arrow' => true, - 'no_null_property_initialization' => true, - 'no_php4_constructor' => true, - 'no_short_bool_cast' => true, - 'no_short_echo_tag' => true, - 'no_singleline_whitespace_before_semicolons' => true, - 'no_spaces_after_function_name' => true, - 'no_spaces_inside_parenthesis' => true, - 'no_superfluous_elseif' => true, - 'no_superfluous_phpdoc_tags' => true, - 'no_trailing_comma_in_list_call' => true, - 'no_trailing_comma_in_singleline_array' => true, - 'no_trailing_whitespace' => true, - 'no_trailing_whitespace_in_comment' => true, - 'no_unneeded_control_parentheses' => true, - 'no_unneeded_curly_braces' => true, - 'no_unneeded_final_method' => true, - 'no_unreachable_default_argument_value' => true, - 'no_unset_on_property' => true, - 'no_unused_imports' => true, - 'no_useless_else' => true, - 'no_useless_return' => true, - 'no_whitespace_before_comma_in_array' => true, - 'no_whitespace_in_blank_line' => true, - 'non_printable_character' => true, - 'normalize_index_brace' => true, - 'object_operator_without_whitespace' => true, - 'ordered_class_elements' => [ - 'order' => [ - 'use_trait', - 'constant_public', - 'constant_protected', - 'constant_private', - 'property_public_static', - 'property_protected_static', - 'property_private_static', - 'property_public', - 'property_protected', - 'property_private', - 'method_public_static', - 'construct', - 'destruct', - 'magic', - 'phpunit', - 'method_public', - 'method_protected', - 'method_private', - 'method_protected_static', - 'method_private_static', - ], - ], - 'ordered_imports' => true, - 'phpdoc_add_missing_param_annotation' => true, - 'phpdoc_align' => true, - 'phpdoc_annotation_without_dot' => true, - 'phpdoc_indent' => true, - 'phpdoc_no_access' => true, - 'phpdoc_no_empty_return' => true, - 'phpdoc_no_package' => true, - 'phpdoc_order' => true, - 'phpdoc_return_self_reference' => true, - 'phpdoc_scalar' => true, - 'phpdoc_separation' => true, - 'phpdoc_single_line_var_spacing' => true, - 'phpdoc_to_comment' => true, - 'phpdoc_trim' => true, - 'phpdoc_trim_consecutive_blank_line_separation' => true, - 'phpdoc_types' => ['groups' => ['simple', 'meta']], - 'phpdoc_types_order' => true, - 'phpdoc_var_without_name' => true, - 'pow_to_exponentiation' => true, - 'protected_to_private' => true, - 'return_assignment' => true, - 'return_type_declaration' => ['space_before' => 'none'], - 'self_accessor' => true, - 'semicolon_after_instruction' => true, - 'set_type_to_cast' => true, - 'short_scalar_cast' => true, - 'simplified_null_return' => true, - 'single_blank_line_at_eof' => true, - 'single_import_per_statement' => true, - 'single_line_after_imports' => true, - 'single_quote' => true, - 'standardize_not_equals' => true, - 'ternary_to_null_coalescing' => true, - 'trailing_comma_in_multiline_array' => true, - 'trim_array_spaces' => true, - 'unary_operator_spaces' => true, - 'visibility_required' => [ - 'elements' => [ - 'const', - 'method', - 'property', - ], - ], - 'void_return' => true, - 'whitespace_after_comma_in_array' => true, - ] - ) - ->setFinder( - PhpCsFixer\Finder::create() - ->files() - ->in(__DIR__ . '/src') - ->in(__DIR__ . '/tests') - ); diff --git a/vendor/phpunit/php-timer/.psalm/baseline.xml b/vendor/phpunit/php-timer/.psalm/baseline.xml new file mode 100644 index 000000000..77e688e07 --- /dev/null +++ b/vendor/phpunit/php-timer/.psalm/baseline.xml @@ -0,0 +1,2 @@ + + diff --git a/vendor/phpunit/php-timer/.psalm/config.xml b/vendor/phpunit/php-timer/.psalm/config.xml new file mode 100644 index 000000000..15abef058 --- /dev/null +++ b/vendor/phpunit/php-timer/.psalm/config.xml @@ -0,0 +1,16 @@ + + + + + + + + + diff --git a/vendor/phpunit/php-timer/.travis.yml b/vendor/phpunit/php-timer/.travis.yml deleted file mode 100644 index a217292fd..000000000 --- a/vendor/phpunit/php-timer/.travis.yml +++ /dev/null @@ -1,23 +0,0 @@ -language: php - -php: - - 7.1 - - 7.2 - - 7.3 - - 7.4snapshot - -before_install: - - composer self-update - - composer clear-cache - -install: - - travis_retry composer update --no-interaction --no-ansi --no-progress --no-suggest - -script: - - ./vendor/bin/phpunit --coverage-clover=coverage.xml - -after_success: - - bash <(curl -s https://codecov.io/bash) - -notifications: - email: false diff --git a/vendor/phpunit/php-timer/ChangeLog.md b/vendor/phpunit/php-timer/ChangeLog.md index 378d4539f..34ef7d1d7 100644 --- a/vendor/phpunit/php-timer/ChangeLog.md +++ b/vendor/phpunit/php-timer/ChangeLog.md @@ -2,17 +2,102 @@ All notable changes are documented in this file using the [Keep a CHANGELOG](http://keepachangelog.com/) principles. -## [2.1.3] - 2020-11-30 +## [5.0.3] - 2020-10-26 + +### Fixed + +* `SebastianBergmann\Timer\Exception` now correctly extends `\Throwable` + +## [5.0.2] - 2020-09-28 ### Changed -* Changed PHP version constraint in `composer.json` from `^7.1` to `>=7.1` +* Changed PHP version constraint in `composer.json` from `^7.3 || ^8.0` to `>=7.3` + +## [5.0.1] - 2020-06-26 + +### Added + +* This component is now supported on PHP 8 + +## [5.0.0] - 2020-06-07 + +### Changed + +* Parameter type for `SebastianBergmann\Timer\Duration::fromMicroseconds()` was changed from `int` to `float` +* Parameter type for `SebastianBergmann\Timer\Duration::fromNanoseconds()` was changed from `int` to `float` +* Return type for `SebastianBergmann\Timer\Duration::asNanoseconds()` was changed from `int` to `float` + +### Fixed + +* [#31](https://github.com/sebastianbergmann/php-timer/issues/31): Type Error on 32-bit systems (where `hrtime()` returns `float` instead of `int`) + +## [4.0.0] - 2020-06-01 + +### Added + +* Introduced `Duration` value object for encapsulating a duration with nanosecond granularity +* Introduced `ResourceUsageFormatter` object for formatting resource usage with option to explicitly pass a duration (instead of looking at the unreliable `$_SERVER['REQUEST_TIME_FLOAT']` variable) + +### Changed + +* The methods of `Timer` are no longer static +* `Timer::stop()` now returns a `Duration` value object + +### Removed + +* Functionality that is now implemented in `Duration` and `ResourceUsageFormatter` has been removed from `Timer` + +## [3.1.4] - 2020-04-20 + +### Changed + +* `Timer::timeSinceStartOfRequest()` no longer tries `$_SERVER['REQUEST_TIME']` when `$_SERVER['REQUEST_TIME_FLOAT']` is not available (`$_SERVER['REQUEST_TIME_FLOAT']` was added in PHP 5.4 and this library requires PHP 7.3) +* Improved exception messages when `$_SERVER['REQUEST_TIME_FLOAT']` is not set or is not of type `float` + +### Changed + +## [3.1.3] - 2020-04-20 + +### Changed + +* `Timer::timeSinceStartOfRequest()` now raises an exception if `$_SERVER['REQUEST_TIME_FLOAT']` does not contain a `float` (or `$_SERVER['REQUEST_TIME']` does not contain an `int`) + +## [3.1.2] - 2020-04-17 + +### Changed + +* Improved the fix for [#30](https://github.com/sebastianbergmann/php-timer/issues/30) and restored usage of `hrtime()` + +## [3.1.1] - 2020-04-17 + +### Fixed + +* [#30](https://github.com/sebastianbergmann/php-timer/issues/30): Resolution of time returned by `Timer::stop()` is different than before (this reverts using `hrtime()` instead of `microtime()`) + +## [3.1.0] - 2020-04-17 + +### Added + +* `Timer::secondsToShortTimeString()` as alternative to `Timer::secondsToTimeString()` + +### Changed + +* `Timer::start()` and `Timer::stop()` now use `hrtime()` (high resolution monotonic timer) instead of `microtime()` +* `Timer::timeSinceStartOfRequest()` now uses `Timer::secondsToShortTimeString()` for time formatting +* Improved formatting of `Timer::secondsToTimeString()` result + +## [3.0.0] - 2020-02-07 + +### Removed + +* This component is no longer supported on PHP 7.1 and PHP 7.2 ## [2.1.2] - 2019-06-07 ### Fixed -* Fixed [#21](https://github.com/sebastianbergmann/php-timer/pull/3352): Formatting of memory consumption does not work on 32bit systems +* [#21](https://github.com/sebastianbergmann/php-timer/pull/21): Formatting of memory consumption does not work on 32bit systems ## [2.1.1] - 2019-02-20 @@ -36,8 +121,18 @@ All notable changes are documented in this file using the [Keep a CHANGELOG](htt * This component is no longer supported on PHP 5.3, PHP 5.4, PHP 5.5, PHP 5.6, and PHP 7.0 -[2.1.3]: https://github.com/sebastianbergmann/diff/compare/2.1.2...2.1.3 -[2.1.2]: https://github.com/sebastianbergmann/diff/compare/2.1.1...2.1.2 -[2.1.1]: https://github.com/sebastianbergmann/diff/compare/2.1.0...2.1.1 -[2.1.0]: https://github.com/sebastianbergmann/diff/compare/2.0.0...2.1.0 -[2.0.0]: https://github.com/sebastianbergmann/diff/compare/1.0.9...2.0.0 +[5.0.3]: https://github.com/sebastianbergmann/php-timer/compare/5.0.2...5.0.3 +[5.0.2]: https://github.com/sebastianbergmann/php-timer/compare/5.0.1...5.0.2 +[5.0.1]: https://github.com/sebastianbergmann/php-timer/compare/5.0.0...5.0.1 +[5.0.0]: https://github.com/sebastianbergmann/php-timer/compare/4.0.0...5.0.0 +[4.0.0]: https://github.com/sebastianbergmann/php-timer/compare/3.1.4...4.0.0 +[3.1.4]: https://github.com/sebastianbergmann/php-timer/compare/3.1.3...3.1.4 +[3.1.3]: https://github.com/sebastianbergmann/php-timer/compare/3.1.2...3.1.3 +[3.1.2]: https://github.com/sebastianbergmann/php-timer/compare/3.1.1...3.1.2 +[3.1.1]: https://github.com/sebastianbergmann/php-timer/compare/3.1.0...3.1.1 +[3.1.0]: https://github.com/sebastianbergmann/php-timer/compare/3.0.0...3.1.0 +[3.0.0]: https://github.com/sebastianbergmann/php-timer/compare/2.1.2...3.0.0 +[2.1.2]: https://github.com/sebastianbergmann/php-timer/compare/2.1.1...2.1.2 +[2.1.1]: https://github.com/sebastianbergmann/php-timer/compare/2.1.0...2.1.1 +[2.1.0]: https://github.com/sebastianbergmann/php-timer/compare/2.0.0...2.1.0 +[2.0.0]: https://github.com/sebastianbergmann/php-timer/compare/1.0.9...2.0.0 diff --git a/vendor/phpunit/php-timer/LICENSE b/vendor/phpunit/php-timer/LICENSE index a4eb9446b..4193d8ae6 100644 --- a/vendor/phpunit/php-timer/LICENSE +++ b/vendor/phpunit/php-timer/LICENSE @@ -1,6 +1,6 @@ phpunit/php-timer -Copyright (c) 2010-2019, Sebastian Bergmann . +Copyright (c) 2010-2020, Sebastian Bergmann . All rights reserved. Redistribution and use in source and binary forms, with or without diff --git a/vendor/phpunit/php-timer/README.md b/vendor/phpunit/php-timer/README.md index 61725c20b..a7d1e70de 100644 --- a/vendor/phpunit/php-timer/README.md +++ b/vendor/phpunit/php-timer/README.md @@ -1,49 +1,104 @@ -[![Build Status](https://travis-ci.org/sebastianbergmann/php-timer.svg?branch=master)](https://travis-ci.org/sebastianbergmann/php-timer) - # phpunit/php-timer +[![CI Status](https://github.com/sebastianbergmann/php-timer/workflows/CI/badge.svg)](https://github.com/sebastianbergmann/php-timer/actions) +[![Type Coverage](https://shepherd.dev/github/sebastianbergmann/php-timer/coverage.svg)](https://shepherd.dev/github/sebastianbergmann/php-timer) + Utility class for timing things, factored out of PHPUnit into a stand-alone component. ## Installation You can add this library as a local, per-project dependency to your project using [Composer](https://getcomposer.org/): - composer require phpunit/php-timer +``` +composer require phpunit/php-timer +``` If you only need this library during development, for instance to run your project's test suite, then you should add it as a development-time dependency: - composer require --dev phpunit/php-timer +``` +composer require --dev phpunit/php-timer +``` ## Usage ### Basic Timing ```php +require __DIR__ . '/vendor/autoload.php'; + use SebastianBergmann\Timer\Timer; -Timer::start(); +$timer = new Timer; -// ... +$timer->start(); -$time = Timer::stop(); -var_dump($time); +foreach (\range(0, 100000) as $i) { + // ... +} -print Timer::secondsToTimeString($time); +$duration = $timer->stop(); + +var_dump(get_class($duration)); +var_dump($duration->asString()); +var_dump($duration->asSeconds()); +var_dump($duration->asMilliseconds()); +var_dump($duration->asMicroseconds()); +var_dump($duration->asNanoseconds()); ``` The code above yields the output below: - double(1.0967254638672E-5) - 0 ms +``` +string(32) "SebastianBergmann\Timer\Duration" +string(9) "00:00.002" +float(0.002851062) +float(2.851062) +float(2851.062) +int(2851062) +``` -### Resource Consumption Since PHP Startup +### Resource Consumption + +#### Explicit duration ```php +require __DIR__ . '/vendor/autoload.php'; + +use SebastianBergmann\Timer\ResourceUsageFormatter; use SebastianBergmann\Timer\Timer; -print Timer::resourceUsage(); +$timer = new Timer; +$timer->start(); + +foreach (\range(0, 100000) as $i) { + // ... +} + +print (new ResourceUsageFormatter)->resourceUsage($timer->stop()); ``` The code above yields the output below: - Time: 0 ms, Memory: 0.50MB +``` +Time: 00:00.002, Memory: 6.00 MB +``` + +#### Duration since PHP Startup (using unreliable `$_SERVER['REQUEST_TIME_FLOAT']`) + +```php +require __DIR__ . '/vendor/autoload.php'; + +use SebastianBergmann\Timer\ResourceUsageFormatter; + +foreach (\range(0, 100000) as $i) { + // ... +} + +print (new ResourceUsageFormatter)->resourceUsageSinceStartOfRequest(); +``` + +The code above yields the output below: + +``` +Time: 00:00.002, Memory: 6.00 MB +``` diff --git a/vendor/phpunit/php-timer/build.xml b/vendor/phpunit/php-timer/build.xml deleted file mode 100644 index b8d325661..000000000 --- a/vendor/phpunit/php-timer/build.xml +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - - - - - - - - - - - - - - - diff --git a/vendor/phpunit/php-timer/composer.json b/vendor/phpunit/php-timer/composer.json index 340d944b3..001701c24 100644 --- a/vendor/phpunit/php-timer/composer.json +++ b/vendor/phpunit/php-timer/composer.json @@ -19,12 +19,15 @@ }, "prefer-stable": true, "require": { - "php": ">=7.1" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^8.5" + "phpunit/phpunit": "^9.3" }, "config": { + "platform": { + "php": "7.3.0" + }, "optimize-autoloader": true, "sort-packages": true }, @@ -35,7 +38,7 @@ }, "extra": { "branch-alias": { - "dev-master": "2.1-dev" + "dev-master": "5.0-dev" } } } diff --git a/vendor/phpunit/php-timer/phpunit.xml b/vendor/phpunit/php-timer/phpunit.xml deleted file mode 100644 index 28a95de47..000000000 --- a/vendor/phpunit/php-timer/phpunit.xml +++ /dev/null @@ -1,19 +0,0 @@ - - - - tests - - - - - src - - - diff --git a/vendor/phpunit/php-timer/src/Duration.php b/vendor/phpunit/php-timer/src/Duration.php new file mode 100644 index 000000000..e52bf018f --- /dev/null +++ b/vendor/phpunit/php-timer/src/Duration.php @@ -0,0 +1,109 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\Timer; + +use function floor; +use function sprintf; + +/** + * @psalm-immutable + */ +final class Duration +{ + /** + * @var float + */ + private $nanoseconds; + + /** + * @var int + */ + private $hours; + + /** + * @var int + */ + private $minutes; + + /** + * @var int + */ + private $seconds; + + /** + * @var int + */ + private $milliseconds; + + public static function fromMicroseconds(float $microseconds): self + { + return new self($microseconds * 1000); + } + + public static function fromNanoseconds(float $nanoseconds): self + { + return new self($nanoseconds); + } + + private function __construct(float $nanoseconds) + { + $this->nanoseconds = $nanoseconds; + $timeInMilliseconds = $nanoseconds / 1000000; + $hours = floor($timeInMilliseconds / 60 / 60 / 1000); + $hoursInMilliseconds = $hours * 60 * 60 * 1000; + $minutes = floor($timeInMilliseconds / 60 / 1000) % 60; + $minutesInMilliseconds = $minutes * 60 * 1000; + $seconds = floor(($timeInMilliseconds - $hoursInMilliseconds - $minutesInMilliseconds) / 1000); + $secondsInMilliseconds = $seconds * 1000; + $milliseconds = $timeInMilliseconds - $hoursInMilliseconds - $minutesInMilliseconds - $secondsInMilliseconds; + $this->hours = (int) $hours; + $this->minutes = $minutes; + $this->seconds = (int) $seconds; + $this->milliseconds = (int) $milliseconds; + } + + public function asNanoseconds(): float + { + return $this->nanoseconds; + } + + public function asMicroseconds(): float + { + return $this->nanoseconds / 1000; + } + + public function asMilliseconds(): float + { + return $this->nanoseconds / 1000000; + } + + public function asSeconds(): float + { + return $this->nanoseconds / 1000000000; + } + + public function asString(): string + { + $result = ''; + + if ($this->hours > 0) { + $result = sprintf('%02d', $this->hours) . ':'; + } + + $result .= sprintf('%02d', $this->minutes) . ':'; + $result .= sprintf('%02d', $this->seconds); + + if ($this->milliseconds > 0) { + $result .= '.' . sprintf('%03d', $this->milliseconds); + } + + return $result; + } +} diff --git a/vendor/phpunit/php-timer/src/ResourceUsageFormatter.php b/vendor/phpunit/php-timer/src/ResourceUsageFormatter.php new file mode 100644 index 000000000..ad7926277 --- /dev/null +++ b/vendor/phpunit/php-timer/src/ResourceUsageFormatter.php @@ -0,0 +1,73 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\Timer; + +use function is_float; +use function memory_get_peak_usage; +use function microtime; +use function sprintf; + +final class ResourceUsageFormatter +{ + /** + * @psalm-var array + */ + private const SIZES = [ + 'GB' => 1073741824, + 'MB' => 1048576, + 'KB' => 1024, + ]; + + public function resourceUsage(Duration $duration): string + { + return sprintf( + 'Time: %s, Memory: %s', + $duration->asString(), + $this->bytesToString(memory_get_peak_usage(true)) + ); + } + + /** + * @throws TimeSinceStartOfRequestNotAvailableException + */ + public function resourceUsageSinceStartOfRequest(): string + { + if (!isset($_SERVER['REQUEST_TIME_FLOAT'])) { + throw new TimeSinceStartOfRequestNotAvailableException( + 'Cannot determine time at which the request started because $_SERVER[\'REQUEST_TIME_FLOAT\'] is not available' + ); + } + + if (!is_float($_SERVER['REQUEST_TIME_FLOAT'])) { + throw new TimeSinceStartOfRequestNotAvailableException( + 'Cannot determine time at which the request started because $_SERVER[\'REQUEST_TIME_FLOAT\'] is not of type float' + ); + } + + return $this->resourceUsage( + Duration::fromMicroseconds( + (1000000 * (microtime(true) - $_SERVER['REQUEST_TIME_FLOAT'])) + ) + ); + } + + private function bytesToString(int $bytes): string + { + foreach (self::SIZES as $unit => $value) { + if ($bytes >= $value) { + return sprintf('%.2f %s', $bytes >= 1024 ? $bytes / $value : $bytes, $unit); + } + } + + // @codeCoverageIgnoreStart + return $bytes . ' byte' . ($bytes !== 1 ? 's' : ''); + // @codeCoverageIgnoreEnd + } +} diff --git a/vendor/phpunit/php-timer/src/Timer.php b/vendor/phpunit/php-timer/src/Timer.php index 378ff7249..0917109be 100644 --- a/vendor/phpunit/php-timer/src/Timer.php +++ b/vendor/phpunit/php-timer/src/Timer.php @@ -9,92 +9,32 @@ */ namespace SebastianBergmann\Timer; +use function array_pop; +use function hrtime; + final class Timer { /** - * @var int[] + * @psalm-var list */ - private static $sizes = [ - 'GB' => 1073741824, - 'MB' => 1048576, - 'KB' => 1024, - ]; + private $startTimes = []; - /** - * @var int[] - */ - private static $times = [ - 'hour' => 3600000, - 'minute' => 60000, - 'second' => 1000, - ]; - - /** - * @var float[] - */ - private static $startTimes = []; - - public static function start(): void + public function start(): void { - self::$startTimes[] = \microtime(true); + $this->startTimes[] = (float) hrtime(true); } - public static function stop(): float + /** + * @throws NoActiveTimerException + */ + public function stop(): Duration { - return \microtime(true) - \array_pop(self::$startTimes); - } - - public static function bytesToString(float $bytes): string - { - foreach (self::$sizes as $unit => $value) { - if ($bytes >= $value) { - return \sprintf('%.2f %s', $bytes >= 1024 ? $bytes / $value : $bytes, $unit); - } + if (empty($this->startTimes)) { + throw new NoActiveTimerException( + 'Timer::start() has to be called before Timer::stop()' + ); } - return $bytes . ' byte' . ((int) $bytes !== 1 ? 's' : ''); - } - - public static function secondsToTimeString(float $time): string - { - $ms = \round($time * 1000); - - foreach (self::$times as $unit => $value) { - if ($ms >= $value) { - $time = \floor($ms / $value * 100.0) / 100.0; - - return $time . ' ' . ($time == 1 ? $unit : $unit . 's'); - } - } - - return $ms . ' ms'; - } - - /** - * @throws RuntimeException - */ - public static function timeSinceStartOfRequest(): string - { - if (isset($_SERVER['REQUEST_TIME_FLOAT'])) { - $startOfRequest = $_SERVER['REQUEST_TIME_FLOAT']; - } elseif (isset($_SERVER['REQUEST_TIME'])) { - $startOfRequest = $_SERVER['REQUEST_TIME']; - } else { - throw new RuntimeException('Cannot determine time at which the request started'); - } - - return self::secondsToTimeString(\microtime(true) - $startOfRequest); - } - - /** - * @throws RuntimeException - */ - public static function resourceUsage(): string - { - return \sprintf( - 'Time: %s, Memory: %s', - self::timeSinceStartOfRequest(), - self::bytesToString(\memory_get_peak_usage(true)) - ); + return Duration::fromNanoseconds((float) hrtime(true) - array_pop($this->startTimes)); } } diff --git a/vendor/phpunit/php-timer/src/Exception.php b/vendor/phpunit/php-timer/src/exceptions/Exception.php similarity index 84% rename from vendor/phpunit/php-timer/src/Exception.php rename to vendor/phpunit/php-timer/src/exceptions/Exception.php index 7f9a26b20..996da0860 100644 --- a/vendor/phpunit/php-timer/src/Exception.php +++ b/vendor/phpunit/php-timer/src/exceptions/Exception.php @@ -9,6 +9,8 @@ */ namespace SebastianBergmann\Timer; -interface Exception +use Throwable; + +interface Exception extends Throwable { } diff --git a/vendor/sebastian/global-state/tests/_fixture/SnapshotDomDocument.php b/vendor/phpunit/php-timer/src/exceptions/NoActiveTimerException.php similarity index 56% rename from vendor/sebastian/global-state/tests/_fixture/SnapshotDomDocument.php rename to vendor/phpunit/php-timer/src/exceptions/NoActiveTimerException.php index 42eafd090..40fe45e86 100644 --- a/vendor/sebastian/global-state/tests/_fixture/SnapshotDomDocument.php +++ b/vendor/phpunit/php-timer/src/exceptions/NoActiveTimerException.php @@ -1,16 +1,16 @@ * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ -namespace SebastianBergmann\GlobalState\TestFixture; +namespace SebastianBergmann\Timer; -use DomDocument; +use LogicException; -class SnapshotDomDocument extends DomDocument +final class NoActiveTimerException extends LogicException implements Exception { } diff --git a/vendor/phpunit/php-timer/src/exceptions/TimeSinceStartOfRequestNotAvailableException.php b/vendor/phpunit/php-timer/src/exceptions/TimeSinceStartOfRequestNotAvailableException.php new file mode 100644 index 000000000..a2d94ce80 --- /dev/null +++ b/vendor/phpunit/php-timer/src/exceptions/TimeSinceStartOfRequestNotAvailableException.php @@ -0,0 +1,16 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\Timer; + +use RuntimeException; + +final class TimeSinceStartOfRequestNotAvailableException extends RuntimeException implements Exception +{ +} diff --git a/vendor/phpunit/php-timer/tests/TimerTest.php b/vendor/phpunit/php-timer/tests/TimerTest.php deleted file mode 100644 index 93cc4749d..000000000 --- a/vendor/phpunit/php-timer/tests/TimerTest.php +++ /dev/null @@ -1,134 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Timer; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\Timer\Timer - */ -final class TimerTest extends TestCase -{ - public function testCanBeStartedAndStopped(): void - { - $this->assertIsFloat(Timer::stop()); - } - - public function testCanFormatTimeSinceStartOfRequest(): void - { - $this->assertStringMatchesFormat('%f %s', Timer::timeSinceStartOfRequest()); - } - - /** - * @backupGlobals enabled - */ - public function testCanFormatSinceStartOfRequestWhenRequestTimeIsNotAvailableAsFloat(): void - { - if (isset($_SERVER['REQUEST_TIME_FLOAT'])) { - unset($_SERVER['REQUEST_TIME_FLOAT']); - } - - $this->assertStringMatchesFormat('%f %s', Timer::timeSinceStartOfRequest()); - } - - /** - * @backupGlobals enabled - */ - public function testCannotFormatTimeSinceStartOfRequestWhenRequestTimeIsNotAvailable(): void - { - if (isset($_SERVER['REQUEST_TIME_FLOAT'])) { - unset($_SERVER['REQUEST_TIME_FLOAT']); - } - - if (isset($_SERVER['REQUEST_TIME'])) { - unset($_SERVER['REQUEST_TIME']); - } - - $this->expectException(RuntimeException::class); - - Timer::timeSinceStartOfRequest(); - } - - public function testCanFormatResourceUsage(): void - { - $this->assertStringMatchesFormat('Time: %s, Memory: %f %s', Timer::resourceUsage()); - } - - /** - * @dataProvider secondsProvider - */ - public function testCanFormatSecondsAsString(string $string, float $seconds): void - { - $this->assertEquals($string, Timer::secondsToTimeString($seconds)); - } - - public function secondsProvider(): array - { - return [ - ['0 ms', 0], - ['1 ms', .001], - ['10 ms', .01], - ['100 ms', .1], - ['999 ms', .999], - ['1 second', .9999], - ['1 second', 1], - ['2 seconds', 2], - ['59.9 seconds', 59.9], - ['59.99 seconds', 59.99], - ['59.99 seconds', 59.999], - ['1 minute', 59.9999], - ['59 seconds', 59.001], - ['59.01 seconds', 59.01], - ['1 minute', 60], - ['1.01 minutes', 61], - ['2 minutes', 120], - ['2.01 minutes', 121], - ['59.99 minutes', 3599.9], - ['59.99 minutes', 3599.99], - ['59.99 minutes', 3599.999], - ['1 hour', 3599.9999], - ['59.98 minutes', 3599.001], - ['59.98 minutes', 3599.01], - ['1 hour', 3600], - ['1 hour', 3601], - ['1 hour', 3601.9], - ['1 hour', 3601.99], - ['1 hour', 3601.999], - ['1 hour', 3601.9999], - ['1.01 hours', 3659.9999], - ['1.01 hours', 3659.001], - ['1.01 hours', 3659.01], - ['2 hours', 7199.9999], - ]; - } - - /** - * @dataProvider bytesProvider - */ - public function testCanFormatBytesAsString(string $string, float $bytes): void - { - $this->assertEquals($string, Timer::bytesToString($bytes)); - } - - public function bytesProvider(): array - { - return [ - ['0 bytes', 0], - ['1 byte', 1], - ['1023 bytes', 1023], - ['1.00 KB', 1024], - ['1.50 KB', 1.5 * 1024], - ['2.00 MB', 2 * 1048576], - ['2.50 MB', 2.5 * 1048576], - ['3.00 GB', 3 * 1073741824], - ['3.50 GB', 3.5 * 1073741824], - ]; - } -} diff --git a/vendor/phpunit/php-token-stream/.gitignore b/vendor/phpunit/php-token-stream/.gitignore deleted file mode 100644 index 93a0be47b..000000000 --- a/vendor/phpunit/php-token-stream/.gitignore +++ /dev/null @@ -1,7 +0,0 @@ -/.idea -/.php_cs -/.php_cs.cache -/.phpunit.result.cache -/.psalm/cache -/composer.lock -/vendor diff --git a/vendor/phpunit/php-token-stream/ChangeLog.md b/vendor/phpunit/php-token-stream/ChangeLog.md deleted file mode 100644 index 4a93f524b..000000000 --- a/vendor/phpunit/php-token-stream/ChangeLog.md +++ /dev/null @@ -1,92 +0,0 @@ -# Change Log - -All notable changes to `sebastianbergmann/php-token-stream` are documented in this file using the [Keep a CHANGELOG](http://keepachangelog.com/) principles. - -## [4.0.4] - 2020-08-04 - -### Added - -* Support for `NAME_FULLY_QUALIFIED`, `NAME_QUALIFIED`, and `NAME_RELATIVE` tokens - -## [4.0.3] - 2020-06-27 - -### Added - -* This component is now supported on PHP 8 - -## [4.0.2] - 2020-06-16 - -### Fixed - -* Fixed backward compatibility breaks introduced in version 4.0.1 - -## [4.0.1] - 2020-05-06 - -### Fixed - -* [#93](https://github.com/sebastianbergmann/php-token-stream/issues/93): Class with method that uses anonymous class is not processed correctly - -## [4.0.0] - 2020-02-07 - -### Removed - -* This component is no longer supported PHP 7.1 and PHP 7.2 - -## [3.1.1] - 2019-09-17 - -### Fixed - -* [#84](https://github.com/sebastianbergmann/php-token-stream/issues/84): Methods named `class` are not handled correctly - -## [3.1.0] - 2019-07-25 - -### Added - -* Added support for `FN` and `COALESCE_EQUAL` tokens introduced in PHP 7.4 - -## [3.0.2] - 2019-07-08 - -### Changed - -* [#82](https://github.com/sebastianbergmann/php-token-stream/issues/82): Make sure this component works when its classes are prefixed using php-scoper - -## [3.0.1] - 2018-10-30 - -### Fixed - -* [#78](https://github.com/sebastianbergmann/php-token-stream/pull/78): `getEndTokenId()` does not handle string-dollar (`"${var}"`) interpolation - -## [3.0.0] - 2018-02-01 - -### Removed - -* [#71](https://github.com/sebastianbergmann/php-token-stream/issues/71): Remove code specific to Hack language constructs -* [#72](https://github.com/sebastianbergmann/php-token-stream/issues/72): Drop support for PHP 7.0 - -## [2.0.2] - 2017-11-27 - -### Fixed - -* [#69](https://github.com/sebastianbergmann/php-token-stream/issues/69): `PHP_Token_USE_FUNCTION` does not serialize correctly - -## [2.0.1] - 2017-08-20 - -### Fixed - -* [#68](https://github.com/sebastianbergmann/php-token-stream/issues/68): Method with name `empty` wrongly recognized as anonymous function - -## [2.0.0] - 2017-08-03 - -[4.0.4]: https://github.com/sebastianbergmann/php-token-stream/compare/4.0.3...4.0.4 -[4.0.3]: https://github.com/sebastianbergmann/php-token-stream/compare/4.0.2...4.0.3 -[4.0.2]: https://github.com/sebastianbergmann/php-token-stream/compare/4.0.1...4.0.2 -[4.0.1]: https://github.com/sebastianbergmann/php-token-stream/compare/4.0.0...4.0.1 -[4.0.0]: https://github.com/sebastianbergmann/php-token-stream/compare/3.1.1...4.0.0 -[3.1.1]: https://github.com/sebastianbergmann/php-token-stream/compare/3.1.0...3.1.1 -[3.1.0]: https://github.com/sebastianbergmann/php-token-stream/compare/3.0.2...3.1.0 -[3.0.2]: https://github.com/sebastianbergmann/php-token-stream/compare/3.0.1...3.0.2 -[3.0.1]: https://github.com/sebastianbergmann/php-token-stream/compare/3.0.0...3.0.1 -[3.0.0]: https://github.com/sebastianbergmann/php-token-stream/compare/2.0...3.0.0 -[2.0.2]: https://github.com/sebastianbergmann/php-token-stream/compare/2.0.1...2.0.2 -[2.0.1]: https://github.com/sebastianbergmann/php-token-stream/compare/2.0.0...2.0.1 -[2.0.0]: https://github.com/sebastianbergmann/php-token-stream/compare/1.4.11...2.0.0 diff --git a/vendor/phpunit/php-token-stream/src/Abstract.php b/vendor/phpunit/php-token-stream/src/Abstract.php deleted file mode 100644 index 7bbb555d3..000000000 --- a/vendor/phpunit/php-token-stream/src/Abstract.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_ABSTRACT extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Ampersand.php b/vendor/phpunit/php-token-stream/src/Ampersand.php deleted file mode 100644 index 3996f3446..000000000 --- a/vendor/phpunit/php-token-stream/src/Ampersand.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_AMPERSAND extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/AndEqual.php b/vendor/phpunit/php-token-stream/src/AndEqual.php deleted file mode 100644 index 9984442a6..000000000 --- a/vendor/phpunit/php-token-stream/src/AndEqual.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_AND_EQUAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Array.php b/vendor/phpunit/php-token-stream/src/Array.php deleted file mode 100644 index 72041e944..000000000 --- a/vendor/phpunit/php-token-stream/src/Array.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_ARRAY extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/ArrayCast.php b/vendor/phpunit/php-token-stream/src/ArrayCast.php deleted file mode 100644 index 9d113db52..000000000 --- a/vendor/phpunit/php-token-stream/src/ArrayCast.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_ARRAY_CAST extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/As.php b/vendor/phpunit/php-token-stream/src/As.php deleted file mode 100644 index 286578e46..000000000 --- a/vendor/phpunit/php-token-stream/src/As.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_AS extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/At.php b/vendor/phpunit/php-token-stream/src/At.php deleted file mode 100644 index d8d246857..000000000 --- a/vendor/phpunit/php-token-stream/src/At.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_AT extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Backtick.php b/vendor/phpunit/php-token-stream/src/Backtick.php deleted file mode 100644 index 3d8b55b7f..000000000 --- a/vendor/phpunit/php-token-stream/src/Backtick.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_BACKTICK extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/BadCharacter.php b/vendor/phpunit/php-token-stream/src/BadCharacter.php deleted file mode 100644 index dfc7a40ff..000000000 --- a/vendor/phpunit/php-token-stream/src/BadCharacter.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_BAD_CHARACTER extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/BoolCast.php b/vendor/phpunit/php-token-stream/src/BoolCast.php deleted file mode 100644 index 201cfeab6..000000000 --- a/vendor/phpunit/php-token-stream/src/BoolCast.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_BOOL_CAST extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/BooleanAnd.php b/vendor/phpunit/php-token-stream/src/BooleanAnd.php deleted file mode 100644 index 03f983311..000000000 --- a/vendor/phpunit/php-token-stream/src/BooleanAnd.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_BOOLEAN_AND extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/BooleanOr.php b/vendor/phpunit/php-token-stream/src/BooleanOr.php deleted file mode 100644 index 0f339245b..000000000 --- a/vendor/phpunit/php-token-stream/src/BooleanOr.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_BOOLEAN_OR extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/CachingFactory.php b/vendor/phpunit/php-token-stream/src/CachingFactory.php deleted file mode 100644 index c557a84f3..000000000 --- a/vendor/phpunit/php-token-stream/src/CachingFactory.php +++ /dev/null @@ -1,42 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_Stream_CachingFactory -{ - /** - * @var array - */ - protected static $cache = []; - - /** - * @param string $filename - * - * @return PHP_Token_Stream - */ - public static function get($filename) - { - if (!isset(self::$cache[$filename])) { - self::$cache[$filename] = new PHP_Token_Stream($filename); - } - - return self::$cache[$filename]; - } - - /** - * @param string $filename - */ - public static function clear($filename = null)/*: void*/ - { - if (\is_string($filename)) { - unset(self::$cache[$filename]); - } else { - self::$cache = []; - } - } -} diff --git a/vendor/phpunit/php-token-stream/src/Callable.php b/vendor/phpunit/php-token-stream/src/Callable.php deleted file mode 100644 index 4f5751259..000000000 --- a/vendor/phpunit/php-token-stream/src/Callable.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_CALLABLE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Caret.php b/vendor/phpunit/php-token-stream/src/Caret.php deleted file mode 100644 index af453d897..000000000 --- a/vendor/phpunit/php-token-stream/src/Caret.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_CARET extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Case.php b/vendor/phpunit/php-token-stream/src/Case.php deleted file mode 100644 index ab9b906db..000000000 --- a/vendor/phpunit/php-token-stream/src/Case.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_CASE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Catch.php b/vendor/phpunit/php-token-stream/src/Catch.php deleted file mode 100644 index 8c244acae..000000000 --- a/vendor/phpunit/php-token-stream/src/Catch.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_CATCH extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Character.php b/vendor/phpunit/php-token-stream/src/Character.php deleted file mode 100644 index eea0db099..000000000 --- a/vendor/phpunit/php-token-stream/src/Character.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_CHARACTER extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Class.php b/vendor/phpunit/php-token-stream/src/Class.php deleted file mode 100644 index 09167f21c..000000000 --- a/vendor/phpunit/php-token-stream/src/Class.php +++ /dev/null @@ -1,62 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_CLASS extends PHP_Token_INTERFACE -{ - /** - * @var bool - */ - private $anonymous = false; - - /** - * @var string - */ - private $name; - - /** - * @return string - */ - public function getName() - { - if ($this->name !== null) { - return $this->name; - } - - $next = $this->tokenStream[$this->id + 1]; - - if ($next instanceof PHP_Token_WHITESPACE) { - $next = $this->tokenStream[$this->id + 2]; - } - - if ($next instanceof PHP_Token_STRING) { - $this->name =(string) $next; - - return $this->name; - } - - if ($next instanceof PHP_Token_OPEN_CURLY || - $next instanceof PHP_Token_EXTENDS || - $next instanceof PHP_Token_IMPLEMENTS) { - $this->name = \sprintf( - 'AnonymousClass:%s#%s', - $this->getLine(), - $this->getId() - ); - - $this->anonymous = true; - - return $this->name; - } - } - - public function isAnonymous() - { - return $this->anonymous; - } -} diff --git a/vendor/phpunit/php-token-stream/src/ClassC.php b/vendor/phpunit/php-token-stream/src/ClassC.php deleted file mode 100644 index 2350c99bd..000000000 --- a/vendor/phpunit/php-token-stream/src/ClassC.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_CLASS_C extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/ClassNameConstant.php b/vendor/phpunit/php-token-stream/src/ClassNameConstant.php deleted file mode 100644 index 1b557e3c7..000000000 --- a/vendor/phpunit/php-token-stream/src/ClassNameConstant.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_CLASS_NAME_CONSTANT extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Clone.php b/vendor/phpunit/php-token-stream/src/Clone.php deleted file mode 100644 index 24e661047..000000000 --- a/vendor/phpunit/php-token-stream/src/Clone.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_CLONE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/CloseBracket.php b/vendor/phpunit/php-token-stream/src/CloseBracket.php deleted file mode 100644 index b86b74575..000000000 --- a/vendor/phpunit/php-token-stream/src/CloseBracket.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_CLOSE_BRACKET extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/CloseCurly.php b/vendor/phpunit/php-token-stream/src/CloseCurly.php deleted file mode 100644 index aa86cdc4d..000000000 --- a/vendor/phpunit/php-token-stream/src/CloseCurly.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_CLOSE_CURLY extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/CloseSquare.php b/vendor/phpunit/php-token-stream/src/CloseSquare.php deleted file mode 100644 index fc819d015..000000000 --- a/vendor/phpunit/php-token-stream/src/CloseSquare.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_CLOSE_SQUARE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/CloseTag.php b/vendor/phpunit/php-token-stream/src/CloseTag.php deleted file mode 100644 index 419510cf8..000000000 --- a/vendor/phpunit/php-token-stream/src/CloseTag.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_CLOSE_TAG extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Coalesce.php b/vendor/phpunit/php-token-stream/src/Coalesce.php deleted file mode 100644 index 55b2beb4a..000000000 --- a/vendor/phpunit/php-token-stream/src/Coalesce.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_COALESCE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/CoalesceEqual.php b/vendor/phpunit/php-token-stream/src/CoalesceEqual.php deleted file mode 100644 index b60096181..000000000 --- a/vendor/phpunit/php-token-stream/src/CoalesceEqual.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_COALESCE_EQUAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Colon.php b/vendor/phpunit/php-token-stream/src/Colon.php deleted file mode 100644 index 66dd84089..000000000 --- a/vendor/phpunit/php-token-stream/src/Colon.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_COLON extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Comma.php b/vendor/phpunit/php-token-stream/src/Comma.php deleted file mode 100644 index b57ba370c..000000000 --- a/vendor/phpunit/php-token-stream/src/Comma.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_COMMA extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Comment.php b/vendor/phpunit/php-token-stream/src/Comment.php deleted file mode 100644 index c50c80b80..000000000 --- a/vendor/phpunit/php-token-stream/src/Comment.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_COMMENT extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/ConcatEqual.php b/vendor/phpunit/php-token-stream/src/ConcatEqual.php deleted file mode 100644 index f57c748f3..000000000 --- a/vendor/phpunit/php-token-stream/src/ConcatEqual.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_CONCAT_EQUAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Const.php b/vendor/phpunit/php-token-stream/src/Const.php deleted file mode 100644 index a5376422c..000000000 --- a/vendor/phpunit/php-token-stream/src/Const.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_CONST extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/ConstantEncapsedString.php b/vendor/phpunit/php-token-stream/src/ConstantEncapsedString.php deleted file mode 100644 index 2a030cd3c..000000000 --- a/vendor/phpunit/php-token-stream/src/ConstantEncapsedString.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_CONSTANT_ENCAPSED_STRING extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Continue.php b/vendor/phpunit/php-token-stream/src/Continue.php deleted file mode 100644 index a21c8ba10..000000000 --- a/vendor/phpunit/php-token-stream/src/Continue.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_CONTINUE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/CurlyOpen.php b/vendor/phpunit/php-token-stream/src/CurlyOpen.php deleted file mode 100644 index 7c3e9bcea..000000000 --- a/vendor/phpunit/php-token-stream/src/CurlyOpen.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_CURLY_OPEN extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/DNumber.php b/vendor/phpunit/php-token-stream/src/DNumber.php deleted file mode 100644 index bf5751f32..000000000 --- a/vendor/phpunit/php-token-stream/src/DNumber.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_DNUMBER extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Dec.php b/vendor/phpunit/php-token-stream/src/Dec.php deleted file mode 100644 index 6f06341c4..000000000 --- a/vendor/phpunit/php-token-stream/src/Dec.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_DEC extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Declare.php b/vendor/phpunit/php-token-stream/src/Declare.php deleted file mode 100644 index 60dab6f88..000000000 --- a/vendor/phpunit/php-token-stream/src/Declare.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_DECLARE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Default.php b/vendor/phpunit/php-token-stream/src/Default.php deleted file mode 100644 index 81f3bfd02..000000000 --- a/vendor/phpunit/php-token-stream/src/Default.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_DEFAULT extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Dir.php b/vendor/phpunit/php-token-stream/src/Dir.php deleted file mode 100644 index add4bf84d..000000000 --- a/vendor/phpunit/php-token-stream/src/Dir.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_DIR extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Div.php b/vendor/phpunit/php-token-stream/src/Div.php deleted file mode 100644 index 87e11d786..000000000 --- a/vendor/phpunit/php-token-stream/src/Div.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_DIV extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/DivEqual.php b/vendor/phpunit/php-token-stream/src/DivEqual.php deleted file mode 100644 index cb558a89d..000000000 --- a/vendor/phpunit/php-token-stream/src/DivEqual.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_DIV_EQUAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Do.php b/vendor/phpunit/php-token-stream/src/Do.php deleted file mode 100644 index 32ceff1c9..000000000 --- a/vendor/phpunit/php-token-stream/src/Do.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_DO extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/DocComment.php b/vendor/phpunit/php-token-stream/src/DocComment.php deleted file mode 100644 index 2ca6f2216..000000000 --- a/vendor/phpunit/php-token-stream/src/DocComment.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_DOC_COMMENT extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Dollar.php b/vendor/phpunit/php-token-stream/src/Dollar.php deleted file mode 100644 index a2a8d5955..000000000 --- a/vendor/phpunit/php-token-stream/src/Dollar.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_DOLLAR extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/DollarOpenCurlyBraces.php b/vendor/phpunit/php-token-stream/src/DollarOpenCurlyBraces.php deleted file mode 100644 index 030bcb29b..000000000 --- a/vendor/phpunit/php-token-stream/src/DollarOpenCurlyBraces.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_DOLLAR_OPEN_CURLY_BRACES extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Dot.php b/vendor/phpunit/php-token-stream/src/Dot.php deleted file mode 100644 index b50a49eed..000000000 --- a/vendor/phpunit/php-token-stream/src/Dot.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_DOT extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/DoubleArrow.php b/vendor/phpunit/php-token-stream/src/DoubleArrow.php deleted file mode 100644 index bc2c6d06a..000000000 --- a/vendor/phpunit/php-token-stream/src/DoubleArrow.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_DOUBLE_ARROW extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/DoubleCast.php b/vendor/phpunit/php-token-stream/src/DoubleCast.php deleted file mode 100644 index eb72f3642..000000000 --- a/vendor/phpunit/php-token-stream/src/DoubleCast.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_DOUBLE_CAST extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/DoubleColon.php b/vendor/phpunit/php-token-stream/src/DoubleColon.php deleted file mode 100644 index 46ff6e7f2..000000000 --- a/vendor/phpunit/php-token-stream/src/DoubleColon.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_DOUBLE_COLON extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/DoubleQuotes.php b/vendor/phpunit/php-token-stream/src/DoubleQuotes.php deleted file mode 100644 index 10779806e..000000000 --- a/vendor/phpunit/php-token-stream/src/DoubleQuotes.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_DOUBLE_QUOTES extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Echo.php b/vendor/phpunit/php-token-stream/src/Echo.php deleted file mode 100644 index bfee30cff..000000000 --- a/vendor/phpunit/php-token-stream/src/Echo.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_ECHO extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Ellipsis.php b/vendor/phpunit/php-token-stream/src/Ellipsis.php deleted file mode 100644 index d932cedb6..000000000 --- a/vendor/phpunit/php-token-stream/src/Ellipsis.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_ELLIPSIS extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Else.php b/vendor/phpunit/php-token-stream/src/Else.php deleted file mode 100644 index a3266f863..000000000 --- a/vendor/phpunit/php-token-stream/src/Else.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_ELSE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Elseif.php b/vendor/phpunit/php-token-stream/src/Elseif.php deleted file mode 100644 index 76a7d4e7c..000000000 --- a/vendor/phpunit/php-token-stream/src/Elseif.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_ELSEIF extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Empty.php b/vendor/phpunit/php-token-stream/src/Empty.php deleted file mode 100644 index 15f662cdb..000000000 --- a/vendor/phpunit/php-token-stream/src/Empty.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_EMPTY extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/EncapsedAndWhitespace.php b/vendor/phpunit/php-token-stream/src/EncapsedAndWhitespace.php deleted file mode 100644 index 5224806db..000000000 --- a/vendor/phpunit/php-token-stream/src/EncapsedAndWhitespace.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_ENCAPSED_AND_WHITESPACE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/EndHeredoc.php b/vendor/phpunit/php-token-stream/src/EndHeredoc.php deleted file mode 100644 index e95930cf4..000000000 --- a/vendor/phpunit/php-token-stream/src/EndHeredoc.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_END_HEREDOC extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Enddeclare.php b/vendor/phpunit/php-token-stream/src/Enddeclare.php deleted file mode 100644 index dd96d7f16..000000000 --- a/vendor/phpunit/php-token-stream/src/Enddeclare.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_ENDDECLARE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Endfor.php b/vendor/phpunit/php-token-stream/src/Endfor.php deleted file mode 100644 index a5382a273..000000000 --- a/vendor/phpunit/php-token-stream/src/Endfor.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_ENDFOR extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Endforeach.php b/vendor/phpunit/php-token-stream/src/Endforeach.php deleted file mode 100644 index d2ab78a52..000000000 --- a/vendor/phpunit/php-token-stream/src/Endforeach.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_ENDFOREACH extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Endif.php b/vendor/phpunit/php-token-stream/src/Endif.php deleted file mode 100644 index 910eeea5c..000000000 --- a/vendor/phpunit/php-token-stream/src/Endif.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_ENDIF extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Endswitch.php b/vendor/phpunit/php-token-stream/src/Endswitch.php deleted file mode 100644 index 0fc81462d..000000000 --- a/vendor/phpunit/php-token-stream/src/Endswitch.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_ENDSWITCH extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Endwhile.php b/vendor/phpunit/php-token-stream/src/Endwhile.php deleted file mode 100644 index 9a289f110..000000000 --- a/vendor/phpunit/php-token-stream/src/Endwhile.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_ENDWHILE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Equal.php b/vendor/phpunit/php-token-stream/src/Equal.php deleted file mode 100644 index c8ecb0b70..000000000 --- a/vendor/phpunit/php-token-stream/src/Equal.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_EQUAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Eval.php b/vendor/phpunit/php-token-stream/src/Eval.php deleted file mode 100644 index fb82bfd7b..000000000 --- a/vendor/phpunit/php-token-stream/src/Eval.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_EVAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/ExclamationMark.php b/vendor/phpunit/php-token-stream/src/ExclamationMark.php deleted file mode 100644 index 009ea238e..000000000 --- a/vendor/phpunit/php-token-stream/src/ExclamationMark.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_EXCLAMATION_MARK extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Exit.php b/vendor/phpunit/php-token-stream/src/Exit.php deleted file mode 100644 index 9475887c6..000000000 --- a/vendor/phpunit/php-token-stream/src/Exit.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_EXIT extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Extends.php b/vendor/phpunit/php-token-stream/src/Extends.php deleted file mode 100644 index bf5116060..000000000 --- a/vendor/phpunit/php-token-stream/src/Extends.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_EXTENDS extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/File.php b/vendor/phpunit/php-token-stream/src/File.php deleted file mode 100644 index a89449c3b..000000000 --- a/vendor/phpunit/php-token-stream/src/File.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_FILE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Final.php b/vendor/phpunit/php-token-stream/src/Final.php deleted file mode 100644 index f1355d239..000000000 --- a/vendor/phpunit/php-token-stream/src/Final.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_FINAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Finally.php b/vendor/phpunit/php-token-stream/src/Finally.php deleted file mode 100644 index 8d31fc326..000000000 --- a/vendor/phpunit/php-token-stream/src/Finally.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_FINALLY extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Fn.php b/vendor/phpunit/php-token-stream/src/Fn.php deleted file mode 100644 index 8c1ceecb1..000000000 --- a/vendor/phpunit/php-token-stream/src/Fn.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_FN extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/For.php b/vendor/phpunit/php-token-stream/src/For.php deleted file mode 100644 index 5b7bcbf8f..000000000 --- a/vendor/phpunit/php-token-stream/src/For.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_FOR extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Foreach.php b/vendor/phpunit/php-token-stream/src/Foreach.php deleted file mode 100644 index 76906b0d1..000000000 --- a/vendor/phpunit/php-token-stream/src/Foreach.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_FOREACH extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/FuncC.php b/vendor/phpunit/php-token-stream/src/FuncC.php deleted file mode 100644 index 853446f12..000000000 --- a/vendor/phpunit/php-token-stream/src/FuncC.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_FUNC_C extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Function.php b/vendor/phpunit/php-token-stream/src/Function.php deleted file mode 100644 index 8cc9eb1ad..000000000 --- a/vendor/phpunit/php-token-stream/src/Function.php +++ /dev/null @@ -1,196 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_FUNCTION extends PHP_TokenWithScopeAndVisibility -{ - /** - * @var array - */ - protected $arguments; - - /** - * @var int - */ - protected $ccn; - - /** - * @var string - */ - protected $name; - - /** - * @var string - */ - protected $signature; - - /** - * @var bool - */ - private $anonymous = false; - - /** - * @return array - */ - public function getArguments() - { - if ($this->arguments !== null) { - return $this->arguments; - } - - $this->arguments = []; - $tokens = $this->tokenStream->tokens(); - $typeDeclaration = null; - - // Search for first token inside brackets - $i = $this->id + 2; - - while (!$tokens[$i - 1] instanceof PHP_Token_OPEN_BRACKET) { - $i++; - } - - while (!$tokens[$i] instanceof PHP_Token_CLOSE_BRACKET) { - if ($tokens[$i] instanceof PHP_Token_STRING) { - $typeDeclaration = (string) $tokens[$i]; - } elseif ($tokens[$i] instanceof PHP_Token_VARIABLE) { - $this->arguments[(string) $tokens[$i]] = $typeDeclaration; - $typeDeclaration = null; - } - - $i++; - } - - return $this->arguments; - } - - /** - * @return string - */ - public function getName() - { - if ($this->name !== null) { - return $this->name; - } - - $tokens = $this->tokenStream->tokens(); - - $i = $this->id + 1; - - if ($tokens[$i] instanceof PHP_Token_WHITESPACE) { - $i++; - } - - if ($tokens[$i] instanceof PHP_Token_AMPERSAND) { - $i++; - } - - if ($tokens[$i + 1] instanceof PHP_Token_OPEN_BRACKET) { - $this->name = (string) $tokens[$i]; - } elseif ($tokens[$i + 1] instanceof PHP_Token_WHITESPACE && $tokens[$i + 2] instanceof PHP_Token_OPEN_BRACKET) { - $this->name = (string) $tokens[$i]; - } else { - $this->anonymous = true; - - $this->name = \sprintf( - 'anonymousFunction:%s#%s', - $this->getLine(), - $this->getId() - ); - } - - if (!$this->isAnonymous()) { - for ($i = $this->id; $i; --$i) { - if ($tokens[$i] instanceof PHP_Token_NAMESPACE) { - $this->name = $tokens[$i]->getName() . '\\' . $this->name; - - break; - } - - if ($tokens[$i] instanceof PHP_Token_INTERFACE) { - break; - } - } - } - - return $this->name; - } - - /** - * @return int - */ - public function getCCN() - { - if ($this->ccn !== null) { - return $this->ccn; - } - - $this->ccn = 1; - $end = $this->getEndTokenId(); - $tokens = $this->tokenStream->tokens(); - - for ($i = $this->id; $i <= $end; $i++) { - switch (\get_class($tokens[$i])) { - case PHP_Token_IF::class: - case PHP_Token_ELSEIF::class: - case PHP_Token_FOR::class: - case PHP_Token_FOREACH::class: - case PHP_Token_WHILE::class: - case PHP_Token_CASE::class: - case PHP_Token_CATCH::class: - case PHP_Token_BOOLEAN_AND::class: - case PHP_Token_LOGICAL_AND::class: - case PHP_Token_BOOLEAN_OR::class: - case PHP_Token_LOGICAL_OR::class: - case PHP_Token_QUESTION_MARK::class: - $this->ccn++; - - break; - } - } - - return $this->ccn; - } - - /** - * @return string - */ - public function getSignature() - { - if ($this->signature !== null) { - return $this->signature; - } - - if ($this->isAnonymous()) { - $this->signature = 'anonymousFunction'; - $i = $this->id + 1; - } else { - $this->signature = ''; - $i = $this->id + 2; - } - - $tokens = $this->tokenStream->tokens(); - - while (isset($tokens[$i]) && - !$tokens[$i] instanceof PHP_Token_OPEN_CURLY && - !$tokens[$i] instanceof PHP_Token_SEMICOLON) { - $this->signature .= $tokens[$i++]; - } - - $this->signature = \trim($this->signature); - - return $this->signature; - } - - /** - * @return bool - */ - public function isAnonymous() - { - return $this->anonymous; - } -} diff --git a/vendor/phpunit/php-token-stream/src/Global.php b/vendor/phpunit/php-token-stream/src/Global.php deleted file mode 100644 index 15d34c0f9..000000000 --- a/vendor/phpunit/php-token-stream/src/Global.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_GLOBAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Goto.php b/vendor/phpunit/php-token-stream/src/Goto.php deleted file mode 100644 index 68cbce0db..000000000 --- a/vendor/phpunit/php-token-stream/src/Goto.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_GOTO extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Gt.php b/vendor/phpunit/php-token-stream/src/Gt.php deleted file mode 100644 index 1df2bc974..000000000 --- a/vendor/phpunit/php-token-stream/src/Gt.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_GT extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/HaltCompiler.php b/vendor/phpunit/php-token-stream/src/HaltCompiler.php deleted file mode 100644 index 1976e9b7d..000000000 --- a/vendor/phpunit/php-token-stream/src/HaltCompiler.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_HALT_COMPILER extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/If.php b/vendor/phpunit/php-token-stream/src/If.php deleted file mode 100644 index 2f888f1ce..000000000 --- a/vendor/phpunit/php-token-stream/src/If.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_IF extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Implements.php b/vendor/phpunit/php-token-stream/src/Implements.php deleted file mode 100644 index bfb035bcc..000000000 --- a/vendor/phpunit/php-token-stream/src/Implements.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_IMPLEMENTS extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Inc.php b/vendor/phpunit/php-token-stream/src/Inc.php deleted file mode 100644 index ca19c33ab..000000000 --- a/vendor/phpunit/php-token-stream/src/Inc.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_INC extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Include.php b/vendor/phpunit/php-token-stream/src/Include.php deleted file mode 100644 index cffb378e7..000000000 --- a/vendor/phpunit/php-token-stream/src/Include.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_INCLUDE extends PHP_Token_Includes -{ -} diff --git a/vendor/phpunit/php-token-stream/src/IncludeOnce.php b/vendor/phpunit/php-token-stream/src/IncludeOnce.php deleted file mode 100644 index da28d6178..000000000 --- a/vendor/phpunit/php-token-stream/src/IncludeOnce.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_INCLUDE_ONCE extends PHP_Token_Includes -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Includes.php b/vendor/phpunit/php-token-stream/src/Includes.php deleted file mode 100644 index 285dfbf65..000000000 --- a/vendor/phpunit/php-token-stream/src/Includes.php +++ /dev/null @@ -1,57 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -abstract class PHP_Token_Includes extends PHP_Token -{ - /** - * @var string - */ - protected $name; - - /** - * @var string - */ - protected $type; - - /** - * @return string - */ - public function getName() - { - if ($this->name === null) { - $this->process(); - } - - return $this->name; - } - - /** - * @return string - */ - public function getType() - { - if ($this->type === null) { - $this->process(); - } - - return $this->type; - } - - private function process(): void - { - $tokens = $this->tokenStream->tokens(); - - if ($tokens[$this->id + 2] instanceof PHP_Token_CONSTANT_ENCAPSED_STRING) { - $this->name = \trim((string) $tokens[$this->id + 2], "'\""); - $this->type = \strtolower( - \str_replace('PHP_Token_', '', PHP_Token_Util::getClass($tokens[$this->id])) - ); - } - } -} diff --git a/vendor/phpunit/php-token-stream/src/InlineHtml.php b/vendor/phpunit/php-token-stream/src/InlineHtml.php deleted file mode 100644 index a4fc15e05..000000000 --- a/vendor/phpunit/php-token-stream/src/InlineHtml.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_INLINE_HTML extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Instanceof.php b/vendor/phpunit/php-token-stream/src/Instanceof.php deleted file mode 100644 index c41dd0e60..000000000 --- a/vendor/phpunit/php-token-stream/src/Instanceof.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_INSTANCEOF extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Insteadof.php b/vendor/phpunit/php-token-stream/src/Insteadof.php deleted file mode 100644 index d8c0bc470..000000000 --- a/vendor/phpunit/php-token-stream/src/Insteadof.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_INSTEADOF extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/IntCast.php b/vendor/phpunit/php-token-stream/src/IntCast.php deleted file mode 100644 index 2b256017c..000000000 --- a/vendor/phpunit/php-token-stream/src/IntCast.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_INT_CAST extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Interface.php b/vendor/phpunit/php-token-stream/src/Interface.php deleted file mode 100644 index d2732f561..000000000 --- a/vendor/phpunit/php-token-stream/src/Interface.php +++ /dev/null @@ -1,166 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_INTERFACE extends PHP_TokenWithScopeAndVisibility -{ - /** - * @var array - */ - protected $interfaces; - - /** - * @return string - */ - public function getName() - { - return (string) $this->tokenStream[$this->id + 2]; - } - - /** - * @return bool - */ - public function hasParent() - { - return $this->tokenStream[$this->id + 4] instanceof PHP_Token_EXTENDS; - } - - /** - * @return array - */ - public function getPackage() - { - $result = [ - 'namespace' => '', - 'fullPackage' => '', - 'category' => '', - 'package' => '', - 'subpackage' => '', - ]; - - $docComment = $this->getDocblock(); - $className = $this->getName(); - - for ($i = $this->id; $i; --$i) { - if ($this->tokenStream[$i] instanceof PHP_Token_NAMESPACE) { - $result['namespace'] = $this->tokenStream[$i]->getName(); - - break; - } - } - - if ($docComment === null) { - return $result; - } - - if (\preg_match('/@category[\s]+([\.\w]+)/', $docComment, $matches)) { - $result['category'] = $matches[1]; - } - - if (\preg_match('/@package[\s]+([\.\w]+)/', $docComment, $matches)) { - $result['package'] = $matches[1]; - $result['fullPackage'] = $matches[1]; - } - - if (\preg_match('/@subpackage[\s]+([\.\w]+)/', $docComment, $matches)) { - $result['subpackage'] = $matches[1]; - $result['fullPackage'] .= '.' . $matches[1]; - } - - if (empty($result['fullPackage'])) { - $result['fullPackage'] = $this->arrayToName( - \explode('_', \str_replace('\\', '_', $className)), - '.' - ); - } - - return $result; - } - - /** - * @return bool|string - */ - public function getParent() - { - if (!$this->hasParent()) { - return false; - } - - $i = $this->id + 6; - $tokens = $this->tokenStream->tokens(); - $className = (string) $tokens[$i]; - - while (isset($tokens[$i + 1]) && - !$tokens[$i + 1] instanceof PHP_Token_WHITESPACE) { - $className .= (string) $tokens[++$i]; - } - - return $className; - } - - /** - * @return bool - */ - public function hasInterfaces() - { - return (isset($this->tokenStream[$this->id + 4]) && - $this->tokenStream[$this->id + 4] instanceof PHP_Token_IMPLEMENTS) || - (isset($this->tokenStream[$this->id + 8]) && - $this->tokenStream[$this->id + 8] instanceof PHP_Token_IMPLEMENTS); - } - - /** - * @return array|bool - */ - public function getInterfaces() - { - if ($this->interfaces !== null) { - return $this->interfaces; - } - - if (!$this->hasInterfaces()) { - return $this->interfaces = false; - } - - if ($this->tokenStream[$this->id + 4] instanceof PHP_Token_IMPLEMENTS) { - $i = $this->id + 3; - } else { - $i = $this->id + 7; - } - - $tokens = $this->tokenStream->tokens(); - - while (!$tokens[$i + 1] instanceof PHP_Token_OPEN_CURLY) { - $i++; - - if ($tokens[$i] instanceof PHP_Token_STRING) { - $this->interfaces[] = (string) $tokens[$i]; - } - } - - return $this->interfaces; - } - - /** - * @param string $join - * - * @return string - */ - protected function arrayToName(array $parts, $join = '\\') - { - $result = ''; - - if (\count($parts) > 1) { - \array_pop($parts); - - $result = \implode($join, $parts); - } - - return $result; - } -} diff --git a/vendor/phpunit/php-token-stream/src/IsEqual.php b/vendor/phpunit/php-token-stream/src/IsEqual.php deleted file mode 100644 index 70f00af5d..000000000 --- a/vendor/phpunit/php-token-stream/src/IsEqual.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_IS_EQUAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/IsGreaterOrEqual.php b/vendor/phpunit/php-token-stream/src/IsGreaterOrEqual.php deleted file mode 100644 index 0227baf46..000000000 --- a/vendor/phpunit/php-token-stream/src/IsGreaterOrEqual.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_IS_GREATER_OR_EQUAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/IsIdentical.php b/vendor/phpunit/php-token-stream/src/IsIdentical.php deleted file mode 100644 index 28388df5b..000000000 --- a/vendor/phpunit/php-token-stream/src/IsIdentical.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_IS_IDENTICAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/IsNotEqual.php b/vendor/phpunit/php-token-stream/src/IsNotEqual.php deleted file mode 100644 index f70f2290e..000000000 --- a/vendor/phpunit/php-token-stream/src/IsNotEqual.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_IS_NOT_EQUAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/IsNotIdentical.php b/vendor/phpunit/php-token-stream/src/IsNotIdentical.php deleted file mode 100644 index 9fe3a71a2..000000000 --- a/vendor/phpunit/php-token-stream/src/IsNotIdentical.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_IS_NOT_IDENTICAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/IsSmallerOrEqual.php b/vendor/phpunit/php-token-stream/src/IsSmallerOrEqual.php deleted file mode 100644 index 7ac0c2fa2..000000000 --- a/vendor/phpunit/php-token-stream/src/IsSmallerOrEqual.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_IS_SMALLER_OR_EQUAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Isset.php b/vendor/phpunit/php-token-stream/src/Isset.php deleted file mode 100644 index 47941d643..000000000 --- a/vendor/phpunit/php-token-stream/src/Isset.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_ISSET extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Line.php b/vendor/phpunit/php-token-stream/src/Line.php deleted file mode 100644 index ffed4dbcc..000000000 --- a/vendor/phpunit/php-token-stream/src/Line.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_LINE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/List.php b/vendor/phpunit/php-token-stream/src/List.php deleted file mode 100644 index 9410fc5a7..000000000 --- a/vendor/phpunit/php-token-stream/src/List.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_LIST extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Lnumber.php b/vendor/phpunit/php-token-stream/src/Lnumber.php deleted file mode 100644 index e996bd0f8..000000000 --- a/vendor/phpunit/php-token-stream/src/Lnumber.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_LNUMBER extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/LogicalAnd.php b/vendor/phpunit/php-token-stream/src/LogicalAnd.php deleted file mode 100644 index 72beb476c..000000000 --- a/vendor/phpunit/php-token-stream/src/LogicalAnd.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_LOGICAL_AND extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/LogicalOr.php b/vendor/phpunit/php-token-stream/src/LogicalOr.php deleted file mode 100644 index ec8be7030..000000000 --- a/vendor/phpunit/php-token-stream/src/LogicalOr.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_LOGICAL_OR extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/LogicalXor.php b/vendor/phpunit/php-token-stream/src/LogicalXor.php deleted file mode 100644 index e1e223b99..000000000 --- a/vendor/phpunit/php-token-stream/src/LogicalXor.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_LOGICAL_XOR extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Lt.php b/vendor/phpunit/php-token-stream/src/Lt.php deleted file mode 100644 index 288a41330..000000000 --- a/vendor/phpunit/php-token-stream/src/Lt.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_LT extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/MethodC.php b/vendor/phpunit/php-token-stream/src/MethodC.php deleted file mode 100644 index 1bebf001a..000000000 --- a/vendor/phpunit/php-token-stream/src/MethodC.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_METHOD_C extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Minus.php b/vendor/phpunit/php-token-stream/src/Minus.php deleted file mode 100644 index 6ca52f523..000000000 --- a/vendor/phpunit/php-token-stream/src/Minus.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_MINUS extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/MinusEqual.php b/vendor/phpunit/php-token-stream/src/MinusEqual.php deleted file mode 100644 index 1bfb24c5e..000000000 --- a/vendor/phpunit/php-token-stream/src/MinusEqual.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_MINUS_EQUAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/ModEqual.php b/vendor/phpunit/php-token-stream/src/ModEqual.php deleted file mode 100644 index 28aab5863..000000000 --- a/vendor/phpunit/php-token-stream/src/ModEqual.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_MOD_EQUAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/MulEqual.php b/vendor/phpunit/php-token-stream/src/MulEqual.php deleted file mode 100644 index 16a0d242e..000000000 --- a/vendor/phpunit/php-token-stream/src/MulEqual.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_MUL_EQUAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Mult.php b/vendor/phpunit/php-token-stream/src/Mult.php deleted file mode 100644 index bd6daed76..000000000 --- a/vendor/phpunit/php-token-stream/src/Mult.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_MULT extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/NameFullyQualified.php b/vendor/phpunit/php-token-stream/src/NameFullyQualified.php deleted file mode 100644 index 744118abc..000000000 --- a/vendor/phpunit/php-token-stream/src/NameFullyQualified.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_NAME_FULLY_QUALIFIED extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/NameQualified.php b/vendor/phpunit/php-token-stream/src/NameQualified.php deleted file mode 100644 index a893144c0..000000000 --- a/vendor/phpunit/php-token-stream/src/NameQualified.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_NAME_QUALIFIED extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/NameRelative.php b/vendor/phpunit/php-token-stream/src/NameRelative.php deleted file mode 100644 index 0b358cc64..000000000 --- a/vendor/phpunit/php-token-stream/src/NameRelative.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_NAME_RELATIVE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Namespace.php b/vendor/phpunit/php-token-stream/src/Namespace.php deleted file mode 100644 index 634d8ad76..000000000 --- a/vendor/phpunit/php-token-stream/src/Namespace.php +++ /dev/null @@ -1,31 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_NAMESPACE extends PHP_TokenWithScope -{ - /** - * @return string - */ - public function getName() - { - $tokens = $this->tokenStream->tokens(); - $namespace = (string) $tokens[$this->id + 2]; - - for ($i = $this->id + 3;; $i += 2) { - if (isset($tokens[$i]) && - $tokens[$i] instanceof PHP_Token_NS_SEPARATOR) { - $namespace .= '\\' . $tokens[$i + 1]; - } else { - break; - } - } - - return $namespace; - } -} diff --git a/vendor/phpunit/php-token-stream/src/New.php b/vendor/phpunit/php-token-stream/src/New.php deleted file mode 100644 index bd67af28b..000000000 --- a/vendor/phpunit/php-token-stream/src/New.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_NEW extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/NsC.php b/vendor/phpunit/php-token-stream/src/NsC.php deleted file mode 100644 index 2778ea4cd..000000000 --- a/vendor/phpunit/php-token-stream/src/NsC.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_NS_C extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/NsSeparator.php b/vendor/phpunit/php-token-stream/src/NsSeparator.php deleted file mode 100644 index 950291ed9..000000000 --- a/vendor/phpunit/php-token-stream/src/NsSeparator.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_NS_SEPARATOR extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/NumString.php b/vendor/phpunit/php-token-stream/src/NumString.php deleted file mode 100644 index a073e3d06..000000000 --- a/vendor/phpunit/php-token-stream/src/NumString.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_NUM_STRING extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/ObjectCast.php b/vendor/phpunit/php-token-stream/src/ObjectCast.php deleted file mode 100644 index c0ec7d5b7..000000000 --- a/vendor/phpunit/php-token-stream/src/ObjectCast.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_OBJECT_CAST extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/ObjectOperator.php b/vendor/phpunit/php-token-stream/src/ObjectOperator.php deleted file mode 100644 index a4ca75b81..000000000 --- a/vendor/phpunit/php-token-stream/src/ObjectOperator.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_OBJECT_OPERATOR extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/OpenBracket.php b/vendor/phpunit/php-token-stream/src/OpenBracket.php deleted file mode 100644 index 2cb93ed20..000000000 --- a/vendor/phpunit/php-token-stream/src/OpenBracket.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_OPEN_BRACKET extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/OpenCurly.php b/vendor/phpunit/php-token-stream/src/OpenCurly.php deleted file mode 100644 index 59c118d1b..000000000 --- a/vendor/phpunit/php-token-stream/src/OpenCurly.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_OPEN_CURLY extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/OpenSquare.php b/vendor/phpunit/php-token-stream/src/OpenSquare.php deleted file mode 100644 index 04cfefab0..000000000 --- a/vendor/phpunit/php-token-stream/src/OpenSquare.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_OPEN_SQUARE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/OpenTag.php b/vendor/phpunit/php-token-stream/src/OpenTag.php deleted file mode 100644 index d3e00239e..000000000 --- a/vendor/phpunit/php-token-stream/src/OpenTag.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_OPEN_TAG extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/OpenTagWithEcho.php b/vendor/phpunit/php-token-stream/src/OpenTagWithEcho.php deleted file mode 100644 index ec981a2a3..000000000 --- a/vendor/phpunit/php-token-stream/src/OpenTagWithEcho.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_OPEN_TAG_WITH_ECHO extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/OrEqual.php b/vendor/phpunit/php-token-stream/src/OrEqual.php deleted file mode 100644 index 8e7005df2..000000000 --- a/vendor/phpunit/php-token-stream/src/OrEqual.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_OR_EQUAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/PaamayimNekudotayim.php b/vendor/phpunit/php-token-stream/src/PaamayimNekudotayim.php deleted file mode 100644 index 3185555d9..000000000 --- a/vendor/phpunit/php-token-stream/src/PaamayimNekudotayim.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_PAAMAYIM_NEKUDOTAYIM extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Percent.php b/vendor/phpunit/php-token-stream/src/Percent.php deleted file mode 100644 index a2baab533..000000000 --- a/vendor/phpunit/php-token-stream/src/Percent.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_PERCENT extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Pipe.php b/vendor/phpunit/php-token-stream/src/Pipe.php deleted file mode 100644 index 4e9438fd9..000000000 --- a/vendor/phpunit/php-token-stream/src/Pipe.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_PIPE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Plus.php b/vendor/phpunit/php-token-stream/src/Plus.php deleted file mode 100644 index 5a4ae324c..000000000 --- a/vendor/phpunit/php-token-stream/src/Plus.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_PLUS extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/PlusEqual.php b/vendor/phpunit/php-token-stream/src/PlusEqual.php deleted file mode 100644 index 23825f377..000000000 --- a/vendor/phpunit/php-token-stream/src/PlusEqual.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_PLUS_EQUAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Pow.php b/vendor/phpunit/php-token-stream/src/Pow.php deleted file mode 100644 index 84276d73d..000000000 --- a/vendor/phpunit/php-token-stream/src/Pow.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_POW extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/PowEqual.php b/vendor/phpunit/php-token-stream/src/PowEqual.php deleted file mode 100644 index 5e5288db7..000000000 --- a/vendor/phpunit/php-token-stream/src/PowEqual.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_POW_EQUAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Print.php b/vendor/phpunit/php-token-stream/src/Print.php deleted file mode 100644 index 72ef8e6ab..000000000 --- a/vendor/phpunit/php-token-stream/src/Print.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_PRINT extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Private.php b/vendor/phpunit/php-token-stream/src/Private.php deleted file mode 100644 index 0eb36d522..000000000 --- a/vendor/phpunit/php-token-stream/src/Private.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_PRIVATE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Protected.php b/vendor/phpunit/php-token-stream/src/Protected.php deleted file mode 100644 index 9c9cc33ba..000000000 --- a/vendor/phpunit/php-token-stream/src/Protected.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_PROTECTED extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Public.php b/vendor/phpunit/php-token-stream/src/Public.php deleted file mode 100644 index b37d4a94d..000000000 --- a/vendor/phpunit/php-token-stream/src/Public.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_PUBLIC extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/QuestionMark.php b/vendor/phpunit/php-token-stream/src/QuestionMark.php deleted file mode 100644 index 4202d5921..000000000 --- a/vendor/phpunit/php-token-stream/src/QuestionMark.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_QUESTION_MARK extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Require.php b/vendor/phpunit/php-token-stream/src/Require.php deleted file mode 100644 index e18c03fcc..000000000 --- a/vendor/phpunit/php-token-stream/src/Require.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_REQUIRE extends PHP_Token_Includes -{ -} diff --git a/vendor/phpunit/php-token-stream/src/RequireOnce.php b/vendor/phpunit/php-token-stream/src/RequireOnce.php deleted file mode 100644 index 15628a3a8..000000000 --- a/vendor/phpunit/php-token-stream/src/RequireOnce.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_REQUIRE_ONCE extends PHP_Token_Includes -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Return.php b/vendor/phpunit/php-token-stream/src/Return.php deleted file mode 100644 index acdbc23b1..000000000 --- a/vendor/phpunit/php-token-stream/src/Return.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_RETURN extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Semicolon.php b/vendor/phpunit/php-token-stream/src/Semicolon.php deleted file mode 100644 index 47bfa5e16..000000000 --- a/vendor/phpunit/php-token-stream/src/Semicolon.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_SEMICOLON extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Sl.php b/vendor/phpunit/php-token-stream/src/Sl.php deleted file mode 100644 index cda5ecc11..000000000 --- a/vendor/phpunit/php-token-stream/src/Sl.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_SL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/SlEqual.php b/vendor/phpunit/php-token-stream/src/SlEqual.php deleted file mode 100644 index 3d8a17e5a..000000000 --- a/vendor/phpunit/php-token-stream/src/SlEqual.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_SL_EQUAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Spaceship.php b/vendor/phpunit/php-token-stream/src/Spaceship.php deleted file mode 100644 index 639a2e30a..000000000 --- a/vendor/phpunit/php-token-stream/src/Spaceship.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_SPACESHIP extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Sr.php b/vendor/phpunit/php-token-stream/src/Sr.php deleted file mode 100644 index 749bf0da5..000000000 --- a/vendor/phpunit/php-token-stream/src/Sr.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_SR extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/SrEqual.php b/vendor/phpunit/php-token-stream/src/SrEqual.php deleted file mode 100644 index 674039fbd..000000000 --- a/vendor/phpunit/php-token-stream/src/SrEqual.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_SR_EQUAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/StartHeredoc.php b/vendor/phpunit/php-token-stream/src/StartHeredoc.php deleted file mode 100644 index 867a35760..000000000 --- a/vendor/phpunit/php-token-stream/src/StartHeredoc.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_START_HEREDOC extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Static.php b/vendor/phpunit/php-token-stream/src/Static.php deleted file mode 100644 index 53307ce29..000000000 --- a/vendor/phpunit/php-token-stream/src/Static.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_STATIC extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Stream.php b/vendor/phpunit/php-token-stream/src/Stream.php deleted file mode 100644 index bcdb48a73..000000000 --- a/vendor/phpunit/php-token-stream/src/Stream.php +++ /dev/null @@ -1,658 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_Stream implements ArrayAccess, Countable, SeekableIterator -{ - /** - * @var array> - */ - protected static $customTokens = [ - '(' => PHP_Token_OPEN_BRACKET::class, - ')' => PHP_Token_CLOSE_BRACKET::class, - '[' => PHP_Token_OPEN_SQUARE::class, - ']' => PHP_Token_CLOSE_SQUARE::class, - '{' => PHP_Token_OPEN_CURLY::class, - '}' => PHP_Token_CLOSE_CURLY::class, - ';' => PHP_Token_SEMICOLON::class, - '.' => PHP_Token_DOT::class, - ',' => PHP_Token_COMMA::class, - '=' => PHP_Token_EQUAL::class, - '<' => PHP_Token_LT::class, - '>' => PHP_Token_GT::class, - '+' => PHP_Token_PLUS::class, - '-' => PHP_Token_MINUS::class, - '*' => PHP_Token_MULT::class, - '/' => PHP_Token_DIV::class, - '?' => PHP_Token_QUESTION_MARK::class, - '!' => PHP_Token_EXCLAMATION_MARK::class, - ':' => PHP_Token_COLON::class, - '"' => PHP_Token_DOUBLE_QUOTES::class, - '@' => PHP_Token_AT::class, - '&' => PHP_Token_AMPERSAND::class, - '%' => PHP_Token_PERCENT::class, - '|' => PHP_Token_PIPE::class, - '$' => PHP_Token_DOLLAR::class, - '^' => PHP_Token_CARET::class, - '~' => PHP_Token_TILDE::class, - '`' => PHP_Token_BACKTICK::class, - ]; - - /** - * @var string - */ - protected $filename; - - /** - * @var array - */ - protected $tokens = []; - - /** - * @var array - */ - protected $tokensByLine = []; - - /** - * @var int - */ - protected $position = 0; - - /** - * @var array - */ - protected $linesOfCode = ['loc' => 0, 'cloc' => 0, 'ncloc' => 0]; - - /** - * @var array - */ - protected $classes; - - /** - * @var array - */ - protected $functions; - - /** - * @var array - */ - protected $includes; - - /** - * @var array - */ - protected $interfaces; - - /** - * @var array - */ - protected $traits; - - /** - * @var array - */ - protected $lineToFunctionMap = []; - - /** - * Constructor. - * - * @param string $sourceCode - */ - public function __construct($sourceCode) - { - if (\is_file($sourceCode)) { - $this->filename = $sourceCode; - $sourceCode = \file_get_contents($sourceCode); - } - - $this->scan($sourceCode); - } - - /** - * Destructor. - */ - public function __destruct() - { - $this->tokens = []; - $this->tokensByLine = []; - } - - /** - * @return string - */ - public function __toString() - { - $buffer = ''; - - foreach ($this as $token) { - $buffer .= $token; - } - - return $buffer; - } - - /** - * @return string - */ - public function getFilename() - { - return $this->filename; - } - - /** - * @return int - */ - public function count() - { - return \count($this->tokens); - } - - /** - * @return PHP_Token[] - */ - public function tokens() - { - return $this->tokens; - } - - /** - * @return array - */ - public function getClasses() - { - if ($this->classes !== null) { - return $this->classes; - } - - $this->parse(); - - return $this->classes; - } - - /** - * @return array - */ - public function getFunctions() - { - if ($this->functions !== null) { - return $this->functions; - } - - $this->parse(); - - return $this->functions; - } - - /** - * @return array - */ - public function getInterfaces() - { - if ($this->interfaces !== null) { - return $this->interfaces; - } - - $this->parse(); - - return $this->interfaces; - } - - /** - * @return array - */ - public function getTraits() - { - if ($this->traits !== null) { - return $this->traits; - } - - $this->parse(); - - return $this->traits; - } - - /** - * Gets the names of all files that have been included - * using include(), include_once(), require() or require_once(). - * - * Parameter $categorize set to TRUE causing this function to return a - * multi-dimensional array with categories in the keys of the first dimension - * and constants and their values in the second dimension. - * - * Parameter $category allow to filter following specific inclusion type - * - * @param bool $categorize OPTIONAL - * @param string $category OPTIONAL Either 'require_once', 'require', - * 'include_once', 'include' - * - * @return array - */ - public function getIncludes($categorize = false, $category = null) - { - if ($this->includes === null) { - $this->includes = [ - 'require_once' => [], - 'require' => [], - 'include_once' => [], - 'include' => [], - ]; - - foreach ($this->tokens as $token) { - switch (\get_class($token)) { - case PHP_Token_REQUIRE_ONCE::class: - case PHP_Token_REQUIRE::class: - case PHP_Token_INCLUDE_ONCE::class: - case PHP_Token_INCLUDE::class: - $this->includes[$token->getType()][] = $token->getName(); - - break; - } - } - } - - if (isset($this->includes[$category])) { - $includes = $this->includes[$category]; - } elseif ($categorize === false) { - $includes = \array_merge( - $this->includes['require_once'], - $this->includes['require'], - $this->includes['include_once'], - $this->includes['include'] - ); - } else { - $includes = $this->includes; - } - - return $includes; - } - - /** - * Returns the name of the function or method a line belongs to. - * - * @return string or null if the line is not in a function or method - */ - public function getFunctionForLine($line) - { - $this->parse(); - - if (isset($this->lineToFunctionMap[$line])) { - return $this->lineToFunctionMap[$line]; - } - } - - /** - * @return array - */ - public function getLinesOfCode() - { - return $this->linesOfCode; - } - - public function rewind()/*: void*/ - { - $this->position = 0; - } - - /** - * @return bool - */ - public function valid() - { - return isset($this->tokens[$this->position]); - } - - /** - * @return int - */ - public function key() - { - return $this->position; - } - - /** - * @return PHP_Token - */ - public function current() - { - return $this->tokens[$this->position]; - } - - public function next()/*: void*/ - { - $this->position++; - } - - /** - * @param int $offset - * - * @return bool - */ - public function offsetExists($offset) - { - return isset($this->tokens[$offset]); - } - - /** - * @param int $offset - * - * @throws OutOfBoundsException - */ - public function offsetGet($offset) - { - if (!$this->offsetExists($offset)) { - throw new OutOfBoundsException( - \sprintf( - 'No token at position "%s"', - $offset - ) - ); - } - - return $this->tokens[$offset]; - } - - /** - * @param int $offset - */ - public function offsetSet($offset, $value)/*: void*/ - { - $this->tokens[$offset] = $value; - } - - /** - * @param int $offset - * - * @throws OutOfBoundsException - */ - public function offsetUnset($offset)/*: void*/ - { - if (!$this->offsetExists($offset)) { - throw new OutOfBoundsException( - \sprintf( - 'No token at position "%s"', - $offset - ) - ); - } - - unset($this->tokens[$offset]); - } - - /** - * Seek to an absolute position. - * - * @param int $position - * - * @throws OutOfBoundsException - */ - public function seek($position)/*: void*/ - { - $this->position = $position; - - if (!$this->valid()) { - throw new OutOfBoundsException( - \sprintf( - 'No token at position "%s"', - $this->position - ) - ); - } - } - - /** - * Scans the source for sequences of characters and converts them into a - * stream of tokens. - * - * @param string $sourceCode - */ - protected function scan($sourceCode)/*: void*/ - { - $id = 0; - $line = 1; - $tokens = \token_get_all($sourceCode); - $numTokens = \count($tokens); - - $lastNonWhitespaceTokenWasDoubleColon = false; - - $name = null; - - for ($i = 0; $i < $numTokens; ++$i) { - $token = $tokens[$i]; - $skip = 0; - - if (\is_array($token)) { - $name = \substr(\token_name($token[0]), 2); - $text = $token[1]; - - if ($lastNonWhitespaceTokenWasDoubleColon && $name == 'CLASS') { - $name = 'CLASS_NAME_CONSTANT'; - } elseif ($name == 'USE' && isset($tokens[$i + 2][0]) && $tokens[$i + 2][0] == \T_FUNCTION) { - $name = 'USE_FUNCTION'; - $text .= $tokens[$i + 1][1] . $tokens[$i + 2][1]; - $skip = 2; - } - - /** @var class-string $tokenClass */ - $tokenClass = 'PHP_Token_' . $name; - } else { - $text = $token; - $tokenClass = self::$customTokens[$token]; - } - - /* - * @see https://github.com/sebastianbergmann/php-token-stream/issues/95 - */ - if (PHP_MAJOR_VERSION >= 8 && - $name === 'WHITESPACE' && // Current token is T_WHITESPACE - isset($this->tokens[$id - 1]) && // Current token is not the first token - $this->tokens[$id - 1] instanceof PHP_Token_COMMENT && // Previous token is T_COMMENT - strpos((string) $this->tokens[$id - 1], '/*') === false && // Previous token is comment that starts with '#' or '//' - strpos($text, "\n") === 0 // Text of current token begins with newline - ) { - $this->tokens[$id - 1] = new PHP_Token_COMMENT( - $this->tokens[$id - 1] . "\n", - $this->tokens[$id - 1]->getLine(), - $this, - $id - 1 - ); - - $text = substr($text, 1); - - $line++; - - if (empty($text)) { - continue; - } - } - - if (!isset($this->tokensByLine[$line])) { - $this->tokensByLine[$line] = []; - } - - $token = new $tokenClass($text, $line, $this, $id++); - - $this->tokens[] = $token; - $this->tokensByLine[$line][] = $token; - - $line += \substr_count($text, "\n"); - - if ($tokenClass == PHP_Token_HALT_COMPILER::class) { - break; - } - - if ($name == 'DOUBLE_COLON') { - $lastNonWhitespaceTokenWasDoubleColon = true; - } elseif ($name != 'WHITESPACE') { - $lastNonWhitespaceTokenWasDoubleColon = false; - } - - $i += $skip; - } - - foreach ($this->tokens as $token) { - if (!$token instanceof PHP_Token_COMMENT && !$token instanceof PHP_Token_DOC_COMMENT) { - continue; - } - - foreach ($this->tokensByLine[$token->getLine()] as $_token) { - if (!$_token instanceof PHP_Token_COMMENT && !$_token instanceof PHP_Token_DOC_COMMENT && !$_token instanceof PHP_Token_WHITESPACE) { - continue 2; - } - } - - $this->linesOfCode['cloc'] += max(1, \substr_count((string) $token, "\n")); - } - - $this->linesOfCode['loc'] = \substr_count($sourceCode, "\n"); - $this->linesOfCode['ncloc'] = $this->linesOfCode['loc'] - - $this->linesOfCode['cloc']; - } - - protected function parse()/*: void*/ - { - $this->interfaces = []; - $this->classes = []; - $this->traits = []; - $this->functions = []; - $class = []; - $classEndLine = []; - $trait = false; - $traitEndLine = false; - $interface = false; - $interfaceEndLine = false; - - foreach ($this->tokens as $token) { - switch (\get_class($token)) { - case PHP_Token_HALT_COMPILER::class: - return; - - case PHP_Token_INTERFACE::class: - $interface = $token->getName(); - $interfaceEndLine = $token->getEndLine(); - - $this->interfaces[$interface] = [ - 'methods' => [], - 'parent' => $token->getParent(), - 'keywords' => $token->getKeywords(), - 'docblock' => $token->getDocblock(), - 'startLine' => $token->getLine(), - 'endLine' => $interfaceEndLine, - 'package' => $token->getPackage(), - 'file' => $this->filename, - ]; - - break; - - case PHP_Token_CLASS::class: - case PHP_Token_TRAIT::class: - $tmp = [ - 'methods' => [], - 'parent' => $token->getParent(), - 'interfaces'=> $token->getInterfaces(), - 'keywords' => $token->getKeywords(), - 'docblock' => $token->getDocblock(), - 'startLine' => $token->getLine(), - 'endLine' => $token->getEndLine(), - 'package' => $token->getPackage(), - 'file' => $this->filename, - ]; - - if ($token instanceof PHP_Token_CLASS) { - $class[] = $token->getName(); - $classEndLine[] = $token->getEndLine(); - - if ($token->getName() !== null) { - $this->classes[$class[\count($class) - 1]] = $tmp; - } - } else { - $trait = $token->getName(); - $traitEndLine = $token->getEndLine(); - $this->traits[$trait] = $tmp; - } - - break; - - case PHP_Token_FUNCTION::class: - $name = $token->getName(); - $tmp = [ - 'docblock' => $token->getDocblock(), - 'keywords' => $token->getKeywords(), - 'visibility'=> $token->getVisibility(), - 'signature' => $token->getSignature(), - 'startLine' => $token->getLine(), - 'endLine' => $token->getEndLine(), - 'ccn' => $token->getCCN(), - 'file' => $this->filename, - ]; - - if (empty($class) && - $trait === false && - $interface === false) { - $this->functions[$name] = $tmp; - - $this->addFunctionToMap( - $name, - $tmp['startLine'], - $tmp['endLine'] - ); - } elseif (!empty($class)) { - if ($class[\count($class) - 1] !== null) { - $this->classes[$class[\count($class) - 1]]['methods'][$name] = $tmp; - - $this->addFunctionToMap( - $class[\count($class) - 1] . '::' . $name, - $tmp['startLine'], - $tmp['endLine'] - ); - } - } elseif ($trait !== false) { - $this->traits[$trait]['methods'][$name] = $tmp; - - $this->addFunctionToMap( - $trait . '::' . $name, - $tmp['startLine'], - $tmp['endLine'] - ); - } else { - $this->interfaces[$interface]['methods'][$name] = $tmp; - } - - break; - - case PHP_Token_CLOSE_CURLY::class: - if (!empty($classEndLine) && - $classEndLine[\count($classEndLine) - 1] == $token->getLine()) { - \array_pop($classEndLine); - \array_pop($class); - } elseif ($traitEndLine !== false && - $traitEndLine == $token->getLine()) { - $trait = false; - $traitEndLine = false; - } elseif ($interfaceEndLine !== false && - $interfaceEndLine == $token->getLine()) { - $interface = false; - $interfaceEndLine = false; - } - - break; - } - } - } - - /** - * @param string $name - * @param int $startLine - * @param int $endLine - */ - private function addFunctionToMap($name, $startLine, $endLine): void - { - for ($line = $startLine; $line <= $endLine; $line++) { - $this->lineToFunctionMap[$line] = $name; - } - } -} diff --git a/vendor/phpunit/php-token-stream/src/String.php b/vendor/phpunit/php-token-stream/src/String.php deleted file mode 100644 index 89deb0048..000000000 --- a/vendor/phpunit/php-token-stream/src/String.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_STRING extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/StringCast.php b/vendor/phpunit/php-token-stream/src/StringCast.php deleted file mode 100644 index f2df377ce..000000000 --- a/vendor/phpunit/php-token-stream/src/StringCast.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_STRING_CAST extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/StringVarname.php b/vendor/phpunit/php-token-stream/src/StringVarname.php deleted file mode 100644 index 9012f1f9b..000000000 --- a/vendor/phpunit/php-token-stream/src/StringVarname.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_STRING_VARNAME extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Switch.php b/vendor/phpunit/php-token-stream/src/Switch.php deleted file mode 100644 index 030d43b52..000000000 --- a/vendor/phpunit/php-token-stream/src/Switch.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_SWITCH extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Throw.php b/vendor/phpunit/php-token-stream/src/Throw.php deleted file mode 100644 index 213fda067..000000000 --- a/vendor/phpunit/php-token-stream/src/Throw.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_THROW extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Tilde.php b/vendor/phpunit/php-token-stream/src/Tilde.php deleted file mode 100644 index c6c6ca5b9..000000000 --- a/vendor/phpunit/php-token-stream/src/Tilde.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_TILDE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Token.php b/vendor/phpunit/php-token-stream/src/Token.php deleted file mode 100644 index d6280f3e9..000000000 --- a/vendor/phpunit/php-token-stream/src/Token.php +++ /dev/null @@ -1,68 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -abstract class PHP_Token -{ - /** - * @var string - */ - protected $text; - - /** - * @var int - */ - protected $line; - - /** - * @var PHP_Token_Stream - */ - protected $tokenStream; - - /** - * @var int - */ - protected $id; - - /** - * @param string $text - * @param int $line - * @param int $id - */ - public function __construct($text, $line, PHP_Token_Stream $tokenStream, $id) - { - $this->text = $text; - $this->line = $line; - $this->tokenStream = $tokenStream; - $this->id = $id; - } - - /** - * @return string - */ - public function __toString() - { - return $this->text; - } - - /** - * @return int - */ - public function getLine() - { - return $this->line; - } - - /** - * @return int - */ - public function getId() - { - return $this->id; - } -} diff --git a/vendor/phpunit/php-token-stream/src/TokenWithScope.php b/vendor/phpunit/php-token-stream/src/TokenWithScope.php deleted file mode 100644 index 876b3508b..000000000 --- a/vendor/phpunit/php-token-stream/src/TokenWithScope.php +++ /dev/null @@ -1,107 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -abstract class PHP_TokenWithScope extends PHP_Token -{ - /** - * @var int - */ - protected $endTokenId; - - /** - * Get the docblock for this token. - * - * This method will fetch the docblock belonging to the current token. The - * docblock must be placed on the line directly above the token to be - * recognized. - * - * @return null|string Returns the docblock as a string if found - */ - public function getDocblock() - { - $tokens = $this->tokenStream->tokens(); - $currentLineNumber = $tokens[$this->id]->getLine(); - $prevLineNumber = $currentLineNumber - 1; - - for ($i = $this->id - 1; $i; $i--) { - if (!isset($tokens[$i])) { - return; - } - - if ($tokens[$i] instanceof PHP_Token_FUNCTION || - $tokens[$i] instanceof PHP_Token_CLASS || - $tokens[$i] instanceof PHP_Token_TRAIT) { - // Some other trait, class or function, no docblock can be - // used for the current token - break; - } - - $line = $tokens[$i]->getLine(); - - if ($line == $currentLineNumber || - ($line == $prevLineNumber && - $tokens[$i] instanceof PHP_Token_WHITESPACE)) { - continue; - } - - if ($line < $currentLineNumber && - !$tokens[$i] instanceof PHP_Token_DOC_COMMENT) { - break; - } - - return (string) $tokens[$i]; - } - } - - /** - * @return int - */ - public function getEndTokenId() - { - $block = 0; - $i = $this->id; - $tokens = $this->tokenStream->tokens(); - - while ($this->endTokenId === null && isset($tokens[$i])) { - if ($tokens[$i] instanceof PHP_Token_OPEN_CURLY || - $tokens[$i] instanceof PHP_Token_DOLLAR_OPEN_CURLY_BRACES || - $tokens[$i] instanceof PHP_Token_CURLY_OPEN) { - $block++; - } elseif ($tokens[$i] instanceof PHP_Token_CLOSE_CURLY) { - $block--; - - if ($block === 0) { - $this->endTokenId = $i; - } - } elseif (($this instanceof PHP_Token_FUNCTION || - $this instanceof PHP_Token_NAMESPACE) && - $tokens[$i] instanceof PHP_Token_SEMICOLON) { - if ($block === 0) { - $this->endTokenId = $i; - } - } - - $i++; - } - - if ($this->endTokenId === null) { - $this->endTokenId = $this->id; - } - - return $this->endTokenId; - } - - /** - * @return int - */ - public function getEndLine() - { - return $this->tokenStream[$this->getEndTokenId()]->getLine(); - } -} diff --git a/vendor/phpunit/php-token-stream/src/TokenWithScopeAndVisibility.php b/vendor/phpunit/php-token-stream/src/TokenWithScopeAndVisibility.php deleted file mode 100644 index fce0c8ea2..000000000 --- a/vendor/phpunit/php-token-stream/src/TokenWithScopeAndVisibility.php +++ /dev/null @@ -1,67 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -abstract class PHP_TokenWithScopeAndVisibility extends PHP_TokenWithScope -{ - /** - * @return string - */ - public function getVisibility() - { - $tokens = $this->tokenStream->tokens(); - - for ($i = $this->id - 2; $i > $this->id - 7; $i -= 2) { - if (isset($tokens[$i]) && - ($tokens[$i] instanceof PHP_Token_PRIVATE || - $tokens[$i] instanceof PHP_Token_PROTECTED || - $tokens[$i] instanceof PHP_Token_PUBLIC)) { - return \strtolower( - \str_replace('PHP_Token_', '', PHP_Token_Util::getClass($tokens[$i])) - ); - } - - if (isset($tokens[$i]) && - !($tokens[$i] instanceof PHP_Token_STATIC || - $tokens[$i] instanceof PHP_Token_FINAL || - $tokens[$i] instanceof PHP_Token_ABSTRACT)) { - // no keywords; stop visibility search - break; - } - } - } - - /** - * @return string - */ - public function getKeywords() - { - $keywords = []; - $tokens = $this->tokenStream->tokens(); - - for ($i = $this->id - 2; $i > $this->id - 7; $i -= 2) { - if (isset($tokens[$i]) && - ($tokens[$i] instanceof PHP_Token_PRIVATE || - $tokens[$i] instanceof PHP_Token_PROTECTED || - $tokens[$i] instanceof PHP_Token_PUBLIC)) { - continue; - } - - if (isset($tokens[$i]) && - ($tokens[$i] instanceof PHP_Token_STATIC || - $tokens[$i] instanceof PHP_Token_FINAL || - $tokens[$i] instanceof PHP_Token_ABSTRACT)) { - $keywords[] = \strtolower( - \str_replace('PHP_Token_', '', PHP_Token_Util::getClass($tokens[$i])) - ); - } - } - - return \implode(',', $keywords); - } -} diff --git a/vendor/phpunit/php-token-stream/src/Trait.php b/vendor/phpunit/php-token-stream/src/Trait.php deleted file mode 100644 index f635f5dfb..000000000 --- a/vendor/phpunit/php-token-stream/src/Trait.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_TRAIT extends PHP_Token_INTERFACE -{ -} diff --git a/vendor/phpunit/php-token-stream/src/TraitC.php b/vendor/phpunit/php-token-stream/src/TraitC.php deleted file mode 100644 index ae4b2a5ae..000000000 --- a/vendor/phpunit/php-token-stream/src/TraitC.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_TRAIT_C extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Try.php b/vendor/phpunit/php-token-stream/src/Try.php deleted file mode 100644 index 8c3783e89..000000000 --- a/vendor/phpunit/php-token-stream/src/Try.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_TRY extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Unset.php b/vendor/phpunit/php-token-stream/src/Unset.php deleted file mode 100644 index 3d39d0b68..000000000 --- a/vendor/phpunit/php-token-stream/src/Unset.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_UNSET extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/UnsetCast.php b/vendor/phpunit/php-token-stream/src/UnsetCast.php deleted file mode 100644 index 133ef29fc..000000000 --- a/vendor/phpunit/php-token-stream/src/UnsetCast.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_UNSET_CAST extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Use.php b/vendor/phpunit/php-token-stream/src/Use.php deleted file mode 100644 index e62a54972..000000000 --- a/vendor/phpunit/php-token-stream/src/Use.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_USE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/UseFunction.php b/vendor/phpunit/php-token-stream/src/UseFunction.php deleted file mode 100644 index 8250864a9..000000000 --- a/vendor/phpunit/php-token-stream/src/UseFunction.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_USE_FUNCTION extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Util.php b/vendor/phpunit/php-token-stream/src/Util.php deleted file mode 100644 index 13b636c21..000000000 --- a/vendor/phpunit/php-token-stream/src/Util.php +++ /dev/null @@ -1,18 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -final class PHP_Token_Util -{ - public static function getClass($object): string - { - $parts = \explode('\\', \get_class($object)); - - return \array_pop($parts); - } -} diff --git a/vendor/phpunit/php-token-stream/src/Var.php b/vendor/phpunit/php-token-stream/src/Var.php deleted file mode 100644 index 3dbd16ff2..000000000 --- a/vendor/phpunit/php-token-stream/src/Var.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_VAR extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Variable.php b/vendor/phpunit/php-token-stream/src/Variable.php deleted file mode 100644 index 921e3ae85..000000000 --- a/vendor/phpunit/php-token-stream/src/Variable.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_VARIABLE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/While.php b/vendor/phpunit/php-token-stream/src/While.php deleted file mode 100644 index e92409fff..000000000 --- a/vendor/phpunit/php-token-stream/src/While.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_WHILE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Whitespace.php b/vendor/phpunit/php-token-stream/src/Whitespace.php deleted file mode 100644 index 6b5b641ca..000000000 --- a/vendor/phpunit/php-token-stream/src/Whitespace.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_WHITESPACE extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/XorEqual.php b/vendor/phpunit/php-token-stream/src/XorEqual.php deleted file mode 100644 index 0095b283e..000000000 --- a/vendor/phpunit/php-token-stream/src/XorEqual.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_XOR_EQUAL extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/Yield.php b/vendor/phpunit/php-token-stream/src/Yield.php deleted file mode 100644 index 3fecb6c10..000000000 --- a/vendor/phpunit/php-token-stream/src/Yield.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_YIELD extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/YieldFrom.php b/vendor/phpunit/php-token-stream/src/YieldFrom.php deleted file mode 100644 index 8f1a71680..000000000 --- a/vendor/phpunit/php-token-stream/src/YieldFrom.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_YIELD_FROM extends PHP_Token -{ -} diff --git a/vendor/phpunit/php-token-stream/src/break.php b/vendor/phpunit/php-token-stream/src/break.php deleted file mode 100644 index 97e96fee4..000000000 --- a/vendor/phpunit/php-token-stream/src/break.php +++ /dev/null @@ -1,12 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -class PHP_Token_BREAK extends PHP_Token -{ -} diff --git a/vendor/phpunit/phpunit/ChangeLog-9.5.md b/vendor/phpunit/phpunit/ChangeLog-9.5.md new file mode 100644 index 000000000..727d17bae --- /dev/null +++ b/vendor/phpunit/phpunit/ChangeLog-9.5.md @@ -0,0 +1,48 @@ +# Changes in PHPUnit 9.5 + +All notable changes of the PHPUnit 9.5 release series are documented in this file using the [Keep a CHANGELOG](https://keepachangelog.com/) principles. + +## [9.5.4] - 2021-03-23 + +### Fixed + +* [#4630](https://github.com/sebastianbergmann/phpunit/issues/4630): Empty test case class causes error in TestDox XML logger + +## [9.5.3] - 2021-03-17 + +### Fixed + +* [#4591](https://github.com/sebastianbergmann/phpunit/issues/4591): TeamCity logger logs warnings as test failures +* [#4620](https://github.com/sebastianbergmann/phpunit/issues/4620): No useful output when an error occurs in the bootstrap script + +## [9.5.2] - 2021-02-02 + +### Fixed + +* [#4573](https://github.com/sebastianbergmann/phpunit/issues/4573): No stack trace printed when PHPUnit is used from PHAR +* [#4590](https://github.com/sebastianbergmann/phpunit/issues/4590): `--coverage-text` CLI option is documented wrong + +## [9.5.1] - 2021-01-17 + +### Fixed + +* [#4572](https://github.com/sebastianbergmann/phpunit/issues/4572): Schema validation does not work with `%xx` sequences in path to `phpunit.xsd` + +## [9.5.0] - 2020-12-04 + +### Changed + +* [#4490](https://github.com/sebastianbergmann/phpunit/issues/4490): Emit Error instead of Warning when test case class cannot be instantiated +* [#4491](https://github.com/sebastianbergmann/phpunit/issues/4491): Emit Error instead of Warning when data provider does not work correctly +* [#4492](https://github.com/sebastianbergmann/phpunit/issues/4492): Emit Error instead of Warning when test double configuration is invalid +* [#4493](https://github.com/sebastianbergmann/phpunit/issues/4493): Emit error when (configured) test directory does not exist + +### Fixed + +* [#4535](https://github.com/sebastianbergmann/phpunit/issues/4535): `getMockFromWsdl()` does not handle methods that do not have parameters correctly + +[9.5.4]: https://github.com/sebastianbergmann/phpunit/compare/9.5.3...9.5.4 +[9.5.3]: https://github.com/sebastianbergmann/phpunit/compare/9.5.2...9.5.3 +[9.5.2]: https://github.com/sebastianbergmann/phpunit/compare/9.5.1...9.5.2 +[9.5.1]: https://github.com/sebastianbergmann/phpunit/compare/9.5.0...9.5.1 +[9.5.0]: https://github.com/sebastianbergmann/phpunit/compare/9.4.4...9.5.0 diff --git a/vendor/phpunit/phpunit/README.md b/vendor/phpunit/phpunit/README.md index edf80e4a2..d6bb0846c 100644 --- a/vendor/phpunit/phpunit/README.md +++ b/vendor/phpunit/phpunit/README.md @@ -3,18 +3,18 @@ PHPUnit is a programmer-oriented testing framework for PHP. It is an instance of the xUnit architecture for unit testing frameworks. [![Latest Stable Version](https://img.shields.io/packagist/v/phpunit/phpunit.svg?style=flat-square)](https://packagist.org/packages/phpunit/phpunit) -[![Minimum PHP Version](https://img.shields.io/badge/php-%3E%3D%207.2-8892BF.svg?style=flat-square)](https://php.net/) -[![CI Status](https://github.com/sebastianbergmann/phpunit/workflows/CI/badge.svg?branch=8.5&event=push)](https://phpunit.de/build-status.html) +[![Minimum PHP Version](https://img.shields.io/badge/php-%3E%3D%207.3-8892BF.svg?style=flat-square)](https://php.net/) +[![CI Status](https://github.com/sebastianbergmann/phpunit/workflows/CI/badge.svg?branch=9.5&event=push)](https://phpunit.de/build-status.html) [![Type Coverage](https://shepherd.dev/github/sebastianbergmann/phpunit/coverage.svg)](https://shepherd.dev/github/sebastianbergmann/phpunit) ## Installation -We distribute a [PHP Archive (PHAR)](https://php.net/phar) that has all required (as well as some optional) dependencies of PHPUnit 8.5 bundled in a single file: +We distribute a [PHP Archive (PHAR)](https://php.net/phar) that has all required (as well as some optional) dependencies of PHPUnit 9.5 bundled in a single file: ```bash -$ wget https://phar.phpunit.de/phpunit-8.5.phar +$ wget https://phar.phpunit.de/phpunit-9.5.phar -$ php phpunit-8.5.phar --version +$ php phpunit-9.5.phar --version ``` Alternatively, you may use [Composer](https://getcomposer.org/) to download and install PHPUnit as well as its dependencies. Please refer to the "[Getting Started](https://phpunit.de/getting-started-with-phpunit.html)" guide for details on how to install PHPUnit. diff --git a/vendor/phpunit/phpunit/composer.json b/vendor/phpunit/phpunit/composer.json index 86f7b21ee..fd6461fc3 100644 --- a/vendor/phpunit/phpunit/composer.json +++ b/vendor/phpunit/phpunit/composer.json @@ -21,7 +21,7 @@ }, "prefer-stable": true, "require": { - "php": ">=7.2", + "php": ">=7.3", "ext-dom": "*", "ext-json": "*", "ext-libxml": "*", @@ -29,36 +29,39 @@ "ext-xml": "*", "ext-xmlwriter": "*", "doctrine/instantiator": "^1.3.1", - "myclabs/deep-copy": "^1.10.0", + "myclabs/deep-copy": "^1.10.1", "phar-io/manifest": "^2.0.1", "phar-io/version": "^3.0.2", - "phpspec/prophecy": "^1.10.3", - "phpunit/php-code-coverage": "^7.0.12", - "phpunit/php-file-iterator": "^2.0.2", - "phpunit/php-text-template": "^1.2.1", - "phpunit/php-timer": "^2.1.2", - "sebastian/comparator": "^3.0.2", - "sebastian/diff": "^3.0.2", - "sebastian/environment": "^4.2.3", - "sebastian/exporter": "^3.1.2", - "sebastian/global-state": "^3.0.0", - "sebastian/object-enumerator": "^3.0.3", - "sebastian/resource-operations": "^2.0.1", - "sebastian/type": "^1.1.3", - "sebastian/version": "^2.0.1" + "phpspec/prophecy": "^1.12.1", + "phpunit/php-code-coverage": "^9.2.3", + "phpunit/php-file-iterator": "^3.0.5", + "phpunit/php-invoker": "^3.1.1", + "phpunit/php-text-template": "^2.0.3", + "phpunit/php-timer": "^5.0.2", + "sebastian/cli-parser": "^1.0.1", + "sebastian/code-unit": "^1.0.6", + "sebastian/comparator": "^4.0.5", + "sebastian/diff": "^4.0.3", + "sebastian/environment": "^5.1.3", + "sebastian/exporter": "^4.0.3", + "sebastian/global-state": "^5.0.1", + "sebastian/object-enumerator": "^4.0.3", + "sebastian/resource-operations": "^3.0.3", + "sebastian/type": "^2.3", + "sebastian/version": "^3.0.2" }, "require-dev": { - "ext-PDO": "*" + "ext-PDO": "*", + "phpspec/prophecy-phpunit": "^2.0.1" }, "config": { "platform": { - "php": "7.2.0" + "php": "7.3.0" }, "optimize-autoloader": true, "sort-packages": true }, "suggest": { - "phpunit/php-invoker": "^2.0.0", "ext-soap": "*", "ext-xdebug": "*" }, @@ -68,6 +71,9 @@ "autoload": { "classmap": [ "src/" + ], + "files": [ + "src/Framework/Assert/Functions.php" ] }, "autoload-dev": { @@ -75,7 +81,6 @@ "tests/" ], "files": [ - "src/Framework/Assert/Functions.php", "tests/_files/CoverageNamespacedFunctionTest.php", "tests/_files/CoveredFunction.php", "tests/_files/NamespaceCoveredFunction.php" @@ -83,7 +88,7 @@ }, "extra": { "branch-alias": { - "dev-master": "8.5-dev" + "dev-master": "9.5-dev" } } } diff --git a/vendor/phpunit/phpunit/phpunit b/vendor/phpunit/phpunit/phpunit index be046cc92..a4553367a 100755 --- a/vendor/phpunit/phpunit/phpunit +++ b/vendor/phpunit/phpunit/phpunit @@ -9,11 +9,11 @@ * file that was distributed with this source code. */ -if (version_compare('7.2.0', PHP_VERSION, '>')) { +if (version_compare('7.3.0', PHP_VERSION, '>')) { fwrite( STDERR, sprintf( - 'This version of PHPUnit requires PHP >= 7.2.' . PHP_EOL . + 'This version of PHPUnit requires PHP >= 7.3.' . PHP_EOL . 'You are using PHP %s (%s).' . PHP_EOL, PHP_VERSION, PHP_BINARY diff --git a/vendor/phpunit/phpunit/phpunit.xsd b/vendor/phpunit/phpunit/phpunit.xsd index 29cfcf2be..3785d21fe 100644 --- a/vendor/phpunit/phpunit/phpunit.xsd +++ b/vendor/phpunit/phpunit/phpunit.xsd @@ -2,7 +2,7 @@ - This Schema file defines the rules by which the XML configuration file of PHPUnit 8.5 may be structured. + This Schema file defines the rules by which the XML configuration file of PHPUnit 9.5 may be structured. @@ -11,30 +11,33 @@ Root Element - - - - + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - + + @@ -122,39 +125,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -241,16 +211,14 @@ - - - + @@ -260,7 +228,10 @@ + + + @@ -270,7 +241,6 @@ - @@ -292,8 +262,8 @@ - - + + @@ -314,4 +284,45 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/vendor/phpunit/phpunit/schema/8.5.xsd b/vendor/phpunit/phpunit/schema/8.5.xsd new file mode 100644 index 000000000..29cfcf2be --- /dev/null +++ b/vendor/phpunit/phpunit/schema/8.5.xsd @@ -0,0 +1,317 @@ + + + + + This Schema file defines the rules by which the XML configuration file of PHPUnit 8.5 may be structured. + + + + + + Root Element + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + The main type specifying the document structure + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/vendor/phpunit/phpunit/schema/9.2.xsd b/vendor/phpunit/phpunit/schema/9.2.xsd new file mode 100644 index 000000000..97e86d3ab --- /dev/null +++ b/vendor/phpunit/phpunit/schema/9.2.xsd @@ -0,0 +1,317 @@ + + + + + This Schema file defines the rules by which the XML configuration file of PHPUnit 9.2 may be structured. + + + + + + Root Element + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + The main type specifying the document structure + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/vendor/phpunit/phpunit/src/Framework/Assert.php b/vendor/phpunit/phpunit/src/Framework/Assert.php index 030f1a5ac..8053f2840 100644 --- a/vendor/phpunit/phpunit/src/Framework/Assert.php +++ b/vendor/phpunit/phpunit/src/Framework/Assert.php @@ -11,7 +11,6 @@ namespace PHPUnit\Framework; use const DEBUG_BACKTRACE_IGNORE_ARGS; use const PHP_EOL; -use function array_key_exists; use function array_shift; use function array_unshift; use function assert; @@ -39,8 +38,6 @@ use DOMAttr; use DOMDocument; use DOMElement; use PHPUnit\Framework\Constraint\ArrayHasKey; -use PHPUnit\Framework\Constraint\ArraySubset; -use PHPUnit\Framework\Constraint\Attribute; use PHPUnit\Framework\Constraint\Callback; use PHPUnit\Framework\Constraint\ClassHasAttribute; use PHPUnit\Framework\Constraint\ClassHasStaticAttribute; @@ -52,6 +49,9 @@ use PHPUnit\Framework\Constraint\GreaterThan; use PHPUnit\Framework\Constraint\IsAnything; use PHPUnit\Framework\Constraint\IsEmpty; use PHPUnit\Framework\Constraint\IsEqual; +use PHPUnit\Framework\Constraint\IsEqualCanonicalizing; +use PHPUnit\Framework\Constraint\IsEqualIgnoringCase; +use PHPUnit\Framework\Constraint\IsEqualWithDelta; use PHPUnit\Framework\Constraint\IsFalse; use PHPUnit\Framework\Constraint\IsFinite; use PHPUnit\Framework\Constraint\IsIdentical; @@ -70,6 +70,7 @@ use PHPUnit\Framework\Constraint\LogicalAnd; use PHPUnit\Framework\Constraint\LogicalNot; use PHPUnit\Framework\Constraint\LogicalOr; use PHPUnit\Framework\Constraint\LogicalXor; +use PHPUnit\Framework\Constraint\ObjectEquals; use PHPUnit\Framework\Constraint\ObjectHasAttribute; use PHPUnit\Framework\Constraint\RegularExpression; use PHPUnit\Framework\Constraint\SameSize; @@ -77,19 +78,15 @@ use PHPUnit\Framework\Constraint\StringContains; use PHPUnit\Framework\Constraint\StringEndsWith; use PHPUnit\Framework\Constraint\StringMatchesFormatDescription; use PHPUnit\Framework\Constraint\StringStartsWith; -use PHPUnit\Framework\Constraint\TraversableContains; use PHPUnit\Framework\Constraint\TraversableContainsEqual; use PHPUnit\Framework\Constraint\TraversableContainsIdentical; use PHPUnit\Framework\Constraint\TraversableContainsOnly; use PHPUnit\Util\Type; use PHPUnit\Util\Xml; -use ReflectionClass; -use ReflectionException; -use ReflectionObject; -use Traversable; +use PHPUnit\Util\Xml\Loader as XmlLoader; /** - * A set of assertion methods. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ abstract class Assert { @@ -129,43 +126,6 @@ abstract class Assert static::assertThat($array, $constraint, $message); } - /** - * Asserts that an array has a specified subset. - * - * @param array|ArrayAccess $subset - * @param array|ArrayAccess $array - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @codeCoverageIgnore - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3494 - */ - public static function assertArraySubset($subset, $array, bool $checkForObjectIdentity = false, string $message = ''): void - { - self::createWarning('assertArraySubset() is deprecated and will be removed in PHPUnit 9.'); - - if (!(is_array($subset) || $subset instanceof ArrayAccess)) { - throw InvalidArgumentException::create( - 1, - 'array or ArrayAccess' - ); - } - - if (!(is_array($array) || $array instanceof ArrayAccess)) { - throw InvalidArgumentException::create( - 2, - 'array or ArrayAccess' - ); - } - - $constraint = new ArraySubset($subset, $checkForObjectIdentity); - - static::assertThat($array, $constraint, $message); - } - /** * Asserts that an array does not have a specified key. * @@ -206,51 +166,9 @@ abstract class Assert * @throws Exception * @throws ExpectationFailedException */ - public static function assertContains($needle, $haystack, string $message = '', bool $ignoreCase = false, bool $checkForObjectIdentity = true, bool $checkForNonObjectIdentity = false): void + public static function assertContains($needle, iterable $haystack, string $message = ''): void { - // @codeCoverageIgnoreStart - if (is_string($haystack)) { - self::createWarning('Using assertContains() with string haystacks is deprecated and will not be supported in PHPUnit 9. Refactor your test to use assertStringContainsString() or assertStringContainsStringIgnoringCase() instead.'); - } - - if (!$checkForObjectIdentity) { - self::createWarning('The optional $checkForObjectIdentity parameter of assertContains() is deprecated and will be removed in PHPUnit 9. Refactor your test to use assertContainsEquals() instead.'); - } - - if ($checkForNonObjectIdentity) { - self::createWarning('The optional $checkForNonObjectIdentity parameter of assertContains() is deprecated and will be removed in PHPUnit 9.'); - } - - if ($ignoreCase) { - self::createWarning('The optional $ignoreCase parameter of assertContains() is deprecated and will be removed in PHPUnit 9.'); - } - // @codeCoverageIgnoreEnd - - if (is_array($haystack) || - (is_object($haystack) && $haystack instanceof Traversable)) { - $constraint = new TraversableContains( - $needle, - $checkForObjectIdentity, - $checkForNonObjectIdentity - ); - } elseif (is_string($haystack)) { - if (!is_string($needle)) { - throw InvalidArgumentException::create( - 1, - 'string' - ); - } - - $constraint = new StringContains( - $needle, - $ignoreCase - ); - } else { - throw InvalidArgumentException::create( - 2, - 'array, traversable or string' - ); - } + $constraint = new TraversableContainsIdentical($needle); static::assertThat($haystack, $constraint, $message); } @@ -262,33 +180,6 @@ abstract class Assert static::assertThat($haystack, $constraint, $message); } - /** - * Asserts that a haystack that is stored in a static attribute of a class - * or an attribute of an object contains a needle. - * - * @param object|string $haystackClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ - public static function assertAttributeContains($needle, string $haystackAttributeName, $haystackClassOrObject, string $message = '', bool $ignoreCase = false, bool $checkForObjectIdentity = true, bool $checkForNonObjectIdentity = false): void - { - self::createWarning('assertAttributeContains() is deprecated and will be removed in PHPUnit 9.'); - - static::assertContains( - $needle, - static::readAttribute($haystackClassOrObject, $haystackAttributeName), - $message, - $ignoreCase, - $checkForObjectIdentity, - $checkForNonObjectIdentity - ); - } - /** * Asserts that a haystack does not contain a needle. * @@ -296,55 +187,11 @@ abstract class Assert * @throws Exception * @throws ExpectationFailedException */ - public static function assertNotContains($needle, $haystack, string $message = '', bool $ignoreCase = false, bool $checkForObjectIdentity = true, bool $checkForNonObjectIdentity = false): void + public static function assertNotContains($needle, iterable $haystack, string $message = ''): void { - // @codeCoverageIgnoreStart - if (is_string($haystack)) { - self::createWarning('Using assertNotContains() with string haystacks is deprecated and will not be supported in PHPUnit 9. Refactor your test to use assertStringNotContainsString() or assertStringNotContainsStringIgnoringCase() instead.'); - } - - if (!$checkForObjectIdentity) { - self::createWarning('The optional $checkForObjectIdentity parameter of assertNotContains() is deprecated and will be removed in PHPUnit 9. Refactor your test to use assertNotContainsEquals() instead.'); - } - - if ($checkForNonObjectIdentity) { - self::createWarning('The optional $checkForNonObjectIdentity parameter of assertNotContains() is deprecated and will be removed in PHPUnit 9.'); - } - - if ($ignoreCase) { - self::createWarning('The optional $ignoreCase parameter of assertNotContains() is deprecated and will be removed in PHPUnit 9.'); - } - // @codeCoverageIgnoreEnd - - if (is_array($haystack) || - (is_object($haystack) && $haystack instanceof Traversable)) { - $constraint = new LogicalNot( - new TraversableContains( - $needle, - $checkForObjectIdentity, - $checkForNonObjectIdentity - ) - ); - } elseif (is_string($haystack)) { - if (!is_string($needle)) { - throw InvalidArgumentException::create( - 1, - 'string' - ); - } - - $constraint = new LogicalNot( - new StringContains( - $needle, - $ignoreCase - ) - ); - } else { - throw InvalidArgumentException::create( - 2, - 'array, traversable or string' - ); - } + $constraint = new LogicalNot( + new TraversableContainsIdentical($needle) + ); static::assertThat($haystack, $constraint, $message); } @@ -356,33 +203,6 @@ abstract class Assert static::assertThat($haystack, $constraint, $message); } - /** - * Asserts that a haystack that is stored in a static attribute of a class - * or an attribute of an object does not contain a needle. - * - * @param object|string $haystackClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ - public static function assertAttributeNotContains($needle, string $haystackAttributeName, $haystackClassOrObject, string $message = '', bool $ignoreCase = false, bool $checkForObjectIdentity = true, bool $checkForNonObjectIdentity = false): void - { - self::createWarning('assertAttributeNotContains() is deprecated and will be removed in PHPUnit 9.'); - - static::assertNotContains( - $needle, - static::readAttribute($haystackClassOrObject, $haystackAttributeName), - $message, - $ignoreCase, - $checkForObjectIdentity, - $checkForNonObjectIdentity - ); - } - /** * Asserts that a haystack contains only values of a given type. * @@ -423,32 +243,6 @@ abstract class Assert ); } - /** - * Asserts that a haystack that is stored in a static attribute of a class - * or an attribute of an object contains only values of a given type. - * - * @param object|string $haystackClassOrObject - * @param bool $isNativeType - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ - public static function assertAttributeContainsOnly(string $type, string $haystackAttributeName, $haystackClassOrObject, ?bool $isNativeType = null, string $message = ''): void - { - self::createWarning('assertAttributeContainsOnly() is deprecated and will be removed in PHPUnit 9.'); - - static::assertContainsOnly( - $type, - static::readAttribute($haystackClassOrObject, $haystackAttributeName), - $isNativeType, - $message - ); - } - /** * Asserts that a haystack does not contain only values of a given type. * @@ -473,33 +267,6 @@ abstract class Assert ); } - /** - * Asserts that a haystack that is stored in a static attribute of a class - * or an attribute of an object does not contain only values of a given - * type. - * - * @param object|string $haystackClassOrObject - * @param bool $isNativeType - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ - public static function assertAttributeNotContainsOnly(string $type, string $haystackAttributeName, $haystackClassOrObject, ?bool $isNativeType = null, string $message = ''): void - { - self::createWarning('assertAttributeNotContainsOnly() is deprecated and will be removed in PHPUnit 9.'); - - static::assertNotContainsOnly( - $type, - static::readAttribute($haystackClassOrObject, $haystackAttributeName), - $isNativeType, - $message - ); - } - /** * Asserts the number of elements of an array, Countable or Traversable. * @@ -522,30 +289,6 @@ abstract class Assert ); } - /** - * Asserts the number of elements of an array, Countable or Traversable - * that is stored in an attribute. - * - * @param object|string $haystackClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ - public static function assertAttributeCount(int $expectedCount, string $haystackAttributeName, $haystackClassOrObject, string $message = ''): void - { - self::createWarning('assertAttributeCount() is deprecated and will be removed in PHPUnit 9.'); - - static::assertCount( - $expectedCount, - static::readAttribute($haystackClassOrObject, $haystackAttributeName), - $message - ); - } - /** * Asserts the number of elements of an array, Countable or Traversable. * @@ -568,63 +311,15 @@ abstract class Assert static::assertThat($haystack, $constraint, $message); } - /** - * Asserts the number of elements of an array, Countable or Traversable - * that is stored in an attribute. - * - * @param object|string $haystackClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ - public static function assertAttributeNotCount(int $expectedCount, string $haystackAttributeName, $haystackClassOrObject, string $message = ''): void - { - self::createWarning('assertAttributeNotCount() is deprecated and will be removed in PHPUnit 9.'); - - static::assertNotCount( - $expectedCount, - static::readAttribute($haystackClassOrObject, $haystackAttributeName), - $message - ); - } - /** * Asserts that two variables are equal. * * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException */ - public static function assertEquals($expected, $actual, string $message = '', float $delta = 0.0, int $maxDepth = 10, bool $canonicalize = false, bool $ignoreCase = false): void + public static function assertEquals($expected, $actual, string $message = ''): void { - // @codeCoverageIgnoreStart - if ($delta !== 0.0) { - self::createWarning('The optional $delta parameter of assertEquals() is deprecated and will be removed in PHPUnit 9. Refactor your test to use assertEqualsWithDelta() instead.'); - } - - if ($maxDepth !== 10) { - self::createWarning('The optional $maxDepth parameter of assertEquals() is deprecated and will be removed in PHPUnit 9.'); - } - - if ($canonicalize) { - self::createWarning('The optional $canonicalize parameter of assertEquals() is deprecated and will be removed in PHPUnit 9. Refactor your test to use assertEqualsCanonicalizing() instead.'); - } - - if ($ignoreCase) { - self::createWarning('The optional $ignoreCase parameter of assertEquals() is deprecated and will be removed in PHPUnit 9. Refactor your test to use assertEqualsIgnoringCase() instead.'); - } - // @codeCoverageIgnoreEnd - - $constraint = new IsEqual( - $expected, - $delta, - $maxDepth, - $canonicalize, - $ignoreCase - ); + $constraint = new IsEqual($expected); static::assertThat($actual, $constraint, $message); } @@ -637,13 +332,7 @@ abstract class Assert */ public static function assertEqualsCanonicalizing($expected, $actual, string $message = ''): void { - $constraint = new IsEqual( - $expected, - 0.0, - 10, - true, - false - ); + $constraint = new IsEqualCanonicalizing($expected); static::assertThat($actual, $constraint, $message); } @@ -656,13 +345,7 @@ abstract class Assert */ public static function assertEqualsIgnoringCase($expected, $actual, string $message = ''): void { - $constraint = new IsEqual( - $expected, - 0.0, - 10, - false, - true - ); + $constraint = new IsEqualIgnoringCase($expected); static::assertThat($actual, $constraint, $message); } @@ -675,7 +358,7 @@ abstract class Assert */ public static function assertEqualsWithDelta($expected, $actual, float $delta, string $message = ''): void { - $constraint = new IsEqual( + $constraint = new IsEqualWithDelta( $expected, $delta ); @@ -683,72 +366,16 @@ abstract class Assert static::assertThat($actual, $constraint, $message); } - /** - * Asserts that a variable is equal to an attribute of an object. - * - * @param object|string $actualClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ - public static function assertAttributeEquals($expected, string $actualAttributeName, $actualClassOrObject, string $message = '', float $delta = 0.0, int $maxDepth = 10, bool $canonicalize = false, bool $ignoreCase = false): void - { - self::createWarning('assertAttributeEquals() is deprecated and will be removed in PHPUnit 9.'); - - static::assertEquals( - $expected, - static::readAttribute($actualClassOrObject, $actualAttributeName), - $message, - $delta, - $maxDepth, - $canonicalize, - $ignoreCase - ); - } - /** * Asserts that two variables are not equal. * - * @param float $delta - * @param int $maxDepth - * @param bool $canonicalize - * @param bool $ignoreCase - * * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException */ - public static function assertNotEquals($expected, $actual, string $message = '', $delta = 0.0, $maxDepth = 10, $canonicalize = false, $ignoreCase = false): void + public static function assertNotEquals($expected, $actual, string $message = ''): void { - // @codeCoverageIgnoreStart - if ($delta !== 0.0) { - self::createWarning('The optional $delta parameter of assertNotEquals() is deprecated and will be removed in PHPUnit 9. Refactor your test to use assertNotEqualsWithDelta() instead.'); - } - - if ($maxDepth !== 10) { - self::createWarning('The optional $maxDepth parameter of assertNotEquals() is deprecated and will be removed in PHPUnit 9.'); - } - - if ($canonicalize) { - self::createWarning('The optional $canonicalize parameter of assertNotEquals() is deprecated and will be removed in PHPUnit 9. Refactor your test to use assertNotEqualsCanonicalizing() instead.'); - } - - if ($ignoreCase) { - self::createWarning('The optional $ignoreCase parameter of assertNotEquals() is deprecated and will be removed in PHPUnit 9. Refactor your test to use assertNotEqualsIgnoringCase() instead.'); - } - // @codeCoverageIgnoreEnd - $constraint = new LogicalNot( - new IsEqual( - $expected, - $delta, - $maxDepth, - $canonicalize, - $ignoreCase - ) + new IsEqual($expected) ); static::assertThat($actual, $constraint, $message); @@ -763,13 +390,7 @@ abstract class Assert public static function assertNotEqualsCanonicalizing($expected, $actual, string $message = ''): void { $constraint = new LogicalNot( - new IsEqual( - $expected, - 0.0, - 10, - true, - false - ) + new IsEqualCanonicalizing($expected) ); static::assertThat($actual, $constraint, $message); @@ -784,13 +405,7 @@ abstract class Assert public static function assertNotEqualsIgnoringCase($expected, $actual, string $message = ''): void { $constraint = new LogicalNot( - new IsEqual( - $expected, - 0.0, - 10, - false, - true - ) + new IsEqualIgnoringCase($expected) ); static::assertThat($actual, $constraint, $message); @@ -805,7 +420,7 @@ abstract class Assert public static function assertNotEqualsWithDelta($expected, $actual, float $delta, string $message = ''): void { $constraint = new LogicalNot( - new IsEqual( + new IsEqualWithDelta( $expected, $delta ) @@ -815,29 +430,14 @@ abstract class Assert } /** - * Asserts that a variable is not equal to an attribute of an object. - * - * @param object|string $actualClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore */ - public static function assertAttributeNotEquals($expected, string $actualAttributeName, $actualClassOrObject, string $message = '', float $delta = 0.0, int $maxDepth = 10, bool $canonicalize = false, bool $ignoreCase = false): void + public static function assertObjectEquals(object $expected, object $actual, string $method = 'equals', string $message = ''): void { - self::createWarning('assertAttributeNotEquals() is deprecated and will be removed in PHPUnit 9.'); - - static::assertNotEquals( - $expected, - static::readAttribute($actualClassOrObject, $actualAttributeName), - $message, - $delta, - $maxDepth, - $canonicalize, - $ignoreCase + static::assertThat( + $actual, + static::objectEquals($expected, $method), + $message ); } @@ -854,29 +454,6 @@ abstract class Assert static::assertThat($actual, static::isEmpty(), $message); } - /** - * Asserts that a static attribute of a class or an attribute of an object - * is empty. - * - * @param object|string $haystackClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ - public static function assertAttributeEmpty(string $haystackAttributeName, $haystackClassOrObject, string $message = ''): void - { - self::createWarning('assertAttributeEmpty() is deprecated and will be removed in PHPUnit 9.'); - - static::assertEmpty( - static::readAttribute($haystackClassOrObject, $haystackAttributeName), - $message - ); - } - /** * Asserts that a variable is not empty. * @@ -890,29 +467,6 @@ abstract class Assert static::assertThat($actual, static::logicalNot(static::isEmpty()), $message); } - /** - * Asserts that a static attribute of a class or an attribute of an object - * is not empty. - * - * @param object|string $haystackClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ - public static function assertAttributeNotEmpty(string $haystackAttributeName, $haystackClassOrObject, string $message = ''): void - { - self::createWarning('assertAttributeNotEmpty() is deprecated and will be removed in PHPUnit 9.'); - - static::assertNotEmpty( - static::readAttribute($haystackClassOrObject, $haystackAttributeName), - $message - ); - } - /** * Asserts that a value is greater than another value. * @@ -924,29 +478,6 @@ abstract class Assert static::assertThat($actual, static::greaterThan($expected), $message); } - /** - * Asserts that an attribute is greater than another value. - * - * @param object|string $actualClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ - public static function assertAttributeGreaterThan($expected, string $actualAttributeName, $actualClassOrObject, string $message = ''): void - { - self::createWarning('assertAttributeGreaterThan() is deprecated and will be removed in PHPUnit 9.'); - - static::assertGreaterThan( - $expected, - static::readAttribute($actualClassOrObject, $actualAttributeName), - $message - ); - } - /** * Asserts that a value is greater than or equal to another value. * @@ -962,29 +493,6 @@ abstract class Assert ); } - /** - * Asserts that an attribute is greater than or equal to another value. - * - * @param object|string $actualClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ - public static function assertAttributeGreaterThanOrEqual($expected, string $actualAttributeName, $actualClassOrObject, string $message = ''): void - { - self::createWarning('assertAttributeGreaterThanOrEqual() is deprecated and will be removed in PHPUnit 9.'); - - static::assertGreaterThanOrEqual( - $expected, - static::readAttribute($actualClassOrObject, $actualAttributeName), - $message - ); - } - /** * Asserts that a value is smaller than another value. * @@ -996,29 +504,6 @@ abstract class Assert static::assertThat($actual, static::lessThan($expected), $message); } - /** - * Asserts that an attribute is smaller than another value. - * - * @param object|string $actualClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ - public static function assertAttributeLessThan($expected, string $actualAttributeName, $actualClassOrObject, string $message = ''): void - { - self::createWarning('assertAttributeLessThan() is deprecated and will be removed in PHPUnit 9.'); - - static::assertLessThan( - $expected, - static::readAttribute($actualClassOrObject, $actualAttributeName), - $message - ); - } - /** * Asserts that a value is smaller than or equal to another value. * @@ -1030,29 +515,6 @@ abstract class Assert static::assertThat($actual, static::lessThanOrEqual($expected), $message); } - /** - * Asserts that an attribute is smaller than or equal to another value. - * - * @param object|string $actualClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ - public static function assertAttributeLessThanOrEqual($expected, string $actualAttributeName, $actualClassOrObject, string $message = ''): void - { - self::createWarning('assertAttributeLessThanOrEqual() is deprecated and will be removed in PHPUnit 9.'); - - static::assertLessThanOrEqual( - $expected, - static::readAttribute($actualClassOrObject, $actualAttributeName), - $message - ); - } - /** * Asserts that the contents of one file is equal to the contents of another * file. @@ -1060,28 +522,12 @@ abstract class Assert * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException */ - public static function assertFileEquals(string $expected, string $actual, string $message = '', bool $canonicalize = false, bool $ignoreCase = false): void + public static function assertFileEquals(string $expected, string $actual, string $message = ''): void { - // @codeCoverageIgnoreStart - if ($canonicalize) { - self::createWarning('The optional $canonicalize parameter of assertFileEquals() is deprecated and will be removed in PHPUnit 9. Refactor your test to use assertFileEqualsCanonicalizing() instead.'); - } - - if ($ignoreCase) { - self::createWarning('The optional $ignoreCase parameter of assertFileEquals() is deprecated and will be removed in PHPUnit 9. Refactor your test to use assertFileEqualsIgnoringCase() instead.'); - } - // @codeCoverageIgnoreEnd - static::assertFileExists($expected, $message); static::assertFileExists($actual, $message); - $constraint = new IsEqual( - file_get_contents($expected), - 0.0, - 10, - $canonicalize, - $ignoreCase - ); + $constraint = new IsEqual(file_get_contents($expected)); static::assertThat(file_get_contents($actual), $constraint, $message); } @@ -1098,11 +544,8 @@ abstract class Assert static::assertFileExists($expected, $message); static::assertFileExists($actual, $message); - $constraint = new IsEqual( - file_get_contents($expected), - 0.0, - 10, - true + $constraint = new IsEqualCanonicalizing( + file_get_contents($expected) ); static::assertThat(file_get_contents($actual), $constraint, $message); @@ -1120,13 +563,7 @@ abstract class Assert static::assertFileExists($expected, $message); static::assertFileExists($actual, $message); - $constraint = new IsEqual( - file_get_contents($expected), - 0.0, - 10, - false, - true - ); + $constraint = new IsEqualIgnoringCase(file_get_contents($expected)); static::assertThat(file_get_contents($actual), $constraint, $message); } @@ -1138,29 +575,13 @@ abstract class Assert * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException */ - public static function assertFileNotEquals(string $expected, string $actual, string $message = '', bool $canonicalize = false, bool $ignoreCase = false): void + public static function assertFileNotEquals(string $expected, string $actual, string $message = ''): void { - // @codeCoverageIgnoreStart - if ($canonicalize) { - self::createWarning('The optional $canonicalize parameter of assertFileNotEquals() is deprecated and will be removed in PHPUnit 9. Refactor your test to use assertFileNotEqualsCanonicalizing() instead.'); - } - - if ($ignoreCase) { - self::createWarning('The optional $ignoreCase parameter of assertFileNotEquals() is deprecated and will be removed in PHPUnit 9. Refactor your test to use assertFileNotEqualsIgnoringCase() instead.'); - } - // @codeCoverageIgnoreEnd - static::assertFileExists($expected, $message); static::assertFileExists($actual, $message); $constraint = new LogicalNot( - new IsEqual( - file_get_contents($expected), - 0.0, - 10, - $canonicalize, - $ignoreCase - ) + new IsEqual(file_get_contents($expected)) ); static::assertThat(file_get_contents($actual), $constraint, $message); @@ -1179,12 +600,7 @@ abstract class Assert static::assertFileExists($actual, $message); $constraint = new LogicalNot( - new IsEqual( - file_get_contents($expected), - 0.0, - 10, - true - ) + new IsEqualCanonicalizing(file_get_contents($expected)) ); static::assertThat(file_get_contents($actual), $constraint, $message); @@ -1203,13 +619,7 @@ abstract class Assert static::assertFileExists($actual, $message); $constraint = new LogicalNot( - new IsEqual( - file_get_contents($expected), - 0.0, - 10, - false, - true - ) + new IsEqualIgnoringCase(file_get_contents($expected)) ); static::assertThat(file_get_contents($actual), $constraint, $message); @@ -1222,27 +632,11 @@ abstract class Assert * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException */ - public static function assertStringEqualsFile(string $expectedFile, string $actualString, string $message = '', bool $canonicalize = false, bool $ignoreCase = false): void + public static function assertStringEqualsFile(string $expectedFile, string $actualString, string $message = ''): void { - // @codeCoverageIgnoreStart - if ($canonicalize) { - self::createWarning('The optional $canonicalize parameter of assertStringEqualsFile() is deprecated and will be removed in PHPUnit 9. Refactor your test to use assertStringEqualsFileCanonicalizing() instead.'); - } - - if ($ignoreCase) { - self::createWarning('The optional $ignoreCase parameter of assertStringEqualsFile() is deprecated and will be removed in PHPUnit 9. Refactor your test to use assertStringEqualsFileIgnoringCase() instead.'); - } - // @codeCoverageIgnoreEnd - static::assertFileExists($expectedFile, $message); - $constraint = new IsEqual( - file_get_contents($expectedFile), - 0.0, - 10, - $canonicalize, - $ignoreCase - ); + $constraint = new IsEqual(file_get_contents($expectedFile)); static::assertThat($actualString, $constraint, $message); } @@ -1258,12 +652,7 @@ abstract class Assert { static::assertFileExists($expectedFile, $message); - $constraint = new IsEqual( - file_get_contents($expectedFile), - 0.0, - 10, - true - ); + $constraint = new IsEqualCanonicalizing(file_get_contents($expectedFile)); static::assertThat($actualString, $constraint, $message); } @@ -1279,13 +668,7 @@ abstract class Assert { static::assertFileExists($expectedFile, $message); - $constraint = new IsEqual( - file_get_contents($expectedFile), - 0.0, - 10, - false, - true - ); + $constraint = new IsEqualIgnoringCase(file_get_contents($expectedFile)); static::assertThat($actualString, $constraint, $message); } @@ -1297,28 +680,12 @@ abstract class Assert * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException */ - public static function assertStringNotEqualsFile(string $expectedFile, string $actualString, string $message = '', bool $canonicalize = false, bool $ignoreCase = false): void + public static function assertStringNotEqualsFile(string $expectedFile, string $actualString, string $message = ''): void { - // @codeCoverageIgnoreStart - if ($canonicalize) { - self::createWarning('The optional $canonicalize parameter of assertStringNotEqualsFile() is deprecated and will be removed in PHPUnit 9. Refactor your test to use assertStringNotEqualsFileCanonicalizing() instead.'); - } - - if ($ignoreCase) { - self::createWarning('The optional $ignoreCase parameter of assertStringNotEqualsFile() is deprecated and will be removed in PHPUnit 9. Refactor your test to use assertStringNotEqualsFileIgnoringCase() instead.'); - } - // @codeCoverageIgnoreEnd - static::assertFileExists($expectedFile, $message); $constraint = new LogicalNot( - new IsEqual( - file_get_contents($expectedFile), - 0.0, - 10, - $canonicalize, - $ignoreCase - ) + new IsEqual(file_get_contents($expectedFile)) ); static::assertThat($actualString, $constraint, $message); @@ -1336,12 +703,7 @@ abstract class Assert static::assertFileExists($expectedFile, $message); $constraint = new LogicalNot( - new IsEqual( - file_get_contents($expectedFile), - 0.0, - 10, - true - ) + new IsEqualCanonicalizing(file_get_contents($expectedFile)) ); static::assertThat($actualString, $constraint, $message); @@ -1359,13 +721,7 @@ abstract class Assert static::assertFileExists($expectedFile, $message); $constraint = new LogicalNot( - new IsEqual( - file_get_contents($expectedFile), - 0.0, - 10, - false, - true - ) + new IsEqualIgnoringCase(file_get_contents($expectedFile)) ); static::assertThat($actualString, $constraint, $message); @@ -1388,8 +744,25 @@ abstract class Assert * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException */ + public static function assertIsNotReadable(string $filename, string $message = ''): void + { + static::assertThat($filename, new LogicalNot(new IsReadable), $message); + } + + /** + * Asserts that a file/dir exists and is not readable. + * + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * @throws ExpectationFailedException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4062 + */ public static function assertNotIsReadable(string $filename, string $message = ''): void { + self::createWarning('assertNotIsReadable() is deprecated and will be removed in PHPUnit 10. Refactor your code to use assertIsNotReadable() instead.'); + static::assertThat($filename, new LogicalNot(new IsReadable), $message); } @@ -1410,8 +783,25 @@ abstract class Assert * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException */ + public static function assertIsNotWritable(string $filename, string $message = ''): void + { + static::assertThat($filename, new LogicalNot(new IsWritable), $message); + } + + /** + * Asserts that a file/dir exists and is not writable. + * + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * @throws ExpectationFailedException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4065 + */ public static function assertNotIsWritable(string $filename, string $message = ''): void { + self::createWarning('assertNotIsWritable() is deprecated and will be removed in PHPUnit 10. Refactor your code to use assertIsNotWritable() instead.'); + static::assertThat($filename, new LogicalNot(new IsWritable), $message); } @@ -1432,8 +822,25 @@ abstract class Assert * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException */ + public static function assertDirectoryDoesNotExist(string $directory, string $message = ''): void + { + static::assertThat($directory, new LogicalNot(new DirectoryExists), $message); + } + + /** + * Asserts that a directory does not exist. + * + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * @throws ExpectationFailedException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4068 + */ public static function assertDirectoryNotExists(string $directory, string $message = ''): void { + self::createWarning('assertDirectoryNotExists() is deprecated and will be removed in PHPUnit 10. Refactor your code to use assertDirectoryDoesNotExist() instead.'); + static::assertThat($directory, new LogicalNot(new DirectoryExists), $message); } @@ -1455,10 +862,28 @@ abstract class Assert * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException */ - public static function assertDirectoryNotIsReadable(string $directory, string $message = ''): void + public static function assertDirectoryIsNotReadable(string $directory, string $message = ''): void { self::assertDirectoryExists($directory, $message); - self::assertNotIsReadable($directory, $message); + self::assertIsNotReadable($directory, $message); + } + + /** + * Asserts that a directory exists and is not readable. + * + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * @throws ExpectationFailedException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4071 + */ + public static function assertDirectoryNotIsReadable(string $directory, string $message = ''): void + { + self::createWarning('assertDirectoryNotIsReadable() is deprecated and will be removed in PHPUnit 10. Refactor your code to use assertDirectoryIsNotReadable() instead.'); + + self::assertDirectoryExists($directory, $message); + self::assertIsNotReadable($directory, $message); } /** @@ -1479,10 +904,28 @@ abstract class Assert * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException */ - public static function assertDirectoryNotIsWritable(string $directory, string $message = ''): void + public static function assertDirectoryIsNotWritable(string $directory, string $message = ''): void { self::assertDirectoryExists($directory, $message); - self::assertNotIsWritable($directory, $message); + self::assertIsNotWritable($directory, $message); + } + + /** + * Asserts that a directory exists and is not writable. + * + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * @throws ExpectationFailedException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4074 + */ + public static function assertDirectoryNotIsWritable(string $directory, string $message = ''): void + { + self::createWarning('assertDirectoryNotIsWritable() is deprecated and will be removed in PHPUnit 10. Refactor your code to use assertDirectoryIsNotWritable() instead.'); + + self::assertDirectoryExists($directory, $message); + self::assertIsNotWritable($directory, $message); } /** @@ -1502,8 +945,25 @@ abstract class Assert * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException */ + public static function assertFileDoesNotExist(string $filename, string $message = ''): void + { + static::assertThat($filename, new LogicalNot(new FileExists), $message); + } + + /** + * Asserts that a file does not exist. + * + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * @throws ExpectationFailedException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4077 + */ public static function assertFileNotExists(string $filename, string $message = ''): void { + self::createWarning('assertFileNotExists() is deprecated and will be removed in PHPUnit 10. Refactor your code to use assertFileDoesNotExist() instead.'); + static::assertThat($filename, new LogicalNot(new FileExists), $message); } @@ -1525,10 +985,28 @@ abstract class Assert * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException */ - public static function assertFileNotIsReadable(string $file, string $message = ''): void + public static function assertFileIsNotReadable(string $file, string $message = ''): void { self::assertFileExists($file, $message); - self::assertNotIsReadable($file, $message); + self::assertIsNotReadable($file, $message); + } + + /** + * Asserts that a file exists and is not readable. + * + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * @throws ExpectationFailedException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4080 + */ + public static function assertFileNotIsReadable(string $file, string $message = ''): void + { + self::createWarning('assertFileNotIsReadable() is deprecated and will be removed in PHPUnit 10. Refactor your code to use assertFileIsNotReadable() instead.'); + + self::assertFileExists($file, $message); + self::assertIsNotReadable($file, $message); } /** @@ -1549,10 +1027,28 @@ abstract class Assert * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException */ - public static function assertFileNotIsWritable(string $file, string $message = ''): void + public static function assertFileIsNotWritable(string $file, string $message = ''): void { self::assertFileExists($file, $message); - self::assertNotIsWritable($file, $message); + self::assertIsNotWritable($file, $message); + } + + /** + * Asserts that a file exists and is not writable. + * + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * @throws ExpectationFailedException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4083 + */ + public static function assertFileNotIsWritable(string $file, string $message = ''): void + { + self::createWarning('assertFileNotIsWritable() is deprecated and will be removed in PHPUnit 10. Refactor your code to use assertFileIsNotWritable() instead.'); + + self::assertFileExists($file, $message); + self::assertIsNotWritable($file, $message); } /** @@ -1837,30 +1333,6 @@ abstract class Assert ); } - /** - * Asserts that a variable and an attribute of an object have the same type - * and value. - * - * @param object|string $actualClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ - public static function assertAttributeSame($expected, string $actualAttributeName, $actualClassOrObject, string $message = ''): void - { - self::createWarning('assertAttributeSame() is deprecated and will be removed in PHPUnit 9.'); - - static::assertSame( - $expected, - static::readAttribute($actualClassOrObject, $actualAttributeName), - $message - ); - } - /** * Asserts that two variables do not have the same type and value. * Used on objects, it asserts that two variables do not reference @@ -1884,30 +1356,6 @@ abstract class Assert ); } - /** - * Asserts that a variable and an attribute of an object do not have the - * same type and value. - * - * @param object|string $actualClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ - public static function assertAttributeNotSame($expected, string $actualAttributeName, $actualClassOrObject, string $message = ''): void - { - self::createWarning('assertAttributeNotSame() is deprecated and will be removed in PHPUnit 9.'); - - static::assertNotSame( - $expected, - static::readAttribute($actualClassOrObject, $actualAttributeName), - $message - ); - } - /** * Asserts that a variable is of a given type. * @@ -1932,31 +1380,6 @@ abstract class Assert ); } - /** - * Asserts that an attribute is of a given type. - * - * @param object|string $classOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - * - * @psalm-param class-string $expected - */ - public static function assertAttributeInstanceOf(string $expected, string $attributeName, $classOrObject, string $message = ''): void - { - self::createWarning('assertAttributeInstanceOf() is deprecated and will be removed in PHPUnit 9.'); - - static::assertInstanceOf( - $expected, - static::readAttribute($classOrObject, $attributeName), - $message - ); - } - /** * Asserts that a variable is not of a given type. * @@ -1983,79 +1406,6 @@ abstract class Assert ); } - /** - * Asserts that an attribute is of a given type. - * - * @param object|string $classOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - * - * @psalm-param class-string $expected - */ - public static function assertAttributeNotInstanceOf(string $expected, string $attributeName, $classOrObject, string $message = ''): void - { - self::createWarning('assertAttributeNotInstanceOf() is deprecated and will be removed in PHPUnit 9.'); - - static::assertNotInstanceOf( - $expected, - static::readAttribute($classOrObject, $attributeName), - $message - ); - } - - /** - * Asserts that a variable is of a given type. - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3369 - * @codeCoverageIgnore - */ - public static function assertInternalType(string $expected, $actual, string $message = ''): void - { - self::createWarning( - sprintf( - 'assertInternalType() is deprecated and will be removed in PHPUnit 9. Refactor your test to use %s() instead.', - self::assertInternalTypeReplacement($expected, false) - ) - ); - - static::assertThat( - $actual, - new IsType($expected), - $message - ); - } - - /** - * Asserts that an attribute is of a given type. - * - * @param object|string $classOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ - public static function assertAttributeInternalType(string $expected, string $attributeName, $classOrObject, string $message = ''): void - { - self::createWarning('assertAttributeInternalType() is deprecated and will be removed in PHPUnit 9.'); - - static::assertInternalType( - $expected, - static::readAttribute($classOrObject, $attributeName), - $message - ); - } - /** * Asserts that a variable is of type array. * @@ -2175,6 +1525,23 @@ abstract class Assert ); } + /** + * Asserts that a variable is of type resource and is closed. + * + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * @throws ExpectationFailedException + * + * @psalm-assert resource $actual + */ + public static function assertIsClosedResource($actual, string $message = ''): void + { + static::assertThat( + $actual, + new IsType(IsType::TYPE_CLOSED_RESOURCE), + $message + ); + } + /** * Asserts that a variable is of type string. * @@ -2243,33 +1610,6 @@ abstract class Assert ); } - /** - * Asserts that a variable is not of a given type. - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3369 - * @codeCoverageIgnore - */ - public static function assertNotInternalType(string $expected, $actual, string $message = ''): void - { - self::createWarning( - sprintf( - 'assertNotInternalType() is deprecated and will be removed in PHPUnit 9. Refactor your test to use %s() instead.', - self::assertInternalTypeReplacement($expected, true) - ) - ); - - static::assertThat( - $actual, - new LogicalNot( - new IsType($expected) - ), - $message - ); - } - /** * Asserts that a variable is not of type array. * @@ -2389,6 +1729,23 @@ abstract class Assert ); } + /** + * Asserts that a variable is not of type resource. + * + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * @throws ExpectationFailedException + * + * @psalm-assert !resource $actual + */ + public static function assertIsNotClosedResource($actual, string $message = ''): void + { + static::assertThat( + $actual, + new LogicalNot(new IsType(IsType::TYPE_CLOSED_RESOURCE)), + $message + ); + } + /** * Asserts that a variable is not of type string. * @@ -2458,26 +1815,14 @@ abstract class Assert } /** - * Asserts that an attribute is of a given type. - * - * @param object|string $classOrObject + * Asserts that a string matches a given regular expression. * * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore */ - public static function assertAttributeNotInternalType(string $expected, string $attributeName, $classOrObject, string $message = ''): void + public static function assertMatchesRegularExpression(string $pattern, string $string, string $message = ''): void { - self::createWarning('assertAttributeNotInternalType() is deprecated and will be removed in PHPUnit 9.'); - - static::assertNotInternalType( - $expected, - static::readAttribute($classOrObject, $attributeName), - $message - ); + static::assertThat($string, new RegularExpression($pattern), $message); } /** @@ -2485,9 +1830,15 @@ abstract class Assert * * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4086 */ public static function assertRegExp(string $pattern, string $string, string $message = ''): void { + self::createWarning('assertRegExp() is deprecated and will be removed in PHPUnit 10. Refactor your code to use assertMatchesRegularExpression() instead.'); + static::assertThat($string, new RegularExpression($pattern), $message); } @@ -2497,8 +1848,31 @@ abstract class Assert * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException */ + public static function assertDoesNotMatchRegularExpression(string $pattern, string $string, string $message = ''): void + { + static::assertThat( + $string, + new LogicalNot( + new RegularExpression($pattern) + ), + $message + ); + } + + /** + * Asserts that a string does not match a given regular expression. + * + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * @throws ExpectationFailedException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4089 + */ public static function assertNotRegExp(string $pattern, string $string, string $message = ''): void { + self::createWarning('assertNotRegExp() is deprecated and will be removed in PHPUnit 10. Refactor your code to use assertDoesNotMatchRegularExpression() instead.'); + static::assertThat( $string, new LogicalNot( @@ -2746,8 +2120,8 @@ abstract class Assert */ public static function assertXmlFileEqualsXmlFile(string $expectedFile, string $actualFile, string $message = ''): void { - $expected = Xml::loadFile($expectedFile); - $actual = Xml::loadFile($actualFile); + $expected = (new XmlLoader)->loadFile($expectedFile); + $actual = (new XmlLoader)->loadFile($actualFile); static::assertEquals($expected, $actual, $message); } @@ -2755,14 +2129,14 @@ abstract class Assert /** * Asserts that two XML files are not equal. * + * @throws \PHPUnit\Util\Exception * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception * @throws ExpectationFailedException */ public static function assertXmlFileNotEqualsXmlFile(string $expectedFile, string $actualFile, string $message = ''): void { - $expected = Xml::loadFile($expectedFile); - $actual = Xml::loadFile($actualFile); + $expected = (new XmlLoader)->loadFile($expectedFile); + $actual = (new XmlLoader)->loadFile($actualFile); static::assertNotEquals($expected, $actual, $message); } @@ -2772,14 +2146,21 @@ abstract class Assert * * @param DOMDocument|string $actualXml * + * @throws \PHPUnit\Util\Xml\Exception * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception * @throws ExpectationFailedException */ public static function assertXmlStringEqualsXmlFile(string $expectedFile, $actualXml, string $message = ''): void { - $expected = Xml::loadFile($expectedFile); - $actual = Xml::load($actualXml); + if (!is_string($actualXml)) { + self::createWarning('Passing an argument of type DOMDocument for the $actualXml parameter is deprecated. Support for this will be removed in PHPUnit 10.'); + + $actual = $actualXml; + } else { + $actual = (new XmlLoader)->load($actualXml); + } + + $expected = (new XmlLoader)->loadFile($expectedFile); static::assertEquals($expected, $actual, $message); } @@ -2789,14 +2170,21 @@ abstract class Assert * * @param DOMDocument|string $actualXml * + * @throws \PHPUnit\Util\Xml\Exception * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception * @throws ExpectationFailedException */ public static function assertXmlStringNotEqualsXmlFile(string $expectedFile, $actualXml, string $message = ''): void { - $expected = Xml::loadFile($expectedFile); - $actual = Xml::load($actualXml); + if (!is_string($actualXml)) { + self::createWarning('Passing an argument of type DOMDocument for the $actualXml parameter is deprecated. Support for this will be removed in PHPUnit 10.'); + + $actual = $actualXml; + } else { + $actual = (new XmlLoader)->load($actualXml); + } + + $expected = (new XmlLoader)->loadFile($expectedFile); static::assertNotEquals($expected, $actual, $message); } @@ -2807,14 +2195,27 @@ abstract class Assert * @param DOMDocument|string $expectedXml * @param DOMDocument|string $actualXml * + * @throws \PHPUnit\Util\Xml\Exception * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception * @throws ExpectationFailedException */ public static function assertXmlStringEqualsXmlString($expectedXml, $actualXml, string $message = ''): void { - $expected = Xml::load($expectedXml); - $actual = Xml::load($actualXml); + if (!is_string($expectedXml)) { + self::createWarning('Passing an argument of type DOMDocument for the $expectedXml parameter is deprecated. Support for this will be removed in PHPUnit 10.'); + + $expected = $expectedXml; + } else { + $expected = (new XmlLoader)->load($expectedXml); + } + + if (!is_string($actualXml)) { + self::createWarning('Passing an argument of type DOMDocument for the $actualXml parameter is deprecated. Support for this will be removed in PHPUnit 10.'); + + $actual = $actualXml; + } else { + $actual = (new XmlLoader)->load($actualXml); + } static::assertEquals($expected, $actual, $message); } @@ -2825,14 +2226,27 @@ abstract class Assert * @param DOMDocument|string $expectedXml * @param DOMDocument|string $actualXml * + * @throws \PHPUnit\Util\Xml\Exception * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception * @throws ExpectationFailedException */ public static function assertXmlStringNotEqualsXmlString($expectedXml, $actualXml, string $message = ''): void { - $expected = Xml::load($expectedXml); - $actual = Xml::load($actualXml); + if (!is_string($expectedXml)) { + self::createWarning('Passing an argument of type DOMDocument for the $expectedXml parameter is deprecated. Support for this will be removed in PHPUnit 10.'); + + $expected = $expectedXml; + } else { + $expected = (new XmlLoader)->load($expectedXml); + } + + if (!is_string($actualXml)) { + self::createWarning('Passing an argument of type DOMDocument for the $actualXml parameter is deprecated. Support for this will be removed in PHPUnit 10.'); + + $actual = $actualXml; + } else { + $actual = (new XmlLoader)->load($actualXml); + } static::assertNotEquals($expected, $actual, $message); } @@ -2843,9 +2257,15 @@ abstract class Assert * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws AssertionFailedError * @throws ExpectationFailedException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4091 */ public static function assertEqualXMLStructure(DOMElement $expectedElement, DOMElement $actualElement, bool $checkAttributes = false, string $message = ''): void { + self::createWarning('assertEqualXMLStructure() is deprecated and will be removed in PHPUnit 10.'); + $expectedElement = Xml::import($expectedElement); $actualElement = Xml::import($actualElement); @@ -3156,25 +2576,6 @@ abstract class Assert return new IsNan; } - /** - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ - public static function attribute(Constraint $constraint, string $attributeName): Attribute - { - self::createWarning('attribute() is deprecated and will be removed in PHPUnit 9.'); - - return new Attribute($constraint, $attributeName); - } - - /** - * @deprecated Use containsEqual() or containsIdentical() instead - */ - public static function contains($value, bool $checkForObjectIdentity = true, bool $checkForNonObjectIdentity = false): TraversableContains - { - return new TraversableContains($value, $checkForObjectIdentity, $checkForNonObjectIdentity); - } - public static function containsEqual($value): TraversableContainsEqual { return new TraversableContainsEqual($value); @@ -3203,29 +2604,24 @@ abstract class Assert return new ArrayHasKey($key); } - public static function equalTo($value, float $delta = 0.0, int $maxDepth = 10, bool $canonicalize = false, bool $ignoreCase = false): IsEqual + public static function equalTo($value): IsEqual { - return new IsEqual($value, $delta, $maxDepth, $canonicalize, $ignoreCase); + return new IsEqual($value, 0.0, false, false); } - /** - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ - public static function attributeEqualTo(string $attributeName, $value, float $delta = 0.0, int $maxDepth = 10, bool $canonicalize = false, bool $ignoreCase = false): Attribute + public static function equalToCanonicalizing($value): IsEqualCanonicalizing { - self::createWarning('attributeEqualTo() is deprecated and will be removed in PHPUnit 9.'); + return new IsEqualCanonicalizing($value); + } - return static::attribute( - static::equalTo( - $value, - $delta, - $maxDepth, - $canonicalize, - $ignoreCase - ), - $attributeName - ); + public static function equalToIgnoringCase($value): IsEqualIgnoringCase + { + return new IsEqualIgnoringCase($value); + } + + public static function equalToWithDelta($value, float $delta): IsEqualWithDelta + { + return new IsEqualWithDelta($value, $delta); } public static function isEmpty(): IsEmpty @@ -3339,6 +2735,11 @@ abstract class Assert return new Count($count); } + public static function objectEquals(object $object, string $method = 'equals'): ObjectEquals + { + return new ObjectEquals($object, $method); + } + /** * Fails a test with the given message. * @@ -3353,153 +2754,6 @@ abstract class Assert throw new AssertionFailedError($message); } - /** - * Returns the value of an attribute of a class or an object. - * This also works for attributes that are declared protected or private. - * - * @param object|string $classOrObject - * - * @throws Exception - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ - public static function readAttribute($classOrObject, string $attributeName) - { - self::createWarning('readAttribute() is deprecated and will be removed in PHPUnit 9.'); - - if (!self::isValidClassAttributeName($attributeName)) { - throw InvalidArgumentException::create(2, 'valid attribute name'); - } - - if (is_string($classOrObject)) { - if (!class_exists($classOrObject)) { - throw InvalidArgumentException::create( - 1, - 'class name' - ); - } - - return static::getStaticAttribute( - $classOrObject, - $attributeName - ); - } - - if (is_object($classOrObject)) { - return static::getObjectAttribute( - $classOrObject, - $attributeName - ); - } - - throw InvalidArgumentException::create( - 1, - 'class name or object' - ); - } - - /** - * Returns the value of a static attribute. - * This also works for attributes that are declared protected or private. - * - * @throws Exception - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ - public static function getStaticAttribute(string $className, string $attributeName) - { - self::createWarning('getStaticAttribute() is deprecated and will be removed in PHPUnit 9.'); - - if (!class_exists($className)) { - throw InvalidArgumentException::create(1, 'class name'); - } - - if (!self::isValidClassAttributeName($attributeName)) { - throw InvalidArgumentException::create(2, 'valid attribute name'); - } - - try { - $class = new ReflectionClass($className); - // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new Exception( - $e->getMessage(), - (int) $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - - while ($class) { - $attributes = $class->getStaticProperties(); - - if (array_key_exists($attributeName, $attributes)) { - return $attributes[$attributeName]; - } - - $class = $class->getParentClass(); - } - - throw new Exception( - sprintf( - 'Attribute "%s" not found in class.', - $attributeName - ) - ); - } - - /** - * Returns the value of an object's attribute. - * This also works for attributes that are declared protected or private. - * - * @param object $object - * - * @throws Exception - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ - public static function getObjectAttribute($object, string $attributeName) - { - self::createWarning('getObjectAttribute() is deprecated and will be removed in PHPUnit 9.'); - - if (!is_object($object)) { - throw InvalidArgumentException::create(1, 'object'); - } - - if (!self::isValidClassAttributeName($attributeName)) { - throw InvalidArgumentException::create(2, 'valid attribute name'); - } - - $reflector = new ReflectionObject($object); - - do { - try { - $attribute = $reflector->getProperty($attributeName); - - if (!$attribute || $attribute->isPublic()) { - return $object->{$attributeName}; - } - - $attribute->setAccessible(true); - $value = $attribute->getValue($object); - $attribute->setAccessible(false); - - return $value; - } catch (ReflectionException $e) { - } - } while ($reflector = $reflector->getParentClass()); - - throw new Exception( - sprintf( - 'Attribute "%s" not found in object.', - $attributeName - ) - ); - } - /** * Mark the test as incomplete. * @@ -3597,59 +2851,4 @@ abstract class Assert } } } - - /** - * @throws Exception - */ - private static function assertInternalTypeReplacement(string $type, bool $not): string - { - switch ($type) { - case 'numeric': - return 'assertIs' . ($not ? 'Not' : '') . 'Numeric'; - - case 'integer': - case 'int': - return 'assertIs' . ($not ? 'Not' : '') . 'Int'; - - case 'double': - case 'float': - case 'real': - return 'assertIs' . ($not ? 'Not' : '') . 'Float'; - - case 'string': - return 'assertIs' . ($not ? 'Not' : '') . 'String'; - - case 'boolean': - case 'bool': - return 'assertIs' . ($not ? 'Not' : '') . 'Bool'; - - case 'null': - return 'assert' . ($not ? 'Not' : '') . 'Null'; - - case 'array': - return 'assertIs' . ($not ? 'Not' : '') . 'Array'; - - case 'object': - return 'assertIs' . ($not ? 'Not' : '') . 'Object'; - - case 'resource': - return 'assertIs' . ($not ? 'Not' : '') . 'Resource'; - - case 'scalar': - return 'assertIs' . ($not ? 'Not' : '') . 'Scalar'; - - case 'callable': - return 'assertIs' . ($not ? 'Not' : '') . 'Callable'; - - case 'iterable': - return 'assertIs' . ($not ? 'Not' : '') . 'Iterable'; - } - - throw new Exception( - sprintf( - '"%s" is not a type supported by assertInternalType() / assertNotInternalType()', - $type - ) - ); - } } diff --git a/vendor/phpunit/phpunit/src/Framework/Assert/Functions.php b/vendor/phpunit/phpunit/src/Framework/Assert/Functions.php index 6af388b2c..7c4831d0f 100644 --- a/vendor/phpunit/phpunit/src/Framework/Assert/Functions.php +++ b/vendor/phpunit/phpunit/src/Framework/Assert/Functions.php @@ -7,10 +7,14 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ -use PHPUnit\Framework\Assert; -use PHPUnit\Framework\AssertionFailedError; +namespace PHPUnit\Framework; + +use function func_get_args; +use ArrayAccess; +use Countable; +use DOMDocument; +use DOMElement; use PHPUnit\Framework\Constraint\ArrayHasKey; -use PHPUnit\Framework\Constraint\Attribute; use PHPUnit\Framework\Constraint\Callback; use PHPUnit\Framework\Constraint\ClassHasAttribute; use PHPUnit\Framework\Constraint\ClassHasStaticAttribute; @@ -22,6 +26,9 @@ use PHPUnit\Framework\Constraint\GreaterThan; use PHPUnit\Framework\Constraint\IsAnything; use PHPUnit\Framework\Constraint\IsEmpty; use PHPUnit\Framework\Constraint\IsEqual; +use PHPUnit\Framework\Constraint\IsEqualCanonicalizing; +use PHPUnit\Framework\Constraint\IsEqualIgnoringCase; +use PHPUnit\Framework\Constraint\IsEqualWithDelta; use PHPUnit\Framework\Constraint\IsFalse; use PHPUnit\Framework\Constraint\IsFinite; use PHPUnit\Framework\Constraint\IsIdentical; @@ -39,17 +46,16 @@ use PHPUnit\Framework\Constraint\LogicalAnd; use PHPUnit\Framework\Constraint\LogicalNot; use PHPUnit\Framework\Constraint\LogicalOr; use PHPUnit\Framework\Constraint\LogicalXor; +use PHPUnit\Framework\Constraint\ObjectEquals; use PHPUnit\Framework\Constraint\ObjectHasAttribute; use PHPUnit\Framework\Constraint\RegularExpression; use PHPUnit\Framework\Constraint\StringContains; use PHPUnit\Framework\Constraint\StringEndsWith; use PHPUnit\Framework\Constraint\StringMatchesFormatDescription; use PHPUnit\Framework\Constraint\StringStartsWith; -use PHPUnit\Framework\Constraint\TraversableContains; use PHPUnit\Framework\Constraint\TraversableContainsEqual; use PHPUnit\Framework\Constraint\TraversableContainsIdentical; use PHPUnit\Framework\Constraint\TraversableContainsOnly; -use PHPUnit\Framework\ExpectationFailedException; use PHPUnit\Framework\MockObject\Rule\AnyInvokedCount as AnyInvokedCountMatcher; use PHPUnit\Framework\MockObject\Rule\InvokedAtIndex as InvokedAtIndexMatcher; use PHPUnit\Framework\MockObject\Rule\InvokedAtLeastCount as InvokedAtLeastCountMatcher; @@ -63,6 +69,7 @@ use PHPUnit\Framework\MockObject\Stub\ReturnCallback as ReturnCallbackStub; use PHPUnit\Framework\MockObject\Stub\ReturnSelf as ReturnSelfStub; use PHPUnit\Framework\MockObject\Stub\ReturnStub; use PHPUnit\Framework\MockObject\Stub\ReturnValueMap as ReturnValueMapStub; +use Throwable; if (!function_exists('PHPUnit\Framework\assertArrayHasKey')) { /** @@ -71,37 +78,17 @@ if (!function_exists('PHPUnit\Framework\assertArrayHasKey')) { * @param int|string $key * @param array|ArrayAccess $array * + * @throws ExpectationFailedException * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws Exception - * @throws ExpectationFailedException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertArrayHasKey */ function assertArrayHasKey($key, $array, string $message = ''): void { - Assert::assertArrayHasKey(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\assertArraySubset')) { - /** - * Asserts that an array has a specified subset. - * - * @param array|ArrayAccess $subset - * @param array|ArrayAccess $array - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @codeCoverageIgnore - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3494 - * @see Assert::assertArraySubset - */ - function assertArraySubset($subset, $array, bool $checkForObjectIdentity = false, string $message = ''): void - { - Assert::assertArraySubset(...\func_get_args()); + Assert::assertArrayHasKey(...func_get_args()); } } @@ -112,15 +99,17 @@ if (!function_exists('PHPUnit\Framework\assertArrayNotHasKey')) { * @param int|string $key * @param array|ArrayAccess $array * + * @throws ExpectationFailedException * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws Exception - * @throws ExpectationFailedException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertArrayNotHasKey */ function assertArrayNotHasKey($key, $array, string $message = ''): void { - Assert::assertArrayNotHasKey(...\func_get_args()); + Assert::assertArrayNotHasKey(...func_get_args()); } } @@ -128,44 +117,24 @@ if (!function_exists('PHPUnit\Framework\assertContains')) { /** * Asserts that a haystack contains a needle. * + * @throws ExpectationFailedException * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws Exception - * @throws ExpectationFailedException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertContains */ - function assertContains($needle, $haystack, string $message = '', bool $ignoreCase = false, bool $checkForObjectIdentity = true, bool $checkForNonObjectIdentity = false): void + function assertContains($needle, iterable $haystack, string $message = ''): void { - Assert::assertContains(...\func_get_args()); + Assert::assertContains(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\assertContainsEquals')) { function assertContainsEquals($needle, iterable $haystack, string $message = ''): void { - Assert::assertContainsEquals(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\assertAttributeContains')) { - /** - * Asserts that a haystack that is stored in a static attribute of a class - * or an attribute of an object contains a needle. - * - * @param object|string $haystackClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - * - * @see Assert::assertAttributeContains - */ - function assertAttributeContains($needle, string $haystackAttributeName, $haystackClassOrObject, string $message = '', bool $ignoreCase = false, bool $checkForObjectIdentity = true, bool $checkForNonObjectIdentity = false): void - { - Assert::assertAttributeContains(...\func_get_args()); + Assert::assertContainsEquals(...func_get_args()); } } @@ -173,44 +142,24 @@ if (!function_exists('PHPUnit\Framework\assertNotContains')) { /** * Asserts that a haystack does not contain a needle. * + * @throws ExpectationFailedException * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws Exception - * @throws ExpectationFailedException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertNotContains */ - function assertNotContains($needle, $haystack, string $message = '', bool $ignoreCase = false, bool $checkForObjectIdentity = true, bool $checkForNonObjectIdentity = false): void + function assertNotContains($needle, iterable $haystack, string $message = ''): void { - Assert::assertNotContains(...\func_get_args()); + Assert::assertNotContains(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\assertNotContainsEquals')) { function assertNotContainsEquals($needle, iterable $haystack, string $message = ''): void { - Assert::assertNotContainsEquals(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\assertAttributeNotContains')) { - /** - * Asserts that a haystack that is stored in a static attribute of a class - * or an attribute of an object does not contain a needle. - * - * @param object|string $haystackClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - * - * @see Assert::assertAttributeNotContains - */ - function assertAttributeNotContains($needle, string $haystackAttributeName, $haystackClassOrObject, string $message = '', bool $ignoreCase = false, bool $checkForObjectIdentity = true, bool $checkForNonObjectIdentity = false): void - { - Assert::assertAttributeNotContains(...\func_get_args()); + Assert::assertNotContainsEquals(...func_get_args()); } } @@ -218,14 +167,16 @@ if (!function_exists('PHPUnit\Framework\assertContainsOnly')) { /** * Asserts that a haystack contains only values of a given type. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertContainsOnly */ function assertContainsOnly(string $type, iterable $haystack, ?bool $isNativeType = null, string $message = ''): void { - Assert::assertContainsOnly(...\func_get_args()); + Assert::assertContainsOnly(...func_get_args()); } } @@ -233,37 +184,16 @@ if (!function_exists('PHPUnit\Framework\assertContainsOnlyInstancesOf')) { /** * Asserts that a haystack contains only instances of a given class name. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertContainsOnlyInstancesOf */ function assertContainsOnlyInstancesOf(string $className, iterable $haystack, string $message = ''): void { - Assert::assertContainsOnlyInstancesOf(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\assertAttributeContainsOnly')) { - /** - * Asserts that a haystack that is stored in a static attribute of a class - * or an attribute of an object contains only values of a given type. - * - * @param object|string $haystackClassOrObject - * @param bool $isNativeType - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - * - * @see Assert::assertAttributeContainsOnly - */ - function assertAttributeContainsOnly(string $type, string $haystackAttributeName, $haystackClassOrObject, ?bool $isNativeType = null, string $message = ''): void - { - Assert::assertAttributeContainsOnly(...\func_get_args()); + Assert::assertContainsOnlyInstancesOf(...func_get_args()); } } @@ -271,38 +201,16 @@ if (!function_exists('PHPUnit\Framework\assertNotContainsOnly')) { /** * Asserts that a haystack does not contain only values of a given type. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertNotContainsOnly */ function assertNotContainsOnly(string $type, iterable $haystack, ?bool $isNativeType = null, string $message = ''): void { - Assert::assertNotContainsOnly(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\assertAttributeNotContainsOnly')) { - /** - * Asserts that a haystack that is stored in a static attribute of a class - * or an attribute of an object does not contain only values of a given - * type. - * - * @param object|string $haystackClassOrObject - * @param bool $isNativeType - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - * - * @see Assert::assertAttributeNotContainsOnly - */ - function assertAttributeNotContainsOnly(string $type, string $haystackAttributeName, $haystackClassOrObject, ?bool $isNativeType = null, string $message = ''): void - { - Assert::assertAttributeNotContainsOnly(...\func_get_args()); + Assert::assertNotContainsOnly(...func_get_args()); } } @@ -312,37 +220,17 @@ if (!function_exists('PHPUnit\Framework\assertCount')) { * * @param Countable|iterable $haystack * + * @throws ExpectationFailedException * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws Exception - * @throws ExpectationFailedException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertCount */ function assertCount(int $expectedCount, $haystack, string $message = ''): void { - Assert::assertCount(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\assertAttributeCount')) { - /** - * Asserts the number of elements of an array, Countable or Traversable - * that is stored in an attribute. - * - * @param object|string $haystackClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - * - * @see Assert::assertAttributeCount - */ - function assertAttributeCount(int $expectedCount, string $haystackAttributeName, $haystackClassOrObject, string $message = ''): void - { - Assert::assertAttributeCount(...\func_get_args()); + Assert::assertCount(...func_get_args()); } } @@ -352,37 +240,17 @@ if (!function_exists('PHPUnit\Framework\assertNotCount')) { * * @param Countable|iterable $haystack * + * @throws ExpectationFailedException * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws Exception - * @throws ExpectationFailedException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertNotCount */ function assertNotCount(int $expectedCount, $haystack, string $message = ''): void { - Assert::assertNotCount(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\assertAttributeNotCount')) { - /** - * Asserts the number of elements of an array, Countable or Traversable - * that is stored in an attribute. - * - * @param object|string $haystackClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - * - * @see Assert::assertAttributeNotCount - */ - function assertAttributeNotCount(int $expectedCount, string $haystackAttributeName, $haystackClassOrObject, string $message = ''): void - { - Assert::assertAttributeNotCount(...\func_get_args()); + Assert::assertNotCount(...func_get_args()); } } @@ -390,14 +258,16 @@ if (!function_exists('PHPUnit\Framework\assertEquals')) { /** * Asserts that two variables are equal. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertEquals */ - function assertEquals($expected, $actual, string $message = '', float $delta = 0.0, int $maxDepth = 10, bool $canonicalize = false, bool $ignoreCase = false): void + function assertEquals($expected, $actual, string $message = ''): void { - Assert::assertEquals(...\func_get_args()); + Assert::assertEquals(...func_get_args()); } } @@ -405,14 +275,16 @@ if (!function_exists('PHPUnit\Framework\assertEqualsCanonicalizing')) { /** * Asserts that two variables are equal (canonicalizing). * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertEqualsCanonicalizing */ function assertEqualsCanonicalizing($expected, $actual, string $message = ''): void { - Assert::assertEqualsCanonicalizing(...\func_get_args()); + Assert::assertEqualsCanonicalizing(...func_get_args()); } } @@ -420,14 +292,16 @@ if (!function_exists('PHPUnit\Framework\assertEqualsIgnoringCase')) { /** * Asserts that two variables are equal (ignoring case). * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertEqualsIgnoringCase */ function assertEqualsIgnoringCase($expected, $actual, string $message = ''): void { - Assert::assertEqualsIgnoringCase(...\func_get_args()); + Assert::assertEqualsIgnoringCase(...func_get_args()); } } @@ -435,35 +309,16 @@ if (!function_exists('PHPUnit\Framework\assertEqualsWithDelta')) { /** * Asserts that two variables are equal (with delta). * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertEqualsWithDelta */ function assertEqualsWithDelta($expected, $actual, float $delta, string $message = ''): void { - Assert::assertEqualsWithDelta(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\assertAttributeEquals')) { - /** - * Asserts that a variable is equal to an attribute of an object. - * - * @param object|string $actualClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - * - * @see Assert::assertAttributeEquals - */ - function assertAttributeEquals($expected, string $actualAttributeName, $actualClassOrObject, string $message = '', float $delta = 0.0, int $maxDepth = 10, bool $canonicalize = false, bool $ignoreCase = false): void - { - Assert::assertAttributeEquals(...\func_get_args()); + Assert::assertEqualsWithDelta(...func_get_args()); } } @@ -471,19 +326,16 @@ if (!function_exists('PHPUnit\Framework\assertNotEquals')) { /** * Asserts that two variables are not equal. * - * @param float $delta - * @param int $maxDepth - * @param bool $canonicalize - * @param bool $ignoreCase - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertNotEquals */ - function assertNotEquals($expected, $actual, string $message = '', $delta = 0.0, $maxDepth = 10, $canonicalize = false, $ignoreCase = false): void + function assertNotEquals($expected, $actual, string $message = ''): void { - Assert::assertNotEquals(...\func_get_args()); + Assert::assertNotEquals(...func_get_args()); } } @@ -491,14 +343,16 @@ if (!function_exists('PHPUnit\Framework\assertNotEqualsCanonicalizing')) { /** * Asserts that two variables are not equal (canonicalizing). * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertNotEqualsCanonicalizing */ function assertNotEqualsCanonicalizing($expected, $actual, string $message = ''): void { - Assert::assertNotEqualsCanonicalizing(...\func_get_args()); + Assert::assertNotEqualsCanonicalizing(...func_get_args()); } } @@ -506,14 +360,16 @@ if (!function_exists('PHPUnit\Framework\assertNotEqualsIgnoringCase')) { /** * Asserts that two variables are not equal (ignoring case). * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertNotEqualsIgnoringCase */ function assertNotEqualsIgnoringCase($expected, $actual, string $message = ''): void { - Assert::assertNotEqualsIgnoringCase(...\func_get_args()); + Assert::assertNotEqualsIgnoringCase(...func_get_args()); } } @@ -521,35 +377,30 @@ if (!function_exists('PHPUnit\Framework\assertNotEqualsWithDelta')) { /** * Asserts that two variables are not equal (with delta). * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertNotEqualsWithDelta */ function assertNotEqualsWithDelta($expected, $actual, float $delta, string $message = ''): void { - Assert::assertNotEqualsWithDelta(...\func_get_args()); + Assert::assertNotEqualsWithDelta(...func_get_args()); } } -if (!function_exists('PHPUnit\Framework\assertAttributeNotEquals')) { +if (!function_exists('PHPUnit\Framework\assertObjectEquals')) { /** - * Asserts that a variable is not equal to an attribute of an object. - * - * @param object|string $actualClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception * @throws ExpectationFailedException * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * - * @see Assert::assertAttributeNotEquals + * @see Assert::assertObjectEquals */ - function assertAttributeNotEquals($expected, string $actualAttributeName, $actualClassOrObject, string $message = '', float $delta = 0.0, int $maxDepth = 10, bool $canonicalize = false, bool $ignoreCase = false): void + function assertObjectEquals(object $expected, object $actual, string $method = 'equals', string $message = ''): void { - Assert::assertAttributeNotEquals(...\func_get_args()); + Assert::assertObjectEquals(...func_get_args()); } } @@ -557,38 +408,18 @@ if (!function_exists('PHPUnit\Framework\assertEmpty')) { /** * Asserts that a variable is empty. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert empty $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertEmpty */ function assertEmpty($actual, string $message = ''): void { - Assert::assertEmpty(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\assertAttributeEmpty')) { - /** - * Asserts that a static attribute of a class or an attribute of an object - * is empty. - * - * @param object|string $haystackClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - * - * @see Assert::assertAttributeEmpty - */ - function assertAttributeEmpty(string $haystackAttributeName, $haystackClassOrObject, string $message = ''): void - { - Assert::assertAttributeEmpty(...\func_get_args()); + Assert::assertEmpty(...func_get_args()); } } @@ -596,38 +427,18 @@ if (!function_exists('PHPUnit\Framework\assertNotEmpty')) { /** * Asserts that a variable is not empty. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert !empty $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertNotEmpty */ function assertNotEmpty($actual, string $message = ''): void { - Assert::assertNotEmpty(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\assertAttributeNotEmpty')) { - /** - * Asserts that a static attribute of a class or an attribute of an object - * is not empty. - * - * @param object|string $haystackClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - * - * @see Assert::assertAttributeNotEmpty - */ - function assertAttributeNotEmpty(string $haystackAttributeName, $haystackClassOrObject, string $message = ''): void - { - Assert::assertAttributeNotEmpty(...\func_get_args()); + Assert::assertNotEmpty(...func_get_args()); } } @@ -635,35 +446,16 @@ if (!function_exists('PHPUnit\Framework\assertGreaterThan')) { /** * Asserts that a value is greater than another value. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertGreaterThan */ function assertGreaterThan($expected, $actual, string $message = ''): void { - Assert::assertGreaterThan(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\assertAttributeGreaterThan')) { - /** - * Asserts that an attribute is greater than another value. - * - * @param object|string $actualClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - * - * @see Assert::assertAttributeGreaterThan - */ - function assertAttributeGreaterThan($expected, string $actualAttributeName, $actualClassOrObject, string $message = ''): void - { - Assert::assertAttributeGreaterThan(...\func_get_args()); + Assert::assertGreaterThan(...func_get_args()); } } @@ -671,35 +463,16 @@ if (!function_exists('PHPUnit\Framework\assertGreaterThanOrEqual')) { /** * Asserts that a value is greater than or equal to another value. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertGreaterThanOrEqual */ function assertGreaterThanOrEqual($expected, $actual, string $message = ''): void { - Assert::assertGreaterThanOrEqual(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\assertAttributeGreaterThanOrEqual')) { - /** - * Asserts that an attribute is greater than or equal to another value. - * - * @param object|string $actualClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - * - * @see Assert::assertAttributeGreaterThanOrEqual - */ - function assertAttributeGreaterThanOrEqual($expected, string $actualAttributeName, $actualClassOrObject, string $message = ''): void - { - Assert::assertAttributeGreaterThanOrEqual(...\func_get_args()); + Assert::assertGreaterThanOrEqual(...func_get_args()); } } @@ -707,35 +480,16 @@ if (!function_exists('PHPUnit\Framework\assertLessThan')) { /** * Asserts that a value is smaller than another value. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertLessThan */ function assertLessThan($expected, $actual, string $message = ''): void { - Assert::assertLessThan(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\assertAttributeLessThan')) { - /** - * Asserts that an attribute is smaller than another value. - * - * @param object|string $actualClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - * - * @see Assert::assertAttributeLessThan - */ - function assertAttributeLessThan($expected, string $actualAttributeName, $actualClassOrObject, string $message = ''): void - { - Assert::assertAttributeLessThan(...\func_get_args()); + Assert::assertLessThan(...func_get_args()); } } @@ -743,35 +497,16 @@ if (!function_exists('PHPUnit\Framework\assertLessThanOrEqual')) { /** * Asserts that a value is smaller than or equal to another value. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertLessThanOrEqual */ function assertLessThanOrEqual($expected, $actual, string $message = ''): void { - Assert::assertLessThanOrEqual(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\assertAttributeLessThanOrEqual')) { - /** - * Asserts that an attribute is smaller than or equal to another value. - * - * @param object|string $actualClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - * - * @see Assert::assertAttributeLessThanOrEqual - */ - function assertAttributeLessThanOrEqual($expected, string $actualAttributeName, $actualClassOrObject, string $message = ''): void - { - Assert::assertAttributeLessThanOrEqual(...\func_get_args()); + Assert::assertLessThanOrEqual(...func_get_args()); } } @@ -780,14 +515,16 @@ if (!function_exists('PHPUnit\Framework\assertFileEquals')) { * Asserts that the contents of one file is equal to the contents of another * file. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertFileEquals */ - function assertFileEquals(string $expected, string $actual, string $message = '', bool $canonicalize = false, bool $ignoreCase = false): void + function assertFileEquals(string $expected, string $actual, string $message = ''): void { - Assert::assertFileEquals(...\func_get_args()); + Assert::assertFileEquals(...func_get_args()); } } @@ -796,14 +533,16 @@ if (!function_exists('PHPUnit\Framework\assertFileEqualsCanonicalizing')) { * Asserts that the contents of one file is equal to the contents of another * file (canonicalizing). * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertFileEqualsCanonicalizing */ function assertFileEqualsCanonicalizing(string $expected, string $actual, string $message = ''): void { - Assert::assertFileEqualsCanonicalizing(...\func_get_args()); + Assert::assertFileEqualsCanonicalizing(...func_get_args()); } } @@ -812,14 +551,16 @@ if (!function_exists('PHPUnit\Framework\assertFileEqualsIgnoringCase')) { * Asserts that the contents of one file is equal to the contents of another * file (ignoring case). * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertFileEqualsIgnoringCase */ function assertFileEqualsIgnoringCase(string $expected, string $actual, string $message = ''): void { - Assert::assertFileEqualsIgnoringCase(...\func_get_args()); + Assert::assertFileEqualsIgnoringCase(...func_get_args()); } } @@ -828,14 +569,16 @@ if (!function_exists('PHPUnit\Framework\assertFileNotEquals')) { * Asserts that the contents of one file is not equal to the contents of * another file. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertFileNotEquals */ - function assertFileNotEquals(string $expected, string $actual, string $message = '', bool $canonicalize = false, bool $ignoreCase = false): void + function assertFileNotEquals(string $expected, string $actual, string $message = ''): void { - Assert::assertFileNotEquals(...\func_get_args()); + Assert::assertFileNotEquals(...func_get_args()); } } @@ -844,14 +587,16 @@ if (!function_exists('PHPUnit\Framework\assertFileNotEqualsCanonicalizing')) { * Asserts that the contents of one file is not equal to the contents of another * file (canonicalizing). * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertFileNotEqualsCanonicalizing */ function assertFileNotEqualsCanonicalizing(string $expected, string $actual, string $message = ''): void { - Assert::assertFileNotEqualsCanonicalizing(...\func_get_args()); + Assert::assertFileNotEqualsCanonicalizing(...func_get_args()); } } @@ -860,14 +605,16 @@ if (!function_exists('PHPUnit\Framework\assertFileNotEqualsIgnoringCase')) { * Asserts that the contents of one file is not equal to the contents of another * file (ignoring case). * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertFileNotEqualsIgnoringCase */ function assertFileNotEqualsIgnoringCase(string $expected, string $actual, string $message = ''): void { - Assert::assertFileNotEqualsIgnoringCase(...\func_get_args()); + Assert::assertFileNotEqualsIgnoringCase(...func_get_args()); } } @@ -876,14 +623,16 @@ if (!function_exists('PHPUnit\Framework\assertStringEqualsFile')) { * Asserts that the contents of a string is equal * to the contents of a file. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertStringEqualsFile */ - function assertStringEqualsFile(string $expectedFile, string $actualString, string $message = '', bool $canonicalize = false, bool $ignoreCase = false): void + function assertStringEqualsFile(string $expectedFile, string $actualString, string $message = ''): void { - Assert::assertStringEqualsFile(...\func_get_args()); + Assert::assertStringEqualsFile(...func_get_args()); } } @@ -892,14 +641,16 @@ if (!function_exists('PHPUnit\Framework\assertStringEqualsFileCanonicalizing')) * Asserts that the contents of a string is equal * to the contents of a file (canonicalizing). * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertStringEqualsFileCanonicalizing */ function assertStringEqualsFileCanonicalizing(string $expectedFile, string $actualString, string $message = ''): void { - Assert::assertStringEqualsFileCanonicalizing(...\func_get_args()); + Assert::assertStringEqualsFileCanonicalizing(...func_get_args()); } } @@ -908,14 +659,16 @@ if (!function_exists('PHPUnit\Framework\assertStringEqualsFileIgnoringCase')) { * Asserts that the contents of a string is equal * to the contents of a file (ignoring case). * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertStringEqualsFileIgnoringCase */ function assertStringEqualsFileIgnoringCase(string $expectedFile, string $actualString, string $message = ''): void { - Assert::assertStringEqualsFileIgnoringCase(...\func_get_args()); + Assert::assertStringEqualsFileIgnoringCase(...func_get_args()); } } @@ -924,14 +677,16 @@ if (!function_exists('PHPUnit\Framework\assertStringNotEqualsFile')) { * Asserts that the contents of a string is not equal * to the contents of a file. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertStringNotEqualsFile */ - function assertStringNotEqualsFile(string $expectedFile, string $actualString, string $message = '', bool $canonicalize = false, bool $ignoreCase = false): void + function assertStringNotEqualsFile(string $expectedFile, string $actualString, string $message = ''): void { - Assert::assertStringNotEqualsFile(...\func_get_args()); + Assert::assertStringNotEqualsFile(...func_get_args()); } } @@ -940,14 +695,16 @@ if (!function_exists('PHPUnit\Framework\assertStringNotEqualsFileCanonicalizing' * Asserts that the contents of a string is not equal * to the contents of a file (canonicalizing). * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertStringNotEqualsFileCanonicalizing */ function assertStringNotEqualsFileCanonicalizing(string $expectedFile, string $actualString, string $message = ''): void { - Assert::assertStringNotEqualsFileCanonicalizing(...\func_get_args()); + Assert::assertStringNotEqualsFileCanonicalizing(...func_get_args()); } } @@ -956,14 +713,16 @@ if (!function_exists('PHPUnit\Framework\assertStringNotEqualsFileIgnoringCase')) * Asserts that the contents of a string is not equal * to the contents of a file (ignoring case). * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertStringNotEqualsFileIgnoringCase */ function assertStringNotEqualsFileIgnoringCase(string $expectedFile, string $actualString, string $message = ''): void { - Assert::assertStringNotEqualsFileIgnoringCase(...\func_get_args()); + Assert::assertStringNotEqualsFileIgnoringCase(...func_get_args()); } } @@ -971,14 +730,33 @@ if (!function_exists('PHPUnit\Framework\assertIsReadable')) { /** * Asserts that a file/dir is readable. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertIsReadable */ function assertIsReadable(string $filename, string $message = ''): void { - Assert::assertIsReadable(...\func_get_args()); + Assert::assertIsReadable(...func_get_args()); + } +} + +if (!function_exists('PHPUnit\Framework\assertIsNotReadable')) { + /** + * Asserts that a file/dir exists and is not readable. + * + * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @see Assert::assertIsNotReadable + */ + function assertIsNotReadable(string $filename, string $message = ''): void + { + Assert::assertIsNotReadable(...func_get_args()); } } @@ -986,14 +764,20 @@ if (!function_exists('PHPUnit\Framework\assertNotIsReadable')) { /** * Asserts that a file/dir exists and is not readable. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4062 + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertNotIsReadable */ function assertNotIsReadable(string $filename, string $message = ''): void { - Assert::assertNotIsReadable(...\func_get_args()); + Assert::assertNotIsReadable(...func_get_args()); } } @@ -1001,14 +785,33 @@ if (!function_exists('PHPUnit\Framework\assertIsWritable')) { /** * Asserts that a file/dir exists and is writable. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertIsWritable */ function assertIsWritable(string $filename, string $message = ''): void { - Assert::assertIsWritable(...\func_get_args()); + Assert::assertIsWritable(...func_get_args()); + } +} + +if (!function_exists('PHPUnit\Framework\assertIsNotWritable')) { + /** + * Asserts that a file/dir exists and is not writable. + * + * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @see Assert::assertIsNotWritable + */ + function assertIsNotWritable(string $filename, string $message = ''): void + { + Assert::assertIsNotWritable(...func_get_args()); } } @@ -1016,14 +819,20 @@ if (!function_exists('PHPUnit\Framework\assertNotIsWritable')) { /** * Asserts that a file/dir exists and is not writable. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4065 + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertNotIsWritable */ function assertNotIsWritable(string $filename, string $message = ''): void { - Assert::assertNotIsWritable(...\func_get_args()); + Assert::assertNotIsWritable(...func_get_args()); } } @@ -1031,14 +840,33 @@ if (!function_exists('PHPUnit\Framework\assertDirectoryExists')) { /** * Asserts that a directory exists. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertDirectoryExists */ function assertDirectoryExists(string $directory, string $message = ''): void { - Assert::assertDirectoryExists(...\func_get_args()); + Assert::assertDirectoryExists(...func_get_args()); + } +} + +if (!function_exists('PHPUnit\Framework\assertDirectoryDoesNotExist')) { + /** + * Asserts that a directory does not exist. + * + * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @see Assert::assertDirectoryDoesNotExist + */ + function assertDirectoryDoesNotExist(string $directory, string $message = ''): void + { + Assert::assertDirectoryDoesNotExist(...func_get_args()); } } @@ -1046,14 +874,20 @@ if (!function_exists('PHPUnit\Framework\assertDirectoryNotExists')) { /** * Asserts that a directory does not exist. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4068 + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertDirectoryNotExists */ function assertDirectoryNotExists(string $directory, string $message = ''): void { - Assert::assertDirectoryNotExists(...\func_get_args()); + Assert::assertDirectoryNotExists(...func_get_args()); } } @@ -1061,14 +895,33 @@ if (!function_exists('PHPUnit\Framework\assertDirectoryIsReadable')) { /** * Asserts that a directory exists and is readable. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertDirectoryIsReadable */ function assertDirectoryIsReadable(string $directory, string $message = ''): void { - Assert::assertDirectoryIsReadable(...\func_get_args()); + Assert::assertDirectoryIsReadable(...func_get_args()); + } +} + +if (!function_exists('PHPUnit\Framework\assertDirectoryIsNotReadable')) { + /** + * Asserts that a directory exists and is not readable. + * + * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @see Assert::assertDirectoryIsNotReadable + */ + function assertDirectoryIsNotReadable(string $directory, string $message = ''): void + { + Assert::assertDirectoryIsNotReadable(...func_get_args()); } } @@ -1076,14 +929,20 @@ if (!function_exists('PHPUnit\Framework\assertDirectoryNotIsReadable')) { /** * Asserts that a directory exists and is not readable. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4071 + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertDirectoryNotIsReadable */ function assertDirectoryNotIsReadable(string $directory, string $message = ''): void { - Assert::assertDirectoryNotIsReadable(...\func_get_args()); + Assert::assertDirectoryNotIsReadable(...func_get_args()); } } @@ -1091,14 +950,33 @@ if (!function_exists('PHPUnit\Framework\assertDirectoryIsWritable')) { /** * Asserts that a directory exists and is writable. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertDirectoryIsWritable */ function assertDirectoryIsWritable(string $directory, string $message = ''): void { - Assert::assertDirectoryIsWritable(...\func_get_args()); + Assert::assertDirectoryIsWritable(...func_get_args()); + } +} + +if (!function_exists('PHPUnit\Framework\assertDirectoryIsNotWritable')) { + /** + * Asserts that a directory exists and is not writable. + * + * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @see Assert::assertDirectoryIsNotWritable + */ + function assertDirectoryIsNotWritable(string $directory, string $message = ''): void + { + Assert::assertDirectoryIsNotWritable(...func_get_args()); } } @@ -1106,14 +984,20 @@ if (!function_exists('PHPUnit\Framework\assertDirectoryNotIsWritable')) { /** * Asserts that a directory exists and is not writable. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4074 + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertDirectoryNotIsWritable */ function assertDirectoryNotIsWritable(string $directory, string $message = ''): void { - Assert::assertDirectoryNotIsWritable(...\func_get_args()); + Assert::assertDirectoryNotIsWritable(...func_get_args()); } } @@ -1121,14 +1005,33 @@ if (!function_exists('PHPUnit\Framework\assertFileExists')) { /** * Asserts that a file exists. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertFileExists */ function assertFileExists(string $filename, string $message = ''): void { - Assert::assertFileExists(...\func_get_args()); + Assert::assertFileExists(...func_get_args()); + } +} + +if (!function_exists('PHPUnit\Framework\assertFileDoesNotExist')) { + /** + * Asserts that a file does not exist. + * + * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @see Assert::assertFileDoesNotExist + */ + function assertFileDoesNotExist(string $filename, string $message = ''): void + { + Assert::assertFileDoesNotExist(...func_get_args()); } } @@ -1136,14 +1039,20 @@ if (!function_exists('PHPUnit\Framework\assertFileNotExists')) { /** * Asserts that a file does not exist. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4077 + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertFileNotExists */ function assertFileNotExists(string $filename, string $message = ''): void { - Assert::assertFileNotExists(...\func_get_args()); + Assert::assertFileNotExists(...func_get_args()); } } @@ -1151,14 +1060,33 @@ if (!function_exists('PHPUnit\Framework\assertFileIsReadable')) { /** * Asserts that a file exists and is readable. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertFileIsReadable */ function assertFileIsReadable(string $file, string $message = ''): void { - Assert::assertFileIsReadable(...\func_get_args()); + Assert::assertFileIsReadable(...func_get_args()); + } +} + +if (!function_exists('PHPUnit\Framework\assertFileIsNotReadable')) { + /** + * Asserts that a file exists and is not readable. + * + * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @see Assert::assertFileIsNotReadable + */ + function assertFileIsNotReadable(string $file, string $message = ''): void + { + Assert::assertFileIsNotReadable(...func_get_args()); } } @@ -1166,14 +1094,20 @@ if (!function_exists('PHPUnit\Framework\assertFileNotIsReadable')) { /** * Asserts that a file exists and is not readable. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4080 + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertFileNotIsReadable */ function assertFileNotIsReadable(string $file, string $message = ''): void { - Assert::assertFileNotIsReadable(...\func_get_args()); + Assert::assertFileNotIsReadable(...func_get_args()); } } @@ -1181,14 +1115,33 @@ if (!function_exists('PHPUnit\Framework\assertFileIsWritable')) { /** * Asserts that a file exists and is writable. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertFileIsWritable */ function assertFileIsWritable(string $file, string $message = ''): void { - Assert::assertFileIsWritable(...\func_get_args()); + Assert::assertFileIsWritable(...func_get_args()); + } +} + +if (!function_exists('PHPUnit\Framework\assertFileIsNotWritable')) { + /** + * Asserts that a file exists and is not writable. + * + * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @see Assert::assertFileIsNotWritable + */ + function assertFileIsNotWritable(string $file, string $message = ''): void + { + Assert::assertFileIsNotWritable(...func_get_args()); } } @@ -1196,14 +1149,20 @@ if (!function_exists('PHPUnit\Framework\assertFileNotIsWritable')) { /** * Asserts that a file exists and is not writable. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4083 + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertFileNotIsWritable */ function assertFileNotIsWritable(string $file, string $message = ''): void { - Assert::assertFileNotIsWritable(...\func_get_args()); + Assert::assertFileNotIsWritable(...func_get_args()); } } @@ -1211,16 +1170,18 @@ if (!function_exists('PHPUnit\Framework\assertTrue')) { /** * Asserts that a condition is true. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert true $condition * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertTrue */ function assertTrue($condition, string $message = ''): void { - Assert::assertTrue(...\func_get_args()); + Assert::assertTrue(...func_get_args()); } } @@ -1228,16 +1189,18 @@ if (!function_exists('PHPUnit\Framework\assertNotTrue')) { /** * Asserts that a condition is not true. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert !true $condition * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertNotTrue */ function assertNotTrue($condition, string $message = ''): void { - Assert::assertNotTrue(...\func_get_args()); + Assert::assertNotTrue(...func_get_args()); } } @@ -1245,16 +1208,18 @@ if (!function_exists('PHPUnit\Framework\assertFalse')) { /** * Asserts that a condition is false. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert false $condition * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertFalse */ function assertFalse($condition, string $message = ''): void { - Assert::assertFalse(...\func_get_args()); + Assert::assertFalse(...func_get_args()); } } @@ -1262,16 +1227,18 @@ if (!function_exists('PHPUnit\Framework\assertNotFalse')) { /** * Asserts that a condition is not false. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert !false $condition * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertNotFalse */ function assertNotFalse($condition, string $message = ''): void { - Assert::assertNotFalse(...\func_get_args()); + Assert::assertNotFalse(...func_get_args()); } } @@ -1279,16 +1246,18 @@ if (!function_exists('PHPUnit\Framework\assertNull')) { /** * Asserts that a variable is null. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert null $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertNull */ function assertNull($actual, string $message = ''): void { - Assert::assertNull(...\func_get_args()); + Assert::assertNull(...func_get_args()); } } @@ -1296,16 +1265,18 @@ if (!function_exists('PHPUnit\Framework\assertNotNull')) { /** * Asserts that a variable is not null. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert !null $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertNotNull */ function assertNotNull($actual, string $message = ''): void { - Assert::assertNotNull(...\func_get_args()); + Assert::assertNotNull(...func_get_args()); } } @@ -1313,14 +1284,16 @@ if (!function_exists('PHPUnit\Framework\assertFinite')) { /** * Asserts that a variable is finite. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertFinite */ function assertFinite($actual, string $message = ''): void { - Assert::assertFinite(...\func_get_args()); + Assert::assertFinite(...func_get_args()); } } @@ -1328,14 +1301,16 @@ if (!function_exists('PHPUnit\Framework\assertInfinite')) { /** * Asserts that a variable is infinite. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertInfinite */ function assertInfinite($actual, string $message = ''): void { - Assert::assertInfinite(...\func_get_args()); + Assert::assertInfinite(...func_get_args()); } } @@ -1343,14 +1318,16 @@ if (!function_exists('PHPUnit\Framework\assertNan')) { /** * Asserts that a variable is nan. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertNan */ function assertNan($actual, string $message = ''): void { - Assert::assertNan(...\func_get_args()); + Assert::assertNan(...func_get_args()); } } @@ -1358,15 +1335,17 @@ if (!function_exists('PHPUnit\Framework\assertClassHasAttribute')) { /** * Asserts that a class has a specified attribute. * + * @throws ExpectationFailedException * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws Exception - * @throws ExpectationFailedException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertClassHasAttribute */ function assertClassHasAttribute(string $attributeName, string $className, string $message = ''): void { - Assert::assertClassHasAttribute(...\func_get_args()); + Assert::assertClassHasAttribute(...func_get_args()); } } @@ -1374,15 +1353,17 @@ if (!function_exists('PHPUnit\Framework\assertClassNotHasAttribute')) { /** * Asserts that a class does not have a specified attribute. * + * @throws ExpectationFailedException * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws Exception - * @throws ExpectationFailedException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertClassNotHasAttribute */ function assertClassNotHasAttribute(string $attributeName, string $className, string $message = ''): void { - Assert::assertClassNotHasAttribute(...\func_get_args()); + Assert::assertClassNotHasAttribute(...func_get_args()); } } @@ -1390,15 +1371,17 @@ if (!function_exists('PHPUnit\Framework\assertClassHasStaticAttribute')) { /** * Asserts that a class has a specified static attribute. * + * @throws ExpectationFailedException * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws Exception - * @throws ExpectationFailedException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertClassHasStaticAttribute */ function assertClassHasStaticAttribute(string $attributeName, string $className, string $message = ''): void { - Assert::assertClassHasStaticAttribute(...\func_get_args()); + Assert::assertClassHasStaticAttribute(...func_get_args()); } } @@ -1406,15 +1389,17 @@ if (!function_exists('PHPUnit\Framework\assertClassNotHasStaticAttribute')) { /** * Asserts that a class does not have a specified static attribute. * + * @throws ExpectationFailedException * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws Exception - * @throws ExpectationFailedException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertClassNotHasStaticAttribute */ function assertClassNotHasStaticAttribute(string $attributeName, string $className, string $message = ''): void { - Assert::assertClassNotHasStaticAttribute(...\func_get_args()); + Assert::assertClassNotHasStaticAttribute(...func_get_args()); } } @@ -1424,15 +1409,17 @@ if (!function_exists('PHPUnit\Framework\assertObjectHasAttribute')) { * * @param object $object * + * @throws ExpectationFailedException * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws Exception - * @throws ExpectationFailedException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertObjectHasAttribute */ function assertObjectHasAttribute(string $attributeName, $object, string $message = ''): void { - Assert::assertObjectHasAttribute(...\func_get_args()); + Assert::assertObjectHasAttribute(...func_get_args()); } } @@ -1442,15 +1429,17 @@ if (!function_exists('PHPUnit\Framework\assertObjectNotHasAttribute')) { * * @param object $object * + * @throws ExpectationFailedException * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws Exception - * @throws ExpectationFailedException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertObjectNotHasAttribute */ function assertObjectNotHasAttribute(string $attributeName, $object, string $message = ''): void { - Assert::assertObjectNotHasAttribute(...\func_get_args()); + Assert::assertObjectNotHasAttribute(...func_get_args()); } } @@ -1460,40 +1449,20 @@ if (!function_exists('PHPUnit\Framework\assertSame')) { * Used on objects, it asserts that two variables reference * the same object. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-template ExpectedType * @psalm-param ExpectedType $expected * @psalm-assert =ExpectedType $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertSame */ function assertSame($expected, $actual, string $message = ''): void { - Assert::assertSame(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\assertAttributeSame')) { - /** - * Asserts that a variable and an attribute of an object have the same type - * and value. - * - * @param object|string $actualClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - * - * @see Assert::assertAttributeSame - */ - function assertAttributeSame($expected, string $actualAttributeName, $actualClassOrObject, string $message = ''): void - { - Assert::assertAttributeSame(...\func_get_args()); + Assert::assertSame(...func_get_args()); } } @@ -1503,36 +1472,16 @@ if (!function_exists('PHPUnit\Framework\assertNotSame')) { * Used on objects, it asserts that two variables do not reference * the same object. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertNotSame */ function assertNotSame($expected, $actual, string $message = ''): void { - Assert::assertNotSame(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\assertAttributeNotSame')) { - /** - * Asserts that a variable and an attribute of an object do not have the - * same type and value. - * - * @param object|string $actualClassOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - * - * @see Assert::assertAttributeNotSame - */ - function assertAttributeNotSame($expected, string $actualAttributeName, $actualClassOrObject, string $message = ''): void - { - Assert::assertAttributeNotSame(...\func_get_args()); + Assert::assertNotSame(...func_get_args()); } } @@ -1540,42 +1489,21 @@ if (!function_exists('PHPUnit\Framework\assertInstanceOf')) { /** * Asserts that a variable is of a given type. * + * @throws ExpectationFailedException * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws Exception - * @throws ExpectationFailedException * * @psalm-template ExpectedType of object * @psalm-param class-string $expected * @psalm-assert =ExpectedType $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertInstanceOf */ function assertInstanceOf(string $expected, $actual, string $message = ''): void { - Assert::assertInstanceOf(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\assertAttributeInstanceOf')) { - /** - * Asserts that an attribute is of a given type. - * - * @param object|string $classOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - * - * @psalm-param class-string $expected - * - * @see Assert::assertAttributeInstanceOf - */ - function assertAttributeInstanceOf(string $expected, string $attributeName, $classOrObject, string $message = ''): void - { - Assert::assertAttributeInstanceOf(...\func_get_args()); + Assert::assertInstanceOf(...func_get_args()); } } @@ -1583,81 +1511,21 @@ if (!function_exists('PHPUnit\Framework\assertNotInstanceOf')) { /** * Asserts that a variable is not of a given type. * + * @throws ExpectationFailedException * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws Exception - * @throws ExpectationFailedException * * @psalm-template ExpectedType of object * @psalm-param class-string $expected * @psalm-assert !ExpectedType $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertNotInstanceOf */ function assertNotInstanceOf(string $expected, $actual, string $message = ''): void { - Assert::assertNotInstanceOf(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\assertAttributeNotInstanceOf')) { - /** - * Asserts that an attribute is of a given type. - * - * @param object|string $classOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - * - * @psalm-param class-string $expected - * - * @see Assert::assertAttributeNotInstanceOf - */ - function assertAttributeNotInstanceOf(string $expected, string $attributeName, $classOrObject, string $message = ''): void - { - Assert::assertAttributeNotInstanceOf(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\assertInternalType')) { - /** - * Asserts that a variable is of a given type. - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3369 - * @codeCoverageIgnore - * - * @see Assert::assertInternalType - */ - function assertInternalType(string $expected, $actual, string $message = ''): void - { - Assert::assertInternalType(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\assertAttributeInternalType')) { - /** - * Asserts that an attribute is of a given type. - * - * @param object|string $classOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - * - * @see Assert::assertAttributeInternalType - */ - function assertAttributeInternalType(string $expected, string $attributeName, $classOrObject, string $message = ''): void - { - Assert::assertAttributeInternalType(...\func_get_args()); + Assert::assertNotInstanceOf(...func_get_args()); } } @@ -1665,16 +1533,18 @@ if (!function_exists('PHPUnit\Framework\assertIsArray')) { /** * Asserts that a variable is of type array. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert array $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsArray */ function assertIsArray($actual, string $message = ''): void { - Assert::assertIsArray(...\func_get_args()); + Assert::assertIsArray(...func_get_args()); } } @@ -1682,16 +1552,18 @@ if (!function_exists('PHPUnit\Framework\assertIsBool')) { /** * Asserts that a variable is of type bool. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert bool $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsBool */ function assertIsBool($actual, string $message = ''): void { - Assert::assertIsBool(...\func_get_args()); + Assert::assertIsBool(...func_get_args()); } } @@ -1699,16 +1571,18 @@ if (!function_exists('PHPUnit\Framework\assertIsFloat')) { /** * Asserts that a variable is of type float. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert float $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsFloat */ function assertIsFloat($actual, string $message = ''): void { - Assert::assertIsFloat(...\func_get_args()); + Assert::assertIsFloat(...func_get_args()); } } @@ -1716,16 +1590,18 @@ if (!function_exists('PHPUnit\Framework\assertIsInt')) { /** * Asserts that a variable is of type int. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert int $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsInt */ function assertIsInt($actual, string $message = ''): void { - Assert::assertIsInt(...\func_get_args()); + Assert::assertIsInt(...func_get_args()); } } @@ -1733,16 +1609,18 @@ if (!function_exists('PHPUnit\Framework\assertIsNumeric')) { /** * Asserts that a variable is of type numeric. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert numeric $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsNumeric */ function assertIsNumeric($actual, string $message = ''): void { - Assert::assertIsNumeric(...\func_get_args()); + Assert::assertIsNumeric(...func_get_args()); } } @@ -1750,16 +1628,18 @@ if (!function_exists('PHPUnit\Framework\assertIsObject')) { /** * Asserts that a variable is of type object. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert object $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsObject */ function assertIsObject($actual, string $message = ''): void { - Assert::assertIsObject(...\func_get_args()); + Assert::assertIsObject(...func_get_args()); } } @@ -1767,16 +1647,37 @@ if (!function_exists('PHPUnit\Framework\assertIsResource')) { /** * Asserts that a variable is of type resource. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert resource $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsResource */ function assertIsResource($actual, string $message = ''): void { - Assert::assertIsResource(...\func_get_args()); + Assert::assertIsResource(...func_get_args()); + } +} + +if (!function_exists('PHPUnit\Framework\assertIsClosedResource')) { + /** + * Asserts that a variable is of type resource and is closed. + * + * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @psalm-assert resource $actual + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @see Assert::assertIsClosedResource + */ + function assertIsClosedResource($actual, string $message = ''): void + { + Assert::assertIsClosedResource(...func_get_args()); } } @@ -1784,16 +1685,18 @@ if (!function_exists('PHPUnit\Framework\assertIsString')) { /** * Asserts that a variable is of type string. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert string $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsString */ function assertIsString($actual, string $message = ''): void { - Assert::assertIsString(...\func_get_args()); + Assert::assertIsString(...func_get_args()); } } @@ -1801,16 +1704,18 @@ if (!function_exists('PHPUnit\Framework\assertIsScalar')) { /** * Asserts that a variable is of type scalar. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert scalar $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsScalar */ function assertIsScalar($actual, string $message = ''): void { - Assert::assertIsScalar(...\func_get_args()); + Assert::assertIsScalar(...func_get_args()); } } @@ -1818,16 +1723,18 @@ if (!function_exists('PHPUnit\Framework\assertIsCallable')) { /** * Asserts that a variable is of type callable. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert callable $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsCallable */ function assertIsCallable($actual, string $message = ''): void { - Assert::assertIsCallable(...\func_get_args()); + Assert::assertIsCallable(...func_get_args()); } } @@ -1835,34 +1742,18 @@ if (!function_exists('PHPUnit\Framework\assertIsIterable')) { /** * Asserts that a variable is of type iterable. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert iterable $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsIterable */ function assertIsIterable($actual, string $message = ''): void { - Assert::assertIsIterable(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\assertNotInternalType')) { - /** - * Asserts that a variable is not of a given type. - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws ExpectationFailedException - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3369 - * @codeCoverageIgnore - * - * @see Assert::assertNotInternalType - */ - function assertNotInternalType(string $expected, $actual, string $message = ''): void - { - Assert::assertNotInternalType(...\func_get_args()); + Assert::assertIsIterable(...func_get_args()); } } @@ -1870,16 +1761,18 @@ if (!function_exists('PHPUnit\Framework\assertIsNotArray')) { /** * Asserts that a variable is not of type array. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert !array $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsNotArray */ function assertIsNotArray($actual, string $message = ''): void { - Assert::assertIsNotArray(...\func_get_args()); + Assert::assertIsNotArray(...func_get_args()); } } @@ -1887,16 +1780,18 @@ if (!function_exists('PHPUnit\Framework\assertIsNotBool')) { /** * Asserts that a variable is not of type bool. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert !bool $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsNotBool */ function assertIsNotBool($actual, string $message = ''): void { - Assert::assertIsNotBool(...\func_get_args()); + Assert::assertIsNotBool(...func_get_args()); } } @@ -1904,16 +1799,18 @@ if (!function_exists('PHPUnit\Framework\assertIsNotFloat')) { /** * Asserts that a variable is not of type float. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert !float $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsNotFloat */ function assertIsNotFloat($actual, string $message = ''): void { - Assert::assertIsNotFloat(...\func_get_args()); + Assert::assertIsNotFloat(...func_get_args()); } } @@ -1921,16 +1818,18 @@ if (!function_exists('PHPUnit\Framework\assertIsNotInt')) { /** * Asserts that a variable is not of type int. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert !int $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsNotInt */ function assertIsNotInt($actual, string $message = ''): void { - Assert::assertIsNotInt(...\func_get_args()); + Assert::assertIsNotInt(...func_get_args()); } } @@ -1938,16 +1837,18 @@ if (!function_exists('PHPUnit\Framework\assertIsNotNumeric')) { /** * Asserts that a variable is not of type numeric. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert !numeric $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsNotNumeric */ function assertIsNotNumeric($actual, string $message = ''): void { - Assert::assertIsNotNumeric(...\func_get_args()); + Assert::assertIsNotNumeric(...func_get_args()); } } @@ -1955,16 +1856,18 @@ if (!function_exists('PHPUnit\Framework\assertIsNotObject')) { /** * Asserts that a variable is not of type object. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert !object $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsNotObject */ function assertIsNotObject($actual, string $message = ''): void { - Assert::assertIsNotObject(...\func_get_args()); + Assert::assertIsNotObject(...func_get_args()); } } @@ -1972,16 +1875,37 @@ if (!function_exists('PHPUnit\Framework\assertIsNotResource')) { /** * Asserts that a variable is not of type resource. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert !resource $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsNotResource */ function assertIsNotResource($actual, string $message = ''): void { - Assert::assertIsNotResource(...\func_get_args()); + Assert::assertIsNotResource(...func_get_args()); + } +} + +if (!function_exists('PHPUnit\Framework\assertIsNotClosedResource')) { + /** + * Asserts that a variable is not of type resource. + * + * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @psalm-assert !resource $actual + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @see Assert::assertIsNotClosedResource + */ + function assertIsNotClosedResource($actual, string $message = ''): void + { + Assert::assertIsNotClosedResource(...func_get_args()); } } @@ -1989,16 +1913,18 @@ if (!function_exists('PHPUnit\Framework\assertIsNotString')) { /** * Asserts that a variable is not of type string. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert !string $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsNotString */ function assertIsNotString($actual, string $message = ''): void { - Assert::assertIsNotString(...\func_get_args()); + Assert::assertIsNotString(...func_get_args()); } } @@ -2006,16 +1932,18 @@ if (!function_exists('PHPUnit\Framework\assertIsNotScalar')) { /** * Asserts that a variable is not of type scalar. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert !scalar $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsNotScalar */ function assertIsNotScalar($actual, string $message = ''): void { - Assert::assertIsNotScalar(...\func_get_args()); + Assert::assertIsNotScalar(...func_get_args()); } } @@ -2023,16 +1951,18 @@ if (!function_exists('PHPUnit\Framework\assertIsNotCallable')) { /** * Asserts that a variable is not of type callable. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert !callable $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsNotCallable */ function assertIsNotCallable($actual, string $message = ''): void { - Assert::assertIsNotCallable(...\func_get_args()); + Assert::assertIsNotCallable(...func_get_args()); } } @@ -2040,37 +1970,35 @@ if (!function_exists('PHPUnit\Framework\assertIsNotIterable')) { /** * Asserts that a variable is not of type iterable. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * * @psalm-assert !iterable $actual * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * * @see Assert::assertIsNotIterable */ function assertIsNotIterable($actual, string $message = ''): void { - Assert::assertIsNotIterable(...\func_get_args()); + Assert::assertIsNotIterable(...func_get_args()); } } -if (!function_exists('PHPUnit\Framework\assertAttributeNotInternalType')) { +if (!function_exists('PHPUnit\Framework\assertMatchesRegularExpression')) { /** - * Asserts that an attribute is of a given type. + * Asserts that a string matches a given regular expression. * - * @param object|string $classOrObject - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * - * @see Assert::assertAttributeNotInternalType + * @see Assert::assertMatchesRegularExpression */ - function assertAttributeNotInternalType(string $expected, string $attributeName, $classOrObject, string $message = ''): void + function assertMatchesRegularExpression(string $pattern, string $string, string $message = ''): void { - Assert::assertAttributeNotInternalType(...\func_get_args()); + Assert::assertMatchesRegularExpression(...func_get_args()); } } @@ -2078,14 +2006,37 @@ if (!function_exists('PHPUnit\Framework\assertRegExp')) { /** * Asserts that a string matches a given regular expression. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4086 + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertRegExp */ function assertRegExp(string $pattern, string $string, string $message = ''): void { - Assert::assertRegExp(...\func_get_args()); + Assert::assertRegExp(...func_get_args()); + } +} + +if (!function_exists('PHPUnit\Framework\assertDoesNotMatchRegularExpression')) { + /** + * Asserts that a string does not match a given regular expression. + * + * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @see Assert::assertDoesNotMatchRegularExpression + */ + function assertDoesNotMatchRegularExpression(string $pattern, string $string, string $message = ''): void + { + Assert::assertDoesNotMatchRegularExpression(...func_get_args()); } } @@ -2093,14 +2044,20 @@ if (!function_exists('PHPUnit\Framework\assertNotRegExp')) { /** * Asserts that a string does not match a given regular expression. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4089 + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertNotRegExp */ function assertNotRegExp(string $pattern, string $string, string $message = ''): void { - Assert::assertNotRegExp(...\func_get_args()); + Assert::assertNotRegExp(...func_get_args()); } } @@ -2112,15 +2069,17 @@ if (!function_exists('PHPUnit\Framework\assertSameSize')) { * @param Countable|iterable $expected * @param Countable|iterable $actual * + * @throws ExpectationFailedException * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws Exception - * @throws ExpectationFailedException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertSameSize */ function assertSameSize($expected, $actual, string $message = ''): void { - Assert::assertSameSize(...\func_get_args()); + Assert::assertSameSize(...func_get_args()); } } @@ -2132,15 +2091,17 @@ if (!function_exists('PHPUnit\Framework\assertNotSameSize')) { * @param Countable|iterable $expected * @param Countable|iterable $actual * + * @throws ExpectationFailedException * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws Exception - * @throws ExpectationFailedException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertNotSameSize */ function assertNotSameSize($expected, $actual, string $message = ''): void { - Assert::assertNotSameSize(...\func_get_args()); + Assert::assertNotSameSize(...func_get_args()); } } @@ -2148,14 +2109,16 @@ if (!function_exists('PHPUnit\Framework\assertStringMatchesFormat')) { /** * Asserts that a string matches a given format string. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertStringMatchesFormat */ function assertStringMatchesFormat(string $format, string $string, string $message = ''): void { - Assert::assertStringMatchesFormat(...\func_get_args()); + Assert::assertStringMatchesFormat(...func_get_args()); } } @@ -2163,14 +2126,16 @@ if (!function_exists('PHPUnit\Framework\assertStringNotMatchesFormat')) { /** * Asserts that a string does not match a given format string. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertStringNotMatchesFormat */ function assertStringNotMatchesFormat(string $format, string $string, string $message = ''): void { - Assert::assertStringNotMatchesFormat(...\func_get_args()); + Assert::assertStringNotMatchesFormat(...func_get_args()); } } @@ -2178,14 +2143,16 @@ if (!function_exists('PHPUnit\Framework\assertStringMatchesFormatFile')) { /** * Asserts that a string matches a given format file. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertStringMatchesFormatFile */ function assertStringMatchesFormatFile(string $formatFile, string $string, string $message = ''): void { - Assert::assertStringMatchesFormatFile(...\func_get_args()); + Assert::assertStringMatchesFormatFile(...func_get_args()); } } @@ -2193,14 +2160,16 @@ if (!function_exists('PHPUnit\Framework\assertStringNotMatchesFormatFile')) { /** * Asserts that a string does not match a given format string. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertStringNotMatchesFormatFile */ function assertStringNotMatchesFormatFile(string $formatFile, string $string, string $message = ''): void { - Assert::assertStringNotMatchesFormatFile(...\func_get_args()); + Assert::assertStringNotMatchesFormatFile(...func_get_args()); } } @@ -2208,14 +2177,16 @@ if (!function_exists('PHPUnit\Framework\assertStringStartsWith')) { /** * Asserts that a string starts with a given prefix. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertStringStartsWith */ function assertStringStartsWith(string $prefix, string $string, string $message = ''): void { - Assert::assertStringStartsWith(...\func_get_args()); + Assert::assertStringStartsWith(...func_get_args()); } } @@ -2226,66 +2197,76 @@ if (!function_exists('PHPUnit\Framework\assertStringStartsNotWith')) { * @param string $prefix * @param string $string * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertStringStartsNotWith */ function assertStringStartsNotWith($prefix, $string, string $message = ''): void { - Assert::assertStringStartsNotWith(...\func_get_args()); + Assert::assertStringStartsNotWith(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\assertStringContainsString')) { /** - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertStringContainsString */ function assertStringContainsString(string $needle, string $haystack, string $message = ''): void { - Assert::assertStringContainsString(...\func_get_args()); + Assert::assertStringContainsString(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\assertStringContainsStringIgnoringCase')) { /** - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertStringContainsStringIgnoringCase */ function assertStringContainsStringIgnoringCase(string $needle, string $haystack, string $message = ''): void { - Assert::assertStringContainsStringIgnoringCase(...\func_get_args()); + Assert::assertStringContainsStringIgnoringCase(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\assertStringNotContainsString')) { /** - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertStringNotContainsString */ function assertStringNotContainsString(string $needle, string $haystack, string $message = ''): void { - Assert::assertStringNotContainsString(...\func_get_args()); + Assert::assertStringNotContainsString(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\assertStringNotContainsStringIgnoringCase')) { /** - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertStringNotContainsStringIgnoringCase */ function assertStringNotContainsStringIgnoringCase(string $needle, string $haystack, string $message = ''): void { - Assert::assertStringNotContainsStringIgnoringCase(...\func_get_args()); + Assert::assertStringNotContainsStringIgnoringCase(...func_get_args()); } } @@ -2293,14 +2274,16 @@ if (!function_exists('PHPUnit\Framework\assertStringEndsWith')) { /** * Asserts that a string ends with a given suffix. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertStringEndsWith */ function assertStringEndsWith(string $suffix, string $string, string $message = ''): void { - Assert::assertStringEndsWith(...\func_get_args()); + Assert::assertStringEndsWith(...func_get_args()); } } @@ -2308,14 +2291,16 @@ if (!function_exists('PHPUnit\Framework\assertStringEndsNotWith')) { /** * Asserts that a string ends not with a given suffix. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertStringEndsNotWith */ function assertStringEndsNotWith(string $suffix, string $string, string $message = ''): void { - Assert::assertStringEndsNotWith(...\func_get_args()); + Assert::assertStringEndsNotWith(...func_get_args()); } } @@ -2323,15 +2308,17 @@ if (!function_exists('PHPUnit\Framework\assertXmlFileEqualsXmlFile')) { /** * Asserts that two XML files are equal. * + * @throws ExpectationFailedException * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws Exception - * @throws ExpectationFailedException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertXmlFileEqualsXmlFile */ function assertXmlFileEqualsXmlFile(string $expectedFile, string $actualFile, string $message = ''): void { - Assert::assertXmlFileEqualsXmlFile(...\func_get_args()); + Assert::assertXmlFileEqualsXmlFile(...func_get_args()); } } @@ -2339,15 +2326,17 @@ if (!function_exists('PHPUnit\Framework\assertXmlFileNotEqualsXmlFile')) { /** * Asserts that two XML files are not equal. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * @throws \PHPUnit\Util\Exception + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertXmlFileNotEqualsXmlFile */ function assertXmlFileNotEqualsXmlFile(string $expectedFile, string $actualFile, string $message = ''): void { - Assert::assertXmlFileNotEqualsXmlFile(...\func_get_args()); + Assert::assertXmlFileNotEqualsXmlFile(...func_get_args()); } } @@ -2357,15 +2346,17 @@ if (!function_exists('PHPUnit\Framework\assertXmlStringEqualsXmlFile')) { * * @param DOMDocument|string $actualXml * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * @throws \PHPUnit\Util\Xml\Exception + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertXmlStringEqualsXmlFile */ function assertXmlStringEqualsXmlFile(string $expectedFile, $actualXml, string $message = ''): void { - Assert::assertXmlStringEqualsXmlFile(...\func_get_args()); + Assert::assertXmlStringEqualsXmlFile(...func_get_args()); } } @@ -2375,15 +2366,17 @@ if (!function_exists('PHPUnit\Framework\assertXmlStringNotEqualsXmlFile')) { * * @param DOMDocument|string $actualXml * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * @throws \PHPUnit\Util\Xml\Exception + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertXmlStringNotEqualsXmlFile */ function assertXmlStringNotEqualsXmlFile(string $expectedFile, $actualXml, string $message = ''): void { - Assert::assertXmlStringNotEqualsXmlFile(...\func_get_args()); + Assert::assertXmlStringNotEqualsXmlFile(...func_get_args()); } } @@ -2394,15 +2387,17 @@ if (!function_exists('PHPUnit\Framework\assertXmlStringEqualsXmlString')) { * @param DOMDocument|string $expectedXml * @param DOMDocument|string $actualXml * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * @throws \PHPUnit\Util\Xml\Exception + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertXmlStringEqualsXmlString */ function assertXmlStringEqualsXmlString($expectedXml, $actualXml, string $message = ''): void { - Assert::assertXmlStringEqualsXmlString(...\func_get_args()); + Assert::assertXmlStringEqualsXmlString(...func_get_args()); } } @@ -2413,15 +2408,17 @@ if (!function_exists('PHPUnit\Framework\assertXmlStringNotEqualsXmlString')) { * @param DOMDocument|string $expectedXml * @param DOMDocument|string $actualXml * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws Exception * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * @throws \PHPUnit\Util\Xml\Exception + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertXmlStringNotEqualsXmlString */ function assertXmlStringNotEqualsXmlString($expectedXml, $actualXml, string $message = ''): void { - Assert::assertXmlStringNotEqualsXmlString(...\func_get_args()); + Assert::assertXmlStringNotEqualsXmlString(...func_get_args()); } } @@ -2429,15 +2426,21 @@ if (!function_exists('PHPUnit\Framework\assertEqualXMLStructure')) { /** * Asserts that a hierarchy of DOMElements matches. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws AssertionFailedError * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @codeCoverageIgnore + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4091 + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertEqualXMLStructure */ function assertEqualXMLStructure(DOMElement $expectedElement, DOMElement $actualElement, bool $checkAttributes = false, string $message = ''): void { - Assert::assertEqualXMLStructure(...\func_get_args()); + Assert::assertEqualXMLStructure(...func_get_args()); } } @@ -2445,14 +2448,16 @@ if (!function_exists('PHPUnit\Framework\assertThat')) { /** * Evaluates a PHPUnit\Framework\Constraint matcher object. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertThat */ function assertThat($value, Constraint $constraint, string $message = ''): void { - Assert::assertThat(...\func_get_args()); + Assert::assertThat(...func_get_args()); } } @@ -2460,14 +2465,16 @@ if (!function_exists('PHPUnit\Framework\assertJson')) { /** * Asserts that a string is a valid JSON string. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertJson */ function assertJson(string $actualJson, string $message = ''): void { - Assert::assertJson(...\func_get_args()); + Assert::assertJson(...func_get_args()); } } @@ -2475,14 +2482,16 @@ if (!function_exists('PHPUnit\Framework\assertJsonStringEqualsJsonString')) { /** * Asserts that two given JSON encoded objects or arrays are equal. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertJsonStringEqualsJsonString */ function assertJsonStringEqualsJsonString(string $expectedJson, string $actualJson, string $message = ''): void { - Assert::assertJsonStringEqualsJsonString(...\func_get_args()); + Assert::assertJsonStringEqualsJsonString(...func_get_args()); } } @@ -2493,14 +2502,16 @@ if (!function_exists('PHPUnit\Framework\assertJsonStringNotEqualsJsonString')) { * @param string $expectedJson * @param string $actualJson * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertJsonStringNotEqualsJsonString */ function assertJsonStringNotEqualsJsonString($expectedJson, $actualJson, string $message = ''): void { - Assert::assertJsonStringNotEqualsJsonString(...\func_get_args()); + Assert::assertJsonStringNotEqualsJsonString(...func_get_args()); } } @@ -2508,14 +2519,16 @@ if (!function_exists('PHPUnit\Framework\assertJsonStringEqualsJsonFile')) { /** * Asserts that the generated JSON encoded object and the content of the given file are equal. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertJsonStringEqualsJsonFile */ function assertJsonStringEqualsJsonFile(string $expectedFile, string $actualJson, string $message = ''): void { - Assert::assertJsonStringEqualsJsonFile(...\func_get_args()); + Assert::assertJsonStringEqualsJsonFile(...func_get_args()); } } @@ -2523,14 +2536,16 @@ if (!function_exists('PHPUnit\Framework\assertJsonStringNotEqualsJsonFile')) { /** * Asserts that the generated JSON encoded object and the content of the given file are not equal. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertJsonStringNotEqualsJsonFile */ function assertJsonStringNotEqualsJsonFile(string $expectedFile, string $actualJson, string $message = ''): void { - Assert::assertJsonStringNotEqualsJsonFile(...\func_get_args()); + Assert::assertJsonStringNotEqualsJsonFile(...func_get_args()); } } @@ -2538,14 +2553,16 @@ if (!function_exists('PHPUnit\Framework\assertJsonFileEqualsJsonFile')) { /** * Asserts that two JSON files are equal. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertJsonFileEqualsJsonFile */ function assertJsonFileEqualsJsonFile(string $expectedFile, string $actualFile, string $message = ''): void { - Assert::assertJsonFileEqualsJsonFile(...\func_get_args()); + Assert::assertJsonFileEqualsJsonFile(...func_get_args()); } } @@ -2553,315 +2570,324 @@ if (!function_exists('PHPUnit\Framework\assertJsonFileNotEqualsJsonFile')) { /** * Asserts that two JSON files are not equal. * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertJsonFileNotEqualsJsonFile */ function assertJsonFileNotEqualsJsonFile(string $expectedFile, string $actualFile, string $message = ''): void { - Assert::assertJsonFileNotEqualsJsonFile(...\func_get_args()); + Assert::assertJsonFileNotEqualsJsonFile(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\logicalAnd')) { function logicalAnd(): LogicalAnd { - return Assert::logicalAnd(...\func_get_args()); + return Assert::logicalAnd(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\logicalOr')) { function logicalOr(): LogicalOr { - return Assert::logicalOr(...\func_get_args()); + return Assert::logicalOr(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\logicalNot')) { function logicalNot(Constraint $constraint): LogicalNot { - return Assert::logicalNot(...\func_get_args()); + return Assert::logicalNot(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\logicalXor')) { function logicalXor(): LogicalXor { - return Assert::logicalXor(...\func_get_args()); + return Assert::logicalXor(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\anything')) { function anything(): IsAnything { - return Assert::anything(...\func_get_args()); + return Assert::anything(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\isTrue')) { function isTrue(): IsTrue { - return Assert::isTrue(...\func_get_args()); + return Assert::isTrue(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\callback')) { function callback(callable $callback): Callback { - return Assert::callback(...\func_get_args()); + return Assert::callback(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\isFalse')) { function isFalse(): IsFalse { - return Assert::isFalse(...\func_get_args()); + return Assert::isFalse(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\isJson')) { function isJson(): IsJson { - return Assert::isJson(...\func_get_args()); + return Assert::isJson(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\isNull')) { function isNull(): IsNull { - return Assert::isNull(...\func_get_args()); + return Assert::isNull(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\isFinite')) { function isFinite(): IsFinite { - return Assert::isFinite(...\func_get_args()); + return Assert::isFinite(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\isInfinite')) { function isInfinite(): IsInfinite { - return Assert::isInfinite(...\func_get_args()); + return Assert::isInfinite(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\isNan')) { function isNan(): IsNan { - return Assert::isNan(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\attribute')) { - function attribute(Constraint $constraint, string $attributeName): Attribute - { - return Assert::attribute(...\func_get_args()); - } -} - -if (!function_exists('PHPUnit\Framework\contains')) { - function contains($value, bool $checkForObjectIdentity = true, bool $checkForNonObjectIdentity = false): TraversableContains - { - return Assert::contains(...\func_get_args()); + return Assert::isNan(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\containsEqual')) { function containsEqual($value): TraversableContainsEqual { - return Assert::containsEqual(...\func_get_args()); + return Assert::containsEqual(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\containsIdentical')) { function containsIdentical($value): TraversableContainsIdentical { - return Assert::containsIdentical(...\func_get_args()); + return Assert::containsIdentical(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\containsOnly')) { function containsOnly(string $type): TraversableContainsOnly { - return Assert::containsOnly(...\func_get_args()); + return Assert::containsOnly(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\containsOnlyInstancesOf')) { function containsOnlyInstancesOf(string $className): TraversableContainsOnly { - return Assert::containsOnlyInstancesOf(...\func_get_args()); + return Assert::containsOnlyInstancesOf(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\arrayHasKey')) { function arrayHasKey($key): ArrayHasKey { - return Assert::arrayHasKey(...\func_get_args()); + return Assert::arrayHasKey(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\equalTo')) { - function equalTo($value, float $delta = 0.0, int $maxDepth = 10, bool $canonicalize = false, bool $ignoreCase = false): IsEqual + function equalTo($value): IsEqual { - return Assert::equalTo(...\func_get_args()); + return Assert::equalTo(...func_get_args()); } } -if (!function_exists('PHPUnit\Framework\attributeEqualTo')) { - function attributeEqualTo(string $attributeName, $value, float $delta = 0.0, int $maxDepth = 10, bool $canonicalize = false, bool $ignoreCase = false): Attribute +if (!function_exists('PHPUnit\Framework\equalToCanonicalizing')) { + function equalToCanonicalizing($value): IsEqualCanonicalizing { - return Assert::attributeEqualTo(...\func_get_args()); + return Assert::equalToCanonicalizing(...func_get_args()); + } +} + +if (!function_exists('PHPUnit\Framework\equalToIgnoringCase')) { + function equalToIgnoringCase($value): IsEqualIgnoringCase + { + return Assert::equalToIgnoringCase(...func_get_args()); + } +} + +if (!function_exists('PHPUnit\Framework\equalToWithDelta')) { + function equalToWithDelta($value, float $delta): IsEqualWithDelta + { + return Assert::equalToWithDelta(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\isEmpty')) { function isEmpty(): IsEmpty { - return Assert::isEmpty(...\func_get_args()); + return Assert::isEmpty(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\isWritable')) { function isWritable(): IsWritable { - return Assert::isWritable(...\func_get_args()); + return Assert::isWritable(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\isReadable')) { function isReadable(): IsReadable { - return Assert::isReadable(...\func_get_args()); + return Assert::isReadable(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\directoryExists')) { function directoryExists(): DirectoryExists { - return Assert::directoryExists(...\func_get_args()); + return Assert::directoryExists(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\fileExists')) { function fileExists(): FileExists { - return Assert::fileExists(...\func_get_args()); + return Assert::fileExists(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\greaterThan')) { function greaterThan($value): GreaterThan { - return Assert::greaterThan(...\func_get_args()); + return Assert::greaterThan(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\greaterThanOrEqual')) { function greaterThanOrEqual($value): LogicalOr { - return Assert::greaterThanOrEqual(...\func_get_args()); + return Assert::greaterThanOrEqual(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\classHasAttribute')) { function classHasAttribute(string $attributeName): ClassHasAttribute { - return Assert::classHasAttribute(...\func_get_args()); + return Assert::classHasAttribute(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\classHasStaticAttribute')) { function classHasStaticAttribute(string $attributeName): ClassHasStaticAttribute { - return Assert::classHasStaticAttribute(...\func_get_args()); + return Assert::classHasStaticAttribute(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\objectHasAttribute')) { function objectHasAttribute($attributeName): ObjectHasAttribute { - return Assert::objectHasAttribute(...\func_get_args()); + return Assert::objectHasAttribute(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\identicalTo')) { function identicalTo($value): IsIdentical { - return Assert::identicalTo(...\func_get_args()); + return Assert::identicalTo(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\isInstanceOf')) { function isInstanceOf(string $className): IsInstanceOf { - return Assert::isInstanceOf(...\func_get_args()); + return Assert::isInstanceOf(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\isType')) { function isType(string $type): IsType { - return Assert::isType(...\func_get_args()); + return Assert::isType(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\lessThan')) { function lessThan($value): LessThan { - return Assert::lessThan(...\func_get_args()); + return Assert::lessThan(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\lessThanOrEqual')) { function lessThanOrEqual($value): LogicalOr { - return Assert::lessThanOrEqual(...\func_get_args()); + return Assert::lessThanOrEqual(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\matchesRegularExpression')) { function matchesRegularExpression(string $pattern): RegularExpression { - return Assert::matchesRegularExpression(...\func_get_args()); + return Assert::matchesRegularExpression(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\matches')) { function matches(string $string): StringMatchesFormatDescription { - return Assert::matches(...\func_get_args()); + return Assert::matches(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\stringStartsWith')) { function stringStartsWith($prefix): StringStartsWith { - return Assert::stringStartsWith(...\func_get_args()); + return Assert::stringStartsWith(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\stringContains')) { function stringContains(string $string, bool $case = true): StringContains { - return Assert::stringContains(...\func_get_args()); + return Assert::stringContains(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\stringEndsWith')) { function stringEndsWith(string $suffix): StringEndsWith { - return Assert::stringEndsWith(...\func_get_args()); + return Assert::stringEndsWith(...func_get_args()); } } if (!function_exists('PHPUnit\Framework\countOf')) { function countOf(int $count): Count { - return Assert::countOf(...\func_get_args()); + return Assert::countOf(...func_get_args()); + } +} + +if (!function_exists('PHPUnit\Framework\objectEquals')) { + function objectEquals(object $object, string $method = 'equals'): ObjectEquals + { + return Assert::objectEquals(...func_get_args()); } } @@ -3002,7 +3028,7 @@ if (!function_exists('PHPUnit\Framework\throwException')) { if (!function_exists('PHPUnit\Framework\onConsecutiveCalls')) { function onConsecutiveCalls(): ConsecutiveCallsStub { - $args = \func_get_args(); + $args = func_get_args(); return new ConsecutiveCallsStub($args); } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/ArraySubset.php b/vendor/phpunit/phpunit/src/Framework/Constraint/ArraySubset.php deleted file mode 100644 index 34c61e3d4..000000000 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/ArraySubset.php +++ /dev/null @@ -1,135 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace PHPUnit\Framework\Constraint; - -use function array_replace_recursive; -use function is_array; -use function iterator_to_array; -use function var_export; -use ArrayObject; -use PHPUnit\Framework\ExpectationFailedException; -use SebastianBergmann\Comparator\ComparisonFailure; -use Traversable; - -/** - * Constraint that asserts that the array it is evaluated for has a specified subset. - * - * Uses array_replace_recursive() to check if a key value subset is part of the - * subject array. - * - * @codeCoverageIgnore - * - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3494 - */ -final class ArraySubset extends Constraint -{ - /** - * @var iterable - */ - private $subset; - - /** - * @var bool - */ - private $strict; - - public function __construct(iterable $subset, bool $strict = false) - { - $this->strict = $strict; - $this->subset = $subset; - } - - /** - * Evaluates the constraint for parameter $other. - * - * If $returnResult is set to false (the default), an exception is thrown - * in case of a failure. null is returned otherwise. - * - * If $returnResult is true, the result of the evaluation is returned as - * a boolean value instead: true in case of success, false in case of a - * failure. - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws ExpectationFailedException - */ - public function evaluate($other, string $description = '', bool $returnResult = false) - { - //type cast $other & $this->subset as an array to allow - //support in standard array functions. - $other = $this->toArray($other); - $this->subset = $this->toArray($this->subset); - - $patched = array_replace_recursive($other, $this->subset); - - if ($this->strict) { - $result = $other === $patched; - } else { - $result = $other == $patched; - } - - if ($returnResult) { - return $result; - } - - if (!$result) { - $f = new ComparisonFailure( - $patched, - $other, - var_export($patched, true), - var_export($other, true) - ); - - $this->fail($other, $description, $f); - } - } - - /** - * Returns a string representation of the constraint. - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - */ - public function toString(): string - { - return 'has the subset ' . $this->exporter()->export($this->subset); - } - - /** - * Returns the description of the failure. - * - * The beginning of failure messages is "Failed asserting that" in most - * cases. This method should return the second part of that sentence. - * - * @param mixed $other evaluated value or object - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - */ - protected function failureDescription($other): string - { - return 'an array ' . $this->toString(); - } - - private function toArray(iterable $other): array - { - if (is_array($other)) { - return $other; - } - - if ($other instanceof ArrayObject) { - return $other->getArrayCopy(); - } - - if ($other instanceof Traversable) { - return iterator_to_array($other); - } - - // Keep BC even if we know that array would not be the expected one - return (array) $other; - } -} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Attribute.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Attribute.php deleted file mode 100644 index ad4e2f984..000000000 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Attribute.php +++ /dev/null @@ -1,79 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace PHPUnit\Framework\Constraint; - -use PHPUnit\Framework\Assert; -use PHPUnit\Framework\ExpectationFailedException; - -/** - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ -final class Attribute extends Composite -{ - /** - * @var string - */ - private $attributeName; - - public function __construct(Constraint $constraint, string $attributeName) - { - parent::__construct($constraint); - - $this->attributeName = $attributeName; - } - - /** - * Evaluates the constraint for parameter $other. - * - * If $returnResult is set to false (the default), an exception is thrown - * in case of a failure. null is returned otherwise. - * - * If $returnResult is true, the result of the evaluation is returned as - * a boolean value instead: true in case of success, false in case of a - * failure. - * - * @throws \PHPUnit\Framework\Exception - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws ExpectationFailedException - */ - public function evaluate($other, string $description = '', bool $returnResult = false) - { - return parent::evaluate( - Assert::readAttribute( - $other, - $this->attributeName - ), - $description, - $returnResult - ); - } - - /** - * Returns a string representation of the constraint. - */ - public function toString(): string - { - return 'attribute "' . $this->attributeName . '" ' . $this->innerConstraint()->toString(); - } - - /** - * Returns the description of the failure. - * - * The beginning of failure messages is "Failed asserting that" in most - * cases. This method should return the second part of that sentence. - * - * @param mixed $other evaluated value or object - */ - protected function failureDescription($other): string - { - return $this->toString(); - } -} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/IsFalse.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Boolean/IsFalse.php similarity index 88% rename from vendor/phpunit/phpunit/src/Framework/Constraint/IsFalse.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Boolean/IsFalse.php index 8b11e0ac5..212e2bcb4 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/IsFalse.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Boolean/IsFalse.php @@ -10,7 +10,7 @@ namespace PHPUnit\Framework\Constraint; /** - * Constraint that accepts false. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class IsFalse extends Constraint { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/IsTrue.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Boolean/IsTrue.php similarity index 88% rename from vendor/phpunit/phpunit/src/Framework/Constraint/IsTrue.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Boolean/IsTrue.php index 7948c8fa0..e1d6b2691 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/IsTrue.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Boolean/IsTrue.php @@ -10,7 +10,7 @@ namespace PHPUnit\Framework\Constraint; /** - * Constraint that accepts true. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class IsTrue extends Constraint { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Callback.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Callback.php index 7a619b611..b7cf95a12 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Callback.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Callback.php @@ -10,9 +10,9 @@ namespace PHPUnit\Framework\Constraint; /** - * Constraint that evaluates against a specified closure. - * * @psalm-template CallbackInput of mixed + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class Callback extends Constraint { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Count.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/Count.php similarity index 84% rename from vendor/phpunit/phpunit/src/Framework/Constraint/Count.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/Count.php index 944d90800..8e27fbfd4 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Count.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/Count.php @@ -18,8 +18,12 @@ use EmptyIterator; use Generator; use Iterator; use IteratorAggregate; +use PHPUnit\Framework\Exception; use Traversable; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ class Count extends Constraint { /** @@ -43,6 +47,8 @@ class Count extends Constraint /** * Evaluates the constraint for parameter $other. Returns true if the * constraint is met, false otherwise. + * + * @throws Exception */ protected function matches($other): bool { @@ -50,7 +56,7 @@ class Count extends Constraint } /** - * @param iterable $other + * @throws Exception */ protected function getCountOf($other): ?int { @@ -64,7 +70,15 @@ class Count extends Constraint if ($other instanceof Traversable) { while ($other instanceof IteratorAggregate) { - $other = $other->getIterator(); + try { + $other = $other->getIterator(); + } catch (\Exception $e) { + throw new Exception( + $e->getMessage(), + $e->getCode(), + $e + ); + } } $iterator = $other; @@ -121,7 +135,7 @@ class Count extends Constraint { return sprintf( 'actual size %d matches expected size %d', - $this->getCountOf($other), + (int) $this->getCountOf($other), $this->expectedCount ); } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/GreaterThan.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/GreaterThan.php similarity index 91% rename from vendor/phpunit/phpunit/src/Framework/Constraint/GreaterThan.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/GreaterThan.php index b007615ca..31df50201 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/GreaterThan.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/GreaterThan.php @@ -10,8 +10,7 @@ namespace PHPUnit\Framework\Constraint; /** - * Constraint that asserts that the value it is evaluated for is greater - * than a given value. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class GreaterThan extends Constraint { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/IsEmpty.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/IsEmpty.php similarity index 94% rename from vendor/phpunit/phpunit/src/Framework/Constraint/IsEmpty.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/IsEmpty.php index 555afa763..e6371d536 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/IsEmpty.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/IsEmpty.php @@ -17,7 +17,7 @@ use Countable; use EmptyIterator; /** - * Constraint that checks whether a variable is empty(). + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class IsEmpty extends Constraint { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/LessThan.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/LessThan.php similarity index 91% rename from vendor/phpunit/phpunit/src/Framework/Constraint/LessThan.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/LessThan.php index 781c81744..c7884ba1d 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/LessThan.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/LessThan.php @@ -10,8 +10,7 @@ namespace PHPUnit\Framework\Constraint; /** - * Constraint that asserts that the value it is evaluated for is less than - * a given value. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class LessThan extends Constraint { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/SameSize.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/SameSize.php similarity index 69% rename from vendor/phpunit/phpunit/src/Framework/Constraint/SameSize.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/SameSize.php index c6b8703a4..a54679425 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/SameSize.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/SameSize.php @@ -9,10 +9,13 @@ */ namespace PHPUnit\Framework\Constraint; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ final class SameSize extends Count { public function __construct(iterable $expected) { - parent::__construct($this->getCountOf($expected)); + parent::__construct((int) $this->getCountOf($expected)); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Composite.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Composite.php deleted file mode 100644 index c9074ead6..000000000 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Composite.php +++ /dev/null @@ -1,69 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace PHPUnit\Framework\Constraint; - -use function count; -use PHPUnit\Framework\ExpectationFailedException; - -/** - * @deprecated https://github.com/sebastianbergmann/phpunit/issues/3338 - * @codeCoverageIgnore - */ -abstract class Composite extends Constraint -{ - /** - * @var Constraint - */ - private $innerConstraint; - - public function __construct(Constraint $innerConstraint) - { - $this->innerConstraint = $innerConstraint; - } - - /** - * Evaluates the constraint for parameter $other. - * - * If $returnResult is set to false (the default), an exception is thrown - * in case of a failure. null is returned otherwise. - * - * If $returnResult is true, the result of the evaluation is returned as - * a boolean value instead: true in case of success, false in case of a - * failure. - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws ExpectationFailedException - */ - public function evaluate($other, string $description = '', bool $returnResult = false) - { - try { - return $this->innerConstraint->evaluate( - $other, - $description, - $returnResult - ); - } catch (ExpectationFailedException $e) { - $this->fail($other, $description, $e->getComparisonFailure()); - } - } - - /** - * Counts the number of constraint elements. - */ - public function count(): int - { - return count($this->innerConstraint); - } - - protected function innerConstraint(): Constraint - { - return $this->innerConstraint; - } -} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Constraint.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Constraint.php index 52972b132..c012d6275 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Constraint.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Constraint.php @@ -17,12 +17,12 @@ use SebastianBergmann\Comparator\ComparisonFailure; use SebastianBergmann\Exporter\Exporter; /** - * Abstract base class for constraints which can be applied to any value. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ abstract class Constraint implements Countable, SelfDescribing { /** - * @var Exporter + * @var ?Exporter */ private $exporter; @@ -39,7 +39,7 @@ abstract class Constraint implements Countable, SelfDescribing * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException */ - public function evaluate($other, string $description = '', bool $returnResult = false) + public function evaluate($other, string $description = '', bool $returnResult = false): ?bool { $success = false; @@ -54,6 +54,8 @@ abstract class Constraint implements Countable, SelfDescribing if (!$success) { $this->fail($other, $description); } + + return null; } /** @@ -152,4 +154,116 @@ abstract class Constraint implements Countable, SelfDescribing { return $this->exporter()->export($other) . ' ' . $this->toString(); } + + /** + * Returns a custom string representation of the constraint object when it + * appears in context of an $operator expression. + * + * The purpose of this method is to provide meaningful descriptive string + * in context of operators such as LogicalNot. Native PHPUnit constraints + * are supported out of the box by LogicalNot, but externally developed + * ones had no way to provide correct strings in this context. + * + * The method shall return empty string, when it does not handle + * customization by itself. + * + * @param Operator $operator the $operator of the expression + * @param mixed $role role of $this constraint in the $operator expression + */ + protected function toStringInContext(Operator $operator, $role): string + { + return ''; + } + + /** + * Returns the description of the failure when this constraint appears in + * context of an $operator expression. + * + * The purpose of this method is to provide meaningful failue description + * in context of operators such as LogicalNot. Native PHPUnit constraints + * are supported out of the box by LogicalNot, but externally developed + * ones had no way to provide correct messages in this context. + * + * The method shall return empty string, when it does not handle + * customization by itself. + * + * @param Operator $operator the $operator of the expression + * @param mixed $role role of $this constraint in the $operator expression + * @param mixed $other evaluated value or object + */ + protected function failureDescriptionInContext(Operator $operator, $role, $other): string + { + $string = $this->toStringInContext($operator, $role); + + if ($string === '') { + return ''; + } + + return $this->exporter()->export($other) . ' ' . $string; + } + + /** + * Reduces the sub-expression starting at $this by skipping degenerate + * sub-expression and returns first descendant constraint that starts + * a non-reducible sub-expression. + * + * Returns $this for terminal constraints and for operators that start + * non-reducible sub-expression, or the nearest descendant of $this that + * starts a non-reducible sub-expression. + * + * A constraint expression may be modelled as a tree with non-terminal + * nodes (operators) and terminal nodes. For example: + * + * LogicalOr (operator, non-terminal) + * + LogicalAnd (operator, non-terminal) + * | + IsType('int') (terminal) + * | + GreaterThan(10) (terminal) + * + LogicalNot (operator, non-terminal) + * + IsType('array') (terminal) + * + * A degenerate sub-expression is a part of the tree, that effectively does + * not contribute to the evaluation of the expression it appears in. An example + * of degenerate sub-expression is a BinaryOperator constructed with single + * operand or nested BinaryOperators, each with single operand. An + * expression involving a degenerate sub-expression is equivalent to a + * reduced expression with the degenerate sub-expression removed, for example + * + * LogicalAnd (operator) + * + LogicalOr (degenerate operator) + * | + LogicalAnd (degenerate operator) + * | + IsType('int') (terminal) + * + GreaterThan(10) (terminal) + * + * is equivalent to + * + * LogicalAnd (operator) + * + IsType('int') (terminal) + * + GreaterThan(10) (terminal) + * + * because the subexpression + * + * + LogicalOr + * + LogicalAnd + * + - + * + * is degenerate. Calling reduce() on the LogicalOr object above, as well + * as on LogicalAnd, shall return the IsType('int') instance. + * + * Other specific reductions can be implemented, for example cascade of + * LogicalNot operators + * + * + LogicalNot + * + LogicalNot + * +LogicalNot + * + IsTrue + * + * can be reduced to + * + * LogicalNot + * + IsTrue + */ + protected function reduce(): self + { + return $this; + } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/IsEqual.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqual.php similarity index 86% rename from vendor/phpunit/phpunit/src/Framework/Constraint/IsEqual.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqual.php index bf90a7838..6a61ebfba 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/IsEqual.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqual.php @@ -18,13 +18,7 @@ use SebastianBergmann\Comparator\ComparisonFailure; use SebastianBergmann\Comparator\Factory as ComparatorFactory; /** - * Constraint that checks if one value is equal to another. - * - * Equality is checked with PHP's == operator, the operator is explained in - * detail at {@url https://php.net/manual/en/types.comparisons.php}. - * Two values are equal if they have the same value disregarding type. - * - * The expected value is passed in the constructor. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class IsEqual extends Constraint { @@ -48,7 +42,7 @@ final class IsEqual extends Constraint */ private $ignoreCase; - public function __construct($value, float $delta = 0.0, int $maxDepth = 10, bool $canonicalize = false, bool $ignoreCase = false) + public function __construct($value, float $delta = 0.0, bool $canonicalize = false, bool $ignoreCase = false) { $this->value = $value; $this->delta = $delta; @@ -67,8 +61,10 @@ final class IsEqual extends Constraint * failure. * * @throws ExpectationFailedException + * + * @return bool */ - public function evaluate($other, string $description = '', bool $returnResult = false) + public function evaluate($other, string $description = '', bool $returnResult = false): ?bool { // If $this->value and $other are identical, they are also equal. // This is the most common path and will allow us to skip diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualCanonicalizing.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualCanonicalizing.php new file mode 100644 index 000000000..57bb91ca1 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualCanonicalizing.php @@ -0,0 +1,108 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\Constraint; + +use function is_string; +use function sprintf; +use function strpos; +use function trim; +use PHPUnit\Framework\ExpectationFailedException; +use SebastianBergmann\Comparator\ComparisonFailure; +use SebastianBergmann\Comparator\Factory as ComparatorFactory; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class IsEqualCanonicalizing extends Constraint +{ + /** + * @var mixed + */ + private $value; + + public function __construct($value) + { + $this->value = $value; + } + + /** + * Evaluates the constraint for parameter $other. + * + * If $returnResult is set to false (the default), an exception is thrown + * in case of a failure. null is returned otherwise. + * + * If $returnResult is true, the result of the evaluation is returned as + * a boolean value instead: true in case of success, false in case of a + * failure. + * + * @throws ExpectationFailedException + */ + public function evaluate($other, string $description = '', bool $returnResult = false): ?bool + { + // If $this->value and $other are identical, they are also equal. + // This is the most common path and will allow us to skip + // initialization of all the comparators. + if ($this->value === $other) { + return true; + } + + $comparatorFactory = ComparatorFactory::getInstance(); + + try { + $comparator = $comparatorFactory->getComparatorFor( + $this->value, + $other + ); + + $comparator->assertEquals( + $this->value, + $other, + 0.0, + true, + false + ); + } catch (ComparisonFailure $f) { + if ($returnResult) { + return false; + } + + throw new ExpectationFailedException( + trim($description . "\n" . $f->getMessage()), + $f + ); + } + + return true; + } + + /** + * Returns a string representation of the constraint. + * + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + */ + public function toString(): string + { + if (is_string($this->value)) { + if (strpos($this->value, "\n") !== false) { + return 'is equal to '; + } + + return sprintf( + "is equal to '%s'", + $this->value + ); + } + + return sprintf( + 'is equal to %s', + $this->exporter()->export($this->value) + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualIgnoringCase.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualIgnoringCase.php new file mode 100644 index 000000000..d657e96a2 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualIgnoringCase.php @@ -0,0 +1,108 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\Constraint; + +use function is_string; +use function sprintf; +use function strpos; +use function trim; +use PHPUnit\Framework\ExpectationFailedException; +use SebastianBergmann\Comparator\ComparisonFailure; +use SebastianBergmann\Comparator\Factory as ComparatorFactory; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class IsEqualIgnoringCase extends Constraint +{ + /** + * @var mixed + */ + private $value; + + public function __construct($value) + { + $this->value = $value; + } + + /** + * Evaluates the constraint for parameter $other. + * + * If $returnResult is set to false (the default), an exception is thrown + * in case of a failure. null is returned otherwise. + * + * If $returnResult is true, the result of the evaluation is returned as + * a boolean value instead: true in case of success, false in case of a + * failure. + * + * @throws ExpectationFailedException + */ + public function evaluate($other, string $description = '', bool $returnResult = false): ?bool + { + // If $this->value and $other are identical, they are also equal. + // This is the most common path and will allow us to skip + // initialization of all the comparators. + if ($this->value === $other) { + return true; + } + + $comparatorFactory = ComparatorFactory::getInstance(); + + try { + $comparator = $comparatorFactory->getComparatorFor( + $this->value, + $other + ); + + $comparator->assertEquals( + $this->value, + $other, + 0.0, + false, + true + ); + } catch (ComparisonFailure $f) { + if ($returnResult) { + return false; + } + + throw new ExpectationFailedException( + trim($description . "\n" . $f->getMessage()), + $f + ); + } + + return true; + } + + /** + * Returns a string representation of the constraint. + * + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + */ + public function toString(): string + { + if (is_string($this->value)) { + if (strpos($this->value, "\n") !== false) { + return 'is equal to '; + } + + return sprintf( + "is equal to '%s'", + $this->value + ); + } + + return sprintf( + 'is equal to %s', + $this->exporter()->export($this->value) + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualWithDelta.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualWithDelta.php new file mode 100644 index 000000000..0370b5118 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualWithDelta.php @@ -0,0 +1,100 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\Constraint; + +use function sprintf; +use function trim; +use PHPUnit\Framework\ExpectationFailedException; +use SebastianBergmann\Comparator\ComparisonFailure; +use SebastianBergmann\Comparator\Factory as ComparatorFactory; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class IsEqualWithDelta extends Constraint +{ + /** + * @var mixed + */ + private $value; + + /** + * @var float + */ + private $delta; + + public function __construct($value, float $delta) + { + $this->value = $value; + $this->delta = $delta; + } + + /** + * Evaluates the constraint for parameter $other. + * + * If $returnResult is set to false (the default), an exception is thrown + * in case of a failure. null is returned otherwise. + * + * If $returnResult is true, the result of the evaluation is returned as + * a boolean value instead: true in case of success, false in case of a + * failure. + * + * @throws ExpectationFailedException + */ + public function evaluate($other, string $description = '', bool $returnResult = false): ?bool + { + // If $this->value and $other are identical, they are also equal. + // This is the most common path and will allow us to skip + // initialization of all the comparators. + if ($this->value === $other) { + return true; + } + + $comparatorFactory = ComparatorFactory::getInstance(); + + try { + $comparator = $comparatorFactory->getComparatorFor( + $this->value, + $other + ); + + $comparator->assertEquals( + $this->value, + $other, + $this->delta + ); + } catch (ComparisonFailure $f) { + if ($returnResult) { + return false; + } + + throw new ExpectationFailedException( + trim($description . "\n" . $f->getMessage()), + $f + ); + } + + return true; + } + + /** + * Returns a string representation of the constraint. + * + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + */ + public function toString(): string + { + return sprintf( + 'is equal to %s with delta <%F>>', + $this->exporter()->export($this->value), + $this->delta + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Exception.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Exception/Exception.php similarity index 94% rename from vendor/phpunit/phpunit/src/Framework/Constraint/Exception.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Exception/Exception.php index 5119071e0..860c0030f 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Exception.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Exception/Exception.php @@ -14,6 +14,9 @@ use function sprintf; use PHPUnit\Util\Filter; use Throwable; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ final class Exception extends Constraint { /** diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/ExceptionCode.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionCode.php similarity index 93% rename from vendor/phpunit/phpunit/src/Framework/Constraint/ExceptionCode.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionCode.php index 682f48cb3..b8054a949 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/ExceptionCode.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionCode.php @@ -12,6 +12,9 @@ namespace PHPUnit\Framework\Constraint; use function sprintf; use Throwable; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ final class ExceptionCode extends Constraint { /** diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/ExceptionMessage.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionMessage.php similarity index 94% rename from vendor/phpunit/phpunit/src/Framework/Constraint/ExceptionMessage.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionMessage.php index 4836b1505..030beff98 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/ExceptionMessage.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionMessage.php @@ -13,6 +13,9 @@ use function sprintf; use function strpos; use Throwable; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ final class ExceptionMessage extends Constraint { /** diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/ExceptionMessageRegularExpression.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionMessageRegularExpression.php similarity index 94% rename from vendor/phpunit/phpunit/src/Framework/Constraint/ExceptionMessageRegularExpression.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionMessageRegularExpression.php index 1b03482f7..fd0db1c8f 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/ExceptionMessageRegularExpression.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionMessageRegularExpression.php @@ -13,6 +13,9 @@ use function sprintf; use Exception; use PHPUnit\Util\RegularExpression as RegularExpressionUtil; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ final class ExceptionMessageRegularExpression extends Constraint { /** diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/DirectoryExists.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/DirectoryExists.php similarity index 89% rename from vendor/phpunit/phpunit/src/Framework/Constraint/DirectoryExists.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/DirectoryExists.php index ecdad816f..ef4b2baf0 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/DirectoryExists.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/DirectoryExists.php @@ -13,9 +13,7 @@ use function is_dir; use function sprintf; /** - * Constraint that checks if the directory(name) that it is evaluated for exists. - * - * The file path to check is passed as $other in evaluate(). + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class DirectoryExists extends Constraint { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/FileExists.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/FileExists.php similarity index 90% rename from vendor/phpunit/phpunit/src/Framework/Constraint/FileExists.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/FileExists.php index 8637359a5..41b3136e9 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/FileExists.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/FileExists.php @@ -13,9 +13,7 @@ use function file_exists; use function sprintf; /** - * Constraint that checks if the file(name) that it is evaluated for exists. - * - * The file path to check is passed as $other in evaluate(). + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class FileExists extends Constraint { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/IsReadable.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/IsReadable.php similarity index 89% rename from vendor/phpunit/phpunit/src/Framework/Constraint/IsReadable.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/IsReadable.php index bcf8274e8..e33d7e045 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/IsReadable.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/IsReadable.php @@ -13,9 +13,7 @@ use function is_readable; use function sprintf; /** - * Constraint that checks if the file/dir(name) that it is evaluated for is readable. - * - * The file path to check is passed as $other in evaluate(). + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class IsReadable extends Constraint { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/IsWritable.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/IsWritable.php similarity index 89% rename from vendor/phpunit/phpunit/src/Framework/Constraint/IsWritable.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/IsWritable.php index 8dd86b562..93981224a 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/IsWritable.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/IsWritable.php @@ -13,9 +13,7 @@ use function is_writable; use function sprintf; /** - * Constraint that checks if the file/dir(name) that it is evaluated for is writable. - * - * The file path to check is passed as $other in evaluate(). + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class IsWritable extends Constraint { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/IsAnything.php b/vendor/phpunit/phpunit/src/Framework/Constraint/IsAnything.php index 0407ef1e2..db84a7431 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/IsAnything.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/IsAnything.php @@ -12,7 +12,7 @@ namespace PHPUnit\Framework\Constraint; use PHPUnit\Framework\ExpectationFailedException; /** - * Constraint that accepts any input value. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class IsAnything extends Constraint { @@ -28,7 +28,7 @@ final class IsAnything extends Constraint * * @throws ExpectationFailedException */ - public function evaluate($other, string $description = '', bool $returnResult = false) + public function evaluate($other, string $description = '', bool $returnResult = false): ?bool { return $returnResult ? true : null; } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/IsIdentical.php b/vendor/phpunit/phpunit/src/Framework/Constraint/IsIdentical.php index ed0d6f4c6..b49d99293 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/IsIdentical.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/IsIdentical.php @@ -22,15 +22,7 @@ use PHPUnit\Framework\ExpectationFailedException; use SebastianBergmann\Comparator\ComparisonFailure; /** - * Constraint that asserts that one value is identical to another. - * - * Identical check is performed with PHP's === operator, the operator is - * explained in detail at - * {@url https://php.net/manual/en/types.comparisons.php}. - * Two values are identical if they have the same value and are of the same - * type. - * - * The expected value is passed in the constructor. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class IsIdentical extends Constraint { @@ -62,7 +54,7 @@ final class IsIdentical extends Constraint * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException */ - public function evaluate($other, string $description = '', bool $returnResult = false) + public function evaluate($other, string $description = '', bool $returnResult = false): ?bool { if (is_float($this->value) && is_float($other) && !is_infinite($this->value) && !is_infinite($other) && @@ -101,6 +93,8 @@ final class IsIdentical extends Constraint $this->fail($other, $description, $f); } + + return null; } /** diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/JsonMatches.php b/vendor/phpunit/phpunit/src/Framework/Constraint/JsonMatches.php index 818a0ee3a..23a4de7e9 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/JsonMatches.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/JsonMatches.php @@ -16,7 +16,7 @@ use PHPUnit\Util\Json; use SebastianBergmann\Comparator\ComparisonFailure; /** - * Asserts whether or not two JSON objects are equal. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class JsonMatches extends Constraint { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/JsonMatchesErrorMessageProvider.php b/vendor/phpunit/phpunit/src/Framework/Constraint/JsonMatchesErrorMessageProvider.php index 2d28c2761..8ded556ce 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/JsonMatchesErrorMessageProvider.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/JsonMatchesErrorMessageProvider.php @@ -18,7 +18,7 @@ use const JSON_ERROR_UTF8; use function strtolower; /** - * Provides human readable messages for each JSON error. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class JsonMatchesErrorMessageProvider { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/LogicalAnd.php b/vendor/phpunit/phpunit/src/Framework/Constraint/LogicalAnd.php deleted file mode 100644 index 6714bf694..000000000 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/LogicalAnd.php +++ /dev/null @@ -1,121 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace PHPUnit\Framework\Constraint; - -use function array_values; -use function count; -use PHPUnit\Framework\ExpectationFailedException; - -/** - * Logical AND. - */ -final class LogicalAnd extends Constraint -{ - /** - * @var Constraint[] - */ - private $constraints = []; - - public static function fromConstraints(Constraint ...$constraints): self - { - $constraint = new self; - - $constraint->constraints = array_values($constraints); - - return $constraint; - } - - /** - * @param Constraint[] $constraints - * - * @throws \PHPUnit\Framework\Exception - */ - public function setConstraints(array $constraints): void - { - $this->constraints = []; - - foreach ($constraints as $constraint) { - if (!($constraint instanceof Constraint)) { - throw new \PHPUnit\Framework\Exception( - 'All parameters to ' . __CLASS__ . - ' must be a constraint object.' - ); - } - - $this->constraints[] = $constraint; - } - } - - /** - * Evaluates the constraint for parameter $other. - * - * If $returnResult is set to false (the default), an exception is thrown - * in case of a failure. null is returned otherwise. - * - * If $returnResult is true, the result of the evaluation is returned as - * a boolean value instead: true in case of success, false in case of a - * failure. - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws ExpectationFailedException - */ - public function evaluate($other, string $description = '', bool $returnResult = false) - { - $success = true; - - foreach ($this->constraints as $constraint) { - if (!$constraint->evaluate($other, $description, true)) { - $success = false; - - break; - } - } - - if ($returnResult) { - return $success; - } - - if (!$success) { - $this->fail($other, $description); - } - } - - /** - * Returns a string representation of the constraint. - */ - public function toString(): string - { - $text = ''; - - foreach ($this->constraints as $key => $constraint) { - if ($key > 0) { - $text .= ' and '; - } - - $text .= $constraint->toString(); - } - - return $text; - } - - /** - * Counts the number of constraint elements. - */ - public function count(): int - { - $count = 0; - - foreach ($this->constraints as $constraint) { - $count += count($constraint); - } - - return $count; - } -} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/LogicalNot.php b/vendor/phpunit/phpunit/src/Framework/Constraint/LogicalNot.php deleted file mode 100644 index e37b4a17f..000000000 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/LogicalNot.php +++ /dev/null @@ -1,169 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace PHPUnit\Framework\Constraint; - -use function count; -use function get_class; -use function preg_match; -use function str_replace; -use PHPUnit\Framework\ExpectationFailedException; - -/** - * Logical NOT. - */ -final class LogicalNot extends Constraint -{ - /** - * @var Constraint - */ - private $constraint; - - public static function negate(string $string): string - { - $positives = [ - 'contains ', - 'exists', - 'has ', - 'is ', - 'are ', - 'matches ', - 'starts with ', - 'ends with ', - 'reference ', - 'not not ', - ]; - - $negatives = [ - 'does not contain ', - 'does not exist', - 'does not have ', - 'is not ', - 'are not ', - 'does not match ', - 'starts not with ', - 'ends not with ', - 'don\'t reference ', - 'not ', - ]; - - preg_match('/(\'[\w\W]*\')([\w\W]*)("[\w\W]*")/i', $string, $matches); - - if (count($matches) > 0) { - $nonInput = $matches[2]; - - $negatedString = str_replace( - $nonInput, - str_replace( - $positives, - $negatives, - $nonInput - ), - $string - ); - } else { - $negatedString = str_replace( - $positives, - $negatives, - $string - ); - } - - return $negatedString; - } - - /** - * @param Constraint|mixed $constraint - */ - public function __construct($constraint) - { - if (!($constraint instanceof Constraint)) { - $constraint = new IsEqual($constraint); - } - - $this->constraint = $constraint; - } - - /** - * Evaluates the constraint for parameter $other. - * - * If $returnResult is set to false (the default), an exception is thrown - * in case of a failure. null is returned otherwise. - * - * If $returnResult is true, the result of the evaluation is returned as - * a boolean value instead: true in case of success, false in case of a - * failure. - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws ExpectationFailedException - */ - public function evaluate($other, string $description = '', bool $returnResult = false) - { - $success = !$this->constraint->evaluate($other, $description, true); - - if ($returnResult) { - return $success; - } - - if (!$success) { - $this->fail($other, $description); - } - } - - /** - * Returns a string representation of the constraint. - */ - public function toString(): string - { - switch (get_class($this->constraint)) { - case LogicalAnd::class: - case self::class: - case LogicalOr::class: - return 'not( ' . $this->constraint->toString() . ' )'; - - default: - return self::negate( - $this->constraint->toString() - ); - } - } - - /** - * Counts the number of constraint elements. - */ - public function count(): int - { - return count($this->constraint); - } - - /** - * Returns the description of the failure. - * - * The beginning of failure messages is "Failed asserting that" in most - * cases. This method should return the second part of that sentence. - * - * @param mixed $other evaluated value or object - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - */ - protected function failureDescription($other): string - { - switch (get_class($this->constraint)) { - case LogicalAnd::class: - case self::class: - case LogicalOr::class: - return 'not( ' . $this->constraint->failureDescription($other) . ' )'; - - default: - return self::negate( - $this->constraint->failureDescription($other) - ); - } - } -} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/LogicalOr.php b/vendor/phpunit/phpunit/src/Framework/Constraint/LogicalOr.php deleted file mode 100644 index 98bd86648..000000000 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/LogicalOr.php +++ /dev/null @@ -1,118 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace PHPUnit\Framework\Constraint; - -use function array_values; -use function count; -use PHPUnit\Framework\ExpectationFailedException; - -/** - * Logical OR. - */ -final class LogicalOr extends Constraint -{ - /** - * @var Constraint[] - */ - private $constraints = []; - - public static function fromConstraints(Constraint ...$constraints): self - { - $constraint = new self; - - $constraint->constraints = array_values($constraints); - - return $constraint; - } - - /** - * @param Constraint[] $constraints - */ - public function setConstraints(array $constraints): void - { - $this->constraints = []; - - foreach ($constraints as $constraint) { - if (!($constraint instanceof Constraint)) { - $constraint = new IsEqual( - $constraint - ); - } - - $this->constraints[] = $constraint; - } - } - - /** - * Evaluates the constraint for parameter $other. - * - * If $returnResult is set to false (the default), an exception is thrown - * in case of a failure. null is returned otherwise. - * - * If $returnResult is true, the result of the evaluation is returned as - * a boolean value instead: true in case of success, false in case of a - * failure. - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws ExpectationFailedException - */ - public function evaluate($other, string $description = '', bool $returnResult = false) - { - $success = false; - - foreach ($this->constraints as $constraint) { - if ($constraint->evaluate($other, $description, true)) { - $success = true; - - break; - } - } - - if ($returnResult) { - return $success; - } - - if (!$success) { - $this->fail($other, $description); - } - } - - /** - * Returns a string representation of the constraint. - */ - public function toString(): string - { - $text = ''; - - foreach ($this->constraints as $key => $constraint) { - if ($key > 0) { - $text .= ' or '; - } - - $text .= $constraint->toString(); - } - - return $text; - } - - /** - * Counts the number of constraint elements. - */ - public function count(): int - { - $count = 0; - - foreach ($this->constraints as $constraint) { - $count += count($constraint); - } - - return $count; - } -} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/LogicalXor.php b/vendor/phpunit/phpunit/src/Framework/Constraint/LogicalXor.php deleted file mode 100644 index 12cfff877..000000000 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/LogicalXor.php +++ /dev/null @@ -1,123 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace PHPUnit\Framework\Constraint; - -use function array_values; -use function count; -use PHPUnit\Framework\ExpectationFailedException; - -/** - * Logical XOR. - */ -final class LogicalXor extends Constraint -{ - /** - * @var Constraint[] - */ - private $constraints = []; - - public static function fromConstraints(Constraint ...$constraints): self - { - $constraint = new self; - - $constraint->constraints = array_values($constraints); - - return $constraint; - } - - /** - * @param Constraint[] $constraints - */ - public function setConstraints(array $constraints): void - { - $this->constraints = []; - - foreach ($constraints as $constraint) { - if (!($constraint instanceof Constraint)) { - $constraint = new IsEqual( - $constraint - ); - } - - $this->constraints[] = $constraint; - } - } - - /** - * Evaluates the constraint for parameter $other. - * - * If $returnResult is set to false (the default), an exception is thrown - * in case of a failure. null is returned otherwise. - * - * If $returnResult is true, the result of the evaluation is returned as - * a boolean value instead: true in case of success, false in case of a - * failure. - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - * @throws ExpectationFailedException - */ - public function evaluate($other, string $description = '', bool $returnResult = false) - { - $success = true; - $lastResult = null; - - foreach ($this->constraints as $constraint) { - $result = $constraint->evaluate($other, $description, true); - - if ($result === $lastResult) { - $success = false; - - break; - } - - $lastResult = $result; - } - - if ($returnResult) { - return $success; - } - - if (!$success) { - $this->fail($other, $description); - } - } - - /** - * Returns a string representation of the constraint. - */ - public function toString(): string - { - $text = ''; - - foreach ($this->constraints as $key => $constraint) { - if ($key > 0) { - $text .= ' xor '; - } - - $text .= $constraint->toString(); - } - - return $text; - } - - /** - * Counts the number of constraint elements. - */ - public function count(): int - { - $count = 0; - - foreach ($this->constraints as $constraint) { - $count += count($constraint); - } - - return $count; - } -} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/IsFinite.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Math/IsFinite.php similarity index 88% rename from vendor/phpunit/phpunit/src/Framework/Constraint/IsFinite.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Math/IsFinite.php index ed727d597..9a2f32866 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/IsFinite.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Math/IsFinite.php @@ -12,7 +12,7 @@ namespace PHPUnit\Framework\Constraint; use function is_finite; /** - * Constraint that accepts finite. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class IsFinite extends Constraint { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/IsInfinite.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Math/IsInfinite.php similarity index 88% rename from vendor/phpunit/phpunit/src/Framework/Constraint/IsInfinite.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Math/IsInfinite.php index 0ada7f1bd..c718514c2 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/IsInfinite.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Math/IsInfinite.php @@ -12,7 +12,7 @@ namespace PHPUnit\Framework\Constraint; use function is_infinite; /** - * Constraint that accepts infinite. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class IsInfinite extends Constraint { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/IsNan.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Math/IsNan.php similarity index 88% rename from vendor/phpunit/phpunit/src/Framework/Constraint/IsNan.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Math/IsNan.php index 9dde4c6f4..0062c5b5c 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/IsNan.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Math/IsNan.php @@ -12,7 +12,7 @@ namespace PHPUnit\Framework\Constraint; use function is_nan; /** - * Constraint that accepts nan. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class IsNan extends Constraint { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/ClassHasAttribute.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Object/ClassHasAttribute.php similarity index 93% rename from vendor/phpunit/phpunit/src/Framework/Constraint/ClassHasAttribute.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Object/ClassHasAttribute.php index c42964cf5..daa14027d 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/ClassHasAttribute.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Object/ClassHasAttribute.php @@ -17,10 +17,7 @@ use ReflectionClass; use ReflectionException; /** - * Constraint that asserts that the class it is evaluated for has a given - * attribute. - * - * The attribute name is passed in the constructor. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ class ClassHasAttribute extends Constraint { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/ClassHasStaticAttribute.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Object/ClassHasStaticAttribute.php similarity index 90% rename from vendor/phpunit/phpunit/src/Framework/Constraint/ClassHasStaticAttribute.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Object/ClassHasStaticAttribute.php index 16e2917f6..cacd0d752 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/ClassHasStaticAttribute.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Object/ClassHasStaticAttribute.php @@ -15,10 +15,7 @@ use ReflectionClass; use ReflectionException; /** - * Constraint that asserts that the class it is evaluated for has a given - * static attribute. - * - * The attribute name is passed in the constructor. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class ClassHasStaticAttribute extends ClassHasAttribute { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Object/ObjectEquals.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Object/ObjectEquals.php new file mode 100644 index 000000000..30f3a330c --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Object/ObjectEquals.php @@ -0,0 +1,151 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\Constraint; + +use function get_class; +use function is_object; +use PHPUnit\Framework\ActualValueIsNotAnObjectException; +use PHPUnit\Framework\ComparisonMethodDoesNotAcceptParameterTypeException; +use PHPUnit\Framework\ComparisonMethodDoesNotDeclareBoolReturnTypeException; +use PHPUnit\Framework\ComparisonMethodDoesNotDeclareExactlyOneParameterException; +use PHPUnit\Framework\ComparisonMethodDoesNotDeclareParameterTypeException; +use PHPUnit\Framework\ComparisonMethodDoesNotExistException; +use ReflectionNamedType; +use ReflectionObject; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class ObjectEquals extends Constraint +{ + /** + * @var object + */ + private $expected; + + /** + * @var string + */ + private $method; + + public function __construct(object $object, string $method = 'equals') + { + $this->expected = $object; + $this->method = $method; + } + + public function toString(): string + { + return 'two objects are equal'; + } + + /** + * @throws ActualValueIsNotAnObjectException + * @throws ComparisonMethodDoesNotAcceptParameterTypeException + * @throws ComparisonMethodDoesNotDeclareBoolReturnTypeException + * @throws ComparisonMethodDoesNotDeclareExactlyOneParameterException + * @throws ComparisonMethodDoesNotDeclareParameterTypeException + * @throws ComparisonMethodDoesNotExistException + */ + protected function matches($other): bool + { + if (!is_object($other)) { + throw new ActualValueIsNotAnObjectException; + } + + $object = new ReflectionObject($other); + + if (!$object->hasMethod($this->method)) { + throw new ComparisonMethodDoesNotExistException( + get_class($other), + $this->method + ); + } + + /** @noinspection PhpUnhandledExceptionInspection */ + $method = $object->getMethod($this->method); + + if (!$method->hasReturnType()) { + throw new ComparisonMethodDoesNotDeclareBoolReturnTypeException( + get_class($other), + $this->method + ); + } + + $returnType = $method->getReturnType(); + + if (!$returnType instanceof ReflectionNamedType) { + throw new ComparisonMethodDoesNotDeclareBoolReturnTypeException( + get_class($other), + $this->method + ); + } + + if ($returnType->allowsNull()) { + throw new ComparisonMethodDoesNotDeclareBoolReturnTypeException( + get_class($other), + $this->method + ); + } + + if ($returnType->getName() !== 'bool') { + throw new ComparisonMethodDoesNotDeclareBoolReturnTypeException( + get_class($other), + $this->method + ); + } + + if ($method->getNumberOfParameters() !== 1 || $method->getNumberOfRequiredParameters() !== 1) { + throw new ComparisonMethodDoesNotDeclareExactlyOneParameterException( + get_class($other), + $this->method + ); + } + + $parameter = $method->getParameters()[0]; + + if (!$parameter->hasType()) { + throw new ComparisonMethodDoesNotDeclareParameterTypeException( + get_class($other), + $this->method + ); + } + + $type = $parameter->getType(); + + if (!$type instanceof ReflectionNamedType) { + throw new ComparisonMethodDoesNotDeclareParameterTypeException( + get_class($other), + $this->method + ); + } + + $typeName = $type->getName(); + + if ($typeName === 'self') { + $typeName = get_class($other); + } + + if (!$this->expected instanceof $typeName) { + throw new ComparisonMethodDoesNotAcceptParameterTypeException( + get_class($other), + $this->method, + get_class($this->expected) + ); + } + + return $other->{$this->method}($this->expected); + } + + protected function failureDescription($other): string + { + return $this->toString(); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/ObjectHasAttribute.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Object/ObjectHasAttribute.php similarity index 83% rename from vendor/phpunit/phpunit/src/Framework/Constraint/ObjectHasAttribute.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Object/ObjectHasAttribute.php index 8543c220f..5fbc0888c 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/ObjectHasAttribute.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Object/ObjectHasAttribute.php @@ -12,10 +12,7 @@ namespace PHPUnit\Framework\Constraint; use ReflectionObject; /** - * Constraint that asserts that the object it is evaluated for has a given - * attribute. - * - * The attribute name is passed in the constructor. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class ObjectHasAttribute extends ClassHasAttribute { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/BinaryOperator.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/BinaryOperator.php new file mode 100644 index 000000000..4588e7c07 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/BinaryOperator.php @@ -0,0 +1,147 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\Constraint; + +use function array_map; +use function array_values; +use function count; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +abstract class BinaryOperator extends Operator +{ + /** + * @var Constraint[] + */ + private $constraints = []; + + public static function fromConstraints(Constraint ...$constraints): self + { + $constraint = new static; + + $constraint->constraints = $constraints; + + return $constraint; + } + + /** + * @param mixed[] $constraints + */ + public function setConstraints(array $constraints): void + { + $this->constraints = array_map(function ($constraint): Constraint { + return $this->checkConstraint($constraint); + }, array_values($constraints)); + } + + /** + * Returns the number of operands (constraints). + */ + final public function arity(): int + { + return count($this->constraints); + } + + /** + * Returns a string representation of the constraint. + */ + public function toString(): string + { + $reduced = $this->reduce(); + + if ($reduced !== $this) { + return $reduced->toString(); + } + + $text = ''; + + foreach ($this->constraints as $key => $constraint) { + $constraint = $constraint->reduce(); + + $text .= $this->constraintToString($constraint, $key); + } + + return $text; + } + + /** + * Counts the number of constraint elements. + */ + public function count(): int + { + $count = 0; + + foreach ($this->constraints as $constraint) { + $count += count($constraint); + } + + return $count; + } + + /** + * Returns the nested constraints. + */ + final protected function constraints(): array + { + return $this->constraints; + } + + /** + * Returns true if the $constraint needs to be wrapped with braces. + */ + final protected function constraintNeedsParentheses(Constraint $constraint): bool + { + return $this->arity() > 1 && parent::constraintNeedsParentheses($constraint); + } + + /** + * Reduces the sub-expression starting at $this by skipping degenerate + * sub-expression and returns first descendant constraint that starts + * a non-reducible sub-expression. + * + * See Constraint::reduce() for more. + */ + protected function reduce(): Constraint + { + if ($this->arity() === 1 && $this->constraints[0] instanceof Operator) { + return $this->constraints[0]->reduce(); + } + + return parent::reduce(); + } + + /** + * Returns string representation of given operand in context of this operator. + * + * @param Constraint $constraint operand constraint + * @param int $position position of $constraint in this expression + */ + private function constraintToString(Constraint $constraint, int $position): string + { + $prefix = ''; + + if ($position > 0) { + $prefix = (' ' . $this->operator() . ' '); + } + + if ($this->constraintNeedsParentheses($constraint)) { + return $prefix . '( ' . $constraint->toString() . ' )'; + } + + $string = $constraint->toStringInContext($this, $position); + + if ($string === '') { + $string = $constraint->toString(); + } + + return $prefix . $string; + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalAnd.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalAnd.php new file mode 100644 index 000000000..a1af4dd32 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalAnd.php @@ -0,0 +1,51 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\Constraint; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class LogicalAnd extends BinaryOperator +{ + /** + * Returns the name of this operator. + */ + public function operator(): string + { + return 'and'; + } + + /** + * Returns this operator's precedence. + * + * @see https://www.php.net/manual/en/language.operators.precedence.php + */ + public function precedence(): int + { + return 22; + } + + /** + * Evaluates the constraint for parameter $other. Returns true if the + * constraint is met, false otherwise. + * + * @param mixed $other value or object to evaluate + */ + protected function matches($other): bool + { + foreach ($this->constraints() as $constraint) { + if (!$constraint->evaluate($other, '', true)) { + return false; + } + } + + return [] !== $this->constraints(); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalNot.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalNot.php new file mode 100644 index 000000000..a89d6780d --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalNot.php @@ -0,0 +1,135 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\Constraint; + +use function array_map; +use function count; +use function preg_match; +use function preg_quote; +use function preg_replace; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class LogicalNot extends UnaryOperator +{ + public static function negate(string $string): string + { + $positives = [ + 'contains ', + 'exists', + 'has ', + 'is ', + 'are ', + 'matches ', + 'starts with ', + 'ends with ', + 'reference ', + 'not not ', + ]; + + $negatives = [ + 'does not contain ', + 'does not exist', + 'does not have ', + 'is not ', + 'are not ', + 'does not match ', + 'starts not with ', + 'ends not with ', + 'don\'t reference ', + 'not ', + ]; + + preg_match('/(\'[\w\W]*\')([\w\W]*)("[\w\W]*")/i', $string, $matches); + + $positives = array_map(static function (string $s) { + return '/\\b' . preg_quote($s, '/') . '/'; + }, $positives); + + if (count($matches) > 0) { + $nonInput = $matches[2]; + + $negatedString = preg_replace( + '/' . preg_quote($nonInput, '/') . '/', + preg_replace( + $positives, + $negatives, + $nonInput + ), + $string + ); + } else { + $negatedString = preg_replace( + $positives, + $negatives, + $string + ); + } + + return $negatedString; + } + + /** + * Returns the name of this operator. + */ + public function operator(): string + { + return 'not'; + } + + /** + * Returns this operator's precedence. + * + * @see https://www.php.net/manual/en/language.operators.precedence.php + */ + public function precedence(): int + { + return 5; + } + + /** + * Evaluates the constraint for parameter $other. Returns true if the + * constraint is met, false otherwise. + * + * @param mixed $other value or object to evaluate + */ + protected function matches($other): bool + { + return !$this->constraint()->evaluate($other, '', true); + } + + /** + * Applies additional transformation to strings returned by toString() or + * failureDescription(). + */ + protected function transformString(string $string): string + { + return self::negate($string); + } + + /** + * Reduces the sub-expression starting at $this by skipping degenerate + * sub-expression and returns first descendant constraint that starts + * a non-reducible sub-expression. + * + * See Constraint::reduce() for more. + */ + protected function reduce(): Constraint + { + $constraint = $this->constraint(); + + if ($constraint instanceof self) { + return $constraint->constraint()->reduce(); + } + + return parent::reduce(); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalOr.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalOr.php new file mode 100644 index 000000000..2932de675 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalOr.php @@ -0,0 +1,51 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\Constraint; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class LogicalOr extends BinaryOperator +{ + /** + * Returns the name of this operator. + */ + public function operator(): string + { + return 'or'; + } + + /** + * Returns this operator's precedence. + * + * @see https://www.php.net/manual/en/language.operators.precedence.php + */ + public function precedence(): int + { + return 24; + } + + /** + * Evaluates the constraint for parameter $other. Returns true if the + * constraint is met, false otherwise. + * + * @param mixed $other value or object to evaluate + */ + public function matches($other): bool + { + foreach ($this->constraints() as $constraint) { + if ($constraint->evaluate($other, '', true)) { + return true; + } + } + + return false; + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalXor.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalXor.php new file mode 100644 index 000000000..157643f82 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalXor.php @@ -0,0 +1,62 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\Constraint; + +use function array_reduce; +use function array_shift; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class LogicalXor extends BinaryOperator +{ + /** + * Returns the name of this operator. + */ + public function operator(): string + { + return 'xor'; + } + + /** + * Returns this operator's precedence. + * + * @see https://www.php.net/manual/en/language.operators.precedence.php. + */ + public function precedence(): int + { + return 23; + } + + /** + * Evaluates the constraint for parameter $other. Returns true if the + * constraint is met, false otherwise. + * + * @param mixed $other value or object to evaluate + */ + public function matches($other): bool + { + $constraints = $this->constraints(); + + $initial = array_shift($constraints); + + if ($initial === null) { + return false; + } + + return array_reduce( + $constraints, + static function (bool $matches, Constraint $constraint) use ($other): bool { + return $matches xor $constraint->evaluate($other, '', true); + }, + $initial->evaluate($other, '', true) + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/Operator.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/Operator.php new file mode 100644 index 000000000..3f51a0f40 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/Operator.php @@ -0,0 +1,55 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\Constraint; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +abstract class Operator extends Constraint +{ + /** + * Returns the name of this operator. + */ + abstract public function operator(): string; + + /** + * Returns this operator's precedence. + * + * @see https://www.php.net/manual/en/language.operators.precedence.php + */ + abstract public function precedence(): int; + + /** + * Returns the number of operands. + */ + abstract public function arity(): int; + + /** + * Validates $constraint argument. + */ + protected function checkConstraint($constraint): Constraint + { + if (!$constraint instanceof Constraint) { + return new IsEqual($constraint); + } + + return $constraint; + } + + /** + * Returns true if the $constraint needs to be wrapped with braces. + */ + protected function constraintNeedsParentheses(Constraint $constraint): bool + { + return $constraint instanceof self && + $constraint->arity() > 1 && + $this->precedence() <= $constraint->precedence(); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/UnaryOperator.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/UnaryOperator.php new file mode 100644 index 000000000..0a7a5fa2f --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/UnaryOperator.php @@ -0,0 +1,140 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\Constraint; + +use function count; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +abstract class UnaryOperator extends Operator +{ + /** + * @var Constraint + */ + private $constraint; + + /** + * @param Constraint|mixed $constraint + */ + public function __construct($constraint) + { + $this->constraint = $this->checkConstraint($constraint); + } + + /** + * Returns the number of operands (constraints). + */ + public function arity(): int + { + return 1; + } + + /** + * Returns a string representation of the constraint. + */ + public function toString(): string + { + $reduced = $this->reduce(); + + if ($reduced !== $this) { + return $reduced->toString(); + } + + $constraint = $this->constraint->reduce(); + + if ($this->constraintNeedsParentheses($constraint)) { + return $this->operator() . '( ' . $constraint->toString() . ' )'; + } + + $string = $constraint->toStringInContext($this, 0); + + if ($string === '') { + return $this->transformString($constraint->toString()); + } + + return $string; + } + + /** + * Counts the number of constraint elements. + */ + public function count(): int + { + return count($this->constraint); + } + + /** + * Returns the description of the failure. + * + * The beginning of failure messages is "Failed asserting that" in most + * cases. This method should return the second part of that sentence. + * + * @param mixed $other evaluated value or object + * + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + */ + protected function failureDescription($other): string + { + $reduced = $this->reduce(); + + if ($reduced !== $this) { + return $reduced->failureDescription($other); + } + + $constraint = $this->constraint->reduce(); + + if ($this->constraintNeedsParentheses($constraint)) { + return $this->operator() . '( ' . $constraint->failureDescription($other) . ' )'; + } + + $string = $constraint->failureDescriptionInContext($this, 0, $other); + + if ($string === '') { + return $this->transformString($constraint->failureDescription($other)); + } + + return $string; + } + + /** + * Transforms string returned by the memeber constraint's toString() or + * failureDescription() such that it reflects constraint's participation in + * this expression. + * + * The method may be overwritten in a subclass to apply default + * transformation in case the operand constraint does not provide its own + * custom strings via toStringInContext() or failureDescriptionInContext(). + * + * @param string $string the string to be transformed + */ + protected function transformString(string $string): string + { + return $string; + } + + /** + * Provides access to $this->constraint for subclasses. + */ + final protected function constraint(): Constraint + { + return $this->constraint; + } + + /** + * Returns true if the $constraint needs to be wrapped with parentheses. + */ + protected function constraintNeedsParentheses(Constraint $constraint): bool + { + $constraint = $constraint->reduce(); + + return $constraint instanceof self || parent::constraintNeedsParentheses($constraint); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/IsJson.php b/vendor/phpunit/phpunit/src/Framework/Constraint/String/IsJson.php similarity index 90% rename from vendor/phpunit/phpunit/src/Framework/Constraint/IsJson.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/String/IsJson.php index e10e6c1d8..97b294617 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/IsJson.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/String/IsJson.php @@ -14,7 +14,7 @@ use function json_last_error; use function sprintf; /** - * Constraint that asserts that a string is valid JSON. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class IsJson extends Constraint { @@ -64,7 +64,7 @@ final class IsJson extends Constraint } json_decode($other); - $error = JsonMatchesErrorMessageProvider::determineJsonError( + $error = (string) JsonMatchesErrorMessageProvider::determineJsonError( (string) json_last_error() ); diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/RegularExpression.php b/vendor/phpunit/phpunit/src/Framework/Constraint/String/RegularExpression.php similarity index 78% rename from vendor/phpunit/phpunit/src/Framework/Constraint/RegularExpression.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/String/RegularExpression.php index 963bfd05d..8e609e795 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/RegularExpression.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/String/RegularExpression.php @@ -13,13 +13,7 @@ use function preg_match; use function sprintf; /** - * Constraint that asserts that the string it is evaluated for matches - * a regular expression. - * - * Checks a given value using the Perl Compatible Regular Expression extension - * in PHP. The pattern is matched by executing preg_match(). - * - * The pattern string passed in the constructor. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ class RegularExpression extends Constraint { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/StringContains.php b/vendor/phpunit/phpunit/src/Framework/Constraint/String/StringContains.php similarity index 61% rename from vendor/phpunit/phpunit/src/Framework/Constraint/StringContains.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/String/StringContains.php index 54606364c..6279f37ba 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/StringContains.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/String/StringContains.php @@ -10,18 +10,12 @@ namespace PHPUnit\Framework\Constraint; use function mb_stripos; -use function mb_strpos; use function mb_strtolower; use function sprintf; +use function strpos; /** - * Constraint that asserts that the string it is evaluated for contains - * a given string. - * - * Uses mb_strpos() to find the position of the string in the input, if not - * found the evaluation fails. - * - * The sub-string is passed in the constructor. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class StringContains extends Constraint { @@ -47,7 +41,7 @@ final class StringContains extends Constraint public function toString(): string { if ($this->ignoreCase) { - $string = mb_strtolower($this->string); + $string = mb_strtolower($this->string, 'UTF-8'); } else { $string = $this->string; } @@ -71,9 +65,21 @@ final class StringContains extends Constraint } if ($this->ignoreCase) { - return mb_stripos($other, $this->string) !== false; + /* + * We must use the multi byte safe version so we can accurately compare non latin upper characters with + * their lowercase equivalents. + */ + return mb_stripos($other, $this->string, 0, 'UTF-8') !== false; } - return mb_strpos($other, $this->string) !== false; + /* + * Use the non multi byte safe functions to see if the string is contained in $other. + * + * This function is very fast and we don't care about the character position in the string. + * + * Additionally, we want this method to be binary safe so we can check if some binary data is in other binary + * data. + */ + return strpos($other, $this->string) !== false; } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/StringEndsWith.php b/vendor/phpunit/phpunit/src/Framework/Constraint/String/StringEndsWith.php similarity index 90% rename from vendor/phpunit/phpunit/src/Framework/Constraint/StringEndsWith.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/String/StringEndsWith.php index ed11b01d1..bb4ce23be 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/StringEndsWith.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/String/StringEndsWith.php @@ -13,8 +13,7 @@ use function strlen; use function substr; /** - * Constraint that asserts that the string it is evaluated for ends with a given - * suffix. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class StringEndsWith extends Constraint { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/StringMatchesFormatDescription.php b/vendor/phpunit/phpunit/src/Framework/Constraint/String/StringMatchesFormatDescription.php similarity index 88% rename from vendor/phpunit/phpunit/src/Framework/Constraint/StringMatchesFormatDescription.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/String/StringMatchesFormatDescription.php index f2324bb3f..c4f7324ec 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/StringMatchesFormatDescription.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/String/StringMatchesFormatDescription.php @@ -17,9 +17,10 @@ use function preg_quote; use function preg_replace; use function strtr; use SebastianBergmann\Diff\Differ; +use SebastianBergmann\Diff\Output\UnifiedDiffOutputBuilder; /** - * ... + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class StringMatchesFormatDescription extends RegularExpression { @@ -75,7 +76,7 @@ final class StringMatchesFormatDescription extends RegularExpression $this->string = implode("\n", $from); $other = implode("\n", $to); - return (new Differ("--- Expected\n+++ Actual\n"))->diff($this->string, $other); + return (new Differ(new UnifiedDiffOutputBuilder("--- Expected\n+++ Actual\n")))->diff($this->string, $other); } private function createPatternFromFormat(string $string): string @@ -101,7 +102,7 @@ final class StringMatchesFormatDescription extends RegularExpression return '/^' . $string . '$/s'; } - private function convertNewlines($text): string + private function convertNewlines(string $text): string { return preg_replace('/\r\n/', "\n", $text); } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/StringStartsWith.php b/vendor/phpunit/phpunit/src/Framework/Constraint/String/StringStartsWith.php similarity index 92% rename from vendor/phpunit/phpunit/src/Framework/Constraint/StringStartsWith.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/String/StringStartsWith.php index a80a3f6b0..089545c12 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/StringStartsWith.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/String/StringStartsWith.php @@ -14,8 +14,7 @@ use function strpos; use PHPUnit\Framework\InvalidArgumentException; /** - * Constraint that asserts that the string it is evaluated for begins with a - * given prefix. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class StringStartsWith extends Constraint { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/ArrayHasKey.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/ArrayHasKey.php similarity index 88% rename from vendor/phpunit/phpunit/src/Framework/Constraint/ArrayHasKey.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/ArrayHasKey.php index 0ba5be92a..44cada3a7 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/ArrayHasKey.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/ArrayHasKey.php @@ -14,12 +14,7 @@ use function is_array; use ArrayAccess; /** - * Constraint that asserts that the array it is evaluated for has a given key. - * - * Uses array_key_exists() to check if the key is found in the input array, if - * not found the evaluation fails. - * - * The array key is passed in the constructor. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class ArrayHasKey extends Constraint { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/TraversableContainsIdentical.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContains.php similarity index 60% rename from vendor/phpunit/phpunit/src/Framework/Constraint/TraversableContainsIdentical.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContains.php index b455629ac..39660a985 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/TraversableContainsIdentical.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContains.php @@ -10,16 +10,12 @@ namespace PHPUnit\Framework\Constraint; use function is_array; -use function is_string; use function sprintf; -use function strpos; -use SplObjectStorage; /** - * Constraint that asserts that the Traversable it is applied to contains - * a given value (using strict comparison). + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ -final class TraversableContainsIdentical extends Constraint +abstract class TraversableContains extends Constraint { /** * @var mixed @@ -38,34 +34,9 @@ final class TraversableContainsIdentical extends Constraint */ public function toString(): string { - if (is_string($this->value) && strpos($this->value, "\n") !== false) { - return 'contains "' . $this->value . '"'; - } - return 'contains ' . $this->exporter()->export($this->value); } - /** - * Evaluates the constraint for parameter $other. Returns true if the - * constraint is met, false otherwise. - * - * @param mixed $other value or object to evaluate - */ - protected function matches($other): bool - { - if ($other instanceof SplObjectStorage) { - return $other->contains($this->value); - } - - foreach ($other as $element) { - if ($this->value === $element) { - return true; - } - } - - return false; - } - /** * Returns the description of the failure. * @@ -84,4 +55,9 @@ final class TraversableContainsIdentical extends Constraint $this->toString() ); } + + protected function value() + { + return $this->value; + } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContainsEqual.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContainsEqual.php new file mode 100644 index 000000000..c315e709a --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContainsEqual.php @@ -0,0 +1,40 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\Constraint; + +use SplObjectStorage; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class TraversableContainsEqual extends TraversableContains +{ + /** + * Evaluates the constraint for parameter $other. Returns true if the + * constraint is met, false otherwise. + * + * @param mixed $other value or object to evaluate + */ + protected function matches($other): bool + { + if ($other instanceof SplObjectStorage) { + return $other->contains($this->value()); + } + + foreach ($other as $element) { + /* @noinspection TypeUnsafeComparisonInspection */ + if ($this->value() == $element) { + return true; + } + } + + return false; + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContainsIdentical.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContainsIdentical.php new file mode 100644 index 000000000..a3437dbc9 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContainsIdentical.php @@ -0,0 +1,39 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\Constraint; + +use SplObjectStorage; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class TraversableContainsIdentical extends TraversableContains +{ + /** + * Evaluates the constraint for parameter $other. Returns true if the + * constraint is met, false otherwise. + * + * @param mixed $other value or object to evaluate + */ + protected function matches($other): bool + { + if ($other instanceof SplObjectStorage) { + return $other->contains($this->value()); + } + + foreach ($other as $element) { + if ($this->value() === $element) { + return true; + } + } + + return false; + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/TraversableContainsOnly.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContainsOnly.php similarity index 90% rename from vendor/phpunit/phpunit/src/Framework/Constraint/TraversableContainsOnly.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContainsOnly.php index a78cfcd8f..cf4a46b42 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/TraversableContainsOnly.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContainsOnly.php @@ -10,10 +10,10 @@ namespace PHPUnit\Framework\Constraint; use PHPUnit\Framework\ExpectationFailedException; +use Traversable; /** - * Constraint that asserts that the Traversable it is applied to contains - * only values of a given type. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class TraversableContainsOnly extends Constraint { @@ -53,10 +53,12 @@ final class TraversableContainsOnly extends Constraint * a boolean value instead: true in case of success, false in case of a * failure. * + * @param mixed|Traversable $other + * * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException */ - public function evaluate($other, string $description = '', bool $returnResult = false) + public function evaluate($other, string $description = '', bool $returnResult = false): ?bool { $success = true; @@ -75,6 +77,8 @@ final class TraversableContainsOnly extends Constraint if (!$success) { $this->fail($other, $description); } + + return null; } /** diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/TraversableContains.php b/vendor/phpunit/phpunit/src/Framework/Constraint/TraversableContains.php deleted file mode 100644 index 1cae5a306..000000000 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/TraversableContains.php +++ /dev/null @@ -1,120 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace PHPUnit\Framework\Constraint; - -use function is_array; -use function is_object; -use function is_string; -use function sprintf; -use function strpos; -use SplObjectStorage; - -/** - * Constraint that asserts that the Traversable it is applied to contains - * a given value. - * - * @deprecated Use TraversableContainsEqual or TraversableContainsIdentical instead - */ -final class TraversableContains extends Constraint -{ - /** - * @var bool - */ - private $checkForObjectIdentity; - - /** - * @var bool - */ - private $checkForNonObjectIdentity; - - /** - * @var mixed - */ - private $value; - - public function __construct($value, bool $checkForObjectIdentity = true, bool $checkForNonObjectIdentity = false) - { - $this->checkForObjectIdentity = $checkForObjectIdentity; - $this->checkForNonObjectIdentity = $checkForNonObjectIdentity; - $this->value = $value; - } - - /** - * Returns a string representation of the constraint. - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - */ - public function toString(): string - { - if (is_string($this->value) && strpos($this->value, "\n") !== false) { - return 'contains "' . $this->value . '"'; - } - - return 'contains ' . $this->exporter()->export($this->value); - } - - /** - * Evaluates the constraint for parameter $other. Returns true if the - * constraint is met, false otherwise. - * - * @param mixed $other value or object to evaluate - */ - protected function matches($other): bool - { - if ($other instanceof SplObjectStorage) { - return $other->contains($this->value); - } - - if (is_object($this->value)) { - foreach ($other as $element) { - if ($this->checkForObjectIdentity && $element === $this->value) { - return true; - } - - /* @noinspection TypeUnsafeComparisonInspection */ - if (!$this->checkForObjectIdentity && $element == $this->value) { - return true; - } - } - } else { - foreach ($other as $element) { - if ($this->checkForNonObjectIdentity && $element === $this->value) { - return true; - } - - /* @noinspection TypeUnsafeComparisonInspection */ - if (!$this->checkForNonObjectIdentity && $element == $this->value) { - return true; - } - } - } - - return false; - } - - /** - * Returns the description of the failure. - * - * The beginning of failure messages is "Failed asserting that" in most - * cases. This method should return the second part of that sentence. - * - * @param mixed $other evaluated value or object - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - */ - protected function failureDescription($other): string - { - return sprintf( - '%s %s', - is_array($other) ? 'an array' : 'a traversable', - $this->toString() - ); - } -} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/TraversableContainsEqual.php b/vendor/phpunit/phpunit/src/Framework/Constraint/TraversableContainsEqual.php deleted file mode 100644 index 1357332f1..000000000 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/TraversableContainsEqual.php +++ /dev/null @@ -1,88 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace PHPUnit\Framework\Constraint; - -use function is_array; -use function is_string; -use function sprintf; -use function strpos; -use SplObjectStorage; - -/** - * Constraint that asserts that the Traversable it is applied to contains - * a given value (using non-strict comparison). - */ -final class TraversableContainsEqual extends Constraint -{ - /** - * @var mixed - */ - private $value; - - public function __construct($value) - { - $this->value = $value; - } - - /** - * Returns a string representation of the constraint. - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - */ - public function toString(): string - { - if (is_string($this->value) && strpos($this->value, "\n") !== false) { - return 'contains "' . $this->value . '"'; - } - - return 'contains ' . $this->exporter()->export($this->value); - } - - /** - * Evaluates the constraint for parameter $other. Returns true if the - * constraint is met, false otherwise. - * - * @param mixed $other value or object to evaluate - */ - protected function matches($other): bool - { - if ($other instanceof SplObjectStorage) { - return $other->contains($this->value); - } - - foreach ($other as $element) { - /* @noinspection TypeUnsafeComparisonInspection */ - if ($this->value == $element) { - return true; - } - } - - return false; - } - - /** - * Returns the description of the failure. - * - * The beginning of failure messages is "Failed asserting that" in most - * cases. This method should return the second part of that sentence. - * - * @param mixed $other evaluated value or object - * - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - */ - protected function failureDescription($other): string - { - return sprintf( - '%s %s', - is_array($other) ? 'an array' : 'a traversable', - $this->toString() - ); - } -} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/IsInstanceOf.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Type/IsInstanceOf.php similarity index 92% rename from vendor/phpunit/phpunit/src/Framework/Constraint/IsInstanceOf.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Type/IsInstanceOf.php index 02631f8f4..f0fa02b99 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/IsInstanceOf.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Type/IsInstanceOf.php @@ -14,10 +14,7 @@ use ReflectionClass; use ReflectionException; /** - * Constraint that asserts that the object it is evaluated for is an instance - * of a given class. - * - * The expected class name is passed in the constructor. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class IsInstanceOf extends Constraint { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/IsNull.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Type/IsNull.php similarity index 88% rename from vendor/phpunit/phpunit/src/Framework/Constraint/IsNull.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Type/IsNull.php index 1538138b7..b9fcdd7a7 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/IsNull.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Type/IsNull.php @@ -10,7 +10,7 @@ namespace PHPUnit\Framework\Constraint; /** - * Constraint that accepts null. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class IsNull extends Constraint { diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/IsType.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Type/IsType.php similarity index 76% rename from vendor/phpunit/phpunit/src/Framework/Constraint/IsType.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Type/IsType.php index 977be34bc..5bc691d74 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/IsType.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Type/IsType.php @@ -9,7 +9,7 @@ */ namespace PHPUnit\Framework\Constraint; -use function get_resource_type; +use function gettype; use function is_array; use function is_bool; use function is_callable; @@ -18,17 +18,12 @@ use function is_int; use function is_iterable; use function is_numeric; use function is_object; -use function is_resource; use function is_scalar; use function is_string; use function sprintf; -use TypeError; /** - * Constraint that asserts that the value it is evaluated for is of a - * specified type. - * - * The expected value is passed in the constructor. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class IsType extends Constraint { @@ -72,6 +67,11 @@ final class IsType extends Constraint */ public const TYPE_RESOURCE = 'resource'; + /** + * @var string + */ + public const TYPE_CLOSED_RESOURCE = 'resource (closed)'; + /** * @var string */ @@ -96,22 +96,23 @@ final class IsType extends Constraint * @var array */ private const KNOWN_TYPES = [ - 'array' => true, - 'boolean' => true, - 'bool' => true, - 'double' => true, - 'float' => true, - 'integer' => true, - 'int' => true, - 'null' => true, - 'numeric' => true, - 'object' => true, - 'real' => true, - 'resource' => true, - 'string' => true, - 'scalar' => true, - 'callable' => true, - 'iterable' => true, + 'array' => true, + 'boolean' => true, + 'bool' => true, + 'double' => true, + 'float' => true, + 'integer' => true, + 'int' => true, + 'null' => true, + 'numeric' => true, + 'object' => true, + 'real' => true, + 'resource' => true, + 'resource (closed)' => true, + 'string' => true, + 'scalar' => true, + 'callable' => true, + 'iterable' => true, ]; /** @@ -186,20 +187,12 @@ final class IsType extends Constraint return is_object($other); case 'resource': - if (is_resource($other)) { - return true; - } + $type = gettype($other); - try { - $resource = @get_resource_type($other); + return $type === 'resource' || $type === 'resource (closed)'; - if (is_string($resource)) { - return true; - } - } catch (TypeError $e) { - } - - return false; + case 'resource (closed)': + return gettype($other) === 'resource (closed)'; case 'scalar': return is_scalar($other); @@ -209,6 +202,9 @@ final class IsType extends Constraint case 'iterable': return is_iterable($other); + + default: + return false; } } } diff --git a/vendor/phpunit/phpunit/src/Framework/DataProviderTestSuite.php b/vendor/phpunit/phpunit/src/Framework/DataProviderTestSuite.php index 2769a2dc2..18b549996 100644 --- a/vendor/phpunit/phpunit/src/Framework/DataProviderTestSuite.php +++ b/vendor/phpunit/phpunit/src/Framework/DataProviderTestSuite.php @@ -9,7 +9,6 @@ */ namespace PHPUnit\Framework; -use function count; use function explode; use PHPUnit\Util\Test as TestUtil; @@ -19,12 +18,12 @@ use PHPUnit\Util\Test as TestUtil; final class DataProviderTestSuite extends TestSuite { /** - * @var string[] + * @var list */ private $dependencies = []; /** - * @param string[] $dependencies + * @param list $dependencies */ public function setDependencies(array $dependencies): void { @@ -32,21 +31,34 @@ final class DataProviderTestSuite extends TestSuite foreach ($this->tests as $test) { if (!$test instanceof TestCase) { + // @codeCoverageIgnoreStart continue; + // @codeCoverageIgnoreStart } - $test->setDependencies($dependencies); } } - public function getDependencies(): array + /** + * @return list + */ + public function provides(): array { - return $this->dependencies; + if ($this->providedTests === null) { + $this->providedTests = [new ExecutionOrderDependency($this->getName())]; + } + + return $this->providedTests; } - public function hasDependencies(): bool + /** + * @return list + */ + public function requires(): array { - return count($this->dependencies) > 0; + // A DataProviderTestSuite does not have to traverse its child tests + // as these are inherited and cannot reference dataProvider rows directly + return $this->dependencies; } /** diff --git a/vendor/phpunit/phpunit/src/Framework/Error/Deprecated.php b/vendor/phpunit/phpunit/src/Framework/Error/Deprecated.php index 607c965c1..db62195f8 100644 --- a/vendor/phpunit/phpunit/src/Framework/Error/Deprecated.php +++ b/vendor/phpunit/phpunit/src/Framework/Error/Deprecated.php @@ -9,6 +9,9 @@ */ namespace PHPUnit\Framework\Error; +/** + * @internal + */ final class Deprecated extends Error { } diff --git a/vendor/phpunit/phpunit/src/Framework/Error/Error.php b/vendor/phpunit/phpunit/src/Framework/Error/Error.php index 61e80f8b6..2990b360e 100644 --- a/vendor/phpunit/phpunit/src/Framework/Error/Error.php +++ b/vendor/phpunit/phpunit/src/Framework/Error/Error.php @@ -11,6 +11,9 @@ namespace PHPUnit\Framework\Error; use PHPUnit\Framework\Exception; +/** + * @internal + */ class Error extends Exception { public function __construct(string $message, int $code, string $file, int $line, \Exception $previous = null) diff --git a/vendor/phpunit/phpunit/src/Framework/Error/Notice.php b/vendor/phpunit/phpunit/src/Framework/Error/Notice.php index 4a3d01da0..54e5e31ea 100644 --- a/vendor/phpunit/phpunit/src/Framework/Error/Notice.php +++ b/vendor/phpunit/phpunit/src/Framework/Error/Notice.php @@ -9,6 +9,9 @@ */ namespace PHPUnit\Framework\Error; +/** + * @internal + */ final class Notice extends Error { } diff --git a/vendor/phpunit/phpunit/src/Framework/Error/Warning.php b/vendor/phpunit/phpunit/src/Framework/Error/Warning.php index d49f99144..0c0c0064f 100644 --- a/vendor/phpunit/phpunit/src/Framework/Error/Warning.php +++ b/vendor/phpunit/phpunit/src/Framework/Error/Warning.php @@ -9,6 +9,9 @@ */ namespace PHPUnit\Framework\Error; +/** + * @internal + */ final class Warning extends Error { } diff --git a/vendor/phpunit/phpunit/src/Framework/ErrorTestCase.php b/vendor/phpunit/phpunit/src/Framework/ErrorTestCase.php new file mode 100644 index 000000000..841247d72 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/ErrorTestCase.php @@ -0,0 +1,66 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class ErrorTestCase extends TestCase +{ + /** + * @var bool + */ + protected $backupGlobals = false; + + /** + * @var bool + */ + protected $backupStaticAttributes = false; + + /** + * @var bool + */ + protected $runTestInSeparateProcess = false; + + /** + * @var string + */ + private $message; + + public function __construct(string $message = '') + { + $this->message = $message; + + parent::__construct('Error'); + } + + public function getMessage(): string + { + return $this->message; + } + + /** + * Returns a string representation of the test case. + */ + public function toString(): string + { + return 'Error'; + } + + /** + * @throws Exception + * + * @psalm-return never-return + */ + protected function runTest(): void + { + throw new Error($this->message); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Exception/ActualValueIsNotAnObjectException.php b/vendor/phpunit/phpunit/src/Framework/Exception/ActualValueIsNotAnObjectException.php new file mode 100644 index 000000000..adae28294 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Exception/ActualValueIsNotAnObjectException.php @@ -0,0 +1,32 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework; + +use const PHP_EOL; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class ActualValueIsNotAnObjectException extends Exception +{ + public function __construct() + { + parent::__construct( + 'Actual value is not an object', + 0, + null + ); + } + + public function __toString(): string + { + return $this->getMessage() . PHP_EOL; + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotAcceptParameterTypeException.php b/vendor/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotAcceptParameterTypeException.php new file mode 100644 index 000000000..ebd68f34c --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotAcceptParameterTypeException.php @@ -0,0 +1,38 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework; + +use const PHP_EOL; +use function sprintf; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class ComparisonMethodDoesNotAcceptParameterTypeException extends Exception +{ + public function __construct(string $className, string $methodName, string $type) + { + parent::__construct( + sprintf( + '%s is not an accepted argument type for comparison method %s::%s().', + $type, + $className, + $methodName + ), + 0, + null + ); + } + + public function __toString(): string + { + return $this->getMessage() . PHP_EOL; + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotDeclareBoolReturnTypeException.php b/vendor/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotDeclareBoolReturnTypeException.php new file mode 100644 index 000000000..20189cde4 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotDeclareBoolReturnTypeException.php @@ -0,0 +1,37 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework; + +use const PHP_EOL; +use function sprintf; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class ComparisonMethodDoesNotDeclareBoolReturnTypeException extends Exception +{ + public function __construct(string $className, string $methodName) + { + parent::__construct( + sprintf( + 'Comparison method %s::%s() does not declare bool return type.', + $className, + $methodName + ), + 0, + null + ); + } + + public function __toString(): string + { + return $this->getMessage() . PHP_EOL; + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotDeclareExactlyOneParameterException.php b/vendor/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotDeclareExactlyOneParameterException.php new file mode 100644 index 000000000..bd09d87cc --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotDeclareExactlyOneParameterException.php @@ -0,0 +1,37 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework; + +use const PHP_EOL; +use function sprintf; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class ComparisonMethodDoesNotDeclareExactlyOneParameterException extends Exception +{ + public function __construct(string $className, string $methodName) + { + parent::__construct( + sprintf( + 'Comparison method %s::%s() does not declare exactly one parameter.', + $className, + $methodName + ), + 0, + null + ); + } + + public function __toString(): string + { + return $this->getMessage() . PHP_EOL; + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotDeclareParameterTypeException.php b/vendor/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotDeclareParameterTypeException.php new file mode 100644 index 000000000..9bbb112ea --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotDeclareParameterTypeException.php @@ -0,0 +1,37 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework; + +use const PHP_EOL; +use function sprintf; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class ComparisonMethodDoesNotDeclareParameterTypeException extends Exception +{ + public function __construct(string $className, string $methodName) + { + parent::__construct( + sprintf( + 'Parameter of comparison method %s::%s() does not have a declared type.', + $className, + $methodName + ), + 0, + null + ); + } + + public function __toString(): string + { + return $this->getMessage() . PHP_EOL; + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotExistException.php b/vendor/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotExistException.php new file mode 100644 index 000000000..ad0e2d088 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Exception/ComparisonMethodDoesNotExistException.php @@ -0,0 +1,37 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework; + +use const PHP_EOL; +use function sprintf; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class ComparisonMethodDoesNotExistException extends Exception +{ + public function __construct(string $className, string $methodName) + { + parent::__construct( + sprintf( + 'Comparison method %s::%s() does not exist.', + $className, + $methodName + ), + 0, + null + ); + } + + public function __toString(): string + { + return $this->getMessage() . PHP_EOL; + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Builder/Match_.php b/vendor/phpunit/phpunit/src/Framework/Exception/Error.php similarity index 51% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Builder/Match_.php rename to vendor/phpunit/phpunit/src/Framework/Exception/Error.php index 6cec73ae9..d43e42186 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Builder/Match_.php +++ b/vendor/phpunit/phpunit/src/Framework/Exception/Error.php @@ -7,20 +7,18 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ -namespace PHPUnit\Framework\MockObject\Builder; +namespace PHPUnit\Framework; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ -interface Match_ extends Stub +final class Error extends Exception implements SelfDescribing { /** - * Defines the expectation which must occur before the current is valid. - * - * @param string $id the identification of the expectation that should - * occur before this one - * - * @return Stub + * Wrapper for getMessage() which is declared as final. */ - public function after($id); + public function toString(): string + { + return $this->getMessage(); + } } diff --git a/vendor/phpunit/phpunit/src/Framework/ExceptionWrapper.php b/vendor/phpunit/phpunit/src/Framework/ExceptionWrapper.php index ec7415372..d1ff4abc6 100644 --- a/vendor/phpunit/phpunit/src/Framework/ExceptionWrapper.php +++ b/vendor/phpunit/phpunit/src/Framework/ExceptionWrapper.php @@ -21,7 +21,7 @@ use Throwable; * Re-instantiates Exceptions thrown by user-space code to retain their original * class names, properties, and stack traces (but without arguments). * - * Unlike PHPUnit\Framework_\Exception, the complete stack of previous Exceptions + * Unlike PHPUnit\Framework\Exception, the complete stack of previous Exceptions * is processed. * * @internal This class is not covered by the backward compatibility promise for PHPUnit @@ -43,6 +43,7 @@ final class ExceptionWrapper extends Exception // PDOException::getCode() is a string. // @see https://php.net/manual/en/class.pdoexception.php#95812 parent::__construct($t->getMessage(), (int) $t->getCode()); + $this->setOriginalException($t); } @@ -103,6 +104,7 @@ final class ExceptionWrapper extends Exception /** * Method to contain static originalException to exclude it from stacktrace to prevent the stacktrace contents, * which can be quite big, from being garbage-collected, thus blocking memory until shutdown. + * * Approach works both for var_dump() and var_export() and print_r(). */ private function originalException(Throwable $exceptionToStore = null): ?Throwable diff --git a/vendor/phpunit/phpunit/src/Framework/ExecutionOrderDependency.php b/vendor/phpunit/phpunit/src/Framework/ExecutionOrderDependency.php new file mode 100644 index 000000000..8ba5b242d --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/ExecutionOrderDependency.php @@ -0,0 +1,203 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework; + +use function array_filter; +use function array_map; +use function array_values; +use function count; +use function explode; +use function in_array; +use function strpos; +use function trim; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class ExecutionOrderDependency +{ + /** + * @var string + */ + private $className = ''; + + /** + * @var string + */ + private $methodName = ''; + + /** + * @var bool + */ + private $useShallowClone = false; + + /** + * @var bool + */ + private $useDeepClone = false; + + public static function createFromDependsAnnotation(string $className, string $annotation): self + { + // Split clone option and target + $parts = explode(' ', trim($annotation), 2); + + if (count($parts) === 1) { + $cloneOption = ''; + $target = $parts[0]; + } else { + $cloneOption = $parts[0]; + $target = $parts[1]; + } + + // Prefix provided class for targets assumed to be in scope + if ($target !== '' && strpos($target, '::') === false) { + $target = $className . '::' . $target; + } + + return new self($target, null, $cloneOption); + } + + /** + * @psalm-param list $dependencies + * + * @psalm-return list + */ + public static function filterInvalid(array $dependencies): array + { + return array_values( + array_filter( + $dependencies, + static function (self $d) { + return $d->isValid(); + } + ) + ); + } + + /** + * @psalm-param list $existing + * @psalm-param list $additional + * + * @psalm-return list + */ + public static function mergeUnique(array $existing, array $additional): array + { + $existingTargets = array_map( + static function ($dependency) { + return $dependency->getTarget(); + }, + $existing + ); + + foreach ($additional as $dependency) { + if (in_array($dependency->getTarget(), $existingTargets, true)) { + continue; + } + + $existingTargets[] = $dependency->getTarget(); + $existing[] = $dependency; + } + + return $existing; + } + + /** + * @psalm-param list $left + * @psalm-param list $right + * + * @psalm-return list + */ + public static function diff(array $left, array $right): array + { + if ($right === []) { + return $left; + } + + if ($left === []) { + return []; + } + + $diff = []; + $rightTargets = array_map( + static function ($dependency) { + return $dependency->getTarget(); + }, + $right + ); + + foreach ($left as $dependency) { + if (in_array($dependency->getTarget(), $rightTargets, true)) { + continue; + } + + $diff[] = $dependency; + } + + return $diff; + } + + public function __construct(string $classOrCallableName, ?string $methodName = null, ?string $option = null) + { + if ($classOrCallableName === '') { + return; + } + + if (strpos($classOrCallableName, '::') !== false) { + [$this->className, $this->methodName] = explode('::', $classOrCallableName); + } else { + $this->className = $classOrCallableName; + $this->methodName = !empty($methodName) ? $methodName : 'class'; + } + + if ($option === 'clone') { + $this->useDeepClone = true; + } elseif ($option === 'shallowClone') { + $this->useShallowClone = true; + } + } + + public function __toString(): string + { + return $this->getTarget(); + } + + public function isValid(): bool + { + // Invalid dependencies can be declared and are skipped by the runner + return $this->className !== '' && $this->methodName !== ''; + } + + public function useShallowClone(): bool + { + return $this->useShallowClone; + } + + public function useDeepClone(): bool + { + return $this->useDeepClone; + } + + public function targetIsClass(): bool + { + return $this->methodName === 'class'; + } + + public function getTarget(): string + { + return $this->isValid() + ? $this->className . '::' . $this->methodName + : ''; + } + + public function getTargetClassName(): string + { + return $this->className; + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/IncompleteTest.php b/vendor/phpunit/phpunit/src/Framework/IncompleteTest.php index 268957c03..b77b1afff 100644 --- a/vendor/phpunit/phpunit/src/Framework/IncompleteTest.php +++ b/vendor/phpunit/phpunit/src/Framework/IncompleteTest.php @@ -9,9 +9,11 @@ */ namespace PHPUnit\Framework; +use Throwable; + /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ -interface IncompleteTest +interface IncompleteTest extends Throwable { } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Builder/InvocationMocker.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Builder/InvocationMocker.php index ee4dd20a6..3f8312afc 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Builder/InvocationMocker.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Builder/InvocationMocker.php @@ -12,20 +12,20 @@ namespace PHPUnit\Framework\MockObject\Builder; use function array_map; use function array_merge; use function count; -use function get_class; -use function gettype; use function in_array; -use function is_object; use function is_string; -use function sprintf; use function strtolower; use PHPUnit\Framework\Constraint\Constraint; use PHPUnit\Framework\MockObject\ConfigurableMethod; use PHPUnit\Framework\MockObject\IncompatibleReturnValueException; use PHPUnit\Framework\MockObject\InvocationHandler; use PHPUnit\Framework\MockObject\Matcher; +use PHPUnit\Framework\MockObject\MatcherAlreadyRegisteredException; +use PHPUnit\Framework\MockObject\MethodCannotBeConfiguredException; +use PHPUnit\Framework\MockObject\MethodNameAlreadyConfiguredException; +use PHPUnit\Framework\MockObject\MethodNameNotConfiguredException; +use PHPUnit\Framework\MockObject\MethodParametersAlreadyConfiguredException; use PHPUnit\Framework\MockObject\Rule; -use PHPUnit\Framework\MockObject\RuntimeException; use PHPUnit\Framework\MockObject\Stub\ConsecutiveCalls; use PHPUnit\Framework\MockObject\Stub\Exception; use PHPUnit\Framework\MockObject\Stub\ReturnArgument; @@ -37,6 +37,9 @@ use PHPUnit\Framework\MockObject\Stub\ReturnValueMap; use PHPUnit\Framework\MockObject\Stub\Stub; use Throwable; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ final class InvocationMocker implements InvocationStubber, MethodNameMatch { /** @@ -62,6 +65,8 @@ final class InvocationMocker implements InvocationStubber, MethodNameMatch } /** + * @throws MatcherAlreadyRegisteredException + * * @return $this */ public function id($id): self @@ -81,6 +86,12 @@ final class InvocationMocker implements InvocationStubber, MethodNameMatch return $this; } + /** + * @param mixed $value + * @param mixed[] $nextValues + * + * @throws IncompatibleReturnValueException + */ public function willReturn($value, ...$nextValues): self { if (count($nextValues) === 0) { @@ -158,13 +169,17 @@ final class InvocationMocker implements InvocationStubber, MethodNameMatch } /** - * @throws RuntimeException + * @param mixed[] $arguments + * + * @throws \PHPUnit\Framework\Exception + * @throws MethodNameNotConfiguredException + * @throws MethodParametersAlreadyConfiguredException * * @return $this */ public function with(...$arguments): self { - $this->canDefineParameters(); + $this->ensureParametersCanBeConfigured(); $this->matcher->setParametersRule(new Rule\Parameters($arguments)); @@ -174,13 +189,15 @@ final class InvocationMocker implements InvocationStubber, MethodNameMatch /** * @param array ...$arguments * - * @throws RuntimeException + * @throws \PHPUnit\Framework\Exception + * @throws MethodNameNotConfiguredException + * @throws MethodParametersAlreadyConfiguredException * * @return $this */ public function withConsecutive(...$arguments): self { - $this->canDefineParameters(); + $this->ensureParametersCanBeConfigured(); $this->matcher->setParametersRule(new Rule\ConsecutiveParameters($arguments)); @@ -188,13 +205,14 @@ final class InvocationMocker implements InvocationStubber, MethodNameMatch } /** - * @throws RuntimeException + * @throws MethodNameNotConfiguredException + * @throws MethodParametersAlreadyConfiguredException * * @return $this */ public function withAnyParameters(): self { - $this->canDefineParameters(); + $this->ensureParametersCanBeConfigured(); $this->matcher->setParametersRule(new Rule\AnyParameters); @@ -204,16 +222,16 @@ final class InvocationMocker implements InvocationStubber, MethodNameMatch /** * @param Constraint|string $constraint * - * @throws RuntimeException + * @throws \PHPUnit\Framework\InvalidArgumentException + * @throws MethodCannotBeConfiguredException + * @throws MethodNameAlreadyConfiguredException * * @return $this */ public function method($constraint): self { if ($this->matcher->hasMethodNameRule()) { - throw new RuntimeException( - 'Rule for method name is already defined, cannot redefine' - ); + throw new MethodNameAlreadyConfiguredException; } $configurableMethodNames = array_map( @@ -224,12 +242,7 @@ final class InvocationMocker implements InvocationStubber, MethodNameMatch ); if (is_string($constraint) && !in_array(strtolower($constraint), $configurableMethodNames, true)) { - throw new RuntimeException( - sprintf( - 'Trying to configure method "%s" which cannot be configured because it does not exist, has not been specified, is final, or is static', - $constraint - ) - ); + throw new MethodCannotBeConfiguredException($constraint); } $this->matcher->setMethodNameRule(new Rule\MethodName($constraint)); @@ -238,23 +251,17 @@ final class InvocationMocker implements InvocationStubber, MethodNameMatch } /** - * Validate that a parameters rule can be defined, throw exceptions otherwise. - * - * @throws RuntimeException + * @throws MethodNameNotConfiguredException + * @throws MethodParametersAlreadyConfiguredException */ - private function canDefineParameters(): void + private function ensureParametersCanBeConfigured(): void { if (!$this->matcher->hasMethodNameRule()) { - throw new RuntimeException( - 'Rule for method name is not defined, cannot define rule for parameters ' . - 'without one' - ); + throw new MethodNameNotConfiguredException; } if ($this->matcher->hasParametersRule()) { - throw new RuntimeException( - 'Rule for parameters is already defined, cannot redefine' - ); + throw new MethodParametersAlreadyConfiguredException; } } @@ -275,6 +282,9 @@ final class InvocationMocker implements InvocationStubber, MethodNameMatch return $configuredMethod; } + /** + * @throws IncompatibleReturnValueException + */ private function ensureTypeOfReturnValues(array $values): void { $configuredMethod = $this->getConfiguredMethod(); @@ -286,12 +296,8 @@ final class InvocationMocker implements InvocationStubber, MethodNameMatch foreach ($values as $value) { if (!$configuredMethod->mayReturn($value)) { throw new IncompatibleReturnValueException( - sprintf( - 'Method %s may not return value of type %s, its return declaration is "%s"', - $configuredMethod->getName(), - is_object($value) ? get_class($value) : gettype($value), - $configuredMethod->getReturnTypeDeclaration() - ) + $configuredMethod, + $value ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Builder/InvocationStubber.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Builder/InvocationStubber.php index c0e51b00e..f32ff0e7c 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Builder/InvocationStubber.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Builder/InvocationStubber.php @@ -12,6 +12,9 @@ namespace PHPUnit\Framework\MockObject\Builder; use PHPUnit\Framework\MockObject\Stub\Stub; use Throwable; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ interface InvocationStubber { public function will(Stub $stub): Identity; diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Builder/ParametersMatch.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Builder/ParametersMatch.php index 6f5fecdd3..707d82551 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Builder/ParametersMatch.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Builder/ParametersMatch.php @@ -12,8 +12,18 @@ namespace PHPUnit\Framework\MockObject\Builder; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ -interface ParametersMatch extends Match_ +interface ParametersMatch extends Stub { + /** + * Defines the expectation which must occur before the current is valid. + * + * @param string $id the identification of the expectation that should + * occur before this one + * + * @return Stub + */ + public function after($id); + /** * Sets the parameters to match for, each parameter to this function will * be part of match. To perform specific matches or constraints create a diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/ConfigurableMethod.php b/vendor/phpunit/phpunit/src/Framework/MockObject/ConfigurableMethod.php index f65983d32..4757dc637 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/ConfigurableMethod.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/ConfigurableMethod.php @@ -48,6 +48,6 @@ final class ConfigurableMethod public function getReturnTypeDeclaration(): string { - return $this->returnType->getReturnTypeDeclaration(); + return $this->returnType->asString(); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/CannotUseAddMethodsException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/CannotUseAddMethodsException.php new file mode 100644 index 000000000..12fa8b5c1 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/CannotUseAddMethodsException.php @@ -0,0 +1,29 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\MockObject; + +use function sprintf; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class CannotUseAddMethodsException extends \PHPUnit\Framework\Exception implements Exception +{ + public function __construct(string $type, string $methodName) + { + parent::__construct( + sprintf( + 'Trying to set mock method "%s" with addMethods(), but it exists in class "%s". Use onlyMethods() for methods that exist in the class', + $methodName, + $type + ) + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/CannotUseOnlyMethodsException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/CannotUseOnlyMethodsException.php new file mode 100644 index 000000000..95c302b3c --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/CannotUseOnlyMethodsException.php @@ -0,0 +1,29 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\MockObject; + +use function sprintf; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class CannotUseOnlyMethodsException extends \PHPUnit\Framework\Exception implements Exception +{ + public function __construct(string $type, string $methodName) + { + parent::__construct( + sprintf( + 'Trying to set mock method "%s" with onlyMethods, but it does not exist in class "%s". Use addMethods() for methods that do not exist in the class', + $methodName, + $type + ) + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassAlreadyExistsException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassAlreadyExistsException.php new file mode 100644 index 000000000..0ba9a187d --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassAlreadyExistsException.php @@ -0,0 +1,28 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\MockObject; + +use function sprintf; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class ClassAlreadyExistsException extends \PHPUnit\Framework\Exception implements Exception +{ + public function __construct(string $className) + { + parent::__construct( + sprintf( + 'Class "%s" already exists', + $className + ) + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsFinalException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsFinalException.php new file mode 100644 index 000000000..9b11f8c08 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsFinalException.php @@ -0,0 +1,28 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\MockObject; + +use function sprintf; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class ClassIsFinalException extends \PHPUnit\Framework\Exception implements Exception +{ + public function __construct(string $className) + { + parent::__construct( + sprintf( + 'Class "%s" is declared "final" and cannot be mocked', + $className + ) + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/DuplicateMethodException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/DuplicateMethodException.php new file mode 100644 index 000000000..6eb421774 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/DuplicateMethodException.php @@ -0,0 +1,32 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\MockObject; + +use function sprintf; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class DuplicateMethodException extends \PHPUnit\Framework\Exception implements Exception +{ + /** + * @psalm-param list $methods + */ + public function __construct(array $methods) + { + parent::__construct( + sprintf( + 'Cannot stub or mock using a method list that contains duplicates: "%s" (duplicate: "%s")', + implode(', ', $methods), + implode(', ', array_unique(array_diff_assoc($methods, array_unique($methods)))) + ) + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/IncompatibleReturnValueException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/IncompatibleReturnValueException.php index f1ceb1deb..1bacc3516 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/IncompatibleReturnValueException.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/IncompatibleReturnValueException.php @@ -9,9 +9,25 @@ */ namespace PHPUnit\Framework\MockObject; +use function sprintf; + /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ final class IncompatibleReturnValueException extends \PHPUnit\Framework\Exception implements Exception { + /** + * @param mixed $value + */ + public function __construct(ConfigurableMethod $method, $value) + { + parent::__construct( + sprintf( + 'Method %s may not return value of type %s, its return declaration is "%s"', + $method->getName(), + is_object($value) ? get_class($value) : gettype($value), + $method->getReturnTypeDeclaration() + ) + ); + } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/InvalidMethodNameException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/InvalidMethodNameException.php new file mode 100644 index 000000000..5d85290fa --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/InvalidMethodNameException.php @@ -0,0 +1,28 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\MockObject; + +use function sprintf; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class InvalidMethodNameException extends \PHPUnit\Framework\Exception implements Exception +{ + public function __construct(string $method) + { + parent::__construct( + sprintf( + 'Cannot stub or mock method with invalid name "%s"', + $method + ) + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MatchBuilderNotFoundException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MatchBuilderNotFoundException.php new file mode 100644 index 000000000..c05b2bce6 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MatchBuilderNotFoundException.php @@ -0,0 +1,28 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\MockObject; + +use function sprintf; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class MatchBuilderNotFoundException extends \PHPUnit\Framework\Exception implements Exception +{ + public function __construct(string $id) + { + parent::__construct( + sprintf( + 'No builder found for match builder identification <%s>', + $id + ) + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MatcherAlreadyRegisteredException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MatcherAlreadyRegisteredException.php new file mode 100644 index 000000000..efcc13ed9 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MatcherAlreadyRegisteredException.php @@ -0,0 +1,28 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\MockObject; + +use function sprintf; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class MatcherAlreadyRegisteredException extends \PHPUnit\Framework\Exception implements Exception +{ + public function __construct(string $id) + { + parent::__construct( + sprintf( + 'Matcher with id <%s> is already registered', + $id + ) + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MethodCannotBeConfiguredException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MethodCannotBeConfiguredException.php new file mode 100644 index 000000000..707290439 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MethodCannotBeConfiguredException.php @@ -0,0 +1,28 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\MockObject; + +use function sprintf; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class MethodCannotBeConfiguredException extends \PHPUnit\Framework\Exception implements Exception +{ + public function __construct(string $method) + { + parent::__construct( + sprintf( + 'Trying to configure method "%s" which cannot be configured because it does not exist, has not been specified, is final, or is static', + $method + ) + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MethodNameAlreadyConfiguredException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MethodNameAlreadyConfiguredException.php new file mode 100644 index 000000000..1e9f2c04c --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MethodNameAlreadyConfiguredException.php @@ -0,0 +1,21 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\MockObject; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class MethodNameAlreadyConfiguredException extends \PHPUnit\Framework\Exception implements Exception +{ + public function __construct() + { + parent::__construct('Method name is already configured'); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MethodNameNotConfiguredException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MethodNameNotConfiguredException.php new file mode 100644 index 000000000..89565b77e --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MethodNameNotConfiguredException.php @@ -0,0 +1,21 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\MockObject; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class MethodNameNotConfiguredException extends \PHPUnit\Framework\Exception implements Exception +{ + public function __construct() + { + parent::__construct('Method name is not configured'); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MethodParametersAlreadyConfiguredException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MethodParametersAlreadyConfiguredException.php new file mode 100644 index 000000000..1609c6ffb --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MethodParametersAlreadyConfiguredException.php @@ -0,0 +1,21 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\MockObject; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class MethodParametersAlreadyConfiguredException extends \PHPUnit\Framework\Exception implements Exception +{ + public function __construct() + { + parent::__construct('Method parameters already configured'); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/OriginalConstructorInvocationRequiredException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/OriginalConstructorInvocationRequiredException.php new file mode 100644 index 000000000..ecb9b63cf --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/OriginalConstructorInvocationRequiredException.php @@ -0,0 +1,21 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\MockObject; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class OriginalConstructorInvocationRequiredException extends \PHPUnit\Framework\Exception implements Exception +{ + public function __construct() + { + parent::__construct('Proxying to original methods requires invoking the original constructor'); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ReflectionException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ReflectionException.php new file mode 100644 index 000000000..d6319c694 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ReflectionException.php @@ -0,0 +1,19 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\MockObject; + +use RuntimeException; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class ReflectionException extends RuntimeException implements Exception +{ +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ReturnValueNotConfiguredException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ReturnValueNotConfiguredException.php new file mode 100644 index 000000000..8121e369b --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ReturnValueNotConfiguredException.php @@ -0,0 +1,27 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\MockObject; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class ReturnValueNotConfiguredException extends \PHPUnit\Framework\Exception implements Exception +{ + public function __construct(Invocation $invocation) + { + parent::__construct( + sprintf( + 'Return value inference disabled and no expectation set up for %s::%s()', + $invocation->getClassName(), + $invocation->getMethodName() + ) + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/SoapExtensionNotAvailableException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/SoapExtensionNotAvailableException.php new file mode 100644 index 000000000..98837c954 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/SoapExtensionNotAvailableException.php @@ -0,0 +1,23 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\MockObject; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class SoapExtensionNotAvailableException extends \PHPUnit\Framework\Exception implements Exception +{ + public function __construct() + { + parent::__construct( + 'The SOAP extension is required to generate a test double from WSDL' + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownClassException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownClassException.php new file mode 100644 index 000000000..e124f9b18 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownClassException.php @@ -0,0 +1,28 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\MockObject; + +use function sprintf; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class UnknownClassException extends \PHPUnit\Framework\Exception implements Exception +{ + public function __construct(string $className) + { + parent::__construct( + sprintf( + 'Class "%s" does not exist', + $className + ) + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownTraitException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownTraitException.php new file mode 100644 index 000000000..90fc8d848 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownTraitException.php @@ -0,0 +1,28 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\MockObject; + +use function sprintf; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class UnknownTraitException extends \PHPUnit\Framework\Exception implements Exception +{ + public function __construct(string $traitName) + { + parent::__construct( + sprintf( + 'Trait "%s" does not exist', + $traitName + ) + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownTypeException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownTypeException.php new file mode 100644 index 000000000..b1a70edd6 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownTypeException.php @@ -0,0 +1,28 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\MockObject; + +use function sprintf; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class UnknownTypeException extends \PHPUnit\Framework\Exception implements Exception +{ + public function __construct(string $type) + { + parent::__construct( + sprintf( + 'Class or interface "%s" does not exist', + $type + ) + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator.php index e0e1d5bc3..cb8531cd3 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator.php @@ -14,8 +14,6 @@ use const PHP_EOL; use const PHP_MAJOR_VERSION; use const PREG_OFFSET_CAPTURE; use const WSDL_CACHE_NONE; -use function array_diff_assoc; -use function array_map; use function array_merge; use function array_pop; use function array_unique; @@ -28,7 +26,6 @@ use function in_array; use function interface_exists; use function is_array; use function is_object; -use function is_string; use function md5; use function mt_rand; use function preg_match; @@ -50,11 +47,11 @@ use Iterator; use IteratorAggregate; use PHPUnit\Framework\InvalidArgumentException; use ReflectionClass; -use ReflectionException; use ReflectionMethod; +use SebastianBergmann\Template\Exception as TemplateException; +use SebastianBergmann\Template\Template; use SoapClient; use SoapFault; -use Text_Template; use Throwable; use Traversable; @@ -66,7 +63,7 @@ final class Generator /** * @var array */ - private const BLACKLISTED_METHOD_NAMES = [ + private const EXCLUDED_METHOD_NAMES = [ '__CLASS__' => true, '__DIR__' => true, '__FILE__' => true, @@ -85,24 +82,27 @@ final class Generator private static $cache = []; /** - * @var Text_Template[] + * @var Template[] */ private static $templates = []; /** * Returns a mock object for the specified class. * - * @param string|string[] $type - * @param null|array $methods + * @param null|array $methods * + * @throws \PHPUnit\Framework\InvalidArgumentException + * @throws ClassAlreadyExistsException + * @throws ClassIsFinalException + * @throws DuplicateMethodException + * @throws InvalidMethodNameException + * @throws OriginalConstructorInvocationRequiredException + * @throws ReflectionException * @throws RuntimeException + * @throws UnknownTypeException */ - public function getMock($type, $methods = [], array $arguments = [], string $mockClassName = '', bool $callOriginalConstructor = true, bool $callOriginalClone = true, bool $callAutoload = true, bool $cloneArguments = true, bool $callOriginalMethods = false, object $proxyTarget = null, bool $allowMockingUnknownTypes = true, bool $returnValueGeneration = true): MockObject + public function getMock(string $type, $methods = [], array $arguments = [], string $mockClassName = '', bool $callOriginalConstructor = true, bool $callOriginalClone = true, bool $callAutoload = true, bool $cloneArguments = true, bool $callOriginalMethods = false, object $proxyTarget = null, bool $allowMockingUnknownTypes = true, bool $returnValueGeneration = true): MockObject { - if (!is_array($type) && !is_string($type)) { - throw InvalidArgumentException::create(1, 'array or string'); - } - if (!is_array($methods) && null !== $methods) { throw InvalidArgumentException::create(2, 'array'); } @@ -111,66 +111,19 @@ final class Generator $type = 'Iterator'; } - if (is_array($type)) { - $type = array_unique( - array_map( - static function ($type) { - if ($type === 'Traversable' || - $type === '\\Traversable' || - $type === '\\Iterator') { - return 'Iterator'; - } - - return $type; - }, - $type - ) - ); - } - - if (!$allowMockingUnknownTypes) { - if (is_array($type)) { - foreach ($type as $_type) { - if (!class_exists($_type, $callAutoload) && - !interface_exists($_type, $callAutoload)) { - throw new RuntimeException( - sprintf( - 'Cannot stub or mock class or interface "%s" which does not exist', - $_type - ) - ); - } - } - } elseif (!class_exists($type, $callAutoload) && !interface_exists($type, $callAutoload)) { - throw new RuntimeException( - sprintf( - 'Cannot stub or mock class or interface "%s" which does not exist', - $type - ) - ); - } + if (!$allowMockingUnknownTypes && !class_exists($type, $callAutoload) && !interface_exists($type, $callAutoload)) { + throw new UnknownTypeException($type); } if (null !== $methods) { foreach ($methods as $method) { if (!preg_match('~[a-zA-Z_\x7f-\xff][a-zA-Z0-9_\x7f-\xff]*~', (string) $method)) { - throw new RuntimeException( - sprintf( - 'Cannot stub or mock method with invalid name "%s"', - $method - ) - ); + throw new InvalidMethodNameException((string) $method); } } if ($methods !== array_unique($methods)) { - throw new RuntimeException( - sprintf( - 'Cannot stub or mock using a method list that contains duplicates: "%s" (duplicate: "%s")', - implode(', ', $methods), - implode(', ', array_unique(array_diff_assoc($methods, array_unique($methods)))) - ) - ); + throw new DuplicateMethodException($methods); } } @@ -178,8 +131,8 @@ final class Generator try { $reflector = new ReflectionClass($mockClassName); // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new RuntimeException( + } catch (\ReflectionException $e) { + throw new ReflectionException( $e->getMessage(), (int) $e->getCode(), $e @@ -188,19 +141,12 @@ final class Generator // @codeCoverageIgnoreEnd if (!$reflector->implementsInterface(MockObject::class)) { - throw new RuntimeException( - sprintf( - 'Class "%s" already exists.', - $mockClassName - ) - ); + throw new ClassAlreadyExistsException($mockClassName); } } if (!$callOriginalConstructor && $callOriginalMethods) { - throw new RuntimeException( - 'Proxying to original methods requires invoking the original constructor' - ); + throw new OriginalConstructorInvocationRequiredException; } $mock = $this->generate( @@ -227,14 +173,24 @@ final class Generator /** * Returns a mock object for the specified abstract class with all abstract - * methods of the class mocked. Concrete methods to mock can be specified with - * the $mockedMethods parameter. + * methods of the class mocked. + * + * Concrete methods to mock can be specified with the $mockedMethods parameter. * * @psalm-template RealInstanceType of object * @psalm-param class-string $originalClassName * @psalm-return MockObject&RealInstanceType * + * @throws \PHPUnit\Framework\InvalidArgumentException + * @throws ClassAlreadyExistsException + * @throws ClassIsFinalException + * @throws DuplicateMethodException + * @throws InvalidMethodNameException + * @throws OriginalConstructorInvocationRequiredException + * @throws ReflectionException * @throws RuntimeException + * @throws UnknownClassException + * @throws UnknownTypeException */ public function getMockForAbstractClass(string $originalClassName, array $arguments = [], string $mockClassName = '', bool $callOriginalConstructor = true, bool $callOriginalClone = true, bool $callAutoload = true, array $mockedMethods = null, bool $cloneArguments = true): MockObject { @@ -243,8 +199,8 @@ final class Generator try { $reflector = new ReflectionClass($originalClassName); // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new RuntimeException( + } catch (\ReflectionException $e) { + throw new ReflectionException( $e->getMessage(), (int) $e->getCode(), $e @@ -276,9 +232,7 @@ final class Generator ); } - throw new RuntimeException( - sprintf('Class "%s" does not exist.', $originalClassName) - ); + throw new UnknownClassException($originalClassName); } /** @@ -286,17 +240,24 @@ final class Generator * of the trait mocked. Concrete methods to mock can be specified with the * `$mockedMethods` parameter. * + * @psalm-param trait-string $traitName + * + * @throws \PHPUnit\Framework\InvalidArgumentException + * @throws ClassAlreadyExistsException + * @throws ClassIsFinalException + * @throws DuplicateMethodException + * @throws InvalidMethodNameException + * @throws OriginalConstructorInvocationRequiredException + * @throws ReflectionException * @throws RuntimeException + * @throws UnknownClassException + * @throws UnknownTraitException + * @throws UnknownTypeException */ public function getMockForTrait(string $traitName, array $arguments = [], string $mockClassName = '', bool $callOriginalConstructor = true, bool $callOriginalClone = true, bool $callAutoload = true, array $mockedMethods = null, bool $cloneArguments = true): MockObject { if (!trait_exists($traitName, $callAutoload)) { - throw new RuntimeException( - sprintf( - 'Trait "%s" does not exist.', - $traitName - ) - ); + throw new UnknownTraitException($traitName); } $className = $this->generateClassName( @@ -324,17 +285,16 @@ final class Generator /** * Returns an object for the specified trait. * + * @psalm-param trait-string $traitName + * + * @throws ReflectionException * @throws RuntimeException + * @throws UnknownTraitException */ public function getObjectForTrait(string $traitName, string $traitClassName = '', bool $callAutoload = true, bool $callOriginalConstructor = false, array $arguments = []): object { if (!trait_exists($traitName, $callAutoload)) { - throw new RuntimeException( - sprintf( - 'Trait "%s" does not exist.', - $traitName - ) - ); + throw new UnknownTraitException($traitName); } $className = $this->generateClassName( @@ -365,12 +325,13 @@ final class Generator ); } - public function generate($type, array $methods = null, string $mockClassName = '', bool $callOriginalClone = true, bool $callAutoload = true, bool $cloneArguments = true, bool $callOriginalMethods = false): MockClass + /** + * @throws ClassIsFinalException + * @throws ReflectionException + * @throws RuntimeException + */ + public function generate(string $type, array $methods = null, string $mockClassName = '', bool $callOriginalClone = true, bool $callAutoload = true, bool $cloneArguments = true, bool $callOriginalMethods = false): MockClass { - if (is_array($type)) { - sort($type); - } - if ($mockClassName !== '') { return $this->generateMock( $type, @@ -384,7 +345,7 @@ final class Generator } $key = md5( - is_array($type) ? implode('_', $type) : $type . + $type . serialize($methods) . serialize($callOriginalClone) . serialize($cloneArguments) . @@ -408,13 +369,12 @@ final class Generator /** * @throws RuntimeException + * @throws SoapExtensionNotAvailableException */ public function generateClassFromWsdl(string $wsdlFile, string $className, array $methods = [], array $options = []): string { if (!extension_loaded('soap')) { - throw new RuntimeException( - 'The SOAP extension is required to generate a mock object from WSDL.' - ); + throw new SoapExtensionNotAvailableException; } $options = array_merge($options, ['cache_wsdl' => WSDL_CACHE_NONE]); @@ -501,7 +461,7 @@ final class Generator } /** - * @throws RuntimeException + * @throws ReflectionException * * @return string[] */ @@ -510,8 +470,8 @@ final class Generator try { $class = new ReflectionClass($className); // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new RuntimeException( + } catch (\ReflectionException $e) { + throw new ReflectionException( $e->getMessage(), (int) $e->getCode(), $e @@ -531,7 +491,7 @@ final class Generator } /** - * @throws RuntimeException + * @throws ReflectionException * * @return MockMethod[] */ @@ -540,8 +500,8 @@ final class Generator try { $class = new ReflectionClass($className); // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new RuntimeException( + } catch (\ReflectionException $e) { + throw new ReflectionException( $e->getMessage(), (int) $e->getCode(), $e @@ -561,7 +521,7 @@ final class Generator } /** - * @throws RuntimeException + * @throws ReflectionException * * @return MockMethod[] */ @@ -570,8 +530,8 @@ final class Generator try { $class = new ReflectionClass($interfaceName); // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new RuntimeException( + } catch (\ReflectionException $e) { + throw new ReflectionException( $e->getMessage(), (int) $e->getCode(), $e @@ -591,6 +551,8 @@ final class Generator /** * @psalm-param class-string $interfaceName * + * @throws ReflectionException + * * @return ReflectionMethod[] */ private function userDefinedInterfaceMethods(string $interfaceName): array @@ -598,8 +560,8 @@ final class Generator try { // @codeCoverageIgnoreStart $interface = new ReflectionClass($interfaceName); - } catch (ReflectionException $e) { - throw new RuntimeException( + } catch (\ReflectionException $e) { + throw new ReflectionException( $e->getMessage(), (int) $e->getCode(), $e @@ -620,6 +582,10 @@ final class Generator return $methods; } + /** + * @throws ReflectionException + * @throws RuntimeException + */ private function getObject(MockType $mockClass, $type = '', bool $callOriginalConstructor = false, bool $callAutoload = false, array $arguments = [], bool $callOriginalMethods = false, object $proxyTarget = null, bool $returnValueGeneration = true) { $className = $mockClass->generate(); @@ -631,8 +597,8 @@ final class Generator try { $class = new ReflectionClass($className); // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new RuntimeException( + } catch (\ReflectionException $e) { + throw new ReflectionException( $e->getMessage(), (int) $e->getCode(), $e @@ -645,8 +611,8 @@ final class Generator } else { try { $object = (new Instantiator)->instantiate($className); - } catch (InstantiatorException $exception) { - throw new RuntimeException($exception->getMessage()); + } catch (InstantiatorException $e) { + throw new RuntimeException($e->getMessage()); } } @@ -658,8 +624,8 @@ final class Generator try { $class = new ReflectionClass($type); // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new RuntimeException( + } catch (\ReflectionException $e) { + throw new ReflectionException( $e->getMessage(), (int) $e->getCode(), $e @@ -682,11 +648,11 @@ final class Generator } /** - * @param array|string $type - * + * @throws ClassIsFinalException + * @throws ReflectionException * @throws RuntimeException */ - private function generateMock($type, ?array $explicitMethods, string $mockClassName, bool $callOriginalClone, bool $callAutoload, bool $cloneArguments, bool $callOriginalMethods): MockClass + private function generateMock(string $type, ?array $explicitMethods, string $mockClassName, bool $callOriginalClone, bool $callAutoload, bool $cloneArguments, bool $callOriginalMethods): MockClass { $classTemplate = $this->getTemplate('mocked_class.tpl'); $additionalInterfaces = []; @@ -697,85 +663,23 @@ final class Generator $class = null; $mockMethods = new MockMethodSet; - if (is_array($type)) { - $interfaceMethods = []; - - foreach ($type as $_type) { - if (!interface_exists($_type, $callAutoload)) { - throw new RuntimeException( - sprintf( - 'Interface "%s" does not exist.', - $_type - ) - ); - } - - $additionalInterfaces[] = $_type; - - try { - $typeClass = new ReflectionClass($_type); - // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new RuntimeException( - $e->getMessage(), - (int) $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - - foreach ($this->getClassMethods($_type) as $method) { - if (in_array($method, $interfaceMethods, true)) { - throw new RuntimeException( - sprintf( - 'Duplicate method "%s" not allowed.', - $method - ) - ); - } - - try { - $methodReflection = $typeClass->getMethod($method); - // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new RuntimeException( - $e->getMessage(), - (int) $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - - if ($this->canMockMethod($methodReflection)) { - $mockMethods->addMethods( - MockMethod::fromReflection($methodReflection, $callOriginalMethods, $cloneArguments) - ); - - $interfaceMethods[] = $method; - } - } - } - - unset($interfaceMethods); - } - - $mockClassName = $this->generateClassName( + $_mockClassName = $this->generateClassName( $type, $mockClassName, 'Mock_' ); - if (class_exists($mockClassName['fullClassName'], $callAutoload)) { + if (class_exists($_mockClassName['fullClassName'], $callAutoload)) { $isClass = true; - } elseif (interface_exists($mockClassName['fullClassName'], $callAutoload)) { + } elseif (interface_exists($_mockClassName['fullClassName'], $callAutoload)) { $isInterface = true; } if (!$isClass && !$isInterface) { - $prologue = 'class ' . $mockClassName['originalClassName'] . "\n{\n}\n\n"; + $prologue = 'class ' . $_mockClassName['originalClassName'] . "\n{\n}\n\n"; - if (!empty($mockClassName['namespaceName'])) { - $prologue = 'namespace ' . $mockClassName['namespaceName'] . + if (!empty($_mockClassName['namespaceName'])) { + $prologue = 'namespace ' . $_mockClassName['namespaceName'] . " {\n\n" . $prologue . "}\n\n" . "namespace {\n\n"; @@ -785,10 +689,10 @@ final class Generator $mockedCloneMethod = true; } else { try { - $class = new ReflectionClass($mockClassName['fullClassName']); + $class = new ReflectionClass($_mockClassName['fullClassName']); // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new RuntimeException( + } catch (\ReflectionException $e) { + throw new ReflectionException( $e->getMessage(), (int) $e->getCode(), $e @@ -797,12 +701,7 @@ final class Generator // @codeCoverageIgnoreEnd if ($class->isFinal()) { - throw new RuntimeException( - sprintf( - 'Class "%s" is declared "final" and cannot be mocked.', - $mockClassName['fullClassName'] - ) - ); + throw new ClassIsFinalException($_mockClassName['fullClassName']); } // @see https://github.com/sebastianbergmann/phpunit/issues/2995 @@ -814,8 +713,8 @@ final class Generator try { $class = new ReflectionClass($actualClassName); // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new RuntimeException( + } catch (\ReflectionException $e) { + throw new ReflectionException( $e->getMessage(), (int) $e->getCode(), $e @@ -823,15 +722,15 @@ final class Generator } // @codeCoverageIgnoreEnd - foreach ($this->userDefinedInterfaceMethods($mockClassName['fullClassName']) as $method) { + foreach ($this->userDefinedInterfaceMethods($_mockClassName['fullClassName']) as $method) { $methodName = $method->getName(); if ($class->hasMethod($methodName)) { try { $classMethod = $class->getMethod($methodName); // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new RuntimeException( + } catch (\ReflectionException $e) { + throw new ReflectionException( $e->getMessage(), (int) $e->getCode(), $e @@ -849,9 +748,9 @@ final class Generator ); } - $mockClassName = $this->generateClassName( + $_mockClassName = $this->generateClassName( $actualClassName, - $mockClassName['className'], + $_mockClassName['className'], 'Mock_' ); } @@ -871,8 +770,8 @@ final class Generator try { $cloneMethod = $class->getMethod('__clone'); // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new RuntimeException( + } catch (\ReflectionException $e) { + throw new ReflectionException( $e->getMessage(), (int) $e->getCode(), $e @@ -894,13 +793,13 @@ final class Generator if ($isClass && $explicitMethods === []) { $mockMethods->addMethods( - ...$this->mockClassMethods($mockClassName['fullClassName'], $callOriginalMethods, $cloneArguments) + ...$this->mockClassMethods($_mockClassName['fullClassName'], $callOriginalMethods, $cloneArguments) ); } if ($isInterface && ($explicitMethods === [] || $explicitMethods === null)) { $mockMethods->addMethods( - ...$this->mockInterfaceMethods($mockClassName['fullClassName'], $cloneArguments) + ...$this->mockInterfaceMethods($_mockClassName['fullClassName'], $cloneArguments) ); } @@ -910,8 +809,8 @@ final class Generator try { $method = $class->getMethod($methodName); // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new RuntimeException( + } catch (\ReflectionException $e) { + throw new ReflectionException( $e->getMessage(), (int) $e->getCode(), $e @@ -927,7 +826,7 @@ final class Generator } else { $mockMethods->addMethods( MockMethod::fromName( - $mockClassName['fullClassName'], + $_mockClassName['fullClassName'], $methodName, $cloneArguments ) @@ -965,12 +864,12 @@ final class Generator 'prologue' => $prologue ?? '', 'epilogue' => $epilogue ?? '', 'class_declaration' => $this->generateMockClassDeclaration( - $mockClassName, + $_mockClassName, $isInterface, $additionalInterfaces ), 'clone' => $cloneTrait, - 'mock_class_name' => $mockClassName['className'], + 'mock_class_name' => $_mockClassName['className'], 'mocked_methods' => $mockedMethods, 'method' => $method, ] @@ -978,20 +877,13 @@ final class Generator return new MockClass( $classTemplate->render(), - $mockClassName['className'], + $_mockClassName['className'], $configurable ); } - /** - * @param array|string $type - */ - private function generateClassName($type, string $className, string $prefix): array + private function generateClassName(string $type, string $className, string $prefix): array { - if (is_array($type)) { - $type = implode('_', $type); - } - if ($type[0] === '\\') { $type = substr($type, 1); } @@ -1060,20 +952,31 @@ final class Generator private function canMockMethod(ReflectionMethod $method): bool { - return !($this->isConstructor($method) || $method->isFinal() || $method->isPrivate() || $this->isMethodNameBlacklisted($method->getName())); + return !($this->isConstructor($method) || $method->isFinal() || $method->isPrivate() || $this->isMethodNameExcluded($method->getName())); } - private function isMethodNameBlacklisted(string $name): bool + private function isMethodNameExcluded(string $name): bool { - return isset(self::BLACKLISTED_METHOD_NAMES[$name]); + return isset(self::EXCLUDED_METHOD_NAMES[$name]); } - private function getTemplate(string $template): Text_Template + /** + * @throws RuntimeException + */ + private function getTemplate(string $template): Template { $filename = __DIR__ . DIRECTORY_SEPARATOR . 'Generator' . DIRECTORY_SEPARATOR . $template; if (!isset(self::$templates[$filename])) { - self::$templates[$filename] = new Text_Template($filename); + try { + self::$templates[$filename] = new Template($filename); + } catch (TemplateException $e) { + throw new RuntimeException( + $e->getMessage(), + (int) $e->getCode(), + $e + ); + } } return self::$templates[$filename]; diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/mocked_method.tpl b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/mocked_method.tpl index 32304f30c..114ff8d0d 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/mocked_method.tpl +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/mocked_method.tpl @@ -14,7 +14,7 @@ $__phpunit_result = $this->__phpunit_getInvocationHandler()->invoke( new \PHPUnit\Framework\MockObject\Invocation( - '{class_name}', '{method_name}', $__phpunit_arguments, '{return_declaration}', $this, {clone_arguments} + '{class_name}', '{method_name}', $__phpunit_arguments, '{return_type}', $this, {clone_arguments} ) ); diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/mocked_method_void.tpl b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/mocked_method_void.tpl index 6ea6f4517..390202201 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/mocked_method_void.tpl +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/mocked_method_void.tpl @@ -14,7 +14,7 @@ $this->__phpunit_getInvocationHandler()->invoke( new \PHPUnit\Framework\MockObject\Invocation( - '{class_name}', '{method_name}', $__phpunit_arguments, '{return_declaration}', $this, {clone_arguments} + '{class_name}', '{method_name}', $__phpunit_arguments, '{return_type}', $this, {clone_arguments} ) ); } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/proxied_method.tpl b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/proxied_method.tpl index 6f699becb..91bef463d 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/proxied_method.tpl +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/proxied_method.tpl @@ -14,7 +14,7 @@ $this->__phpunit_getInvocationHandler()->invoke( new \PHPUnit\Framework\MockObject\Invocation( - '{class_name}', '{method_name}', $__phpunit_arguments, '{return_declaration}', $this, {clone_arguments}, true + '{class_name}', '{method_name}', $__phpunit_arguments, '{return_type}', $this, {clone_arguments}, true ) ); diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/proxied_method_void.tpl b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/proxied_method_void.tpl index b2f963dfb..cce198826 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/proxied_method_void.tpl +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/proxied_method_void.tpl @@ -14,7 +14,7 @@ $this->__phpunit_getInvocationHandler()->invoke( new \PHPUnit\Framework\MockObject\Invocation( - '{class_name}', '{method_name}', $__phpunit_arguments, '{return_declaration}', $this, {clone_arguments}, true + '{class_name}', '{method_name}', $__phpunit_arguments, '{return_type}', $this, {clone_arguments}, true ) ); diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Invocation.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Invocation.php index bedfebf1b..f4bbfa1c3 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Invocation.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Invocation.php @@ -10,13 +10,15 @@ namespace PHPUnit\Framework\MockObject; use function array_map; +use function explode; +use function get_class; use function implode; use function is_object; -use function ltrim; use function sprintf; use function strpos; use function strtolower; use function substr; +use Doctrine\Instantiator\Instantiator; use PHPUnit\Framework\SelfDescribing; use PHPUnit\Util\Type; use SebastianBergmann\Exporter\Exporter; @@ -70,8 +72,6 @@ final class Invocation implements SelfDescribing $this->object = $object; $this->proxiedCall = $proxiedCall; - $returnType = ltrim($returnType, ': '); - if (strtolower($methodName) === '__tostring') { $returnType = 'string'; } @@ -120,7 +120,20 @@ final class Invocation implements SelfDescribing return; } - switch (strtolower($this->returnType)) { + $returnType = $this->returnType; + + if (strpos($returnType, '|') !== false) { + $types = explode('|', $returnType); + $returnType = $types[0]; + + foreach ($types as $type) { + if ($type === 'null') { + return; + } + } + } + + switch (strtolower($returnType)) { case '': case 'void': return; @@ -140,6 +153,9 @@ final class Invocation implements SelfDescribing case 'array': return []; + case 'static': + return (new Instantiator)->instantiate(get_class($this->object)); + case 'object': return new stdClass; @@ -151,16 +167,17 @@ final class Invocation implements SelfDescribing case 'traversable': case 'generator': case 'iterable': - $generator = static function () { + $generator = static function (): \Generator { yield; }; return $generator(); - default: - $generator = new Generator; + case 'mixed': + return null; - return $generator->getMock($this->returnType, [], [], '', false); + default: + return (new Generator)->getMock($this->returnType, [], [], '', false); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/InvocationHandler.php b/vendor/phpunit/phpunit/src/Framework/MockObject/InvocationHandler.php index 77d7825a2..b9d62610a 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/InvocationHandler.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/InvocationHandler.php @@ -9,10 +9,8 @@ */ namespace PHPUnit\Framework\MockObject; -use function sprintf; use function strtolower; use Exception; -use PHPUnit\Framework\ExpectationFailedException; use PHPUnit\Framework\MockObject\Builder\InvocationMocker; use PHPUnit\Framework\MockObject\Rule\InvocationOrder; use Throwable; @@ -85,14 +83,12 @@ final class InvocationHandler * @param string $id The identification of the matcher * @param Matcher $matcher The builder which is being registered * - * @throws RuntimeException + * @throws MatcherAlreadyRegisteredException */ public function registerMatcher(string $id, Matcher $matcher): void { if (isset($this->matcherMap[$id])) { - throw new RuntimeException( - 'Matcher with id <' . $id . '> is already registered.' - ); + throw new MatcherAlreadyRegisteredException($id); } $this->matcherMap[$id] = $matcher; @@ -112,8 +108,7 @@ final class InvocationHandler /** * @throws Exception - * - * @return mixed|void + * @throws RuntimeException */ public function invoke(Invocation $invocation) { @@ -145,13 +140,7 @@ final class InvocationHandler } if (!$this->returnValueGeneration) { - $exception = new ExpectationFailedException( - sprintf( - 'Return value inference disabled and no expectation set up for %s::%s()', - $invocation->getClassName(), - $invocation->getMethodName() - ) - ); + $exception = new ReturnValueNotConfiguredException($invocation); if (strtolower($invocation->getMethodName()) === '__tostring') { $this->deferredError = $exception; @@ -177,7 +166,7 @@ final class InvocationHandler } /** - * @throws \PHPUnit\Framework\ExpectationFailedException + * @throws Throwable */ public function verify(): void { diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Matcher.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Matcher.php index 2b1cd8c86..a0f8817bd 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Matcher.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Matcher.php @@ -12,7 +12,6 @@ namespace PHPUnit\Framework\MockObject; use function assert; use function implode; use function sprintf; -use Exception; use PHPUnit\Framework\ExpectationFailedException; use PHPUnit\Framework\MockObject\Rule\AnyInvokedCount; use PHPUnit\Framework\MockObject\Rule\AnyParameters; @@ -104,14 +103,15 @@ final class Matcher } /** - * @throws Exception * @throws ExpectationFailedException + * @throws MatchBuilderNotFoundException + * @throws MethodNameNotConfiguredException * @throws RuntimeException */ public function invoked(Invocation $invocation) { if ($this->methodNameRule === null) { - throw new RuntimeException('No method rule is set'); + throw new MethodNameNotConfiguredException; } if ($this->afterMatchBuilderId !== null) { @@ -120,13 +120,9 @@ final class Matcher ->lookupMatcher($this->afterMatchBuilderId); if (!$matcher) { - throw new RuntimeException( - sprintf( - 'No builder found for match builder identification <%s>', - $this->afterMatchBuilderId - ) - ); + throw new MatchBuilderNotFoundException($this->afterMatchBuilderId); } + assert($matcher instanceof self); if ($matcher->invocationRule->hasBeenInvoked()) { @@ -162,6 +158,8 @@ final class Matcher /** * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException + * @throws MatchBuilderNotFoundException + * @throws MethodNameNotConfiguredException * @throws RuntimeException */ public function matches(Invocation $invocation): bool @@ -172,13 +170,9 @@ final class Matcher ->lookupMatcher($this->afterMatchBuilderId); if (!$matcher) { - throw new RuntimeException( - sprintf( - 'No builder found for match builder identification <%s>', - $this->afterMatchBuilderId - ) - ); + throw new MatchBuilderNotFoundException($this->afterMatchBuilderId); } + assert($matcher instanceof self); if (!$matcher->invocationRule->hasBeenInvoked()) { @@ -187,7 +181,7 @@ final class Matcher } if ($this->methodNameRule === null) { - throw new RuntimeException('No method rule is set'); + throw new MethodNameNotConfiguredException; } if (!$this->invocationRule->matches($invocation)) { @@ -216,12 +210,12 @@ final class Matcher /** * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws ExpectationFailedException - * @throws RuntimeException + * @throws MethodNameNotConfiguredException */ public function verify(): void { if ($this->methodNameRule === null) { - throw new RuntimeException('No method rule is set'); + throw new MethodNameNotConfiguredException; } try { diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/MockBuilder.php b/vendor/phpunit/phpunit/src/Framework/MockObject/MockBuilder.php index 6ff2b264e..aec32a2d4 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/MockBuilder.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/MockBuilder.php @@ -11,13 +11,13 @@ namespace PHPUnit\Framework\MockObject; use function array_diff; use function array_merge; -use function sprintf; use PHPUnit\Framework\TestCase; use ReflectionClass; -use ReflectionException; /** * @psalm-template MockedType + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class MockBuilder { @@ -111,7 +111,15 @@ final class MockBuilder /** * Creates a mock object using a fluent interface. * + * @throws \PHPUnit\Framework\InvalidArgumentException + * @throws ClassAlreadyExistsException + * @throws ClassIsFinalException + * @throws DuplicateMethodException + * @throws InvalidMethodNameException + * @throws OriginalConstructorInvocationRequiredException + * @throws ReflectionException * @throws RuntimeException + * @throws UnknownTypeException * * @psalm-return MockObject&MockedType */ @@ -140,10 +148,11 @@ final class MockBuilder /** * Creates a mock object for an abstract class using a fluent interface. * - * @throws \PHPUnit\Framework\Exception - * @throws RuntimeException - * * @psalm-return MockObject&MockedType + * + * @throws \PHPUnit\Framework\Exception + * @throws ReflectionException + * @throws RuntimeException */ public function getMockForAbstractClass(): MockObject { @@ -166,10 +175,11 @@ final class MockBuilder /** * Creates a mock object for a trait using a fluent interface. * - * @throws \PHPUnit\Framework\Exception - * @throws RuntimeException - * * @psalm-return MockObject&MockedType + * + * @throws \PHPUnit\Framework\Exception + * @throws ReflectionException + * @throws RuntimeException */ public function getMockForTrait(): MockObject { @@ -212,7 +222,8 @@ final class MockBuilder * * @param string[] $methods * - * @throws RuntimeException + * @throws CannotUseOnlyMethodsException + * @throws ReflectionException * * @return $this */ @@ -227,8 +238,8 @@ final class MockBuilder try { $reflector = new ReflectionClass($this->type); // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new RuntimeException( + } catch (\ReflectionException $e) { + throw new ReflectionException( $e->getMessage(), (int) $e->getCode(), $e @@ -238,13 +249,7 @@ final class MockBuilder foreach ($methods as $method) { if (!$reflector->hasMethod($method)) { - throw new RuntimeException( - sprintf( - 'Trying to set mock method "%s" with onlyMethods, but it does not exist in class "%s". Use addMethods() for methods that don\'t exist in the class.', - $method, - $this->type - ) - ); + throw new CannotUseOnlyMethodsException($this->type, $method); } } @@ -258,6 +263,8 @@ final class MockBuilder * * @param string[] $methods * + * @throws CannotUseAddMethodsException + * @throws ReflectionException * @throws RuntimeException * * @return $this @@ -273,8 +280,8 @@ final class MockBuilder try { $reflector = new ReflectionClass($this->type); // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new RuntimeException( + } catch (\ReflectionException $e) { + throw new ReflectionException( $e->getMessage(), (int) $e->getCode(), $e @@ -284,13 +291,7 @@ final class MockBuilder foreach ($methods as $method) { if ($reflector->hasMethod($method)) { - throw new RuntimeException( - sprintf( - 'Trying to set mock method "%s" with addMethods(), but it exists in class "%s". Use onlyMethods() for methods that exist in the class.', - $method, - $this->type - ) - ); + throw new CannotUseAddMethodsException($this->type, $method); } } @@ -301,6 +302,10 @@ final class MockBuilder /** * Specifies the subset of methods to not mock. Default is to mock all of them. + * + * @deprecated https://github.com/sebastianbergmann/phpunit/pull/3687 + * + * @throws ReflectionException */ public function setMethodsExcept(array $methods = []): self { diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/MockClass.php b/vendor/phpunit/phpunit/src/Framework/MockObject/MockClass.php index 4aaac1b43..253d78460 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/MockClass.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/MockClass.php @@ -23,7 +23,7 @@ final class MockClass implements MockType private $classCode; /** - * @var string + * @var class-string */ private $mockName; @@ -32,6 +32,9 @@ final class MockClass implements MockType */ private $configurableMethods; + /** + * @psalm-param class-string $mockName + */ public function __construct(string $classCode, string $mockName, array $configurableMethods) { $this->classCode = $classCode; @@ -39,6 +42,9 @@ final class MockClass implements MockType $this->configurableMethods = $configurableMethods; } + /** + * @psalm-return class-string + */ public function generate(): string { if (!class_exists($this->mockName, false)) { diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/MockMethod.php b/vendor/phpunit/phpunit/src/Framework/MockObject/MockMethod.php index 1aa728f1a..5e02cae5f 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/MockMethod.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/MockMethod.php @@ -18,14 +18,16 @@ use function sprintf; use function substr_count; use function trim; use function var_export; -use ReflectionException; use ReflectionMethod; use ReflectionNamedType; -use SebastianBergmann\Type\ObjectType; +use ReflectionParameter; +use ReflectionUnionType; +use SebastianBergmann\Template\Exception as TemplateException; +use SebastianBergmann\Template\Template; +use SebastianBergmann\Type\ReflectionMapper; use SebastianBergmann\Type\Type; use SebastianBergmann\Type\UnknownType; use SebastianBergmann\Type\VoidType; -use Text_Template; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit @@ -33,7 +35,7 @@ use Text_Template; final class MockMethod { /** - * @var Text_Template[] + * @var Template[] */ private static $templates = []; @@ -93,11 +95,7 @@ final class MockMethod private $deprecation; /** - * @var bool - */ - private $allowsReturnNull; - - /** + * @throws ReflectionException * @throws RuntimeException */ public static function fromReflection(ReflectionMethod $method, bool $callOriginalMethod, bool $cloneArguments): self @@ -136,12 +134,11 @@ final class MockMethod $modifier, self::getMethodParametersForDeclaration($method), self::getMethodParametersForCall($method), - self::deriveReturnType($method), + (new ReflectionMapper)->fromMethodReturnType($method), $reference, $callOriginalMethod, $method->isStatic(), - $deprecation, - $method->hasReturnType() && $method->getReturnType()->allowsNull() + $deprecation ); } @@ -158,12 +155,11 @@ final class MockMethod '', false, false, - null, - false + null ); } - public function __construct(string $className, string $methodName, bool $cloneArguments, string $modifier, string $argumentsForDeclaration, string $argumentsForCall, Type $returnType, string $reference, bool $callOriginalMethod, bool $static, ?string $deprecation, bool $allowsReturnNull) + public function __construct(string $className, string $methodName, bool $cloneArguments, string $modifier, string $argumentsForDeclaration, string $argumentsForCall, Type $returnType, string $reference, bool $callOriginalMethod, bool $static, ?string $deprecation) { $this->className = $className; $this->methodName = $methodName; @@ -176,7 +172,6 @@ final class MockMethod $this->callOriginalMethod = $callOriginalMethod; $this->static = $static; $this->deprecation = $deprecation; - $this->allowsReturnNull = $allowsReturnNull; } public function getName(): string @@ -209,9 +204,11 @@ final class MockMethod $deprecation = "The {$this->className}::{$this->methodName} method is deprecated ({$this->deprecation})."; $deprecationTemplate = $this->getTemplate('deprecation.tpl'); - $deprecationTemplate->setVar([ - 'deprecation' => var_export($deprecation, true), - ]); + $deprecationTemplate->setVar( + [ + 'deprecation' => var_export($deprecation, true), + ] + ); $deprecation = $deprecationTemplate->render(); } @@ -222,7 +219,8 @@ final class MockMethod [ 'arguments_decl' => $this->argumentsForDeclaration, 'arguments_call' => $this->argumentsForCall, - 'return_declaration' => $this->returnType->getReturnTypeDeclaration(), + 'return_declaration' => !empty($this->returnType->asString()) ? (': ' . $this->returnType->asString()) : '', + 'return_type' => $this->returnType->asString(), 'arguments_count' => !empty($this->argumentsForCall) ? substr_count($this->argumentsForCall, ',') + 1 : 0, 'class_name' => $this->className, 'method_name' => $this->methodName, @@ -241,12 +239,23 @@ final class MockMethod return $this->returnType; } - private function getTemplate(string $template): Text_Template + /** + * @throws RuntimeException + */ + private function getTemplate(string $template): Template { $filename = __DIR__ . DIRECTORY_SEPARATOR . 'Generator' . DIRECTORY_SEPARATOR . $template; if (!isset(self::$templates[$filename])) { - self::$templates[$filename] = new Text_Template($filename); + try { + self::$templates[$filename] = new Template($filename); + } catch (TemplateException $e) { + throw new RuntimeException( + $e->getMessage(), + (int) $e->getCode(), + $e + ); + } } return self::$templates[$filename]; @@ -289,13 +298,13 @@ final class MockMethod if ($parameter->isVariadic()) { $name = '...' . $name; } elseif ($parameter->isDefaultValueAvailable()) { - $default = ' = ' . var_export($parameter->getDefaultValue(), true); + $default = ' = ' . self::exportDefaultValue($parameter); } elseif ($parameter->isOptional()) { $default = ' = null'; } if ($type !== null) { - if ($typeName !== 'mixed' && $parameter->allowsNull()) { + if ($typeName !== 'mixed' && $parameter->allowsNull() && !$type instanceof ReflectionUnionType) { $nullable = '?'; } @@ -303,6 +312,11 @@ final class MockMethod $typeDeclaration = $method->getDeclaringClass()->getName() . ' '; } elseif ($typeName !== null) { $typeDeclaration = $typeName . ' '; + } elseif ($type instanceof ReflectionUnionType) { + $typeDeclaration = self::unionTypeAsString( + $type, + $method->getDeclaringClass()->getName() + ); } } @@ -349,37 +363,36 @@ final class MockMethod return implode(', ', $parameters); } - private static function deriveReturnType(ReflectionMethod $method): Type + /** + * @throws ReflectionException + */ + private static function exportDefaultValue(ReflectionParameter $parameter): string { - $returnType = $method->getReturnType(); - - if ($returnType === null) { - return new UnknownType(); + try { + return (string) var_export($parameter->getDefaultValue(), true); + // @codeCoverageIgnoreStart + } catch (\ReflectionException $e) { + throw new ReflectionException( + $e->getMessage(), + (int) $e->getCode(), + $e + ); } + // @codeCoverageIgnoreEnd + } - // @see https://bugs.php.net/bug.php?id=70722 - if ($returnType->getName() === 'self') { - return ObjectType::fromName($method->getDeclaringClass()->getName(), $returnType->allowsNull()); - } + private static function unionTypeAsString(ReflectionUnionType $union, string $self): string + { + $types = []; - // @see https://github.com/sebastianbergmann/phpunit-mock-objects/issues/406 - if ($returnType->getName() === 'parent') { - $parentClass = $method->getDeclaringClass()->getParentClass(); - - if ($parentClass === false) { - throw new RuntimeException( - sprintf( - 'Cannot mock %s::%s because "parent" return type declaration is used but %s does not have a parent class', - $method->getDeclaringClass()->getName(), - $method->getName(), - $method->getDeclaringClass()->getName() - ) - ); + foreach ($union->getTypes() as $type) { + if ((string) $type === 'self') { + $types[] = $self; + } else { + $types[] = $type; } - - return ObjectType::fromName($parentClass->getName(), $returnType->allowsNull()); } - return Type::fromName($returnType->getName(), $returnType->allowsNull()); + return implode('|', $types) . ' '; } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/MockObject.php b/vendor/phpunit/phpunit/src/Framework/MockObject/MockObject.php index 4db11e152..094decf43 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/MockObject.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/MockObject.php @@ -14,6 +14,8 @@ use PHPUnit\Framework\MockObject\Rule\InvocationOrder; /** * @method BuilderInvocationMocker method($constraint) + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ interface MockObject extends Stub { diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/MockTrait.php b/vendor/phpunit/phpunit/src/Framework/MockObject/MockTrait.php index 7b9f45003..7c326988f 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/MockTrait.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/MockTrait.php @@ -22,16 +22,22 @@ final class MockTrait implements MockType private $classCode; /** - * @var string + * @var class-string */ private $mockName; + /** + * @psalm-param class-string $mockName + */ public function __construct(string $classCode, string $mockName) { $this->classCode = $classCode; $this->mockName = $mockName; } + /** + * @psalm-return class-string + */ public function generate(): string { if (!class_exists($this->mockName, false)) { diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/MockType.php b/vendor/phpunit/phpunit/src/Framework/MockObject/MockType.php index b35ac306d..6a03fb51a 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/MockType.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/MockType.php @@ -14,5 +14,8 @@ namespace PHPUnit\Framework\MockObject; */ interface MockType { + /** + * @psalm-return class-string + */ public function generate(): string; } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/ConsecutiveParameters.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/ConsecutiveParameters.php index 9cb8137d1..6025c0a16 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/ConsecutiveParameters.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/ConsecutiveParameters.php @@ -103,12 +103,6 @@ final class ConsecutiveParameters implements ParametersRule return; } - if ($invocation === null) { - throw new ExpectationFailedException( - 'Mocked method does not exist.' - ); - } - $parameters = $this->parameterGroups[$callIndex]; if (count($invocation->getParameters()) < count($parameters)) { diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedAtIndex.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedAtIndex.php index 3d8446c93..2a6625e2f 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedAtIndex.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedAtIndex.php @@ -15,8 +15,11 @@ use PHPUnit\Framework\MockObject\Invocation as BaseInvocation; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4297 + * @codeCoverageIgnore */ -class InvokedAtIndex extends InvocationOrder +final class InvokedAtIndex extends InvocationOrder { /** * @var int diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/MethodName.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/MethodName.php index 39fb33332..83ba3b8da 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/MethodName.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/MethodName.php @@ -57,8 +57,12 @@ final class MethodName return $this->matchesName($invocation->getMethodName()); } + /** + * @throws \PHPUnit\Framework\ExpectationFailedException + * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException + */ public function matchesName(string $methodName): bool { - return $this->constraint->evaluate($methodName, '', true); + return (bool) $this->constraint->evaluate($methodName, '', true); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/ParametersRule.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/ParametersRule.php index 0c9f1910d..70c47fe32 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/ParametersRule.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/ParametersRule.php @@ -14,6 +14,9 @@ use PHPUnit\Framework\MockObject\Invocation as BaseInvocation; use PHPUnit\Framework\MockObject\Verifiable; use PHPUnit\Framework\SelfDescribing; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ interface ParametersRule extends SelfDescribing, Verifiable { /** diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Stub.php index f7358afab..2b032e2dc 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Stub.php @@ -13,6 +13,8 @@ use PHPUnit\Framework\MockObject\Builder\InvocationStubber; /** * @method InvocationStubber method($constraint) + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ interface Stub { diff --git a/vendor/phpunit/phpunit/src/Framework/Reorderable.php b/vendor/phpunit/phpunit/src/Framework/Reorderable.php new file mode 100644 index 000000000..34951f8dc --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Reorderable.php @@ -0,0 +1,28 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +interface Reorderable +{ + public function sortId(): string; + + /** + * @return list + */ + public function provides(): array; + + /** + * @return list + */ + public function requires(): array; +} diff --git a/vendor/phpunit/phpunit/src/Framework/SkippedTest.php b/vendor/phpunit/phpunit/src/Framework/SkippedTest.php index c5ac84e67..a12aa402d 100644 --- a/vendor/phpunit/phpunit/src/Framework/SkippedTest.php +++ b/vendor/phpunit/phpunit/src/Framework/SkippedTest.php @@ -9,9 +9,11 @@ */ namespace PHPUnit\Framework; +use Throwable; + /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ -interface SkippedTest +interface SkippedTest extends Throwable { } diff --git a/vendor/phpunit/phpunit/src/Framework/Test.php b/vendor/phpunit/phpunit/src/Framework/Test.php index 7740afc27..be0dcd0ef 100644 --- a/vendor/phpunit/phpunit/src/Framework/Test.php +++ b/vendor/phpunit/phpunit/src/Framework/Test.php @@ -12,7 +12,7 @@ namespace PHPUnit\Framework; use Countable; /** - * A Test can be run and collect its results. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ interface Test extends Countable { diff --git a/vendor/phpunit/phpunit/src/Framework/TestBuilder.php b/vendor/phpunit/phpunit/src/Framework/TestBuilder.php index 583a9f2c4..5dd91e219 100644 --- a/vendor/phpunit/phpunit/src/Framework/TestBuilder.php +++ b/vendor/phpunit/phpunit/src/Framework/TestBuilder.php @@ -30,7 +30,7 @@ final class TestBuilder $className = $theClass->getName(); if (!$theClass->isInstantiable()) { - return new WarningTestCase( + return new ErrorTestCase( sprintf('Cannot instantiate class "%s".', $className) ); } @@ -99,7 +99,7 @@ final class TestBuilder $this->throwableToString($t) ); - $data = new WarningTestCase($message); + $data = new ErrorTestCase($message); } // Test method with @dataProvider. @@ -154,7 +154,7 @@ final class TestBuilder $groups = TestUtil::getGroups($className, $methodName); - if ($data instanceof WarningTestCase || + if ($data instanceof ErrorTestCase || $data instanceof SkippedTestCase || $data instanceof IncompleteTestCase) { $dataProviderTestSuite->addTest($data, $groups); diff --git a/vendor/phpunit/phpunit/src/Framework/TestCase.php b/vendor/phpunit/phpunit/src/Framework/TestCase.php index 8cfea45fa..a9daaf8aa 100644 --- a/vendor/phpunit/phpunit/src/Framework/TestCase.php +++ b/vendor/phpunit/phpunit/src/Framework/TestCase.php @@ -12,7 +12,6 @@ namespace PHPUnit\Framework; use const LC_ALL; use const LC_COLLATE; use const LC_CTYPE; -use const LC_MESSAGES; use const LC_MONETARY; use const LC_NUMERIC; use const LC_TIME; @@ -23,15 +22,17 @@ use function array_filter; use function array_flip; use function array_keys; use function array_merge; +use function array_pop; +use function array_search; use function array_unique; use function array_values; -use function assert; use function basename; use function call_user_func; use function chdir; use function class_exists; use function clearstatcache; use function count; +use function debug_backtrace; use function defined; use function explode; use function get_class; @@ -41,6 +42,7 @@ use function implode; use function in_array; use function ini_set; use function is_array; +use function is_callable; use function is_int; use function is_object; use function is_string; @@ -56,7 +58,6 @@ use function preg_replace; use function serialize; use function setlocale; use function sprintf; -use function strlen; use function strpos; use function substr; use function trim; @@ -104,14 +105,18 @@ use SebastianBergmann\Comparator\Comparator; use SebastianBergmann\Comparator\Factory as ComparatorFactory; use SebastianBergmann\Diff\Differ; use SebastianBergmann\Exporter\Exporter; -use SebastianBergmann\GlobalState\Blacklist; +use SebastianBergmann\GlobalState\ExcludeList; use SebastianBergmann\GlobalState\Restorer; use SebastianBergmann\GlobalState\Snapshot; use SebastianBergmann\ObjectEnumerator\Enumerator; -use Text_Template; +use SebastianBergmann\Template\Template; +use SoapClient; use Throwable; -abstract class TestCase extends Assert implements SelfDescribing, Test +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +abstract class TestCase extends Assert implements Reorderable, SelfDescribing, Test { private const LOCALE_CATEGORIES = [LC_ALL, LC_COLLATE, LC_CTYPE, LC_MONETARY, LC_NUMERIC, LC_TIME]; @@ -123,6 +128,13 @@ abstract class TestCase extends Assert implements SelfDescribing, Test /** * @var string[] */ + protected $backupGlobalsExcludeList = []; + + /** + * @var string[] + * + * @deprecated Use $backupGlobalsExcludeList instead + */ protected $backupGlobalsBlacklist = []; /** @@ -133,6 +145,13 @@ abstract class TestCase extends Assert implements SelfDescribing, Test /** * @var array> */ + protected $backupStaticAttributesExcludeList = []; + + /** + * @var array> + * + * @deprecated Use $backupStaticAttributesExcludeList instead + */ protected $backupStaticAttributesBlacklist = []; /** @@ -145,6 +164,11 @@ abstract class TestCase extends Assert implements SelfDescribing, Test */ protected $preserveGlobalState = true; + /** + * @var list + */ + protected $providedTests = []; + /** * @var bool */ @@ -161,7 +185,7 @@ abstract class TestCase extends Assert implements SelfDescribing, Test private $data; /** - * @var string + * @var int|string */ private $dataName; @@ -191,7 +215,7 @@ abstract class TestCase extends Assert implements SelfDescribing, Test private $name = ''; /** - * @var string[] + * @var list */ private $dependencies = []; @@ -251,12 +275,12 @@ abstract class TestCase extends Assert implements SelfDescribing, Test private $output = ''; /** - * @var string + * @var ?string */ private $outputExpectedRegex; /** - * @var string + * @var ?string */ private $outputExpectedString; @@ -281,7 +305,7 @@ abstract class TestCase extends Assert implements SelfDescribing, Test private $outputRetrievedForAssertion = false; /** - * @var Snapshot + * @var ?Snapshot */ private $snapshot; @@ -325,11 +349,6 @@ abstract class TestCase extends Assert implements SelfDescribing, Test */ private $doubledTypes = []; - /** - * @var bool - */ - private $deprecatedExpectExceptionMessageRegExpUsed = false; - /** * Returns a matcher that matches when the method is executed * zero or more times. @@ -395,9 +414,26 @@ abstract class TestCase extends Assert implements SelfDescribing, Test /** * Returns a matcher that matches when the method is executed * at the given index. + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/4297 + * @codeCoverageIgnore */ public static function at(int $index): InvokedAtIndexMatcher { + $stack = debug_backtrace(); + + while (!empty($stack)) { + $frame = array_pop($stack); + + if (isset($frame['object']) && $frame['object'] instanceof self) { + $frame['object']->addWarning( + 'The at() matcher has been deprecated. It will be removed in PHPUnit 10. Please refactor your test to not rely on the order in which methods are invoked.' + ); + + break; + } + } + return new InvokedAtIndexMatcher($index); } @@ -442,12 +478,11 @@ abstract class TestCase extends Assert implements SelfDescribing, Test } /** - * @param string $name - * @param string $dataName + * @param int|string $dataName * * @internal This method is not covered by the backward compatibility promise for PHPUnit */ - public function __construct($name = null, array $data = [], $dataName = '') + public function __construct(?string $name = null, array $data = [], $dataName = '') { if ($name !== null) { $this->setName($name); @@ -541,6 +576,30 @@ abstract class TestCase extends Assert implements SelfDescribing, Test */ public function expectException(string $exception): void { + // @codeCoverageIgnoreStart + switch ($exception) { + case Deprecated::class: + $this->addWarning('Support for using expectException() with PHPUnit\Framework\Error\Deprecated is deprecated and will be removed in PHPUnit 10. Use expectDeprecation() instead.'); + + break; + + case Error::class: + $this->addWarning('Support for using expectException() with PHPUnit\Framework\Error\Error is deprecated and will be removed in PHPUnit 10. Use expectError() instead.'); + + break; + + case Notice::class: + $this->addWarning('Support for using expectException() with PHPUnit\Framework\Error\Notice is deprecated and will be removed in PHPUnit 10. Use expectNotice() instead.'); + + break; + + case WarningError::class: + $this->addWarning('Support for using expectException() with PHPUnit\Framework\Error\Warning is deprecated and will be removed in PHPUnit 10. Use expectWarning() instead.'); + + break; + } + // @codeCoverageIgnoreEnd + $this->expectedException = $exception; } @@ -562,16 +621,6 @@ abstract class TestCase extends Assert implements SelfDescribing, Test $this->expectedExceptionMessageRegExp = $regularExpression; } - /** - * @deprecated Use expectExceptionMessageMatches() instead - */ - public function expectExceptionMessageRegExp(string $regularExpression): void - { - $this->deprecatedExpectExceptionMessageRegExpUsed = true; - - $this->expectExceptionMessageMatches($regularExpression); - } - /** * Sets up an expectation for an exception to be raised by the code under test. * Information for expected exception class, expected exception message, and @@ -591,7 +640,7 @@ abstract class TestCase extends Assert implements SelfDescribing, Test public function expectDeprecation(): void { - $this->expectException(Deprecated::class); + $this->expectedException = Deprecated::class; } public function expectDeprecationMessage(string $message): void @@ -606,7 +655,7 @@ abstract class TestCase extends Assert implements SelfDescribing, Test public function expectNotice(): void { - $this->expectException(Notice::class); + $this->expectedException = Notice::class; } public function expectNoticeMessage(string $message): void @@ -621,7 +670,7 @@ abstract class TestCase extends Assert implements SelfDescribing, Test public function expectWarning(): void { - $this->expectException(WarningError::class); + $this->expectedException = WarningError::class; } public function expectWarningMessage(string $message): void @@ -636,7 +685,7 @@ abstract class TestCase extends Assert implements SelfDescribing, Test public function expectError(): void { - $this->expectException(Error::class); + $this->expectedException = Error::class; } public function expectErrorMessage(string $message): void @@ -675,10 +724,7 @@ abstract class TestCase extends Assert implements SelfDescribing, Test * Runs the test case and collects the results in a TestResult object. * If no TestResult object is passed a new one will be created. * - * @throws \SebastianBergmann\CodeCoverage\CoveredCodeNotExecutedException * @throws \SebastianBergmann\CodeCoverage\InvalidArgumentException - * @throws \SebastianBergmann\CodeCoverage\MissingCoversAnnotationException - * @throws \SebastianBergmann\CodeCoverage\RuntimeException * @throws \SebastianBergmann\CodeCoverage\UnintentionallyCoveredCodeException * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws CodeCoverageException @@ -690,11 +736,12 @@ abstract class TestCase extends Assert implements SelfDescribing, Test $result = $this->createResult(); } - if (!$this instanceof WarningTestCase) { + if (!$this instanceof ErrorTestCase && !$this instanceof WarningTestCase) { $this->setTestResultObject($result); } - if (!$this instanceof WarningTestCase && + if (!$this instanceof ErrorTestCase && + !$this instanceof WarningTestCase && !$this instanceof SkippedTestCase && !$this->handleDependencies()) { return $result; @@ -716,11 +763,11 @@ abstract class TestCase extends Assert implements SelfDescribing, Test // @codeCoverageIgnoreEnd if ($runEntireClass) { - $template = new Text_Template( + $template = new Template( __DIR__ . '/../Util/PHP/Template/TestCaseClass.tpl' ); } else { - $template = new Text_Template( + $template = new Template( __DIR__ . '/../Util/PHP/Template/TestCaseMethod.tpl' ); } @@ -762,24 +809,39 @@ abstract class TestCase extends Assert implements SelfDescribing, Test $phar = '\'\''; } - if ($result->getCodeCoverage()) { - $codeCoverageFilter = $result->getCodeCoverage()->filter(); - } else { - $codeCoverageFilter = null; + $codeCoverage = $result->getCodeCoverage(); + $codeCoverageFilter = null; + $cachesStaticAnalysis = 'false'; + $codeCoverageCacheDirectory = null; + $driverMethod = 'forLineCoverage'; + + if ($codeCoverage) { + $codeCoverageFilter = $codeCoverage->filter(); + + if ($codeCoverage->collectsBranchAndPathCoverage()) { + $driverMethod = 'forLineAndPathCoverage'; + } + + if ($codeCoverage->cachesStaticAnalysis()) { + $cachesStaticAnalysis = 'true'; + $codeCoverageCacheDirectory = $codeCoverage->cacheDirectory(); + } } - $data = var_export(serialize($this->data), true); - $dataName = var_export($this->dataName, true); - $dependencyInput = var_export(serialize($this->dependencyInput), true); - $includePath = var_export(get_include_path(), true); - $codeCoverageFilter = var_export(serialize($codeCoverageFilter), true); + $data = var_export(serialize($this->data), true); + $dataName = var_export($this->dataName, true); + $dependencyInput = var_export(serialize($this->dependencyInput), true); + $includePath = var_export(get_include_path(), true); + $codeCoverageFilter = var_export(serialize($codeCoverageFilter), true); + $codeCoverageCacheDirectory = var_export(serialize($codeCoverageCacheDirectory), true); // must do these fixes because TestCaseMethod.tpl has unserialize('{data}') in it, and we can't break BC // the lines above used to use addcslashes() rather than var_export(), which breaks null byte escape sequences - $data = "'." . $data . ".'"; - $dataName = "'.(" . $dataName . ").'"; - $dependencyInput = "'." . $dependencyInput . ".'"; - $includePath = "'." . $includePath . ".'"; - $codeCoverageFilter = "'." . $codeCoverageFilter . ".'"; + $data = "'." . $data . ".'"; + $dataName = "'.(" . $dataName . ").'"; + $dependencyInput = "'." . $dependencyInput . ".'"; + $includePath = "'." . $includePath . ".'"; + $codeCoverageFilter = "'." . $codeCoverageFilter . ".'"; + $codeCoverageCacheDirectory = "'." . $codeCoverageCacheDirectory . ".'"; $configurationFilePath = $GLOBALS['__PHPUNIT_CONFIGURATION_FILE'] ?? ''; @@ -789,6 +851,9 @@ abstract class TestCase extends Assert implements SelfDescribing, Test 'filename' => $class->getFileName(), 'className' => $class->getName(), 'collectCodeCoverageInformation' => $coverage, + 'cachesStaticAnalysis' => $cachesStaticAnalysis, + 'codeCoverageCacheDirectory' => $codeCoverageCacheDirectory, + 'driverMethod' => $driverMethod, 'data' => $data, 'dataName' => $dataName, 'dependencyInput' => $dependencyInput, @@ -827,18 +892,12 @@ abstract class TestCase extends Assert implements SelfDescribing, Test /** * Returns a builder object to create mock objects using a fluent interface. * - * @param string|string[] $className - * * @psalm-template RealInstanceType of object - * @psalm-param class-string|string[] $className + * @psalm-param class-string $className * @psalm-return MockBuilder */ - public function getMockBuilder($className): MockBuilder + public function getMockBuilder(string $className): MockBuilder { - if (!is_string($className)) { - $this->addWarning('Passing an array of interface names to getMockBuilder() for creating a test double that implements multiple interfaces is deprecated and will no longer be supported in PHPUnit 9.'); - } - $this->recordDoubledType($className); return new MockBuilder($this, $className); @@ -851,15 +910,6 @@ abstract class TestCase extends Assert implements SelfDescribing, Test $this->customComparators[] = $comparator; } - /** - * @internal This method is not covered by the backward compatibility promise for PHPUnit - * - * @deprecated Invoking this method has no effect; it will be removed in PHPUnit 9 - */ - public function setUseErrorHandler(bool $useErrorHandler): void - { - } - /** * @return string[] * @@ -886,17 +936,6 @@ abstract class TestCase extends Assert implements SelfDescribing, Test $this->groups = $groups; } - /** - * @internal This method is not covered by the backward compatibility promise for PHPUnit - */ - public function getAnnotations(): array - { - return TestUtil::parseTestMethodAnnotations( - static::class, - $this->name - ); - } - /** * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @@ -1080,17 +1119,22 @@ abstract class TestCase extends Assert implements SelfDescribing, Test } } - $this->setExpectedExceptionFromAnnotation(); $this->setDoesNotPerformAssertionsFromAnnotation(); foreach ($hookMethods['before'] as $method) { $this->{$method}(); } - $this->assertPreConditions(); + foreach ($hookMethods['preCondition'] as $method) { + $this->{$method}(); + } + $this->testResult = $this->runTest(); $this->verifyMockObjects(); - $this->assertPostConditions(); + + foreach ($hookMethods['postCondition'] as $method) { + $this->{$method}(); + } if (!empty($this->warnings)) { throw new Warning( @@ -1171,7 +1215,7 @@ abstract class TestCase extends Assert implements SelfDescribing, Test if (!isset($e)) { try { if ($this->outputExpectedRegex !== null) { - $this->assertRegExp($this->outputExpectedRegex, $this->output); + $this->assertMatchesRegularExpression($this->outputExpectedRegex, $this->output); } elseif ($this->outputExpectedString !== null) { $this->assertEquals($this->outputExpectedString, $this->output); } @@ -1196,10 +1240,14 @@ abstract class TestCase extends Assert implements SelfDescribing, Test public function setName(string $name): void { $this->name = $name; + + if (is_callable($this->sortId(), true)) { + $this->providedTests = [new ExecutionOrderDependency($this->sortId())]; + } } /** - * @param string[] $dependencies + * @param list $dependencies * * @internal This method is not covered by the backward compatibility promise for PHPUnit */ @@ -1208,22 +1256,6 @@ abstract class TestCase extends Assert implements SelfDescribing, Test $this->dependencies = $dependencies; } - /** - * @internal This method is not covered by the backward compatibility promise for PHPUnit - */ - public function getDependencies(): array - { - return $this->dependencies; - } - - /** - * @internal This method is not covered by the backward compatibility promise for PHPUnit - */ - public function hasDependencies(): bool - { - return count($this->dependencies) > 0; - } - /** * @internal This method is not covered by the backward compatibility promise for PHPUnit */ @@ -1232,14 +1264,6 @@ abstract class TestCase extends Assert implements SelfDescribing, Test $this->dependencyInput = $dependencyInput; } - /** - * @internal This method is not covered by the backward compatibility promise for PHPUnit - */ - public function getDependencyInput(): array - { - return $this->dependencyInput; - } - /** * @internal This method is not covered by the backward compatibility promise for PHPUnit */ @@ -1386,14 +1410,6 @@ abstract class TestCase extends Assert implements SelfDescribing, Test return !empty($this->data); } - /** - * @internal This method is not covered by the backward compatibility promise for PHPUnit - */ - public function dataDescription(): string - { - return is_string($this->dataName) ? $this->dataName : ''; - } - /** * @return int|string * @@ -1446,6 +1462,45 @@ abstract class TestCase extends Assert implements SelfDescribing, Test $this->warnings[] = $warning; } + public function sortId(): string + { + $id = $this->name; + + if (strpos($id, '::') === false) { + $id = static::class . '::' . $id; + } + + if ($this->usesDataProvider()) { + $id .= $this->getDataSetAsString(false); + } + + return $id; + } + + /** + * Returns the normalized test name as class::method. + * + * @return list + */ + public function provides(): array + { + return $this->providedTests; + } + + /** + * Returns a list of normalized dependency names, class::method. + * + * This list can differ from the raw dependencies as the resolver has + * no need for the [!][shallow]clone prefix that is filtered out + * during normalization. + * + * @return list + */ + public function requires(): array + { + return $this->dependencies; + } + /** * Override to run the test and assert its state. * @@ -1510,10 +1565,6 @@ abstract class TestCase extends Assert implements SelfDescribing, Test ); } - if ($this->deprecatedExpectExceptionMessageRegExpUsed) { - $this->addWarning('expectExceptionMessageRegExp() is deprecated in PHPUnit 8 and will be removed in PHPUnit 9. Use expectExceptionMessageMatches() instead.'); - } - return; } @@ -1594,10 +1645,6 @@ abstract class TestCase extends Assert implements SelfDescribing, Test [$category, $locale] = $args; - if (defined('LC_MESSAGES')) { - $categories[] = LC_MESSAGES; - } - if (!in_array($category, self::LOCALE_CATEGORIES, true)) { throw new Exception; } @@ -1628,44 +1675,31 @@ abstract class TestCase extends Assert implements SelfDescribing, Test */ protected function createStub(string $originalClassName): Stub { - return $this->createMock($originalClassName); + return $this->createMockObject($originalClassName); } /** * Returns a mock object for the specified class. * - * @param string|string[] $originalClassName - * * @psalm-template RealInstanceType of object - * @psalm-param class-string|string[] $originalClassName + * @psalm-param class-string $originalClassName * @psalm-return MockObject&RealInstanceType */ - protected function createMock($originalClassName): MockObject + protected function createMock(string $originalClassName): MockObject { - if (!is_string($originalClassName)) { - $this->addWarning('Passing an array of interface names to createMock() for creating a test double that implements multiple interfaces is deprecated and will no longer be supported in PHPUnit 9.'); - } - - return $this->getMockBuilder($originalClassName) - ->disableOriginalConstructor() - ->disableOriginalClone() - ->disableArgumentCloning() - ->disallowMockingUnknownTypes() - ->getMock(); + return $this->createMockObject($originalClassName); } /** * Returns a configured mock object for the specified class. * - * @param string|string[] $originalClassName - * * @psalm-template RealInstanceType of object - * @psalm-param class-string|string[] $originalClassName + * @psalm-param class-string $originalClassName * @psalm-return MockObject&RealInstanceType */ - protected function createConfiguredMock($originalClassName, array $configuration): MockObject + protected function createConfiguredMock(string $originalClassName, array $configuration): MockObject { - $o = $this->createMock($originalClassName); + $o = $this->createMockObject($originalClassName); foreach ($configuration as $method => $return) { $o->method($method)->willReturn($return); @@ -1677,40 +1711,41 @@ abstract class TestCase extends Assert implements SelfDescribing, Test /** * Returns a partial mock object for the specified class. * - * @param string|string[] $originalClassName - * @param string[] $methods + * @param string[] $methods * * @psalm-template RealInstanceType of object - * @psalm-param class-string|string[] $originalClassName + * @psalm-param class-string $originalClassName * @psalm-return MockObject&RealInstanceType */ - protected function createPartialMock($originalClassName, array $methods): MockObject + protected function createPartialMock(string $originalClassName, array $methods): MockObject { - if (!is_string($originalClassName)) { - $this->addWarning('Passing an array of interface names to createPartialMock() for creating a test double that implements multiple interfaces is deprecated and will no longer be supported in PHPUnit 9.'); - } - - $class_names = is_array($originalClassName) ? $originalClassName : [$originalClassName]; - - foreach ($class_names as $class_name) { - $reflection = new ReflectionClass($class_name); - - $mockedMethodsThatDontExist = array_filter( - $methods, - static function (string $method) use ($reflection) { - return !$reflection->hasMethod($method); - } + try { + $reflector = new ReflectionClass($originalClassName); + // @codeCoverageIgnoreStart + } catch (ReflectionException $e) { + throw new Exception( + $e->getMessage(), + (int) $e->getCode(), + $e ); + } + // @codeCoverageIgnoreEnd - if ($mockedMethodsThatDontExist) { - $this->addWarning( - sprintf( - 'createPartialMock called with method(s) %s that do not exist in %s. This will not be allowed in future versions of PHPUnit.', - implode(', ', $mockedMethodsThatDontExist), - $class_name - ) - ); + $mockedMethodsThatDontExist = array_filter( + $methods, + static function (string $method) use ($reflector) { + return !$reflector->hasMethod($method); } + ); + + if ($mockedMethodsThatDontExist) { + $this->addWarning( + sprintf( + 'createPartialMock() called with method(s) %s that do not exist in %s. This will not be allowed in future versions of PHPUnit.', + implode(', ', $mockedMethodsThatDontExist), + $originalClassName + ) + ); } return $this->getMockBuilder($originalClassName) @@ -1740,19 +1775,13 @@ abstract class TestCase extends Assert implements SelfDescribing, Test /** * Mocks the specified class and returns the name of the mocked class. * - * @param string $originalClassName - * @param array $methods - * @param string $mockClassName - * @param bool $callOriginalConstructor - * @param bool $callOriginalClone - * @param bool $callAutoload - * @param bool $cloneArguments + * @param null|array $methods $methods * * @psalm-template RealInstanceType of object * @psalm-param class-string|string $originalClassName * @psalm-return class-string */ - protected function getMockClass($originalClassName, $methods = [], array $arguments = [], $mockClassName = '', $callOriginalConstructor = false, $callOriginalClone = true, $callAutoload = true, $cloneArguments = false): string + protected function getMockClass(string $originalClassName, $methods = [], array $arguments = [], string $mockClassName = '', bool $callOriginalConstructor = false, bool $callOriginalClone = true, bool $callAutoload = true, bool $cloneArguments = false): string { $this->recordDoubledType($originalClassName); @@ -1775,19 +1804,11 @@ abstract class TestCase extends Assert implements SelfDescribing, Test * methods of the class mocked. Concrete methods are not mocked by default. * To mock concrete methods, use the 7th parameter ($mockedMethods). * - * @param string $originalClassName - * @param string $mockClassName - * @param bool $callOriginalConstructor - * @param bool $callOriginalClone - * @param bool $callAutoload - * @param array $mockedMethods - * @param bool $cloneArguments - * * @psalm-template RealInstanceType of object * @psalm-param class-string $originalClassName * @psalm-return MockObject&RealInstanceType */ - protected function getMockForAbstractClass($originalClassName, array $arguments = [], $mockClassName = '', $callOriginalConstructor = true, $callOriginalClone = true, $callAutoload = true, $mockedMethods = [], $cloneArguments = false): MockObject + protected function getMockForAbstractClass(string $originalClassName, array $arguments = [], string $mockClassName = '', bool $callOriginalConstructor = true, bool $callOriginalClone = true, bool $callAutoload = true, array $mockedMethods = [], bool $cloneArguments = false): MockObject { $this->recordDoubledType($originalClassName); @@ -1810,19 +1831,13 @@ abstract class TestCase extends Assert implements SelfDescribing, Test /** * Returns a mock object based on the given WSDL file. * - * @param string $wsdlFile - * @param string $originalClassName - * @param string $mockClassName - * @param bool $callOriginalConstructor - * @param array $options An array of options passed to SOAPClient::_construct - * * @psalm-template RealInstanceType of object * @psalm-param class-string|string $originalClassName * @psalm-return MockObject&RealInstanceType */ - protected function getMockFromWsdl($wsdlFile, $originalClassName = '', $mockClassName = '', array $methods = [], $callOriginalConstructor = true, array $options = []): MockObject + protected function getMockFromWsdl(string $wsdlFile, string $originalClassName = '', string $mockClassName = '', array $methods = [], bool $callOriginalConstructor = true, array $options = []): MockObject { - $this->recordDoubledType('SoapClient'); + $this->recordDoubledType(SoapClient::class); if ($originalClassName === '') { $fileName = pathinfo(basename(parse_url($wsdlFile, PHP_URL_PATH)), PATHINFO_FILENAME); @@ -1860,15 +1875,9 @@ abstract class TestCase extends Assert implements SelfDescribing, Test * of the trait mocked. Concrete methods to mock can be specified with the * `$mockedMethods` parameter. * - * @param string $traitName - * @param string $mockClassName - * @param bool $callOriginalConstructor - * @param bool $callOriginalClone - * @param bool $callAutoload - * @param array $mockedMethods - * @param bool $cloneArguments + * @psalm-param trait-string $traitName */ - protected function getMockForTrait($traitName, array $arguments = [], $mockClassName = '', $callOriginalConstructor = true, $callOriginalClone = true, $callAutoload = true, $mockedMethods = [], $cloneArguments = false): MockObject + protected function getMockForTrait(string $traitName, array $arguments = [], string $mockClassName = '', bool $callOriginalConstructor = true, bool $callOriginalClone = true, bool $callAutoload = true, array $mockedMethods = [], bool $cloneArguments = false): MockObject { $this->recordDoubledType($traitName); @@ -1891,15 +1900,9 @@ abstract class TestCase extends Assert implements SelfDescribing, Test /** * Returns an object for the specified trait. * - * @param string $traitName - * @param string $traitClassName - * @param bool $callOriginalConstructor - * @param bool $callOriginalClone - * @param bool $callAutoload - * - * @return object + * @psalm-param trait-string $traitName */ - protected function getObjectForTrait($traitName, array $arguments = [], $traitClassName = '', $callOriginalConstructor = true, $callOriginalClone = true, $callAutoload = true)/*: object*/ + protected function getObjectForTrait(string $traitName, array $arguments = [], string $traitClassName = '', bool $callOriginalConstructor = true, bool $callOriginalClone = true, bool $callAutoload = true): object { $this->recordDoubledType($traitName); @@ -1913,16 +1916,16 @@ abstract class TestCase extends Assert implements SelfDescribing, Test } /** - * @param null|string $classOrInterface - * * @throws \Prophecy\Exception\Doubler\ClassNotFoundException * @throws \Prophecy\Exception\Doubler\DoubleException * @throws \Prophecy\Exception\Doubler\InterfaceNotFoundException * * @psalm-param class-string|null $classOrInterface */ - protected function prophesize($classOrInterface = null): ObjectProphecy + protected function prophesize(?string $classOrInterface = null): ObjectProphecy { + $this->addWarning('PHPUnit\Framework\TestCase::prophesize() is deprecated and will be removed in PHPUnit 10. Please use the trait provided by phpspec/prophecy-phpunit.'); + if (is_string($classOrInterface)) { $this->recordDoubledType($classOrInterface); } @@ -1968,56 +1971,9 @@ abstract class TestCase extends Assert implements SelfDescribing, Test throw $t; } - private function setExpectedExceptionFromAnnotation(): void + protected function recordDoubledType(string $originalClassName): void { - if ($this->name === null) { - return; - } - - try { - $expectedException = TestUtil::getExpectedException( - static::class, - $this->name - ); - - if ($expectedException !== false) { - $this->addWarning('The @expectedException, @expectedExceptionCode, @expectedExceptionMessage, and @expectedExceptionMessageRegExp annotations are deprecated. They will be removed in PHPUnit 9. Refactor your test to use expectException(), expectExceptionCode(), expectExceptionMessage(), or expectExceptionMessageMatches() instead.'); - - $this->expectException($expectedException['class']); - - if ($expectedException['code'] !== null) { - $this->expectExceptionCode($expectedException['code']); - } - - if ($expectedException['message'] !== '') { - $this->expectExceptionMessage($expectedException['message']); - } elseif ($expectedException['message_regex'] !== '') { - $this->expectExceptionMessageMatches($expectedException['message_regex']); - } - } - } catch (UtilException $e) { - } - } - - /** - * @throws SkippedTestError - * @throws SyntheticSkippedError - * @throws Warning - */ - private function checkRequirements(): void - { - if (!$this->name || !method_exists($this, $this->name)) { - return; - } - - $missingRequirements = TestUtil::getMissingRequirements( - static::class, - $this->name - ); - - if (!empty($missingRequirements)) { - $this->markTestSkipped(implode(PHP_EOL, $missingRequirements)); - } + $this->doubledTypes[] = $originalClassName; } /** @@ -2042,8 +1998,7 @@ abstract class TestCase extends Assert implements SelfDescribing, Test foreach ($this->prophet->getProphecies() as $objectProphecy) { foreach ($objectProphecy->getMethodProphecies() as $methodProphecies) { foreach ($methodProphecies as $methodProphecy) { - assert($methodProphecy instanceof MethodProphecy); - + /* @var MethodProphecy $methodProphecy */ $this->numAssertions += count($methodProphecy->getCheckedPredictions()); } } @@ -2052,90 +2007,105 @@ abstract class TestCase extends Assert implements SelfDescribing, Test } } + /** + * @throws SkippedTestError + * @throws SyntheticSkippedError + * @throws Warning + */ + private function checkRequirements(): void + { + if (!$this->name || !method_exists($this, $this->name)) { + return; + } + + $missingRequirements = TestUtil::getMissingRequirements( + static::class, + $this->name + ); + + if (!empty($missingRequirements)) { + $this->markTestSkipped(implode(PHP_EOL, $missingRequirements)); + } + } + private function handleDependencies(): bool { - if (!empty($this->dependencies) && !$this->inIsolation) { - $passed = $this->result->passed(); - $passedKeys = array_keys($passed); + if ([] === $this->dependencies || $this->inIsolation) { + return true; + } - foreach ($passedKeys as $key => $value) { - $pos = strpos($value, ' with data set'); + $passed = $this->result->passed(); + $passedKeys = array_keys($passed); + $numKeys = count($passedKeys); - if ($pos !== false) { - $passedKeys[$key] = substr($value, 0, $pos); - } + for ($i = 0; $i < $numKeys; $i++) { + $pos = strpos($passedKeys[$i], ' with data set'); + + if ($pos !== false) { + $passedKeys[$i] = substr($passedKeys[$i], 0, $pos); + } + } + + $passedKeys = array_flip(array_unique($passedKeys)); + + foreach ($this->dependencies as $dependency) { + if (!$dependency->isValid()) { + $this->markSkippedForNotSpecifyingDependency(); + + return false; } - $passedKeys = array_flip(array_unique($passedKeys)); + if ($dependency->targetIsClass()) { + $dependencyClassName = $dependency->getTargetClassName(); - foreach ($this->dependencies as $dependency) { - $deepClone = false; - $shallowClone = false; - - if (empty($dependency)) { - $this->markSkippedForNotSpecifyingDependency(); + if (array_search($dependencyClassName, $this->result->passedClasses(), true) === false) { + $this->markSkippedForMissingDependency($dependency); return false; } - if (strpos($dependency, 'clone ') === 0) { - $deepClone = true; - $dependency = substr($dependency, strlen('clone ')); - } elseif (strpos($dependency, '!clone ') === 0) { - $deepClone = false; - $dependency = substr($dependency, strlen('!clone ')); - } + continue; + } - if (strpos($dependency, 'shallowClone ') === 0) { - $shallowClone = true; - $dependency = substr($dependency, strlen('shallowClone ')); - } elseif (strpos($dependency, '!shallowClone ') === 0) { - $shallowClone = false; - $dependency = substr($dependency, strlen('!shallowClone ')); - } + $dependencyTarget = $dependency->getTarget(); - if (strpos($dependency, '::') === false) { - $dependency = static::class . '::' . $dependency; - } - - if (!isset($passedKeys[$dependency])) { - if (!$this->isCallableTestMethod($dependency)) { - $this->warnAboutDependencyThatDoesNotExist($dependency); - } else { - $this->markSkippedForMissingDependency($dependency); - } - - return false; - } - - if (isset($passed[$dependency])) { - if ($passed[$dependency]['size'] !== TestUtil::UNKNOWN && - $this->getSize() !== TestUtil::UNKNOWN && - $passed[$dependency]['size'] > $this->getSize()) { - $this->result->addError( - $this, - new SkippedTestError( - 'This test depends on a test that is larger than itself.' - ), - 0 - ); - - return false; - } - - if ($deepClone) { - $deepCopy = new DeepCopy; - $deepCopy->skipUncloneable(false); - - $this->dependencyInput[$dependency] = $deepCopy->copy($passed[$dependency]['result']); - } elseif ($shallowClone) { - $this->dependencyInput[$dependency] = clone $passed[$dependency]['result']; - } else { - $this->dependencyInput[$dependency] = $passed[$dependency]['result']; - } + if (!isset($passedKeys[$dependencyTarget])) { + if (!$this->isCallableTestMethod($dependencyTarget)) { + $this->markWarningForUncallableDependency($dependency); } else { - $this->dependencyInput[$dependency] = null; + $this->markSkippedForMissingDependency($dependency); } + + return false; + } + + if (isset($passed[$dependencyTarget])) { + if ($passed[$dependencyTarget]['size'] != \PHPUnit\Util\Test::UNKNOWN && + $this->getSize() != \PHPUnit\Util\Test::UNKNOWN && + $passed[$dependencyTarget]['size'] > $this->getSize()) { + $this->result->addError( + $this, + new SkippedTestError( + 'This test depends on a test that is larger than itself.' + ), + 0 + ); + + return false; + } + + if ($dependency->useDeepClone()) { + $deepCopy = new DeepCopy; + $deepCopy->skipUncloneable(false); + + $this->dependencyInput[$dependencyTarget] = $deepCopy->copy($passed[$dependencyTarget]['result']); + } elseif ($dependency->useShallowClone()) { + $this->dependencyInput[$dependencyTarget] = clone $passed[$dependencyTarget]['result']; + } else { + $this->dependencyInput[$dependencyTarget] = $passed[$dependencyTarget]['result']; + } + } else { + $this->dependencyInput[$dependencyTarget] = null; } } @@ -2159,7 +2129,7 @@ abstract class TestCase extends Assert implements SelfDescribing, Test $this->result->endTest($this, 0); } - private function markSkippedForMissingDependency(string $dependency): void + private function markSkippedForMissingDependency(ExecutionOrderDependency $dependency): void { $this->status = BaseTestRunner::STATUS_SKIPPED; @@ -2170,7 +2140,7 @@ abstract class TestCase extends Assert implements SelfDescribing, Test new SkippedTestError( sprintf( 'This test depends on "%s" to pass.', - $dependency + $dependency->getTarget() ) ), 0 @@ -2179,7 +2149,7 @@ abstract class TestCase extends Assert implements SelfDescribing, Test $this->result->endTest($this, 0); } - private function warnAboutDependencyThatDoesNotExist(string $dependency): void + private function markWarningForUncallableDependency(ExecutionOrderDependency $dependency): void { $this->status = BaseTestRunner::STATUS_WARNING; @@ -2190,7 +2160,7 @@ abstract class TestCase extends Assert implements SelfDescribing, Test new Warning( sprintf( 'This test depends on "%s" which does not exist.', - $dependency + $dependency->getTarget() ) ), 0 @@ -2296,34 +2266,51 @@ abstract class TestCase extends Assert implements SelfDescribing, Test private function createGlobalStateSnapshot(bool $backupGlobals): Snapshot { - $blacklist = new Blacklist; + $excludeList = new ExcludeList; - foreach ($this->backupGlobalsBlacklist as $globalVariable) { - $blacklist->addGlobalVariable($globalVariable); + foreach ($this->backupGlobalsExcludeList as $globalVariable) { + $excludeList->addGlobalVariable($globalVariable); + } + + if (!empty($this->backupGlobalsBlacklist)) { + $this->addWarning('PHPUnit\Framework\TestCase::$backupGlobalsBlacklist is deprecated and will be removed in PHPUnit 10. Please use PHPUnit\Framework\TestCase::$backupGlobalsExcludeList instead.'); + + foreach ($this->backupGlobalsBlacklist as $globalVariable) { + $excludeList->addGlobalVariable($globalVariable); + } } if (!defined('PHPUNIT_TESTSUITE')) { - $blacklist->addClassNamePrefix('PHPUnit'); - $blacklist->addClassNamePrefix('SebastianBergmann\CodeCoverage'); - $blacklist->addClassNamePrefix('SebastianBergmann\FileIterator'); - $blacklist->addClassNamePrefix('SebastianBergmann\Invoker'); - $blacklist->addClassNamePrefix('SebastianBergmann\Timer'); - $blacklist->addClassNamePrefix('PHP_Token'); - $blacklist->addClassNamePrefix('Symfony'); - $blacklist->addClassNamePrefix('Text_Template'); - $blacklist->addClassNamePrefix('Doctrine\Instantiator'); - $blacklist->addClassNamePrefix('Prophecy'); - $blacklist->addStaticAttribute(ComparatorFactory::class, 'instance'); + $excludeList->addClassNamePrefix('PHPUnit'); + $excludeList->addClassNamePrefix('SebastianBergmann\CodeCoverage'); + $excludeList->addClassNamePrefix('SebastianBergmann\FileIterator'); + $excludeList->addClassNamePrefix('SebastianBergmann\Invoker'); + $excludeList->addClassNamePrefix('SebastianBergmann\Template'); + $excludeList->addClassNamePrefix('SebastianBergmann\Timer'); + $excludeList->addClassNamePrefix('Symfony'); + $excludeList->addClassNamePrefix('Doctrine\Instantiator'); + $excludeList->addClassNamePrefix('Prophecy'); + $excludeList->addStaticAttribute(ComparatorFactory::class, 'instance'); - foreach ($this->backupStaticAttributesBlacklist as $class => $attributes) { + foreach ($this->backupStaticAttributesExcludeList as $class => $attributes) { foreach ($attributes as $attribute) { - $blacklist->addStaticAttribute($class, $attribute); + $excludeList->addStaticAttribute($class, $attribute); + } + } + + if (!empty($this->backupStaticAttributesBlacklist)) { + $this->addWarning('PHPUnit\Framework\TestCase::$backupStaticAttributesBlacklist is deprecated and will be removed in PHPUnit 10. Please use PHPUnit\Framework\TestCase::$backupStaticAttributesExcludeList instead.'); + + foreach ($this->backupStaticAttributesBlacklist as $class => $attributes) { + foreach ($attributes as $attribute) { + $excludeList->addStaticAttribute($class, $attribute); + } } } } return new Snapshot( - $blacklist, + $excludeList, $backupGlobals, (bool) $this->backupStaticAttributes, false, @@ -2451,7 +2438,10 @@ abstract class TestCase extends Assert implements SelfDescribing, Test private function setDoesNotPerformAssertionsFromAnnotation(): void { - $annotations = $this->getAnnotations(); + $annotations = TestUtil::parseTestMethodAnnotations( + static::class, + $this->name + ); if (isset($annotations['method']['doesNotPerformAssertions'])) { $this->doesNotPerformAssertions = true; @@ -2531,24 +2521,6 @@ abstract class TestCase extends Assert implements SelfDescribing, Test !$this->inIsolation && !$this instanceof PhptTestCase; } - /** - * @param string|string[] $originalClassName - */ - private function recordDoubledType($originalClassName): void - { - if (is_string($originalClassName)) { - $this->doubledTypes[] = $originalClassName; - } - - if (is_array($originalClassName)) { - foreach ($originalClassName as $_originalClassName) { - if (is_string($_originalClassName)) { - $this->doubledTypes[] = $_originalClassName; - } - } - } - } - private function isCallableTestMethod(string $dependency): bool { [$className, $methodName] = explode('::', $dependency); @@ -2579,4 +2551,19 @@ abstract class TestCase extends Assert implements SelfDescribing, Test return TestUtil::isTestMethod($method); } + + /** + * @psalm-template RealInstanceType of object + * @psalm-param class-string $originalClassName + * @psalm-return MockObject&RealInstanceType + */ + private function createMockObject(string $originalClassName): MockObject + { + return $this->getMockBuilder($originalClassName) + ->disableOriginalConstructor() + ->disableOriginalClone() + ->disableArgumentCloning() + ->disallowMockingUnknownTypes() + ->getMock(); + } } diff --git a/vendor/phpunit/phpunit/src/Framework/TestFailure.php b/vendor/phpunit/phpunit/src/Framework/TestFailure.php index 5849d36ed..0764bc789 100644 --- a/vendor/phpunit/phpunit/src/Framework/TestFailure.php +++ b/vendor/phpunit/phpunit/src/Framework/TestFailure.php @@ -71,10 +71,8 @@ final class TestFailure /** * Constructs a TestFailure with the given test and exception. - * - * @param Throwable $t */ - public function __construct(Test $failedTest, $t) + public function __construct(Test $failedTest, Throwable $t) { if ($failedTest instanceof SelfDescribing) { $this->testName = $failedTest->toString(); diff --git a/vendor/phpunit/phpunit/src/Framework/TestListener.php b/vendor/phpunit/phpunit/src/Framework/TestListener.php index 96ce4eec7..aaf5e7cd9 100644 --- a/vendor/phpunit/phpunit/src/Framework/TestListener.php +++ b/vendor/phpunit/phpunit/src/Framework/TestListener.php @@ -13,6 +13,7 @@ use Throwable; /** * @deprecated Use the `TestHook` interfaces instead + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ interface TestListener { diff --git a/vendor/phpunit/phpunit/src/Framework/TestListenerDefaultImplementation.php b/vendor/phpunit/phpunit/src/Framework/TestListenerDefaultImplementation.php index 7c99f5cb2..3e56708b6 100644 --- a/vendor/phpunit/phpunit/src/Framework/TestListenerDefaultImplementation.php +++ b/vendor/phpunit/phpunit/src/Framework/TestListenerDefaultImplementation.php @@ -13,6 +13,7 @@ use Throwable; /** * @deprecated The `TestListener` interface is deprecated + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ trait TestListenerDefaultImplementation { diff --git a/vendor/phpunit/phpunit/src/Framework/TestResult.php b/vendor/phpunit/phpunit/src/Framework/TestResult.php index 8c333b540..fc00628f1 100644 --- a/vendor/phpunit/phpunit/src/Framework/TestResult.php +++ b/vendor/phpunit/phpunit/src/Framework/TestResult.php @@ -10,29 +10,21 @@ namespace PHPUnit\Framework; use const PHP_EOL; -use function class_exists; use function count; -use function extension_loaded; use function function_exists; use function get_class; use function sprintf; -use function xdebug_get_monitored_functions; -use function xdebug_start_function_monitor; -use function xdebug_stop_function_monitor; use AssertionError; use Countable; use Error; -use PHPUnit\Framework\MockObject\Exception as MockObjectException; -use PHPUnit\Util\Blacklist; use PHPUnit\Util\ErrorHandler; +use PHPUnit\Util\ExcludeList; use PHPUnit\Util\Printer; use PHPUnit\Util\Test as TestUtil; use ReflectionClass; use ReflectionException; use SebastianBergmann\CodeCoverage\CodeCoverage; -use SebastianBergmann\CodeCoverage\CoveredCodeNotExecutedException as OriginalCoveredCodeNotExecutedException; use SebastianBergmann\CodeCoverage\Exception as OriginalCodeCoverageException; -use SebastianBergmann\CodeCoverage\MissingCoversAnnotationException as OriginalMissingCoversAnnotationException; use SebastianBergmann\CodeCoverage\UnintentionallyCoveredCodeException; use SebastianBergmann\Invoker\Invoker; use SebastianBergmann\Invoker\TimeoutException; @@ -50,6 +42,16 @@ final class TestResult implements Countable */ private $passed = []; + /** + * @var array + */ + private $passedTestClasses = []; + + /** + * @var bool + */ + private $currentTestSuiteFailed = false; + /** * @var TestFailure[] */ @@ -97,11 +99,6 @@ final class TestResult implements Countable */ private $time = 0; - /** - * @var TestSuite - */ - private $topTestSuite; - /** * Code Coverage information. * @@ -174,6 +171,11 @@ final class TestResult implements Countable */ private $enforceTimeLimit = false; + /** + * @var bool + */ + private $forceCoversAnnotation = false; + /** * @var int */ @@ -274,8 +276,9 @@ final class TestResult implements Countable public function addError(Test $test, Throwable $t, float $time): void { if ($t instanceof RiskyTestError) { - $this->risky[] = new TestFailure($test, $t); - $notifyMethod = 'addRiskyTest'; + $this->recordRisky($test, $t); + + $notifyMethod = 'addRiskyTest'; if ($test instanceof TestCase) { $test->markAsRisky(); @@ -285,22 +288,25 @@ final class TestResult implements Countable $this->stop(); } } elseif ($t instanceof IncompleteTest) { - $this->notImplemented[] = new TestFailure($test, $t); - $notifyMethod = 'addIncompleteTest'; + $this->recordNotImplemented($test, $t); + + $notifyMethod = 'addIncompleteTest'; if ($this->stopOnIncomplete) { $this->stop(); } } elseif ($t instanceof SkippedTest) { - $this->skipped[] = new TestFailure($test, $t); - $notifyMethod = 'addSkippedTest'; + $this->recordSkipped($test, $t); + + $notifyMethod = 'addSkippedTest'; if ($this->stopOnSkipped) { $this->stop(); } } else { - $this->errors[] = new TestFailure($test, $t); - $notifyMethod = 'addError'; + $this->recordError($test, $t); + + $notifyMethod = 'addError'; if ($this->stopOnError || $this->stopOnFailure) { $this->stop(); @@ -330,7 +336,7 @@ final class TestResult implements Countable $this->stop(); } - $this->warnings[] = new TestFailure($test, $e); + $this->recordWarning($test, $e); foreach ($this->listeners as $listener) { $listener->addWarning($test, $e, $time); @@ -346,8 +352,9 @@ final class TestResult implements Countable public function addFailure(Test $test, AssertionFailedError $e, float $time): void { if ($e instanceof RiskyTestError || $e instanceof OutputError) { - $this->risky[] = new TestFailure($test, $e); - $notifyMethod = 'addRiskyTest'; + $this->recordRisky($test, $e); + + $notifyMethod = 'addRiskyTest'; if ($test instanceof TestCase) { $test->markAsRisky(); @@ -357,15 +364,17 @@ final class TestResult implements Countable $this->stop(); } } elseif ($e instanceof IncompleteTest) { - $this->notImplemented[] = new TestFailure($test, $e); - $notifyMethod = 'addIncompleteTest'; + $this->recordNotImplemented($test, $e); + + $notifyMethod = 'addIncompleteTest'; if ($this->stopOnIncomplete) { $this->stop(); } } elseif ($e instanceof SkippedTest) { - $this->skipped[] = new TestFailure($test, $e); - $notifyMethod = 'addSkippedTest'; + $this->recordSkipped($test, $e); + + $notifyMethod = 'addSkippedTest'; if ($this->stopOnSkipped) { $this->stop(); @@ -392,9 +401,7 @@ final class TestResult implements Countable */ public function startTestSuite(TestSuite $suite): void { - if ($this->topTestSuite === null) { - $this->topTestSuite = $suite; - } + $this->currentTestSuiteFailed = false; foreach ($this->listeners as $listener) { $listener->startTestSuite($suite); @@ -406,6 +413,10 @@ final class TestResult implements Countable */ public function endTestSuite(TestSuite $suite): void { + if (!$this->currentTestSuiteFailed) { + $this->passedTestClasses[] = $suite->getName(); + } + foreach ($this->listeners as $listener) { $listener->endTestSuite($suite); } @@ -449,6 +460,10 @@ final class TestResult implements Countable $this->time += $time; } + + if ($this->lastTestFailed && $test instanceof TestCase) { + $this->currentTestSuiteFailed = true; + } } /** @@ -456,7 +471,7 @@ final class TestResult implements Countable */ public function allHarmless(): bool { - return $this->riskyCount() == 0; + return $this->riskyCount() === 0; } /** @@ -472,7 +487,7 @@ final class TestResult implements Countable */ public function allCompletelyImplemented(): bool { - return $this->notImplementedCount() == 0; + return $this->notImplementedCount() === 0; } /** @@ -508,7 +523,7 @@ final class TestResult implements Countable */ public function noneSkipped(): bool { - return $this->skippedCount() == 0; + return $this->skippedCount() === 0; } /** @@ -592,11 +607,13 @@ final class TestResult implements Countable } /** - * Returns the (top) test suite. + * Returns the names of the TestSuites that have passed. + * + * This enables @depends-annotations for TestClassName::class */ - public function topTestSuite(): TestSuite + public function passedClasses(): array { - return $this->topTestSuite; + return $this->passedTestClasses; } /** @@ -611,11 +628,8 @@ final class TestResult implements Countable * Runs a TestCase. * * @throws \SebastianBergmann\CodeCoverage\InvalidArgumentException - * @throws \SebastianBergmann\CodeCoverage\RuntimeException * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws CodeCoverageException - * @throws OriginalCoveredCodeNotExecutedException - * @throws OriginalMissingCoversAnnotationException * @throws UnintentionallyCoveredCodeException */ public function run(Test $test): void @@ -651,6 +665,7 @@ final class TestResult implements Countable } $collectCodeCoverage = $this->codeCoverage !== null && + !$test instanceof ErrorTestCase && !$test instanceof WarningTestCase && $isAnyCoverageRequired; @@ -659,22 +674,27 @@ final class TestResult implements Countable } $monitorFunctions = $this->beStrictAboutResourceUsageDuringSmallTests && - !$test instanceof WarningTestCase && - $test->getSize() == \PHPUnit\Util\Test::SMALL && - function_exists('xdebug_start_function_monitor'); + !$test instanceof ErrorTestCase && + !$test instanceof WarningTestCase && + $test->getSize() === \PHPUnit\Util\Test::SMALL && + function_exists('xdebug_start_function_monitor'); if ($monitorFunctions) { /* @noinspection ForgottenDebugOutputInspection */ xdebug_start_function_monitor(ResourceOperations::getFunctions()); } - Timer::start(); + $timer = new Timer; + $timer->start(); try { - if (!$test instanceof WarningTestCase && + $invoker = new Invoker; + + if (!$test instanceof ErrorTestCase && + !$test instanceof WarningTestCase && $this->enforceTimeLimit && ($this->defaultTimeLimit || $test->getSize() != \PHPUnit\Util\Test::UNKNOWN) && - extension_loaded('pcntl') && class_exists(Invoker::class)) { + $invoker->canInvokeWithTimeout()) { switch ($test->getSize()) { case \PHPUnit\Util\Test::SMALL: $_timeout = $this->timeoutForSmallTests; @@ -697,7 +717,6 @@ final class TestResult implements Countable break; } - $invoker = new Invoker; $invoker->invoke([$test, 'runBare'], [], $_timeout); } else { $test->runBare(); @@ -712,12 +731,6 @@ final class TestResult implements Countable ); $risky = true; - } catch (MockObjectException $e) { - $e = new Warning( - $e->getMessage() - ); - - $warning = true; } catch (AssertionFailedError $e) { $failure = true; @@ -751,11 +764,12 @@ final class TestResult implements Countable $error = true; } - $time = Timer::stop(); + $time = $timer->stop()->asSeconds(); + $test->addToAssertionCount(Assert::getCount()); if ($monitorFunctions) { - $blacklist = new Blacklist; + $excludeList = new ExcludeList; /** @noinspection ForgottenDebugOutputInspection */ $functions = xdebug_get_monitored_functions(); @@ -764,7 +778,7 @@ final class TestResult implements Countable xdebug_stop_function_monitor(); foreach ($functions as $function) { - if (!$blacklist->isBlacklisted($function['filename'])) { + if (!$excludeList->isExcluded($function['filename'])) { $this->addFailure( $test, new RiskyTestError( @@ -782,10 +796,32 @@ final class TestResult implements Countable } if ($this->beStrictAboutTestsThatDoNotTestAnything && - $test->getNumAssertions() == 0) { + $test->getNumAssertions() === 0) { $risky = true; } + if ($this->forceCoversAnnotation && !$error && !$failure && !$warning && !$incomplete && !$skipped && !$risky) { + $annotations = TestUtil::parseTestMethodAnnotations( + get_class($test), + $test->getName(false) + ); + + if (!isset($annotations['class']['covers']) && + !isset($annotations['method']['covers']) && + !isset($annotations['class']['coversNothing']) && + !isset($annotations['method']['coversNothing'])) { + $this->addFailure( + $test, + new MissingCoversAnnotationException( + 'This test does not have a @covers annotation but is expected to have one' + ), + $time + ); + + $risky = true; + } + } + if ($collectCodeCoverage) { $append = !$risky && !$incomplete && !$skipped; $linesToBeCovered = []; @@ -820,33 +856,10 @@ final class TestResult implements Countable $linesToBeUsed ); } catch (UnintentionallyCoveredCodeException $cce) { - $this->addFailure( - $test, - new UnintentionallyCoveredCodeError( - 'This test executed code that is not listed as code to be covered or used:' . - PHP_EOL . $cce->getMessage() - ), - $time + $unintentionallyCoveredCodeError = new UnintentionallyCoveredCodeError( + 'This test executed code that is not listed as code to be covered or used:' . + PHP_EOL . $cce->getMessage() ); - } catch (OriginalCoveredCodeNotExecutedException $cce) { - $this->addFailure( - $test, - new CoveredCodeNotExecutedException( - 'This test did not execute all the code that is listed as code to be covered:' . - PHP_EOL . $cce->getMessage() - ), - $time - ); - } catch (OriginalMissingCoversAnnotationException $cce) { - if ($linesToBeCovered !== false) { - $this->addFailure( - $test, - new MissingCoversAnnotationException( - 'This test does not have a @covers annotation but is expected to have one' - ), - $time - ); - } } catch (OriginalCodeCoverageException $cce) { $error = true; @@ -866,9 +879,15 @@ final class TestResult implements Countable $this->addFailure($test, $e, $time); } elseif ($warning) { $this->addWarning($test, $e, $time); + } elseif (isset($unintentionallyCoveredCodeError)) { + $this->addFailure( + $test, + $unintentionallyCoveredCodeError, + $time + ); } elseif ($this->beStrictAboutTestsThatDoNotTestAnything && !$test->doesNotPerformAssertions() && - $test->getNumAssertions() == 0) { + $test->getNumAssertions() === 0) { try { $reflected = new ReflectionClass($test); // @codeCoverageIgnoreStart @@ -933,7 +952,10 @@ final class TestResult implements Countable $time ); } elseif ($this->beStrictAboutTodoAnnotatedTests && $test instanceof TestCase) { - $annotations = $test->getAnnotations(); + $annotations = TestUtil::parseTestMethodAnnotations( + get_class($test), + $test->getName(false) + ); if (isset($annotations['method']['todo'])) { $this->addFailure( @@ -1127,6 +1149,16 @@ final class TestResult implements Countable return $this->beStrictAboutTodoAnnotatedTests; } + public function forceCoversAnnotation(): void + { + $this->forceCoversAnnotation = true; + } + + public function forcesCoversAnnotation(): bool + { + return $this->forceCoversAnnotation; + } + /** * Enables or disables the stopping for risky tests. */ @@ -1229,4 +1261,29 @@ final class TestResult implements Countable { $this->registerMockObjectsFromTestArgumentsRecursively = $flag; } + + private function recordError(Test $test, Throwable $t): void + { + $this->errors[] = new TestFailure($test, $t); + } + + private function recordNotImplemented(Test $test, Throwable $t): void + { + $this->notImplemented[] = new TestFailure($test, $t); + } + + private function recordRisky(Test $test, Throwable $t): void + { + $this->risky[] = new TestFailure($test, $t); + } + + private function recordSkipped(Test $test, Throwable $t): void + { + $this->skipped[] = new TestFailure($test, $t); + } + + private function recordWarning(Test $test, Throwable $t): void + { + $this->warnings[] = new TestFailure($test, $t); + } } diff --git a/vendor/phpunit/phpunit/src/Framework/TestSuite.php b/vendor/phpunit/phpunit/src/Framework/TestSuite.php index 144cb6f1b..16422562c 100644 --- a/vendor/phpunit/phpunit/src/Framework/TestSuite.php +++ b/vendor/phpunit/phpunit/src/Framework/TestSuite.php @@ -12,22 +12,26 @@ namespace PHPUnit\Framework; use const PHP_EOL; use function array_diff; use function array_keys; +use function array_map; use function array_merge; +use function array_unique; use function basename; use function call_user_func; use function class_exists; use function count; use function dirname; -use function file_exists; use function get_declared_classes; use function implode; use function is_bool; +use function is_callable; +use function is_file; use function is_object; use function is_string; use function method_exists; use function preg_match; use function preg_quote; use function sprintf; +use function strpos; use function substr; use Iterator; use IteratorAggregate; @@ -44,7 +48,7 @@ use Throwable; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ -class TestSuite implements IteratorAggregate, SelfDescribing, Test +class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test { /** * Enable or disable the backup and restoration of the $GLOBALS array. @@ -75,7 +79,7 @@ class TestSuite implements IteratorAggregate, SelfDescribing, Test /** * The test groups of the test suite. * - * @var array + * @psalm-var array> */ protected $groups = []; @@ -104,11 +108,14 @@ class TestSuite implements IteratorAggregate, SelfDescribing, Test protected $foundClasses = []; /** - * Last count of tests in this suite. - * - * @var null|int + * @var null|list */ - private $cachedNumTests; + protected $providedTests; + + /** + * @var null|list + */ + protected $requiredTests; /** * @var bool @@ -126,7 +133,12 @@ class TestSuite implements IteratorAggregate, SelfDescribing, Test private $declaredClasses; /** - * Constructs a new TestSuite:. + * @psalm-var array + */ + private $warnings = []; + + /** + * Constructs a new TestSuite. * * - PHPUnit\Framework\TestSuite() constructs an empty TestSuite. * @@ -165,7 +177,6 @@ class TestSuite implements IteratorAggregate, SelfDescribing, Test try { $theClass = new ReflectionClass($theClass); - // @codeCoverageIgnoreStart } catch (ReflectionException $e) { throw new Exception( $e->getMessage(), @@ -267,15 +278,15 @@ class TestSuite implements IteratorAggregate, SelfDescribing, Test // @codeCoverageIgnoreEnd if (!$class->isAbstract()) { - $this->tests[] = $test; - $this->numTests = -1; + $this->tests[] = $test; + $this->clearCaches(); if ($test instanceof self && empty($groups)) { $groups = $test->getGroups(); } - if (empty($groups)) { - $groups = ['default']; + if ($this->containsOnlyVirtualGroups($groups)) { + $groups[] = 'default'; } foreach ($groups as $group) { @@ -295,7 +306,7 @@ class TestSuite implements IteratorAggregate, SelfDescribing, Test /** * Adds the tests from the given class to the suite. * - * @param object|string $testClass + * @psalm-param object|class-string $testClass * * @throws Exception */ @@ -359,6 +370,11 @@ class TestSuite implements IteratorAggregate, SelfDescribing, Test } } + public function addWarning(string $warning): void + { + $this->warnings[] = $warning; + } + /** * Wraps both addTest() and addTestSuite * as well as the separate import statements for the user's convenience. @@ -371,14 +387,16 @@ class TestSuite implements IteratorAggregate, SelfDescribing, Test */ public function addTestFile(string $filename): void { - if (file_exists($filename) && substr($filename, -5) === '.phpt') { - $this->addTest( - new PhptTestCase($filename) - ); + if (is_file($filename) && substr($filename, -5) === '.phpt') { + $this->addTest(new PhptTestCase($filename)); + + $this->declaredClasses = get_declared_classes(); return; } + $numTests = count($this->tests); + // The given file may contain further stub classes in addition to the // test class itself. Figure out the actual test class. $filename = FileLoader::checkAndLoad($filename); @@ -463,11 +481,41 @@ class TestSuite implements IteratorAggregate, SelfDescribing, Test $this->addTest($method->invoke(null, $className)); } } elseif ($class->implementsInterface(Test::class)) { + $expectedClassName = $shortName; + + if (($pos = strpos($expectedClassName, '.')) !== false) { + $expectedClassName = substr( + $expectedClassName, + 0, + $pos + ); + } + + if ($class->getShortName() !== $expectedClassName) { + $this->addWarning( + sprintf( + "Test case class not matching filename is deprecated\n in %s\n Class name was '%s', expected '%s'", + $filename, + $class->getShortName(), + $expectedClassName + ) + ); + } + $this->addTestSuite($class); } } } + if (count($this->tests) > ++$numTests) { + $this->addWarning( + sprintf( + "Multiple test case classes per file is deprecated\n in %s", + $filename + ) + ); + } + $this->numTests = -1; } @@ -485,22 +533,18 @@ class TestSuite implements IteratorAggregate, SelfDescribing, Test /** * Counts the number of test cases that will be run by this test. + * + * @todo refactor usage of numTests in DefaultResultPrinter */ - public function count(bool $preferCache = false): int + public function count(): int { - if ($preferCache && $this->cachedNumTests !== null) { - return $this->cachedNumTests; - } - - $numTests = 0; + $this->numTests = 0; foreach ($this as $test) { - $numTests += count($test); + $this->numTests += count($test); } - $this->cachedNumTests = $numTests; - - return $numTests; + return $this->numTests; } /** @@ -513,10 +557,17 @@ class TestSuite implements IteratorAggregate, SelfDescribing, Test /** * Returns the test groups of the suite. + * + * @psalm-return list */ public function getGroups(): array { - return array_keys($this->groups); + return array_map( + static function ($key): string { + return (string) $key; + }, + array_keys($this->groups) + ); } public function getGroupDetails(): array @@ -536,10 +587,7 @@ class TestSuite implements IteratorAggregate, SelfDescribing, Test * Runs the tests and collects their result in a TestResult. * * @throws \PHPUnit\Framework\CodeCoverageException - * @throws \SebastianBergmann\CodeCoverage\CoveredCodeNotExecutedException * @throws \SebastianBergmann\CodeCoverage\InvalidArgumentException - * @throws \SebastianBergmann\CodeCoverage\MissingCoversAnnotationException - * @throws \SebastianBergmann\CodeCoverage\RuntimeException * @throws \SebastianBergmann\CodeCoverage\UnintentionallyCoveredCodeException * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws Warning @@ -560,56 +608,58 @@ class TestSuite implements IteratorAggregate, SelfDescribing, Test $result->startTestSuite($this); - try { - foreach ($hookMethods['beforeClass'] as $beforeClassMethod) { - if ($this->testCase && - class_exists($this->name, false) && - method_exists($this->name, $beforeClassMethod)) { - if ($missingRequirements = TestUtil::getMissingRequirements($this->name, $beforeClassMethod)) { - $this->markTestSuiteSkipped(implode(PHP_EOL, $missingRequirements)); + $test = null; + + if ($this->testCase && class_exists($this->name, false)) { + try { + foreach ($hookMethods['beforeClass'] as $beforeClassMethod) { + if (method_exists($this->name, $beforeClassMethod)) { + if ($missingRequirements = TestUtil::getMissingRequirements($this->name, $beforeClassMethod)) { + $this->markTestSuiteSkipped(implode(PHP_EOL, $missingRequirements)); + } + + call_user_func([$this->name, $beforeClassMethod]); + } + } + } catch (SkippedTestSuiteError $error) { + foreach ($this->tests() as $test) { + $result->startTest($test); + $result->addFailure($test, $error, 0); + $result->endTest($test, 0); + } + + $result->endTestSuite($this); + + return $result; + } catch (Throwable $t) { + $errorAdded = false; + + foreach ($this->tests() as $test) { + if ($result->shouldStop()) { + break; } - call_user_func([$this->name, $beforeClassMethod]); - } - } - } catch (SkippedTestSuiteError $error) { - foreach ($this->tests() as $test) { - $result->startTest($test); - $result->addFailure($test, $error, 0); - $result->endTest($test, 0); - } + $result->startTest($test); - $result->endTestSuite($this); + if (!$errorAdded) { + $result->addError($test, $t, 0); - return $result; - } catch (Throwable $t) { - $errorAdded = false; + $errorAdded = true; + } else { + $result->addFailure( + $test, + new SkippedTestError('Test skipped because of an error in hook method'), + 0 + ); + } - foreach ($this->tests() as $test) { - if ($result->shouldStop()) { - break; + $result->endTest($test, 0); } - $result->startTest($test); + $result->endTestSuite($this); - if (!$errorAdded) { - $result->addError($test, $t, 0); - - $errorAdded = true; - } else { - $result->addFailure( - $test, - new SkippedTestError('Test skipped because of an error in hook method'), - 0 - ); - } - - $result->endTest($test, 0); + return $result; } - - $result->endTestSuite($this); - - return $result; } foreach ($this as $test) { @@ -627,24 +677,24 @@ class TestSuite implements IteratorAggregate, SelfDescribing, Test $test->run($result); } - try { + if ($this->testCase && class_exists($this->name, false)) { foreach ($hookMethods['afterClass'] as $afterClassMethod) { - if ($this->testCase && - class_exists($this->name, false) && - method_exists($this->name, $afterClassMethod)) { - call_user_func([$this->name, $afterClassMethod]); + if (method_exists($this->name, $afterClassMethod)) { + try { + call_user_func([$this->name, $afterClassMethod]); + } catch (Throwable $t) { + $message = "Exception in {$this->name}::{$afterClassMethod}" . PHP_EOL . $t->getMessage(); + $error = new SyntheticError($message, 0, $t->getFile(), $t->getLine(), $t->getTrace()); + + $placeholderTest = clone $test; + $placeholderTest->setName($afterClassMethod); + + $result->startTest($placeholderTest); + $result->addFailure($placeholderTest, $error, 0); + $result->endTest($placeholderTest, 0); + } } } - } catch (Throwable $t) { - $message = "Exception in {$this->name}::{$afterClassMethod}" . PHP_EOL . $t->getMessage(); - $error = new SyntheticError($message, 0, $t->getFile(), $t->getLine(), $t->getTrace()); - - $placeholderTest = clone $test; - $placeholderTest->setName($afterClassMethod); - - $result->startTest($placeholderTest); - $result->addFailure($placeholderTest, $error, 0); - $result->endTest($placeholderTest, 0); } $result->endTestSuite($this); @@ -662,16 +712,6 @@ class TestSuite implements IteratorAggregate, SelfDescribing, Test $this->name = $name; } - /** - * Returns the test at the given index. - * - * @return false|Test - */ - public function testAt(int $index) - { - return $this->tests[$index] ?? false; - } - /** * Returns the tests as an enumeration. * @@ -761,6 +801,70 @@ class TestSuite implements IteratorAggregate, SelfDescribing, Test } } + /** + * @psalm-return array + */ + public function warnings(): array + { + return array_unique($this->warnings); + } + + /** + * @return list + */ + public function provides(): array + { + if ($this->providedTests === null) { + $this->providedTests = []; + + if (is_callable($this->sortId(), true)) { + $this->providedTests[] = new ExecutionOrderDependency($this->sortId()); + } + + foreach ($this->tests as $test) { + if (!($test instanceof Reorderable)) { + // @codeCoverageIgnoreStart + continue; + // @codeCoverageIgnoreEnd + } + $this->providedTests = ExecutionOrderDependency::mergeUnique($this->providedTests, $test->provides()); + } + } + + return $this->providedTests; + } + + /** + * @return list + */ + public function requires(): array + { + if ($this->requiredTests === null) { + $this->requiredTests = []; + + foreach ($this->tests as $test) { + if (!($test instanceof Reorderable)) { + // @codeCoverageIgnoreStart + continue; + // @codeCoverageIgnoreEnd + } + $this->requiredTests = ExecutionOrderDependency::mergeUnique( + ExecutionOrderDependency::filterInvalid($this->requiredTests), + $test->requires() + ); + } + + $this->requiredTests = ExecutionOrderDependency::diff($this->requiredTests, $this->provides()); + } + + return $this->requiredTests; + } + + public function sortId(): string + { + return $this->getName() . '::class'; + } + /** * Creates a default TestResult object. */ @@ -774,10 +878,6 @@ class TestSuite implements IteratorAggregate, SelfDescribing, Test */ protected function addTestMethod(ReflectionClass $class, ReflectionMethod $method): void { - if (!TestUtil::isTestMethod($method)) { - return; - } - $methodName = $method->getName(); $test = (new TestBuilder)->build($class, $methodName); @@ -793,4 +893,22 @@ class TestSuite implements IteratorAggregate, SelfDescribing, Test TestUtil::getGroups($class->getName(), $methodName) ); } + + private function clearCaches(): void + { + $this->numTests = -1; + $this->providedTests = null; + $this->requiredTests = null; + } + + private function containsOnlyVirtualGroups(array $groups): bool + { + foreach ($groups as $group) { + if (strpos($group, '__phpunit_') !== 0) { + return false; + } + } + + return true; + } } diff --git a/vendor/phpunit/phpunit/src/Runner/BaseTestRunner.php b/vendor/phpunit/phpunit/src/Runner/BaseTestRunner.php index 3e5e0f71c..75a70ca5f 100644 --- a/vendor/phpunit/phpunit/src/Runner/BaseTestRunner.php +++ b/vendor/phpunit/phpunit/src/Runner/BaseTestRunner.php @@ -11,8 +11,8 @@ namespace PHPUnit\Runner; use function is_dir; use function is_file; +use function substr; use PHPUnit\Framework\Exception; -use PHPUnit\Framework\Test; use PHPUnit\Framework\TestSuite; use ReflectionClass; use ReflectionException; @@ -85,27 +85,33 @@ abstract class BaseTestRunner * * @throws Exception */ - public function getTest(string $suiteClassName, string $suiteClassFile = '', $suffixes = ''): ?Test + public function getTest(string $suiteClassFile, $suffixes = ''): ?TestSuite { - if (empty($suiteClassFile) && is_dir($suiteClassName) && !is_file($suiteClassName . '.php')) { + if (is_dir($suiteClassFile)) { /** @var string[] $files */ $files = (new FileIteratorFacade)->getFilesAsArray( - $suiteClassName, + $suiteClassFile, $suffixes ); - $suite = new TestSuite($suiteClassName); + $suite = new TestSuite($suiteClassFile); $suite->addTestFiles($files); return $suite; } + if (is_file($suiteClassFile) && substr($suiteClassFile, -5, 5) === '.phpt') { + $suite = new TestSuite; + $suite->addTestFile($suiteClassFile); + + return $suite; + } + try { $testClass = $this->loadSuiteClass( - $suiteClassName, $suiteClassFile ); - } catch (Exception $e) { + } catch (\PHPUnit\Exception $e) { $this->runFailed($e->getMessage()); return null; @@ -124,12 +130,7 @@ abstract class BaseTestRunner $test = $suiteMethod->invoke(null, $testClass->getName()); } catch (ReflectionException $e) { - try { - $test = new TestSuite($testClass); - } catch (Exception $e) { - $test = new TestSuite; - $test->setName($suiteClassName); - } + $test = new TestSuite($testClass); } $this->clearStatus(); @@ -140,9 +141,9 @@ abstract class BaseTestRunner /** * Returns the loaded ReflectionClass for a suite name. */ - protected function loadSuiteClass(string $suiteClassName, string $suiteClassFile = ''): ReflectionClass + protected function loadSuiteClass(string $suiteClassFile): ReflectionClass { - return $this->getLoader()->load($suiteClassName, $suiteClassFile); + return $this->getLoader()->load($suiteClassFile); } /** diff --git a/vendor/phpunit/phpunit/src/Runner/Extension/ExtensionHandler.php b/vendor/phpunit/phpunit/src/Runner/Extension/ExtensionHandler.php new file mode 100644 index 000000000..286f717ee --- /dev/null +++ b/vendor/phpunit/phpunit/src/Runner/Extension/ExtensionHandler.php @@ -0,0 +1,117 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Runner\Extension; + +use function class_exists; +use function sprintf; +use PHPUnit\Framework\TestListener; +use PHPUnit\Runner\Exception; +use PHPUnit\Runner\Hook; +use PHPUnit\TextUI\TestRunner; +use PHPUnit\TextUI\XmlConfiguration\Extension; +use ReflectionClass; +use ReflectionException; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class ExtensionHandler +{ + /** + * @throws Exception + */ + public function registerExtension(Extension $extensionConfiguration, TestRunner $runner): void + { + $extension = $this->createInstance($extensionConfiguration); + + if (!$extension instanceof Hook) { + throw new Exception( + sprintf( + 'Class "%s" does not implement a PHPUnit\Runner\Hook interface', + $extensionConfiguration->className() + ) + ); + } + + $runner->addExtension($extension); + } + + /** + * @throws Exception + * + * @deprecated + */ + public function createTestListenerInstance(Extension $listenerConfiguration): TestListener + { + $listener = $this->createInstance($listenerConfiguration); + + if (!$listener instanceof TestListener) { + throw new Exception( + sprintf( + 'Class "%s" does not implement the PHPUnit\Framework\TestListener interface', + $listenerConfiguration->className() + ) + ); + } + + return $listener; + } + + /** + * @throws Exception + */ + private function createInstance(Extension $extensionConfiguration): object + { + $this->ensureClassExists($extensionConfiguration); + + try { + $reflector = new ReflectionClass($extensionConfiguration->className()); + } catch (ReflectionException $e) { + throw new Exception( + $e->getMessage(), + (int) $e->getCode(), + $e + ); + } + + if (!$extensionConfiguration->hasArguments()) { + return $reflector->newInstance(); + } + + return $reflector->newInstanceArgs($extensionConfiguration->arguments()); + } + + /** + * @throws Exception + */ + private function ensureClassExists(Extension $extensionConfiguration): void + { + if (class_exists($extensionConfiguration->className(), false)) { + return; + } + + if ($extensionConfiguration->hasSourceFile()) { + /** + * @noinspection PhpIncludeInspection + * @psalm-suppress UnresolvableInclude + */ + require_once $extensionConfiguration->sourceFile(); + } + + if (!class_exists($extensionConfiguration->className())) { + throw new Exception( + sprintf( + 'Class "%s" does not exist', + $extensionConfiguration->className() + ) + ); + } + } +} diff --git a/vendor/phpunit/phpunit/src/Runner/Extension/PharLoader.php b/vendor/phpunit/phpunit/src/Runner/Extension/PharLoader.php new file mode 100644 index 000000000..adc4cd77c --- /dev/null +++ b/vendor/phpunit/phpunit/src/Runner/Extension/PharLoader.php @@ -0,0 +1,75 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Runner\Extension; + +use PharIo\Manifest\ApplicationName; +use PharIo\Manifest\Exception as ManifestException; +use PharIo\Manifest\ManifestLoader; +use PharIo\Version\Version as PharIoVersion; +use PHPUnit\Runner\Version; +use SebastianBergmann\FileIterator\Facade as FileIteratorFacade; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class PharLoader +{ + /** + * @psalm-return array{loadedExtensions: list, notLoadedExtensions: list} + */ + public function loadPharExtensionsInDirectory(string $directory): array + { + $loadedExtensions = []; + $notLoadedExtensions = []; + + foreach ((new FileIteratorFacade)->getFilesAsArray($directory, '.phar') as $file) { + if (!is_file('phar://' . $file . '/manifest.xml')) { + $notLoadedExtensions[] = $file . ' is not an extension for PHPUnit'; + + continue; + } + + try { + $applicationName = new ApplicationName('phpunit/phpunit'); + $version = new PharIoVersion(Version::series()); + $manifest = ManifestLoader::fromFile('phar://' . $file . '/manifest.xml'); + + if (!$manifest->isExtensionFor($applicationName)) { + $notLoadedExtensions[] = $file . ' is not an extension for PHPUnit'; + + continue; + } + + if (!$manifest->isExtensionFor($applicationName, $version)) { + $notLoadedExtensions[] = $file . ' is not compatible with this version of PHPUnit'; + + continue; + } + } catch (ManifestException $e) { + $notLoadedExtensions[] = $file . ': ' . $e->getMessage(); + + continue; + } + + /** + * @noinspection PhpIncludeInspection + * @psalm-suppress UnresolvableInclude + */ + require $file; + + $loadedExtensions[] = $manifest->getName()->asString() . ' ' . $manifest->getVersion()->getVersionString(); + } + + return [ + 'loadedExtensions' => $loadedExtensions, + 'notLoadedExtensions' => $notLoadedExtensions, + ]; + } +} diff --git a/vendor/phpunit/phpunit/src/Runner/Filter/Factory.php b/vendor/phpunit/phpunit/src/Runner/Filter/Factory.php index 82dc1b7e0..3f79da541 100644 --- a/vendor/phpunit/phpunit/src/Runner/Filter/Factory.php +++ b/vendor/phpunit/phpunit/src/Runner/Filter/Factory.php @@ -9,11 +9,12 @@ */ namespace PHPUnit\Runner\Filter; +use function assert; use function sprintf; use FilterIterator; -use InvalidArgumentException; use Iterator; use PHPUnit\Framework\TestSuite; +use PHPUnit\Runner\Exception; use RecursiveFilterIterator; use ReflectionClass; @@ -23,17 +24,19 @@ use ReflectionClass; final class Factory { /** - * @var array + * @psalm-var array */ private $filters = []; /** - * @throws InvalidArgumentException + * @param array|string $args + * + * @throws Exception */ public function addFilter(ReflectionClass $filter, $args): void { if (!$filter->isSubclassOf(RecursiveFilterIterator::class)) { - throw new InvalidArgumentException( + throw new Exception( sprintf( 'Class "%s" does not extend RecursiveFilterIterator', $filter->name @@ -51,6 +54,8 @@ final class Factory $iterator = $class->newInstance($iterator, $args, $suite); } + assert($iterator instanceof FilterIterator); + return $iterator; } } diff --git a/vendor/phpunit/phpunit/src/Runner/Filter/NameFilterIterator.php b/vendor/phpunit/phpunit/src/Runner/Filter/NameFilterIterator.php index d90054d84..7057e1c47 100644 --- a/vendor/phpunit/phpunit/src/Runner/Filter/NameFilterIterator.php +++ b/vendor/phpunit/phpunit/src/Runner/Filter/NameFilterIterator.php @@ -15,6 +15,7 @@ use function preg_match; use function sprintf; use function str_replace; use Exception; +use PHPUnit\Framework\ErrorTestCase; use PHPUnit\Framework\TestSuite; use PHPUnit\Framework\WarningTestCase; use PHPUnit\Util\RegularExpression; @@ -64,7 +65,7 @@ final class NameFilterIterator extends RecursiveFilterIterator $tmp = \PHPUnit\Util\Test::describe($test); - if ($test instanceof WarningTestCase) { + if ($test instanceof ErrorTestCase || $test instanceof WarningTestCase) { $name = $test->getMessage(); } elseif ($tmp[0] !== '') { $name = implode('::', $tmp); diff --git a/vendor/phpunit/phpunit/src/Runner/Hook/AfterIncompleteTestHook.php b/vendor/phpunit/phpunit/src/Runner/Hook/AfterIncompleteTestHook.php index 35ded5d09..48441e6a2 100644 --- a/vendor/phpunit/phpunit/src/Runner/Hook/AfterIncompleteTestHook.php +++ b/vendor/phpunit/phpunit/src/Runner/Hook/AfterIncompleteTestHook.php @@ -9,6 +9,9 @@ */ namespace PHPUnit\Runner; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ interface AfterIncompleteTestHook extends TestHook { public function executeAfterIncompleteTest(string $test, string $message, float $time): void; diff --git a/vendor/phpunit/phpunit/src/Runner/Hook/AfterLastTestHook.php b/vendor/phpunit/phpunit/src/Runner/Hook/AfterLastTestHook.php index 7dee9f9e8..29997b752 100644 --- a/vendor/phpunit/phpunit/src/Runner/Hook/AfterLastTestHook.php +++ b/vendor/phpunit/phpunit/src/Runner/Hook/AfterLastTestHook.php @@ -9,6 +9,9 @@ */ namespace PHPUnit\Runner; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ interface AfterLastTestHook extends Hook { public function executeAfterLastTest(): void; diff --git a/vendor/phpunit/phpunit/src/Runner/Hook/AfterRiskyTestHook.php b/vendor/phpunit/phpunit/src/Runner/Hook/AfterRiskyTestHook.php index 7fe9ee72e..b45c77d2a 100644 --- a/vendor/phpunit/phpunit/src/Runner/Hook/AfterRiskyTestHook.php +++ b/vendor/phpunit/phpunit/src/Runner/Hook/AfterRiskyTestHook.php @@ -9,6 +9,9 @@ */ namespace PHPUnit\Runner; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ interface AfterRiskyTestHook extends TestHook { public function executeAfterRiskyTest(string $test, string $message, float $time): void; diff --git a/vendor/phpunit/phpunit/src/Runner/Hook/AfterSkippedTestHook.php b/vendor/phpunit/phpunit/src/Runner/Hook/AfterSkippedTestHook.php index f9253b5ba..17b202531 100644 --- a/vendor/phpunit/phpunit/src/Runner/Hook/AfterSkippedTestHook.php +++ b/vendor/phpunit/phpunit/src/Runner/Hook/AfterSkippedTestHook.php @@ -9,6 +9,9 @@ */ namespace PHPUnit\Runner; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ interface AfterSkippedTestHook extends TestHook { public function executeAfterSkippedTest(string $test, string $message, float $time): void; diff --git a/vendor/phpunit/phpunit/src/Runner/Hook/AfterSuccessfulTestHook.php b/vendor/phpunit/phpunit/src/Runner/Hook/AfterSuccessfulTestHook.php index 6b55cc877..7ceb30f15 100644 --- a/vendor/phpunit/phpunit/src/Runner/Hook/AfterSuccessfulTestHook.php +++ b/vendor/phpunit/phpunit/src/Runner/Hook/AfterSuccessfulTestHook.php @@ -9,6 +9,9 @@ */ namespace PHPUnit\Runner; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ interface AfterSuccessfulTestHook extends TestHook { public function executeAfterSuccessfulTest(string $test, float $time): void; diff --git a/vendor/phpunit/phpunit/src/Runner/Hook/AfterTestErrorHook.php b/vendor/phpunit/phpunit/src/Runner/Hook/AfterTestErrorHook.php index f5c23fb21..5e21ce6ad 100644 --- a/vendor/phpunit/phpunit/src/Runner/Hook/AfterTestErrorHook.php +++ b/vendor/phpunit/phpunit/src/Runner/Hook/AfterTestErrorHook.php @@ -9,6 +9,9 @@ */ namespace PHPUnit\Runner; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ interface AfterTestErrorHook extends TestHook { public function executeAfterTestError(string $test, string $message, float $time): void; diff --git a/vendor/phpunit/phpunit/src/Runner/Hook/AfterTestFailureHook.php b/vendor/phpunit/phpunit/src/Runner/Hook/AfterTestFailureHook.php index 9ed2939bf..011cca426 100644 --- a/vendor/phpunit/phpunit/src/Runner/Hook/AfterTestFailureHook.php +++ b/vendor/phpunit/phpunit/src/Runner/Hook/AfterTestFailureHook.php @@ -9,6 +9,9 @@ */ namespace PHPUnit\Runner; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ interface AfterTestFailureHook extends TestHook { public function executeAfterTestFailure(string $test, string $message, float $time): void; diff --git a/vendor/phpunit/phpunit/src/Runner/Hook/AfterTestHook.php b/vendor/phpunit/phpunit/src/Runner/Hook/AfterTestHook.php index 7e0af80b1..451510ecf 100644 --- a/vendor/phpunit/phpunit/src/Runner/Hook/AfterTestHook.php +++ b/vendor/phpunit/phpunit/src/Runner/Hook/AfterTestHook.php @@ -9,6 +9,9 @@ */ namespace PHPUnit\Runner; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ interface AfterTestHook extends TestHook { /** diff --git a/vendor/phpunit/phpunit/src/Runner/Hook/AfterTestWarningHook.php b/vendor/phpunit/phpunit/src/Runner/Hook/AfterTestWarningHook.php index 12de80f9c..0b782939d 100644 --- a/vendor/phpunit/phpunit/src/Runner/Hook/AfterTestWarningHook.php +++ b/vendor/phpunit/phpunit/src/Runner/Hook/AfterTestWarningHook.php @@ -9,6 +9,9 @@ */ namespace PHPUnit\Runner; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ interface AfterTestWarningHook extends TestHook { public function executeAfterTestWarning(string $test, string $message, float $time): void; diff --git a/vendor/phpunit/phpunit/src/Runner/Hook/BeforeFirstTestHook.php b/vendor/phpunit/phpunit/src/Runner/Hook/BeforeFirstTestHook.php index 59b666649..b4ffdbd05 100644 --- a/vendor/phpunit/phpunit/src/Runner/Hook/BeforeFirstTestHook.php +++ b/vendor/phpunit/phpunit/src/Runner/Hook/BeforeFirstTestHook.php @@ -9,6 +9,9 @@ */ namespace PHPUnit\Runner; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ interface BeforeFirstTestHook extends Hook { public function executeBeforeFirstTest(): void; diff --git a/vendor/phpunit/phpunit/src/Runner/Hook/BeforeTestHook.php b/vendor/phpunit/phpunit/src/Runner/Hook/BeforeTestHook.php index 8bbf8a99d..381a6558f 100644 --- a/vendor/phpunit/phpunit/src/Runner/Hook/BeforeTestHook.php +++ b/vendor/phpunit/phpunit/src/Runner/Hook/BeforeTestHook.php @@ -9,6 +9,9 @@ */ namespace PHPUnit\Runner; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ interface BeforeTestHook extends TestHook { public function executeBeforeTest(string $test): void; diff --git a/vendor/phpunit/phpunit/src/Runner/Hook/Hook.php b/vendor/phpunit/phpunit/src/Runner/Hook/Hook.php index 546f1a351..9a957ce63 100644 --- a/vendor/phpunit/phpunit/src/Runner/Hook/Hook.php +++ b/vendor/phpunit/phpunit/src/Runner/Hook/Hook.php @@ -9,6 +9,9 @@ */ namespace PHPUnit\Runner; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ interface Hook { } diff --git a/vendor/phpunit/phpunit/src/Runner/Hook/TestHook.php b/vendor/phpunit/phpunit/src/Runner/Hook/TestHook.php index 47c41f9eb..f3387b4c8 100644 --- a/vendor/phpunit/phpunit/src/Runner/Hook/TestHook.php +++ b/vendor/phpunit/phpunit/src/Runner/Hook/TestHook.php @@ -9,6 +9,9 @@ */ namespace PHPUnit\Runner; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ interface TestHook extends Hook { } diff --git a/vendor/phpunit/phpunit/src/Runner/PhptTestCase.php b/vendor/phpunit/phpunit/src/Runner/PhptTestCase.php index e29b3dba3..bdd3e97db 100644 --- a/vendor/phpunit/phpunit/src/Runner/PhptTestCase.php +++ b/vendor/phpunit/phpunit/src/Runner/PhptTestCase.php @@ -19,7 +19,6 @@ use function dirname; use function explode; use function extension_loaded; use function file; -use function file_exists; use function file_get_contents; use function file_put_contents; use function is_array; @@ -45,23 +44,26 @@ use function var_export; use function version_compare; use PHPUnit\Framework\Assert; use PHPUnit\Framework\AssertionFailedError; +use PHPUnit\Framework\ExecutionOrderDependency; use PHPUnit\Framework\ExpectationFailedException; use PHPUnit\Framework\IncompleteTestError; use PHPUnit\Framework\PHPTAssertionFailedError; +use PHPUnit\Framework\Reorderable; use PHPUnit\Framework\SelfDescribing; use PHPUnit\Framework\SkippedTestError; use PHPUnit\Framework\SyntheticSkippedError; use PHPUnit\Framework\Test; use PHPUnit\Framework\TestResult; use PHPUnit\Util\PHP\AbstractPhpProcess; +use SebastianBergmann\CodeCoverage\RawCodeCoverageData; +use SebastianBergmann\Template\Template; use SebastianBergmann\Timer\Timer; -use Text_Template; use Throwable; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ -final class PhptTestCase implements SelfDescribing, Test +final class PhptTestCase implements Reorderable, SelfDescribing, Test { /** * @var string @@ -109,10 +111,7 @@ final class PhptTestCase implements SelfDescribing, Test /** * Runs a test and collects its result in a TestResult instance. * - * @throws \SebastianBergmann\CodeCoverage\CoveredCodeNotExecutedException * @throws \SebastianBergmann\CodeCoverage\InvalidArgumentException - * @throws \SebastianBergmann\CodeCoverage\MissingCoversAnnotationException - * @throws \SebastianBergmann\CodeCoverage\RuntimeException * @throws \SebastianBergmann\CodeCoverage\UnintentionallyCoveredCodeException * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException * @throws Exception @@ -173,17 +172,31 @@ final class PhptTestCase implements SelfDescribing, Test } if ($result->getCollectCodeCoverageInformation()) { - $this->renderForCoverage($code); + $codeCoverageCacheDirectory = null; + $pathCoverage = false; + + $codeCoverage = $result->getCodeCoverage(); + + if ($codeCoverage) { + if ($codeCoverage->cachesStaticAnalysis()) { + $codeCoverageCacheDirectory = $codeCoverage->cacheDirectory(); + } + + $pathCoverage = $codeCoverage->collectsBranchAndPathCoverage(); + } + + $this->renderForCoverage($code, $pathCoverage, $codeCoverageCacheDirectory); } - Timer::start(); + $timer = new Timer; + $timer->start(); $jobResult = $this->phpUtil->runJob($code, $this->stringifyIni($settings)); - $time = Timer::stop(); + $time = $timer->stop()->asSeconds(); $this->output = $jobResult['stdout'] ?? ''; - if ($result->getCollectCodeCoverageInformation() && ($coverage = $this->cleanupForCoverage())) { - $result->getCodeCoverage()->append($coverage, $this, true, [], [], true); + if (isset($codeCoverage) && ($coverage = $this->cleanupForCoverage())) { + $codeCoverage->append($coverage, $this, true, [], []); } try { @@ -266,12 +279,33 @@ final class PhptTestCase implements SelfDescribing, Test return !empty($this->output); } + public function sortId(): string + { + return $this->filename; + } + + /** + * @return list + */ + public function provides(): array + { + return []; + } + + /** + * @return list + */ + public function requires(): array + { + return []; + } + /** * Parse --INI-- section key value pairs and return as array. * - * @param array|string + * @param array|string $content */ - private function parseIniSection($content, $ini = []): array + private function parseIniSection($content, array $ini = []): array { if (is_string($content)) { $content = explode("\n", trim($content)); @@ -327,7 +361,7 @@ final class PhptTestCase implements SelfDescribing, Test $assertions = [ 'EXPECT' => 'assertEquals', 'EXPECTF' => 'assertStringMatchesFormat', - 'EXPECTREGEX' => 'assertRegExp', + 'EXPECTREGEX' => 'assertMatchesRegularExpression', ]; $actual = preg_replace('/\r\n/', "\n", trim($output)); @@ -337,7 +371,7 @@ final class PhptTestCase implements SelfDescribing, Test $sectionContent = preg_replace('/\r\n/', "\n", trim($sections[$sectionName])); $expected = $sectionName === 'EXPECTREGEX' ? "/{$sectionContent}/" : $sectionContent; - if ($expected === null) { + if ($expected === '') { throw new Exception('No PHPT expectation found'); } @@ -560,11 +594,11 @@ final class PhptTestCase implements SelfDescribing, Test ]; } - private function renderForCoverage(string &$job): void + private function renderForCoverage(string &$job, bool $pathCoverage, ?string $codeCoverageCacheDirectory): void { $files = $this->getCoverageFiles(); - $template = new Text_Template( + $template = new Template( __DIR__ . '/../Util/PHP/Template/PhptTestCase.tpl' ); @@ -589,33 +623,42 @@ final class PhptTestCase implements SelfDescribing, Test ) . ";\n"; } + if ($codeCoverageCacheDirectory === null) { + $codeCoverageCacheDirectory = 'null'; + } else { + $codeCoverageCacheDirectory = "'" . $codeCoverageCacheDirectory . "'"; + } + $template->setVar( [ - 'composerAutoload' => $composerAutoload, - 'phar' => $phar, - 'globals' => $globals, - 'job' => $files['job'], - 'coverageFile' => $files['coverage'], + 'composerAutoload' => $composerAutoload, + 'phar' => $phar, + 'globals' => $globals, + 'job' => $files['job'], + 'coverageFile' => $files['coverage'], + 'driverMethod' => $pathCoverage ? 'forLineAndPathCoverage' : 'forLineCoverage', + 'codeCoverageCacheDirectory' => $codeCoverageCacheDirectory, ] ); file_put_contents($files['job'], $job); + $job = $template->render(); } - private function cleanupForCoverage(): array + private function cleanupForCoverage(): RawCodeCoverageData { - $coverage = []; + $coverage = RawCodeCoverageData::fromXdebugWithoutPathCoverage([]); $files = $this->getCoverageFiles(); - if (file_exists($files['coverage'])) { + if (is_file($files['coverage'])) { $buffer = @file_get_contents($files['coverage']); if ($buffer !== false) { $coverage = @unserialize($buffer); if ($coverage === false) { - $coverage = []; + $coverage = RawCodeCoverageData::fromXdebugWithoutPathCoverage([]); } } } @@ -716,6 +759,8 @@ final class PhptTestCase implements SelfDescribing, Test ]; } + $sectionOffset = null; + foreach ($search as $section) { if (!isset($sections[$section])) { continue; diff --git a/vendor/phpunit/phpunit/src/Runner/StandardTestSuiteLoader.php b/vendor/phpunit/phpunit/src/Runner/StandardTestSuiteLoader.php index b658dfcc4..f6de4e937 100644 --- a/vendor/phpunit/phpunit/src/Runner/StandardTestSuiteLoader.php +++ b/vendor/phpunit/phpunit/src/Runner/StandardTestSuiteLoader.php @@ -11,67 +11,52 @@ namespace PHPUnit\Runner; use function array_diff; use function array_values; +use function basename; use function class_exists; use function get_declared_classes; -use function realpath; use function sprintf; -use function str_replace; +use function stripos; use function strlen; use function substr; use PHPUnit\Framework\TestCase; use PHPUnit\Util\FileLoader; -use PHPUnit\Util\Filesystem; use ReflectionClass; use ReflectionException; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit + * + * @deprecated see https://github.com/sebastianbergmann/phpunit/issues/4039 */ final class StandardTestSuiteLoader implements TestSuiteLoader { /** - * @throws \PHPUnit\Framework\Exception * @throws Exception */ - public function load(string $suiteClassName, string $suiteClassFile = ''): ReflectionClass + public function load(string $suiteClassFile): ReflectionClass { - $suiteClassName = str_replace('.php', '', $suiteClassName); - $filename = null; - - if (empty($suiteClassFile)) { - $suiteClassFile = Filesystem::classNameToFilename( - $suiteClassName - ); - } + $suiteClassName = basename($suiteClassFile, '.php'); + $loadedClasses = get_declared_classes(); if (!class_exists($suiteClassName, false)) { - $loadedClasses = get_declared_classes(); - - $filename = FileLoader::checkAndLoad($suiteClassFile); + /* @noinspection UnusedFunctionResultInspection */ + FileLoader::checkAndLoad($suiteClassFile); $loadedClasses = array_values( array_diff(get_declared_classes(), $loadedClasses) ); + + if (empty($loadedClasses)) { + throw $this->exceptionFor($suiteClassName, $suiteClassFile); + } } - if (!empty($loadedClasses) && !class_exists($suiteClassName, false)) { + if (!class_exists($suiteClassName, false)) { + // this block will handle namespaced classes $offset = 0 - strlen($suiteClassName); foreach ($loadedClasses as $loadedClass) { - try { - $class = new ReflectionClass($loadedClass); - // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new Exception( - $e->getMessage(), - (int) $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - - if (substr($loadedClass, $offset) === $suiteClassName && - $class->getFileName() == $filename) { + if (stripos(substr($loadedClass, $offset - 1), '\\' . $suiteClassName) === 0) { $suiteClassName = $loadedClass; break; @@ -79,60 +64,29 @@ final class StandardTestSuiteLoader implements TestSuiteLoader } } - if (!empty($loadedClasses) && !class_exists($suiteClassName, false)) { - $testCaseClass = TestCase::class; - - foreach ($loadedClasses as $loadedClass) { - try { - $class = new ReflectionClass($loadedClass); - // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new Exception( - $e->getMessage(), - (int) $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - - $classFile = $class->getFileName(); - - if ($class->isSubclassOf($testCaseClass) && !$class->isAbstract()) { - $suiteClassName = $loadedClass; - $testCaseClass = $loadedClass; - - if ($classFile == realpath($suiteClassFile)) { - break; - } - } - - if ($class->hasMethod('suite')) { - try { - $method = $class->getMethod('suite'); - // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new Exception( - $e->getMessage(), - (int) $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - - if (!$method->isAbstract() && $method->isPublic() && $method->isStatic()) { - $suiteClassName = $loadedClass; - - if ($classFile == realpath($suiteClassFile)) { - break; - } - } - } - } + if (!class_exists($suiteClassName, false)) { + throw $this->exceptionFor($suiteClassName, $suiteClassFile); } - if (class_exists($suiteClassName, false)) { + try { + $class = new ReflectionClass($suiteClassName); + // @codeCoverageIgnoreStart + } catch (ReflectionException $e) { + throw new Exception( + $e->getMessage(), + (int) $e->getCode(), + $e + ); + } + // @codeCoverageIgnoreEnd + + if ($class->isSubclassOf(TestCase::class) && !$class->isAbstract()) { + return $class; + } + + if ($class->hasMethod('suite')) { try { - $class = new ReflectionClass($suiteClassName); + $method = $class->getMethod('suite'); // @codeCoverageIgnoreStart } catch (ReflectionException $e) { throw new Exception( @@ -143,22 +97,27 @@ final class StandardTestSuiteLoader implements TestSuiteLoader } // @codeCoverageIgnoreEnd - if ($class->getFileName() == realpath($suiteClassFile)) { + if (!$method->isAbstract() && $method->isPublic() && $method->isStatic()) { return $class; } } - throw new Exception( - sprintf( - "Class '%s' could not be found in '%s'.", - $suiteClassName, - $suiteClassFile - ) - ); + throw $this->exceptionFor($suiteClassName, $suiteClassFile); } public function reload(ReflectionClass $aClass): ReflectionClass { return $aClass; } + + private function exceptionFor(string $className, string $filename): Exception + { + return new Exception( + sprintf( + "Class '%s' could not be found in '%s'.", + $className, + $filename + ) + ); + } } diff --git a/vendor/phpunit/phpunit/src/Runner/TestSuiteLoader.php b/vendor/phpunit/phpunit/src/Runner/TestSuiteLoader.php index f05968892..c9d8e01b1 100644 --- a/vendor/phpunit/phpunit/src/Runner/TestSuiteLoader.php +++ b/vendor/phpunit/phpunit/src/Runner/TestSuiteLoader.php @@ -12,11 +12,13 @@ namespace PHPUnit\Runner; use ReflectionClass; /** - * An interface to define how a test suite should be loaded. + * @deprecated see https://github.com/sebastianbergmann/phpunit/issues/4039 + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ interface TestSuiteLoader { - public function load(string $suiteClassName, string $suiteClassFile = ''): ReflectionClass; + public function load(string $suiteClassFile): ReflectionClass; public function reload(ReflectionClass $aClass): ReflectionClass; } diff --git a/vendor/phpunit/phpunit/src/Runner/TestSuiteSorter.php b/vendor/phpunit/phpunit/src/Runner/TestSuiteSorter.php index f44b92ced..fcf2cdbb4 100644 --- a/vendor/phpunit/phpunit/src/Runner/TestSuiteSorter.php +++ b/vendor/phpunit/phpunit/src/Runner/TestSuiteSorter.php @@ -9,21 +9,17 @@ */ namespace PHPUnit\Runner; -use function array_intersect; -use function array_map; +use function array_diff; use function array_merge; -use function array_reduce; use function array_reverse; use function array_splice; use function count; -use function get_class; use function in_array; use function max; use function shuffle; -use function strpos; -use function substr; use function usort; use PHPUnit\Framework\DataProviderTestSuite; +use PHPUnit\Framework\Reorderable; use PHPUnit\Framework\Test; use PHPUnit\Framework\TestCase; use PHPUnit\Framework\TestSuite; @@ -97,37 +93,15 @@ final class TestSuiteSorter private $cache; /** - * @var string[] A list of normalized names of tests before reordering + * @var array A list of normalized names of tests before reordering */ private $originalExecutionOrder = []; /** - * @var string[] A list of normalized names of tests affected by reordering + * @var array A list of normalized names of tests affected by reordering */ private $executionOrder = []; - /** - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - */ - public static function getTestSorterUID(Test $test): string - { - if ($test instanceof PhptTestCase) { - return $test->getName(); - } - - if ($test instanceof TestCase) { - $testName = $test->getName(true); - - if (strpos($testName, '::') === false) { - $testName = get_class($test) . '::' . $testName; - } - - return $testName; - } - - return $test->getName(); - } - public function __construct(?TestResultCache $cache = null) { $this->cache = $cache ?? new NullTestResultCache; @@ -215,7 +189,7 @@ final class TestSuiteSorter $suite->setTests($this->sortDefectsFirst($suite->tests())); } - if ($resolveDependencies && !($suite instanceof DataProviderTestSuite) && $this->suiteOnlyContainsTests($suite)) { + if ($resolveDependencies && !($suite instanceof DataProviderTestSuite)) { /** @var TestCase[] $tests */ $tests = $suite->tests(); @@ -231,26 +205,17 @@ final class TestSuiteSorter $max = 0; foreach ($suite->tests() as $test) { - $testname = self::getTestSorterUID($test); + if (!$test instanceof Reorderable) { + continue; + } - if (!isset($this->defectSortOrder[$testname])) { - $this->defectSortOrder[$testname] = self::DEFECT_SORT_WEIGHT[$this->cache->getState($testname)]; - $max = max($max, $this->defectSortOrder[$testname]); + if (!isset($this->defectSortOrder[$test->sortId()])) { + $this->defectSortOrder[$test->sortId()] = self::DEFECT_SORT_WEIGHT[$this->cache->getState($test->sortId())]; + $max = max($max, $this->defectSortOrder[$test->sortId()]); } } - $this->defectSortOrder[$suite->getName()] = $max; - } - - private function suiteOnlyContainsTests(TestSuite $suite): bool - { - return array_reduce( - $suite->tests(), - static function ($carry, $test) { - return $carry && ($test instanceof TestCase || $test instanceof DataProviderTestSuite); - }, - true - ); + $this->defectSortOrder[$suite->sortId()] = $max; } private function reverse(array $tests): array @@ -311,17 +276,22 @@ final class TestSuiteSorter } /** - * Comparator callback function to sort tests for "reach failure as fast as possible": + * Comparator callback function to sort tests for "reach failure as fast as possible". + * * 1. sort tests by defect weight defined in self::DEFECT_SORT_WEIGHT * 2. when tests are equally defective, sort the fastest to the front - * 3. do not reorder successful tests. + * 3. do not reorder successful tests * * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException */ private function cmpDefectPriorityAndTime(Test $a, Test $b): int { - $priorityA = $this->defectSortOrder[self::getTestSorterUID($a)] ?? 0; - $priorityB = $this->defectSortOrder[self::getTestSorterUID($b)] ?? 0; + if (!($a instanceof Reorderable && $b instanceof Reorderable)) { + return 0; + } + + $priorityA = $this->defectSortOrder[$a->sortId()] ?? 0; + $priorityB = $this->defectSortOrder[$b->sortId()] ?? 0; if ($priorityB <=> $priorityA) { // Sort defect weight descending @@ -343,7 +313,11 @@ final class TestSuiteSorter */ private function cmpDuration(Test $a, Test $b): int { - return $this->cache->getTime(self::getTestSorterUID($a)) <=> $this->cache->getTime(self::getTestSorterUID($b)); + if (!($a instanceof Reorderable && $b instanceof Reorderable)) { + return 0; + } + + return $this->cache->getTime($a->sortId()) <=> $this->cache->getTime($b->sortId()); } /** @@ -380,19 +354,11 @@ final class TestSuiteSorter { $newTestOrder = []; $i = 0; + $provided = []; do { - $todoNames = array_map( - /** - * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException - */ - static function ($test) { - return self::getTestSorterUID($test); - }, - $tests - ); - - if (!$tests[$i]->hasDependencies() || empty(array_intersect($this->getNormalizedDependencyNames($tests[$i]), $todoNames))) { + if ([] === array_diff($tests[$i]->requires(), $provided)) { + $provided = array_merge($provided, $tests[$i]->provides()); $newTestOrder = array_merge($newTestOrder, array_splice($tests, $i, 1)); $i = 0; } else { @@ -403,29 +369,6 @@ final class TestSuiteSorter return array_merge($newTestOrder, $tests); } - /** - * @param DataProviderTestSuite|TestCase $test - * - * @return array A list of full test names as "TestSuiteClassName::testMethodName" - */ - private function getNormalizedDependencyNames($test): array - { - if ($test instanceof DataProviderTestSuite) { - $testClass = substr($test->getName(), 0, strpos($test->getName(), '::')); - } else { - $testClass = get_class($test); - } - - $names = array_map( - static function ($name) use ($testClass) { - return strpos($name, '::') === false ? $testClass . '::' . $name : $name; - }, - $test->getDependencies() - ); - - return $names; - } - /** * @throws \SebastianBergmann\RecursionContext\InvalidArgumentException */ @@ -435,8 +378,8 @@ final class TestSuiteSorter if ($suite instanceof TestSuite) { foreach ($suite->tests() as $test) { - if (!($test instanceof TestSuite)) { - $tests[] = self::getTestSorterUID($test); + if (!$test instanceof TestSuite && $test instanceof Reorderable) { + $tests[] = $test->sortId(); } else { $tests = array_merge($tests, $this->calculateTestExecutionOrder($test)); } diff --git a/vendor/phpunit/phpunit/src/Runner/Version.php b/vendor/phpunit/phpunit/src/Runner/Version.php index 263210ab8..88e919c76 100644 --- a/vendor/phpunit/phpunit/src/Runner/Version.php +++ b/vendor/phpunit/phpunit/src/Runner/Version.php @@ -16,6 +16,9 @@ use function implode; use function strpos; use SebastianBergmann\Version as VersionId; +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ final class Version { /** @@ -38,7 +41,7 @@ final class Version } if (self::$version === '') { - self::$version = (new VersionId('8.5.15', dirname(__DIR__, 2)))->getVersion(); + self::$version = (new VersionId('9.5.4', dirname(__DIR__, 2)))->getVersion(); } return self::$version; @@ -59,13 +62,4 @@ final class Version { return 'PHPUnit ' . self::id() . ' by Sebastian Bergmann and contributors.'; } - - public static function getReleaseChannel(): string - { - if (strpos(self::$pharVersion, '-') !== false) { - return '-nightly'; - } - - return ''; - } } diff --git a/vendor/phpunit/phpunit/src/TextUI/CliArguments/Builder.php b/vendor/phpunit/phpunit/src/TextUI/CliArguments/Builder.php new file mode 100644 index 000000000..7d5e1b5b4 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/CliArguments/Builder.php @@ -0,0 +1,887 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\CliArguments; + +use function array_map; +use function array_merge; +use function class_exists; +use function explode; +use function is_numeric; +use function str_replace; +use PHPUnit\Runner\TestSuiteSorter; +use PHPUnit\TextUI\DefaultResultPrinter; +use PHPUnit\TextUI\XmlConfiguration\Extension; +use PHPUnit\Util\Log\TeamCity; +use PHPUnit\Util\TestDox\CliTestDoxPrinter; +use SebastianBergmann\CliParser\Exception as CliParserException; +use SebastianBergmann\CliParser\Parser as CliParser; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class Builder +{ + private const LONG_OPTIONS = [ + 'atleast-version=', + 'prepend=', + 'bootstrap=', + 'cache-result', + 'do-not-cache-result', + 'cache-result-file=', + 'check-version', + 'colors==', + 'columns=', + 'configuration=', + 'coverage-cache=', + 'warm-coverage-cache', + 'coverage-filter=', + 'coverage-clover=', + 'coverage-cobertura=', + 'coverage-crap4j=', + 'coverage-html=', + 'coverage-php=', + 'coverage-text==', + 'coverage-xml=', + 'path-coverage', + 'debug', + 'disallow-test-output', + 'disallow-resource-usage', + 'disallow-todo-tests', + 'default-time-limit=', + 'enforce-time-limit', + 'exclude-group=', + 'extensions=', + 'filter=', + 'generate-configuration', + 'globals-backup', + 'group=', + 'covers=', + 'uses=', + 'help', + 'resolve-dependencies', + 'ignore-dependencies', + 'include-path=', + 'list-groups', + 'list-suites', + 'list-tests', + 'list-tests-xml=', + 'loader=', + 'log-junit=', + 'log-teamcity=', + 'migrate-configuration', + 'no-configuration', + 'no-coverage', + 'no-logging', + 'no-interaction', + 'no-extensions', + 'order-by=', + 'printer=', + 'process-isolation', + 'repeat=', + 'dont-report-useless-tests', + 'random-order', + 'random-order-seed=', + 'reverse-order', + 'reverse-list', + 'static-backup', + 'stderr', + 'stop-on-defect', + 'stop-on-error', + 'stop-on-failure', + 'stop-on-warning', + 'stop-on-incomplete', + 'stop-on-risky', + 'stop-on-skipped', + 'fail-on-empty-test-suite', + 'fail-on-incomplete', + 'fail-on-risky', + 'fail-on-skipped', + 'fail-on-warning', + 'strict-coverage', + 'disable-coverage-ignore', + 'strict-global-state', + 'teamcity', + 'testdox', + 'testdox-group=', + 'testdox-exclude-group=', + 'testdox-html=', + 'testdox-text=', + 'testdox-xml=', + 'test-suffix=', + 'testsuite=', + 'verbose', + 'version', + 'whitelist=', + 'dump-xdebug-filter=', + ]; + + private const SHORT_OPTIONS = 'd:c:hv'; + + public function fromParameters(array $parameters, array $additionalLongOptions): Configuration + { + try { + $options = (new CliParser)->parse( + $parameters, + self::SHORT_OPTIONS, + array_merge(self::LONG_OPTIONS, $additionalLongOptions) + ); + } catch (CliParserException $e) { + throw new Exception( + $e->getMessage(), + (int) $e->getCode(), + $e + ); + } + + $argument = null; + $atLeastVersion = null; + $backupGlobals = null; + $backupStaticAttributes = null; + $beStrictAboutChangesToGlobalState = null; + $beStrictAboutResourceUsageDuringSmallTests = null; + $bootstrap = null; + $cacheResult = null; + $cacheResultFile = null; + $checkVersion = null; + $colors = null; + $columns = null; + $configuration = null; + $coverageCacheDirectory = null; + $warmCoverageCache = null; + $coverageFilter = null; + $coverageClover = null; + $coverageCobertura = null; + $coverageCrap4J = null; + $coverageHtml = null; + $coveragePhp = null; + $coverageText = null; + $coverageTextShowUncoveredFiles = null; + $coverageTextShowOnlySummary = null; + $coverageXml = null; + $pathCoverage = null; + $debug = null; + $defaultTimeLimit = null; + $disableCodeCoverageIgnore = null; + $disallowTestOutput = null; + $disallowTodoAnnotatedTests = null; + $enforceTimeLimit = null; + $excludeGroups = null; + $executionOrder = null; + $executionOrderDefects = null; + $extensions = []; + $unavailableExtensions = []; + $failOnEmptyTestSuite = null; + $failOnIncomplete = null; + $failOnRisky = null; + $failOnSkipped = null; + $failOnWarning = null; + $filter = null; + $generateConfiguration = null; + $migrateConfiguration = null; + $groups = null; + $testsCovering = null; + $testsUsing = null; + $help = null; + $includePath = null; + $iniSettings = []; + $junitLogfile = null; + $listGroups = null; + $listSuites = null; + $listTests = null; + $listTestsXml = null; + $loader = null; + $noCoverage = null; + $noExtensions = null; + $noInteraction = null; + $noLogging = null; + $printer = null; + $processIsolation = null; + $randomOrderSeed = null; + $repeat = null; + $reportUselessTests = null; + $resolveDependencies = null; + $reverseList = null; + $stderr = null; + $strictCoverage = null; + $stopOnDefect = null; + $stopOnError = null; + $stopOnFailure = null; + $stopOnIncomplete = null; + $stopOnRisky = null; + $stopOnSkipped = null; + $stopOnWarning = null; + $teamcityLogfile = null; + $testdoxExcludeGroups = null; + $testdoxGroups = null; + $testdoxHtmlFile = null; + $testdoxTextFile = null; + $testdoxXmlFile = null; + $testSuffixes = null; + $testSuite = null; + $unrecognizedOptions = []; + $unrecognizedOrderBy = null; + $useDefaultConfiguration = null; + $verbose = null; + $version = null; + $xdebugFilterFile = null; + + if (isset($options[1][0])) { + $argument = $options[1][0]; + } + + foreach ($options[0] as $option) { + switch ($option[0]) { + case '--colors': + $colors = $option[1] ?: DefaultResultPrinter::COLOR_AUTO; + + break; + + case '--bootstrap': + $bootstrap = $option[1]; + + break; + + case '--cache-result': + $cacheResult = true; + + break; + + case '--do-not-cache-result': + $cacheResult = false; + + break; + + case '--cache-result-file': + $cacheResultFile = $option[1]; + + break; + + case '--columns': + if (is_numeric($option[1])) { + $columns = (int) $option[1]; + } elseif ($option[1] === 'max') { + $columns = 'max'; + } + + break; + + case 'c': + case '--configuration': + $configuration = $option[1]; + + break; + + case '--coverage-cache': + $coverageCacheDirectory = $option[1]; + + break; + + case '--warm-coverage-cache': + $warmCoverageCache = true; + + break; + + case '--coverage-clover': + $coverageClover = $option[1]; + + break; + + case '--coverage-cobertura': + $coverageCobertura = $option[1]; + + break; + + case '--coverage-crap4j': + $coverageCrap4J = $option[1]; + + break; + + case '--coverage-html': + $coverageHtml = $option[1]; + + break; + + case '--coverage-php': + $coveragePhp = $option[1]; + + break; + + case '--coverage-text': + if ($option[1] === null) { + $option[1] = 'php://stdout'; + } + + $coverageText = $option[1]; + $coverageTextShowUncoveredFiles = false; + $coverageTextShowOnlySummary = false; + + break; + + case '--coverage-xml': + $coverageXml = $option[1]; + + break; + + case '--path-coverage': + $pathCoverage = true; + + break; + + case 'd': + $tmp = explode('=', $option[1]); + + if (isset($tmp[0])) { + if (isset($tmp[1])) { + $iniSettings[$tmp[0]] = $tmp[1]; + } else { + $iniSettings[$tmp[0]] = '1'; + } + } + + break; + + case '--debug': + $debug = true; + + break; + + case 'h': + case '--help': + $help = true; + + break; + + case '--filter': + $filter = $option[1]; + + break; + + case '--testsuite': + $testSuite = $option[1]; + + break; + + case '--generate-configuration': + $generateConfiguration = true; + + break; + + case '--migrate-configuration': + $migrateConfiguration = true; + + break; + + case '--group': + $groups = explode(',', $option[1]); + + break; + + case '--exclude-group': + $excludeGroups = explode(',', $option[1]); + + break; + + case '--covers': + $testsCovering = array_map('strtolower', explode(',', $option[1])); + + break; + + case '--uses': + $testsUsing = array_map('strtolower', explode(',', $option[1])); + + break; + + case '--test-suffix': + $testSuffixes = explode(',', $option[1]); + + break; + + case '--include-path': + $includePath = $option[1]; + + break; + + case '--list-groups': + $listGroups = true; + + break; + + case '--list-suites': + $listSuites = true; + + break; + + case '--list-tests': + $listTests = true; + + break; + + case '--list-tests-xml': + $listTestsXml = $option[1]; + + break; + + case '--printer': + $printer = $option[1]; + + break; + + case '--loader': + $loader = $option[1]; + + break; + + case '--log-junit': + $junitLogfile = $option[1]; + + break; + + case '--log-teamcity': + $teamcityLogfile = $option[1]; + + break; + + case '--order-by': + foreach (explode(',', $option[1]) as $order) { + switch ($order) { + case 'default': + $executionOrder = TestSuiteSorter::ORDER_DEFAULT; + $executionOrderDefects = TestSuiteSorter::ORDER_DEFAULT; + $resolveDependencies = true; + + break; + + case 'defects': + $executionOrderDefects = TestSuiteSorter::ORDER_DEFECTS_FIRST; + + break; + + case 'depends': + $resolveDependencies = true; + + break; + + case 'duration': + $executionOrder = TestSuiteSorter::ORDER_DURATION; + + break; + + case 'no-depends': + $resolveDependencies = false; + + break; + + case 'random': + $executionOrder = TestSuiteSorter::ORDER_RANDOMIZED; + + break; + + case 'reverse': + $executionOrder = TestSuiteSorter::ORDER_REVERSED; + + break; + + case 'size': + $executionOrder = TestSuiteSorter::ORDER_SIZE; + + break; + + default: + $unrecognizedOrderBy = $order; + } + } + + break; + + case '--process-isolation': + $processIsolation = true; + + break; + + case '--repeat': + $repeat = (int) $option[1]; + + break; + + case '--stderr': + $stderr = true; + + break; + + case '--stop-on-defect': + $stopOnDefect = true; + + break; + + case '--stop-on-error': + $stopOnError = true; + + break; + + case '--stop-on-failure': + $stopOnFailure = true; + + break; + + case '--stop-on-warning': + $stopOnWarning = true; + + break; + + case '--stop-on-incomplete': + $stopOnIncomplete = true; + + break; + + case '--stop-on-risky': + $stopOnRisky = true; + + break; + + case '--stop-on-skipped': + $stopOnSkipped = true; + + break; + + case '--fail-on-empty-test-suite': + $failOnEmptyTestSuite = true; + + break; + + case '--fail-on-incomplete': + $failOnIncomplete = true; + + break; + + case '--fail-on-risky': + $failOnRisky = true; + + break; + + case '--fail-on-skipped': + $failOnSkipped = true; + + break; + + case '--fail-on-warning': + $failOnWarning = true; + + break; + + case '--teamcity': + $printer = TeamCity::class; + + break; + + case '--testdox': + $printer = CliTestDoxPrinter::class; + + break; + + case '--testdox-group': + $testdoxGroups = explode(',', $option[1]); + + break; + + case '--testdox-exclude-group': + $testdoxExcludeGroups = explode(',', $option[1]); + + break; + + case '--testdox-html': + $testdoxHtmlFile = $option[1]; + + break; + + case '--testdox-text': + $testdoxTextFile = $option[1]; + + break; + + case '--testdox-xml': + $testdoxXmlFile = $option[1]; + + break; + + case '--no-configuration': + $useDefaultConfiguration = false; + + break; + + case '--extensions': + foreach (explode(',', $option[1]) as $extensionClass) { + if (!class_exists($extensionClass)) { + $unavailableExtensions[] = $extensionClass; + + continue; + } + + $extensions[] = new Extension($extensionClass, '', []); + } + + break; + + case '--no-extensions': + $noExtensions = true; + + break; + + case '--no-coverage': + $noCoverage = true; + + break; + + case '--no-logging': + $noLogging = true; + + break; + + case '--no-interaction': + $noInteraction = true; + + break; + + case '--globals-backup': + $backupGlobals = true; + + break; + + case '--static-backup': + $backupStaticAttributes = true; + + break; + + case 'v': + case '--verbose': + $verbose = true; + + break; + + case '--atleast-version': + $atLeastVersion = $option[1]; + + break; + + case '--version': + $version = true; + + break; + + case '--dont-report-useless-tests': + $reportUselessTests = false; + + break; + + case '--strict-coverage': + $strictCoverage = true; + + break; + + case '--disable-coverage-ignore': + $disableCodeCoverageIgnore = true; + + break; + + case '--strict-global-state': + $beStrictAboutChangesToGlobalState = true; + + break; + + case '--disallow-test-output': + $disallowTestOutput = true; + + break; + + case '--disallow-resource-usage': + $beStrictAboutResourceUsageDuringSmallTests = true; + + break; + + case '--default-time-limit': + $defaultTimeLimit = (int) $option[1]; + + break; + + case '--enforce-time-limit': + $enforceTimeLimit = true; + + break; + + case '--disallow-todo-tests': + $disallowTodoAnnotatedTests = true; + + break; + + case '--reverse-list': + $reverseList = true; + + break; + + case '--check-version': + $checkVersion = true; + + break; + + case '--coverage-filter': + case '--whitelist': + if ($coverageFilter === null) { + $coverageFilter = []; + } + + $coverageFilter[] = $option[1]; + + break; + + case '--random-order': + $executionOrder = TestSuiteSorter::ORDER_RANDOMIZED; + + break; + + case '--random-order-seed': + $randomOrderSeed = (int) $option[1]; + + break; + + case '--resolve-dependencies': + $resolveDependencies = true; + + break; + + case '--ignore-dependencies': + $resolveDependencies = false; + + break; + + case '--reverse-order': + $executionOrder = TestSuiteSorter::ORDER_REVERSED; + + break; + + case '--dump-xdebug-filter': + $xdebugFilterFile = $option[1]; + + break; + + default: + $unrecognizedOptions[str_replace('--', '', $option[0])] = $option[1]; + } + } + + if (empty($extensions)) { + $extensions = null; + } + + if (empty($unavailableExtensions)) { + $unavailableExtensions = null; + } + + if (empty($iniSettings)) { + $iniSettings = null; + } + + if (empty($coverageFilter)) { + $coverageFilter = null; + } + + return new Configuration( + $argument, + $atLeastVersion, + $backupGlobals, + $backupStaticAttributes, + $beStrictAboutChangesToGlobalState, + $beStrictAboutResourceUsageDuringSmallTests, + $bootstrap, + $cacheResult, + $cacheResultFile, + $checkVersion, + $colors, + $columns, + $configuration, + $coverageClover, + $coverageCobertura, + $coverageCrap4J, + $coverageHtml, + $coveragePhp, + $coverageText, + $coverageTextShowUncoveredFiles, + $coverageTextShowOnlySummary, + $coverageXml, + $pathCoverage, + $coverageCacheDirectory, + $warmCoverageCache, + $debug, + $defaultTimeLimit, + $disableCodeCoverageIgnore, + $disallowTestOutput, + $disallowTodoAnnotatedTests, + $enforceTimeLimit, + $excludeGroups, + $executionOrder, + $executionOrderDefects, + $extensions, + $unavailableExtensions, + $failOnEmptyTestSuite, + $failOnIncomplete, + $failOnRisky, + $failOnSkipped, + $failOnWarning, + $filter, + $generateConfiguration, + $migrateConfiguration, + $groups, + $testsCovering, + $testsUsing, + $help, + $includePath, + $iniSettings, + $junitLogfile, + $listGroups, + $listSuites, + $listTests, + $listTestsXml, + $loader, + $noCoverage, + $noExtensions, + $noInteraction, + $noLogging, + $printer, + $processIsolation, + $randomOrderSeed, + $repeat, + $reportUselessTests, + $resolveDependencies, + $reverseList, + $stderr, + $strictCoverage, + $stopOnDefect, + $stopOnError, + $stopOnFailure, + $stopOnIncomplete, + $stopOnRisky, + $stopOnSkipped, + $stopOnWarning, + $teamcityLogfile, + $testdoxExcludeGroups, + $testdoxGroups, + $testdoxHtmlFile, + $testdoxTextFile, + $testdoxXmlFile, + $testSuffixes, + $testSuite, + $unrecognizedOptions, + $unrecognizedOrderBy, + $useDefaultConfiguration, + $verbose, + $version, + $coverageFilter, + $xdebugFilterFile + ); + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/CliArguments/Configuration.php b/vendor/phpunit/phpunit/src/TextUI/CliArguments/Configuration.php new file mode 100644 index 000000000..b220dd7aa --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/CliArguments/Configuration.php @@ -0,0 +1,2107 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\CliArguments; + +use PHPUnit\TextUI\XmlConfiguration\Extension; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Configuration +{ + /** + * @var ?string + */ + private $argument; + + /** + * @var ?string + */ + private $atLeastVersion; + + /** + * @var ?bool + */ + private $backupGlobals; + + /** + * @var ?bool + */ + private $backupStaticAttributes; + + /** + * @var ?bool + */ + private $beStrictAboutChangesToGlobalState; + + /** + * @var ?bool + */ + private $beStrictAboutResourceUsageDuringSmallTests; + + /** + * @var ?string + */ + private $bootstrap; + + /** + * @var ?bool + */ + private $cacheResult; + + /** + * @var ?string + */ + private $cacheResultFile; + + /** + * @var ?bool + */ + private $checkVersion; + + /** + * @var ?string + */ + private $colors; + + /** + * @var null|int|string + */ + private $columns; + + /** + * @var ?string + */ + private $configuration; + + /** + * @var null|string[] + */ + private $coverageFilter; + + /** + * @var ?string + */ + private $coverageClover; + + /** + * @var ?string + */ + private $coverageCobertura; + + /** + * @var ?string + */ + private $coverageCrap4J; + + /** + * @var ?string + */ + private $coverageHtml; + + /** + * @var ?string + */ + private $coveragePhp; + + /** + * @var ?string + */ + private $coverageText; + + /** + * @var ?bool + */ + private $coverageTextShowUncoveredFiles; + + /** + * @var ?bool + */ + private $coverageTextShowOnlySummary; + + /** + * @var ?string + */ + private $coverageXml; + + /** + * @var ?bool + */ + private $pathCoverage; + + /** + * @var ?string + */ + private $coverageCacheDirectory; + + /** + * @var ?bool + */ + private $warmCoverageCache; + + /** + * @var ?bool + */ + private $debug; + + /** + * @var ?int + */ + private $defaultTimeLimit; + + /** + * @var ?bool + */ + private $disableCodeCoverageIgnore; + + /** + * @var ?bool + */ + private $disallowTestOutput; + + /** + * @var ?bool + */ + private $disallowTodoAnnotatedTests; + + /** + * @var ?bool + */ + private $enforceTimeLimit; + + /** + * @var null|string[] + */ + private $excludeGroups; + + /** + * @var ?int + */ + private $executionOrder; + + /** + * @var ?int + */ + private $executionOrderDefects; + + /** + * @var null|Extension[] + */ + private $extensions; + + /** + * @var null|string[] + */ + private $unavailableExtensions; + + /** + * @var ?bool + */ + private $failOnEmptyTestSuite; + + /** + * @var ?bool + */ + private $failOnIncomplete; + + /** + * @var ?bool + */ + private $failOnRisky; + + /** + * @var ?bool + */ + private $failOnSkipped; + + /** + * @var ?bool + */ + private $failOnWarning; + + /** + * @var ?string + */ + private $filter; + + /** + * @var ?bool + */ + private $generateConfiguration; + + /** + * @var ?bool + */ + private $migrateConfiguration; + + /** + * @var null|string[] + */ + private $groups; + + /** + * @var null|string[] + */ + private $testsCovering; + + /** + * @var null|string[] + */ + private $testsUsing; + + /** + * @var ?bool + */ + private $help; + + /** + * @var ?string + */ + private $includePath; + + /** + * @var null|string[] + */ + private $iniSettings; + + /** + * @var ?string + */ + private $junitLogfile; + + /** + * @var ?bool + */ + private $listGroups; + + /** + * @var ?bool + */ + private $listSuites; + + /** + * @var ?bool + */ + private $listTests; + + /** + * @var ?string + */ + private $listTestsXml; + + /** + * @var ?string + */ + private $loader; + + /** + * @var ?bool + */ + private $noCoverage; + + /** + * @var ?bool + */ + private $noExtensions; + + /** + * @var ?bool + */ + private $noInteraction; + + /** + * @var ?bool + */ + private $noLogging; + + /** + * @var ?string + */ + private $printer; + + /** + * @var ?bool + */ + private $processIsolation; + + /** + * @var ?int + */ + private $randomOrderSeed; + + /** + * @var ?int + */ + private $repeat; + + /** + * @var ?bool + */ + private $reportUselessTests; + + /** + * @var ?bool + */ + private $resolveDependencies; + + /** + * @var ?bool + */ + private $reverseList; + + /** + * @var ?bool + */ + private $stderr; + + /** + * @var ?bool + */ + private $strictCoverage; + + /** + * @var ?bool + */ + private $stopOnDefect; + + /** + * @var ?bool + */ + private $stopOnError; + + /** + * @var ?bool + */ + private $stopOnFailure; + + /** + * @var ?bool + */ + private $stopOnIncomplete; + + /** + * @var ?bool + */ + private $stopOnRisky; + + /** + * @var ?bool + */ + private $stopOnSkipped; + + /** + * @var ?bool + */ + private $stopOnWarning; + + /** + * @var ?string + */ + private $teamcityLogfile; + + /** + * @var null|string[] + */ + private $testdoxExcludeGroups; + + /** + * @var null|string[] + */ + private $testdoxGroups; + + /** + * @var ?string + */ + private $testdoxHtmlFile; + + /** + * @var ?string + */ + private $testdoxTextFile; + + /** + * @var ?string + */ + private $testdoxXmlFile; + + /** + * @var null|string[] + */ + private $testSuffixes; + + /** + * @var ?string + */ + private $testSuite; + + /** + * @var string[] + */ + private $unrecognizedOptions; + + /** + * @var ?string + */ + private $unrecognizedOrderBy; + + /** + * @var ?bool + */ + private $useDefaultConfiguration; + + /** + * @var ?bool + */ + private $verbose; + + /** + * @var ?bool + */ + private $version; + + /** + * @var ?string + */ + private $xdebugFilterFile; + + /** + * @param null|int|string $columns + */ + public function __construct(?string $argument, ?string $atLeastVersion, ?bool $backupGlobals, ?bool $backupStaticAttributes, ?bool $beStrictAboutChangesToGlobalState, ?bool $beStrictAboutResourceUsageDuringSmallTests, ?string $bootstrap, ?bool $cacheResult, ?string $cacheResultFile, ?bool $checkVersion, ?string $colors, $columns, ?string $configuration, ?string $coverageClover, ?string $coverageCobertura, ?string $coverageCrap4J, ?string $coverageHtml, ?string $coveragePhp, ?string $coverageText, ?bool $coverageTextShowUncoveredFiles, ?bool $coverageTextShowOnlySummary, ?string $coverageXml, ?bool $pathCoverage, ?string $coverageCacheDirectory, ?bool $warmCoverageCache, ?bool $debug, ?int $defaultTimeLimit, ?bool $disableCodeCoverageIgnore, ?bool $disallowTestOutput, ?bool $disallowTodoAnnotatedTests, ?bool $enforceTimeLimit, ?array $excludeGroups, ?int $executionOrder, ?int $executionOrderDefects, ?array $extensions, ?array $unavailableExtensions, ?bool $failOnEmptyTestSuite, ?bool $failOnIncomplete, ?bool $failOnRisky, ?bool $failOnSkipped, ?bool $failOnWarning, ?string $filter, ?bool $generateConfiguration, ?bool $migrateConfiguration, ?array $groups, ?array $testsCovering, ?array $testsUsing, ?bool $help, ?string $includePath, ?array $iniSettings, ?string $junitLogfile, ?bool $listGroups, ?bool $listSuites, ?bool $listTests, ?string $listTestsXml, ?string $loader, ?bool $noCoverage, ?bool $noExtensions, ?bool $noInteraction, ?bool $noLogging, ?string $printer, ?bool $processIsolation, ?int $randomOrderSeed, ?int $repeat, ?bool $reportUselessTests, ?bool $resolveDependencies, ?bool $reverseList, ?bool $stderr, ?bool $strictCoverage, ?bool $stopOnDefect, ?bool $stopOnError, ?bool $stopOnFailure, ?bool $stopOnIncomplete, ?bool $stopOnRisky, ?bool $stopOnSkipped, ?bool $stopOnWarning, ?string $teamcityLogfile, ?array $testdoxExcludeGroups, ?array $testdoxGroups, ?string $testdoxHtmlFile, ?string $testdoxTextFile, ?string $testdoxXmlFile, ?array $testSuffixes, ?string $testSuite, array $unrecognizedOptions, ?string $unrecognizedOrderBy, ?bool $useDefaultConfiguration, ?bool $verbose, ?bool $version, ?array $coverageFilter, ?string $xdebugFilterFile) + { + $this->argument = $argument; + $this->atLeastVersion = $atLeastVersion; + $this->backupGlobals = $backupGlobals; + $this->backupStaticAttributes = $backupStaticAttributes; + $this->beStrictAboutChangesToGlobalState = $beStrictAboutChangesToGlobalState; + $this->beStrictAboutResourceUsageDuringSmallTests = $beStrictAboutResourceUsageDuringSmallTests; + $this->bootstrap = $bootstrap; + $this->cacheResult = $cacheResult; + $this->cacheResultFile = $cacheResultFile; + $this->checkVersion = $checkVersion; + $this->colors = $colors; + $this->columns = $columns; + $this->configuration = $configuration; + $this->coverageFilter = $coverageFilter; + $this->coverageClover = $coverageClover; + $this->coverageCobertura = $coverageCobertura; + $this->coverageCrap4J = $coverageCrap4J; + $this->coverageHtml = $coverageHtml; + $this->coveragePhp = $coveragePhp; + $this->coverageText = $coverageText; + $this->coverageTextShowUncoveredFiles = $coverageTextShowUncoveredFiles; + $this->coverageTextShowOnlySummary = $coverageTextShowOnlySummary; + $this->coverageXml = $coverageXml; + $this->pathCoverage = $pathCoverage; + $this->coverageCacheDirectory = $coverageCacheDirectory; + $this->warmCoverageCache = $warmCoverageCache; + $this->debug = $debug; + $this->defaultTimeLimit = $defaultTimeLimit; + $this->disableCodeCoverageIgnore = $disableCodeCoverageIgnore; + $this->disallowTestOutput = $disallowTestOutput; + $this->disallowTodoAnnotatedTests = $disallowTodoAnnotatedTests; + $this->enforceTimeLimit = $enforceTimeLimit; + $this->excludeGroups = $excludeGroups; + $this->executionOrder = $executionOrder; + $this->executionOrderDefects = $executionOrderDefects; + $this->extensions = $extensions; + $this->unavailableExtensions = $unavailableExtensions; + $this->failOnEmptyTestSuite = $failOnEmptyTestSuite; + $this->failOnIncomplete = $failOnIncomplete; + $this->failOnRisky = $failOnRisky; + $this->failOnSkipped = $failOnSkipped; + $this->failOnWarning = $failOnWarning; + $this->filter = $filter; + $this->generateConfiguration = $generateConfiguration; + $this->migrateConfiguration = $migrateConfiguration; + $this->groups = $groups; + $this->testsCovering = $testsCovering; + $this->testsUsing = $testsUsing; + $this->help = $help; + $this->includePath = $includePath; + $this->iniSettings = $iniSettings; + $this->junitLogfile = $junitLogfile; + $this->listGroups = $listGroups; + $this->listSuites = $listSuites; + $this->listTests = $listTests; + $this->listTestsXml = $listTestsXml; + $this->loader = $loader; + $this->noCoverage = $noCoverage; + $this->noExtensions = $noExtensions; + $this->noInteraction = $noInteraction; + $this->noLogging = $noLogging; + $this->printer = $printer; + $this->processIsolation = $processIsolation; + $this->randomOrderSeed = $randomOrderSeed; + $this->repeat = $repeat; + $this->reportUselessTests = $reportUselessTests; + $this->resolveDependencies = $resolveDependencies; + $this->reverseList = $reverseList; + $this->stderr = $stderr; + $this->strictCoverage = $strictCoverage; + $this->stopOnDefect = $stopOnDefect; + $this->stopOnError = $stopOnError; + $this->stopOnFailure = $stopOnFailure; + $this->stopOnIncomplete = $stopOnIncomplete; + $this->stopOnRisky = $stopOnRisky; + $this->stopOnSkipped = $stopOnSkipped; + $this->stopOnWarning = $stopOnWarning; + $this->teamcityLogfile = $teamcityLogfile; + $this->testdoxExcludeGroups = $testdoxExcludeGroups; + $this->testdoxGroups = $testdoxGroups; + $this->testdoxHtmlFile = $testdoxHtmlFile; + $this->testdoxTextFile = $testdoxTextFile; + $this->testdoxXmlFile = $testdoxXmlFile; + $this->testSuffixes = $testSuffixes; + $this->testSuite = $testSuite; + $this->unrecognizedOptions = $unrecognizedOptions; + $this->unrecognizedOrderBy = $unrecognizedOrderBy; + $this->useDefaultConfiguration = $useDefaultConfiguration; + $this->verbose = $verbose; + $this->version = $version; + $this->xdebugFilterFile = $xdebugFilterFile; + } + + public function hasArgument(): bool + { + return $this->argument !== null; + } + + /** + * @throws Exception + */ + public function argument(): string + { + if ($this->argument === null) { + throw new Exception; + } + + return $this->argument; + } + + public function hasAtLeastVersion(): bool + { + return $this->atLeastVersion !== null; + } + + /** + * @throws Exception + */ + public function atLeastVersion(): string + { + if ($this->atLeastVersion === null) { + throw new Exception; + } + + return $this->atLeastVersion; + } + + public function hasBackupGlobals(): bool + { + return $this->backupGlobals !== null; + } + + /** + * @throws Exception + */ + public function backupGlobals(): bool + { + if ($this->backupGlobals === null) { + throw new Exception; + } + + return $this->backupGlobals; + } + + public function hasBackupStaticAttributes(): bool + { + return $this->backupStaticAttributes !== null; + } + + /** + * @throws Exception + */ + public function backupStaticAttributes(): bool + { + if ($this->backupStaticAttributes === null) { + throw new Exception; + } + + return $this->backupStaticAttributes; + } + + public function hasBeStrictAboutChangesToGlobalState(): bool + { + return $this->beStrictAboutChangesToGlobalState !== null; + } + + /** + * @throws Exception + */ + public function beStrictAboutChangesToGlobalState(): bool + { + if ($this->beStrictAboutChangesToGlobalState === null) { + throw new Exception; + } + + return $this->beStrictAboutChangesToGlobalState; + } + + public function hasBeStrictAboutResourceUsageDuringSmallTests(): bool + { + return $this->beStrictAboutResourceUsageDuringSmallTests !== null; + } + + /** + * @throws Exception + */ + public function beStrictAboutResourceUsageDuringSmallTests(): bool + { + if ($this->beStrictAboutResourceUsageDuringSmallTests === null) { + throw new Exception; + } + + return $this->beStrictAboutResourceUsageDuringSmallTests; + } + + public function hasBootstrap(): bool + { + return $this->bootstrap !== null; + } + + /** + * @throws Exception + */ + public function bootstrap(): string + { + if ($this->bootstrap === null) { + throw new Exception; + } + + return $this->bootstrap; + } + + public function hasCacheResult(): bool + { + return $this->cacheResult !== null; + } + + /** + * @throws Exception + */ + public function cacheResult(): bool + { + if ($this->cacheResult === null) { + throw new Exception; + } + + return $this->cacheResult; + } + + public function hasCacheResultFile(): bool + { + return $this->cacheResultFile !== null; + } + + /** + * @throws Exception + */ + public function cacheResultFile(): string + { + if ($this->cacheResultFile === null) { + throw new Exception; + } + + return $this->cacheResultFile; + } + + public function hasCheckVersion(): bool + { + return $this->checkVersion !== null; + } + + /** + * @throws Exception + */ + public function checkVersion(): bool + { + if ($this->checkVersion === null) { + throw new Exception; + } + + return $this->checkVersion; + } + + public function hasColors(): bool + { + return $this->colors !== null; + } + + /** + * @throws Exception + */ + public function colors(): string + { + if ($this->colors === null) { + throw new Exception; + } + + return $this->colors; + } + + public function hasColumns(): bool + { + return $this->columns !== null; + } + + /** + * @throws Exception + */ + public function columns() + { + if ($this->columns === null) { + throw new Exception; + } + + return $this->columns; + } + + public function hasConfiguration(): bool + { + return $this->configuration !== null; + } + + /** + * @throws Exception + */ + public function configuration(): string + { + if ($this->configuration === null) { + throw new Exception; + } + + return $this->configuration; + } + + public function hasCoverageFilter(): bool + { + return $this->coverageFilter !== null; + } + + /** + * @throws Exception + */ + public function coverageFilter(): array + { + if ($this->coverageFilter === null) { + throw new Exception; + } + + return $this->coverageFilter; + } + + public function hasCoverageClover(): bool + { + return $this->coverageClover !== null; + } + + /** + * @throws Exception + */ + public function coverageClover(): string + { + if ($this->coverageClover === null) { + throw new Exception; + } + + return $this->coverageClover; + } + + public function hasCoverageCobertura(): bool + { + return $this->coverageCobertura !== null; + } + + /** + * @throws Exception + */ + public function coverageCobertura(): string + { + if ($this->coverageCobertura === null) { + throw new Exception; + } + + return $this->coverageCobertura; + } + + public function hasCoverageCrap4J(): bool + { + return $this->coverageCrap4J !== null; + } + + /** + * @throws Exception + */ + public function coverageCrap4J(): string + { + if ($this->coverageCrap4J === null) { + throw new Exception; + } + + return $this->coverageCrap4J; + } + + public function hasCoverageHtml(): bool + { + return $this->coverageHtml !== null; + } + + /** + * @throws Exception + */ + public function coverageHtml(): string + { + if ($this->coverageHtml === null) { + throw new Exception; + } + + return $this->coverageHtml; + } + + public function hasCoveragePhp(): bool + { + return $this->coveragePhp !== null; + } + + /** + * @throws Exception + */ + public function coveragePhp(): string + { + if ($this->coveragePhp === null) { + throw new Exception; + } + + return $this->coveragePhp; + } + + public function hasCoverageText(): bool + { + return $this->coverageText !== null; + } + + /** + * @throws Exception + */ + public function coverageText(): string + { + if ($this->coverageText === null) { + throw new Exception; + } + + return $this->coverageText; + } + + public function hasCoverageTextShowUncoveredFiles(): bool + { + return $this->coverageTextShowUncoveredFiles !== null; + } + + /** + * @throws Exception + */ + public function coverageTextShowUncoveredFiles(): bool + { + if ($this->coverageTextShowUncoveredFiles === null) { + throw new Exception; + } + + return $this->coverageTextShowUncoveredFiles; + } + + public function hasCoverageTextShowOnlySummary(): bool + { + return $this->coverageTextShowOnlySummary !== null; + } + + /** + * @throws Exception + */ + public function coverageTextShowOnlySummary(): bool + { + if ($this->coverageTextShowOnlySummary === null) { + throw new Exception; + } + + return $this->coverageTextShowOnlySummary; + } + + public function hasCoverageXml(): bool + { + return $this->coverageXml !== null; + } + + /** + * @throws Exception + */ + public function coverageXml(): string + { + if ($this->coverageXml === null) { + throw new Exception; + } + + return $this->coverageXml; + } + + public function hasPathCoverage(): bool + { + return $this->pathCoverage !== null; + } + + /** + * @throws Exception + */ + public function pathCoverage(): bool + { + if ($this->pathCoverage === null) { + throw new Exception; + } + + return $this->pathCoverage; + } + + public function hasCoverageCacheDirectory(): bool + { + return $this->coverageCacheDirectory !== null; + } + + /** + * @throws Exception + */ + public function coverageCacheDirectory(): string + { + if ($this->coverageCacheDirectory === null) { + throw new Exception; + } + + return $this->coverageCacheDirectory; + } + + public function hasWarmCoverageCache(): bool + { + return $this->warmCoverageCache !== null; + } + + /** + * @throws Exception + */ + public function warmCoverageCache(): bool + { + if ($this->warmCoverageCache === null) { + throw new Exception; + } + + return $this->warmCoverageCache; + } + + public function hasDebug(): bool + { + return $this->debug !== null; + } + + /** + * @throws Exception + */ + public function debug(): bool + { + if ($this->debug === null) { + throw new Exception; + } + + return $this->debug; + } + + public function hasDefaultTimeLimit(): bool + { + return $this->defaultTimeLimit !== null; + } + + /** + * @throws Exception + */ + public function defaultTimeLimit(): int + { + if ($this->defaultTimeLimit === null) { + throw new Exception; + } + + return $this->defaultTimeLimit; + } + + public function hasDisableCodeCoverageIgnore(): bool + { + return $this->disableCodeCoverageIgnore !== null; + } + + /** + * @throws Exception + */ + public function disableCodeCoverageIgnore(): bool + { + if ($this->disableCodeCoverageIgnore === null) { + throw new Exception; + } + + return $this->disableCodeCoverageIgnore; + } + + public function hasDisallowTestOutput(): bool + { + return $this->disallowTestOutput !== null; + } + + /** + * @throws Exception + */ + public function disallowTestOutput(): bool + { + if ($this->disallowTestOutput === null) { + throw new Exception; + } + + return $this->disallowTestOutput; + } + + public function hasDisallowTodoAnnotatedTests(): bool + { + return $this->disallowTodoAnnotatedTests !== null; + } + + /** + * @throws Exception + */ + public function disallowTodoAnnotatedTests(): bool + { + if ($this->disallowTodoAnnotatedTests === null) { + throw new Exception; + } + + return $this->disallowTodoAnnotatedTests; + } + + public function hasEnforceTimeLimit(): bool + { + return $this->enforceTimeLimit !== null; + } + + /** + * @throws Exception + */ + public function enforceTimeLimit(): bool + { + if ($this->enforceTimeLimit === null) { + throw new Exception; + } + + return $this->enforceTimeLimit; + } + + public function hasExcludeGroups(): bool + { + return $this->excludeGroups !== null; + } + + /** + * @throws Exception + */ + public function excludeGroups(): array + { + if ($this->excludeGroups === null) { + throw new Exception; + } + + return $this->excludeGroups; + } + + public function hasExecutionOrder(): bool + { + return $this->executionOrder !== null; + } + + /** + * @throws Exception + */ + public function executionOrder(): int + { + if ($this->executionOrder === null) { + throw new Exception; + } + + return $this->executionOrder; + } + + public function hasExecutionOrderDefects(): bool + { + return $this->executionOrderDefects !== null; + } + + /** + * @throws Exception + */ + public function executionOrderDefects(): int + { + if ($this->executionOrderDefects === null) { + throw new Exception; + } + + return $this->executionOrderDefects; + } + + public function hasFailOnEmptyTestSuite(): bool + { + return $this->failOnEmptyTestSuite !== null; + } + + /** + * @throws Exception + */ + public function failOnEmptyTestSuite(): bool + { + if ($this->failOnEmptyTestSuite === null) { + throw new Exception; + } + + return $this->failOnEmptyTestSuite; + } + + public function hasFailOnIncomplete(): bool + { + return $this->failOnIncomplete !== null; + } + + /** + * @throws Exception + */ + public function failOnIncomplete(): bool + { + if ($this->failOnIncomplete === null) { + throw new Exception; + } + + return $this->failOnIncomplete; + } + + public function hasFailOnRisky(): bool + { + return $this->failOnRisky !== null; + } + + /** + * @throws Exception + */ + public function failOnRisky(): bool + { + if ($this->failOnRisky === null) { + throw new Exception; + } + + return $this->failOnRisky; + } + + public function hasFailOnSkipped(): bool + { + return $this->failOnSkipped !== null; + } + + /** + * @throws Exception + */ + public function failOnSkipped(): bool + { + if ($this->failOnSkipped === null) { + throw new Exception; + } + + return $this->failOnSkipped; + } + + public function hasFailOnWarning(): bool + { + return $this->failOnWarning !== null; + } + + /** + * @throws Exception + */ + public function failOnWarning(): bool + { + if ($this->failOnWarning === null) { + throw new Exception; + } + + return $this->failOnWarning; + } + + public function hasFilter(): bool + { + return $this->filter !== null; + } + + /** + * @throws Exception + */ + public function filter(): string + { + if ($this->filter === null) { + throw new Exception; + } + + return $this->filter; + } + + public function hasGenerateConfiguration(): bool + { + return $this->generateConfiguration !== null; + } + + /** + * @throws Exception + */ + public function generateConfiguration(): bool + { + if ($this->generateConfiguration === null) { + throw new Exception; + } + + return $this->generateConfiguration; + } + + public function hasMigrateConfiguration(): bool + { + return $this->migrateConfiguration !== null; + } + + /** + * @throws Exception + */ + public function migrateConfiguration(): bool + { + if ($this->migrateConfiguration === null) { + throw new Exception; + } + + return $this->migrateConfiguration; + } + + public function hasGroups(): bool + { + return $this->groups !== null; + } + + /** + * @throws Exception + */ + public function groups(): array + { + if ($this->groups === null) { + throw new Exception; + } + + return $this->groups; + } + + public function hasTestsCovering(): bool + { + return $this->testsCovering !== null; + } + + /** + * @throws Exception + */ + public function testsCovering(): array + { + if ($this->testsCovering === null) { + throw new Exception; + } + + return $this->testsCovering; + } + + public function hasTestsUsing(): bool + { + return $this->testsUsing !== null; + } + + /** + * @throws Exception + */ + public function testsUsing(): array + { + if ($this->testsUsing === null) { + throw new Exception; + } + + return $this->testsUsing; + } + + public function hasHelp(): bool + { + return $this->help !== null; + } + + /** + * @throws Exception + */ + public function help(): bool + { + if ($this->help === null) { + throw new Exception; + } + + return $this->help; + } + + public function hasIncludePath(): bool + { + return $this->includePath !== null; + } + + /** + * @throws Exception + */ + public function includePath(): string + { + if ($this->includePath === null) { + throw new Exception; + } + + return $this->includePath; + } + + public function hasIniSettings(): bool + { + return $this->iniSettings !== null; + } + + /** + * @throws Exception + */ + public function iniSettings(): array + { + if ($this->iniSettings === null) { + throw new Exception; + } + + return $this->iniSettings; + } + + public function hasJunitLogfile(): bool + { + return $this->junitLogfile !== null; + } + + /** + * @throws Exception + */ + public function junitLogfile(): string + { + if ($this->junitLogfile === null) { + throw new Exception; + } + + return $this->junitLogfile; + } + + public function hasListGroups(): bool + { + return $this->listGroups !== null; + } + + /** + * @throws Exception + */ + public function listGroups(): bool + { + if ($this->listGroups === null) { + throw new Exception; + } + + return $this->listGroups; + } + + public function hasListSuites(): bool + { + return $this->listSuites !== null; + } + + /** + * @throws Exception + */ + public function listSuites(): bool + { + if ($this->listSuites === null) { + throw new Exception; + } + + return $this->listSuites; + } + + public function hasListTests(): bool + { + return $this->listTests !== null; + } + + /** + * @throws Exception + */ + public function listTests(): bool + { + if ($this->listTests === null) { + throw new Exception; + } + + return $this->listTests; + } + + public function hasListTestsXml(): bool + { + return $this->listTestsXml !== null; + } + + /** + * @throws Exception + */ + public function listTestsXml(): string + { + if ($this->listTestsXml === null) { + throw new Exception; + } + + return $this->listTestsXml; + } + + public function hasLoader(): bool + { + return $this->loader !== null; + } + + /** + * @throws Exception + */ + public function loader(): string + { + if ($this->loader === null) { + throw new Exception; + } + + return $this->loader; + } + + public function hasNoCoverage(): bool + { + return $this->noCoverage !== null; + } + + /** + * @throws Exception + */ + public function noCoverage(): bool + { + if ($this->noCoverage === null) { + throw new Exception; + } + + return $this->noCoverage; + } + + public function hasNoExtensions(): bool + { + return $this->noExtensions !== null; + } + + /** + * @throws Exception + */ + public function noExtensions(): bool + { + if ($this->noExtensions === null) { + throw new Exception; + } + + return $this->noExtensions; + } + + public function hasExtensions(): bool + { + return $this->extensions !== null; + } + + /** + * @throws Exception + */ + public function extensions(): array + { + if ($this->extensions === null) { + throw new Exception; + } + + return $this->extensions; + } + + public function hasUnavailableExtensions(): bool + { + return $this->unavailableExtensions !== null; + } + + /** + * @throws Exception + */ + public function unavailableExtensions(): array + { + if ($this->unavailableExtensions === null) { + throw new Exception; + } + + return $this->unavailableExtensions; + } + + public function hasNoInteraction(): bool + { + return $this->noInteraction !== null; + } + + /** + * @throws Exception + */ + public function noInteraction(): bool + { + if ($this->noInteraction === null) { + throw new Exception; + } + + return $this->noInteraction; + } + + public function hasNoLogging(): bool + { + return $this->noLogging !== null; + } + + /** + * @throws Exception + */ + public function noLogging(): bool + { + if ($this->noLogging === null) { + throw new Exception; + } + + return $this->noLogging; + } + + public function hasPrinter(): bool + { + return $this->printer !== null; + } + + /** + * @throws Exception + */ + public function printer(): string + { + if ($this->printer === null) { + throw new Exception; + } + + return $this->printer; + } + + public function hasProcessIsolation(): bool + { + return $this->processIsolation !== null; + } + + /** + * @throws Exception + */ + public function processIsolation(): bool + { + if ($this->processIsolation === null) { + throw new Exception; + } + + return $this->processIsolation; + } + + public function hasRandomOrderSeed(): bool + { + return $this->randomOrderSeed !== null; + } + + /** + * @throws Exception + */ + public function randomOrderSeed(): int + { + if ($this->randomOrderSeed === null) { + throw new Exception; + } + + return $this->randomOrderSeed; + } + + public function hasRepeat(): bool + { + return $this->repeat !== null; + } + + /** + * @throws Exception + */ + public function repeat(): int + { + if ($this->repeat === null) { + throw new Exception; + } + + return $this->repeat; + } + + public function hasReportUselessTests(): bool + { + return $this->reportUselessTests !== null; + } + + /** + * @throws Exception + */ + public function reportUselessTests(): bool + { + if ($this->reportUselessTests === null) { + throw new Exception; + } + + return $this->reportUselessTests; + } + + public function hasResolveDependencies(): bool + { + return $this->resolveDependencies !== null; + } + + /** + * @throws Exception + */ + public function resolveDependencies(): bool + { + if ($this->resolveDependencies === null) { + throw new Exception; + } + + return $this->resolveDependencies; + } + + public function hasReverseList(): bool + { + return $this->reverseList !== null; + } + + /** + * @throws Exception + */ + public function reverseList(): bool + { + if ($this->reverseList === null) { + throw new Exception; + } + + return $this->reverseList; + } + + public function hasStderr(): bool + { + return $this->stderr !== null; + } + + /** + * @throws Exception + */ + public function stderr(): bool + { + if ($this->stderr === null) { + throw new Exception; + } + + return $this->stderr; + } + + public function hasStrictCoverage(): bool + { + return $this->strictCoverage !== null; + } + + /** + * @throws Exception + */ + public function strictCoverage(): bool + { + if ($this->strictCoverage === null) { + throw new Exception; + } + + return $this->strictCoverage; + } + + public function hasStopOnDefect(): bool + { + return $this->stopOnDefect !== null; + } + + /** + * @throws Exception + */ + public function stopOnDefect(): bool + { + if ($this->stopOnDefect === null) { + throw new Exception; + } + + return $this->stopOnDefect; + } + + public function hasStopOnError(): bool + { + return $this->stopOnError !== null; + } + + /** + * @throws Exception + */ + public function stopOnError(): bool + { + if ($this->stopOnError === null) { + throw new Exception; + } + + return $this->stopOnError; + } + + public function hasStopOnFailure(): bool + { + return $this->stopOnFailure !== null; + } + + /** + * @throws Exception + */ + public function stopOnFailure(): bool + { + if ($this->stopOnFailure === null) { + throw new Exception; + } + + return $this->stopOnFailure; + } + + public function hasStopOnIncomplete(): bool + { + return $this->stopOnIncomplete !== null; + } + + /** + * @throws Exception + */ + public function stopOnIncomplete(): bool + { + if ($this->stopOnIncomplete === null) { + throw new Exception; + } + + return $this->stopOnIncomplete; + } + + public function hasStopOnRisky(): bool + { + return $this->stopOnRisky !== null; + } + + /** + * @throws Exception + */ + public function stopOnRisky(): bool + { + if ($this->stopOnRisky === null) { + throw new Exception; + } + + return $this->stopOnRisky; + } + + public function hasStopOnSkipped(): bool + { + return $this->stopOnSkipped !== null; + } + + /** + * @throws Exception + */ + public function stopOnSkipped(): bool + { + if ($this->stopOnSkipped === null) { + throw new Exception; + } + + return $this->stopOnSkipped; + } + + public function hasStopOnWarning(): bool + { + return $this->stopOnWarning !== null; + } + + /** + * @throws Exception + */ + public function stopOnWarning(): bool + { + if ($this->stopOnWarning === null) { + throw new Exception; + } + + return $this->stopOnWarning; + } + + public function hasTeamcityLogfile(): bool + { + return $this->teamcityLogfile !== null; + } + + /** + * @throws Exception + */ + public function teamcityLogfile(): string + { + if ($this->teamcityLogfile === null) { + throw new Exception; + } + + return $this->teamcityLogfile; + } + + public function hasTestdoxExcludeGroups(): bool + { + return $this->testdoxExcludeGroups !== null; + } + + /** + * @throws Exception + */ + public function testdoxExcludeGroups(): array + { + if ($this->testdoxExcludeGroups === null) { + throw new Exception; + } + + return $this->testdoxExcludeGroups; + } + + public function hasTestdoxGroups(): bool + { + return $this->testdoxGroups !== null; + } + + /** + * @throws Exception + */ + public function testdoxGroups(): array + { + if ($this->testdoxGroups === null) { + throw new Exception; + } + + return $this->testdoxGroups; + } + + public function hasTestdoxHtmlFile(): bool + { + return $this->testdoxHtmlFile !== null; + } + + /** + * @throws Exception + */ + public function testdoxHtmlFile(): string + { + if ($this->testdoxHtmlFile === null) { + throw new Exception; + } + + return $this->testdoxHtmlFile; + } + + public function hasTestdoxTextFile(): bool + { + return $this->testdoxTextFile !== null; + } + + /** + * @throws Exception + */ + public function testdoxTextFile(): string + { + if ($this->testdoxTextFile === null) { + throw new Exception; + } + + return $this->testdoxTextFile; + } + + public function hasTestdoxXmlFile(): bool + { + return $this->testdoxXmlFile !== null; + } + + /** + * @throws Exception + */ + public function testdoxXmlFile(): string + { + if ($this->testdoxXmlFile === null) { + throw new Exception; + } + + return $this->testdoxXmlFile; + } + + public function hasTestSuffixes(): bool + { + return $this->testSuffixes !== null; + } + + /** + * @throws Exception + */ + public function testSuffixes(): array + { + if ($this->testSuffixes === null) { + throw new Exception; + } + + return $this->testSuffixes; + } + + public function hasTestSuite(): bool + { + return $this->testSuite !== null; + } + + /** + * @throws Exception + */ + public function testSuite(): string + { + if ($this->testSuite === null) { + throw new Exception; + } + + return $this->testSuite; + } + + public function unrecognizedOptions(): array + { + return $this->unrecognizedOptions; + } + + public function hasUnrecognizedOrderBy(): bool + { + return $this->unrecognizedOrderBy !== null; + } + + /** + * @throws Exception + */ + public function unrecognizedOrderBy(): string + { + if ($this->unrecognizedOrderBy === null) { + throw new Exception; + } + + return $this->unrecognizedOrderBy; + } + + public function hasUseDefaultConfiguration(): bool + { + return $this->useDefaultConfiguration !== null; + } + + /** + * @throws Exception + */ + public function useDefaultConfiguration(): bool + { + if ($this->useDefaultConfiguration === null) { + throw new Exception; + } + + return $this->useDefaultConfiguration; + } + + public function hasVerbose(): bool + { + return $this->verbose !== null; + } + + /** + * @throws Exception + */ + public function verbose(): bool + { + if ($this->verbose === null) { + throw new Exception; + } + + return $this->verbose; + } + + public function hasVersion(): bool + { + return $this->version !== null; + } + + /** + * @throws Exception + */ + public function version(): bool + { + if ($this->version === null) { + throw new Exception; + } + + return $this->version; + } + + public function hasXdebugFilterFile(): bool + { + return $this->xdebugFilterFile !== null; + } + + /** + * @throws Exception + */ + public function xdebugFilterFile(): string + { + if ($this->xdebugFilterFile === null) { + throw new Exception; + } + + return $this->xdebugFilterFile; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/CliArguments/Exception.php b/vendor/phpunit/phpunit/src/TextUI/CliArguments/Exception.php new file mode 100644 index 000000000..dd5536eaa --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/CliArguments/Exception.php @@ -0,0 +1,19 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\CliArguments; + +use RuntimeException; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class Exception extends RuntimeException implements \PHPUnit\Exception +{ +} diff --git a/vendor/phpunit/phpunit/src/TextUI/CliArguments/Mapper.php b/vendor/phpunit/phpunit/src/TextUI/CliArguments/Mapper.php new file mode 100644 index 000000000..9ceb8ab47 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/CliArguments/Mapper.php @@ -0,0 +1,365 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\CliArguments; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class Mapper +{ + /** + * @throws Exception + */ + public function mapToLegacyArray(Configuration $arguments): array + { + $result = [ + 'extensions' => [], + 'listGroups' => false, + 'listSuites' => false, + 'listTests' => false, + 'listTestsXml' => false, + 'loader' => null, + 'useDefaultConfiguration' => true, + 'loadedExtensions' => [], + 'unavailableExtensions' => [], + 'notLoadedExtensions' => [], + ]; + + if ($arguments->hasColors()) { + $result['colors'] = $arguments->colors(); + } + + if ($arguments->hasBootstrap()) { + $result['bootstrap'] = $arguments->bootstrap(); + } + + if ($arguments->hasCacheResult()) { + $result['cacheResult'] = $arguments->cacheResult(); + } + + if ($arguments->hasCacheResultFile()) { + $result['cacheResultFile'] = $arguments->cacheResultFile(); + } + + if ($arguments->hasColumns()) { + $result['columns'] = $arguments->columns(); + } + + if ($arguments->hasConfiguration()) { + $result['configuration'] = $arguments->configuration(); + } + + if ($arguments->hasCoverageCacheDirectory()) { + $result['coverageCacheDirectory'] = $arguments->coverageCacheDirectory(); + } + + if ($arguments->hasWarmCoverageCache()) { + $result['warmCoverageCache'] = $arguments->warmCoverageCache(); + } + + if ($arguments->hasCoverageClover()) { + $result['coverageClover'] = $arguments->coverageClover(); + } + + if ($arguments->hasCoverageCobertura()) { + $result['coverageCobertura'] = $arguments->coverageCobertura(); + } + + if ($arguments->hasCoverageCrap4J()) { + $result['coverageCrap4J'] = $arguments->coverageCrap4J(); + } + + if ($arguments->hasCoverageHtml()) { + $result['coverageHtml'] = $arguments->coverageHtml(); + } + + if ($arguments->hasCoveragePhp()) { + $result['coveragePHP'] = $arguments->coveragePhp(); + } + + if ($arguments->hasCoverageText()) { + $result['coverageText'] = $arguments->coverageText(); + } + + if ($arguments->hasCoverageTextShowUncoveredFiles()) { + $result['coverageTextShowUncoveredFiles'] = $arguments->hasCoverageTextShowUncoveredFiles(); + } + + if ($arguments->hasCoverageTextShowOnlySummary()) { + $result['coverageTextShowOnlySummary'] = $arguments->coverageTextShowOnlySummary(); + } + + if ($arguments->hasCoverageXml()) { + $result['coverageXml'] = $arguments->coverageXml(); + } + + if ($arguments->hasPathCoverage()) { + $result['pathCoverage'] = $arguments->pathCoverage(); + } + + if ($arguments->hasDebug()) { + $result['debug'] = $arguments->debug(); + } + + if ($arguments->hasHelp()) { + $result['help'] = $arguments->help(); + } + + if ($arguments->hasFilter()) { + $result['filter'] = $arguments->filter(); + } + + if ($arguments->hasTestSuite()) { + $result['testsuite'] = $arguments->testSuite(); + } + + if ($arguments->hasGroups()) { + $result['groups'] = $arguments->groups(); + } + + if ($arguments->hasExcludeGroups()) { + $result['excludeGroups'] = $arguments->excludeGroups(); + } + + if ($arguments->hasTestsCovering()) { + $result['testsCovering'] = $arguments->testsCovering(); + } + + if ($arguments->hasTestsUsing()) { + $result['testsUsing'] = $arguments->testsUsing(); + } + + if ($arguments->hasTestSuffixes()) { + $result['testSuffixes'] = $arguments->testSuffixes(); + } + + if ($arguments->hasIncludePath()) { + $result['includePath'] = $arguments->includePath(); + } + + if ($arguments->hasListGroups()) { + $result['listGroups'] = $arguments->listGroups(); + } + + if ($arguments->hasListSuites()) { + $result['listSuites'] = $arguments->listSuites(); + } + + if ($arguments->hasListTests()) { + $result['listTests'] = $arguments->listTests(); + } + + if ($arguments->hasListTestsXml()) { + $result['listTestsXml'] = $arguments->listTestsXml(); + } + + if ($arguments->hasPrinter()) { + $result['printer'] = $arguments->printer(); + } + + if ($arguments->hasLoader()) { + $result['loader'] = $arguments->loader(); + } + + if ($arguments->hasJunitLogfile()) { + $result['junitLogfile'] = $arguments->junitLogfile(); + } + + if ($arguments->hasTeamcityLogfile()) { + $result['teamcityLogfile'] = $arguments->teamcityLogfile(); + } + + if ($arguments->hasExecutionOrder()) { + $result['executionOrder'] = $arguments->executionOrder(); + } + + if ($arguments->hasExecutionOrderDefects()) { + $result['executionOrderDefects'] = $arguments->executionOrderDefects(); + } + + if ($arguments->hasExtensions()) { + $result['extensions'] = $arguments->extensions(); + } + + if ($arguments->hasUnavailableExtensions()) { + $result['unavailableExtensions'] = $arguments->unavailableExtensions(); + } + + if ($arguments->hasResolveDependencies()) { + $result['resolveDependencies'] = $arguments->resolveDependencies(); + } + + if ($arguments->hasProcessIsolation()) { + $result['processIsolation'] = $arguments->processIsolation(); + } + + if ($arguments->hasRepeat()) { + $result['repeat'] = $arguments->repeat(); + } + + if ($arguments->hasStderr()) { + $result['stderr'] = $arguments->stderr(); + } + + if ($arguments->hasStopOnDefect()) { + $result['stopOnDefect'] = $arguments->stopOnDefect(); + } + + if ($arguments->hasStopOnError()) { + $result['stopOnError'] = $arguments->stopOnError(); + } + + if ($arguments->hasStopOnFailure()) { + $result['stopOnFailure'] = $arguments->stopOnFailure(); + } + + if ($arguments->hasStopOnWarning()) { + $result['stopOnWarning'] = $arguments->stopOnWarning(); + } + + if ($arguments->hasStopOnIncomplete()) { + $result['stopOnIncomplete'] = $arguments->stopOnIncomplete(); + } + + if ($arguments->hasStopOnRisky()) { + $result['stopOnRisky'] = $arguments->stopOnRisky(); + } + + if ($arguments->hasStopOnSkipped()) { + $result['stopOnSkipped'] = $arguments->stopOnSkipped(); + } + + if ($arguments->hasFailOnEmptyTestSuite()) { + $result['failOnEmptyTestSuite'] = $arguments->failOnEmptyTestSuite(); + } + + if ($arguments->hasFailOnIncomplete()) { + $result['failOnIncomplete'] = $arguments->failOnIncomplete(); + } + + if ($arguments->hasFailOnRisky()) { + $result['failOnRisky'] = $arguments->failOnRisky(); + } + + if ($arguments->hasFailOnSkipped()) { + $result['failOnSkipped'] = $arguments->failOnSkipped(); + } + + if ($arguments->hasFailOnWarning()) { + $result['failOnWarning'] = $arguments->failOnWarning(); + } + + if ($arguments->hasTestdoxGroups()) { + $result['testdoxGroups'] = $arguments->testdoxGroups(); + } + + if ($arguments->hasTestdoxExcludeGroups()) { + $result['testdoxExcludeGroups'] = $arguments->testdoxExcludeGroups(); + } + + if ($arguments->hasTestdoxHtmlFile()) { + $result['testdoxHTMLFile'] = $arguments->testdoxHtmlFile(); + } + + if ($arguments->hasTestdoxTextFile()) { + $result['testdoxTextFile'] = $arguments->testdoxTextFile(); + } + + if ($arguments->hasTestdoxXmlFile()) { + $result['testdoxXMLFile'] = $arguments->testdoxXmlFile(); + } + + if ($arguments->hasUseDefaultConfiguration()) { + $result['useDefaultConfiguration'] = $arguments->useDefaultConfiguration(); + } + + if ($arguments->hasNoExtensions()) { + $result['noExtensions'] = $arguments->noExtensions(); + } + + if ($arguments->hasNoCoverage()) { + $result['noCoverage'] = $arguments->noCoverage(); + } + + if ($arguments->hasNoLogging()) { + $result['noLogging'] = $arguments->noLogging(); + } + + if ($arguments->hasNoInteraction()) { + $result['noInteraction'] = $arguments->noInteraction(); + } + + if ($arguments->hasBackupGlobals()) { + $result['backupGlobals'] = $arguments->backupGlobals(); + } + + if ($arguments->hasBackupStaticAttributes()) { + $result['backupStaticAttributes'] = $arguments->backupStaticAttributes(); + } + + if ($arguments->hasVerbose()) { + $result['verbose'] = $arguments->verbose(); + } + + if ($arguments->hasReportUselessTests()) { + $result['reportUselessTests'] = $arguments->reportUselessTests(); + } + + if ($arguments->hasStrictCoverage()) { + $result['strictCoverage'] = $arguments->strictCoverage(); + } + + if ($arguments->hasDisableCodeCoverageIgnore()) { + $result['disableCodeCoverageIgnore'] = $arguments->disableCodeCoverageIgnore(); + } + + if ($arguments->hasBeStrictAboutChangesToGlobalState()) { + $result['beStrictAboutChangesToGlobalState'] = $arguments->beStrictAboutChangesToGlobalState(); + } + + if ($arguments->hasDisallowTestOutput()) { + $result['disallowTestOutput'] = $arguments->disallowTestOutput(); + } + + if ($arguments->hasBeStrictAboutResourceUsageDuringSmallTests()) { + $result['beStrictAboutResourceUsageDuringSmallTests'] = $arguments->beStrictAboutResourceUsageDuringSmallTests(); + } + + if ($arguments->hasDefaultTimeLimit()) { + $result['defaultTimeLimit'] = $arguments->defaultTimeLimit(); + } + + if ($arguments->hasEnforceTimeLimit()) { + $result['enforceTimeLimit'] = $arguments->enforceTimeLimit(); + } + + if ($arguments->hasDisallowTodoAnnotatedTests()) { + $result['disallowTodoAnnotatedTests'] = $arguments->disallowTodoAnnotatedTests(); + } + + if ($arguments->hasReverseList()) { + $result['reverseList'] = $arguments->reverseList(); + } + + if ($arguments->hasCoverageFilter()) { + $result['coverageFilter'] = $arguments->coverageFilter(); + } + + if ($arguments->hasRandomOrderSeed()) { + $result['randomOrderSeed'] = $arguments->randomOrderSeed(); + } + + if ($arguments->hasXdebugFilterFile()) { + $result['xdebugFilterFile'] = $arguments->xdebugFilterFile(); + } + + return $result; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/Command.php b/vendor/phpunit/phpunit/src/TextUI/Command.php index 7c245d890..e5dd7a01d 100644 --- a/vendor/phpunit/phpunit/src/TextUI/Command.php +++ b/vendor/phpunit/phpunit/src/TextUI/Command.php @@ -15,172 +15,67 @@ use const STDIN; use function array_keys; use function assert; use function class_exists; -use function explode; +use function copy; use function extension_loaded; use function fgets; -use function file_exists; use function file_get_contents; use function file_put_contents; +use function get_class; use function getcwd; use function ini_get; use function ini_set; use function is_callable; use function is_dir; use function is_file; -use function is_numeric; use function is_string; use function printf; use function realpath; use function sort; - use function sprintf; -use function str_replace; use function stream_resolve_include_path; -use function strrpos; -use function substr; +use function strpos; use function trim; use function version_compare; -use PharIo\Manifest\ApplicationName; -use PharIo\Manifest\Exception as ManifestException; -use PharIo\Manifest\ManifestLoader; -use PharIo\Version\Version as PharIoVersion; -use PHPUnit\Framework\Exception; -use PHPUnit\Framework\Test; -use PHPUnit\Framework\TestListener; use PHPUnit\Framework\TestSuite; +use PHPUnit\Runner\Extension\PharLoader; use PHPUnit\Runner\StandardTestSuiteLoader; use PHPUnit\Runner\TestSuiteLoader; -use PHPUnit\Runner\TestSuiteSorter; use PHPUnit\Runner\Version; -use PHPUnit\Util\Configuration; -use PHPUnit\Util\ConfigurationGenerator; +use PHPUnit\TextUI\CliArguments\Builder; +use PHPUnit\TextUI\CliArguments\Configuration; +use PHPUnit\TextUI\CliArguments\Exception as ArgumentsException; +use PHPUnit\TextUI\CliArguments\Mapper; +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\FilterMapper; +use PHPUnit\TextUI\XmlConfiguration\Generator; +use PHPUnit\TextUI\XmlConfiguration\Loader; +use PHPUnit\TextUI\XmlConfiguration\Migrator; +use PHPUnit\TextUI\XmlConfiguration\PhpHandler; use PHPUnit\Util\FileLoader; use PHPUnit\Util\Filesystem; -use PHPUnit\Util\Getopt; -use PHPUnit\Util\Log\TeamCity; use PHPUnit\Util\Printer; -use PHPUnit\Util\TestDox\CliTestDoxPrinter; use PHPUnit\Util\TextTestListRenderer; +use PHPUnit\Util\Xml\SchemaDetector; use PHPUnit\Util\XmlTestListRenderer; use ReflectionClass; -use ReflectionException; -use SebastianBergmann\FileIterator\Facade as FileIteratorFacade; +use SebastianBergmann\CodeCoverage\Filter; +use SebastianBergmann\CodeCoverage\StaticAnalysis\CacheWarmer; +use SebastianBergmann\Timer\Timer; use Throwable; /** - * A TestRunner for the Command Line Interface (CLI) - * PHP SAPI Module. + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ class Command { /** * @var array */ - protected $arguments = [ - 'listGroups' => false, - 'listSuites' => false, - 'listTests' => false, - 'listTestsXml' => false, - 'loader' => null, - 'useDefaultConfiguration' => true, - 'loadedExtensions' => [], - 'notLoadedExtensions' => [], - ]; + protected $arguments = []; /** * @var array */ - protected $options = []; - - /** - * @var array - */ - protected $longOptions = [ - 'atleast-version=' => null, - 'prepend=' => null, - 'bootstrap=' => null, - 'cache-result' => null, - 'do-not-cache-result' => null, - 'cache-result-file=' => null, - 'check-version' => null, - 'colors==' => null, - 'columns=' => null, - 'configuration=' => null, - 'coverage-clover=' => null, - 'coverage-crap4j=' => null, - 'coverage-html=' => null, - 'coverage-php=' => null, - 'coverage-text==' => null, - 'coverage-xml=' => null, - 'debug' => null, - 'disallow-test-output' => null, - 'disallow-resource-usage' => null, - 'disallow-todo-tests' => null, - 'default-time-limit=' => null, - 'enforce-time-limit' => null, - 'exclude-group=' => null, - 'filter=' => null, - 'generate-configuration' => null, - 'globals-backup' => null, - 'group=' => null, - 'help' => null, - 'resolve-dependencies' => null, - 'ignore-dependencies' => null, - 'include-path=' => null, - 'list-groups' => null, - 'list-suites' => null, - 'list-tests' => null, - 'list-tests-xml=' => null, - 'loader=' => null, - 'log-junit=' => null, - 'log-teamcity=' => null, - 'no-configuration' => null, - 'no-coverage' => null, - 'no-logging' => null, - 'no-interaction' => null, - 'no-extensions' => null, - 'order-by=' => null, - 'printer=' => null, - 'process-isolation' => null, - 'repeat=' => null, - 'dont-report-useless-tests' => null, - 'random-order' => null, - 'random-order-seed=' => null, - 'reverse-order' => null, - 'reverse-list' => null, - 'static-backup' => null, - 'stderr' => null, - 'stop-on-defect' => null, - 'stop-on-error' => null, - 'stop-on-failure' => null, - 'stop-on-warning' => null, - 'stop-on-incomplete' => null, - 'stop-on-risky' => null, - 'stop-on-skipped' => null, - 'fail-on-warning' => null, - 'fail-on-risky' => null, - 'strict-coverage' => null, - 'disable-coverage-ignore' => null, - 'strict-global-state' => null, - 'teamcity' => null, - 'testdox' => null, - 'testdox-group=' => null, - 'testdox-exclude-group=' => null, - 'testdox-html=' => null, - 'testdox-text=' => null, - 'testdox-xml=' => null, - 'test-suffix=' => null, - 'testsuite=' => null, - 'verbose' => null, - 'version' => null, - 'whitelist=' => null, - 'dump-xdebug-filter=' => null, - ]; - - /** - * @var @psalm-var list - */ - private $warnings = []; + protected $longOptions = []; /** * @var bool @@ -188,11 +83,24 @@ class Command private $versionStringPrinted = false; /** - * @throws \PHPUnit\Framework\Exception + * @psalm-var list + */ + private $warnings = []; + + /** + * @throws Exception */ public static function main(bool $exit = true): int { - return (new static)->run($_SERVER['argv'], $exit); + try { + return (new static)->run($_SERVER['argv'], $exit); + } catch (Throwable $t) { + throw new RuntimeException( + $t->getMessage(), + (int) $t->getCode(), + $t + ); + } } /** @@ -204,12 +112,11 @@ class Command $runner = $this->createRunner(); - if ($this->arguments['test'] instanceof Test) { + if ($this->arguments['test'] instanceof TestSuite) { $suite = $this->arguments['test']; } else { $suite = $runner->getTest( $this->arguments['test'], - $this->arguments['testFile'], $this->arguments['testSuffixes'] ); } @@ -233,9 +140,9 @@ class Command unset($this->arguments['test'], $this->arguments['testFile']); try { - $result = $runner->doRun($suite, $this->arguments, $this->warnings, $exit); - } catch (Exception $e) { - print $e->getMessage() . PHP_EOL; + $result = $runner->run($suite, $this->arguments, $this->warnings, $exit); + } catch (Throwable $t) { + print $t->getMessage() . PHP_EOL; } $return = TestRunner::FAILURE_EXIT; @@ -309,673 +216,199 @@ class Command protected function handleArguments(array $argv): void { try { - $this->options = Getopt::parse( - $argv, - 'd:c:hv', - array_keys($this->longOptions) - ); - } catch (Exception $t) { - $this->exitWithErrorMessage($t->getMessage()); + $arguments = (new Builder)->fromParameters($argv, array_keys($this->longOptions)); + } catch (ArgumentsException $e) { + $this->exitWithErrorMessage($e->getMessage()); } - foreach ($this->options[0] as $option) { - switch ($option[0]) { - case '--colors': - $this->arguments['colors'] = $option[1] ?: ResultPrinter::COLOR_AUTO; + assert(isset($arguments) && $arguments instanceof Configuration); - break; + if ($arguments->hasGenerateConfiguration() && $arguments->generateConfiguration()) { + $this->generateConfiguration(); + } - case '--bootstrap': - $this->arguments['bootstrap'] = $option[1]; + if ($arguments->hasAtLeastVersion()) { + if (version_compare(Version::id(), $arguments->atLeastVersion(), '>=')) { + exit(TestRunner::SUCCESS_EXIT); + } - break; + exit(TestRunner::FAILURE_EXIT); + } - case '--cache-result': - $this->arguments['cacheResult'] = true; + if ($arguments->hasVersion() && $arguments->version()) { + $this->printVersionString(); - break; + exit(TestRunner::SUCCESS_EXIT); + } - case '--do-not-cache-result': - $this->arguments['cacheResult'] = false; + if ($arguments->hasCheckVersion() && $arguments->checkVersion()) { + $this->handleVersionCheck(); + } - break; + if ($arguments->hasHelp()) { + $this->showHelp(); - case '--cache-result-file': - $this->arguments['cacheResultFile'] = $option[1]; + exit(TestRunner::SUCCESS_EXIT); + } - break; + if ($arguments->hasUnrecognizedOrderBy()) { + $this->exitWithErrorMessage( + sprintf( + 'unrecognized --order-by option: %s', + $arguments->unrecognizedOrderBy() + ) + ); + } - case '--columns': - if (is_numeric($option[1])) { - $this->arguments['columns'] = (int) $option[1]; - } elseif ($option[1] === 'max') { - $this->arguments['columns'] = 'max'; - } - - break; - - case 'c': - case '--configuration': - $this->arguments['configuration'] = $option[1]; - - break; - - case '--coverage-clover': - $this->arguments['coverageClover'] = $option[1]; - - break; - - case '--coverage-crap4j': - $this->arguments['coverageCrap4J'] = $option[1]; - - break; - - case '--coverage-html': - $this->arguments['coverageHtml'] = $option[1]; - - break; - - case '--coverage-php': - $this->arguments['coveragePHP'] = $option[1]; - - break; - - case '--coverage-text': - if ($option[1] === null) { - $option[1] = 'php://stdout'; - } - - $this->arguments['coverageText'] = $option[1]; - $this->arguments['coverageTextShowUncoveredFiles'] = false; - $this->arguments['coverageTextShowOnlySummary'] = false; - - break; - - case '--coverage-xml': - $this->arguments['coverageXml'] = $option[1]; - - break; - - case 'd': - $ini = explode('=', $option[1]); - - if (isset($ini[0])) { - if (isset($ini[1])) { - ini_set($ini[0], $ini[1]); - } else { - ini_set($ini[0], '1'); - } - } - - break; - - case '--debug': - $this->arguments['debug'] = true; - - break; - - case 'h': - case '--help': - $this->showHelp(); - - exit(TestRunner::SUCCESS_EXIT); - - break; - - case '--filter': - $this->arguments['filter'] = $option[1]; - - break; - - case '--testsuite': - $this->arguments['testsuite'] = $option[1]; - - break; - - case '--generate-configuration': - $this->printVersionString(); - - print 'Generating phpunit.xml in ' . getcwd() . PHP_EOL . PHP_EOL; - - print 'Bootstrap script (relative to path shown above; default: vendor/autoload.php): '; - $bootstrapScript = trim(fgets(STDIN)); - - print 'Tests directory (relative to path shown above; default: tests): '; - $testsDirectory = trim(fgets(STDIN)); - - print 'Source directory (relative to path shown above; default: src): '; - $src = trim(fgets(STDIN)); - - if ($bootstrapScript === '') { - $bootstrapScript = 'vendor/autoload.php'; - } - - if ($testsDirectory === '') { - $testsDirectory = 'tests'; - } - - if ($src === '') { - $src = 'src'; - } - - $generator = new ConfigurationGenerator; - - file_put_contents( - 'phpunit.xml', - $generator->generateDefaultConfiguration( - Version::series(), - $bootstrapScript, - $testsDirectory, - $src - ) - ); - - print PHP_EOL . 'Generated phpunit.xml in ' . getcwd() . PHP_EOL; - - exit(TestRunner::SUCCESS_EXIT); - - break; - - case '--group': - $this->arguments['groups'] = explode(',', $option[1]); - - break; - - case '--exclude-group': - $this->arguments['excludeGroups'] = explode( - ',', - $option[1] - ); - - break; - - case '--test-suffix': - $this->arguments['testSuffixes'] = explode( - ',', - $option[1] - ); - - break; - - case '--include-path': - $includePath = $option[1]; - - break; - - case '--list-groups': - $this->arguments['listGroups'] = true; - - break; - - case '--list-suites': - $this->arguments['listSuites'] = true; - - break; - - case '--list-tests': - $this->arguments['listTests'] = true; - - break; - - case '--list-tests-xml': - $this->arguments['listTestsXml'] = $option[1]; - - break; - - case '--printer': - $this->arguments['printer'] = $option[1]; - - break; - - case '--loader': - $this->arguments['loader'] = $option[1]; - - break; - - case '--log-junit': - $this->arguments['junitLogfile'] = $option[1]; - - break; - - case '--log-teamcity': - $this->arguments['teamcityLogfile'] = $option[1]; - - break; - - case '--order-by': - $this->handleOrderByOption($option[1]); - - break; - - case '--process-isolation': - $this->arguments['processIsolation'] = true; - - break; - - case '--repeat': - $this->arguments['repeat'] = (int) $option[1]; - - break; - - case '--stderr': - $this->arguments['stderr'] = true; - - break; - - case '--stop-on-defect': - $this->arguments['stopOnDefect'] = true; - - break; - - case '--stop-on-error': - $this->arguments['stopOnError'] = true; - - break; - - case '--stop-on-failure': - $this->arguments['stopOnFailure'] = true; - - break; - - case '--stop-on-warning': - $this->arguments['stopOnWarning'] = true; - - break; - - case '--stop-on-incomplete': - $this->arguments['stopOnIncomplete'] = true; - - break; - - case '--stop-on-risky': - $this->arguments['stopOnRisky'] = true; - - break; - - case '--stop-on-skipped': - $this->arguments['stopOnSkipped'] = true; - - break; - - case '--fail-on-warning': - $this->arguments['failOnWarning'] = true; - - break; - - case '--fail-on-risky': - $this->arguments['failOnRisky'] = true; - - break; - - case '--teamcity': - $this->arguments['printer'] = TeamCity::class; - - break; - - case '--testdox': - $this->arguments['printer'] = CliTestDoxPrinter::class; - - break; - - case '--testdox-group': - $this->arguments['testdoxGroups'] = explode( - ',', - $option[1] - ); - - break; - - case '--testdox-exclude-group': - $this->arguments['testdoxExcludeGroups'] = explode( - ',', - $option[1] - ); - - break; - - case '--testdox-html': - $this->arguments['testdoxHTMLFile'] = $option[1]; - - break; - - case '--testdox-text': - $this->arguments['testdoxTextFile'] = $option[1]; - - break; - - case '--testdox-xml': - $this->arguments['testdoxXMLFile'] = $option[1]; - - break; - - case '--no-configuration': - $this->arguments['useDefaultConfiguration'] = false; - - break; - - case '--no-extensions': - $this->arguments['noExtensions'] = true; - - break; - - case '--no-coverage': - $this->arguments['noCoverage'] = true; - - break; - - case '--no-logging': - $this->arguments['noLogging'] = true; - - break; - - case '--no-interaction': - $this->arguments['noInteraction'] = true; - - break; - - case '--globals-backup': - $this->arguments['backupGlobals'] = true; - - break; - - case '--static-backup': - $this->arguments['backupStaticAttributes'] = true; - - break; - - case 'v': - case '--verbose': - $this->arguments['verbose'] = true; - - break; - - case '--atleast-version': - if (version_compare(Version::id(), $option[1], '>=')) { - exit(TestRunner::SUCCESS_EXIT); - } - - exit(TestRunner::FAILURE_EXIT); - - break; - - case '--version': - $this->printVersionString(); - - exit(TestRunner::SUCCESS_EXIT); - - break; - - case '--dont-report-useless-tests': - $this->arguments['reportUselessTests'] = false; - - break; - - case '--strict-coverage': - $this->arguments['strictCoverage'] = true; - - break; - - case '--disable-coverage-ignore': - $this->arguments['disableCodeCoverageIgnore'] = true; - - break; - - case '--strict-global-state': - $this->arguments['beStrictAboutChangesToGlobalState'] = true; - - break; - - case '--disallow-test-output': - $this->arguments['disallowTestOutput'] = true; - - break; - - case '--disallow-resource-usage': - $this->arguments['beStrictAboutResourceUsageDuringSmallTests'] = true; - - break; - - case '--default-time-limit': - $this->arguments['defaultTimeLimit'] = (int) $option[1]; - - break; - - case '--enforce-time-limit': - $this->arguments['enforceTimeLimit'] = true; - - break; - - case '--disallow-todo-tests': - $this->arguments['disallowTodoAnnotatedTests'] = true; - - break; - - case '--reverse-list': - $this->arguments['reverseList'] = true; - - break; - - case '--check-version': - $this->handleVersionCheck(); - - break; - - case '--whitelist': - $this->arguments['whitelist'] = $option[1]; - - break; - - case '--random-order': - $this->handleOrderByOption('random'); - - break; - - case '--random-order-seed': - $this->arguments['randomOrderSeed'] = (int) $option[1]; - - break; - - case '--resolve-dependencies': - $this->handleOrderByOption('depends'); - - break; - - case '--ignore-dependencies': - $this->handleOrderByOption('no-depends'); - - break; - - case '--reverse-order': - $this->handleOrderByOption('reverse'); - - break; - - case '--dump-xdebug-filter': - $this->arguments['xdebugFilterFile'] = $option[1]; - - break; - - default: - $optionName = str_replace('--', '', $option[0]); - - $handler = null; - - if (isset($this->longOptions[$optionName])) { - $handler = $this->longOptions[$optionName]; - } elseif (isset($this->longOptions[$optionName . '='])) { - $handler = $this->longOptions[$optionName . '=']; - } - - if (isset($handler) && is_callable([$this, $handler])) { - $this->{$handler}($option[1]); - } + if ($arguments->hasIniSettings()) { + foreach ($arguments->iniSettings() as $name => $value) { + ini_set($name, $value); } } + if ($arguments->hasIncludePath()) { + ini_set( + 'include_path', + $arguments->includePath() . PATH_SEPARATOR . ini_get('include_path') + ); + } + + $this->arguments = (new Mapper)->mapToLegacyArray($arguments); + + $this->handleCustomOptions($arguments->unrecognizedOptions()); $this->handleCustomTestSuite(); if (!isset($this->arguments['testSuffixes'])) { $this->arguments['testSuffixes'] = ['Test.php', '.phpt']; } - if (isset($this->options[1][0]) && - substr($this->options[1][0], -5, 5) !== '.phpt' && - substr($this->options[1][0], -4, 4) !== '.php' && - substr($this->options[1][0], -1, 1) !== '/' && - !is_dir($this->options[1][0])) { - $this->warnings[] = 'Invocation with class name is deprecated'; - } + if (!isset($this->arguments['test']) && $arguments->hasArgument()) { + $this->arguments['test'] = realpath($arguments->argument()); - if (!isset($this->arguments['test'])) { - if (isset($this->options[1][0])) { - $this->arguments['test'] = $this->options[1][0]; + if ($this->arguments['test'] === false) { + $this->exitWithErrorMessage( + sprintf( + 'Cannot open file "%s".', + $arguments->argument() + ) + ); } - - if (isset($this->options[1][1])) { - $testFile = realpath($this->options[1][1]); - - if ($testFile === false) { - $this->exitWithErrorMessage( - sprintf( - 'Cannot open file "%s".', - $this->options[1][1] - ) - ); - } - $this->arguments['testFile'] = $testFile; - } else { - $this->arguments['testFile'] = ''; - } - - if (isset($this->arguments['test']) && - is_file($this->arguments['test']) && - strrpos($this->arguments['test'], '.') !== false && - substr($this->arguments['test'], -5, 5) !== '.phpt') { - $this->arguments['testFile'] = realpath($this->arguments['test']); - $this->arguments['test'] = substr($this->arguments['test'], 0, strrpos($this->arguments['test'], '.')); - } - - if (isset($this->arguments['test']) && - is_string($this->arguments['test']) && - substr($this->arguments['test'], -5, 5) === '.phpt') { - $suite = new TestSuite; - $suite->addTestFile($this->arguments['test']); - $this->arguments['test'] = $suite; - } - } - - if (isset($includePath)) { - ini_set( - 'include_path', - $includePath . PATH_SEPARATOR . ini_get('include_path') - ); } if ($this->arguments['loader'] !== null) { $this->arguments['loader'] = $this->handleLoader($this->arguments['loader']); } - if (isset($this->arguments['configuration']) && - is_dir($this->arguments['configuration'])) { - $configurationFile = $this->arguments['configuration'] . '/phpunit.xml'; + if (isset($this->arguments['configuration'])) { + if (is_dir($this->arguments['configuration'])) { + $candidate = $this->configurationFileInDirectory($this->arguments['configuration']); - if (file_exists($configurationFile)) { - $this->arguments['configuration'] = realpath( - $configurationFile - ); - } elseif (file_exists($configurationFile . '.dist')) { - $this->arguments['configuration'] = realpath( - $configurationFile . '.dist' - ); + if ($candidate !== null) { + $this->arguments['configuration'] = $candidate; + } } - } elseif (!isset($this->arguments['configuration']) && - $this->arguments['useDefaultConfiguration']) { - if (file_exists('phpunit.xml')) { - $this->arguments['configuration'] = realpath('phpunit.xml'); - } elseif (file_exists('phpunit.xml.dist')) { - $this->arguments['configuration'] = realpath( - 'phpunit.xml.dist' - ); + } elseif ($this->arguments['useDefaultConfiguration']) { + $candidate = $this->configurationFileInDirectory(getcwd()); + + if ($candidate !== null) { + $this->arguments['configuration'] = $candidate; } } + if ($arguments->hasMigrateConfiguration() && $arguments->migrateConfiguration()) { + if (!isset($this->arguments['configuration'])) { + print 'No configuration file found to migrate.' . PHP_EOL; + + exit(TestRunner::EXCEPTION_EXIT); + } + + $this->migrateConfiguration(realpath($this->arguments['configuration'])); + } + if (isset($this->arguments['configuration'])) { try { - $configuration = Configuration::getInstance( - $this->arguments['configuration'] - ); - } catch (Throwable $t) { - print $t->getMessage() . PHP_EOL; + $this->arguments['configurationObject'] = (new Loader)->load($this->arguments['configuration']); + } catch (Throwable $e) { + print $e->getMessage() . PHP_EOL; exit(TestRunner::FAILURE_EXIT); } - $phpunitConfiguration = $configuration->getPHPUnitConfiguration(); + $phpunitConfiguration = $this->arguments['configurationObject']->phpunit(); - $configuration->handlePHPConfiguration(); + (new PhpHandler)->handle($this->arguments['configurationObject']->php()); - /* - * Issue #1216 - */ if (isset($this->arguments['bootstrap'])) { $this->handleBootstrap($this->arguments['bootstrap']); - } elseif (isset($phpunitConfiguration['bootstrap'])) { - $this->handleBootstrap($phpunitConfiguration['bootstrap']); + } elseif ($phpunitConfiguration->hasBootstrap()) { + $this->handleBootstrap($phpunitConfiguration->bootstrap()); } - /* - * Issue #657 - */ - if (isset($phpunitConfiguration['stderr']) && !isset($this->arguments['stderr'])) { - $this->arguments['stderr'] = $phpunitConfiguration['stderr']; + if (!isset($this->arguments['stderr'])) { + $this->arguments['stderr'] = $phpunitConfiguration->stderr(); } - if (isset($phpunitConfiguration['extensionsDirectory']) && !isset($this->arguments['noExtensions']) && extension_loaded('phar')) { - $this->handleExtensions($phpunitConfiguration['extensionsDirectory']); + if (!isset($this->arguments['noExtensions']) && $phpunitConfiguration->hasExtensionsDirectory() && extension_loaded('phar')) { + $result = (new PharLoader)->loadPharExtensionsInDirectory($phpunitConfiguration->extensionsDirectory()); + + $this->arguments['loadedExtensions'] = $result['loadedExtensions']; + $this->arguments['notLoadedExtensions'] = $result['notLoadedExtensions']; + + unset($result); } - if (isset($phpunitConfiguration['columns']) && !isset($this->arguments['columns'])) { - $this->arguments['columns'] = $phpunitConfiguration['columns']; + if (!isset($this->arguments['columns'])) { + $this->arguments['columns'] = $phpunitConfiguration->columns(); } - if (!isset($this->arguments['printer']) && isset($phpunitConfiguration['printerClass'])) { - $file = $phpunitConfiguration['printerFile'] ?? ''; + if (!isset($this->arguments['printer']) && $phpunitConfiguration->hasPrinterClass()) { + $file = $phpunitConfiguration->hasPrinterFile() ? $phpunitConfiguration->printerFile() : ''; $this->arguments['printer'] = $this->handlePrinter( - $phpunitConfiguration['printerClass'], + $phpunitConfiguration->printerClass(), $file ); } - if (isset($phpunitConfiguration['testSuiteLoaderClass'])) { - $file = $phpunitConfiguration['testSuiteLoaderFile'] ?? ''; + if ($phpunitConfiguration->hasTestSuiteLoaderClass()) { + $file = $phpunitConfiguration->hasTestSuiteLoaderFile() ? $phpunitConfiguration->testSuiteLoaderFile() : ''; $this->arguments['loader'] = $this->handleLoader( - $phpunitConfiguration['testSuiteLoaderClass'], + $phpunitConfiguration->testSuiteLoaderClass(), $file ); } - if (!isset($this->arguments['testsuite']) && isset($phpunitConfiguration['defaultTestSuite'])) { - $this->arguments['testsuite'] = $phpunitConfiguration['defaultTestSuite']; + if (!isset($this->arguments['testsuite']) && $phpunitConfiguration->hasDefaultTestSuite()) { + $this->arguments['testsuite'] = $phpunitConfiguration->defaultTestSuite(); } if (!isset($this->arguments['test'])) { - $testSuite = $configuration->getTestSuiteConfiguration($this->arguments['testsuite'] ?? ''); + try { + $this->arguments['test'] = (new TestSuiteMapper)->map( + $this->arguments['configurationObject']->testSuite(), + $this->arguments['testsuite'] ?? '' + ); + } catch (Exception $e) { + $this->printVersionString(); - if ($testSuite !== null) { - $this->arguments['test'] = $testSuite; + print $e->getMessage() . PHP_EOL; + + exit(TestRunner::EXCEPTION_EXIT); } } } elseif (isset($this->arguments['bootstrap'])) { $this->handleBootstrap($this->arguments['bootstrap']); } - if (isset($this->arguments['printer']) && - is_string($this->arguments['printer'])) { + if (isset($this->arguments['printer']) && is_string($this->arguments['printer'])) { $this->arguments['printer'] = $this->handlePrinter($this->arguments['printer']); } + if (isset($this->arguments['configurationObject'], $this->arguments['warmCoverageCache'])) { + $this->handleWarmCoverageCache($this->arguments['configurationObject']); + } + if (!isset($this->arguments['test'])) { $this->showHelp(); @@ -985,9 +418,13 @@ class Command /** * Handles the loading of the PHPUnit\Runner\TestSuiteLoader implementation. + * + * @deprecated see https://github.com/sebastianbergmann/phpunit/issues/4039 */ protected function handleLoader(string $loaderClass, string $loaderFile = ''): ?TestSuiteLoader { + $this->warnings[] = 'Using a custom test suite loader is deprecated'; + if (!class_exists($loaderClass, false)) { if ($loaderFile == '') { $loaderFile = Filesystem::classNameToFilename( @@ -998,6 +435,10 @@ class Command $loaderFile = stream_resolve_include_path($loaderFile); if ($loaderFile) { + /** + * @noinspection PhpIncludeInspection + * @psalm-suppress UnresolvableInclude + */ require $loaderFile; } } @@ -1006,8 +447,8 @@ class Command try { $class = new ReflectionClass($loaderClass); // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new Exception( + } catch (\ReflectionException $e) { + throw new ReflectionException( $e->getMessage(), (int) $e->getCode(), $e @@ -1046,7 +487,7 @@ class Command protected function handlePrinter(string $printerClass, string $printerFile = '') { if (!class_exists($printerClass, false)) { - if ($printerFile == '') { + if ($printerFile === '') { $printerFile = Filesystem::classNameToFilename( $printerClass ); @@ -1055,6 +496,10 @@ class Command $printerFile = stream_resolve_include_path($printerFile); if ($printerFile) { + /** + * @noinspection PhpIncludeInspection + * @psalm-suppress UnresolvableInclude + */ require $printerFile; } } @@ -1071,8 +516,8 @@ class Command try { $class = new ReflectionClass($printerClass); // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new Exception( + } catch (\ReflectionException $e) { + throw new ReflectionException( $e->getMessage(), (int) $e->getCode(), $e @@ -1080,22 +525,12 @@ class Command // @codeCoverageIgnoreEnd } - if (!$class->implementsInterface(TestListener::class)) { + if (!$class->implementsInterface(ResultPrinter::class)) { $this->exitWithErrorMessage( sprintf( 'Could not use "%s" as printer: class does not implement %s', $printerClass, - TestListener::class - ) - ); - } - - if (!$class->isSubclassOf(Printer::class)) { - $this->exitWithErrorMessage( - sprintf( - 'Could not use "%s" as printer: class does not extend %s', - $printerClass, - Printer::class + ResultPrinter::class ) ); } @@ -1125,8 +560,19 @@ class Command { try { FileLoader::checkAndLoad($filename); - } catch (Exception $e) { - $this->exitWithErrorMessage($e->getMessage()); + } catch (Throwable $t) { + if ($t instanceof \PHPUnit\Exception) { + $this->exitWithErrorMessage($t->getMessage()); + } + + $this->exitWithErrorMessage( + sprintf( + 'Error in bootstrap script: %s:%s%s', + get_class($t), + PHP_EOL, + $t->getMessage() + ) + ); } } @@ -1186,43 +632,6 @@ class Command exit(TestRunner::FAILURE_EXIT); } - private function handleExtensions(string $directory): void - { - foreach ((new FileIteratorFacade)->getFilesAsArray($directory, '.phar') as $file) { - if (!file_exists('phar://' . $file . '/manifest.xml')) { - $this->arguments['notLoadedExtensions'][] = $file . ' is not an extension for PHPUnit'; - - continue; - } - - try { - $applicationName = new ApplicationName('phpunit/phpunit'); - $version = new PharIoVersion(Version::series()); - $manifest = ManifestLoader::fromFile('phar://' . $file . '/manifest.xml'); - - if (!$manifest->isExtensionFor($applicationName)) { - $this->arguments['notLoadedExtensions'][] = $file . ' is not an extension for PHPUnit'; - - continue; - } - - if (!$manifest->isExtensionFor($applicationName, $version)) { - $this->arguments['notLoadedExtensions'][] = $file . ' is not compatible with this version of PHPUnit'; - - continue; - } - } catch (ManifestException $e) { - $this->arguments['notLoadedExtensions'][] = $file . ': ' . $e->getMessage(); - - continue; - } - - require $file; - - $this->arguments['loadedExtensions'][] = $manifest->getName()->asString() . ' ' . $manifest->getVersion()->getVersionString(); - } - } - private function handleListGroups(TestSuite $suite, bool $exit): int { $this->printVersionString(); @@ -1233,6 +642,10 @@ class Command sort($groups); foreach ($groups as $group) { + if (strpos($group, '__phpunit_') === 0) { + continue; + } + printf( ' - %s' . PHP_EOL, $group @@ -1248,6 +661,7 @@ class Command /** * @throws \PHPUnit\Framework\Exception + * @throws \PHPUnit\TextUI\XmlConfiguration\Exception */ private function handleListSuites(bool $exit): int { @@ -1255,14 +669,10 @@ class Command print 'Available test suite(s):' . PHP_EOL; - $configuration = Configuration::getInstance( - $this->arguments['configuration'] - ); - - foreach ($configuration->getTestSuiteNames() as $suiteName) { + foreach ($this->arguments['configurationObject']->testSuite() as $testSuite) { printf( ' - %s' . PHP_EOL, - $suiteName + $testSuite->name() ); } @@ -1314,55 +724,180 @@ class Command return TestRunner::SUCCESS_EXIT; } - private function handleOrderByOption(string $value): void + private function generateConfiguration(): void { - foreach (explode(',', $value) as $order) { - switch ($order) { - case 'default': - $this->arguments['executionOrder'] = TestSuiteSorter::ORDER_DEFAULT; - $this->arguments['executionOrderDefects'] = TestSuiteSorter::ORDER_DEFAULT; - $this->arguments['resolveDependencies'] = true; + $this->printVersionString(); - break; + print 'Generating phpunit.xml in ' . getcwd() . PHP_EOL . PHP_EOL; + print 'Bootstrap script (relative to path shown above; default: vendor/autoload.php): '; - case 'defects': - $this->arguments['executionOrderDefects'] = TestSuiteSorter::ORDER_DEFECTS_FIRST; + $bootstrapScript = trim(fgets(STDIN)); - break; + print 'Tests directory (relative to path shown above; default: tests): '; - case 'depends': - $this->arguments['resolveDependencies'] = true; + $testsDirectory = trim(fgets(STDIN)); - break; + print 'Source directory (relative to path shown above; default: src): '; - case 'duration': - $this->arguments['executionOrder'] = TestSuiteSorter::ORDER_DURATION; + $src = trim(fgets(STDIN)); - break; + print 'Cache directory (relative to path shown above; default: .phpunit.cache): '; - case 'no-depends': - $this->arguments['resolveDependencies'] = false; + $cacheDirectory = trim(fgets(STDIN)); - break; + if ($bootstrapScript === '') { + $bootstrapScript = 'vendor/autoload.php'; + } - case 'random': - $this->arguments['executionOrder'] = TestSuiteSorter::ORDER_RANDOMIZED; + if ($testsDirectory === '') { + $testsDirectory = 'tests'; + } - break; + if ($src === '') { + $src = 'src'; + } - case 'reverse': - $this->arguments['executionOrder'] = TestSuiteSorter::ORDER_REVERSED; + if ($cacheDirectory === '') { + $cacheDirectory = '.phpunit.cache'; + } - break; + $generator = new Generator; - case 'size': - $this->arguments['executionOrder'] = TestSuiteSorter::ORDER_SIZE; + file_put_contents( + 'phpunit.xml', + $generator->generateDefaultConfiguration( + Version::series(), + $bootstrapScript, + $testsDirectory, + $src, + $cacheDirectory + ) + ); - break; + print PHP_EOL . 'Generated phpunit.xml in ' . getcwd() . '.' . PHP_EOL; + print 'Make sure to exclude the ' . $cacheDirectory . ' directory from version control.' . PHP_EOL; - default: - $this->exitWithErrorMessage("unrecognized --order-by option: {$order}"); + exit(TestRunner::SUCCESS_EXIT); + } + + private function migrateConfiguration(string $filename): void + { + $this->printVersionString(); + + if (!(new SchemaDetector)->detect($filename)->detected()) { + print $filename . ' does not need to be migrated.' . PHP_EOL; + + exit(TestRunner::EXCEPTION_EXIT); + } + + copy($filename, $filename . '.bak'); + + print 'Created backup: ' . $filename . '.bak' . PHP_EOL; + + try { + file_put_contents( + $filename, + (new Migrator)->migrate($filename) + ); + + print 'Migrated configuration: ' . $filename . PHP_EOL; + } catch (Throwable $t) { + print 'Migration failed: ' . $t->getMessage() . PHP_EOL; + + exit(TestRunner::EXCEPTION_EXIT); + } + + exit(TestRunner::SUCCESS_EXIT); + } + + private function handleCustomOptions(array $unrecognizedOptions): void + { + foreach ($unrecognizedOptions as $name => $value) { + if (isset($this->longOptions[$name])) { + $handler = $this->longOptions[$name]; + } + + $name .= '='; + + if (isset($this->longOptions[$name])) { + $handler = $this->longOptions[$name]; + } + + if (isset($handler) && is_callable([$this, $handler])) { + $this->{$handler}($value); + + unset($handler); } } } + + private function handleWarmCoverageCache(XmlConfiguration\Configuration $configuration): void + { + $this->printVersionString(); + + if (isset($this->arguments['coverageCacheDirectory'])) { + $cacheDirectory = $this->arguments['coverageCacheDirectory']; + } elseif ($configuration->codeCoverage()->hasCacheDirectory()) { + $cacheDirectory = $configuration->codeCoverage()->cacheDirectory()->path(); + } else { + print 'Cache for static analysis has not been configured' . PHP_EOL; + + exit(TestRunner::EXCEPTION_EXIT); + } + + $filter = new Filter; + + if ($configuration->codeCoverage()->hasNonEmptyListOfFilesToBeIncludedInCodeCoverageReport()) { + (new FilterMapper)->map( + $filter, + $configuration->codeCoverage() + ); + } elseif (isset($this->arguments['coverageFilter'])) { + if (!is_array($this->arguments['coverageFilter'])) { + $coverageFilterDirectories = [$this->arguments['coverageFilter']]; + } else { + $coverageFilterDirectories = $this->arguments['coverageFilter']; + } + + foreach ($coverageFilterDirectories as $coverageFilterDirectory) { + $filter->includeDirectory($coverageFilterDirectory); + } + } else { + print 'Filter for code coverage has not been configured' . PHP_EOL; + + exit(TestRunner::EXCEPTION_EXIT); + } + + $timer = new Timer; + $timer->start(); + + print 'Warming cache for static analysis ... '; + + (new CacheWarmer)->warmCache( + $cacheDirectory, + !$configuration->codeCoverage()->disableCodeCoverageIgnore(), + $configuration->codeCoverage()->ignoreDeprecatedCodeUnits(), + $filter + ); + + print 'done [' . $timer->stop()->asString() . ']' . PHP_EOL; + + exit(TestRunner::SUCCESS_EXIT); + } + + private function configurationFileInDirectory(string $directory): ?string + { + $candidates = [ + $directory . '/phpunit.xml', + $directory . '/phpunit.xml.dist', + ]; + + foreach ($candidates as $candidate) { + if (is_file($candidate)) { + return realpath($candidate); + } + } + + return null; + } } diff --git a/vendor/phpunit/phpunit/src/TextUI/DefaultResultPrinter.php b/vendor/phpunit/phpunit/src/TextUI/DefaultResultPrinter.php new file mode 100644 index 000000000..6a0ad2c79 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/DefaultResultPrinter.php @@ -0,0 +1,592 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI; + +use const PHP_EOL; +use function array_map; +use function array_reverse; +use function count; +use function floor; +use function implode; +use function in_array; +use function is_int; +use function max; +use function preg_split; +use function sprintf; +use function str_pad; +use function str_repeat; +use function strlen; +use function vsprintf; +use PHPUnit\Framework\AssertionFailedError; +use PHPUnit\Framework\Exception; +use PHPUnit\Framework\InvalidArgumentException; +use PHPUnit\Framework\Test; +use PHPUnit\Framework\TestCase; +use PHPUnit\Framework\TestFailure; +use PHPUnit\Framework\TestResult; +use PHPUnit\Framework\TestSuite; +use PHPUnit\Framework\Warning; +use PHPUnit\Runner\PhptTestCase; +use PHPUnit\Util\Color; +use PHPUnit\Util\Printer; +use SebastianBergmann\Environment\Console; +use SebastianBergmann\Timer\ResourceUsageFormatter; +use SebastianBergmann\Timer\Timer; +use Throwable; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +class DefaultResultPrinter extends Printer implements ResultPrinter +{ + public const EVENT_TEST_START = 0; + + public const EVENT_TEST_END = 1; + + public const EVENT_TESTSUITE_START = 2; + + public const EVENT_TESTSUITE_END = 3; + + public const COLOR_NEVER = 'never'; + + public const COLOR_AUTO = 'auto'; + + public const COLOR_ALWAYS = 'always'; + + public const COLOR_DEFAULT = self::COLOR_NEVER; + + private const AVAILABLE_COLORS = [self::COLOR_NEVER, self::COLOR_AUTO, self::COLOR_ALWAYS]; + + /** + * @var int + */ + protected $column = 0; + + /** + * @var int + */ + protected $maxColumn; + + /** + * @var bool + */ + protected $lastTestFailed = false; + + /** + * @var int + */ + protected $numAssertions = 0; + + /** + * @var int + */ + protected $numTests = -1; + + /** + * @var int + */ + protected $numTestsRun = 0; + + /** + * @var int + */ + protected $numTestsWidth; + + /** + * @var bool + */ + protected $colors = false; + + /** + * @var bool + */ + protected $debug = false; + + /** + * @var bool + */ + protected $verbose = false; + + /** + * @var int + */ + private $numberOfColumns; + + /** + * @var bool + */ + private $reverse; + + /** + * @var bool + */ + private $defectListPrinted = false; + + /** + * @var Timer + */ + private $timer; + + /** + * Constructor. + * + * @param null|resource|string $out + * @param int|string $numberOfColumns + * + * @throws Exception + */ + public function __construct($out = null, bool $verbose = false, string $colors = self::COLOR_DEFAULT, bool $debug = false, $numberOfColumns = 80, bool $reverse = false) + { + parent::__construct($out); + + if (!in_array($colors, self::AVAILABLE_COLORS, true)) { + throw InvalidArgumentException::create( + 3, + vsprintf('value from "%s", "%s" or "%s"', self::AVAILABLE_COLORS) + ); + } + + if (!is_int($numberOfColumns) && $numberOfColumns !== 'max') { + throw InvalidArgumentException::create(5, 'integer or "max"'); + } + + $console = new Console; + $maxNumberOfColumns = $console->getNumberOfColumns(); + + if ($numberOfColumns === 'max' || ($numberOfColumns !== 80 && $numberOfColumns > $maxNumberOfColumns)) { + $numberOfColumns = $maxNumberOfColumns; + } + + $this->numberOfColumns = $numberOfColumns; + $this->verbose = $verbose; + $this->debug = $debug; + $this->reverse = $reverse; + + if ($colors === self::COLOR_AUTO && $console->hasColorSupport()) { + $this->colors = true; + } else { + $this->colors = (self::COLOR_ALWAYS === $colors); + } + + $this->timer = new Timer; + + $this->timer->start(); + } + + public function printResult(TestResult $result): void + { + $this->printHeader($result); + $this->printErrors($result); + $this->printWarnings($result); + $this->printFailures($result); + $this->printRisky($result); + + if ($this->verbose) { + $this->printIncompletes($result); + $this->printSkipped($result); + } + + $this->printFooter($result); + } + + /** + * An error occurred. + */ + public function addError(Test $test, Throwable $t, float $time): void + { + $this->writeProgressWithColor('fg-red, bold', 'E'); + $this->lastTestFailed = true; + } + + /** + * A failure occurred. + */ + public function addFailure(Test $test, AssertionFailedError $e, float $time): void + { + $this->writeProgressWithColor('bg-red, fg-white', 'F'); + $this->lastTestFailed = true; + } + + /** + * A warning occurred. + */ + public function addWarning(Test $test, Warning $e, float $time): void + { + $this->writeProgressWithColor('fg-yellow, bold', 'W'); + $this->lastTestFailed = true; + } + + /** + * Incomplete test. + */ + public function addIncompleteTest(Test $test, Throwable $t, float $time): void + { + $this->writeProgressWithColor('fg-yellow, bold', 'I'); + $this->lastTestFailed = true; + } + + /** + * Risky test. + */ + public function addRiskyTest(Test $test, Throwable $t, float $time): void + { + $this->writeProgressWithColor('fg-yellow, bold', 'R'); + $this->lastTestFailed = true; + } + + /** + * Skipped test. + */ + public function addSkippedTest(Test $test, Throwable $t, float $time): void + { + $this->writeProgressWithColor('fg-cyan, bold', 'S'); + $this->lastTestFailed = true; + } + + /** + * A testsuite started. + */ + public function startTestSuite(TestSuite $suite): void + { + if ($this->numTests == -1) { + $this->numTests = count($suite); + $this->numTestsWidth = strlen((string) $this->numTests); + $this->maxColumn = $this->numberOfColumns - strlen(' / (XXX%)') - (2 * $this->numTestsWidth); + } + } + + /** + * A testsuite ended. + */ + public function endTestSuite(TestSuite $suite): void + { + } + + /** + * A test started. + */ + public function startTest(Test $test): void + { + if ($this->debug) { + $this->write( + sprintf( + "Test '%s' started\n", + \PHPUnit\Util\Test::describeAsString($test) + ) + ); + } + } + + /** + * A test ended. + */ + public function endTest(Test $test, float $time): void + { + if ($this->debug) { + $this->write( + sprintf( + "Test '%s' ended\n", + \PHPUnit\Util\Test::describeAsString($test) + ) + ); + } + + if (!$this->lastTestFailed) { + $this->writeProgress('.'); + } + + if ($test instanceof TestCase) { + $this->numAssertions += $test->getNumAssertions(); + } elseif ($test instanceof PhptTestCase) { + $this->numAssertions++; + } + + $this->lastTestFailed = false; + + if ($test instanceof TestCase && !$test->hasExpectationOnOutput()) { + $this->write($test->getActualOutput()); + } + } + + protected function printDefects(array $defects, string $type): void + { + $count = count($defects); + + if ($count == 0) { + return; + } + + if ($this->defectListPrinted) { + $this->write("\n--\n\n"); + } + + $this->write( + sprintf( + "There %s %d %s%s:\n", + ($count == 1) ? 'was' : 'were', + $count, + $type, + ($count == 1) ? '' : 's' + ) + ); + + $i = 1; + + if ($this->reverse) { + $defects = array_reverse($defects); + } + + foreach ($defects as $defect) { + $this->printDefect($defect, $i++); + } + + $this->defectListPrinted = true; + } + + protected function printDefect(TestFailure $defect, int $count): void + { + $this->printDefectHeader($defect, $count); + $this->printDefectTrace($defect); + } + + protected function printDefectHeader(TestFailure $defect, int $count): void + { + $this->write( + sprintf( + "\n%d) %s\n", + $count, + $defect->getTestName() + ) + ); + } + + protected function printDefectTrace(TestFailure $defect): void + { + $e = $defect->thrownException(); + + $this->write((string) $e); + + while ($e = $e->getPrevious()) { + $this->write("\nCaused by\n" . $e); + } + } + + protected function printErrors(TestResult $result): void + { + $this->printDefects($result->errors(), 'error'); + } + + protected function printFailures(TestResult $result): void + { + $this->printDefects($result->failures(), 'failure'); + } + + protected function printWarnings(TestResult $result): void + { + $this->printDefects($result->warnings(), 'warning'); + } + + protected function printIncompletes(TestResult $result): void + { + $this->printDefects($result->notImplemented(), 'incomplete test'); + } + + protected function printRisky(TestResult $result): void + { + $this->printDefects($result->risky(), 'risky test'); + } + + protected function printSkipped(TestResult $result): void + { + $this->printDefects($result->skipped(), 'skipped test'); + } + + protected function printHeader(TestResult $result): void + { + if (count($result) > 0) { + $this->write(PHP_EOL . PHP_EOL . (new ResourceUsageFormatter)->resourceUsage($this->timer->stop()) . PHP_EOL . PHP_EOL); + } + } + + protected function printFooter(TestResult $result): void + { + if (count($result) === 0) { + $this->writeWithColor( + 'fg-black, bg-yellow', + 'No tests executed!' + ); + + return; + } + + if ($result->wasSuccessfulAndNoTestIsRiskyOrSkippedOrIncomplete()) { + $this->writeWithColor( + 'fg-black, bg-green', + sprintf( + 'OK (%d test%s, %d assertion%s)', + count($result), + (count($result) === 1) ? '' : 's', + $this->numAssertions, + ($this->numAssertions === 1) ? '' : 's' + ) + ); + + return; + } + + $color = 'fg-black, bg-yellow'; + + if ($result->wasSuccessful()) { + if ($this->verbose || !$result->allHarmless()) { + $this->write("\n"); + } + + $this->writeWithColor( + $color, + 'OK, but incomplete, skipped, or risky tests!' + ); + } else { + $this->write("\n"); + + if ($result->errorCount()) { + $color = 'fg-white, bg-red'; + + $this->writeWithColor( + $color, + 'ERRORS!' + ); + } elseif ($result->failureCount()) { + $color = 'fg-white, bg-red'; + + $this->writeWithColor( + $color, + 'FAILURES!' + ); + } elseif ($result->warningCount()) { + $color = 'fg-black, bg-yellow'; + + $this->writeWithColor( + $color, + 'WARNINGS!' + ); + } + } + + $this->writeCountString(count($result), 'Tests', $color, true); + $this->writeCountString($this->numAssertions, 'Assertions', $color, true); + $this->writeCountString($result->errorCount(), 'Errors', $color); + $this->writeCountString($result->failureCount(), 'Failures', $color); + $this->writeCountString($result->warningCount(), 'Warnings', $color); + $this->writeCountString($result->skippedCount(), 'Skipped', $color); + $this->writeCountString($result->notImplementedCount(), 'Incomplete', $color); + $this->writeCountString($result->riskyCount(), 'Risky', $color); + $this->writeWithColor($color, '.'); + } + + protected function writeProgress(string $progress): void + { + if ($this->debug) { + return; + } + + $this->write($progress); + $this->column++; + $this->numTestsRun++; + + if ($this->column == $this->maxColumn || $this->numTestsRun == $this->numTests) { + if ($this->numTestsRun == $this->numTests) { + $this->write(str_repeat(' ', $this->maxColumn - $this->column)); + } + + $this->write( + sprintf( + ' %' . $this->numTestsWidth . 'd / %' . + $this->numTestsWidth . 'd (%3s%%)', + $this->numTestsRun, + $this->numTests, + floor(($this->numTestsRun / $this->numTests) * 100) + ) + ); + + if ($this->column == $this->maxColumn) { + $this->writeNewLine(); + } + } + } + + protected function writeNewLine(): void + { + $this->column = 0; + $this->write("\n"); + } + + /** + * Formats a buffer with a specified ANSI color sequence if colors are + * enabled. + */ + protected function colorizeTextBox(string $color, string $buffer): string + { + if (!$this->colors) { + return $buffer; + } + + $lines = preg_split('/\r\n|\r|\n/', $buffer); + $padding = max(array_map('\strlen', $lines)); + + $styledLines = []; + + foreach ($lines as $line) { + $styledLines[] = Color::colorize($color, str_pad($line, $padding)); + } + + return implode(PHP_EOL, $styledLines); + } + + /** + * Writes a buffer out with a color sequence if colors are enabled. + */ + protected function writeWithColor(string $color, string $buffer, bool $lf = true): void + { + $this->write($this->colorizeTextBox($color, $buffer)); + + if ($lf) { + $this->write(PHP_EOL); + } + } + + /** + * Writes progress with a color sequence if colors are enabled. + */ + protected function writeProgressWithColor(string $color, string $buffer): void + { + $buffer = $this->colorizeTextBox($color, $buffer); + $this->writeProgress($buffer); + } + + private function writeCountString(int $count, string $name, string $color, bool $always = false): void + { + static $first = true; + + if ($always || $count > 0) { + $this->writeWithColor( + $color, + sprintf( + '%s%s: %d', + !$first ? ', ' : '', + $name, + $count + ), + false + ); + + $first = false; + } + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/Exception/Exception.php b/vendor/phpunit/phpunit/src/TextUI/Exception/Exception.php new file mode 100644 index 000000000..ee2ae4ffa --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/Exception/Exception.php @@ -0,0 +1,19 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI; + +use Throwable; + +/** + * @internal This interface is not covered by the backward compatibility promise for PHPUnit + */ +interface Exception extends Throwable +{ +} diff --git a/vendor/phpunit/phpunit/src/TextUI/Exception/ReflectionException.php b/vendor/phpunit/phpunit/src/TextUI/Exception/ReflectionException.php new file mode 100644 index 000000000..74e9d25dd --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/Exception/ReflectionException.php @@ -0,0 +1,19 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI; + +use RuntimeException; + +/** + * @internal This interface is not covered by the backward compatibility promise for PHPUnit + */ +final class ReflectionException extends RuntimeException implements Exception +{ +} diff --git a/vendor/phpunit/phpunit/src/TextUI/Exception/RuntimeException.php b/vendor/phpunit/phpunit/src/TextUI/Exception/RuntimeException.php new file mode 100644 index 000000000..790a84634 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/Exception/RuntimeException.php @@ -0,0 +1,17 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI; + +/** + * @internal This interface is not covered by the backward compatibility promise for PHPUnit + */ +final class RuntimeException extends \RuntimeException implements Exception +{ +} diff --git a/vendor/phpunit/phpunit/src/TextUI/Exception/TestDirectoryNotFoundException.php b/vendor/phpunit/phpunit/src/TextUI/Exception/TestDirectoryNotFoundException.php new file mode 100644 index 000000000..770ad8742 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/Exception/TestDirectoryNotFoundException.php @@ -0,0 +1,29 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI; + +use function sprintf; +use RuntimeException; + +/** + * @internal This interface is not covered by the backward compatibility promise for PHPUnit + */ +final class TestDirectoryNotFoundException extends RuntimeException implements Exception +{ + public function __construct(string $path) + { + parent::__construct( + sprintf( + 'Test directory "%s" not found', + $path + ) + ); + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/Exception/TestFileNotFoundException.php b/vendor/phpunit/phpunit/src/TextUI/Exception/TestFileNotFoundException.php new file mode 100644 index 000000000..7ffd2c78c --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/Exception/TestFileNotFoundException.php @@ -0,0 +1,29 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI; + +use function sprintf; +use RuntimeException; + +/** + * @internal This interface is not covered by the backward compatibility promise for PHPUnit + */ +final class TestFileNotFoundException extends RuntimeException implements Exception +{ + public function __construct(string $path) + { + parent::__construct( + sprintf( + 'Test file "%s" not found', + $path + ) + ); + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/Help.php b/vendor/phpunit/phpunit/src/TextUI/Help.php index f5af31147..7c5d51c79 100644 --- a/vendor/phpunit/phpunit/src/TextUI/Help.php +++ b/vendor/phpunit/phpunit/src/TextUI/Help.php @@ -30,20 +30,24 @@ final class Help private const HELP_TEXT = [ 'Usage' => [ - ['text' => 'phpunit [options] UnitTest [UnitTest.php]'], + ['text' => 'phpunit [options] UnitTest.php'], ['text' => 'phpunit [options] '], ], + 'Code Coverage Options' => [ ['arg' => '--coverage-clover ', 'desc' => 'Generate code coverage report in Clover XML format'], + ['arg' => '--coverage-cobertura ', 'desc' => 'Generate code coverage report in Cobertura XML format'], ['arg' => '--coverage-crap4j ', 'desc' => 'Generate code coverage report in Crap4J XML format'], ['arg' => '--coverage-html ', 'desc' => 'Generate code coverage report in HTML format'], ['arg' => '--coverage-php ', 'desc' => 'Export PHP_CodeCoverage object to file'], ['arg' => '--coverage-text=', 'desc' => 'Generate code coverage report in text format [default: standard output]'], ['arg' => '--coverage-xml ', 'desc' => 'Generate code coverage report in PHPUnit XML format'], - ['arg' => '--whitelist ', 'desc' => 'Whitelist for code coverage analysis'], + ['arg' => '--coverage-cache ', 'desc' => 'Cache static analysis results'], + ['arg' => '--warm-coverage-cache', 'desc' => 'Warm static analysis cache'], + ['arg' => '--coverage-filter ', 'desc' => 'Include in code coverage analysis'], + ['arg' => '--path-coverage', 'desc' => 'Perform path coverage analysis'], ['arg' => '--disable-coverage-ignore', 'desc' => 'Disable annotations for ignoring code coverage'], ['arg' => '--no-coverage', 'desc' => 'Ignore code coverage configuration'], - ['arg' => '--dump-xdebug-filter ', 'desc' => 'Generate script to set Xdebug code coverage filter'], ], 'Logging Options' => [ @@ -57,14 +61,16 @@ final class Help ], 'Test Selection Options' => [ - ['arg' => '--filter ', 'desc' => 'Filter which tests to run'], + ['arg' => '--list-suites', 'desc' => 'List available test suites'], ['arg' => '--testsuite ', 'desc' => 'Filter which testsuite to run'], + ['arg' => '--list-groups', 'desc' => 'List available test groups'], ['arg' => '--group ', 'desc' => 'Only runs tests from the specified group(s)'], ['arg' => '--exclude-group ', 'desc' => 'Exclude tests from the specified group(s)'], - ['arg' => '--list-groups', 'desc' => 'List available test groups'], - ['arg' => '--list-suites', 'desc' => 'List available test suites'], + ['arg' => '--covers ', 'desc' => 'Only runs tests annotated with "@covers "'], + ['arg' => '--uses ', 'desc' => 'Only runs tests annotated with "@uses "'], ['arg' => '--list-tests', 'desc' => 'List available tests'], ['arg' => '--list-tests-xml ', 'desc' => 'List available tests in XML format'], + ['arg' => '--filter ', 'desc' => 'Filter which tests to run'], ['arg' => '--test-suffix ', 'desc' => 'Only search for test in files with specified suffix(es). Default: Test.php,.phpt'], ], @@ -75,7 +81,7 @@ final class Help ['arg' => '--disallow-test-output', 'desc' => 'Be strict about output during tests'], ['arg' => '--disallow-resource-usage', 'desc' => 'Be strict about resource usage during small tests'], ['arg' => '--enforce-time-limit', 'desc' => 'Enforce time limit based on test size'], - ['arg' => '--default-time-limit=', 'desc' => 'Timeout in seconds for tests without @small, @medium or @large'], + ['arg' => '--default-time-limit ', 'desc' => 'Timeout in seconds for tests without @small, @medium or @large'], ['arg' => '--disallow-todo-tests', 'desc' => 'Disallow @todo-annotated tests'], ['spacer' => ''], @@ -84,7 +90,7 @@ final class Help ['arg' => '--static-backup', 'desc' => 'Backup and restore static attributes for each test'], ['spacer' => ''], - ['arg' => '--colors=', 'desc' => 'Use colors in output ("never", "auto" or "always")'], + ['arg' => '--colors ', 'desc' => 'Use colors in output ("never", "auto" or "always")'], ['arg' => '--columns ', 'desc' => 'Number of columns to use for progress output'], ['arg' => '--columns max', 'desc' => 'Use maximum number of columns for progress output'], ['arg' => '--stderr', 'desc' => 'Write to STDERR instead of STDOUT'], @@ -95,13 +101,14 @@ final class Help ['arg' => '--stop-on-risky', 'desc' => 'Stop execution upon first risky test'], ['arg' => '--stop-on-skipped', 'desc' => 'Stop execution upon first skipped test'], ['arg' => '--stop-on-incomplete', 'desc' => 'Stop execution upon first incomplete test'], - ['arg' => '--fail-on-warning', 'desc' => 'Treat tests with warnings as failures'], + ['arg' => '--fail-on-incomplete', 'desc' => 'Treat incomplete tests as failures'], ['arg' => '--fail-on-risky', 'desc' => 'Treat risky tests as failures'], + ['arg' => '--fail-on-skipped', 'desc' => 'Treat skipped tests as failures'], + ['arg' => '--fail-on-warning', 'desc' => 'Treat tests with warnings as failures'], ['arg' => '-v|--verbose', 'desc' => 'Output more verbose information'], ['arg' => '--debug', 'desc' => 'Display debugging information'], ['spacer' => ''], - ['arg' => '--loader ', 'desc' => 'TestSuiteLoader implementation to use'], ['arg' => '--repeat ', 'desc' => 'Runs the test(s) repeatedly'], ['arg' => '--teamcity', 'desc' => 'Report test execution progress in TeamCity format'], ['arg' => '--testdox', 'desc' => 'Report test execution progress in TestDox format'], @@ -111,8 +118,8 @@ final class Help ['arg' => '--printer ', 'desc' => 'TestListener implementation to use'], ['spacer' => ''], - ['arg' => '--order-by=', 'desc' => 'Run tests in order: default|defects|duration|no-depends|random|reverse|size'], - ['arg' => '--random-order-seed=', 'desc' => 'Use a specific random seed for random order'], + ['arg' => '--order-by ', 'desc' => 'Run tests in order: default|defects|duration|no-depends|random|reverse|size'], + ['arg' => '--random-order-seed ', 'desc' => 'Use a specific random seed for random order'], ['arg' => '--cache-result', 'desc' => 'Write test results to cache file'], ['arg' => '--do-not-cache-result', 'desc' => 'Do not write test results to cache file'], ], @@ -122,11 +129,13 @@ final class Help ['arg' => '--bootstrap ', 'desc' => 'A PHP script that is included before the tests run'], ['arg' => '-c|--configuration ', 'desc' => 'Read configuration from XML file'], ['arg' => '--no-configuration', 'desc' => 'Ignore default configuration file (phpunit.xml)'], + ['arg' => '--extensions ', 'desc' => 'A comma separated list of PHPUnit extensions to load'], ['arg' => '--no-extensions', 'desc' => 'Do not load PHPUnit extensions'], ['arg' => '--include-path ', 'desc' => 'Prepend PHP\'s include_path with given path(s)'], ['arg' => '-d ', 'desc' => 'Sets a php.ini value'], + ['arg' => '--cache-result-file ', 'desc' => 'Specify result cache path and filename'], ['arg' => '--generate-configuration', 'desc' => 'Generate configuration file with suggested settings'], - ['arg' => '--cache-result-file=', 'desc' => 'Specify result cache path and filename'], + ['arg' => '--migrate-configuration', 'desc' => 'Migrate configuration file to current format'], ], 'Miscellaneous Options' => [ diff --git a/vendor/phpunit/phpunit/src/TextUI/ResultPrinter.php b/vendor/phpunit/phpunit/src/TextUI/ResultPrinter.php index c4d06b3d2..ec89f6006 100644 --- a/vendor/phpunit/phpunit/src/TextUI/ResultPrinter.php +++ b/vendor/phpunit/phpunit/src/TextUI/ResultPrinter.php @@ -9,580 +9,15 @@ */ namespace PHPUnit\TextUI; -use const PHP_EOL; -use function array_map; -use function array_reverse; -use function count; -use function floor; -use function implode; -use function in_array; -use function is_int; -use function max; -use function preg_split; -use function sprintf; -use function str_pad; -use function str_repeat; -use function strlen; -use function vsprintf; -use PHPUnit\Framework\AssertionFailedError; -use PHPUnit\Framework\Exception; -use PHPUnit\Framework\InvalidArgumentException; -use PHPUnit\Framework\Test; -use PHPUnit\Framework\TestCase; -use PHPUnit\Framework\TestFailure; use PHPUnit\Framework\TestListener; use PHPUnit\Framework\TestResult; -use PHPUnit\Framework\TestSuite; -use PHPUnit\Framework\Warning; -use PHPUnit\Runner\PhptTestCase; -use PHPUnit\Util\Color; -use PHPUnit\Util\Printer; -use SebastianBergmann\Environment\Console; -use SebastianBergmann\Timer\Timer; -use Throwable; /** - * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ -class ResultPrinter extends Printer implements TestListener +interface ResultPrinter extends TestListener { - public const EVENT_TEST_START = 0; + public function printResult(TestResult $result): void; - public const EVENT_TEST_END = 1; - - public const EVENT_TESTSUITE_START = 2; - - public const EVENT_TESTSUITE_END = 3; - - public const COLOR_NEVER = 'never'; - - public const COLOR_AUTO = 'auto'; - - public const COLOR_ALWAYS = 'always'; - - public const COLOR_DEFAULT = self::COLOR_NEVER; - - private const AVAILABLE_COLORS = [self::COLOR_NEVER, self::COLOR_AUTO, self::COLOR_ALWAYS]; - - /** - * @var int - */ - protected $column = 0; - - /** - * @var int - */ - protected $maxColumn; - - /** - * @var bool - */ - protected $lastTestFailed = false; - - /** - * @var int - */ - protected $numAssertions = 0; - - /** - * @var int - */ - protected $numTests = -1; - - /** - * @var int - */ - protected $numTestsRun = 0; - - /** - * @var int - */ - protected $numTestsWidth; - - /** - * @var bool - */ - protected $colors = false; - - /** - * @var bool - */ - protected $debug = false; - - /** - * @var bool - */ - protected $verbose = false; - - /** - * @var int - */ - private $numberOfColumns; - - /** - * @var bool - */ - private $reverse; - - /** - * @var bool - */ - private $defectListPrinted = false; - - /** - * Constructor. - * - * @param null|resource|string $out - * @param int|string $numberOfColumns - * - * @throws Exception - */ - public function __construct($out = null, bool $verbose = false, string $colors = self::COLOR_DEFAULT, bool $debug = false, $numberOfColumns = 80, bool $reverse = false) - { - parent::__construct($out); - - if (!in_array($colors, self::AVAILABLE_COLORS, true)) { - throw InvalidArgumentException::create( - 3, - vsprintf('value from "%s", "%s" or "%s"', self::AVAILABLE_COLORS) - ); - } - - if (!is_int($numberOfColumns) && $numberOfColumns !== 'max') { - throw InvalidArgumentException::create(5, 'integer or "max"'); - } - - $console = new Console; - $maxNumberOfColumns = $console->getNumberOfColumns(); - - if ($numberOfColumns === 'max' || ($numberOfColumns !== 80 && $numberOfColumns > $maxNumberOfColumns)) { - $numberOfColumns = $maxNumberOfColumns; - } - - $this->numberOfColumns = $numberOfColumns; - $this->verbose = $verbose; - $this->debug = $debug; - $this->reverse = $reverse; - - if ($colors === self::COLOR_AUTO && $console->hasColorSupport()) { - $this->colors = true; - } else { - $this->colors = (self::COLOR_ALWAYS === $colors); - } - } - - /** - * @throws \SebastianBergmann\Timer\RuntimeException - */ - public function printResult(TestResult $result): void - { - $this->printHeader($result); - $this->printErrors($result); - $this->printWarnings($result); - $this->printFailures($result); - $this->printRisky($result); - - if ($this->verbose) { - $this->printIncompletes($result); - $this->printSkipped($result); - } - - $this->printFooter($result); - } - - /** - * An error occurred. - */ - public function addError(Test $test, Throwable $t, float $time): void - { - $this->writeProgressWithColor('fg-red, bold', 'E'); - $this->lastTestFailed = true; - } - - /** - * A failure occurred. - */ - public function addFailure(Test $test, AssertionFailedError $e, float $time): void - { - $this->writeProgressWithColor('bg-red, fg-white', 'F'); - $this->lastTestFailed = true; - } - - /** - * A warning occurred. - */ - public function addWarning(Test $test, Warning $e, float $time): void - { - $this->writeProgressWithColor('fg-yellow, bold', 'W'); - $this->lastTestFailed = true; - } - - /** - * Incomplete test. - */ - public function addIncompleteTest(Test $test, Throwable $t, float $time): void - { - $this->writeProgressWithColor('fg-yellow, bold', 'I'); - $this->lastTestFailed = true; - } - - /** - * Risky test. - */ - public function addRiskyTest(Test $test, Throwable $t, float $time): void - { - $this->writeProgressWithColor('fg-yellow, bold', 'R'); - $this->lastTestFailed = true; - } - - /** - * Skipped test. - */ - public function addSkippedTest(Test $test, Throwable $t, float $time): void - { - $this->writeProgressWithColor('fg-cyan, bold', 'S'); - $this->lastTestFailed = true; - } - - /** - * A testsuite started. - */ - public function startTestSuite(TestSuite $suite): void - { - if ($this->numTests == -1) { - $this->numTests = count($suite); - $this->numTestsWidth = strlen((string) $this->numTests); - $this->maxColumn = $this->numberOfColumns - strlen(' / (XXX%)') - (2 * $this->numTestsWidth); - } - } - - /** - * A testsuite ended. - */ - public function endTestSuite(TestSuite $suite): void - { - } - - /** - * A test started. - */ - public function startTest(Test $test): void - { - if ($this->debug) { - $this->write( - sprintf( - "Test '%s' started\n", - \PHPUnit\Util\Test::describeAsString($test) - ) - ); - } - } - - /** - * A test ended. - */ - public function endTest(Test $test, float $time): void - { - if ($this->debug) { - $this->write( - sprintf( - "Test '%s' ended\n", - \PHPUnit\Util\Test::describeAsString($test) - ) - ); - } - - if (!$this->lastTestFailed) { - $this->writeProgress('.'); - } - - if ($test instanceof TestCase) { - $this->numAssertions += $test->getNumAssertions(); - } elseif ($test instanceof PhptTestCase) { - $this->numAssertions++; - } - - $this->lastTestFailed = false; - - if ($test instanceof TestCase && !$test->hasExpectationOnOutput()) { - $this->write($test->getActualOutput()); - } - } - - protected function printDefects(array $defects, string $type): void - { - $count = count($defects); - - if ($count == 0) { - return; - } - - if ($this->defectListPrinted) { - $this->write("\n--\n\n"); - } - - $this->write( - sprintf( - "There %s %d %s%s:\n", - ($count == 1) ? 'was' : 'were', - $count, - $type, - ($count == 1) ? '' : 's' - ) - ); - - $i = 1; - - if ($this->reverse) { - $defects = array_reverse($defects); - } - - foreach ($defects as $defect) { - $this->printDefect($defect, $i++); - } - - $this->defectListPrinted = true; - } - - protected function printDefect(TestFailure $defect, int $count): void - { - $this->printDefectHeader($defect, $count); - $this->printDefectTrace($defect); - } - - protected function printDefectHeader(TestFailure $defect, int $count): void - { - $this->write( - sprintf( - "\n%d) %s\n", - $count, - $defect->getTestName() - ) - ); - } - - protected function printDefectTrace(TestFailure $defect): void - { - $e = $defect->thrownException(); - $this->write((string) $e); - - while ($e = $e->getPrevious()) { - $this->write("\nCaused by\n" . $e); - } - } - - protected function printErrors(TestResult $result): void - { - $this->printDefects($result->errors(), 'error'); - } - - protected function printFailures(TestResult $result): void - { - $this->printDefects($result->failures(), 'failure'); - } - - protected function printWarnings(TestResult $result): void - { - $this->printDefects($result->warnings(), 'warning'); - } - - protected function printIncompletes(TestResult $result): void - { - $this->printDefects($result->notImplemented(), 'incomplete test'); - } - - protected function printRisky(TestResult $result): void - { - $this->printDefects($result->risky(), 'risky test'); - } - - protected function printSkipped(TestResult $result): void - { - $this->printDefects($result->skipped(), 'skipped test'); - } - - /** - * @throws \SebastianBergmann\Timer\RuntimeException - */ - protected function printHeader(TestResult $result): void - { - if (count($result) > 0) { - $this->write(PHP_EOL . PHP_EOL . Timer::resourceUsage() . PHP_EOL . PHP_EOL); - } - } - - protected function printFooter(TestResult $result): void - { - if (count($result) === 0) { - $this->writeWithColor( - 'fg-black, bg-yellow', - 'No tests executed!' - ); - - return; - } - - if ($result->wasSuccessfulAndNoTestIsRiskyOrSkippedOrIncomplete()) { - $this->writeWithColor( - 'fg-black, bg-green', - sprintf( - 'OK (%d test%s, %d assertion%s)', - count($result), - (count($result) == 1) ? '' : 's', - $this->numAssertions, - ($this->numAssertions == 1) ? '' : 's' - ) - ); - - return; - } - - $color = 'fg-black, bg-yellow'; - - if ($result->wasSuccessful()) { - if ($this->verbose || !$result->allHarmless()) { - $this->write("\n"); - } - - $this->writeWithColor( - $color, - 'OK, but incomplete, skipped, or risky tests!' - ); - } else { - $this->write("\n"); - - if ($result->errorCount()) { - $color = 'fg-white, bg-red'; - - $this->writeWithColor( - $color, - 'ERRORS!' - ); - } elseif ($result->failureCount()) { - $color = 'fg-white, bg-red'; - - $this->writeWithColor( - $color, - 'FAILURES!' - ); - } elseif ($result->warningCount()) { - $color = 'fg-black, bg-yellow'; - - $this->writeWithColor( - $color, - 'WARNINGS!' - ); - } - } - - $this->writeCountString(count($result), 'Tests', $color, true); - $this->writeCountString($this->numAssertions, 'Assertions', $color, true); - $this->writeCountString($result->errorCount(), 'Errors', $color); - $this->writeCountString($result->failureCount(), 'Failures', $color); - $this->writeCountString($result->warningCount(), 'Warnings', $color); - $this->writeCountString($result->skippedCount(), 'Skipped', $color); - $this->writeCountString($result->notImplementedCount(), 'Incomplete', $color); - $this->writeCountString($result->riskyCount(), 'Risky', $color); - $this->writeWithColor($color, '.'); - } - - protected function writeProgress(string $progress): void - { - if ($this->debug) { - return; - } - - $this->write($progress); - $this->column++; - $this->numTestsRun++; - - if ($this->column == $this->maxColumn || $this->numTestsRun == $this->numTests) { - if ($this->numTestsRun == $this->numTests) { - $this->write(str_repeat(' ', $this->maxColumn - $this->column)); - } - - $this->write( - sprintf( - ' %' . $this->numTestsWidth . 'd / %' . - $this->numTestsWidth . 'd (%3s%%)', - $this->numTestsRun, - $this->numTests, - floor(($this->numTestsRun / $this->numTests) * 100) - ) - ); - - if ($this->column == $this->maxColumn) { - $this->writeNewLine(); - } - } - } - - protected function writeNewLine(): void - { - $this->column = 0; - $this->write("\n"); - } - - /** - * Formats a buffer with a specified ANSI color sequence if colors are - * enabled. - */ - protected function colorizeTextBox(string $color, string $buffer): string - { - if (!$this->colors) { - return $buffer; - } - - $lines = preg_split('/\r\n|\r|\n/', $buffer); - $padding = max(array_map('\strlen', $lines)); - - $styledLines = []; - - foreach ($lines as $line) { - $styledLines[] = Color::colorize($color, str_pad($line, $padding)); - } - - return implode(PHP_EOL, $styledLines); - } - - /** - * Writes a buffer out with a color sequence if colors are enabled. - */ - protected function writeWithColor(string $color, string $buffer, bool $lf = true): void - { - $this->write($this->colorizeTextBox($color, $buffer)); - - if ($lf) { - $this->write(PHP_EOL); - } - } - - /** - * Writes progress with a color sequence if colors are enabled. - */ - protected function writeProgressWithColor(string $color, string $buffer): void - { - $buffer = $this->colorizeTextBox($color, $buffer); - $this->writeProgress($buffer); - } - - private function writeCountString(int $count, string $name, string $color, bool $always = false): void - { - static $first = true; - - if ($always || $count > 0) { - $this->writeWithColor( - $color, - sprintf( - '%s%s: %d', - !$first ? ', ' : '', - $name, - $count - ), - false - ); - - $first = false; - } - } + public function write(string $buffer): void; } diff --git a/vendor/phpunit/phpunit/src/TextUI/TestRunner.php b/vendor/phpunit/phpunit/src/TextUI/TestRunner.php index 017b63a63..d8dc0581b 100644 --- a/vendor/phpunit/phpunit/src/TextUI/TestRunner.php +++ b/vendor/phpunit/phpunit/src/TextUI/TestRunner.php @@ -10,36 +10,32 @@ namespace PHPUnit\TextUI; use const PHP_EOL; -use const PHP_MAJOR_VERSION; use const PHP_SAPI; +use const PHP_VERSION; use function array_diff; +use function array_map; use function assert; use function class_exists; use function count; use function dirname; -use function extension_loaded; use function file_put_contents; use function htmlspecialchars; -use function ini_get; +use function is_array; use function is_int; use function is_string; -use function is_subclass_of; use function mt_srand; use function range; use function realpath; use function sprintf; -use function strpos; use function time; use PHPUnit\Framework\Exception; -use PHPUnit\Framework\Test; -use PHPUnit\Framework\TestCase; -use PHPUnit\Framework\TestListener; use PHPUnit\Framework\TestResult; use PHPUnit\Framework\TestSuite; use PHPUnit\Runner\AfterLastTestHook; use PHPUnit\Runner\BaseTestRunner; use PHPUnit\Runner\BeforeFirstTestHook; use PHPUnit\Runner\DefaultTestResultCache; +use PHPUnit\Runner\Extension\ExtensionHandler; use PHPUnit\Runner\Filter\ExcludeGroupFilterIterator; use PHPUnit\Runner\Filter\Factory; use PHPUnit\Runner\Filter\IncludeGroupFilterIterator; @@ -53,7 +49,10 @@ use PHPUnit\Runner\TestListenerAdapter; use PHPUnit\Runner\TestSuiteLoader; use PHPUnit\Runner\TestSuiteSorter; use PHPUnit\Runner\Version; -use PHPUnit\Util\Configuration; +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\FilterMapper; +use PHPUnit\TextUI\XmlConfiguration\Configuration; +use PHPUnit\TextUI\XmlConfiguration\Loader; +use PHPUnit\TextUI\XmlConfiguration\PhpHandler; use PHPUnit\Util\Filesystem; use PHPUnit\Util\Log\JUnit; use PHPUnit\Util\Log\TeamCity; @@ -63,12 +62,15 @@ use PHPUnit\Util\TestDox\HtmlResultPrinter; use PHPUnit\Util\TestDox\TextResultPrinter; use PHPUnit\Util\TestDox\XmlResultPrinter; use PHPUnit\Util\XdebugFilterScriptGenerator; +use PHPUnit\Util\Xml\SchemaDetector; use ReflectionClass; use ReflectionException; use SebastianBergmann\CodeCoverage\CodeCoverage; +use SebastianBergmann\CodeCoverage\Driver\Selector; use SebastianBergmann\CodeCoverage\Exception as CodeCoverageException; use SebastianBergmann\CodeCoverage\Filter as CodeCoverageFilter; use SebastianBergmann\CodeCoverage\Report\Clover as CloverReport; +use SebastianBergmann\CodeCoverage\Report\Cobertura as CoberturaReport; use SebastianBergmann\CodeCoverage\Report\Crap4j as Crap4jReport; use SebastianBergmann\CodeCoverage\Report\Html\Facade as HtmlReport; use SebastianBergmann\CodeCoverage\Report\PHP as PhpReport; @@ -106,15 +108,10 @@ final class TestRunner extends BaseTestRunner private $loader; /** - * @psalm-var Printer&TestListener + * @var ResultPrinter */ private $printer; - /** - * @var Runtime - */ - private $runtime; - /** * @var bool */ @@ -125,6 +122,11 @@ final class TestRunner extends BaseTestRunner */ private $extensions = []; + /** + * @var Timer + */ + private $timer; + public function __construct(TestSuiteLoader $loader = null, CodeCoverageFilter $filter = null) { if ($filter === null) { @@ -133,14 +135,15 @@ final class TestRunner extends BaseTestRunner $this->codeCoverageFilter = $filter; $this->loader = $loader; - $this->runtime = new Runtime; + $this->timer = new Timer; } /** * @throws \PHPUnit\Runner\Exception + * @throws \PHPUnit\TextUI\XmlConfiguration\Exception * @throws Exception */ - public function doRun(Test $suite, array $arguments = [], array $warnings = [], bool $exit = true): TestResult + public function run(TestSuite $suite, array $arguments = [], array $warnings = [], bool $exit = true): TestResult { if (isset($arguments['configuration'])) { $GLOBALS['__PHPUNIT_CONFIGURATION_FILE'] = $arguments['configuration']; @@ -157,18 +160,16 @@ final class TestRunner extends BaseTestRunner $GLOBALS['__PHPUNIT_BOOTSTRAP'] = $arguments['bootstrap']; } - if ($suite instanceof TestCase || $suite instanceof TestSuite) { - if ($arguments['backupGlobals'] === true) { - $suite->setBackupGlobals(true); - } + if ($arguments['backupGlobals'] === true) { + $suite->setBackupGlobals(true); + } - if ($arguments['backupStaticAttributes'] === true) { - $suite->setBackupStaticAttributes(true); - } + if ($arguments['backupStaticAttributes'] === true) { + $suite->setBackupStaticAttributes(true); + } - if ($arguments['beStrictAboutChangesToGlobalState'] === true) { - $suite->setBeStrictAboutChangesToGlobalState(true); - } + if ($arguments['beStrictAboutChangesToGlobalState'] === true) { + $suite->setBeStrictAboutChangesToGlobalState(true); } if ($arguments['executionOrder'] === TestSuiteSorter::ORDER_RANDOMIZED) { @@ -177,8 +178,10 @@ final class TestRunner extends BaseTestRunner if ($arguments['cacheResult']) { if (!isset($arguments['cacheResultFile'])) { - if (isset($arguments['configuration']) && $arguments['configuration'] instanceof Configuration) { - $cacheLocation = $arguments['configuration']->getFilename(); + if (isset($arguments['configurationObject'])) { + assert($arguments['configurationObject'] instanceof Configuration); + + $cacheLocation = $arguments['configurationObject']->filename(); } else { $cacheLocation = $_SERVER['PHP_SELF']; } @@ -292,11 +295,16 @@ final class TestRunner extends BaseTestRunner if ($this->printer === null) { if (isset($arguments['printer'])) { - if ($arguments['printer'] instanceof Printer && $arguments['printer'] instanceof TestListener) { + if ($arguments['printer'] instanceof ResultPrinter) { $this->printer = $arguments['printer']; } elseif (is_string($arguments['printer']) && class_exists($arguments['printer'], false)) { try { - new ReflectionClass($arguments['printer']); + $reflector = new ReflectionClass($arguments['printer']); + + if ($reflector->implementsInterface(ResultPrinter::class)) { + $this->printer = $this->createPrinter($arguments['printer'], $arguments); + } + // @codeCoverageIgnoreStart } catch (ReflectionException $e) { throw new Exception( @@ -306,13 +314,9 @@ final class TestRunner extends BaseTestRunner ); } // @codeCoverageIgnoreEnd - - if (is_subclass_of($arguments['printer'], ResultPrinter::class)) { - $this->printer = $this->createPrinter($arguments['printer'], $arguments); - } } } else { - $this->printer = $this->createPrinter(ResultPrinter::class, $arguments); + $this->printer = $this->createPrinter(DefaultResultPrinter::class, $arguments); } } @@ -329,13 +333,213 @@ final class TestRunner extends BaseTestRunner self::$versionStringPrinted = true; - if ($arguments['verbose']) { - $this->writeMessage('Runtime', $this->runtime->getNameWithVersionAndCodeCoverageDriver()); + foreach ($arguments['listeners'] as $listener) { + $result->addListener($listener); + } + + $result->addListener($this->printer); + + $coverageFilterFromConfigurationFile = false; + $coverageFilterFromOption = false; + $codeCoverageReports = 0; + + if (isset($arguments['testdoxHTMLFile'])) { + $result->addListener( + new HtmlResultPrinter( + $arguments['testdoxHTMLFile'], + $arguments['testdoxGroups'], + $arguments['testdoxExcludeGroups'] + ) + ); + } + + if (isset($arguments['testdoxTextFile'])) { + $result->addListener( + new TextResultPrinter( + $arguments['testdoxTextFile'], + $arguments['testdoxGroups'], + $arguments['testdoxExcludeGroups'] + ) + ); + } + + if (isset($arguments['testdoxXMLFile'])) { + $result->addListener( + new XmlResultPrinter( + $arguments['testdoxXMLFile'] + ) + ); + } + + if (isset($arguments['teamcityLogfile'])) { + $result->addListener( + new TeamCity($arguments['teamcityLogfile']) + ); + } + + if (isset($arguments['junitLogfile'])) { + $result->addListener( + new JUnit( + $arguments['junitLogfile'], + $arguments['reportUselessTests'] + ) + ); + } + + if (isset($arguments['coverageClover'])) { + $codeCoverageReports++; + } + + if (isset($arguments['coverageCobertura'])) { + $codeCoverageReports++; + } + + if (isset($arguments['coverageCrap4J'])) { + $codeCoverageReports++; + } + + if (isset($arguments['coverageHtml'])) { + $codeCoverageReports++; + } + + if (isset($arguments['coveragePHP'])) { + $codeCoverageReports++; + } + + if (isset($arguments['coverageText'])) { + $codeCoverageReports++; + } + + if (isset($arguments['coverageXml'])) { + $codeCoverageReports++; + } + + if ($codeCoverageReports > 0 || isset($arguments['xdebugFilterFile'])) { + if (isset($arguments['coverageFilter'])) { + if (!is_array($arguments['coverageFilter'])) { + $coverageFilterDirectories = [$arguments['coverageFilter']]; + } else { + $coverageFilterDirectories = $arguments['coverageFilter']; + } + + foreach ($coverageFilterDirectories as $coverageFilterDirectory) { + $this->codeCoverageFilter->includeDirectory($coverageFilterDirectory); + } + + $coverageFilterFromOption = true; + } + + if (isset($arguments['configurationObject'])) { + assert($arguments['configurationObject'] instanceof Configuration); + + $codeCoverageConfiguration = $arguments['configurationObject']->codeCoverage(); + + if ($codeCoverageConfiguration->hasNonEmptyListOfFilesToBeIncludedInCodeCoverageReport()) { + $coverageFilterFromConfigurationFile = true; + + (new FilterMapper)->map( + $this->codeCoverageFilter, + $codeCoverageConfiguration + ); + } + } + } + + if ($codeCoverageReports > 0) { + try { + if (isset($codeCoverageConfiguration) && + ($codeCoverageConfiguration->pathCoverage() || (isset($arguments['pathCoverage']) && $arguments['pathCoverage'] === true))) { + $codeCoverageDriver = (new Selector)->forLineAndPathCoverage($this->codeCoverageFilter); + } else { + $codeCoverageDriver = (new Selector)->forLineCoverage($this->codeCoverageFilter); + } + + $codeCoverage = new CodeCoverage( + $codeCoverageDriver, + $this->codeCoverageFilter + ); + + if (isset($codeCoverageConfiguration) && $codeCoverageConfiguration->hasCacheDirectory()) { + $codeCoverage->cacheStaticAnalysis($codeCoverageConfiguration->cacheDirectory()->path()); + } + + if (isset($arguments['coverageCacheDirectory'])) { + $codeCoverage->cacheStaticAnalysis($arguments['coverageCacheDirectory']); + } + + $codeCoverage->excludeSubclassesOfThisClassFromUnintentionallyCoveredCodeCheck(Comparator::class); + + if ($arguments['strictCoverage']) { + $codeCoverage->enableCheckForUnintentionallyCoveredCode(); + } + + if (isset($arguments['ignoreDeprecatedCodeUnitsFromCodeCoverage'])) { + if ($arguments['ignoreDeprecatedCodeUnitsFromCodeCoverage']) { + $codeCoverage->ignoreDeprecatedCode(); + } else { + $codeCoverage->doNotIgnoreDeprecatedCode(); + } + } + + if (isset($arguments['disableCodeCoverageIgnore'])) { + if ($arguments['disableCodeCoverageIgnore']) { + $codeCoverage->disableAnnotationsForIgnoringCode(); + } else { + $codeCoverage->enableAnnotationsForIgnoringCode(); + } + } + + if (isset($arguments['configurationObject'])) { + $codeCoverageConfiguration = $arguments['configurationObject']->codeCoverage(); + + if ($codeCoverageConfiguration->hasNonEmptyListOfFilesToBeIncludedInCodeCoverageReport()) { + if ($codeCoverageConfiguration->includeUncoveredFiles()) { + $codeCoverage->includeUncoveredFiles(); + } else { + $codeCoverage->excludeUncoveredFiles(); + } + + if ($codeCoverageConfiguration->processUncoveredFiles()) { + $codeCoverage->processUncoveredFiles(); + } else { + $codeCoverage->doNotProcessUncoveredFiles(); + } + } + } + + if ($this->codeCoverageFilter->isEmpty()) { + if (!$coverageFilterFromConfigurationFile && !$coverageFilterFromOption) { + $warnings[] = 'No filter is configured, code coverage will not be processed'; + } else { + $warnings[] = 'Incorrect filter configuration, code coverage will not be processed'; + } + + unset($codeCoverage); + } + } catch (CodeCoverageException $e) { + $warnings[] = $e->getMessage(); + } + } + + if ($arguments['verbose']) { + if (PHP_SAPI === 'phpdbg') { + $this->writeMessage('Runtime', 'PHPDBG ' . PHP_VERSION); + } else { + $runtime = 'PHP ' . PHP_VERSION; + + if (isset($codeCoverageDriver)) { + $runtime .= ' with ' . $codeCoverageDriver->nameAndVersion(); + } + + $this->writeMessage('Runtime', $runtime); + } + + if (isset($arguments['configurationObject'])) { + assert($arguments['configurationObject'] instanceof Configuration); - if (isset($arguments['configuration'])) { $this->writeMessage( 'Configuration', - $arguments['configuration']->getFilename() + $arguments['configurationObject']->filename() ); } @@ -354,250 +558,52 @@ final class TestRunner extends BaseTestRunner } } - foreach ($warnings as $warning) { - $this->writeMessage('Warning', $warning); - } - if ($arguments['executionOrder'] === TestSuiteSorter::ORDER_RANDOMIZED) { $this->writeMessage( - 'Random seed', + 'Random Seed', (string) $arguments['randomOrderSeed'] ); } if (isset($tooFewColumnsRequested)) { - $this->writeMessage('Error', 'Less than 16 columns requested, number of columns set to 16'); + $warnings[] = 'Less than 16 columns requested, number of columns set to 16'; } - if ($this->runtime->discardsComments()) { - $this->writeMessage('Warning', 'opcache.save_comments=0 set; annotations will not work'); - } - - if (isset($arguments['configuration']) && $arguments['configuration']->hasValidationErrors()) { - $this->write( - "\n Warning - The configuration file did not pass validation!\n The following problems have been detected:\n" - ); - - foreach ($arguments['configuration']->getValidationErrors() as $line => $errors) { - $this->write(sprintf("\n Line %d:\n", $line)); - - foreach ($errors as $msg) { - $this->write(sprintf(" - %s\n", $msg)); - } - } - - $this->write("\n Test results may not be as expected.\n\n"); + if ((new Runtime)->discardsComments()) { + $warnings[] = 'opcache.save_comments=0 set; annotations will not work'; } if (isset($arguments['conflictBetweenPrinterClassAndTestdox'])) { - $this->writeMessage('Warning', 'Directives printerClass and testdox are mutually exclusive'); + $warnings[] = 'Directives printerClass and testdox are mutually exclusive'; } - foreach ($arguments['listeners'] as $listener) { - $result->addListener($listener); + foreach ($warnings as $warning) { + $this->writeMessage('Warning', $warning); } - $result->addListener($this->printer); + if (isset($arguments['configurationObject'])) { + assert($arguments['configurationObject'] instanceof Configuration); - $codeCoverageReports = 0; + if ($arguments['configurationObject']->hasValidationErrors()) { + if ((new SchemaDetector)->detect($arguments['configurationObject']->filename())->detected()) { + $this->writeMessage('Warning', 'Your XML configuration validates against a deprecated schema.'); + $this->writeMessage('Suggestion', 'Migrate your XML configuration using "--migrate-configuration"!'); + } else { + $this->write( + "\n Warning - The configuration file did not pass validation!\n The following problems have been detected:\n" + ); - if (!isset($arguments['noLogging'])) { - if (isset($arguments['testdoxHTMLFile'])) { - $result->addListener( - new HtmlResultPrinter( - $arguments['testdoxHTMLFile'], - $arguments['testdoxGroups'], - $arguments['testdoxExcludeGroups'] - ) - ); - } + $this->write($arguments['configurationObject']->validationErrors()); - if (isset($arguments['testdoxTextFile'])) { - $result->addListener( - new TextResultPrinter( - $arguments['testdoxTextFile'], - $arguments['testdoxGroups'], - $arguments['testdoxExcludeGroups'] - ) - ); - } - - if (isset($arguments['testdoxXMLFile'])) { - $result->addListener( - new XmlResultPrinter( - $arguments['testdoxXMLFile'] - ) - ); - } - - if (isset($arguments['teamcityLogfile'])) { - $result->addListener( - new TeamCity($arguments['teamcityLogfile']) - ); - } - - if (isset($arguments['junitLogfile'])) { - $result->addListener( - new JUnit( - $arguments['junitLogfile'], - $arguments['reportUselessTests'] - ) - ); - } - - if (isset($arguments['coverageClover'])) { - $codeCoverageReports++; - } - - if (isset($arguments['coverageCrap4J'])) { - $codeCoverageReports++; - } - - if (isset($arguments['coverageHtml'])) { - $codeCoverageReports++; - } - - if (isset($arguments['coveragePHP'])) { - $codeCoverageReports++; - } - - if (isset($arguments['coverageText'])) { - $codeCoverageReports++; - } - - if (isset($arguments['coverageXml'])) { - $codeCoverageReports++; - } - } - - if (isset($arguments['noCoverage'])) { - $codeCoverageReports = 0; - } - - if ($codeCoverageReports > 0 && PHP_MAJOR_VERSION < 8 && !$this->runtime->canCollectCodeCoverage()) { - $this->writeMessage('Error', 'No code coverage driver is available'); - - $codeCoverageReports = 0; - } - - if ($codeCoverageReports > 0 || isset($arguments['xdebugFilterFile'])) { - $whitelistFromConfigurationFile = false; - $whitelistFromOption = false; - - if (isset($arguments['whitelist'])) { - $this->codeCoverageFilter->addDirectoryToWhitelist($arguments['whitelist']); - - $whitelistFromOption = true; - } - - if (isset($arguments['configuration'])) { - $filterConfiguration = $arguments['configuration']->getFilterConfiguration(); - - if (!empty($filterConfiguration['whitelist'])) { - $whitelistFromConfigurationFile = true; - } - - if (!empty($filterConfiguration['whitelist'])) { - foreach ($filterConfiguration['whitelist']['include']['directory'] as $dir) { - $this->codeCoverageFilter->addDirectoryToWhitelist( - $dir['path'], - $dir['suffix'], - $dir['prefix'] - ); - } - - foreach ($filterConfiguration['whitelist']['include']['file'] as $file) { - $this->codeCoverageFilter->addFileToWhitelist($file); - } - - foreach ($filterConfiguration['whitelist']['exclude']['directory'] as $dir) { - $this->codeCoverageFilter->removeDirectoryFromWhitelist( - $dir['path'], - $dir['suffix'], - $dir['prefix'] - ); - } - - foreach ($filterConfiguration['whitelist']['exclude']['file'] as $file) { - $this->codeCoverageFilter->removeFileFromWhitelist($file); - } + $this->write("\n Test results may not be as expected.\n\n"); } } } - if ($codeCoverageReports > 0) { - if (PHP_MAJOR_VERSION >= 8) { - $this->writeMessage('Error', 'This version of PHPUnit does not support code coverage on PHP 8'); + if (isset($arguments['xdebugFilterFile'], $codeCoverageConfiguration)) { + $this->write(PHP_EOL . 'Please note that --dump-xdebug-filter and --prepend are deprecated and will be removed in PHPUnit 10.' . PHP_EOL); - $codeCoverageReports = 0; - } else { - try { - $codeCoverage = new CodeCoverage( - null, - $this->codeCoverageFilter - ); - - $codeCoverage->setUnintentionallyCoveredSubclassesWhitelist( - [Comparator::class] - ); - - $codeCoverage->setCheckForUnintentionallyCoveredCode( - $arguments['strictCoverage'] - ); - - $codeCoverage->setCheckForMissingCoversAnnotation( - $arguments['strictCoverage'] - ); - - if (isset($arguments['forceCoversAnnotation'])) { - $codeCoverage->setForceCoversAnnotation( - $arguments['forceCoversAnnotation'] - ); - } - - if (isset($arguments['ignoreDeprecatedCodeUnitsFromCodeCoverage'])) { - $codeCoverage->setIgnoreDeprecatedCode( - $arguments['ignoreDeprecatedCodeUnitsFromCodeCoverage'] - ); - } - - if (isset($arguments['disableCodeCoverageIgnore'])) { - $codeCoverage->setDisableIgnoredLines(true); - } - - if (!empty($filterConfiguration['whitelist'])) { - $codeCoverage->setAddUncoveredFilesFromWhitelist( - $filterConfiguration['whitelist']['addUncoveredFilesFromWhitelist'] - ); - - $codeCoverage->setProcessUncoveredFilesFromWhitelist( - $filterConfiguration['whitelist']['processUncoveredFilesFromWhitelist'] - ); - } - - if (!$this->codeCoverageFilter->hasWhitelist()) { - if (!$whitelistFromConfigurationFile && !$whitelistFromOption) { - $this->writeMessage('Error', 'No whitelist is configured, no code coverage will be generated.'); - } else { - $this->writeMessage('Error', 'Incorrect whitelist config, no code coverage will be generated.'); - } - - $codeCoverageReports = 0; - - unset($codeCoverage); - } - } catch (CodeCoverageException $e) { - $this->writeMessage('Error', $e->getMessage()); - - $codeCoverageReports = 0; - } - } - } - - if (isset($arguments['xdebugFilterFile'], $filterConfiguration)) { - $this->write("\n"); - - $script = (new XdebugFilterScriptGenerator)->generate($filterConfiguration['whitelist']); + $script = (new XdebugFilterScriptGenerator)->generate($codeCoverageConfiguration); if ($arguments['xdebugFilterFile'] !== 'php://stdout' && $arguments['xdebugFilterFile'] !== 'php://stderr' && !Filesystem::createDirectory(dirname($arguments['xdebugFilterFile']))) { $this->write(sprintf('Cannot write Xdebug filter script to %s ' . PHP_EOL, $arguments['xdebugFilterFile'])); @@ -607,7 +613,7 @@ final class TestRunner extends BaseTestRunner file_put_contents($arguments['xdebugFilterFile'], $script); - $this->write(sprintf('Wrote Xdebug filter script to %s ' . PHP_EOL, $arguments['xdebugFilterFile'])); + $this->write(sprintf('Wrote Xdebug filter script to %s ' . PHP_EOL . PHP_EOL, $arguments['xdebugFilterFile'])); exit(self::SUCCESS_EXIT); } @@ -616,10 +622,6 @@ final class TestRunner extends BaseTestRunner if (isset($codeCoverage)) { $result->setCodeCoverage($codeCoverage); - - if ($codeCoverageReports > 1 && isset($arguments['cacheTokens'])) { - $codeCoverage->setCacheTokens($arguments['cacheTokens']); - } } $result->beStrictAboutTestsThatDoNotTestAnything($arguments['reportUselessTests']); @@ -627,32 +629,41 @@ final class TestRunner extends BaseTestRunner $result->beStrictAboutTodoAnnotatedTests($arguments['disallowTodoAnnotatedTests']); $result->beStrictAboutResourceUsageDuringSmallTests($arguments['beStrictAboutResourceUsageDuringSmallTests']); - if ($arguments['enforceTimeLimit'] === true) { - if (!class_exists(Invoker::class)) { - $this->writeMessage('Error', 'Package phpunit/php-invoker is required for enforcing time limits'); - } - - if (!extension_loaded('pcntl') || strpos(ini_get('disable_functions'), 'pcntl') !== false) { - $this->writeMessage('Error', 'PHP extension pcntl is required for enforcing time limits'); - } + if ($arguments['enforceTimeLimit'] === true && !(new Invoker)->canInvokeWithTimeout()) { + $this->writeMessage('Error', 'PHP extension pcntl is required for enforcing time limits'); } + $result->enforceTimeLimit($arguments['enforceTimeLimit']); $result->setDefaultTimeLimit($arguments['defaultTimeLimit']); $result->setTimeoutForSmallTests($arguments['timeoutForSmallTests']); $result->setTimeoutForMediumTests($arguments['timeoutForMediumTests']); $result->setTimeoutForLargeTests($arguments['timeoutForLargeTests']); - if ($suite instanceof TestSuite) { - $this->processSuiteFilters($suite, $arguments); - $suite->setRunTestInSeparateProcess($arguments['processIsolation']); + if (isset($arguments['forceCoversAnnotation']) && $arguments['forceCoversAnnotation'] === true) { + $result->forceCoversAnnotation(); } + $this->processSuiteFilters($suite, $arguments); + $suite->setRunTestInSeparateProcess($arguments['processIsolation']); + foreach ($this->extensions as $extension) { if ($extension instanceof BeforeFirstTestHook) { $extension->executeBeforeFirstTest(); } } + $testSuiteWarningsPrinted = false; + + foreach ($suite->warnings() as $warning) { + $this->writeMessage('Warning', $warning); + + $testSuiteWarningsPrinted = true; + } + + if ($testSuiteWarningsPrinted) { + $this->write(PHP_EOL); + } + $suite->run($result); foreach ($this->extensions as $extension) { @@ -662,10 +673,7 @@ final class TestRunner extends BaseTestRunner } $result->flushListeners(); - - if ($this->printer instanceof ResultPrinter) { - $this->printer->printResult($result); - } + $this->printer->printResult($result); if (isset($codeCoverage)) { if (isset($arguments['coverageClover'])) { @@ -683,6 +691,21 @@ final class TestRunner extends BaseTestRunner } } + if (isset($arguments['coverageCobertura'])) { + $this->codeCoverageGenerationStart('Cobertura XML'); + + try { + $writer = new CoberturaReport; + $writer->process($codeCoverage, $arguments['coverageCobertura']); + + $this->codeCoverageGenerationSucceeded(); + + unset($writer); + } catch (CodeCoverageException $e) { + $this->codeCoverageGenerationFailed($e); + } + } + if (isset($arguments['coverageCrap4J'])) { $this->codeCoverageGenerationStart('Crap4J XML'); @@ -739,7 +762,7 @@ final class TestRunner extends BaseTestRunner if (isset($arguments['coverageText'])) { if ($arguments['coverageText'] === 'php://stdout') { $outputStream = $this->printer; - $colors = $arguments['colors'] && $arguments['colors'] !== ResultPrinter::COLOR_NEVER; + $colors = $arguments['colors'] && $arguments['colors'] !== DefaultResultPrinter::COLOR_NEVER; } else { $outputStream = new Printer($arguments['coverageText']); $colors = false; @@ -774,6 +797,10 @@ final class TestRunner extends BaseTestRunner } if ($exit) { + if (isset($arguments['failOnEmptyTestSuite']) && $arguments['failOnEmptyTestSuite'] === true && count($result) === 0) { + exit(self::FAILURE_EXIT); + } + if ($result->wasSuccessfulIgnoringWarnings()) { if ($arguments['failOnRisky'] && !$result->allHarmless()) { exit(self::FAILURE_EXIT); @@ -783,6 +810,14 @@ final class TestRunner extends BaseTestRunner exit(self::FAILURE_EXIT); } + if ($arguments['failOnIncomplete'] && $result->notImplementedCount() > 0) { + exit(self::FAILURE_EXIT); + } + + if ($arguments['failOnSkipped'] && $result->skippedCount() > 0) { + exit(self::FAILURE_EXIT); + } + exit(self::SUCCESS_EXIT); } @@ -798,11 +833,6 @@ final class TestRunner extends BaseTestRunner return $result; } - public function setPrinter(ResultPrinter $resultPrinter): void - { - $this->printer = $resultPrinter; - } - /** * Returns the loader to be used. */ @@ -850,199 +880,125 @@ final class TestRunner extends BaseTestRunner } /** + * @throws \PHPUnit\TextUI\XmlConfiguration\Exception * @throws Exception */ private function handleConfiguration(array &$arguments): void { - if (isset($arguments['configuration']) && - !$arguments['configuration'] instanceof Configuration) { - $arguments['configuration'] = Configuration::getInstance( - $arguments['configuration'] - ); + if (!isset($arguments['configurationObject']) && isset($arguments['configuration'])) { + $arguments['configurationObject'] = (new Loader)->load($arguments['configuration']); } $arguments['debug'] = $arguments['debug'] ?? false; $arguments['filter'] = $arguments['filter'] ?? false; $arguments['listeners'] = $arguments['listeners'] ?? []; - if (isset($arguments['configuration'])) { - $arguments['configuration']->handlePHPConfiguration(); + if (isset($arguments['configurationObject'])) { + (new PhpHandler)->handle($arguments['configurationObject']->php()); - $phpunitConfiguration = $arguments['configuration']->getPHPUnitConfiguration(); + $codeCoverageConfiguration = $arguments['configurationObject']->codeCoverage(); - if (isset($phpunitConfiguration['backupGlobals']) && !isset($arguments['backupGlobals'])) { - $arguments['backupGlobals'] = $phpunitConfiguration['backupGlobals']; + if (!isset($arguments['noCoverage'])) { + if (!isset($arguments['coverageClover']) && $codeCoverageConfiguration->hasClover()) { + $arguments['coverageClover'] = $codeCoverageConfiguration->clover()->target()->path(); + } + + if (!isset($arguments['coverageCobertura']) && $codeCoverageConfiguration->hasCobertura()) { + $arguments['coverageCobertura'] = $codeCoverageConfiguration->cobertura()->target()->path(); + } + + if (!isset($arguments['coverageCrap4J']) && $codeCoverageConfiguration->hasCrap4j()) { + $arguments['coverageCrap4J'] = $codeCoverageConfiguration->crap4j()->target()->path(); + + if (!isset($arguments['crap4jThreshold'])) { + $arguments['crap4jThreshold'] = $codeCoverageConfiguration->crap4j()->threshold(); + } + } + + if (!isset($arguments['coverageHtml']) && $codeCoverageConfiguration->hasHtml()) { + $arguments['coverageHtml'] = $codeCoverageConfiguration->html()->target()->path(); + + if (!isset($arguments['reportLowUpperBound'])) { + $arguments['reportLowUpperBound'] = $codeCoverageConfiguration->html()->lowUpperBound(); + } + + if (!isset($arguments['reportHighLowerBound'])) { + $arguments['reportHighLowerBound'] = $codeCoverageConfiguration->html()->highLowerBound(); + } + } + + if (!isset($arguments['coveragePHP']) && $codeCoverageConfiguration->hasPhp()) { + $arguments['coveragePHP'] = $codeCoverageConfiguration->php()->target()->path(); + } + + if (!isset($arguments['coverageText']) && $codeCoverageConfiguration->hasText()) { + $arguments['coverageText'] = $codeCoverageConfiguration->text()->target()->path(); + $arguments['coverageTextShowUncoveredFiles'] = $codeCoverageConfiguration->text()->showUncoveredFiles(); + $arguments['coverageTextShowOnlySummary'] = $codeCoverageConfiguration->text()->showOnlySummary(); + } + + if (!isset($arguments['coverageXml']) && $codeCoverageConfiguration->hasXml()) { + $arguments['coverageXml'] = $codeCoverageConfiguration->xml()->target()->path(); + } } - if (isset($phpunitConfiguration['backupStaticAttributes']) && !isset($arguments['backupStaticAttributes'])) { - $arguments['backupStaticAttributes'] = $phpunitConfiguration['backupStaticAttributes']; + $phpunitConfiguration = $arguments['configurationObject']->phpunit(); + + $arguments['backupGlobals'] = $arguments['backupGlobals'] ?? $phpunitConfiguration->backupGlobals(); + $arguments['backupStaticAttributes'] = $arguments['backupStaticAttributes'] ?? $phpunitConfiguration->backupStaticAttributes(); + $arguments['beStrictAboutChangesToGlobalState'] = $arguments['beStrictAboutChangesToGlobalState'] ?? $phpunitConfiguration->beStrictAboutChangesToGlobalState(); + $arguments['cacheResult'] = $arguments['cacheResult'] ?? $phpunitConfiguration->cacheResult(); + $arguments['colors'] = $arguments['colors'] ?? $phpunitConfiguration->colors(); + $arguments['convertDeprecationsToExceptions'] = $arguments['convertDeprecationsToExceptions'] ?? $phpunitConfiguration->convertDeprecationsToExceptions(); + $arguments['convertErrorsToExceptions'] = $arguments['convertErrorsToExceptions'] ?? $phpunitConfiguration->convertErrorsToExceptions(); + $arguments['convertNoticesToExceptions'] = $arguments['convertNoticesToExceptions'] ?? $phpunitConfiguration->convertNoticesToExceptions(); + $arguments['convertWarningsToExceptions'] = $arguments['convertWarningsToExceptions'] ?? $phpunitConfiguration->convertWarningsToExceptions(); + $arguments['processIsolation'] = $arguments['processIsolation'] ?? $phpunitConfiguration->processIsolation(); + $arguments['stopOnDefect'] = $arguments['stopOnDefect'] ?? $phpunitConfiguration->stopOnDefect(); + $arguments['stopOnError'] = $arguments['stopOnError'] ?? $phpunitConfiguration->stopOnError(); + $arguments['stopOnFailure'] = $arguments['stopOnFailure'] ?? $phpunitConfiguration->stopOnFailure(); + $arguments['stopOnWarning'] = $arguments['stopOnWarning'] ?? $phpunitConfiguration->stopOnWarning(); + $arguments['stopOnIncomplete'] = $arguments['stopOnIncomplete'] ?? $phpunitConfiguration->stopOnIncomplete(); + $arguments['stopOnRisky'] = $arguments['stopOnRisky'] ?? $phpunitConfiguration->stopOnRisky(); + $arguments['stopOnSkipped'] = $arguments['stopOnSkipped'] ?? $phpunitConfiguration->stopOnSkipped(); + $arguments['failOnEmptyTestSuite'] = $arguments['failOnEmptyTestSuite'] ?? $phpunitConfiguration->failOnEmptyTestSuite(); + $arguments['failOnIncomplete'] = $arguments['failOnIncomplete'] ?? $phpunitConfiguration->failOnIncomplete(); + $arguments['failOnRisky'] = $arguments['failOnRisky'] ?? $phpunitConfiguration->failOnRisky(); + $arguments['failOnSkipped'] = $arguments['failOnSkipped'] ?? $phpunitConfiguration->failOnSkipped(); + $arguments['failOnWarning'] = $arguments['failOnWarning'] ?? $phpunitConfiguration->failOnWarning(); + $arguments['enforceTimeLimit'] = $arguments['enforceTimeLimit'] ?? $phpunitConfiguration->enforceTimeLimit(); + $arguments['defaultTimeLimit'] = $arguments['defaultTimeLimit'] ?? $phpunitConfiguration->defaultTimeLimit(); + $arguments['timeoutForSmallTests'] = $arguments['timeoutForSmallTests'] ?? $phpunitConfiguration->timeoutForSmallTests(); + $arguments['timeoutForMediumTests'] = $arguments['timeoutForMediumTests'] ?? $phpunitConfiguration->timeoutForMediumTests(); + $arguments['timeoutForLargeTests'] = $arguments['timeoutForLargeTests'] ?? $phpunitConfiguration->timeoutForLargeTests(); + $arguments['reportUselessTests'] = $arguments['reportUselessTests'] ?? $phpunitConfiguration->beStrictAboutTestsThatDoNotTestAnything(); + $arguments['strictCoverage'] = $arguments['strictCoverage'] ?? $phpunitConfiguration->beStrictAboutCoversAnnotation(); + $arguments['ignoreDeprecatedCodeUnitsFromCodeCoverage'] = $arguments['ignoreDeprecatedCodeUnitsFromCodeCoverage'] ?? $codeCoverageConfiguration->ignoreDeprecatedCodeUnits(); + $arguments['disallowTestOutput'] = $arguments['disallowTestOutput'] ?? $phpunitConfiguration->beStrictAboutOutputDuringTests(); + $arguments['disallowTodoAnnotatedTests'] = $arguments['disallowTodoAnnotatedTests'] ?? $phpunitConfiguration->beStrictAboutTodoAnnotatedTests(); + $arguments['beStrictAboutResourceUsageDuringSmallTests'] = $arguments['beStrictAboutResourceUsageDuringSmallTests'] ?? $phpunitConfiguration->beStrictAboutResourceUsageDuringSmallTests(); + $arguments['verbose'] = $arguments['verbose'] ?? $phpunitConfiguration->verbose(); + $arguments['reverseDefectList'] = $arguments['reverseDefectList'] ?? $phpunitConfiguration->reverseDefectList(); + $arguments['forceCoversAnnotation'] = $arguments['forceCoversAnnotation'] ?? $phpunitConfiguration->forceCoversAnnotation(); + $arguments['disableCodeCoverageIgnore'] = $arguments['disableCodeCoverageIgnore'] ?? $codeCoverageConfiguration->disableCodeCoverageIgnore(); + $arguments['registerMockObjectsFromTestArgumentsRecursively'] = $arguments['registerMockObjectsFromTestArgumentsRecursively'] ?? $phpunitConfiguration->registerMockObjectsFromTestArgumentsRecursively(); + $arguments['noInteraction'] = $arguments['noInteraction'] ?? $phpunitConfiguration->noInteraction(); + $arguments['executionOrder'] = $arguments['executionOrder'] ?? $phpunitConfiguration->executionOrder(); + $arguments['resolveDependencies'] = $arguments['resolveDependencies'] ?? $phpunitConfiguration->resolveDependencies(); + + if (!isset($arguments['bootstrap']) && $phpunitConfiguration->hasBootstrap()) { + $arguments['bootstrap'] = $phpunitConfiguration->bootstrap(); } - if (isset($phpunitConfiguration['beStrictAboutChangesToGlobalState']) && !isset($arguments['beStrictAboutChangesToGlobalState'])) { - $arguments['beStrictAboutChangesToGlobalState'] = $phpunitConfiguration['beStrictAboutChangesToGlobalState']; + if (!isset($arguments['cacheResultFile']) && $phpunitConfiguration->hasCacheResultFile()) { + $arguments['cacheResultFile'] = $phpunitConfiguration->cacheResultFile(); } - if (isset($phpunitConfiguration['bootstrap']) && !isset($arguments['bootstrap'])) { - $arguments['bootstrap'] = $phpunitConfiguration['bootstrap']; + if (!isset($arguments['executionOrderDefects'])) { + $arguments['executionOrderDefects'] = $phpunitConfiguration->defectsFirst() ? TestSuiteSorter::ORDER_DEFECTS_FIRST : TestSuiteSorter::ORDER_DEFAULT; } - if (isset($phpunitConfiguration['cacheResult']) && !isset($arguments['cacheResult'])) { - $arguments['cacheResult'] = $phpunitConfiguration['cacheResult']; - } - - if (isset($phpunitConfiguration['cacheResultFile']) && !isset($arguments['cacheResultFile'])) { - $arguments['cacheResultFile'] = $phpunitConfiguration['cacheResultFile']; - } - - if (isset($phpunitConfiguration['cacheTokens']) && !isset($arguments['cacheTokens'])) { - $arguments['cacheTokens'] = $phpunitConfiguration['cacheTokens']; - } - - if (isset($phpunitConfiguration['cacheTokens']) && !isset($arguments['cacheTokens'])) { - $arguments['cacheTokens'] = $phpunitConfiguration['cacheTokens']; - } - - if (isset($phpunitConfiguration['colors']) && !isset($arguments['colors'])) { - $arguments['colors'] = $phpunitConfiguration['colors']; - } - - if (isset($phpunitConfiguration['convertDeprecationsToExceptions']) && !isset($arguments['convertDeprecationsToExceptions'])) { - $arguments['convertDeprecationsToExceptions'] = $phpunitConfiguration['convertDeprecationsToExceptions']; - } - - if (isset($phpunitConfiguration['convertErrorsToExceptions']) && !isset($arguments['convertErrorsToExceptions'])) { - $arguments['convertErrorsToExceptions'] = $phpunitConfiguration['convertErrorsToExceptions']; - } - - if (isset($phpunitConfiguration['convertNoticesToExceptions']) && !isset($arguments['convertNoticesToExceptions'])) { - $arguments['convertNoticesToExceptions'] = $phpunitConfiguration['convertNoticesToExceptions']; - } - - if (isset($phpunitConfiguration['convertWarningsToExceptions']) && !isset($arguments['convertWarningsToExceptions'])) { - $arguments['convertWarningsToExceptions'] = $phpunitConfiguration['convertWarningsToExceptions']; - } - - if (isset($phpunitConfiguration['processIsolation']) && !isset($arguments['processIsolation'])) { - $arguments['processIsolation'] = $phpunitConfiguration['processIsolation']; - } - - if (isset($phpunitConfiguration['stopOnDefect']) && !isset($arguments['stopOnDefect'])) { - $arguments['stopOnDefect'] = $phpunitConfiguration['stopOnDefect']; - } - - if (isset($phpunitConfiguration['stopOnError']) && !isset($arguments['stopOnError'])) { - $arguments['stopOnError'] = $phpunitConfiguration['stopOnError']; - } - - if (isset($phpunitConfiguration['stopOnFailure']) && !isset($arguments['stopOnFailure'])) { - $arguments['stopOnFailure'] = $phpunitConfiguration['stopOnFailure']; - } - - if (isset($phpunitConfiguration['stopOnWarning']) && !isset($arguments['stopOnWarning'])) { - $arguments['stopOnWarning'] = $phpunitConfiguration['stopOnWarning']; - } - - if (isset($phpunitConfiguration['stopOnIncomplete']) && !isset($arguments['stopOnIncomplete'])) { - $arguments['stopOnIncomplete'] = $phpunitConfiguration['stopOnIncomplete']; - } - - if (isset($phpunitConfiguration['stopOnRisky']) && !isset($arguments['stopOnRisky'])) { - $arguments['stopOnRisky'] = $phpunitConfiguration['stopOnRisky']; - } - - if (isset($phpunitConfiguration['stopOnSkipped']) && !isset($arguments['stopOnSkipped'])) { - $arguments['stopOnSkipped'] = $phpunitConfiguration['stopOnSkipped']; - } - - if (isset($phpunitConfiguration['failOnWarning']) && !isset($arguments['failOnWarning'])) { - $arguments['failOnWarning'] = $phpunitConfiguration['failOnWarning']; - } - - if (isset($phpunitConfiguration['failOnRisky']) && !isset($arguments['failOnRisky'])) { - $arguments['failOnRisky'] = $phpunitConfiguration['failOnRisky']; - } - - if (isset($phpunitConfiguration['timeoutForSmallTests']) && !isset($arguments['timeoutForSmallTests'])) { - $arguments['timeoutForSmallTests'] = $phpunitConfiguration['timeoutForSmallTests']; - } - - if (isset($phpunitConfiguration['timeoutForMediumTests']) && !isset($arguments['timeoutForMediumTests'])) { - $arguments['timeoutForMediumTests'] = $phpunitConfiguration['timeoutForMediumTests']; - } - - if (isset($phpunitConfiguration['timeoutForLargeTests']) && !isset($arguments['timeoutForLargeTests'])) { - $arguments['timeoutForLargeTests'] = $phpunitConfiguration['timeoutForLargeTests']; - } - - if (isset($phpunitConfiguration['reportUselessTests']) && !isset($arguments['reportUselessTests'])) { - $arguments['reportUselessTests'] = $phpunitConfiguration['reportUselessTests']; - } - - if (isset($phpunitConfiguration['strictCoverage']) && !isset($arguments['strictCoverage'])) { - $arguments['strictCoverage'] = $phpunitConfiguration['strictCoverage']; - } - - if (isset($phpunitConfiguration['ignoreDeprecatedCodeUnitsFromCodeCoverage']) && !isset($arguments['ignoreDeprecatedCodeUnitsFromCodeCoverage'])) { - $arguments['ignoreDeprecatedCodeUnitsFromCodeCoverage'] = $phpunitConfiguration['ignoreDeprecatedCodeUnitsFromCodeCoverage']; - } - - if (isset($phpunitConfiguration['disallowTestOutput']) && !isset($arguments['disallowTestOutput'])) { - $arguments['disallowTestOutput'] = $phpunitConfiguration['disallowTestOutput']; - } - - if (isset($phpunitConfiguration['defaultTimeLimit']) && !isset($arguments['defaultTimeLimit'])) { - $arguments['defaultTimeLimit'] = $phpunitConfiguration['defaultTimeLimit']; - } - - if (isset($phpunitConfiguration['enforceTimeLimit']) && !isset($arguments['enforceTimeLimit'])) { - $arguments['enforceTimeLimit'] = $phpunitConfiguration['enforceTimeLimit']; - } - - if (isset($phpunitConfiguration['disallowTodoAnnotatedTests']) && !isset($arguments['disallowTodoAnnotatedTests'])) { - $arguments['disallowTodoAnnotatedTests'] = $phpunitConfiguration['disallowTodoAnnotatedTests']; - } - - if (isset($phpunitConfiguration['beStrictAboutResourceUsageDuringSmallTests']) && !isset($arguments['beStrictAboutResourceUsageDuringSmallTests'])) { - $arguments['beStrictAboutResourceUsageDuringSmallTests'] = $phpunitConfiguration['beStrictAboutResourceUsageDuringSmallTests']; - } - - if (isset($phpunitConfiguration['verbose']) && !isset($arguments['verbose'])) { - $arguments['verbose'] = $phpunitConfiguration['verbose']; - } - - if (isset($phpunitConfiguration['reverseDefectList']) && !isset($arguments['reverseList'])) { - $arguments['reverseList'] = $phpunitConfiguration['reverseDefectList']; - } - - if (isset($phpunitConfiguration['forceCoversAnnotation']) && !isset($arguments['forceCoversAnnotation'])) { - $arguments['forceCoversAnnotation'] = $phpunitConfiguration['forceCoversAnnotation']; - } - - if (isset($phpunitConfiguration['disableCodeCoverageIgnore']) && !isset($arguments['disableCodeCoverageIgnore'])) { - $arguments['disableCodeCoverageIgnore'] = $phpunitConfiguration['disableCodeCoverageIgnore']; - } - - if (isset($phpunitConfiguration['registerMockObjectsFromTestArgumentsRecursively']) && !isset($arguments['registerMockObjectsFromTestArgumentsRecursively'])) { - $arguments['registerMockObjectsFromTestArgumentsRecursively'] = $phpunitConfiguration['registerMockObjectsFromTestArgumentsRecursively']; - } - - if (isset($phpunitConfiguration['executionOrder']) && !isset($arguments['executionOrder'])) { - $arguments['executionOrder'] = $phpunitConfiguration['executionOrder']; - } - - if (isset($phpunitConfiguration['executionOrderDefects']) && !isset($arguments['executionOrderDefects'])) { - $arguments['executionOrderDefects'] = $phpunitConfiguration['executionOrderDefects']; - } - - if (isset($phpunitConfiguration['resolveDependencies']) && !isset($arguments['resolveDependencies'])) { - $arguments['resolveDependencies'] = $phpunitConfiguration['resolveDependencies']; - } - - if (isset($phpunitConfiguration['noInteraction']) && !isset($arguments['noInteraction'])) { - $arguments['noInteraction'] = $phpunitConfiguration['noInteraction']; - } - - if (isset($phpunitConfiguration['conflictBetweenPrinterClassAndTestdox'])) { + if ($phpunitConfiguration->conflictBetweenPrinterClassAndTestdox()) { $arguments['conflictBetweenPrinterClassAndTestdox'] = true; } @@ -1052,198 +1008,91 @@ final class TestRunner extends BaseTestRunner $groupCliArgs = $arguments['groups']; } - $groupConfiguration = $arguments['configuration']->getGroupConfiguration(); + $groupConfiguration = $arguments['configurationObject']->groups(); - if (!empty($groupConfiguration['include']) && !isset($arguments['groups'])) { - $arguments['groups'] = $groupConfiguration['include']; + if (!isset($arguments['groups']) && $groupConfiguration->hasInclude()) { + $arguments['groups'] = $groupConfiguration->include()->asArrayOfStrings(); } - if (!empty($groupConfiguration['exclude']) && !isset($arguments['excludeGroups'])) { - $arguments['excludeGroups'] = array_diff($groupConfiguration['exclude'], $groupCliArgs); + if (!isset($arguments['excludeGroups']) && $groupConfiguration->hasExclude()) { + $arguments['excludeGroups'] = array_diff($groupConfiguration->exclude()->asArrayOfStrings(), $groupCliArgs); } - foreach ($arguments['configuration']->getExtensionConfiguration() as $extension) { - if ($extension['file'] !== '' && !class_exists($extension['class'], false)) { - require_once $extension['file']; - } + $extensionHandler = new ExtensionHandler; - if (!class_exists($extension['class'])) { - throw new Exception( - sprintf( - 'Class "%s" does not exist', - $extension['class'] - ) - ); - } - - try { - $extensionClass = new ReflectionClass($extension['class']); - // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new Exception( - $e->getMessage(), - (int) $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - - if (!$extensionClass->implementsInterface(Hook::class)) { - throw new Exception( - sprintf( - 'Class "%s" does not implement a PHPUnit\Runner\Hook interface', - $extension['class'] - ) - ); - } - - if (count($extension['arguments']) === 0) { - $extensionObject = $extensionClass->newInstance(); - } else { - $extensionObject = $extensionClass->newInstanceArgs( - $extension['arguments'] - ); - } - - assert($extensionObject instanceof Hook); - - $this->addExtension($extensionObject); + foreach ($arguments['configurationObject']->extensions() as $extension) { + $extensionHandler->registerExtension($extension, $this); } - foreach ($arguments['configuration']->getListenerConfiguration() as $listener) { - if ($listener['file'] !== '' && !class_exists($listener['class'], false)) { - require_once $listener['file']; - } - - if (!class_exists($listener['class'])) { - throw new Exception( - sprintf( - 'Class "%s" does not exist', - $listener['class'] - ) - ); - } - - try { - $listenerClass = new ReflectionClass($listener['class']); - // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new Exception( - $e->getMessage(), - (int) $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - - if (!$listenerClass->implementsInterface(TestListener::class)) { - throw new Exception( - sprintf( - 'Class "%s" does not implement the PHPUnit\Framework\TestListener interface', - $listener['class'] - ) - ); - } - - if (count($listener['arguments']) === 0) { - $listener = new $listener['class']; - } else { - $listener = $listenerClass->newInstanceArgs( - $listener['arguments'] - ); - } - - $arguments['listeners'][] = $listener; + foreach ($arguments['configurationObject']->listeners() as $listener) { + $arguments['listeners'][] = $extensionHandler->createTestListenerInstance($listener); } - $loggingConfiguration = $arguments['configuration']->getLoggingConfiguration(); + unset($extensionHandler); - if (isset($loggingConfiguration['coverage-clover']) && !isset($arguments['coverageClover'])) { - $arguments['coverageClover'] = $loggingConfiguration['coverage-clover']; - } - - if (isset($loggingConfiguration['coverage-crap4j']) && !isset($arguments['coverageCrap4J'])) { - $arguments['coverageCrap4J'] = $loggingConfiguration['coverage-crap4j']; - - if (isset($loggingConfiguration['crap4jThreshold']) && !isset($arguments['crap4jThreshold'])) { - $arguments['crap4jThreshold'] = $loggingConfiguration['crap4jThreshold']; - } - } - - if (isset($loggingConfiguration['coverage-html']) && !isset($arguments['coverageHtml'])) { - if (isset($loggingConfiguration['lowUpperBound']) && !isset($arguments['reportLowUpperBound'])) { - $arguments['reportLowUpperBound'] = $loggingConfiguration['lowUpperBound']; - } - - if (isset($loggingConfiguration['highLowerBound']) && !isset($arguments['reportHighLowerBound'])) { - $arguments['reportHighLowerBound'] = $loggingConfiguration['highLowerBound']; - } - - $arguments['coverageHtml'] = $loggingConfiguration['coverage-html']; - } - - if (isset($loggingConfiguration['coverage-php']) && !isset($arguments['coveragePHP'])) { - $arguments['coveragePHP'] = $loggingConfiguration['coverage-php']; - } - - if (isset($loggingConfiguration['coverage-text']) && !isset($arguments['coverageText'])) { - $arguments['coverageText'] = $loggingConfiguration['coverage-text']; - $arguments['coverageTextShowUncoveredFiles'] = $loggingConfiguration['coverageTextShowUncoveredFiles'] ?? false; - $arguments['coverageTextShowOnlySummary'] = $loggingConfiguration['coverageTextShowOnlySummary'] ?? false; - } - - if (isset($loggingConfiguration['coverage-xml']) && !isset($arguments['coverageXml'])) { - $arguments['coverageXml'] = $loggingConfiguration['coverage-xml']; - } - - if (isset($loggingConfiguration['plain'])) { - $arguments['listeners'][] = new ResultPrinter( - $loggingConfiguration['plain'], - true + foreach ($arguments['unavailableExtensions'] as $extension) { + $arguments['warnings'][] = sprintf( + 'Extension "%s" is not available', + $extension ); } - if (isset($loggingConfiguration['teamcity']) && !isset($arguments['teamcityLogfile'])) { - $arguments['teamcityLogfile'] = $loggingConfiguration['teamcity']; + $loggingConfiguration = $arguments['configurationObject']->logging(); + + if (!isset($arguments['noLogging'])) { + if ($loggingConfiguration->hasText()) { + $arguments['listeners'][] = new DefaultResultPrinter( + $loggingConfiguration->text()->target()->path(), + true + ); + } + + if (!isset($arguments['teamcityLogfile']) && $loggingConfiguration->hasTeamCity()) { + $arguments['teamcityLogfile'] = $loggingConfiguration->teamCity()->target()->path(); + } + + if (!isset($arguments['junitLogfile']) && $loggingConfiguration->hasJunit()) { + $arguments['junitLogfile'] = $loggingConfiguration->junit()->target()->path(); + } + + if (!isset($arguments['testdoxHTMLFile']) && $loggingConfiguration->hasTestDoxHtml()) { + $arguments['testdoxHTMLFile'] = $loggingConfiguration->testDoxHtml()->target()->path(); + } + + if (!isset($arguments['testdoxTextFile']) && $loggingConfiguration->hasTestDoxText()) { + $arguments['testdoxTextFile'] = $loggingConfiguration->testDoxText()->target()->path(); + } + + if (!isset($arguments['testdoxXMLFile']) && $loggingConfiguration->hasTestDoxXml()) { + $arguments['testdoxXMLFile'] = $loggingConfiguration->testDoxXml()->target()->path(); + } } - if (isset($loggingConfiguration['junit']) && !isset($arguments['junitLogfile'])) { - $arguments['junitLogfile'] = $loggingConfiguration['junit']; + $testdoxGroupConfiguration = $arguments['configurationObject']->testdoxGroups(); + + if (!isset($arguments['testdoxGroups']) && $testdoxGroupConfiguration->hasInclude()) { + $arguments['testdoxGroups'] = $testdoxGroupConfiguration->include()->asArrayOfStrings(); } - if (isset($loggingConfiguration['testdox-html']) && !isset($arguments['testdoxHTMLFile'])) { - $arguments['testdoxHTMLFile'] = $loggingConfiguration['testdox-html']; - } - - if (isset($loggingConfiguration['testdox-text']) && !isset($arguments['testdoxTextFile'])) { - $arguments['testdoxTextFile'] = $loggingConfiguration['testdox-text']; - } - - if (isset($loggingConfiguration['testdox-xml']) && !isset($arguments['testdoxXMLFile'])) { - $arguments['testdoxXMLFile'] = $loggingConfiguration['testdox-xml']; - } - - $testdoxGroupConfiguration = $arguments['configuration']->getTestdoxGroupConfiguration(); - - if (isset($testdoxGroupConfiguration['include']) && - !isset($arguments['testdoxGroups'])) { - $arguments['testdoxGroups'] = $testdoxGroupConfiguration['include']; - } - - if (isset($testdoxGroupConfiguration['exclude']) && - !isset($arguments['testdoxExcludeGroups'])) { - $arguments['testdoxExcludeGroups'] = $testdoxGroupConfiguration['exclude']; + if (!isset($arguments['testdoxExcludeGroups']) && $testdoxGroupConfiguration->hasExclude()) { + $arguments['testdoxExcludeGroups'] = $testdoxGroupConfiguration->exclude()->asArrayOfStrings(); } } - $arguments['addUncoveredFilesFromWhitelist'] = $arguments['addUncoveredFilesFromWhitelist'] ?? true; + $extensionHandler = new ExtensionHandler; + + foreach ($arguments['extensions'] as $extension) { + $extensionHandler->registerExtension($extension, $this); + } + + unset($extensionHandler); + $arguments['backupGlobals'] = $arguments['backupGlobals'] ?? null; $arguments['backupStaticAttributes'] = $arguments['backupStaticAttributes'] ?? null; $arguments['beStrictAboutChangesToGlobalState'] = $arguments['beStrictAboutChangesToGlobalState'] ?? null; $arguments['beStrictAboutResourceUsageDuringSmallTests'] = $arguments['beStrictAboutResourceUsageDuringSmallTests'] ?? false; $arguments['cacheResult'] = $arguments['cacheResult'] ?? true; - $arguments['cacheTokens'] = $arguments['cacheTokens'] ?? false; - $arguments['colors'] = $arguments['colors'] ?? ResultPrinter::COLOR_DEFAULT; + $arguments['colors'] = $arguments['colors'] ?? DefaultResultPrinter::COLOR_DEFAULT; $arguments['columns'] = $arguments['columns'] ?? 80; $arguments['convertDeprecationsToExceptions'] = $arguments['convertDeprecationsToExceptions'] ?? true; $arguments['convertErrorsToExceptions'] = $arguments['convertErrorsToExceptions'] ?? true; @@ -1257,12 +1106,13 @@ final class TestRunner extends BaseTestRunner $arguments['excludeGroups'] = $arguments['excludeGroups'] ?? []; $arguments['executionOrder'] = $arguments['executionOrder'] ?? TestSuiteSorter::ORDER_DEFAULT; $arguments['executionOrderDefects'] = $arguments['executionOrderDefects'] ?? TestSuiteSorter::ORDER_DEFAULT; + $arguments['failOnIncomplete'] = $arguments['failOnIncomplete'] ?? false; $arguments['failOnRisky'] = $arguments['failOnRisky'] ?? false; + $arguments['failOnSkipped'] = $arguments['failOnSkipped'] ?? false; $arguments['failOnWarning'] = $arguments['failOnWarning'] ?? false; $arguments['groups'] = $arguments['groups'] ?? []; $arguments['noInteraction'] = $arguments['noInteraction'] ?? false; $arguments['processIsolation'] = $arguments['processIsolation'] ?? false; - $arguments['processUncoveredFilesFromWhitelist'] = $arguments['processUncoveredFilesFromWhitelist'] ?? false; $arguments['randomOrderSeed'] = $arguments['randomOrderSeed'] ?? time(); $arguments['registerMockObjectsFromTestArgumentsRecursively'] = $arguments['registerMockObjectsFromTestArgumentsRecursively'] ?? false; $arguments['repeat'] = $arguments['repeat'] ?? false; @@ -1291,7 +1141,9 @@ final class TestRunner extends BaseTestRunner { if (!$arguments['filter'] && empty($arguments['groups']) && - empty($arguments['excludeGroups'])) { + empty($arguments['excludeGroups']) && + empty($arguments['testsCovering']) && + empty($arguments['testsUsing'])) { return; } @@ -1311,6 +1163,30 @@ final class TestRunner extends BaseTestRunner ); } + if (!empty($arguments['testsCovering'])) { + $filterFactory->addFilter( + new ReflectionClass(IncludeGroupFilterIterator::class), + array_map( + static function (string $name): string { + return '__phpunit_covers_' . $name; + }, + $arguments['testsCovering'] + ) + ); + } + + if (!empty($arguments['testsUsing'])) { + $filterFactory->addFilter( + new ReflectionClass(IncludeGroupFilterIterator::class), + array_map( + static function (string $name): string { + return '__phpunit_uses_' . $name; + }, + $arguments['testsUsing'] + ) + ); + } + if ($arguments['filter']) { $filterFactory->addFilter( new ReflectionClass(NameFilterIterator::class), @@ -1338,16 +1214,9 @@ final class TestRunner extends BaseTestRunner $this->messagePrinted = true; } - /** - * @template T as Printer - * - * @param class-string $class - * - * @return T - */ - private function createPrinter(string $class, array $arguments): Printer + private function createPrinter(string $class, array $arguments): ResultPrinter { - return new $class( + $object = new $class( (isset($arguments['stderr']) && $arguments['stderr'] === true) ? 'php://stderr' : null, $arguments['verbose'], $arguments['colors'], @@ -1355,6 +1224,10 @@ final class TestRunner extends BaseTestRunner $arguments['columns'], $arguments['reverseList'] ); + + assert($object instanceof ResultPrinter); + + return $object; } private function codeCoverageGenerationStart(string $format): void @@ -1366,7 +1239,7 @@ final class TestRunner extends BaseTestRunner ) ); - Timer::start(); + $this->timer->start(); } private function codeCoverageGenerationSucceeded(): void @@ -1374,7 +1247,7 @@ final class TestRunner extends BaseTestRunner $this->printer->write( sprintf( "done [%s]\n", - Timer::secondsToTimeString(Timer::stop()) + $this->timer->stop()->asString() ) ); } @@ -1384,7 +1257,7 @@ final class TestRunner extends BaseTestRunner $this->printer->write( sprintf( "failed [%s]\n%s\n", - Timer::secondsToTimeString(Timer::stop()), + $this->timer->stop()->asString(), $e->getMessage() ) ); diff --git a/vendor/phpunit/phpunit/src/TextUI/TestSuiteMapper.php b/vendor/phpunit/phpunit/src/TextUI/TestSuiteMapper.php new file mode 100644 index 000000000..8a703aeea --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/TestSuiteMapper.php @@ -0,0 +1,103 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI; + +use const PHP_VERSION; +use function explode; +use function in_array; +use function is_dir; +use function is_file; +use function strpos; +use function version_compare; +use PHPUnit\Framework\Exception as FrameworkException; +use PHPUnit\Framework\TestSuite as TestSuiteObject; +use PHPUnit\TextUI\XmlConfiguration\TestSuiteCollection; +use SebastianBergmann\FileIterator\Facade; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class TestSuiteMapper +{ + /** + * @throws RuntimeException + * @throws TestDirectoryNotFoundException + * @throws TestFileNotFoundException + */ + public function map(TestSuiteCollection $configuration, string $filter): TestSuiteObject + { + try { + $filterAsArray = $filter ? explode(',', $filter) : []; + $result = new TestSuiteObject; + + foreach ($configuration as $testSuiteConfiguration) { + if (!empty($filterAsArray) && !in_array($testSuiteConfiguration->name(), $filterAsArray, true)) { + continue; + } + + $testSuite = new TestSuiteObject($testSuiteConfiguration->name()); + $testSuiteEmpty = true; + + foreach ($testSuiteConfiguration->directories() as $directory) { + if (!version_compare(PHP_VERSION, $directory->phpVersion(), $directory->phpVersionOperator()->asString())) { + continue; + } + + $exclude = []; + + foreach ($testSuiteConfiguration->exclude()->asArray() as $file) { + $exclude[] = $file->path(); + } + + $files = (new Facade)->getFilesAsArray( + $directory->path(), + $directory->suffix(), + $directory->prefix(), + $exclude + ); + + if (!empty($files)) { + $testSuite->addTestFiles($files); + + $testSuiteEmpty = false; + } elseif (strpos($directory->path(), '*') === false && !is_dir($directory->path())) { + throw new TestDirectoryNotFoundException($directory->path()); + } + } + + foreach ($testSuiteConfiguration->files() as $file) { + if (!is_file($file->path())) { + throw new TestFileNotFoundException($file->path()); + } + + if (!version_compare(PHP_VERSION, $file->phpVersion(), $file->phpVersionOperator()->asString())) { + continue; + } + + $testSuite->addTestFile($file->path()); + + $testSuiteEmpty = false; + } + + if (!$testSuiteEmpty) { + $result->addTest($testSuite); + } + } + + return $result; + } catch (FrameworkException $e) { + throw new RuntimeException( + $e->getMessage(), + (int) $e->getCode(), + $e + ); + } + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/CodeCoverage.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/CodeCoverage.php new file mode 100644 index 000000000..33cbea321 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/CodeCoverage.php @@ -0,0 +1,362 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration\CodeCoverage; + +use function count; +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Filter\DirectoryCollection; +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Report\Clover; +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Report\Cobertura; +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Report\Crap4j; +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Report\Html; +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Report\Php; +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Report\Text; +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Report\Xml; +use PHPUnit\TextUI\XmlConfiguration\Directory; +use PHPUnit\TextUI\XmlConfiguration\Exception; +use PHPUnit\TextUI\XmlConfiguration\FileCollection; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class CodeCoverage +{ + /** + * @var ?Directory + */ + private $cacheDirectory; + + /** + * @var DirectoryCollection + */ + private $directories; + + /** + * @var FileCollection + */ + private $files; + + /** + * @var DirectoryCollection + */ + private $excludeDirectories; + + /** + * @var FileCollection + */ + private $excludeFiles; + + /** + * @var bool + */ + private $pathCoverage; + + /** + * @var bool + */ + private $includeUncoveredFiles; + + /** + * @var bool + */ + private $processUncoveredFiles; + + /** + * @var bool + */ + private $ignoreDeprecatedCodeUnits; + + /** + * @var bool + */ + private $disableCodeCoverageIgnore; + + /** + * @var ?Clover + */ + private $clover; + + /** + * @var ?Cobertura + */ + private $cobertura; + + /** + * @var ?Crap4j + */ + private $crap4j; + + /** + * @var ?Html + */ + private $html; + + /** + * @var ?Php + */ + private $php; + + /** + * @var ?Text + */ + private $text; + + /** + * @var ?Xml + */ + private $xml; + + public function __construct(?Directory $cacheDirectory, DirectoryCollection $directories, FileCollection $files, DirectoryCollection $excludeDirectories, FileCollection $excludeFiles, bool $pathCoverage, bool $includeUncoveredFiles, bool $processUncoveredFiles, bool $ignoreDeprecatedCodeUnits, bool $disableCodeCoverageIgnore, ?Clover $clover, ?Cobertura $cobertura, ?Crap4j $crap4j, ?Html $html, ?Php $php, ?Text $text, ?Xml $xml) + { + $this->cacheDirectory = $cacheDirectory; + $this->directories = $directories; + $this->files = $files; + $this->excludeDirectories = $excludeDirectories; + $this->excludeFiles = $excludeFiles; + $this->pathCoverage = $pathCoverage; + $this->includeUncoveredFiles = $includeUncoveredFiles; + $this->processUncoveredFiles = $processUncoveredFiles; + $this->ignoreDeprecatedCodeUnits = $ignoreDeprecatedCodeUnits; + $this->disableCodeCoverageIgnore = $disableCodeCoverageIgnore; + $this->clover = $clover; + $this->cobertura = $cobertura; + $this->crap4j = $crap4j; + $this->html = $html; + $this->php = $php; + $this->text = $text; + $this->xml = $xml; + } + + /** + * @psalm-assert-if-true !null $this->cacheDirectory + */ + public function hasCacheDirectory(): bool + { + return $this->cacheDirectory !== null; + } + + /** + * @throws Exception + */ + public function cacheDirectory(): Directory + { + if (!$this->hasCacheDirectory()) { + throw new Exception( + 'No cache directory has been configured' + ); + } + + return $this->cacheDirectory; + } + + public function hasNonEmptyListOfFilesToBeIncludedInCodeCoverageReport(): bool + { + return count($this->directories) > 0 || count($this->files) > 0; + } + + public function directories(): DirectoryCollection + { + return $this->directories; + } + + public function files(): FileCollection + { + return $this->files; + } + + public function excludeDirectories(): DirectoryCollection + { + return $this->excludeDirectories; + } + + public function excludeFiles(): FileCollection + { + return $this->excludeFiles; + } + + public function pathCoverage(): bool + { + return $this->pathCoverage; + } + + public function includeUncoveredFiles(): bool + { + return $this->includeUncoveredFiles; + } + + public function ignoreDeprecatedCodeUnits(): bool + { + return $this->ignoreDeprecatedCodeUnits; + } + + public function disableCodeCoverageIgnore(): bool + { + return $this->disableCodeCoverageIgnore; + } + + public function processUncoveredFiles(): bool + { + return $this->processUncoveredFiles; + } + + /** + * @psalm-assert-if-true !null $this->clover + */ + public function hasClover(): bool + { + return $this->clover !== null; + } + + /** + * @throws Exception + */ + public function clover(): Clover + { + if (!$this->hasClover()) { + throw new Exception( + 'Code Coverage report "Clover XML" has not been configured' + ); + } + + return $this->clover; + } + + /** + * @psalm-assert-if-true !null $this->cobertura + */ + public function hasCobertura(): bool + { + return $this->cobertura !== null; + } + + /** + * @throws Exception + */ + public function cobertura(): Cobertura + { + if (!$this->hasCobertura()) { + throw new Exception( + 'Code Coverage report "Cobertura XML" has not been configured' + ); + } + + return $this->cobertura; + } + + /** + * @psalm-assert-if-true !null $this->crap4j + */ + public function hasCrap4j(): bool + { + return $this->crap4j !== null; + } + + /** + * @throws Exception + */ + public function crap4j(): Crap4j + { + if (!$this->hasCrap4j()) { + throw new Exception( + 'Code Coverage report "Crap4J" has not been configured' + ); + } + + return $this->crap4j; + } + + /** + * @psalm-assert-if-true !null $this->html + */ + public function hasHtml(): bool + { + return $this->html !== null; + } + + /** + * @throws Exception + */ + public function html(): Html + { + if (!$this->hasHtml()) { + throw new Exception( + 'Code Coverage report "HTML" has not been configured' + ); + } + + return $this->html; + } + + /** + * @psalm-assert-if-true !null $this->php + */ + public function hasPhp(): bool + { + return $this->php !== null; + } + + /** + * @throws Exception + */ + public function php(): Php + { + if (!$this->hasPhp()) { + throw new Exception( + 'Code Coverage report "PHP" has not been configured' + ); + } + + return $this->php; + } + + /** + * @psalm-assert-if-true !null $this->text + */ + public function hasText(): bool + { + return $this->text !== null; + } + + /** + * @throws Exception + */ + public function text(): Text + { + if (!$this->hasText()) { + throw new Exception( + 'Code Coverage report "Text" has not been configured' + ); + } + + return $this->text; + } + + /** + * @psalm-assert-if-true !null $this->xml + */ + public function hasXml(): bool + { + return $this->xml !== null; + } + + /** + * @throws Exception + */ + public function xml(): Xml + { + if (!$this->hasXml()) { + throw new Exception( + 'Code Coverage report "XML" has not been configured' + ); + } + + return $this->xml; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Filter/Directory.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Filter/Directory.php new file mode 100644 index 000000000..3bf99c39d --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Filter/Directory.php @@ -0,0 +1,65 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Filter; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Directory +{ + /** + * @var string + */ + private $path; + + /** + * @var string + */ + private $prefix; + + /** + * @var string + */ + private $suffix; + + /** + * @var string + */ + private $group; + + public function __construct(string $path, string $prefix, string $suffix, string $group) + { + $this->path = $path; + $this->prefix = $prefix; + $this->suffix = $suffix; + $this->group = $group; + } + + public function path(): string + { + return $this->path; + } + + public function prefix(): string + { + return $this->prefix; + } + + public function suffix(): string + { + return $this->suffix; + } + + public function group(): string + { + return $this->group; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Filter/DirectoryCollection.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Filter/DirectoryCollection.php new file mode 100644 index 000000000..803ccda20 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Filter/DirectoryCollection.php @@ -0,0 +1,57 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Filter; + +use function count; +use Countable; +use IteratorAggregate; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class DirectoryCollection implements Countable, IteratorAggregate +{ + /** + * @var Directory[] + */ + private $directories; + + /** + * @param Directory[] $directories + */ + public static function fromArray(array $directories): self + { + return new self(...$directories); + } + + private function __construct(Directory ...$directories) + { + $this->directories = $directories; + } + + /** + * @return Directory[] + */ + public function asArray(): array + { + return $this->directories; + } + + public function count(): int + { + return count($this->directories); + } + + public function getIterator(): DirectoryCollectionIterator + { + return new DirectoryCollectionIterator($this); + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Filter/DirectoryCollectionIterator.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Filter/DirectoryCollectionIterator.php new file mode 100644 index 000000000..c59a3ba99 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Filter/DirectoryCollectionIterator.php @@ -0,0 +1,66 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Filter; + +use function count; +use function iterator_count; +use Countable; +use Iterator; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class DirectoryCollectionIterator implements Countable, Iterator +{ + /** + * @var Directory[] + */ + private $directories; + + /** + * @var int + */ + private $position; + + public function __construct(DirectoryCollection $directories) + { + $this->directories = $directories->asArray(); + } + + public function count(): int + { + return iterator_count($this); + } + + public function rewind(): void + { + $this->position = 0; + } + + public function valid(): bool + { + return $this->position < count($this->directories); + } + + public function key(): int + { + return $this->position; + } + + public function current(): Directory + { + return $this->directories[$this->position]; + } + + public function next(): void + { + $this->position++; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/FilterMapper.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/FilterMapper.php new file mode 100644 index 000000000..102c96ebc --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/FilterMapper.php @@ -0,0 +1,45 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration\CodeCoverage; + +use SebastianBergmann\CodeCoverage\Filter; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class FilterMapper +{ + public function map(Filter $filter, CodeCoverage $configuration): void + { + foreach ($configuration->directories() as $directory) { + $filter->includeDirectory( + $directory->path(), + $directory->suffix(), + $directory->prefix() + ); + } + + foreach ($configuration->files() as $file) { + $filter->includeFile($file->path()); + } + + foreach ($configuration->excludeDirectories() as $directory) { + $filter->excludeDirectory( + $directory->path(), + $directory->suffix(), + $directory->prefix() + ); + } + + foreach ($configuration->excludeFiles() as $file) { + $filter->excludeFile($file->path()); + } + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Clover.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Clover.php new file mode 100644 index 000000000..e7ff407be --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Clover.php @@ -0,0 +1,34 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Report; + +use PHPUnit\TextUI\XmlConfiguration\File; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Clover +{ + /** + * @var File + */ + private $target; + + public function __construct(File $target) + { + $this->target = $target; + } + + public function target(): File + { + return $this->target; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Cobertura.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Cobertura.php new file mode 100644 index 000000000..e6ee7c9f6 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Cobertura.php @@ -0,0 +1,34 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Report; + +use PHPUnit\TextUI\XmlConfiguration\File; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Cobertura +{ + /** + * @var File + */ + private $target; + + public function __construct(File $target) + { + $this->target = $target; + } + + public function target(): File + { + return $this->target; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Crap4j.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Crap4j.php new file mode 100644 index 000000000..fd4d42912 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Crap4j.php @@ -0,0 +1,45 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Report; + +use PHPUnit\TextUI\XmlConfiguration\File; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Crap4j +{ + /** + * @var File + */ + private $target; + + /** + * @var int + */ + private $threshold; + + public function __construct(File $target, int $threshold) + { + $this->target = $target; + $this->threshold = $threshold; + } + + public function target(): File + { + return $this->target; + } + + public function threshold(): int + { + return $this->threshold; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Html.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Html.php new file mode 100644 index 000000000..7084ffe5e --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Html.php @@ -0,0 +1,56 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Report; + +use PHPUnit\TextUI\XmlConfiguration\Directory; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Html +{ + /** + * @var Directory + */ + private $target; + + /** + * @var int + */ + private $lowUpperBound; + + /** + * @var int + */ + private $highLowerBound; + + public function __construct(Directory $target, int $lowUpperBound, int $highLowerBound) + { + $this->target = $target; + $this->lowUpperBound = $lowUpperBound; + $this->highLowerBound = $highLowerBound; + } + + public function target(): Directory + { + return $this->target; + } + + public function lowUpperBound(): int + { + return $this->lowUpperBound; + } + + public function highLowerBound(): int + { + return $this->highLowerBound; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Php.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Php.php new file mode 100644 index 000000000..d86b66216 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Php.php @@ -0,0 +1,34 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Report; + +use PHPUnit\TextUI\XmlConfiguration\File; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Php +{ + /** + * @var File + */ + private $target; + + public function __construct(File $target) + { + $this->target = $target; + } + + public function target(): File + { + return $this->target; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Text.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Text.php new file mode 100644 index 000000000..b7e9f3da3 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Text.php @@ -0,0 +1,56 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Report; + +use PHPUnit\TextUI\XmlConfiguration\File; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Text +{ + /** + * @var File + */ + private $target; + + /** + * @var bool + */ + private $showUncoveredFiles; + + /** + * @var bool + */ + private $showOnlySummary; + + public function __construct(File $target, bool $showUncoveredFiles, bool $showOnlySummary) + { + $this->target = $target; + $this->showUncoveredFiles = $showUncoveredFiles; + $this->showOnlySummary = $showOnlySummary; + } + + public function target(): File + { + return $this->target; + } + + public function showUncoveredFiles(): bool + { + return $this->showUncoveredFiles; + } + + public function showOnlySummary(): bool + { + return $this->showOnlySummary; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Xml.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Xml.php new file mode 100644 index 000000000..977685c46 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/CodeCoverage/Report/Xml.php @@ -0,0 +1,34 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Report; + +use PHPUnit\TextUI\XmlConfiguration\Directory; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Xml +{ + /** + * @var Directory + */ + private $target; + + public function __construct(Directory $target) + { + $this->target = $target; + } + + public function target(): Directory + { + return $this->target; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Configuration.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Configuration.php new file mode 100644 index 000000000..8f102e3ba --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Configuration.php @@ -0,0 +1,151 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\CodeCoverage; +use PHPUnit\TextUI\XmlConfiguration\Logging\Logging; +use PHPUnit\Util\Xml\ValidationResult; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Configuration +{ + /** + * @var string + */ + private $filename; + + /** + * @var ValidationResult + */ + private $validationResult; + + /** + * @var ExtensionCollection + */ + private $extensions; + + /** + * @var CodeCoverage + */ + private $codeCoverage; + + /** + * @var Groups + */ + private $groups; + + /** + * @var Groups + */ + private $testdoxGroups; + + /** + * @var ExtensionCollection + */ + private $listeners; + + /** + * @var Logging + */ + private $logging; + + /** + * @var Php + */ + private $php; + + /** + * @var PHPUnit + */ + private $phpunit; + + /** + * @var TestSuiteCollection + */ + private $testSuite; + + public function __construct(string $filename, ValidationResult $validationResult, ExtensionCollection $extensions, CodeCoverage $codeCoverage, Groups $groups, Groups $testdoxGroups, ExtensionCollection $listeners, Logging $logging, Php $php, PHPUnit $phpunit, TestSuiteCollection $testSuite) + { + $this->filename = $filename; + $this->validationResult = $validationResult; + $this->extensions = $extensions; + $this->codeCoverage = $codeCoverage; + $this->groups = $groups; + $this->testdoxGroups = $testdoxGroups; + $this->listeners = $listeners; + $this->logging = $logging; + $this->php = $php; + $this->phpunit = $phpunit; + $this->testSuite = $testSuite; + } + + public function filename(): string + { + return $this->filename; + } + + public function hasValidationErrors(): bool + { + return $this->validationResult->hasValidationErrors(); + } + + public function validationErrors(): string + { + return $this->validationResult->asString(); + } + + public function extensions(): ExtensionCollection + { + return $this->extensions; + } + + public function codeCoverage(): CodeCoverage + { + return $this->codeCoverage; + } + + public function groups(): Groups + { + return $this->groups; + } + + public function testdoxGroups(): Groups + { + return $this->testdoxGroups; + } + + public function listeners(): ExtensionCollection + { + return $this->listeners; + } + + public function logging(): Logging + { + return $this->logging; + } + + public function php(): Php + { + return $this->php; + } + + public function phpunit(): PHPUnit + { + return $this->phpunit; + } + + public function testSuite(): TestSuiteCollection + { + return $this->testSuite; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Exception.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Exception.php new file mode 100644 index 000000000..162b37e88 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Exception.php @@ -0,0 +1,19 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use RuntimeException; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class Exception extends RuntimeException implements \PHPUnit\Exception +{ +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/Directory.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/Directory.php new file mode 100644 index 000000000..1629603b7 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/Directory.php @@ -0,0 +1,32 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Directory +{ + /** + * @var string + */ + private $path; + + public function __construct(string $path) + { + $this->path = $path; + } + + public function path(): string + { + return $this->path; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/DirectoryCollection.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/DirectoryCollection.php new file mode 100644 index 000000000..c8ae59641 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/DirectoryCollection.php @@ -0,0 +1,62 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function count; +use Countable; +use IteratorAggregate; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class DirectoryCollection implements Countable, IteratorAggregate +{ + /** + * @var Directory[] + */ + private $directories; + + /** + * @param Directory[] $directories + */ + public static function fromArray(array $directories): self + { + return new self(...$directories); + } + + private function __construct(Directory ...$directories) + { + $this->directories = $directories; + } + + /** + * @return Directory[] + */ + public function asArray(): array + { + return $this->directories; + } + + public function count(): int + { + return count($this->directories); + } + + public function getIterator(): DirectoryCollectionIterator + { + return new DirectoryCollectionIterator($this); + } + + public function isEmpty(): bool + { + return $this->count() === 0; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/DirectoryCollectionIterator.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/DirectoryCollectionIterator.php new file mode 100644 index 000000000..7f354eea5 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/DirectoryCollectionIterator.php @@ -0,0 +1,66 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function count; +use function iterator_count; +use Countable; +use Iterator; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class DirectoryCollectionIterator implements Countable, Iterator +{ + /** + * @var Directory[] + */ + private $directories; + + /** + * @var int + */ + private $position; + + public function __construct(DirectoryCollection $directories) + { + $this->directories = $directories->asArray(); + } + + public function count(): int + { + return iterator_count($this); + } + + public function rewind(): void + { + $this->position = 0; + } + + public function valid(): bool + { + return $this->position < count($this->directories); + } + + public function key(): int + { + return $this->position; + } + + public function current(): Directory + { + return $this->directories[$this->position]; + } + + public function next(): void + { + $this->position++; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/File.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/File.php new file mode 100644 index 000000000..0af5000d1 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/File.php @@ -0,0 +1,32 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class File +{ + /** + * @var string + */ + private $path; + + public function __construct(string $path) + { + $this->path = $path; + } + + public function path(): string + { + return $this->path; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/FileCollection.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/FileCollection.php new file mode 100644 index 000000000..bfc1e33e4 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/FileCollection.php @@ -0,0 +1,62 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function count; +use Countable; +use IteratorAggregate; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class FileCollection implements Countable, IteratorAggregate +{ + /** + * @var File[] + */ + private $files; + + /** + * @param File[] $files + */ + public static function fromArray(array $files): self + { + return new self(...$files); + } + + private function __construct(File ...$files) + { + $this->files = $files; + } + + /** + * @return File[] + */ + public function asArray(): array + { + return $this->files; + } + + public function count(): int + { + return count($this->files); + } + + public function getIterator(): FileCollectionIterator + { + return new FileCollectionIterator($this); + } + + public function isEmpty(): bool + { + return $this->count() === 0; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/FileCollectionIterator.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/FileCollectionIterator.php new file mode 100644 index 000000000..d9bab1f8b --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Filesystem/FileCollectionIterator.php @@ -0,0 +1,66 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function count; +use function iterator_count; +use Countable; +use Iterator; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class FileCollectionIterator implements Countable, Iterator +{ + /** + * @var File[] + */ + private $files; + + /** + * @var int + */ + private $position; + + public function __construct(FileCollection $files) + { + $this->files = $files->asArray(); + } + + public function count(): int + { + return iterator_count($this); + } + + public function rewind(): void + { + $this->position = 0; + } + + public function valid(): bool + { + return $this->position < count($this->files); + } + + public function key(): int + { + return $this->position; + } + + public function current(): File + { + return $this->files[$this->position]; + } + + public function next(): void + { + $this->position++; + } +} diff --git a/vendor/phpunit/phpunit/src/Util/ConfigurationGenerator.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Generator.php similarity index 79% rename from vendor/phpunit/phpunit/src/Util/ConfigurationGenerator.php rename to vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Generator.php index fcf9891bd..478a51bf7 100644 --- a/vendor/phpunit/phpunit/src/Util/ConfigurationGenerator.php +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Generator.php @@ -7,14 +7,14 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ -namespace PHPUnit\Util; +namespace PHPUnit\TextUI\XmlConfiguration; use function str_replace; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ -final class ConfigurationGenerator +final class Generator { /** * @var string @@ -24,11 +24,14 @@ final class ConfigurationGenerator @@ -36,16 +39,17 @@ final class ConfigurationGenerator - - + + {src_directory} - - + + EOT; - public function generateDefaultConfiguration(string $phpunitVersion, string $bootstrapScript, string $testsDirectory, string $srcDirectory): string + public function generateDefaultConfiguration(string $phpunitVersion, string $bootstrapScript, string $testsDirectory, string $srcDirectory, string $cacheDirectory): string { return str_replace( [ @@ -53,12 +57,14 @@ EOT; '{bootstrap_script}', '{tests_directory}', '{src_directory}', + '{cache_directory}', ], [ $phpunitVersion, $bootstrapScript, $testsDirectory, $srcDirectory, + $cacheDirectory, ], self::TEMPLATE ); diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/Group.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/Group.php new file mode 100644 index 000000000..e59844053 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/Group.php @@ -0,0 +1,32 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Group +{ + /** + * @var string + */ + private $name; + + public function __construct(string $name) + { + $this->name = $name; + } + + public function name(): string + { + return $this->name; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/GroupCollection.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/GroupCollection.php new file mode 100644 index 000000000..2ad9fef68 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/GroupCollection.php @@ -0,0 +1,69 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use IteratorAggregate; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class GroupCollection implements IteratorAggregate +{ + /** + * @var Group[] + */ + private $groups; + + /** + * @param Group[] $groups + */ + public static function fromArray(array $groups): self + { + return new self(...$groups); + } + + private function __construct(Group ...$groups) + { + $this->groups = $groups; + } + + /** + * @return Group[] + */ + public function asArray(): array + { + return $this->groups; + } + + /** + * @return string[] + */ + public function asArrayOfStrings(): array + { + $result = []; + + foreach ($this->groups as $group) { + $result[] = $group->name(); + } + + return $result; + } + + public function isEmpty(): bool + { + return empty($this->groups); + } + + public function getIterator(): GroupCollectionIterator + { + return new GroupCollectionIterator($this); + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/GroupCollectionIterator.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/GroupCollectionIterator.php new file mode 100644 index 000000000..0755fdac4 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/GroupCollectionIterator.php @@ -0,0 +1,66 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function count; +use function iterator_count; +use Countable; +use Iterator; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class GroupCollectionIterator implements Countable, Iterator +{ + /** + * @var Group[] + */ + private $groups; + + /** + * @var int + */ + private $position; + + public function __construct(GroupCollection $groups) + { + $this->groups = $groups->asArray(); + } + + public function count(): int + { + return iterator_count($this); + } + + public function rewind(): void + { + $this->position = 0; + } + + public function valid(): bool + { + return $this->position < count($this->groups); + } + + public function key(): int + { + return $this->position; + } + + public function current(): Group + { + return $this->groups[$this->position]; + } + + public function next(): void + { + $this->position++; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/Groups.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/Groups.php new file mode 100644 index 000000000..9004fe43b --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Group/Groups.php @@ -0,0 +1,53 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Groups +{ + /** + * @var GroupCollection + */ + private $include; + + /** + * @var GroupCollection + */ + private $exclude; + + public function __construct(GroupCollection $include, GroupCollection $exclude) + { + $this->include = $include; + $this->exclude = $exclude; + } + + public function hasInclude(): bool + { + return !$this->include->isEmpty(); + } + + public function include(): GroupCollection + { + return $this->include; + } + + public function hasExclude(): bool + { + return !$this->exclude->isEmpty(); + } + + public function exclude(): GroupCollection + { + return $this->exclude; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Loader.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Loader.php new file mode 100644 index 000000000..63e20bd85 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Loader.php @@ -0,0 +1,1264 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use const DIRECTORY_SEPARATOR; +use const PHP_VERSION; +use function assert; +use function defined; +use function dirname; +use function explode; +use function is_file; +use function is_numeric; +use function preg_match; +use function stream_resolve_include_path; +use function strlen; +use function strpos; +use function strtolower; +use function substr; +use function trim; +use DOMDocument; +use DOMElement; +use DOMNodeList; +use DOMXPath; +use PHPUnit\Runner\TestSuiteSorter; +use PHPUnit\Runner\Version; +use PHPUnit\TextUI\DefaultResultPrinter; +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\CodeCoverage; +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Filter\Directory as FilterDirectory; +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Filter\DirectoryCollection as FilterDirectoryCollection; +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Report\Clover; +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Report\Cobertura; +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Report\Crap4j; +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Report\Html as CodeCoverageHtml; +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Report\Php as CodeCoveragePhp; +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Report\Text as CodeCoverageText; +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\Report\Xml as CodeCoverageXml; +use PHPUnit\TextUI\XmlConfiguration\Logging\Junit; +use PHPUnit\TextUI\XmlConfiguration\Logging\Logging; +use PHPUnit\TextUI\XmlConfiguration\Logging\TeamCity; +use PHPUnit\TextUI\XmlConfiguration\Logging\TestDox\Html as TestDoxHtml; +use PHPUnit\TextUI\XmlConfiguration\Logging\TestDox\Text as TestDoxText; +use PHPUnit\TextUI\XmlConfiguration\Logging\TestDox\Xml as TestDoxXml; +use PHPUnit\TextUI\XmlConfiguration\Logging\Text; +use PHPUnit\TextUI\XmlConfiguration\TestSuite as TestSuiteConfiguration; +use PHPUnit\Util\TestDox\CliTestDoxPrinter; +use PHPUnit\Util\VersionComparisonOperator; +use PHPUnit\Util\Xml; +use PHPUnit\Util\Xml\Exception as XmlException; +use PHPUnit\Util\Xml\Loader as XmlLoader; +use PHPUnit\Util\Xml\SchemaFinder; +use PHPUnit\Util\Xml\Validator; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class Loader +{ + /** + * @throws Exception + */ + public function load(string $filename): Configuration + { + try { + $document = (new XmlLoader)->loadFile($filename, false, true, true); + } catch (XmlException $e) { + throw new Exception( + $e->getMessage(), + (int) $e->getCode(), + $e + ); + } + + $xpath = new DOMXPath($document); + + try { + $xsdFilename = (new SchemaFinder)->find(Version::series()); + } catch (XmlException $e) { + throw new Exception( + $e->getMessage(), + (int) $e->getCode(), + $e + ); + } + + return new Configuration( + $filename, + (new Validator)->validate($document, $xsdFilename), + $this->extensions($filename, $xpath), + $this->codeCoverage($filename, $xpath, $document), + $this->groups($xpath), + $this->testdoxGroups($xpath), + $this->listeners($filename, $xpath), + $this->logging($filename, $xpath), + $this->php($filename, $xpath), + $this->phpunit($filename, $document), + $this->testSuite($filename, $xpath) + ); + } + + public function logging(string $filename, DOMXPath $xpath): Logging + { + if ($xpath->query('logging/log')->length !== 0) { + return $this->legacyLogging($filename, $xpath); + } + + $junit = null; + $element = $this->element($xpath, 'logging/junit'); + + if ($element) { + $junit = new Junit( + new File( + $this->toAbsolutePath( + $filename, + (string) $this->getStringAttribute($element, 'outputFile') + ) + ) + ); + } + + $text = null; + $element = $this->element($xpath, 'logging/text'); + + if ($element) { + $text = new Text( + new File( + $this->toAbsolutePath( + $filename, + (string) $this->getStringAttribute($element, 'outputFile') + ) + ) + ); + } + + $teamCity = null; + $element = $this->element($xpath, 'logging/teamcity'); + + if ($element) { + $teamCity = new TeamCity( + new File( + $this->toAbsolutePath( + $filename, + (string) $this->getStringAttribute($element, 'outputFile') + ) + ) + ); + } + + $testDoxHtml = null; + $element = $this->element($xpath, 'logging/testdoxHtml'); + + if ($element) { + $testDoxHtml = new TestDoxHtml( + new File( + $this->toAbsolutePath( + $filename, + (string) $this->getStringAttribute($element, 'outputFile') + ) + ) + ); + } + + $testDoxText = null; + $element = $this->element($xpath, 'logging/testdoxText'); + + if ($element) { + $testDoxText = new TestDoxText( + new File( + $this->toAbsolutePath( + $filename, + (string) $this->getStringAttribute($element, 'outputFile') + ) + ) + ); + } + + $testDoxXml = null; + $element = $this->element($xpath, 'logging/testdoxXml'); + + if ($element) { + $testDoxXml = new TestDoxXml( + new File( + $this->toAbsolutePath( + $filename, + (string) $this->getStringAttribute($element, 'outputFile') + ) + ) + ); + } + + return new Logging( + $junit, + $text, + $teamCity, + $testDoxHtml, + $testDoxText, + $testDoxXml + ); + } + + public function legacyLogging(string $filename, DOMXPath $xpath): Logging + { + $junit = null; + $teamCity = null; + $testDoxHtml = null; + $testDoxText = null; + $testDoxXml = null; + $text = null; + + foreach ($xpath->query('logging/log') as $log) { + assert($log instanceof DOMElement); + + $type = (string) $log->getAttribute('type'); + $target = (string) $log->getAttribute('target'); + + if (!$target) { + continue; + } + + $target = $this->toAbsolutePath($filename, $target); + + switch ($type) { + case 'plain': + $text = new Text( + new File($target) + ); + + break; + + case 'junit': + $junit = new Junit( + new File($target) + ); + + break; + + case 'teamcity': + $teamCity = new TeamCity( + new File($target) + ); + + break; + + case 'testdox-html': + $testDoxHtml = new TestDoxHtml( + new File($target) + ); + + break; + + case 'testdox-text': + $testDoxText = new TestDoxText( + new File($target) + ); + + break; + + case 'testdox-xml': + $testDoxXml = new TestDoxXml( + new File($target) + ); + + break; + } + } + + return new Logging( + $junit, + $text, + $teamCity, + $testDoxHtml, + $testDoxText, + $testDoxXml + ); + } + + private function extensions(string $filename, DOMXPath $xpath): ExtensionCollection + { + $extensions = []; + + foreach ($xpath->query('extensions/extension') as $extension) { + assert($extension instanceof DOMElement); + + $extensions[] = $this->getElementConfigurationParameters($filename, $extension); + } + + return ExtensionCollection::fromArray($extensions); + } + + private function getElementConfigurationParameters(string $filename, DOMElement $element): Extension + { + /** @psalm-var class-string $class */ + $class = (string) $element->getAttribute('class'); + $file = ''; + $arguments = $this->getConfigurationArguments($filename, $element->childNodes); + + if ($element->getAttribute('file')) { + $file = $this->toAbsolutePath( + $filename, + (string) $element->getAttribute('file'), + true + ); + } + + return new Extension($class, $file, $arguments); + } + + private function toAbsolutePath(string $filename, string $path, bool $useIncludePath = false): string + { + $path = trim($path); + + if (strpos($path, '/') === 0) { + return $path; + } + + // Matches the following on Windows: + // - \\NetworkComputer\Path + // - \\.\D: + // - \\.\c: + // - C:\Windows + // - C:\windows + // - C:/windows + // - c:/windows + if (defined('PHP_WINDOWS_VERSION_BUILD') && + ($path[0] === '\\' || (strlen($path) >= 3 && preg_match('#^[A-Z]\:[/\\\]#i', substr($path, 0, 3))))) { + return $path; + } + + if (strpos($path, '://') !== false) { + return $path; + } + + $file = dirname($filename) . DIRECTORY_SEPARATOR . $path; + + if ($useIncludePath && !is_file($file)) { + $includePathFile = stream_resolve_include_path($path); + + if ($includePathFile) { + $file = $includePathFile; + } + } + + return $file; + } + + private function getConfigurationArguments(string $filename, DOMNodeList $nodes): array + { + $arguments = []; + + if ($nodes->length === 0) { + return $arguments; + } + + foreach ($nodes as $node) { + if (!$node instanceof DOMElement) { + continue; + } + + if ($node->tagName !== 'arguments') { + continue; + } + + foreach ($node->childNodes as $argument) { + if (!$argument instanceof DOMElement) { + continue; + } + + if ($argument->tagName === 'file' || $argument->tagName === 'directory') { + $arguments[] = $this->toAbsolutePath($filename, (string) $argument->textContent); + } else { + $arguments[] = Xml::xmlToVariable($argument); + } + } + } + + return $arguments; + } + + private function codeCoverage(string $filename, DOMXPath $xpath, DOMDocument $document): CodeCoverage + { + if ($xpath->query('filter/whitelist')->length !== 0) { + return $this->legacyCodeCoverage($filename, $xpath, $document); + } + + $cacheDirectory = null; + $pathCoverage = false; + $includeUncoveredFiles = true; + $processUncoveredFiles = false; + $ignoreDeprecatedCodeUnits = false; + $disableCodeCoverageIgnore = false; + + $element = $this->element($xpath, 'coverage'); + + if ($element) { + $cacheDirectory = $this->getStringAttribute($element, 'cacheDirectory'); + + if ($cacheDirectory !== null) { + $cacheDirectory = new Directory( + $this->toAbsolutePath($filename, $cacheDirectory) + ); + } + + $pathCoverage = $this->getBooleanAttribute( + $element, + 'pathCoverage', + false + ); + + $includeUncoveredFiles = $this->getBooleanAttribute( + $element, + 'includeUncoveredFiles', + true + ); + + $processUncoveredFiles = $this->getBooleanAttribute( + $element, + 'processUncoveredFiles', + false + ); + + $ignoreDeprecatedCodeUnits = $this->getBooleanAttribute( + $element, + 'ignoreDeprecatedCodeUnits', + false + ); + + $disableCodeCoverageIgnore = $this->getBooleanAttribute( + $element, + 'disableCodeCoverageIgnore', + false + ); + } + + $clover = null; + $element = $this->element($xpath, 'coverage/report/clover'); + + if ($element) { + $clover = new Clover( + new File( + $this->toAbsolutePath( + $filename, + (string) $this->getStringAttribute($element, 'outputFile') + ) + ) + ); + } + + $cobertura = null; + $element = $this->element($xpath, 'coverage/report/cobertura'); + + if ($element) { + $cobertura = new Cobertura( + new File( + $this->toAbsolutePath( + $filename, + (string) $this->getStringAttribute($element, 'outputFile') + ) + ) + ); + } + + $crap4j = null; + $element = $this->element($xpath, 'coverage/report/crap4j'); + + if ($element) { + $crap4j = new Crap4j( + new File( + $this->toAbsolutePath( + $filename, + (string) $this->getStringAttribute($element, 'outputFile') + ) + ), + $this->getIntegerAttribute($element, 'threshold', 30) + ); + } + + $html = null; + $element = $this->element($xpath, 'coverage/report/html'); + + if ($element) { + $html = new CodeCoverageHtml( + new Directory( + $this->toAbsolutePath( + $filename, + (string) $this->getStringAttribute($element, 'outputDirectory') + ) + ), + $this->getIntegerAttribute($element, 'lowUpperBound', 50), + $this->getIntegerAttribute($element, 'highLowerBound', 90) + ); + } + + $php = null; + $element = $this->element($xpath, 'coverage/report/php'); + + if ($element) { + $php = new CodeCoveragePhp( + new File( + $this->toAbsolutePath( + $filename, + (string) $this->getStringAttribute($element, 'outputFile') + ) + ) + ); + } + + $text = null; + $element = $this->element($xpath, 'coverage/report/text'); + + if ($element) { + $text = new CodeCoverageText( + new File( + $this->toAbsolutePath( + $filename, + (string) $this->getStringAttribute($element, 'outputFile') + ) + ), + $this->getBooleanAttribute($element, 'showUncoveredFiles', false), + $this->getBooleanAttribute($element, 'showOnlySummary', false) + ); + } + + $xml = null; + $element = $this->element($xpath, 'coverage/report/xml'); + + if ($element) { + $xml = new CodeCoverageXml( + new Directory( + $this->toAbsolutePath( + $filename, + (string) $this->getStringAttribute($element, 'outputDirectory') + ) + ) + ); + } + + return new CodeCoverage( + $cacheDirectory, + $this->readFilterDirectories($filename, $xpath, 'coverage/include/directory'), + $this->readFilterFiles($filename, $xpath, 'coverage/include/file'), + $this->readFilterDirectories($filename, $xpath, 'coverage/exclude/directory'), + $this->readFilterFiles($filename, $xpath, 'coverage/exclude/file'), + $pathCoverage, + $includeUncoveredFiles, + $processUncoveredFiles, + $ignoreDeprecatedCodeUnits, + $disableCodeCoverageIgnore, + $clover, + $cobertura, + $crap4j, + $html, + $php, + $text, + $xml + ); + } + + /** + * @deprecated + */ + private function legacyCodeCoverage(string $filename, DOMXPath $xpath, DOMDocument $document): CodeCoverage + { + $ignoreDeprecatedCodeUnits = $this->getBooleanAttribute( + $document->documentElement, + 'ignoreDeprecatedCodeUnitsFromCodeCoverage', + false + ); + + $disableCodeCoverageIgnore = $this->getBooleanAttribute( + $document->documentElement, + 'disableCodeCoverageIgnore', + false + ); + + $includeUncoveredFiles = true; + $processUncoveredFiles = false; + + $element = $this->element($xpath, 'filter/whitelist'); + + if ($element) { + if ($element->hasAttribute('addUncoveredFilesFromWhitelist')) { + $includeUncoveredFiles = (bool) $this->getBoolean( + (string) $element->getAttribute('addUncoveredFilesFromWhitelist'), + true + ); + } + + if ($element->hasAttribute('processUncoveredFilesFromWhitelist')) { + $processUncoveredFiles = (bool) $this->getBoolean( + (string) $element->getAttribute('processUncoveredFilesFromWhitelist'), + false + ); + } + } + + $clover = null; + $cobertura = null; + $crap4j = null; + $html = null; + $php = null; + $text = null; + $xml = null; + + foreach ($xpath->query('logging/log') as $log) { + assert($log instanceof DOMElement); + + $type = (string) $log->getAttribute('type'); + $target = (string) $log->getAttribute('target'); + + if (!$target) { + continue; + } + + $target = $this->toAbsolutePath($filename, $target); + + switch ($type) { + case 'coverage-clover': + $clover = new Clover( + new File($target) + ); + + break; + + case 'coverage-cobertura': + $cobertura = new Cobertura( + new File($target) + ); + + break; + + case 'coverage-crap4j': + $crap4j = new Crap4j( + new File($target), + $this->getIntegerAttribute($log, 'threshold', 30) + ); + + break; + + case 'coverage-html': + $html = new CodeCoverageHtml( + new Directory($target), + $this->getIntegerAttribute($log, 'lowUpperBound', 50), + $this->getIntegerAttribute($log, 'highLowerBound', 90) + ); + + break; + + case 'coverage-php': + $php = new CodeCoveragePhp( + new File($target) + ); + + break; + + case 'coverage-text': + $text = new CodeCoverageText( + new File($target), + $this->getBooleanAttribute($log, 'showUncoveredFiles', false), + $this->getBooleanAttribute($log, 'showOnlySummary', false) + ); + + break; + + case 'coverage-xml': + $xml = new CodeCoverageXml( + new Directory($target) + ); + + break; + } + } + + return new CodeCoverage( + null, + $this->readFilterDirectories($filename, $xpath, 'filter/whitelist/directory'), + $this->readFilterFiles($filename, $xpath, 'filter/whitelist/file'), + $this->readFilterDirectories($filename, $xpath, 'filter/whitelist/exclude/directory'), + $this->readFilterFiles($filename, $xpath, 'filter/whitelist/exclude/file'), + false, + $includeUncoveredFiles, + $processUncoveredFiles, + $ignoreDeprecatedCodeUnits, + $disableCodeCoverageIgnore, + $clover, + $cobertura, + $crap4j, + $html, + $php, + $text, + $xml + ); + } + + /** + * If $value is 'false' or 'true', this returns the value that $value represents. + * Otherwise, returns $default, which may be a string in rare cases. + * + * @see \PHPUnit\TextUI\XmlConfigurationTest::testPHPConfigurationIsReadCorrectly + * + * @param bool|string $default + * + * @return bool|string + */ + private function getBoolean(string $value, $default) + { + if (strtolower($value) === 'false') { + return false; + } + + if (strtolower($value) === 'true') { + return true; + } + + return $default; + } + + private function readFilterDirectories(string $filename, DOMXPath $xpath, string $query): FilterDirectoryCollection + { + $directories = []; + + foreach ($xpath->query($query) as $directoryNode) { + assert($directoryNode instanceof DOMElement); + + $directoryPath = (string) $directoryNode->textContent; + + if (!$directoryPath) { + continue; + } + + $directories[] = new FilterDirectory( + $this->toAbsolutePath($filename, $directoryPath), + $directoryNode->hasAttribute('prefix') ? (string) $directoryNode->getAttribute('prefix') : '', + $directoryNode->hasAttribute('suffix') ? (string) $directoryNode->getAttribute('suffix') : '.php', + $directoryNode->hasAttribute('group') ? (string) $directoryNode->getAttribute('group') : 'DEFAULT' + ); + } + + return FilterDirectoryCollection::fromArray($directories); + } + + private function readFilterFiles(string $filename, DOMXPath $xpath, string $query): FileCollection + { + $files = []; + + foreach ($xpath->query($query) as $file) { + $filePath = (string) $file->textContent; + + if ($filePath) { + $files[] = new File($this->toAbsolutePath($filename, $filePath)); + } + } + + return FileCollection::fromArray($files); + } + + private function groups(DOMXPath $xpath): Groups + { + return $this->parseGroupConfiguration($xpath, 'groups'); + } + + private function testdoxGroups(DOMXPath $xpath): Groups + { + return $this->parseGroupConfiguration($xpath, 'testdoxGroups'); + } + + private function parseGroupConfiguration(DOMXPath $xpath, string $root): Groups + { + $include = []; + $exclude = []; + + foreach ($xpath->query($root . '/include/group') as $group) { + $include[] = new Group((string) $group->textContent); + } + + foreach ($xpath->query($root . '/exclude/group') as $group) { + $exclude[] = new Group((string) $group->textContent); + } + + return new Groups( + GroupCollection::fromArray($include), + GroupCollection::fromArray($exclude) + ); + } + + private function listeners(string $filename, DOMXPath $xpath): ExtensionCollection + { + $listeners = []; + + foreach ($xpath->query('listeners/listener') as $listener) { + assert($listener instanceof DOMElement); + + $listeners[] = $this->getElementConfigurationParameters($filename, $listener); + } + + return ExtensionCollection::fromArray($listeners); + } + + private function getBooleanAttribute(DOMElement $element, string $attribute, bool $default): bool + { + if (!$element->hasAttribute($attribute)) { + return $default; + } + + return (bool) $this->getBoolean( + (string) $element->getAttribute($attribute), + false + ); + } + + private function getIntegerAttribute(DOMElement $element, string $attribute, int $default): int + { + if (!$element->hasAttribute($attribute)) { + return $default; + } + + return $this->getInteger( + (string) $element->getAttribute($attribute), + $default + ); + } + + private function getStringAttribute(DOMElement $element, string $attribute): ?string + { + if (!$element->hasAttribute($attribute)) { + return null; + } + + return (string) $element->getAttribute($attribute); + } + + private function getInteger(string $value, int $default): int + { + if (is_numeric($value)) { + return (int) $value; + } + + return $default; + } + + private function php(string $filename, DOMXPath $xpath): Php + { + $includePaths = []; + + foreach ($xpath->query('php/includePath') as $includePath) { + $path = (string) $includePath->textContent; + + if ($path) { + $includePaths[] = new Directory($this->toAbsolutePath($filename, $path)); + } + } + + $iniSettings = []; + + foreach ($xpath->query('php/ini') as $ini) { + assert($ini instanceof DOMElement); + + $iniSettings[] = new IniSetting( + (string) $ini->getAttribute('name'), + (string) $ini->getAttribute('value') + ); + } + + $constants = []; + + foreach ($xpath->query('php/const') as $const) { + assert($const instanceof DOMElement); + + $value = (string) $const->getAttribute('value'); + + $constants[] = new Constant( + (string) $const->getAttribute('name'), + $this->getBoolean($value, $value) + ); + } + + $variables = [ + 'var' => [], + 'env' => [], + 'post' => [], + 'get' => [], + 'cookie' => [], + 'server' => [], + 'files' => [], + 'request' => [], + ]; + + foreach (['var', 'env', 'post', 'get', 'cookie', 'server', 'files', 'request'] as $array) { + foreach ($xpath->query('php/' . $array) as $var) { + assert($var instanceof DOMElement); + + $name = (string) $var->getAttribute('name'); + $value = (string) $var->getAttribute('value'); + $force = false; + $verbatim = false; + + if ($var->hasAttribute('force')) { + $force = (bool) $this->getBoolean($var->getAttribute('force'), false); + } + + if ($var->hasAttribute('verbatim')) { + $verbatim = $this->getBoolean($var->getAttribute('verbatim'), false); + } + + if (!$verbatim) { + $value = $this->getBoolean($value, $value); + } + + $variables[$array][] = new Variable($name, $value, $force); + } + } + + return new Php( + DirectoryCollection::fromArray($includePaths), + IniSettingCollection::fromArray($iniSettings), + ConstantCollection::fromArray($constants), + VariableCollection::fromArray($variables['var']), + VariableCollection::fromArray($variables['env']), + VariableCollection::fromArray($variables['post']), + VariableCollection::fromArray($variables['get']), + VariableCollection::fromArray($variables['cookie']), + VariableCollection::fromArray($variables['server']), + VariableCollection::fromArray($variables['files']), + VariableCollection::fromArray($variables['request']), + ); + } + + private function phpunit(string $filename, DOMDocument $document): PHPUnit + { + $executionOrder = TestSuiteSorter::ORDER_DEFAULT; + $defectsFirst = false; + $resolveDependencies = $this->getBooleanAttribute($document->documentElement, 'resolveDependencies', true); + + if ($document->documentElement->hasAttribute('executionOrder')) { + foreach (explode(',', $document->documentElement->getAttribute('executionOrder')) as $order) { + switch ($order) { + case 'default': + $executionOrder = TestSuiteSorter::ORDER_DEFAULT; + $defectsFirst = false; + $resolveDependencies = true; + + break; + + case 'depends': + $resolveDependencies = true; + + break; + + case 'no-depends': + $resolveDependencies = false; + + break; + + case 'defects': + $defectsFirst = true; + + break; + + case 'duration': + $executionOrder = TestSuiteSorter::ORDER_DURATION; + + break; + + case 'random': + $executionOrder = TestSuiteSorter::ORDER_RANDOMIZED; + + break; + + case 'reverse': + $executionOrder = TestSuiteSorter::ORDER_REVERSED; + + break; + + case 'size': + $executionOrder = TestSuiteSorter::ORDER_SIZE; + + break; + } + } + } + + $printerClass = $this->getStringAttribute($document->documentElement, 'printerClass'); + $testdox = $this->getBooleanAttribute($document->documentElement, 'testdox', false); + $conflictBetweenPrinterClassAndTestdox = false; + + if ($testdox) { + if ($printerClass !== null) { + $conflictBetweenPrinterClassAndTestdox = true; + } + + $printerClass = CliTestDoxPrinter::class; + } + + $cacheResultFile = $this->getStringAttribute($document->documentElement, 'cacheResultFile'); + + if ($cacheResultFile !== null) { + $cacheResultFile = $this->toAbsolutePath($filename, $cacheResultFile); + } + + $bootstrap = $this->getStringAttribute($document->documentElement, 'bootstrap'); + + if ($bootstrap !== null) { + $bootstrap = $this->toAbsolutePath($filename, $bootstrap); + } + + $extensionsDirectory = $this->getStringAttribute($document->documentElement, 'extensionsDirectory'); + + if ($extensionsDirectory !== null) { + $extensionsDirectory = $this->toAbsolutePath($filename, $extensionsDirectory); + } + + $testSuiteLoaderFile = $this->getStringAttribute($document->documentElement, 'testSuiteLoaderFile'); + + if ($testSuiteLoaderFile !== null) { + $testSuiteLoaderFile = $this->toAbsolutePath($filename, $testSuiteLoaderFile); + } + + $printerFile = $this->getStringAttribute($document->documentElement, 'printerFile'); + + if ($printerFile !== null) { + $printerFile = $this->toAbsolutePath($filename, $printerFile); + } + + return new PHPUnit( + $this->getBooleanAttribute($document->documentElement, 'cacheResult', true), + $cacheResultFile, + $this->getColumns($document), + $this->getColors($document), + $this->getBooleanAttribute($document->documentElement, 'stderr', false), + $this->getBooleanAttribute($document->documentElement, 'noInteraction', false), + $this->getBooleanAttribute($document->documentElement, 'verbose', false), + $this->getBooleanAttribute($document->documentElement, 'reverseDefectList', false), + $this->getBooleanAttribute($document->documentElement, 'convertDeprecationsToExceptions', true), + $this->getBooleanAttribute($document->documentElement, 'convertErrorsToExceptions', true), + $this->getBooleanAttribute($document->documentElement, 'convertNoticesToExceptions', true), + $this->getBooleanAttribute($document->documentElement, 'convertWarningsToExceptions', true), + $this->getBooleanAttribute($document->documentElement, 'forceCoversAnnotation', false), + $bootstrap, + $this->getBooleanAttribute($document->documentElement, 'processIsolation', false), + $this->getBooleanAttribute($document->documentElement, 'failOnEmptyTestSuite', false), + $this->getBooleanAttribute($document->documentElement, 'failOnIncomplete', false), + $this->getBooleanAttribute($document->documentElement, 'failOnRisky', false), + $this->getBooleanAttribute($document->documentElement, 'failOnSkipped', false), + $this->getBooleanAttribute($document->documentElement, 'failOnWarning', false), + $this->getBooleanAttribute($document->documentElement, 'stopOnDefect', false), + $this->getBooleanAttribute($document->documentElement, 'stopOnError', false), + $this->getBooleanAttribute($document->documentElement, 'stopOnFailure', false), + $this->getBooleanAttribute($document->documentElement, 'stopOnWarning', false), + $this->getBooleanAttribute($document->documentElement, 'stopOnIncomplete', false), + $this->getBooleanAttribute($document->documentElement, 'stopOnRisky', false), + $this->getBooleanAttribute($document->documentElement, 'stopOnSkipped', false), + $extensionsDirectory, + $this->getStringAttribute($document->documentElement, 'testSuiteLoaderClass'), + $testSuiteLoaderFile, + $printerClass, + $printerFile, + $this->getBooleanAttribute($document->documentElement, 'beStrictAboutChangesToGlobalState', false), + $this->getBooleanAttribute($document->documentElement, 'beStrictAboutOutputDuringTests', false), + $this->getBooleanAttribute($document->documentElement, 'beStrictAboutResourceUsageDuringSmallTests', false), + $this->getBooleanAttribute($document->documentElement, 'beStrictAboutTestsThatDoNotTestAnything', true), + $this->getBooleanAttribute($document->documentElement, 'beStrictAboutTodoAnnotatedTests', false), + $this->getBooleanAttribute($document->documentElement, 'beStrictAboutCoversAnnotation', false), + $this->getBooleanAttribute($document->documentElement, 'enforceTimeLimit', false), + $this->getIntegerAttribute($document->documentElement, 'defaultTimeLimit', 1), + $this->getIntegerAttribute($document->documentElement, 'timeoutForSmallTests', 1), + $this->getIntegerAttribute($document->documentElement, 'timeoutForMediumTests', 10), + $this->getIntegerAttribute($document->documentElement, 'timeoutForLargeTests', 60), + $this->getStringAttribute($document->documentElement, 'defaultTestSuite'), + $executionOrder, + $resolveDependencies, + $defectsFirst, + $this->getBooleanAttribute($document->documentElement, 'backupGlobals', false), + $this->getBooleanAttribute($document->documentElement, 'backupStaticAttributes', false), + $this->getBooleanAttribute($document->documentElement, 'registerMockObjectsFromTestArgumentsRecursively', false), + $conflictBetweenPrinterClassAndTestdox + ); + } + + private function getColors(DOMDocument $document): string + { + $colors = DefaultResultPrinter::COLOR_DEFAULT; + + if ($document->documentElement->hasAttribute('colors')) { + /* only allow boolean for compatibility with previous versions + 'always' only allowed from command line */ + if ($this->getBoolean($document->documentElement->getAttribute('colors'), false)) { + $colors = DefaultResultPrinter::COLOR_AUTO; + } else { + $colors = DefaultResultPrinter::COLOR_NEVER; + } + } + + return $colors; + } + + /** + * @return int|string + */ + private function getColumns(DOMDocument $document) + { + $columns = 80; + + if ($document->documentElement->hasAttribute('columns')) { + $columns = (string) $document->documentElement->getAttribute('columns'); + + if ($columns !== 'max') { + $columns = $this->getInteger($columns, 80); + } + } + + return $columns; + } + + private function testSuite(string $filename, DOMXPath $xpath): TestSuiteCollection + { + $testSuites = []; + + foreach ($this->getTestSuiteElements($xpath) as $element) { + $exclude = []; + + foreach ($element->getElementsByTagName('exclude') as $excludeNode) { + $excludeFile = (string) $excludeNode->textContent; + + if ($excludeFile) { + $exclude[] = new File($this->toAbsolutePath($filename, $excludeFile)); + } + } + + $directories = []; + + foreach ($element->getElementsByTagName('directory') as $directoryNode) { + assert($directoryNode instanceof DOMElement); + + $directory = (string) $directoryNode->textContent; + + if (empty($directory)) { + continue; + } + + $prefix = ''; + + if ($directoryNode->hasAttribute('prefix')) { + $prefix = (string) $directoryNode->getAttribute('prefix'); + } + + $suffix = 'Test.php'; + + if ($directoryNode->hasAttribute('suffix')) { + $suffix = (string) $directoryNode->getAttribute('suffix'); + } + + $phpVersion = PHP_VERSION; + + if ($directoryNode->hasAttribute('phpVersion')) { + $phpVersion = (string) $directoryNode->getAttribute('phpVersion'); + } + + $phpVersionOperator = new VersionComparisonOperator('>='); + + if ($directoryNode->hasAttribute('phpVersionOperator')) { + $phpVersionOperator = new VersionComparisonOperator((string) $directoryNode->getAttribute('phpVersionOperator')); + } + + $directories[] = new TestDirectory( + $this->toAbsolutePath($filename, $directory), + $prefix, + $suffix, + $phpVersion, + $phpVersionOperator + ); + } + + $files = []; + + foreach ($element->getElementsByTagName('file') as $fileNode) { + assert($fileNode instanceof DOMElement); + + $file = (string) $fileNode->textContent; + + if (empty($file)) { + continue; + } + + $phpVersion = PHP_VERSION; + + if ($fileNode->hasAttribute('phpVersion')) { + $phpVersion = (string) $fileNode->getAttribute('phpVersion'); + } + + $phpVersionOperator = new VersionComparisonOperator('>='); + + if ($fileNode->hasAttribute('phpVersionOperator')) { + $phpVersionOperator = new VersionComparisonOperator((string) $fileNode->getAttribute('phpVersionOperator')); + } + + $files[] = new TestFile( + $this->toAbsolutePath($filename, $file), + $phpVersion, + $phpVersionOperator + ); + } + + $testSuites[] = new TestSuiteConfiguration( + (string) $element->getAttribute('name'), + TestDirectoryCollection::fromArray($directories), + TestFileCollection::fromArray($files), + FileCollection::fromArray($exclude) + ); + } + + return TestSuiteCollection::fromArray($testSuites); + } + + /** + * @return DOMElement[] + */ + private function getTestSuiteElements(DOMXPath $xpath): array + { + /** @var DOMElement[] $elements */ + $elements = []; + + $testSuiteNodes = $xpath->query('testsuites/testsuite'); + + if ($testSuiteNodes->length === 0) { + $testSuiteNodes = $xpath->query('testsuite'); + } + + if ($testSuiteNodes->length === 1) { + $element = $testSuiteNodes->item(0); + + assert($element instanceof DOMElement); + + $elements[] = $element; + } else { + foreach ($testSuiteNodes as $testSuiteNode) { + assert($testSuiteNode instanceof DOMElement); + + $elements[] = $testSuiteNode; + } + } + + return $elements; + } + + private function element(DOMXPath $xpath, string $element): ?DOMElement + { + $nodes = $xpath->query($element); + + if ($nodes->length === 1) { + $node = $nodes->item(0); + + assert($node instanceof DOMElement); + + return $node; + } + + return null; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/Junit.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/Junit.php new file mode 100644 index 000000000..efde962d9 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/Junit.php @@ -0,0 +1,34 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration\Logging; + +use PHPUnit\TextUI\XmlConfiguration\File; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Junit +{ + /** + * @var File + */ + private $target; + + public function __construct(File $target) + { + $this->target = $target; + } + + public function target(): File + { + return $this->target; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/Logging.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/Logging.php new file mode 100644 index 000000000..cdceced50 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/Logging.php @@ -0,0 +1,146 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration\Logging; + +use PHPUnit\TextUI\XmlConfiguration\Exception; +use PHPUnit\TextUI\XmlConfiguration\Logging\TestDox\Html as TestDoxHtml; +use PHPUnit\TextUI\XmlConfiguration\Logging\TestDox\Text as TestDoxText; +use PHPUnit\TextUI\XmlConfiguration\Logging\TestDox\Xml as TestDoxXml; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Logging +{ + /** + * @var ?Junit + */ + private $junit; + + /** + * @var ?Text + */ + private $text; + + /** + * @var ?TeamCity + */ + private $teamCity; + + /** + * @var ?TestDoxHtml + */ + private $testDoxHtml; + + /** + * @var ?TestDoxText + */ + private $testDoxText; + + /** + * @var ?TestDoxXml + */ + private $testDoxXml; + + public function __construct(?Junit $junit, ?Text $text, ?TeamCity $teamCity, ?TestDoxHtml $testDoxHtml, ?TestDoxText $testDoxText, ?TestDoxXml $testDoxXml) + { + $this->junit = $junit; + $this->text = $text; + $this->teamCity = $teamCity; + $this->testDoxHtml = $testDoxHtml; + $this->testDoxText = $testDoxText; + $this->testDoxXml = $testDoxXml; + } + + public function hasJunit(): bool + { + return $this->junit !== null; + } + + public function junit(): Junit + { + if ($this->junit === null) { + throw new Exception('Logger "JUnit XML" is not configured'); + } + + return $this->junit; + } + + public function hasText(): bool + { + return $this->text !== null; + } + + public function text(): Text + { + if ($this->text === null) { + throw new Exception('Logger "Text" is not configured'); + } + + return $this->text; + } + + public function hasTeamCity(): bool + { + return $this->teamCity !== null; + } + + public function teamCity(): TeamCity + { + if ($this->teamCity === null) { + throw new Exception('Logger "Team City" is not configured'); + } + + return $this->teamCity; + } + + public function hasTestDoxHtml(): bool + { + return $this->testDoxHtml !== null; + } + + public function testDoxHtml(): TestDoxHtml + { + if ($this->testDoxHtml === null) { + throw new Exception('Logger "TestDox HTML" is not configured'); + } + + return $this->testDoxHtml; + } + + public function hasTestDoxText(): bool + { + return $this->testDoxText !== null; + } + + public function testDoxText(): TestDoxText + { + if ($this->testDoxText === null) { + throw new Exception('Logger "TestDox Text" is not configured'); + } + + return $this->testDoxText; + } + + public function hasTestDoxXml(): bool + { + return $this->testDoxXml !== null; + } + + public function testDoxXml(): TestDoxXml + { + if ($this->testDoxXml === null) { + throw new Exception('Logger "TestDox XML" is not configured'); + } + + return $this->testDoxXml; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TeamCity.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TeamCity.php new file mode 100644 index 000000000..03b2b56a9 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TeamCity.php @@ -0,0 +1,34 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration\Logging; + +use PHPUnit\TextUI\XmlConfiguration\File; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class TeamCity +{ + /** + * @var File + */ + private $target; + + public function __construct(File $target) + { + $this->target = $target; + } + + public function target(): File + { + return $this->target; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TestDox/Html.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TestDox/Html.php new file mode 100644 index 000000000..310040b2e --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TestDox/Html.php @@ -0,0 +1,34 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration\Logging\TestDox; + +use PHPUnit\TextUI\XmlConfiguration\File; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Html +{ + /** + * @var File + */ + private $target; + + public function __construct(File $target) + { + $this->target = $target; + } + + public function target(): File + { + return $this->target; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TestDox/Text.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TestDox/Text.php new file mode 100644 index 000000000..59d37e9b2 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TestDox/Text.php @@ -0,0 +1,34 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration\Logging\TestDox; + +use PHPUnit\TextUI\XmlConfiguration\File; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Text +{ + /** + * @var File + */ + private $target; + + public function __construct(File $target) + { + $this->target = $target; + } + + public function target(): File + { + return $this->target; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TestDox/Xml.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TestDox/Xml.php new file mode 100644 index 000000000..b8c1576c1 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/TestDox/Xml.php @@ -0,0 +1,34 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration\Logging\TestDox; + +use PHPUnit\TextUI\XmlConfiguration\File; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Xml +{ + /** + * @var File + */ + private $target; + + public function __construct(File $target) + { + $this->target = $target; + } + + public function target(): File + { + return $this->target; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/Text.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/Text.php new file mode 100644 index 000000000..2769ec967 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Logging/Text.php @@ -0,0 +1,34 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration\Logging; + +use PHPUnit\TextUI\XmlConfiguration\File; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Text +{ + /** + * @var File + */ + private $target; + + public function __construct(File $target) + { + $this->target = $target; + } + + public function target(): File + { + return $this->target; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/MigrationBuilder.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/MigrationBuilder.php new file mode 100644 index 000000000..abef49f10 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/MigrationBuilder.php @@ -0,0 +1,73 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function array_key_exists; +use function sprintf; +use function version_compare; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class MigrationBuilder +{ + private const AVAILABLE_MIGRATIONS = [ + '8.5' => [ + RemoveLogTypes::class, + ], + + '9.2' => [ + RemoveCacheTokensAttribute::class, + IntroduceCoverageElement::class, + MoveAttributesFromRootToCoverage::class, + MoveAttributesFromFilterWhitelistToCoverage::class, + MoveWhitelistDirectoriesToCoverage::class, + MoveWhitelistExcludesToCoverage::class, + RemoveEmptyFilter::class, + CoverageCloverToReport::class, + CoverageCrap4jToReport::class, + CoverageHtmlToReport::class, + CoveragePhpToReport::class, + CoverageTextToReport::class, + CoverageXmlToReport::class, + ConvertLogTypes::class, + UpdateSchemaLocationTo93::class, + ], + ]; + + /** + * @throws MigrationBuilderException + */ + public function build(string $fromVersion): array + { + if (!array_key_exists($fromVersion, self::AVAILABLE_MIGRATIONS)) { + throw new MigrationBuilderException( + sprintf( + 'Migration from schema version %s is not supported', + $fromVersion + ) + ); + } + + $stack = []; + + foreach (self::AVAILABLE_MIGRATIONS as $version => $migrations) { + if (version_compare($version, $fromVersion, '<')) { + continue; + } + + foreach ($migrations as $migration) { + $stack[] = new $migration; + } + } + + return $stack; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/MigrationBuilderException.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/MigrationBuilderException.php new file mode 100644 index 000000000..3d3c767af --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/MigrationBuilderException.php @@ -0,0 +1,19 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use RuntimeException; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class MigrationBuilderException extends RuntimeException implements \PHPUnit\Exception +{ +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/MigrationException.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/MigrationException.php new file mode 100644 index 000000000..f92b2db30 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/MigrationException.php @@ -0,0 +1,19 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use RuntimeException; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class MigrationException extends RuntimeException implements \PHPUnit\Exception +{ +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/ConvertLogTypes.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/ConvertLogTypes.php new file mode 100644 index 000000000..697bbe082 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/ConvertLogTypes.php @@ -0,0 +1,53 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use DOMDocument; +use DOMElement; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class ConvertLogTypes implements Migration +{ + public function migrate(DOMDocument $document): void + { + $logging = $document->getElementsByTagName('logging')->item(0); + + if (!$logging instanceof DOMElement) { + return; + } + $types = [ + 'junit' => 'junit', + 'teamcity' => 'teamcity', + 'testdox-html' => 'testdoxHtml', + 'testdox-text' => 'testdoxText', + 'testdox-xml' => 'testdoxXml', + 'plain' => 'text', + ]; + + $logNodes = []; + + foreach ($logging->getElementsByTagName('log') as $logNode) { + if (!isset($types[$logNode->getAttribute('type')])) { + continue; + } + + $logNodes[] = $logNode; + } + + foreach ($logNodes as $oldNode) { + $newLogNode = $document->createElement($types[$oldNode->getAttribute('type')]); + $newLogNode->setAttribute('outputFile', $oldNode->getAttribute('target')); + + $logging->replaceChild($newLogNode, $oldNode); + } + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageCloverToReport.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageCloverToReport.php new file mode 100644 index 000000000..5f1522b9c --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageCloverToReport.php @@ -0,0 +1,31 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use DOMElement; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class CoverageCloverToReport extends LogToReportMigration +{ + protected function forType(): string + { + return 'coverage-clover'; + } + + protected function toReportFormat(DOMElement $logNode): DOMElement + { + $clover = $logNode->ownerDocument->createElement('clover'); + $clover->setAttribute('outputFile', $logNode->getAttribute('target')); + + return $clover; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageCrap4jToReport.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageCrap4jToReport.php new file mode 100644 index 000000000..afbaaec18 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageCrap4jToReport.php @@ -0,0 +1,33 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use DOMElement; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class CoverageCrap4jToReport extends LogToReportMigration +{ + protected function forType(): string + { + return 'coverage-crap4j'; + } + + protected function toReportFormat(DOMElement $logNode): DOMElement + { + $crap4j = $logNode->ownerDocument->createElement('crap4j'); + $crap4j->setAttribute('outputFile', $logNode->getAttribute('target')); + + $this->migrateAttributes($logNode, $crap4j, ['threshold']); + + return $crap4j; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageHtmlToReport.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageHtmlToReport.php new file mode 100644 index 000000000..7e12095b4 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageHtmlToReport.php @@ -0,0 +1,33 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use DOMElement; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class CoverageHtmlToReport extends LogToReportMigration +{ + protected function forType(): string + { + return 'coverage-html'; + } + + protected function toReportFormat(DOMElement $logNode): DOMElement + { + $html = $logNode->ownerDocument->createElement('html'); + $html->setAttribute('outputDirectory', $logNode->getAttribute('target')); + + $this->migrateAttributes($logNode, $html, ['lowUpperBound', 'highLowerBound']); + + return $html; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoveragePhpToReport.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoveragePhpToReport.php new file mode 100644 index 000000000..bfa10030b --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoveragePhpToReport.php @@ -0,0 +1,31 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use DOMElement; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class CoveragePhpToReport extends LogToReportMigration +{ + protected function forType(): string + { + return 'coverage-php'; + } + + protected function toReportFormat(DOMElement $logNode): DOMElement + { + $php = $logNode->ownerDocument->createElement('php'); + $php->setAttribute('outputFile', $logNode->getAttribute('target')); + + return $php; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageTextToReport.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageTextToReport.php new file mode 100644 index 000000000..063d8df0c --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageTextToReport.php @@ -0,0 +1,33 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use DOMElement; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class CoverageTextToReport extends LogToReportMigration +{ + protected function forType(): string + { + return 'coverage-text'; + } + + protected function toReportFormat(DOMElement $logNode): DOMElement + { + $text = $logNode->ownerDocument->createElement('text'); + $text->setAttribute('outputFile', $logNode->getAttribute('target')); + + $this->migrateAttributes($logNode, $text, ['showUncoveredFiles', 'showOnlySummary']); + + return $text; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageXmlToReport.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageXmlToReport.php new file mode 100644 index 000000000..480d7777e --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/CoverageXmlToReport.php @@ -0,0 +1,31 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use DOMElement; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class CoverageXmlToReport extends LogToReportMigration +{ + protected function forType(): string + { + return 'coverage-xml'; + } + + protected function toReportFormat(DOMElement $logNode): DOMElement + { + $xml = $logNode->ownerDocument->createElement('xml'); + $xml->setAttribute('outputDirectory', $logNode->getAttribute('target')); + + return $xml; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/IntroduceCoverageElement.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/IntroduceCoverageElement.php new file mode 100644 index 000000000..867a84417 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/IntroduceCoverageElement.php @@ -0,0 +1,28 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use DOMDocument; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class IntroduceCoverageElement implements Migration +{ + public function migrate(DOMDocument $document): void + { + $coverage = $document->createElement('coverage'); + + $document->documentElement->insertBefore( + $coverage, + $document->documentElement->firstChild + ); + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/LogToReportMigration.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/LogToReportMigration.php new file mode 100644 index 000000000..e987308b7 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/LogToReportMigration.php @@ -0,0 +1,79 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function sprintf; +use DOMDocument; +use DOMElement; +use DOMXPath; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +abstract class LogToReportMigration implements Migration +{ + /** + * @throws MigrationException + */ + public function migrate(DOMDocument $document): void + { + $coverage = $document->getElementsByTagName('coverage')->item(0); + + if (!$coverage instanceof DOMElement) { + throw new MigrationException('Unexpected state - No coverage element'); + } + + $logNode = $this->findLogNode($document); + + if ($logNode === null) { + return; + } + + $reportChild = $this->toReportFormat($logNode); + + $report = $coverage->getElementsByTagName('report')->item(0); + + if ($report === null) { + $report = $coverage->appendChild($document->createElement('report')); + } + + $report->appendChild($reportChild); + $logNode->parentNode->removeChild($logNode); + } + + protected function migrateAttributes(DOMElement $src, DOMElement $dest, array $attributes): void + { + foreach ($attributes as $attr) { + if (!$src->hasAttribute($attr)) { + continue; + } + + $dest->setAttribute($attr, $src->getAttribute($attr)); + $src->removeAttribute($attr); + } + } + + abstract protected function forType(): string; + + abstract protected function toReportFormat(DOMElement $logNode): DOMElement; + + private function findLogNode(DOMDocument $document): ?DOMElement + { + $logNode = (new DOMXPath($document))->query( + sprintf('//logging/log[@type="%s"]', $this->forType()) + )->item(0); + + if (!$logNode instanceof DOMElement) { + return null; + } + + return $logNode; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/Migration.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/Migration.php new file mode 100644 index 000000000..fa4092a9f --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/Migration.php @@ -0,0 +1,20 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use DOMDocument; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +interface Migration +{ + public function migrate(DOMDocument $document): void; +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveAttributesFromFilterWhitelistToCoverage.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveAttributesFromFilterWhitelistToCoverage.php new file mode 100644 index 000000000..a7aab5e51 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveAttributesFromFilterWhitelistToCoverage.php @@ -0,0 +1,51 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use DOMDocument; +use DOMElement; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class MoveAttributesFromFilterWhitelistToCoverage implements Migration +{ + /** + * @throws MigrationException + */ + public function migrate(DOMDocument $document): void + { + $whitelist = $document->getElementsByTagName('whitelist')->item(0); + + if (!$whitelist) { + return; + } + + $coverage = $document->getElementsByTagName('coverage')->item(0); + + if (!$coverage instanceof DOMElement) { + throw new MigrationException('Unexpected state - No coverage element'); + } + + $map = [ + 'addUncoveredFilesFromWhitelist' => 'includeUncoveredFiles', + 'processUncoveredFilesFromWhitelist' => 'processUncoveredFiles', + ]; + + foreach ($map as $old => $new) { + if (!$whitelist->hasAttribute($old)) { + continue; + } + + $coverage->setAttribute($new, $whitelist->getAttribute($old)); + $whitelist->removeAttribute($old); + } + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveAttributesFromRootToCoverage.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveAttributesFromRootToCoverage.php new file mode 100644 index 000000000..b86b259c3 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveAttributesFromRootToCoverage.php @@ -0,0 +1,47 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use DOMDocument; +use DOMElement; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class MoveAttributesFromRootToCoverage implements Migration +{ + /** + * @throws MigrationException + */ + public function migrate(DOMDocument $document): void + { + $map = [ + 'disableCodeCoverageIgnore' => 'disableCodeCoverageIgnore', + 'ignoreDeprecatedCodeUnitsFromCodeCoverage' => 'ignoreDeprecatedCodeUnits', + ]; + + $root = $document->documentElement; + + $coverage = $document->getElementsByTagName('coverage')->item(0); + + if (!$coverage instanceof DOMElement) { + throw new MigrationException('Unexpected state - No coverage element'); + } + + foreach ($map as $old => $new) { + if (!$root->hasAttribute($old)) { + continue; + } + + $coverage->setAttribute($new, $root->getAttribute($old)); + $root->removeAttribute($old); + } + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveWhitelistDirectoriesToCoverage.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveWhitelistDirectoriesToCoverage.php new file mode 100644 index 000000000..14e6cec83 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveWhitelistDirectoriesToCoverage.php @@ -0,0 +1,49 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use DOMDocument; +use DOMElement; +use PHPUnit\Util\Xml\SnapshotNodeList; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class MoveWhitelistDirectoriesToCoverage implements Migration +{ + /** + * @throws MigrationException + */ + public function migrate(DOMDocument $document): void + { + $whitelist = $document->getElementsByTagName('whitelist')->item(0); + + if ($whitelist === null) { + return; + } + + $coverage = $document->getElementsByTagName('coverage')->item(0); + + if (!$coverage instanceof DOMElement) { + throw new MigrationException('Unexpected state - No coverage element'); + } + + $include = $document->createElement('include'); + $coverage->appendChild($include); + + foreach (SnapshotNodeList::fromNodeList($whitelist->childNodes) as $child) { + if (!$child instanceof DOMElement || $child->nodeName !== 'directory') { + continue; + } + + $include->appendChild($child); + } + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveWhitelistExcludesToCoverage.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveWhitelistExcludesToCoverage.php new file mode 100644 index 000000000..d8958cf4e --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/MoveWhitelistExcludesToCoverage.php @@ -0,0 +1,70 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use DOMDocument; +use DOMElement; +use PHPUnit\Util\Xml\SnapshotNodeList; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class MoveWhitelistExcludesToCoverage implements Migration +{ + /** + * @throws MigrationException + */ + public function migrate(DOMDocument $document): void + { + $whitelist = $document->getElementsByTagName('whitelist')->item(0); + + if ($whitelist === null) { + return; + } + + $excludeNodes = SnapshotNodeList::fromNodeList($whitelist->getElementsByTagName('exclude')); + + if ($excludeNodes->count() === 0) { + return; + } + + $coverage = $document->getElementsByTagName('coverage')->item(0); + + if (!$coverage instanceof DOMElement) { + throw new MigrationException('Unexpected state - No coverage element'); + } + + $targetExclude = $coverage->getElementsByTagName('exclude')->item(0); + + if ($targetExclude === null) { + $targetExclude = $coverage->appendChild( + $document->createElement('exclude') + ); + } + + foreach ($excludeNodes as $excludeNode) { + assert($excludeNode instanceof DOMElement); + + foreach (SnapshotNodeList::fromNodeList($excludeNode->childNodes) as $child) { + if (!$child instanceof DOMElement || !in_array($child->nodeName, ['directory', 'file'], true)) { + continue; + } + + $targetExclude->appendChild($child); + } + + if ($excludeNode->getElementsByTagName('*')->count() !== 0) { + throw new MigrationException('Dangling child elements in exclude found.'); + } + + $whitelist->removeChild($excludeNode); + } + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/RemoveCacheTokensAttribute.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/RemoveCacheTokensAttribute.php new file mode 100644 index 000000000..0eec12ac1 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/RemoveCacheTokensAttribute.php @@ -0,0 +1,27 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use DOMDocument; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class RemoveCacheTokensAttribute implements Migration +{ + public function migrate(DOMDocument $document): void + { + $root = $document->documentElement; + + if ($root->hasAttribute('cacheTokens')) { + $root->removeAttribute('cacheTokens'); + } + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/RemoveEmptyFilter.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/RemoveEmptyFilter.php new file mode 100644 index 000000000..8f1a6d547 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/RemoveEmptyFilter.php @@ -0,0 +1,54 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function sprintf; +use DOMDocument; +use DOMElement; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class RemoveEmptyFilter implements Migration +{ + /** + * @throws MigrationException + */ + public function migrate(DOMDocument $document): void + { + $whitelist = $document->getElementsByTagName('whitelist')->item(0); + + if ($whitelist instanceof DOMElement) { + $this->ensureEmpty($whitelist); + $whitelist->parentNode->removeChild($whitelist); + } + + $filter = $document->getElementsByTagName('filter')->item(0); + + if ($filter instanceof DOMElement) { + $this->ensureEmpty($filter); + $filter->parentNode->removeChild($filter); + } + } + + /** + * @throws MigrationException + */ + private function ensureEmpty(DOMElement $element): void + { + if ($element->attributes->length > 0) { + throw new MigrationException(sprintf('%s element has unexpected attributes', $element->nodeName)); + } + + if ($element->getElementsByTagName('*')->length > 0) { + throw new MigrationException(sprintf('%s element has unexpected children', $element->nodeName)); + } + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/RemoveLogTypes.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/RemoveLogTypes.php new file mode 100644 index 000000000..99a762b18 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/RemoveLogTypes.php @@ -0,0 +1,37 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use DOMDocument; +use DOMElement; +use PHPUnit\Util\Xml\SnapshotNodeList; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class RemoveLogTypes implements Migration +{ + public function migrate(DOMDocument $document): void + { + $logging = $document->getElementsByTagName('logging')->item(0); + + if (!$logging instanceof DOMElement) { + return; + } + + foreach (SnapshotNodeList::fromNodeList($logging->getElementsByTagName('log')) as $logNode) { + switch ($logNode->getAttribute('type')) { + case 'json': + case 'tap': + $logging->removeChild($logNode); + } + } + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/UpdateSchemaLocationTo93.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/UpdateSchemaLocationTo93.php new file mode 100644 index 000000000..2e86ab6e9 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrations/UpdateSchemaLocationTo93.php @@ -0,0 +1,27 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use DOMDocument; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class UpdateSchemaLocationTo93 implements Migration +{ + public function migrate(DOMDocument $document): void + { + $document->documentElement->setAttributeNS( + 'http://www.w3.org/2001/XMLSchema-instance', + 'xsi:noNamespaceSchemaLocation', + 'https://schema.phpunit.de/9.3/phpunit.xsd' + ); + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrator.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrator.php new file mode 100644 index 000000000..d173e7af2 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/Migration/Migrator.php @@ -0,0 +1,57 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function sprintf; +use PHPUnit\Util\Xml\Exception as XmlException; +use PHPUnit\Util\Xml\Loader as XmlLoader; +use PHPUnit\Util\Xml\SchemaDetector; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class Migrator +{ + /** + * @throws Exception + * @throws MigrationBuilderException + * @throws MigrationException + * @throws XmlException + */ + public function migrate(string $filename): string + { + $origin = (new SchemaDetector)->detect($filename); + + if (!$origin->detected()) { + throw new Exception( + sprintf( + '"%s" is not a valid PHPUnit XML configuration file that can be migrated', + $filename, + ) + ); + } + + $configurationDocument = (new XmlLoader)->loadFile( + $filename, + false, + true, + true + ); + + foreach ((new MigrationBuilder)->build($origin->version()) as $migration) { + $migration->migrate($configurationDocument); + } + + $configurationDocument->formatOutput = true; + $configurationDocument->preserveWhiteSpace = false; + + return $configurationDocument->saveXML(); + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/Constant.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/Constant.php new file mode 100644 index 000000000..e9b28b9e8 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/Constant.php @@ -0,0 +1,43 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Constant +{ + /** + * @var string + */ + private $name; + + /** + * @var mixed + */ + private $value; + + public function __construct(string $name, $value) + { + $this->name = $name; + $this->value = $value; + } + + public function name(): string + { + return $this->name; + } + + public function value() + { + return $this->value; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/ConstantCollection.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/ConstantCollection.php new file mode 100644 index 000000000..51c14715f --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/ConstantCollection.php @@ -0,0 +1,57 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function count; +use Countable; +use IteratorAggregate; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class ConstantCollection implements Countable, IteratorAggregate +{ + /** + * @var Constant[] + */ + private $constants; + + /** + * @param Constant[] $constants + */ + public static function fromArray(array $constants): self + { + return new self(...$constants); + } + + private function __construct(Constant ...$constants) + { + $this->constants = $constants; + } + + /** + * @return Constant[] + */ + public function asArray(): array + { + return $this->constants; + } + + public function count(): int + { + return count($this->constants); + } + + public function getIterator(): ConstantCollectionIterator + { + return new ConstantCollectionIterator($this); + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/ConstantCollectionIterator.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/ConstantCollectionIterator.php new file mode 100644 index 000000000..c1c8d834b --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/ConstantCollectionIterator.php @@ -0,0 +1,66 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function count; +use function iterator_count; +use Countable; +use Iterator; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class ConstantCollectionIterator implements Countable, Iterator +{ + /** + * @var Constant[] + */ + private $constants; + + /** + * @var int + */ + private $position; + + public function __construct(ConstantCollection $constants) + { + $this->constants = $constants->asArray(); + } + + public function count(): int + { + return iterator_count($this); + } + + public function rewind(): void + { + $this->position = 0; + } + + public function valid(): bool + { + return $this->position < count($this->constants); + } + + public function key(): int + { + return $this->position; + } + + public function current(): Constant + { + return $this->constants[$this->position]; + } + + public function next(): void + { + $this->position++; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/IniSetting.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/IniSetting.php new file mode 100644 index 000000000..58cf735b0 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/IniSetting.php @@ -0,0 +1,43 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class IniSetting +{ + /** + * @var string + */ + private $name; + + /** + * @var string + */ + private $value; + + public function __construct(string $name, string $value) + { + $this->name = $name; + $this->value = $value; + } + + public function name(): string + { + return $this->name; + } + + public function value(): string + { + return $this->value; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/IniSettingCollection.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/IniSettingCollection.php new file mode 100644 index 000000000..216d85aec --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/IniSettingCollection.php @@ -0,0 +1,57 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function count; +use Countable; +use IteratorAggregate; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class IniSettingCollection implements Countable, IteratorAggregate +{ + /** + * @var IniSetting[] + */ + private $iniSettings; + + /** + * @param IniSetting[] $iniSettings + */ + public static function fromArray(array $iniSettings): self + { + return new self(...$iniSettings); + } + + private function __construct(IniSetting ...$iniSettings) + { + $this->iniSettings = $iniSettings; + } + + /** + * @return IniSetting[] + */ + public function asArray(): array + { + return $this->iniSettings; + } + + public function count(): int + { + return count($this->iniSettings); + } + + public function getIterator(): IniSettingCollectionIterator + { + return new IniSettingCollectionIterator($this); + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/IniSettingCollectionIterator.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/IniSettingCollectionIterator.php new file mode 100644 index 000000000..f31225e8f --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/IniSettingCollectionIterator.php @@ -0,0 +1,66 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function count; +use function iterator_count; +use Countable; +use Iterator; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class IniSettingCollectionIterator implements Countable, Iterator +{ + /** + * @var IniSetting[] + */ + private $iniSettings; + + /** + * @var int + */ + private $position; + + public function __construct(IniSettingCollection $iniSettings) + { + $this->iniSettings = $iniSettings->asArray(); + } + + public function count(): int + { + return iterator_count($this); + } + + public function rewind(): void + { + $this->position = 0; + } + + public function valid(): bool + { + return $this->position < count($this->iniSettings); + } + + public function key(): int + { + return $this->position; + } + + public function current(): IniSetting + { + return $this->iniSettings[$this->position]; + } + + public function next(): void + { + $this->position++; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/Php.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/Php.php new file mode 100644 index 000000000..26897e359 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/Php.php @@ -0,0 +1,142 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Php +{ + /** + * @var DirectoryCollection + */ + private $includePaths; + + /** + * @var IniSettingCollection + */ + private $iniSettings; + + /** + * @var ConstantCollection + */ + private $constants; + + /** + * @var VariableCollection + */ + private $globalVariables; + + /** + * @var VariableCollection + */ + private $envVariables; + + /** + * @var VariableCollection + */ + private $postVariables; + + /** + * @var VariableCollection + */ + private $getVariables; + + /** + * @var VariableCollection + */ + private $cookieVariables; + + /** + * @var VariableCollection + */ + private $serverVariables; + + /** + * @var VariableCollection + */ + private $filesVariables; + + /** + * @var VariableCollection + */ + private $requestVariables; + + public function __construct(DirectoryCollection $includePaths, IniSettingCollection $iniSettings, ConstantCollection $constants, VariableCollection $globalVariables, VariableCollection $envVariables, VariableCollection $postVariables, VariableCollection $getVariables, VariableCollection $cookieVariables, VariableCollection $serverVariables, VariableCollection $filesVariables, VariableCollection $requestVariables) + { + $this->includePaths = $includePaths; + $this->iniSettings = $iniSettings; + $this->constants = $constants; + $this->globalVariables = $globalVariables; + $this->envVariables = $envVariables; + $this->postVariables = $postVariables; + $this->getVariables = $getVariables; + $this->cookieVariables = $cookieVariables; + $this->serverVariables = $serverVariables; + $this->filesVariables = $filesVariables; + $this->requestVariables = $requestVariables; + } + + public function includePaths(): DirectoryCollection + { + return $this->includePaths; + } + + public function iniSettings(): IniSettingCollection + { + return $this->iniSettings; + } + + public function constants(): ConstantCollection + { + return $this->constants; + } + + public function globalVariables(): VariableCollection + { + return $this->globalVariables; + } + + public function envVariables(): VariableCollection + { + return $this->envVariables; + } + + public function postVariables(): VariableCollection + { + return $this->postVariables; + } + + public function getVariables(): VariableCollection + { + return $this->getVariables; + } + + public function cookieVariables(): VariableCollection + { + return $this->cookieVariables; + } + + public function serverVariables(): VariableCollection + { + return $this->serverVariables; + } + + public function filesVariables(): VariableCollection + { + return $this->filesVariables; + } + + public function requestVariables(): VariableCollection + { + return $this->requestVariables; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/PhpHandler.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/PhpHandler.php new file mode 100644 index 000000000..5fb0c72b2 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/PhpHandler.php @@ -0,0 +1,121 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use const PATH_SEPARATOR; +use function constant; +use function define; +use function defined; +use function getenv; +use function implode; +use function ini_get; +use function ini_set; +use function putenv; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class PhpHandler +{ + public function handle(Php $configuration): void + { + $this->handleIncludePaths($configuration->includePaths()); + $this->handleIniSettings($configuration->iniSettings()); + $this->handleConstants($configuration->constants()); + $this->handleGlobalVariables($configuration->globalVariables()); + $this->handleServerVariables($configuration->serverVariables()); + $this->handleEnvVariables($configuration->envVariables()); + $this->handleVariables('_POST', $configuration->postVariables()); + $this->handleVariables('_GET', $configuration->getVariables()); + $this->handleVariables('_COOKIE', $configuration->cookieVariables()); + $this->handleVariables('_FILES', $configuration->filesVariables()); + $this->handleVariables('_REQUEST', $configuration->requestVariables()); + } + + private function handleIncludePaths(DirectoryCollection $includePaths): void + { + if (!$includePaths->isEmpty()) { + $includePathsAsStrings = []; + + foreach ($includePaths as $includePath) { + $includePathsAsStrings[] = $includePath->path(); + } + + ini_set( + 'include_path', + implode(PATH_SEPARATOR, $includePathsAsStrings) . + PATH_SEPARATOR . + ini_get('include_path') + ); + } + } + + private function handleIniSettings(IniSettingCollection $iniSettings): void + { + foreach ($iniSettings as $iniSetting) { + $value = $iniSetting->value(); + + if (defined($value)) { + $value = (string) constant($value); + } + + ini_set($iniSetting->name(), $value); + } + } + + private function handleConstants(ConstantCollection $constants): void + { + foreach ($constants as $constant) { + if (!defined($constant->name())) { + define($constant->name(), $constant->value()); + } + } + } + + private function handleGlobalVariables(VariableCollection $variables): void + { + foreach ($variables as $variable) { + $GLOBALS[$variable->name()] = $variable->value(); + } + } + + private function handleServerVariables(VariableCollection $variables): void + { + foreach ($variables as $variable) { + $_SERVER[$variable->name()] = $variable->value(); + } + } + + private function handleVariables(string $target, VariableCollection $variables): void + { + foreach ($variables as $variable) { + $GLOBALS[$target][$variable->name()] = $variable->value(); + } + } + + private function handleEnvVariables(VariableCollection $variables): void + { + foreach ($variables as $variable) { + $name = $variable->name(); + $value = $variable->value(); + $force = $variable->force(); + + if ($force || getenv($name) === false) { + putenv("{$name}={$value}"); + } + + $value = getenv($name); + + if ($force || !isset($_ENV[$name])) { + $_ENV[$name] = $value; + } + } + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/Variable.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/Variable.php new file mode 100644 index 000000000..c2684e28f --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/Variable.php @@ -0,0 +1,54 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Variable +{ + /** + * @var string + */ + private $name; + + /** + * @var mixed + */ + private $value; + + /** + * @var bool + */ + private $force; + + public function __construct(string $name, $value, bool $force) + { + $this->name = $name; + $this->value = $value; + $this->force = $force; + } + + public function name(): string + { + return $this->name; + } + + public function value() + { + return $this->value; + } + + public function force(): bool + { + return $this->force; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/VariableCollection.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/VariableCollection.php new file mode 100644 index 000000000..e84992168 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/VariableCollection.php @@ -0,0 +1,57 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function count; +use Countable; +use IteratorAggregate; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class VariableCollection implements Countable, IteratorAggregate +{ + /** + * @var Variable[] + */ + private $variables; + + /** + * @param Variable[] $variables + */ + public static function fromArray(array $variables): self + { + return new self(...$variables); + } + + private function __construct(Variable ...$variables) + { + $this->variables = $variables; + } + + /** + * @return Variable[] + */ + public function asArray(): array + { + return $this->variables; + } + + public function count(): int + { + return count($this->variables); + } + + public function getIterator(): VariableCollectionIterator + { + return new VariableCollectionIterator($this); + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/VariableCollectionIterator.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/VariableCollectionIterator.php new file mode 100644 index 000000000..3d594c1ee --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHP/VariableCollectionIterator.php @@ -0,0 +1,66 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function count; +use function iterator_count; +use Countable; +use Iterator; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class VariableCollectionIterator implements Countable, Iterator +{ + /** + * @var Variable[] + */ + private $variables; + + /** + * @var int + */ + private $position; + + public function __construct(VariableCollection $variables) + { + $this->variables = $variables->asArray(); + } + + public function count(): int + { + return iterator_count($this); + } + + public function rewind(): void + { + $this->position = 0; + } + + public function valid(): bool + { + return $this->position < count($this->variables); + } + + public function key(): int + { + return $this->position; + } + + public function current(): Variable + { + return $this->variables[$this->position]; + } + + public function next(): void + { + $this->position++; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/Extension.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/Extension.php new file mode 100644 index 000000000..77c5b2d0d --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/Extension.php @@ -0,0 +1,71 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class Extension +{ + /** + * @var string + * @psalm-var class-string + */ + private $className; + + /** + * @var string + */ + private $sourceFile; + + /** + * @var array + */ + private $arguments; + + /** + * @psalm-param class-string $className + */ + public function __construct(string $className, string $sourceFile, array $arguments) + { + $this->className = $className; + $this->sourceFile = $sourceFile; + $this->arguments = $arguments; + } + + /** + * @psalm-return class-string + */ + public function className(): string + { + return $this->className; + } + + public function hasSourceFile(): bool + { + return $this->sourceFile !== ''; + } + + public function sourceFile(): string + { + return $this->sourceFile; + } + + public function hasArguments(): bool + { + return !empty($this->arguments); + } + + public function arguments(): array + { + return $this->arguments; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/ExtensionCollection.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/ExtensionCollection.php new file mode 100644 index 000000000..45be2eeeb --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/ExtensionCollection.php @@ -0,0 +1,50 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use IteratorAggregate; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class ExtensionCollection implements IteratorAggregate +{ + /** + * @var Extension[] + */ + private $extensions; + + /** + * @param Extension[] $extensions + */ + public static function fromArray(array $extensions): self + { + return new self(...$extensions); + } + + private function __construct(Extension ...$extensions) + { + $this->extensions = $extensions; + } + + /** + * @return Extension[] + */ + public function asArray(): array + { + return $this->extensions; + } + + public function getIterator(): ExtensionCollectionIterator + { + return new ExtensionCollectionIterator($this); + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/ExtensionCollectionIterator.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/ExtensionCollectionIterator.php new file mode 100644 index 000000000..4bd54be49 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/ExtensionCollectionIterator.php @@ -0,0 +1,66 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function count; +use function iterator_count; +use Countable; +use Iterator; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class ExtensionCollectionIterator implements Countable, Iterator +{ + /** + * @var Extension[] + */ + private $extensions; + + /** + * @var int + */ + private $position; + + public function __construct(ExtensionCollection $extensions) + { + $this->extensions = $extensions->asArray(); + } + + public function count(): int + { + return iterator_count($this); + } + + public function rewind(): void + { + $this->position = 0; + } + + public function valid(): bool + { + return $this->position < count($this->extensions); + } + + public function key(): int + { + return $this->position; + } + + public function current(): Extension + { + return $this->extensions[$this->position]; + } + + public function next(): void + { + $this->position++; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/PHPUnit.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/PHPUnit.php new file mode 100644 index 000000000..edf298dd5 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/PHPUnit/PHPUnit.php @@ -0,0 +1,714 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class PHPUnit +{ + /** + * @var bool + */ + private $cacheResult; + + /** + * @var ?string + */ + private $cacheResultFile; + + /** + * @var int|string + */ + private $columns; + + /** + * @var string + */ + private $colors; + + /** + * @var bool + */ + private $stderr; + + /** + * @var bool + */ + private $noInteraction; + + /** + * @var bool + */ + private $verbose; + + /** + * @var bool + */ + private $reverseDefectList; + + /** + * @var bool + */ + private $convertDeprecationsToExceptions; + + /** + * @var bool + */ + private $convertErrorsToExceptions; + + /** + * @var bool + */ + private $convertNoticesToExceptions; + + /** + * @var bool + */ + private $convertWarningsToExceptions; + + /** + * @var bool + */ + private $forceCoversAnnotation; + + /** + * @var ?string + */ + private $bootstrap; + + /** + * @var bool + */ + private $processIsolation; + + /** + * @var bool + */ + private $failOnEmptyTestSuite; + + /** + * @var bool + */ + private $failOnIncomplete; + + /** + * @var bool + */ + private $failOnRisky; + + /** + * @var bool + */ + private $failOnSkipped; + + /** + * @var bool + */ + private $failOnWarning; + + /** + * @var bool + */ + private $stopOnDefect; + + /** + * @var bool + */ + private $stopOnError; + + /** + * @var bool + */ + private $stopOnFailure; + + /** + * @var bool + */ + private $stopOnWarning; + + /** + * @var bool + */ + private $stopOnIncomplete; + + /** + * @var bool + */ + private $stopOnRisky; + + /** + * @var bool + */ + private $stopOnSkipped; + + /** + * @var ?string + */ + private $extensionsDirectory; + + /** + * @var ?string + * + * @deprecated see https://github.com/sebastianbergmann/phpunit/issues/4039 + */ + private $testSuiteLoaderClass; + + /** + * @var ?string + * + * @deprecated see https://github.com/sebastianbergmann/phpunit/issues/4039 + */ + private $testSuiteLoaderFile; + + /** + * @var ?string + */ + private $printerClass; + + /** + * @var ?string + */ + private $printerFile; + + /** + * @var bool + */ + private $beStrictAboutChangesToGlobalState; + + /** + * @var bool + */ + private $beStrictAboutOutputDuringTests; + + /** + * @var bool + */ + private $beStrictAboutResourceUsageDuringSmallTests; + + /** + * @var bool + */ + private $beStrictAboutTestsThatDoNotTestAnything; + + /** + * @var bool + */ + private $beStrictAboutTodoAnnotatedTests; + + /** + * @var bool + */ + private $beStrictAboutCoversAnnotation; + + /** + * @var bool + */ + private $enforceTimeLimit; + + /** + * @var int + */ + private $defaultTimeLimit; + + /** + * @var int + */ + private $timeoutForSmallTests; + + /** + * @var int + */ + private $timeoutForMediumTests; + + /** + * @var int + */ + private $timeoutForLargeTests; + + /** + * @var ?string + */ + private $defaultTestSuite; + + /** + * @var int + */ + private $executionOrder; + + /** + * @var bool + */ + private $resolveDependencies; + + /** + * @var bool + */ + private $defectsFirst; + + /** + * @var bool + */ + private $backupGlobals; + + /** + * @var bool + */ + private $backupStaticAttributes; + + /** + * @var bool + */ + private $registerMockObjectsFromTestArgumentsRecursively; + + /** + * @var bool + */ + private $conflictBetweenPrinterClassAndTestdox; + + public function __construct(bool $cacheResult, ?string $cacheResultFile, $columns, string $colors, bool $stderr, bool $noInteraction, bool $verbose, bool $reverseDefectList, bool $convertDeprecationsToExceptions, bool $convertErrorsToExceptions, bool $convertNoticesToExceptions, bool $convertWarningsToExceptions, bool $forceCoversAnnotation, ?string $bootstrap, bool $processIsolation, bool $failOnEmptyTestSuite, bool $failOnIncomplete, bool $failOnRisky, bool $failOnSkipped, bool $failOnWarning, bool $stopOnDefect, bool $stopOnError, bool $stopOnFailure, bool $stopOnWarning, bool $stopOnIncomplete, bool $stopOnRisky, bool $stopOnSkipped, ?string $extensionsDirectory, ?string $testSuiteLoaderClass, ?string $testSuiteLoaderFile, ?string $printerClass, ?string $printerFile, bool $beStrictAboutChangesToGlobalState, bool $beStrictAboutOutputDuringTests, bool $beStrictAboutResourceUsageDuringSmallTests, bool $beStrictAboutTestsThatDoNotTestAnything, bool $beStrictAboutTodoAnnotatedTests, bool $beStrictAboutCoversAnnotation, bool $enforceTimeLimit, int $defaultTimeLimit, int $timeoutForSmallTests, int $timeoutForMediumTests, int $timeoutForLargeTests, ?string $defaultTestSuite, int $executionOrder, bool $resolveDependencies, bool $defectsFirst, bool $backupGlobals, bool $backupStaticAttributes, bool $registerMockObjectsFromTestArgumentsRecursively, bool $conflictBetweenPrinterClassAndTestdox) + { + $this->cacheResult = $cacheResult; + $this->cacheResultFile = $cacheResultFile; + $this->columns = $columns; + $this->colors = $colors; + $this->stderr = $stderr; + $this->noInteraction = $noInteraction; + $this->verbose = $verbose; + $this->reverseDefectList = $reverseDefectList; + $this->convertDeprecationsToExceptions = $convertDeprecationsToExceptions; + $this->convertErrorsToExceptions = $convertErrorsToExceptions; + $this->convertNoticesToExceptions = $convertNoticesToExceptions; + $this->convertWarningsToExceptions = $convertWarningsToExceptions; + $this->forceCoversAnnotation = $forceCoversAnnotation; + $this->bootstrap = $bootstrap; + $this->processIsolation = $processIsolation; + $this->failOnEmptyTestSuite = $failOnEmptyTestSuite; + $this->failOnIncomplete = $failOnIncomplete; + $this->failOnRisky = $failOnRisky; + $this->failOnSkipped = $failOnSkipped; + $this->failOnWarning = $failOnWarning; + $this->stopOnDefect = $stopOnDefect; + $this->stopOnError = $stopOnError; + $this->stopOnFailure = $stopOnFailure; + $this->stopOnWarning = $stopOnWarning; + $this->stopOnIncomplete = $stopOnIncomplete; + $this->stopOnRisky = $stopOnRisky; + $this->stopOnSkipped = $stopOnSkipped; + $this->extensionsDirectory = $extensionsDirectory; + $this->testSuiteLoaderClass = $testSuiteLoaderClass; + $this->testSuiteLoaderFile = $testSuiteLoaderFile; + $this->printerClass = $printerClass; + $this->printerFile = $printerFile; + $this->beStrictAboutChangesToGlobalState = $beStrictAboutChangesToGlobalState; + $this->beStrictAboutOutputDuringTests = $beStrictAboutOutputDuringTests; + $this->beStrictAboutResourceUsageDuringSmallTests = $beStrictAboutResourceUsageDuringSmallTests; + $this->beStrictAboutTestsThatDoNotTestAnything = $beStrictAboutTestsThatDoNotTestAnything; + $this->beStrictAboutTodoAnnotatedTests = $beStrictAboutTodoAnnotatedTests; + $this->beStrictAboutCoversAnnotation = $beStrictAboutCoversAnnotation; + $this->enforceTimeLimit = $enforceTimeLimit; + $this->defaultTimeLimit = $defaultTimeLimit; + $this->timeoutForSmallTests = $timeoutForSmallTests; + $this->timeoutForMediumTests = $timeoutForMediumTests; + $this->timeoutForLargeTests = $timeoutForLargeTests; + $this->defaultTestSuite = $defaultTestSuite; + $this->executionOrder = $executionOrder; + $this->resolveDependencies = $resolveDependencies; + $this->defectsFirst = $defectsFirst; + $this->backupGlobals = $backupGlobals; + $this->backupStaticAttributes = $backupStaticAttributes; + $this->registerMockObjectsFromTestArgumentsRecursively = $registerMockObjectsFromTestArgumentsRecursively; + $this->conflictBetweenPrinterClassAndTestdox = $conflictBetweenPrinterClassAndTestdox; + } + + public function cacheResult(): bool + { + return $this->cacheResult; + } + + /** + * @psalm-assert-if-true !null $this->cacheResultFile + */ + public function hasCacheResultFile(): bool + { + return $this->cacheResultFile !== null; + } + + /** + * @throws Exception + */ + public function cacheResultFile(): string + { + if (!$this->hasCacheResultFile()) { + throw new Exception('Cache result file is not configured'); + } + + return (string) $this->cacheResultFile; + } + + public function columns() + { + return $this->columns; + } + + public function colors(): string + { + return $this->colors; + } + + public function stderr(): bool + { + return $this->stderr; + } + + public function noInteraction(): bool + { + return $this->noInteraction; + } + + public function verbose(): bool + { + return $this->verbose; + } + + public function reverseDefectList(): bool + { + return $this->reverseDefectList; + } + + public function convertDeprecationsToExceptions(): bool + { + return $this->convertDeprecationsToExceptions; + } + + public function convertErrorsToExceptions(): bool + { + return $this->convertErrorsToExceptions; + } + + public function convertNoticesToExceptions(): bool + { + return $this->convertNoticesToExceptions; + } + + public function convertWarningsToExceptions(): bool + { + return $this->convertWarningsToExceptions; + } + + public function forceCoversAnnotation(): bool + { + return $this->forceCoversAnnotation; + } + + /** + * @psalm-assert-if-true !null $this->bootstrap + */ + public function hasBootstrap(): bool + { + return $this->bootstrap !== null; + } + + /** + * @throws Exception + */ + public function bootstrap(): string + { + if (!$this->hasBootstrap()) { + throw new Exception('Bootstrap script is not configured'); + } + + return (string) $this->bootstrap; + } + + public function processIsolation(): bool + { + return $this->processIsolation; + } + + public function failOnEmptyTestSuite(): bool + { + return $this->failOnEmptyTestSuite; + } + + public function failOnIncomplete(): bool + { + return $this->failOnIncomplete; + } + + public function failOnRisky(): bool + { + return $this->failOnRisky; + } + + public function failOnSkipped(): bool + { + return $this->failOnSkipped; + } + + public function failOnWarning(): bool + { + return $this->failOnWarning; + } + + public function stopOnDefect(): bool + { + return $this->stopOnDefect; + } + + public function stopOnError(): bool + { + return $this->stopOnError; + } + + public function stopOnFailure(): bool + { + return $this->stopOnFailure; + } + + public function stopOnWarning(): bool + { + return $this->stopOnWarning; + } + + public function stopOnIncomplete(): bool + { + return $this->stopOnIncomplete; + } + + public function stopOnRisky(): bool + { + return $this->stopOnRisky; + } + + public function stopOnSkipped(): bool + { + return $this->stopOnSkipped; + } + + /** + * @psalm-assert-if-true !null $this->extensionsDirectory + */ + public function hasExtensionsDirectory(): bool + { + return $this->extensionsDirectory !== null; + } + + /** + * @throws Exception + */ + public function extensionsDirectory(): string + { + if (!$this->hasExtensionsDirectory()) { + throw new Exception('Extensions directory is not configured'); + } + + return (string) $this->extensionsDirectory; + } + + /** + * @psalm-assert-if-true !null $this->testSuiteLoaderClass + * + * @deprecated see https://github.com/sebastianbergmann/phpunit/issues/4039 + */ + public function hasTestSuiteLoaderClass(): bool + { + return $this->testSuiteLoaderClass !== null; + } + + /** + * @throws Exception + * + * @deprecated see https://github.com/sebastianbergmann/phpunit/issues/4039 + */ + public function testSuiteLoaderClass(): string + { + if (!$this->hasTestSuiteLoaderClass()) { + throw new Exception('TestSuiteLoader class is not configured'); + } + + return (string) $this->testSuiteLoaderClass; + } + + /** + * @psalm-assert-if-true !null $this->testSuiteLoaderFile + * + * @deprecated see https://github.com/sebastianbergmann/phpunit/issues/4039 + */ + public function hasTestSuiteLoaderFile(): bool + { + return $this->testSuiteLoaderFile !== null; + } + + /** + * @throws Exception + * + * @deprecated see https://github.com/sebastianbergmann/phpunit/issues/4039 + */ + public function testSuiteLoaderFile(): string + { + if (!$this->hasTestSuiteLoaderFile()) { + throw new Exception('TestSuiteLoader sourcecode file is not configured'); + } + + return (string) $this->testSuiteLoaderFile; + } + + /** + * @psalm-assert-if-true !null $this->printerClass + */ + public function hasPrinterClass(): bool + { + return $this->printerClass !== null; + } + + /** + * @throws Exception + */ + public function printerClass(): string + { + if (!$this->hasPrinterClass()) { + throw new Exception('ResultPrinter class is not configured'); + } + + return (string) $this->printerClass; + } + + /** + * @psalm-assert-if-true !null $this->printerFile + */ + public function hasPrinterFile(): bool + { + return $this->printerFile !== null; + } + + /** + * @throws Exception + */ + public function printerFile(): string + { + if (!$this->hasPrinterFile()) { + throw new Exception('ResultPrinter sourcecode file is not configured'); + } + + return (string) $this->printerFile; + } + + public function beStrictAboutChangesToGlobalState(): bool + { + return $this->beStrictAboutChangesToGlobalState; + } + + public function beStrictAboutOutputDuringTests(): bool + { + return $this->beStrictAboutOutputDuringTests; + } + + public function beStrictAboutResourceUsageDuringSmallTests(): bool + { + return $this->beStrictAboutResourceUsageDuringSmallTests; + } + + public function beStrictAboutTestsThatDoNotTestAnything(): bool + { + return $this->beStrictAboutTestsThatDoNotTestAnything; + } + + public function beStrictAboutTodoAnnotatedTests(): bool + { + return $this->beStrictAboutTodoAnnotatedTests; + } + + public function beStrictAboutCoversAnnotation(): bool + { + return $this->beStrictAboutCoversAnnotation; + } + + public function enforceTimeLimit(): bool + { + return $this->enforceTimeLimit; + } + + public function defaultTimeLimit(): int + { + return $this->defaultTimeLimit; + } + + public function timeoutForSmallTests(): int + { + return $this->timeoutForSmallTests; + } + + public function timeoutForMediumTests(): int + { + return $this->timeoutForMediumTests; + } + + public function timeoutForLargeTests(): int + { + return $this->timeoutForLargeTests; + } + + /** + * @psalm-assert-if-true !null $this->defaultTestSuite + */ + public function hasDefaultTestSuite(): bool + { + return $this->defaultTestSuite !== null; + } + + /** + * @throws Exception + */ + public function defaultTestSuite(): string + { + if (!$this->hasDefaultTestSuite()) { + throw new Exception('Default test suite is not configured'); + } + + return (string) $this->defaultTestSuite; + } + + public function executionOrder(): int + { + return $this->executionOrder; + } + + public function resolveDependencies(): bool + { + return $this->resolveDependencies; + } + + public function defectsFirst(): bool + { + return $this->defectsFirst; + } + + public function backupGlobals(): bool + { + return $this->backupGlobals; + } + + public function backupStaticAttributes(): bool + { + return $this->backupStaticAttributes; + } + + public function registerMockObjectsFromTestArgumentsRecursively(): bool + { + return $this->registerMockObjectsFromTestArgumentsRecursively; + } + + public function conflictBetweenPrinterClassAndTestdox(): bool + { + return $this->conflictBetweenPrinterClassAndTestdox; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestDirectory.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestDirectory.php new file mode 100644 index 000000000..263d02ea9 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestDirectory.php @@ -0,0 +1,78 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use PHPUnit\Util\VersionComparisonOperator; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class TestDirectory +{ + /** + * @var string + */ + private $path; + + /** + * @var string + */ + private $prefix; + + /** + * @var string + */ + private $suffix; + + /** + * @var string + */ + private $phpVersion; + + /** + * @var VersionComparisonOperator + */ + private $phpVersionOperator; + + public function __construct(string $path, string $prefix, string $suffix, string $phpVersion, VersionComparisonOperator $phpVersionOperator) + { + $this->path = $path; + $this->prefix = $prefix; + $this->suffix = $suffix; + $this->phpVersion = $phpVersion; + $this->phpVersionOperator = $phpVersionOperator; + } + + public function path(): string + { + return $this->path; + } + + public function prefix(): string + { + return $this->prefix; + } + + public function suffix(): string + { + return $this->suffix; + } + + public function phpVersion(): string + { + return $this->phpVersion; + } + + public function phpVersionOperator(): VersionComparisonOperator + { + return $this->phpVersionOperator; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestDirectoryCollection.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestDirectoryCollection.php new file mode 100644 index 000000000..10111af05 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestDirectoryCollection.php @@ -0,0 +1,62 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function count; +use Countable; +use IteratorAggregate; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class TestDirectoryCollection implements Countable, IteratorAggregate +{ + /** + * @var TestDirectory[] + */ + private $directories; + + /** + * @param TestDirectory[] $directories + */ + public static function fromArray(array $directories): self + { + return new self(...$directories); + } + + private function __construct(TestDirectory ...$directories) + { + $this->directories = $directories; + } + + /** + * @return TestDirectory[] + */ + public function asArray(): array + { + return $this->directories; + } + + public function count(): int + { + return count($this->directories); + } + + public function getIterator(): TestDirectoryCollectionIterator + { + return new TestDirectoryCollectionIterator($this); + } + + public function isEmpty(): bool + { + return $this->count() === 0; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestDirectoryCollectionIterator.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestDirectoryCollectionIterator.php new file mode 100644 index 000000000..11a48a247 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestDirectoryCollectionIterator.php @@ -0,0 +1,66 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function count; +use function iterator_count; +use Countable; +use Iterator; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class TestDirectoryCollectionIterator implements Countable, Iterator +{ + /** + * @var TestDirectory[] + */ + private $directories; + + /** + * @var int + */ + private $position; + + public function __construct(TestDirectoryCollection $directories) + { + $this->directories = $directories->asArray(); + } + + public function count(): int + { + return iterator_count($this); + } + + public function rewind(): void + { + $this->position = 0; + } + + public function valid(): bool + { + return $this->position < count($this->directories); + } + + public function key(): int + { + return $this->position; + } + + public function current(): TestDirectory + { + return $this->directories[$this->position]; + } + + public function next(): void + { + $this->position++; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestFile.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestFile.php new file mode 100644 index 000000000..2e69450c1 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestFile.php @@ -0,0 +1,56 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use PHPUnit\Util\VersionComparisonOperator; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class TestFile +{ + /** + * @var string + */ + private $path; + + /** + * @var string + */ + private $phpVersion; + + /** + * @var VersionComparisonOperator + */ + private $phpVersionOperator; + + public function __construct(string $path, string $phpVersion, VersionComparisonOperator $phpVersionOperator) + { + $this->path = $path; + $this->phpVersion = $phpVersion; + $this->phpVersionOperator = $phpVersionOperator; + } + + public function path(): string + { + return $this->path; + } + + public function phpVersion(): string + { + return $this->phpVersion; + } + + public function phpVersionOperator(): VersionComparisonOperator + { + return $this->phpVersionOperator; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestFileCollection.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestFileCollection.php new file mode 100644 index 000000000..791ddf718 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestFileCollection.php @@ -0,0 +1,62 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function count; +use Countable; +use IteratorAggregate; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class TestFileCollection implements Countable, IteratorAggregate +{ + /** + * @var TestFile[] + */ + private $files; + + /** + * @param TestFile[] $files + */ + public static function fromArray(array $files): self + { + return new self(...$files); + } + + private function __construct(TestFile ...$files) + { + $this->files = $files; + } + + /** + * @return TestFile[] + */ + public function asArray(): array + { + return $this->files; + } + + public function count(): int + { + return count($this->files); + } + + public function getIterator(): TestFileCollectionIterator + { + return new TestFileCollectionIterator($this); + } + + public function isEmpty(): bool + { + return $this->count() === 0; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestFileCollectionIterator.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestFileCollectionIterator.php new file mode 100644 index 000000000..b44c36894 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestFileCollectionIterator.php @@ -0,0 +1,66 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function count; +use function iterator_count; +use Countable; +use Iterator; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class TestFileCollectionIterator implements Countable, Iterator +{ + /** + * @var TestFile[] + */ + private $files; + + /** + * @var int + */ + private $position; + + public function __construct(TestFileCollection $files) + { + $this->files = $files->asArray(); + } + + public function count(): int + { + return iterator_count($this); + } + + public function rewind(): void + { + $this->position = 0; + } + + public function valid(): bool + { + return $this->position < count($this->files); + } + + public function key(): int + { + return $this->position; + } + + public function current(): TestFile + { + return $this->files[$this->position]; + } + + public function next(): void + { + $this->position++; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestSuite.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestSuite.php new file mode 100644 index 000000000..4a6098215 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestSuite.php @@ -0,0 +1,65 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class TestSuite +{ + /** + * @var string + */ + private $name; + + /** + * @var TestDirectoryCollection + */ + private $directories; + + /** + * @var TestFileCollection + */ + private $files; + + /** + * @var FileCollection + */ + private $exclude; + + public function __construct(string $name, TestDirectoryCollection $directories, TestFileCollection $files, FileCollection $exclude) + { + $this->name = $name; + $this->directories = $directories; + $this->files = $files; + $this->exclude = $exclude; + } + + public function name(): string + { + return $this->name; + } + + public function directories(): TestDirectoryCollection + { + return $this->directories; + } + + public function files(): TestFileCollection + { + return $this->files; + } + + public function exclude(): FileCollection + { + return $this->exclude; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestSuiteCollection.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestSuiteCollection.php new file mode 100644 index 000000000..124609d74 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestSuiteCollection.php @@ -0,0 +1,62 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function count; +use Countable; +use IteratorAggregate; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @psalm-immutable + */ +final class TestSuiteCollection implements Countable, IteratorAggregate +{ + /** + * @var TestSuite[] + */ + private $testSuites; + + /** + * @param TestSuite[] $testSuites + */ + public static function fromArray(array $testSuites): self + { + return new self(...$testSuites); + } + + private function __construct(TestSuite ...$testSuites) + { + $this->testSuites = $testSuites; + } + + /** + * @return TestSuite[] + */ + public function asArray(): array + { + return $this->testSuites; + } + + public function count(): int + { + return count($this->testSuites); + } + + public function getIterator(): TestSuiteCollectionIterator + { + return new TestSuiteCollectionIterator($this); + } + + public function isEmpty(): bool + { + return $this->count() === 0; + } +} diff --git a/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestSuiteCollectionIterator.php b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestSuiteCollectionIterator.php new file mode 100644 index 000000000..33b0f8495 --- /dev/null +++ b/vendor/phpunit/phpunit/src/TextUI/XmlConfiguration/TestSuite/TestSuiteCollectionIterator.php @@ -0,0 +1,66 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\TextUI\XmlConfiguration; + +use function count; +use function iterator_count; +use Countable; +use Iterator; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class TestSuiteCollectionIterator implements Countable, Iterator +{ + /** + * @var TestSuite[] + */ + private $testSuites; + + /** + * @var int + */ + private $position; + + public function __construct(TestSuiteCollection $testSuites) + { + $this->testSuites = $testSuites->asArray(); + } + + public function count(): int + { + return iterator_count($this); + } + + public function rewind(): void + { + $this->position = 0; + } + + public function valid(): bool + { + return $this->position < count($this->testSuites); + } + + public function key(): int + { + return $this->position; + } + + public function current(): TestSuite + { + return $this->testSuites[$this->position]; + } + + public function next(): void + { + $this->position++; + } +} diff --git a/vendor/phpunit/phpunit/src/Util/Annotation/DocBlock.php b/vendor/phpunit/phpunit/src/Util/Annotation/DocBlock.php index 024c19b11..83d741e6b 100644 --- a/vendor/phpunit/phpunit/src/Util/Annotation/DocBlock.php +++ b/vendor/phpunit/phpunit/src/Util/Annotation/DocBlock.php @@ -18,16 +18,12 @@ use function array_merge; use function array_pop; use function array_slice; use function array_values; -use function constant; use function count; -use function defined; use function explode; use function file; use function implode; use function is_array; use function is_int; -use function is_numeric; -use function is_string; use function json_decode; use function json_last_error; use function json_last_error_msg; @@ -43,7 +39,6 @@ use function strlen; use function strpos; use function strtolower; use function substr; -use function substr_count; use function trim; use PharIo\Version\VersionConstraintParser; use PHPUnit\Framework\InvalidDataProviderException; @@ -84,8 +79,6 @@ final class DocBlock private const REGEX_TEST_WITH = '/@testWith\s+/'; - private const REGEX_EXPECTED_EXCEPTION = '(@expectedException\s+([:.\w\\\\x7f-\xff]+)(?:[\t ]+(\S*))?(?:[\t ]+(\S*))?\s*$)m'; - /** @var string */ private $docComment; @@ -239,7 +232,6 @@ final class DocBlock ]; $recordedOffsets[$matches['name'] . '_constraint'] = $offset; } catch (\PharIo\Version\Exception $e) { - /* @TODO this catch is currently not valid, see https://github.com/phar-io/version/issues/16 */ throw new Warning($e->getMessage(), $e->getCode(), $e); } } @@ -280,61 +272,6 @@ final class DocBlock ); } - /** - * @return array|bool - * - * @psalm-return false|array{ - * class: class-string, - * code: int|string|null, - * message: string, - * message_regex: string - * } - */ - public function expectedException() - { - $docComment = (string) substr($this->docComment, 3, -2); - - if (1 !== preg_match(self::REGEX_EXPECTED_EXCEPTION, $docComment, $matches)) { - return false; - } - - /** @psalm-var class-string $class */ - $class = $matches[1]; - $annotations = $this->symbolAnnotations(); - $code = null; - $message = ''; - $messageRegExp = ''; - - if (isset($matches[2])) { - $message = trim($matches[2]); - } elseif (isset($annotations['expectedExceptionMessage'])) { - $message = $this->parseAnnotationContent($annotations['expectedExceptionMessage'][0]); - } - - if (isset($annotations['expectedExceptionMessageRegExp'])) { - $messageRegExp = $this->parseAnnotationContent($annotations['expectedExceptionMessageRegExp'][0]); - } - - if (isset($matches[3])) { - $code = $matches[3]; - } elseif (isset($annotations['expectedExceptionCode'])) { - $code = $this->parseAnnotationContent($annotations['expectedExceptionCode'][0]); - } - - if (is_numeric($code)) { - $code = (int) $code; - } elseif (is_string($code) && defined($code)) { - $code = (int) constant($code); - } - - return [ - 'class' => $class, - 'code' => $code, - 'message' => $message, - 'message_regex' => $messageRegExp, - ]; - } - /** * Returns the provided data for a method. * @@ -420,21 +357,14 @@ final class DocBlock return 1 === preg_match('/@after\b/', $this->docComment); } - /** - * Parse annotation content to use constant/class constant values. - * - * Constants are specified using a starting '@'. For example: @ClassName::CONST_NAME - * - * If the constant is not found the string is used as is to ensure maximum BC. - */ - private function parseAnnotationContent(string $message): string + public function isToBeExecutedAsPreCondition(): bool { - if (defined($message) && - (strpos($message, '::') !== false && substr_count($message, '::') + 1 === 2)) { - return constant($message); - } + return 1 === preg_match('/@preCondition\b/', $this->docComment); + } - return $message; + public function isToBeExecutedAsPostCondition(): bool + { + return 1 === preg_match('/@postCondition\b/', $this->docComment); } private function getDataFromDataProviderAnnotation(string $docComment): ?array diff --git a/vendor/phpunit/phpunit/src/Util/Blacklist.php b/vendor/phpunit/phpunit/src/Util/Blacklist.php index dd89dcd55..3b416e142 100644 --- a/vendor/phpunit/phpunit/src/Util/Blacklist.php +++ b/vendor/phpunit/phpunit/src/Util/Blacklist.php @@ -9,145 +9,17 @@ */ namespace PHPUnit\Util; -use const DIRECTORY_SEPARATOR; -use function class_exists; -use function defined; -use function dirname; -use function strpos; -use function sys_get_temp_dir; -use Composer\Autoload\ClassLoader; -use DeepCopy\DeepCopy; -use Doctrine\Instantiator\Instantiator; -use PharIo\Manifest\Manifest; -use PharIo\Version\Version as PharIoVersion; -use PHP_Token; -use phpDocumentor\Reflection\DocBlock; -use phpDocumentor\Reflection\Project; -use phpDocumentor\Reflection\Type; -use PHPUnit\Framework\TestCase; -use Prophecy\Prophet; -use ReflectionClass; -use ReflectionException; -use SebastianBergmann\CodeCoverage\CodeCoverage; -use SebastianBergmann\CodeUnitReverseLookup\Wizard; -use SebastianBergmann\Comparator\Comparator; -use SebastianBergmann\Diff\Diff; -use SebastianBergmann\Environment\Runtime; -use SebastianBergmann\Exporter\Exporter; -use SebastianBergmann\FileIterator\Facade as FileIteratorFacade; -use SebastianBergmann\GlobalState\Snapshot; -use SebastianBergmann\Invoker\Invoker; -use SebastianBergmann\ObjectEnumerator\Enumerator; -use SebastianBergmann\RecursionContext\Context; -use SebastianBergmann\ResourceOperations\ResourceOperations; -use SebastianBergmann\Timer\Timer; -use SebastianBergmann\Type\TypeName; -use SebastianBergmann\Version; -use Text_Template; -use TheSeer\Tokenizer\Tokenizer; -use Webmozart\Assert\Assert; - /** - * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @deprecated Use ExcludeList instead + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class Blacklist { - /** - * @var array - */ - public static $blacklistedClassNames = [ - // composer - ClassLoader::class => 1, - - // doctrine/instantiator - Instantiator::class => 1, - - // myclabs/deepcopy - DeepCopy::class => 1, - - // phar-io/manifest - Manifest::class => 1, - - // phar-io/version - PharIoVersion::class => 1, - - // phpdocumentor/reflection-common - Project::class => 1, - - // phpdocumentor/reflection-docblock - DocBlock::class => 1, - - // phpdocumentor/type-resolver - Type::class => 1, - - // phpspec/prophecy - Prophet::class => 1, - - // phpunit/phpunit - TestCase::class => 2, - - // phpunit/php-code-coverage - CodeCoverage::class => 1, - - // phpunit/php-file-iterator - FileIteratorFacade::class => 1, - - // phpunit/php-invoker - Invoker::class => 1, - - // phpunit/php-text-template - Text_Template::class => 1, - - // phpunit/php-timer - Timer::class => 1, - - // phpunit/php-token-stream - PHP_Token::class => 1, - - // sebastian/code-unit-reverse-lookup - Wizard::class => 1, - - // sebastian/comparator - Comparator::class => 1, - - // sebastian/diff - Diff::class => 1, - - // sebastian/environment - Runtime::class => 1, - - // sebastian/exporter - Exporter::class => 1, - - // sebastian/global-state - Snapshot::class => 1, - - // sebastian/object-enumerator - Enumerator::class => 1, - - // sebastian/recursion-context - Context::class => 1, - - // sebastian/resource-operations - ResourceOperations::class => 1, - - // sebastian/type - TypeName::class => 1, - - // sebastian/version - Version::class => 1, - - // theseer/tokenizer - Tokenizer::class => 1, - - // webmozart/assert - Assert::class => 1, - ]; - - /** - * @var string[] - */ - private static $directories; + public static function addDirectory(string $directory): void + { + ExcludeList::addDirectory($directory); + } /** * @throws Exception @@ -156,9 +28,7 @@ final class Blacklist */ public function getBlacklistedDirectories(): array { - $this->initialize(); - - return self::$directories; + return (new ExcludeList)->getExcludedDirectories(); } /** @@ -166,59 +36,6 @@ final class Blacklist */ public function isBlacklisted(string $file): bool { - if (defined('PHPUNIT_TESTSUITE')) { - return false; - } - - $this->initialize(); - - foreach (self::$directories as $directory) { - if (strpos($file, $directory) === 0) { - return true; - } - } - - return false; - } - - /** - * @throws Exception - */ - private function initialize(): void - { - if (self::$directories === null) { - self::$directories = []; - - foreach (self::$blacklistedClassNames as $className => $parent) { - if (!class_exists($className)) { - continue; - } - - try { - $directory = (new ReflectionClass($className))->getFileName(); - // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new Exception( - $e->getMessage(), - (int) $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - - for ($i = 0; $i < $parent; $i++) { - $directory = dirname($directory); - } - - self::$directories[] = $directory; - } - - // Hide process isolation workaround on Windows. - if (DIRECTORY_SEPARATOR === '\\') { - // tempnam() prefix is limited to first 3 chars. - // @see https://php.net/manual/en/function.tempnam.php - self::$directories[] = sys_get_temp_dir() . '\\PHP'; - } - } + return (new ExcludeList)->isExcluded($file); } } diff --git a/vendor/phpunit/phpunit/src/Util/Configuration.php b/vendor/phpunit/phpunit/src/Util/Configuration.php deleted file mode 100644 index dfc4e241f..000000000 --- a/vendor/phpunit/phpunit/src/Util/Configuration.php +++ /dev/null @@ -1,1231 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace PHPUnit\Util; - -use const DIRECTORY_SEPARATOR; -use const PATH_SEPARATOR; -use const PHP_VERSION; -use function assert; -use function constant; -use function count; -use function define; -use function defined; -use function dirname; -use function explode; -use function file_exists; -use function file_get_contents; -use function getenv; -use function implode; -use function in_array; -use function ini_get; -use function ini_set; -use function is_numeric; -use function libxml_clear_errors; -use function libxml_get_errors; -use function libxml_use_internal_errors; -use function preg_match; -use function putenv; -use function realpath; -use function sprintf; -use function stream_resolve_include_path; -use function strlen; -use function strpos; -use function strtolower; -use function strtoupper; -use function substr; -use function trim; -use function version_compare; -use DOMDocument; -use DOMElement; -use DOMNodeList; -use DOMXPath; -use LibXMLError; -use PHPUnit\Framework\Exception; -use PHPUnit\Framework\TestSuite; -use PHPUnit\Runner\TestSuiteSorter; -use PHPUnit\TextUI\ResultPrinter; -use PHPUnit\Util\TestDox\CliTestDoxPrinter; -use SebastianBergmann\FileIterator\Facade as FileIteratorFacade; - -/** - * @internal This class is not covered by the backward compatibility promise for PHPUnit - */ -final class Configuration -{ - /** - * @var self[] - */ - private static $instances = []; - - /** - * @var DOMDocument - */ - private $document; - - /** - * @var DOMXPath - */ - private $xpath; - - /** - * @var string - */ - private $filename; - - /** - * @var LibXMLError[] - */ - private $errors = []; - - /** - * Returns a PHPUnit configuration object. - * - * @throws Exception - */ - public static function getInstance(string $filename): self - { - $realPath = realpath($filename); - - if ($realPath === false) { - throw new Exception( - sprintf( - 'Could not read "%s".', - $filename - ) - ); - } - - if (!isset(self::$instances[$realPath])) { - self::$instances[$realPath] = new self($realPath); - } - - return self::$instances[$realPath]; - } - - /** - * Loads a PHPUnit configuration file. - * - * @throws Exception - */ - private function __construct(string $filename) - { - $this->filename = $filename; - $this->document = Xml::loadFile($filename, false, true, true); - $this->xpath = new DOMXPath($this->document); - - $this->validateConfigurationAgainstSchema(); - } - - /** - * @codeCoverageIgnore - */ - private function __clone() - { - } - - public function hasValidationErrors(): bool - { - return count($this->errors) > 0; - } - - public function getValidationErrors(): array - { - $result = []; - - foreach ($this->errors as $error) { - if (!isset($result[$error->line])) { - $result[$error->line] = []; - } - $result[$error->line][] = trim($error->message); - } - - return $result; - } - - /** - * Returns the real path to the configuration file. - */ - public function getFilename(): string - { - return $this->filename; - } - - public function getExtensionConfiguration(): array - { - $result = []; - - foreach ($this->xpath->query('extensions/extension') as $extension) { - $result[] = $this->getElementConfigurationParameters($extension); - } - - return $result; - } - - /** - * Returns the configuration for SUT filtering. - */ - public function getFilterConfiguration(): array - { - $addUncoveredFilesFromWhitelist = true; - $processUncoveredFilesFromWhitelist = false; - $includeDirectory = []; - $includeFile = []; - $excludeDirectory = []; - $excludeFile = []; - - $tmp = $this->xpath->query('filter/whitelist'); - - if ($tmp->length === 1) { - if ($tmp->item(0)->hasAttribute('addUncoveredFilesFromWhitelist')) { - $addUncoveredFilesFromWhitelist = $this->getBoolean( - (string) $tmp->item(0)->getAttribute( - 'addUncoveredFilesFromWhitelist' - ), - true - ); - } - - if ($tmp->item(0)->hasAttribute('processUncoveredFilesFromWhitelist')) { - $processUncoveredFilesFromWhitelist = $this->getBoolean( - (string) $tmp->item(0)->getAttribute( - 'processUncoveredFilesFromWhitelist' - ), - false - ); - } - - $includeDirectory = $this->readFilterDirectories( - 'filter/whitelist/directory' - ); - - $includeFile = $this->readFilterFiles( - 'filter/whitelist/file' - ); - - $excludeDirectory = $this->readFilterDirectories( - 'filter/whitelist/exclude/directory' - ); - - $excludeFile = $this->readFilterFiles( - 'filter/whitelist/exclude/file' - ); - } - - return [ - 'whitelist' => [ - 'addUncoveredFilesFromWhitelist' => $addUncoveredFilesFromWhitelist, - 'processUncoveredFilesFromWhitelist' => $processUncoveredFilesFromWhitelist, - 'include' => [ - 'directory' => $includeDirectory, - 'file' => $includeFile, - ], - 'exclude' => [ - 'directory' => $excludeDirectory, - 'file' => $excludeFile, - ], - ], - ]; - } - - /** - * Returns the configuration for groups. - */ - public function getGroupConfiguration(): array - { - return $this->parseGroupConfiguration('groups'); - } - - /** - * Returns the configuration for testdox groups. - */ - public function getTestdoxGroupConfiguration(): array - { - return $this->parseGroupConfiguration('testdoxGroups'); - } - - /** - * Returns the configuration for listeners. - */ - public function getListenerConfiguration(): array - { - $result = []; - - foreach ($this->xpath->query('listeners/listener') as $listener) { - $result[] = $this->getElementConfigurationParameters($listener); - } - - return $result; - } - - /** - * Returns the logging configuration. - */ - public function getLoggingConfiguration(): array - { - $result = []; - - foreach ($this->xpath->query('logging/log') as $log) { - assert($log instanceof DOMElement); - - $type = (string) $log->getAttribute('type'); - $target = (string) $log->getAttribute('target'); - - if (!$target) { - continue; - } - - $target = $this->toAbsolutePath($target); - - if ($type === 'coverage-html') { - if ($log->hasAttribute('lowUpperBound')) { - $result['lowUpperBound'] = $this->getInteger( - (string) $log->getAttribute('lowUpperBound'), - 50 - ); - } - - if ($log->hasAttribute('highLowerBound')) { - $result['highLowerBound'] = $this->getInteger( - (string) $log->getAttribute('highLowerBound'), - 90 - ); - } - } elseif ($type === 'coverage-crap4j') { - if ($log->hasAttribute('threshold')) { - $result['crap4jThreshold'] = $this->getInteger( - (string) $log->getAttribute('threshold'), - 30 - ); - } - } elseif ($type === 'coverage-text') { - if ($log->hasAttribute('showUncoveredFiles')) { - $result['coverageTextShowUncoveredFiles'] = $this->getBoolean( - (string) $log->getAttribute('showUncoveredFiles'), - false - ); - } - - if ($log->hasAttribute('showOnlySummary')) { - $result['coverageTextShowOnlySummary'] = $this->getBoolean( - (string) $log->getAttribute('showOnlySummary'), - false - ); - } - } - - $result[$type] = $target; - } - - return $result; - } - - /** - * Returns the PHP configuration. - */ - public function getPHPConfiguration(): array - { - $result = [ - 'include_path' => [], - 'ini' => [], - 'const' => [], - 'var' => [], - 'env' => [], - 'post' => [], - 'get' => [], - 'cookie' => [], - 'server' => [], - 'files' => [], - 'request' => [], - ]; - - foreach ($this->xpath->query('php/includePath') as $includePath) { - $path = (string) $includePath->textContent; - - if ($path) { - $result['include_path'][] = $this->toAbsolutePath($path); - } - } - - foreach ($this->xpath->query('php/ini') as $ini) { - assert($ini instanceof DOMElement); - - $name = (string) $ini->getAttribute('name'); - $value = (string) $ini->getAttribute('value'); - - $result['ini'][$name]['value'] = $value; - } - - foreach ($this->xpath->query('php/const') as $const) { - assert($const instanceof DOMElement); - - $name = (string) $const->getAttribute('name'); - $value = (string) $const->getAttribute('value'); - - $result['const'][$name]['value'] = $this->getBoolean($value, $value); - } - - foreach (['var', 'env', 'post', 'get', 'cookie', 'server', 'files', 'request'] as $array) { - foreach ($this->xpath->query('php/' . $array) as $var) { - assert($var instanceof DOMElement); - - $name = (string) $var->getAttribute('name'); - $value = (string) $var->getAttribute('value'); - $verbatim = false; - - if ($var->hasAttribute('verbatim')) { - $verbatim = $this->getBoolean($var->getAttribute('verbatim'), false); - $result[$array][$name]['verbatim'] = $verbatim; - } - - if ($var->hasAttribute('force')) { - $force = $this->getBoolean($var->getAttribute('force'), false); - $result[$array][$name]['force'] = $force; - } - - if (!$verbatim) { - $value = $this->getBoolean($value, $value); - } - - $result[$array][$name]['value'] = $value; - } - } - - return $result; - } - - /** - * Handles the PHP configuration. - */ - public function handlePHPConfiguration(): void - { - $configuration = $this->getPHPConfiguration(); - - if (!empty($configuration['include_path'])) { - ini_set( - 'include_path', - implode(PATH_SEPARATOR, $configuration['include_path']) . - PATH_SEPARATOR . - ini_get('include_path') - ); - } - - foreach ($configuration['ini'] as $name => $data) { - $value = $data['value']; - - if (defined($value)) { - $value = (string) constant($value); - } - - ini_set($name, $value); - } - - foreach ($configuration['const'] as $name => $data) { - $value = $data['value']; - - if (!defined($name)) { - define($name, $value); - } - } - - foreach ($configuration['var'] as $name => $data) { - $GLOBALS[$name] = $data['value']; - } - - foreach ($configuration['server'] as $name => $data) { - $_SERVER[$name] = $data['value']; - } - - foreach (['post', 'get', 'cookie', 'files', 'request'] as $array) { - $target = &$GLOBALS['_' . strtoupper($array)]; - - foreach ($configuration[$array] as $name => $data) { - $target[$name] = $data['value']; - } - } - - foreach ($configuration['env'] as $name => $data) { - $value = $data['value']; - $force = $data['force'] ?? false; - - if ($force || getenv($name) === false) { - putenv("{$name}={$value}"); - } - - $value = getenv($name); - - if (!isset($_ENV[$name])) { - $_ENV[$name] = $value; - } - - if ($force) { - $_ENV[$name] = $value; - } - } - } - - /** - * Returns the PHPUnit configuration. - */ - public function getPHPUnitConfiguration(): array - { - $result = []; - $root = $this->document->documentElement; - - if ($root->hasAttribute('cacheTokens')) { - $result['cacheTokens'] = $this->getBoolean( - (string) $root->getAttribute('cacheTokens'), - false - ); - } - - if ($root->hasAttribute('columns')) { - $columns = (string) $root->getAttribute('columns'); - - if ($columns === 'max') { - $result['columns'] = 'max'; - } else { - $result['columns'] = $this->getInteger($columns, 80); - } - } - - if ($root->hasAttribute('colors')) { - /* only allow boolean for compatibility with previous versions - 'always' only allowed from command line */ - if ($this->getBoolean($root->getAttribute('colors'), false)) { - $result['colors'] = ResultPrinter::COLOR_AUTO; - } else { - $result['colors'] = ResultPrinter::COLOR_NEVER; - } - } - - /* - * @see https://github.com/sebastianbergmann/phpunit/issues/657 - */ - if ($root->hasAttribute('stderr')) { - $result['stderr'] = $this->getBoolean( - (string) $root->getAttribute('stderr'), - false - ); - } - - if ($root->hasAttribute('backupGlobals')) { - $result['backupGlobals'] = $this->getBoolean( - (string) $root->getAttribute('backupGlobals'), - false - ); - } - - if ($root->hasAttribute('backupStaticAttributes')) { - $result['backupStaticAttributes'] = $this->getBoolean( - (string) $root->getAttribute('backupStaticAttributes'), - false - ); - } - - if ($root->getAttribute('bootstrap')) { - $result['bootstrap'] = $this->toAbsolutePath( - (string) $root->getAttribute('bootstrap') - ); - } - - if ($root->hasAttribute('convertDeprecationsToExceptions')) { - $result['convertDeprecationsToExceptions'] = $this->getBoolean( - (string) $root->getAttribute('convertDeprecationsToExceptions'), - true - ); - } - - if ($root->hasAttribute('convertErrorsToExceptions')) { - $result['convertErrorsToExceptions'] = $this->getBoolean( - (string) $root->getAttribute('convertErrorsToExceptions'), - true - ); - } - - if ($root->hasAttribute('convertNoticesToExceptions')) { - $result['convertNoticesToExceptions'] = $this->getBoolean( - (string) $root->getAttribute('convertNoticesToExceptions'), - true - ); - } - - if ($root->hasAttribute('convertWarningsToExceptions')) { - $result['convertWarningsToExceptions'] = $this->getBoolean( - (string) $root->getAttribute('convertWarningsToExceptions'), - true - ); - } - - if ($root->hasAttribute('forceCoversAnnotation')) { - $result['forceCoversAnnotation'] = $this->getBoolean( - (string) $root->getAttribute('forceCoversAnnotation'), - false - ); - } - - if ($root->hasAttribute('disableCodeCoverageIgnore')) { - $result['disableCodeCoverageIgnore'] = $this->getBoolean( - (string) $root->getAttribute('disableCodeCoverageIgnore'), - false - ); - } - - if ($root->hasAttribute('processIsolation')) { - $result['processIsolation'] = $this->getBoolean( - (string) $root->getAttribute('processIsolation'), - false - ); - } - - if ($root->hasAttribute('stopOnDefect')) { - $result['stopOnDefect'] = $this->getBoolean( - (string) $root->getAttribute('stopOnDefect'), - false - ); - } - - if ($root->hasAttribute('stopOnError')) { - $result['stopOnError'] = $this->getBoolean( - (string) $root->getAttribute('stopOnError'), - false - ); - } - - if ($root->hasAttribute('stopOnFailure')) { - $result['stopOnFailure'] = $this->getBoolean( - (string) $root->getAttribute('stopOnFailure'), - false - ); - } - - if ($root->hasAttribute('stopOnWarning')) { - $result['stopOnWarning'] = $this->getBoolean( - (string) $root->getAttribute('stopOnWarning'), - false - ); - } - - if ($root->hasAttribute('stopOnIncomplete')) { - $result['stopOnIncomplete'] = $this->getBoolean( - (string) $root->getAttribute('stopOnIncomplete'), - false - ); - } - - if ($root->hasAttribute('stopOnRisky')) { - $result['stopOnRisky'] = $this->getBoolean( - (string) $root->getAttribute('stopOnRisky'), - false - ); - } - - if ($root->hasAttribute('stopOnSkipped')) { - $result['stopOnSkipped'] = $this->getBoolean( - (string) $root->getAttribute('stopOnSkipped'), - false - ); - } - - if ($root->hasAttribute('failOnWarning')) { - $result['failOnWarning'] = $this->getBoolean( - (string) $root->getAttribute('failOnWarning'), - false - ); - } - - if ($root->hasAttribute('failOnRisky')) { - $result['failOnRisky'] = $this->getBoolean( - (string) $root->getAttribute('failOnRisky'), - false - ); - } - - if ($root->hasAttribute('testSuiteLoaderClass')) { - $result['testSuiteLoaderClass'] = (string) $root->getAttribute( - 'testSuiteLoaderClass' - ); - } - - if ($root->hasAttribute('defaultTestSuite')) { - $result['defaultTestSuite'] = (string) $root->getAttribute( - 'defaultTestSuite' - ); - } - - if ($root->getAttribute('testSuiteLoaderFile')) { - $result['testSuiteLoaderFile'] = $this->toAbsolutePath( - (string) $root->getAttribute('testSuiteLoaderFile') - ); - } - - if ($root->hasAttribute('printerClass')) { - $result['printerClass'] = (string) $root->getAttribute( - 'printerClass' - ); - } - - if ($root->getAttribute('printerFile')) { - $result['printerFile'] = $this->toAbsolutePath( - (string) $root->getAttribute('printerFile') - ); - } - - if ($root->hasAttribute('beStrictAboutChangesToGlobalState')) { - $result['beStrictAboutChangesToGlobalState'] = $this->getBoolean( - (string) $root->getAttribute('beStrictAboutChangesToGlobalState'), - false - ); - } - - if ($root->hasAttribute('beStrictAboutOutputDuringTests')) { - $result['disallowTestOutput'] = $this->getBoolean( - (string) $root->getAttribute('beStrictAboutOutputDuringTests'), - false - ); - } - - if ($root->hasAttribute('beStrictAboutResourceUsageDuringSmallTests')) { - $result['beStrictAboutResourceUsageDuringSmallTests'] = $this->getBoolean( - (string) $root->getAttribute('beStrictAboutResourceUsageDuringSmallTests'), - false - ); - } - - if ($root->hasAttribute('beStrictAboutTestsThatDoNotTestAnything')) { - $result['reportUselessTests'] = $this->getBoolean( - (string) $root->getAttribute('beStrictAboutTestsThatDoNotTestAnything'), - true - ); - } - - if ($root->hasAttribute('beStrictAboutTodoAnnotatedTests')) { - $result['disallowTodoAnnotatedTests'] = $this->getBoolean( - (string) $root->getAttribute('beStrictAboutTodoAnnotatedTests'), - false - ); - } - - if ($root->hasAttribute('beStrictAboutCoversAnnotation')) { - $result['strictCoverage'] = $this->getBoolean( - (string) $root->getAttribute('beStrictAboutCoversAnnotation'), - false - ); - } - - if ($root->hasAttribute('defaultTimeLimit')) { - $result['defaultTimeLimit'] = $this->getInteger( - (string) $root->getAttribute('defaultTimeLimit'), - 1 - ); - } - - if ($root->hasAttribute('enforceTimeLimit')) { - $result['enforceTimeLimit'] = $this->getBoolean( - (string) $root->getAttribute('enforceTimeLimit'), - false - ); - } - - if ($root->hasAttribute('ignoreDeprecatedCodeUnitsFromCodeCoverage')) { - $result['ignoreDeprecatedCodeUnitsFromCodeCoverage'] = $this->getBoolean( - (string) $root->getAttribute('ignoreDeprecatedCodeUnitsFromCodeCoverage'), - false - ); - } - - if ($root->hasAttribute('timeoutForSmallTests')) { - $result['timeoutForSmallTests'] = $this->getInteger( - (string) $root->getAttribute('timeoutForSmallTests'), - 1 - ); - } - - if ($root->hasAttribute('timeoutForMediumTests')) { - $result['timeoutForMediumTests'] = $this->getInteger( - (string) $root->getAttribute('timeoutForMediumTests'), - 10 - ); - } - - if ($root->hasAttribute('timeoutForLargeTests')) { - $result['timeoutForLargeTests'] = $this->getInteger( - (string) $root->getAttribute('timeoutForLargeTests'), - 60 - ); - } - - if ($root->hasAttribute('reverseDefectList')) { - $result['reverseDefectList'] = $this->getBoolean( - (string) $root->getAttribute('reverseDefectList'), - false - ); - } - - if ($root->hasAttribute('verbose')) { - $result['verbose'] = $this->getBoolean( - (string) $root->getAttribute('verbose'), - false - ); - } - - if ($root->hasAttribute('testdox')) { - $testdox = $this->getBoolean( - (string) $root->getAttribute('testdox'), - false - ); - - if ($testdox) { - if (isset($result['printerClass'])) { - $result['conflictBetweenPrinterClassAndTestdox'] = true; - } else { - $result['printerClass'] = CliTestDoxPrinter::class; - } - } - } - - if ($root->hasAttribute('registerMockObjectsFromTestArgumentsRecursively')) { - $result['registerMockObjectsFromTestArgumentsRecursively'] = $this->getBoolean( - (string) $root->getAttribute('registerMockObjectsFromTestArgumentsRecursively'), - false - ); - } - - if ($root->hasAttribute('extensionsDirectory')) { - $result['extensionsDirectory'] = $this->toAbsolutePath( - (string) $root->getAttribute( - 'extensionsDirectory' - ) - ); - } - - if ($root->hasAttribute('cacheResult')) { - $result['cacheResult'] = $this->getBoolean( - (string) $root->getAttribute('cacheResult'), - true - ); - } - - if ($root->hasAttribute('cacheResultFile')) { - $result['cacheResultFile'] = $this->toAbsolutePath( - (string) $root->getAttribute('cacheResultFile') - ); - } - - if ($root->hasAttribute('executionOrder')) { - foreach (explode(',', $root->getAttribute('executionOrder')) as $order) { - switch ($order) { - case 'default': - $result['executionOrder'] = TestSuiteSorter::ORDER_DEFAULT; - $result['executionOrderDefects'] = TestSuiteSorter::ORDER_DEFAULT; - $result['resolveDependencies'] = false; - - break; - - case 'defects': - $result['executionOrderDefects'] = TestSuiteSorter::ORDER_DEFECTS_FIRST; - - break; - - case 'depends': - $result['resolveDependencies'] = true; - - break; - - case 'duration': - $result['executionOrder'] = TestSuiteSorter::ORDER_DURATION; - - break; - - case 'no-depends': - $result['resolveDependencies'] = false; - - break; - - case 'random': - $result['executionOrder'] = TestSuiteSorter::ORDER_RANDOMIZED; - - break; - - case 'reverse': - $result['executionOrder'] = TestSuiteSorter::ORDER_REVERSED; - - break; - - case 'size': - $result['executionOrder'] = TestSuiteSorter::ORDER_SIZE; - - break; - } - } - } - - if ($root->hasAttribute('resolveDependencies')) { - $result['resolveDependencies'] = $this->getBoolean( - (string) $root->getAttribute('resolveDependencies'), - false - ); - } - - if ($root->hasAttribute('noInteraction')) { - $result['noInteraction'] = $this->getBoolean( - (string) $root->getAttribute('noInteraction'), - false - ); - } - - return $result; - } - - /** - * Returns the test suite configuration. - * - * @throws Exception - */ - public function getTestSuiteConfiguration(string $testSuiteFilter = ''): TestSuite - { - $testSuiteNodes = $this->xpath->query('testsuites/testsuite'); - - if ($testSuiteNodes->length === 0) { - $testSuiteNodes = $this->xpath->query('testsuite'); - } - - if ($testSuiteNodes->length === 1) { - return $this->getTestSuite($testSuiteNodes->item(0), $testSuiteFilter); - } - - $suite = new TestSuite; - - foreach ($testSuiteNodes as $testSuiteNode) { - $suite->addTestSuite( - $this->getTestSuite($testSuiteNode, $testSuiteFilter) - ); - } - - return $suite; - } - - /** - * Returns the test suite names from the configuration. - */ - public function getTestSuiteNames(): array - { - $names = []; - - foreach ($this->xpath->query('*/testsuite') as $node) { - /* @var DOMElement $node */ - $names[] = $node->getAttribute('name'); - } - - return $names; - } - - private function validateConfigurationAgainstSchema(): void - { - $original = libxml_use_internal_errors(true); - $xsdFilename = __DIR__ . '/../../phpunit.xsd'; - - if (defined('__PHPUNIT_PHAR_ROOT__')) { - $xsdFilename = __PHPUNIT_PHAR_ROOT__ . '/phpunit.xsd'; - } - - $this->document->schemaValidateSource(file_get_contents($xsdFilename)); - $this->errors = libxml_get_errors(); - libxml_clear_errors(); - libxml_use_internal_errors($original); - } - - /** - * Collects and returns the configuration arguments from the PHPUnit - * XML configuration. - */ - private function getConfigurationArguments(DOMNodeList $nodes): array - { - $arguments = []; - - if ($nodes->length === 0) { - return $arguments; - } - - foreach ($nodes as $node) { - if (!$node instanceof DOMElement) { - continue; - } - - if ($node->tagName !== 'arguments') { - continue; - } - - foreach ($node->childNodes as $argument) { - if (!$argument instanceof DOMElement) { - continue; - } - - if ($argument->tagName === 'file' || $argument->tagName === 'directory') { - $arguments[] = $this->toAbsolutePath((string) $argument->textContent); - } else { - $arguments[] = Xml::xmlToVariable($argument); - } - } - } - - return $arguments; - } - - /** - * @throws \PHPUnit\Framework\Exception - */ - private function getTestSuite(DOMElement $testSuiteNode, string $testSuiteFilter = ''): TestSuite - { - if ($testSuiteNode->hasAttribute('name')) { - $suite = new TestSuite( - (string) $testSuiteNode->getAttribute('name') - ); - } else { - $suite = new TestSuite; - } - - $exclude = []; - - foreach ($testSuiteNode->getElementsByTagName('exclude') as $excludeNode) { - $excludeFile = (string) $excludeNode->textContent; - - if ($excludeFile) { - $exclude[] = $this->toAbsolutePath($excludeFile); - } - } - - $fileIteratorFacade = new FileIteratorFacade; - $testSuiteFilter = $testSuiteFilter ? explode(',', $testSuiteFilter) : []; - - foreach ($testSuiteNode->getElementsByTagName('directory') as $directoryNode) { - assert($directoryNode instanceof DOMElement); - - if (!empty($testSuiteFilter) && !in_array($directoryNode->parentNode->getAttribute('name'), $testSuiteFilter, true)) { - continue; - } - - $directory = (string) $directoryNode->textContent; - - if (empty($directory)) { - continue; - } - - if (!$this->satisfiesPhpVersion($directoryNode)) { - continue; - } - - $files = $fileIteratorFacade->getFilesAsArray( - $this->toAbsolutePath($directory), - $directoryNode->hasAttribute('suffix') ? (string) $directoryNode->getAttribute('suffix') : 'Test.php', - $directoryNode->hasAttribute('prefix') ? (string) $directoryNode->getAttribute('prefix') : '', - $exclude - ); - - $suite->addTestFiles($files); - } - - foreach ($testSuiteNode->getElementsByTagName('file') as $fileNode) { - assert($fileNode instanceof DOMElement); - - if (!empty($testSuiteFilter) && !in_array($fileNode->parentNode->getAttribute('name'), $testSuiteFilter, true)) { - continue; - } - - $file = (string) $fileNode->textContent; - - if (empty($file)) { - continue; - } - - $file = $fileIteratorFacade->getFilesAsArray( - $this->toAbsolutePath($file) - ); - - if (!isset($file[0])) { - continue; - } - - $file = $file[0]; - - if (!$this->satisfiesPhpVersion($fileNode)) { - continue; - } - - $suite->addTestFile($file); - } - - return $suite; - } - - private function satisfiesPhpVersion(DOMElement $node): bool - { - $phpVersion = PHP_VERSION; - $phpVersionOperator = '>='; - - if ($node->hasAttribute('phpVersion')) { - $phpVersion = (string) $node->getAttribute('phpVersion'); - } - - if ($node->hasAttribute('phpVersionOperator')) { - $phpVersionOperator = (string) $node->getAttribute('phpVersionOperator'); - } - - return version_compare(PHP_VERSION, $phpVersion, (new VersionComparisonOperator($phpVersionOperator))->asString()); - } - - /** - * if $value is 'false' or 'true', this returns the value that $value represents. - * Otherwise, returns $default, which may be a string in rare cases. - * See PHPUnit\Util\ConfigurationTest::testPHPConfigurationIsReadCorrectly. - * - * @param bool|string $default - * - * @return bool|string - */ - private function getBoolean(string $value, $default) - { - if (strtolower($value) === 'false') { - return false; - } - - if (strtolower($value) === 'true') { - return true; - } - - return $default; - } - - private function getInteger(string $value, int $default): int - { - if (is_numeric($value)) { - return (int) $value; - } - - return $default; - } - - private function readFilterDirectories(string $query): array - { - $directories = []; - - foreach ($this->xpath->query($query) as $directoryNode) { - assert($directoryNode instanceof DOMElement); - - $directoryPath = (string) $directoryNode->textContent; - - if (!$directoryPath) { - continue; - } - - $directories[] = [ - 'path' => $this->toAbsolutePath($directoryPath), - 'prefix' => $directoryNode->hasAttribute('prefix') ? (string) $directoryNode->getAttribute('prefix') : '', - 'suffix' => $directoryNode->hasAttribute('suffix') ? (string) $directoryNode->getAttribute('suffix') : '.php', - 'group' => $directoryNode->hasAttribute('group') ? (string) $directoryNode->getAttribute('group') : 'DEFAULT', - ]; - } - - return $directories; - } - - /** - * @return string[] - */ - private function readFilterFiles(string $query): array - { - $files = []; - - foreach ($this->xpath->query($query) as $file) { - $filePath = (string) $file->textContent; - - if ($filePath) { - $files[] = $this->toAbsolutePath($filePath); - } - } - - return $files; - } - - private function toAbsolutePath(string $path, bool $useIncludePath = false): string - { - $path = trim($path); - - if (strpos($path, '/') === 0) { - return $path; - } - - // Matches the following on Windows: - // - \\NetworkComputer\Path - // - \\.\D: - // - \\.\c: - // - C:\Windows - // - C:\windows - // - C:/windows - // - c:/windows - if (defined('PHP_WINDOWS_VERSION_BUILD') && - ($path[0] === '\\' || (strlen($path) >= 3 && preg_match('#^[A-Z]\:[/\\\]#i', substr($path, 0, 3))))) { - return $path; - } - - if (strpos($path, '://') !== false) { - return $path; - } - - $file = dirname($this->filename) . DIRECTORY_SEPARATOR . $path; - - if ($useIncludePath && !file_exists($file)) { - $includePathFile = stream_resolve_include_path($path); - - if ($includePathFile) { - $file = $includePathFile; - } - } - - return $file; - } - - private function parseGroupConfiguration(string $root): array - { - $groups = [ - 'include' => [], - 'exclude' => [], - ]; - - foreach ($this->xpath->query($root . '/include/group') as $group) { - $groups['include'][] = (string) $group->textContent; - } - - foreach ($this->xpath->query($root . '/exclude/group') as $group) { - $groups['exclude'][] = (string) $group->textContent; - } - - return $groups; - } - - private function getElementConfigurationParameters(DOMElement $element): array - { - $class = (string) $element->getAttribute('class'); - $file = ''; - $arguments = $this->getConfigurationArguments($element->childNodes); - - if ($element->getAttribute('file')) { - $file = $this->toAbsolutePath( - (string) $element->getAttribute('file'), - true - ); - } - - return [ - 'class' => $class, - 'file' => $file, - 'arguments' => $arguments, - ]; - } -} diff --git a/vendor/phpunit/phpunit/src/Util/ExcludeList.php b/vendor/phpunit/phpunit/src/Util/ExcludeList.php new file mode 100644 index 000000000..c7e6704a8 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Util/ExcludeList.php @@ -0,0 +1,261 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Util; + +use const DIRECTORY_SEPARATOR; +use function class_exists; +use function defined; +use function dirname; +use function is_dir; +use function realpath; +use function sprintf; +use function strpos; +use function sys_get_temp_dir; +use Composer\Autoload\ClassLoader; +use DeepCopy\DeepCopy; +use Doctrine\Instantiator\Instantiator; +use PharIo\Manifest\Manifest; +use PharIo\Version\Version as PharIoVersion; +use phpDocumentor\Reflection\DocBlock; +use phpDocumentor\Reflection\Project; +use phpDocumentor\Reflection\Type; +use PhpParser\Parser; +use PHPUnit\Framework\TestCase; +use Prophecy\Prophet; +use ReflectionClass; +use ReflectionException; +use SebastianBergmann\CliParser\Parser as CliParser; +use SebastianBergmann\CodeCoverage\CodeCoverage; +use SebastianBergmann\CodeUnit\CodeUnit; +use SebastianBergmann\CodeUnitReverseLookup\Wizard; +use SebastianBergmann\Comparator\Comparator; +use SebastianBergmann\Complexity\Calculator; +use SebastianBergmann\Diff\Diff; +use SebastianBergmann\Environment\Runtime; +use SebastianBergmann\Exporter\Exporter; +use SebastianBergmann\FileIterator\Facade as FileIteratorFacade; +use SebastianBergmann\GlobalState\Snapshot; +use SebastianBergmann\Invoker\Invoker; +use SebastianBergmann\LinesOfCode\Counter; +use SebastianBergmann\ObjectEnumerator\Enumerator; +use SebastianBergmann\RecursionContext\Context; +use SebastianBergmann\ResourceOperations\ResourceOperations; +use SebastianBergmann\Template\Template; +use SebastianBergmann\Timer\Timer; +use SebastianBergmann\Type\TypeName; +use SebastianBergmann\Version; +use Symfony\Polyfill\Ctype\Ctype; +use TheSeer\Tokenizer\Tokenizer; +use Webmozart\Assert\Assert; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class ExcludeList +{ + /** + * @var array + */ + private const EXCLUDED_CLASS_NAMES = [ + // composer + ClassLoader::class => 1, + + // doctrine/instantiator + Instantiator::class => 1, + + // myclabs/deepcopy + DeepCopy::class => 1, + + // nikic/php-parser + Parser::class => 1, + + // phar-io/manifest + Manifest::class => 1, + + // phar-io/version + PharIoVersion::class => 1, + + // phpdocumentor/reflection-common + Project::class => 1, + + // phpdocumentor/reflection-docblock + DocBlock::class => 1, + + // phpdocumentor/type-resolver + Type::class => 1, + + // phpspec/prophecy + Prophet::class => 1, + + // phpunit/phpunit + TestCase::class => 2, + + // phpunit/php-code-coverage + CodeCoverage::class => 1, + + // phpunit/php-file-iterator + FileIteratorFacade::class => 1, + + // phpunit/php-invoker + Invoker::class => 1, + + // phpunit/php-text-template + Template::class => 1, + + // phpunit/php-timer + Timer::class => 1, + + // sebastian/cli-parser + CliParser::class => 1, + + // sebastian/code-unit + CodeUnit::class => 1, + + // sebastian/code-unit-reverse-lookup + Wizard::class => 1, + + // sebastian/comparator + Comparator::class => 1, + + // sebastian/complexity + Calculator::class => 1, + + // sebastian/diff + Diff::class => 1, + + // sebastian/environment + Runtime::class => 1, + + // sebastian/exporter + Exporter::class => 1, + + // sebastian/global-state + Snapshot::class => 1, + + // sebastian/lines-of-code + Counter::class => 1, + + // sebastian/object-enumerator + Enumerator::class => 1, + + // sebastian/recursion-context + Context::class => 1, + + // sebastian/resource-operations + ResourceOperations::class => 1, + + // sebastian/type + TypeName::class => 1, + + // sebastian/version + Version::class => 1, + + // symfony/polyfill-ctype + Ctype::class => 1, + + // theseer/tokenizer + Tokenizer::class => 1, + + // webmozart/assert + Assert::class => 1, + ]; + + /** + * @var string[] + */ + private static $directories; + + public static function addDirectory(string $directory): void + { + if (!is_dir($directory)) { + throw new Exception( + sprintf( + '"%s" is not a directory', + $directory + ) + ); + } + + self::$directories[] = realpath($directory); + } + + /** + * @throws Exception + * + * @return string[] + */ + public function getExcludedDirectories(): array + { + $this->initialize(); + + return self::$directories; + } + + /** + * @throws Exception + */ + public function isExcluded(string $file): bool + { + if (defined('PHPUNIT_TESTSUITE')) { + return false; + } + + $this->initialize(); + + foreach (self::$directories as $directory) { + if (strpos($file, $directory) === 0) { + return true; + } + } + + return false; + } + + /** + * @throws Exception + */ + private function initialize(): void + { + if (self::$directories === null) { + self::$directories = []; + + foreach (self::EXCLUDED_CLASS_NAMES as $className => $parent) { + if (!class_exists($className)) { + continue; + } + + try { + $directory = (new ReflectionClass($className))->getFileName(); + // @codeCoverageIgnoreStart + } catch (ReflectionException $e) { + throw new Exception( + $e->getMessage(), + (int) $e->getCode(), + $e + ); + } + // @codeCoverageIgnoreEnd + + for ($i = 0; $i < $parent; $i++) { + $directory = dirname($directory); + } + + self::$directories[] = $directory; + } + + // Hide process isolation workaround on Windows. + if (DIRECTORY_SEPARATOR === '\\') { + // tempnam() prefix is limited to first 3 chars. + // @see https://php.net/manual/en/function.tempnam.php + self::$directories[] = sys_get_temp_dir() . '\\PHP'; + } + } + } +} diff --git a/vendor/phpunit/phpunit/src/Util/FileLoader.php b/vendor/phpunit/phpunit/src/Util/FileLoader.php index 1390d8cf4..732870723 100644 --- a/vendor/phpunit/phpunit/src/Util/FileLoader.php +++ b/vendor/phpunit/phpunit/src/Util/FileLoader.php @@ -16,7 +16,6 @@ use function fopen; use function get_defined_vars; use function sprintf; use function stream_resolve_include_path; -use PHPUnit\Framework\Exception; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit @@ -37,15 +36,11 @@ final class FileLoader { $includePathFilename = stream_resolve_include_path($filename); - if (!$includePathFilename) { - throw new Exception( - sprintf('Cannot open file "%s".' . "\n", $filename) - ); - } - $localFile = __DIR__ . DIRECTORY_SEPARATOR . $filename; - if ($includePathFilename === $localFile || !self::isReadable($includePathFilename)) { + if (!$includePathFilename || + $includePathFilename === $localFile || + !self::isReadable($includePathFilename)) { throw new Exception( sprintf('Cannot open file "%s".' . "\n", $filename) ); @@ -63,6 +58,10 @@ final class FileLoader { $oldVariableNames = array_keys(get_defined_vars()); + /** + * @noinspection PhpIncludeInspection + * @psalm-suppress UnresolvableInclude + */ include_once $filename; $newVariables = get_defined_vars(); diff --git a/vendor/phpunit/phpunit/src/Util/Filesystem.php b/vendor/phpunit/phpunit/src/Util/Filesystem.php index cd0c125f7..35b2690b1 100644 --- a/vendor/phpunit/phpunit/src/Util/Filesystem.php +++ b/vendor/phpunit/phpunit/src/Util/Filesystem.php @@ -20,9 +20,10 @@ use function str_replace; final class Filesystem { /** - * Maps class names to source file names: + * Maps class names to source file names. + * * - PEAR CS: Foo_Bar_Baz -> Foo/Bar/Baz.php - * - Namespace: Foo\Bar\Baz -> Foo/Bar/Baz.php. + * - Namespace: Foo\Bar\Baz -> Foo/Bar/Baz.php */ public static function classNameToFilename(string $className): string { diff --git a/vendor/phpunit/phpunit/src/Util/Filter.php b/vendor/phpunit/phpunit/src/Util/Filter.php index 06f58d55d..42563937d 100644 --- a/vendor/phpunit/phpunit/src/Util/Filter.php +++ b/vendor/phpunit/phpunit/src/Util/Filter.php @@ -57,11 +57,11 @@ final class Filter ); } - $prefix = defined('__PHPUNIT_PHAR_ROOT__') ? __PHPUNIT_PHAR_ROOT__ : false; - $blacklist = new Blacklist; + $prefix = defined('__PHPUNIT_PHAR_ROOT__') ? __PHPUNIT_PHAR_ROOT__ : false; + $excludeList = new ExcludeList; foreach ($eTrace as $frame) { - if (self::shouldPrintFrame($frame, $prefix, $blacklist)) { + if (self::shouldPrintFrame($frame, $prefix, $excludeList)) { $filteredStacktrace .= sprintf( "%s:%s\n", $frame['file'], @@ -73,7 +73,7 @@ final class Filter return $filteredStacktrace; } - private static function shouldPrintFrame($frame, $prefix, Blacklist $blacklist): bool + private static function shouldPrintFrame(array $frame, $prefix, ExcludeList $excludeList): bool { if (!isset($frame['file'])) { return false; @@ -90,16 +90,16 @@ final class Filter } return is_file($file) && - self::fileIsBlacklisted($file, $blacklist) && + self::fileIsExcluded($file, $excludeList) && $fileIsNotPrefixed && $file !== $script; } - private static function fileIsBlacklisted($file, Blacklist $blacklist): bool + private static function fileIsExcluded(string $file, ExcludeList $excludeList): bool { - return (empty($GLOBALS['__PHPUNIT_ISOLATION_BLACKLIST']) || - !in_array($file, $GLOBALS['__PHPUNIT_ISOLATION_BLACKLIST'], true)) && - !$blacklist->isBlacklisted($file); + return (empty($GLOBALS['__PHPUNIT_ISOLATION_EXCLUDE_LIST']) || + !in_array($file, $GLOBALS['__PHPUNIT_ISOLATION_EXCLUDE_LIST'], true)) && + !$excludeList->isExcluded($file); } private static function frameExists(array $trace, string $file, int $line): bool diff --git a/vendor/phpunit/phpunit/src/Util/Getopt.php b/vendor/phpunit/phpunit/src/Util/Getopt.php deleted file mode 100644 index 878e2a43f..000000000 --- a/vendor/phpunit/phpunit/src/Util/Getopt.php +++ /dev/null @@ -1,197 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace PHPUnit\Util; - -use function array_map; -use function array_merge; -use function array_shift; -use function array_slice; -use function count; -use function current; -use function explode; -use function key; -use function next; -use function preg_replace; -use function reset; -use function sort; -use function strlen; -use function strpos; -use function strstr; -use function substr; -use PHPUnit\Framework\Exception; - -/** - * @internal This class is not covered by the backward compatibility promise for PHPUnit - */ -final class Getopt -{ - /** - * @throws Exception - */ - public static function parse(array $args, string $short_options, array $long_options = null): array - { - if (empty($args)) { - return [[], []]; - } - - $opts = []; - $non_opts = []; - - if ($long_options) { - sort($long_options); - } - - if (isset($args[0][0]) && $args[0][0] !== '-') { - array_shift($args); - } - - reset($args); - - $args = array_map('trim', $args); - - /* @noinspection ComparisonOperandsOrderInspection */ - while (false !== $arg = current($args)) { - $i = key($args); - next($args); - - if ($arg === '') { - continue; - } - - if ($arg === '--') { - $non_opts = array_merge($non_opts, array_slice($args, $i + 1)); - - break; - } - - if ($arg[0] !== '-' || (strlen($arg) > 1 && $arg[1] === '-' && !$long_options)) { - $non_opts[] = $args[$i]; - - continue; - } - - if (strlen($arg) > 1 && $arg[1] === '-') { - self::parseLongOption( - substr($arg, 2), - $long_options, - $opts, - $args - ); - } else { - self::parseShortOption( - substr($arg, 1), - $short_options, - $opts, - $args - ); - } - } - - return [$opts, $non_opts]; - } - - /** - * @throws Exception - */ - private static function parseShortOption(string $arg, string $short_options, array &$opts, array &$args): void - { - $argLen = strlen($arg); - - for ($i = 0; $i < $argLen; $i++) { - $opt = $arg[$i]; - $opt_arg = null; - - if ($arg[$i] === ':' || ($spec = strstr($short_options, $opt)) === false) { - throw new Exception( - "unrecognized option -- {$opt}" - ); - } - - if (strlen($spec) > 1 && $spec[1] === ':') { - if ($i + 1 < $argLen) { - $opts[] = [$opt, substr($arg, $i + 1)]; - - break; - } - - if (!(strlen($spec) > 2 && $spec[2] === ':')) { - /* @noinspection ComparisonOperandsOrderInspection */ - if (false === $opt_arg = current($args)) { - throw new Exception( - "option requires an argument -- {$opt}" - ); - } - - next($args); - } - } - - $opts[] = [$opt, $opt_arg]; - } - } - - /** - * @throws Exception - */ - private static function parseLongOption(string $arg, array $long_options, array &$opts, array &$args): void - { - $count = count($long_options); - $list = explode('=', $arg); - $opt = $list[0]; - $opt_arg = null; - - if (count($list) > 1) { - $opt_arg = $list[1]; - } - - $opt_len = strlen($opt); - - foreach ($long_options as $i => $long_opt) { - $opt_start = substr($long_opt, 0, $opt_len); - - if ($opt_start !== $opt) { - continue; - } - - $opt_rest = substr($long_opt, $opt_len); - - if ($opt_rest !== '' && $i + 1 < $count && $opt[0] !== '=' && strpos($long_options[$i + 1], $opt) === 0) { - throw new Exception( - "option --{$opt} is ambiguous" - ); - } - - if (substr($long_opt, -1) === '=') { - /* @noinspection StrlenInEmptyStringCheckContextInspection */ - if (substr($long_opt, -2) !== '==' && !strlen((string) $opt_arg)) { - /* @noinspection ComparisonOperandsOrderInspection */ - if (false === $opt_arg = current($args)) { - throw new Exception( - "option --{$opt} requires an argument" - ); - } - - next($args); - } - } elseif ($opt_arg) { - throw new Exception( - "option --{$opt} doesn't allow an argument" - ); - } - - $full_option = '--' . preg_replace('/={1,2}$/', '', $long_opt); - $opts[] = [$full_option, $opt_arg]; - - return; - } - - throw new Exception("unrecognized option --{$opt}"); - } -} diff --git a/vendor/phpunit/phpunit/src/Util/GlobalState.php b/vendor/phpunit/phpunit/src/Util/GlobalState.php index 0bd52de25..b2110e9ca 100644 --- a/vendor/phpunit/phpunit/src/Util/GlobalState.php +++ b/vendor/phpunit/phpunit/src/Util/GlobalState.php @@ -10,7 +10,7 @@ namespace PHPUnit\Util; use function array_keys; -use function count; +use function array_reverse; use function defined; use function get_defined_constants; use function get_included_files; @@ -59,19 +59,20 @@ final class GlobalState */ public static function processIncludedFilesAsString(array $files): string { - $blacklist = new Blacklist; - $prefix = false; - $result = ''; + $excludeList = new ExcludeList; + $prefix = false; + $result = ''; if (defined('__PHPUNIT_PHAR__')) { $prefix = 'phar://' . __PHPUNIT_PHAR__ . '/'; } - for ($i = count($files) - 1; $i > 0; $i--) { - $file = $files[$i]; + // Do not process bootstrap script + unset($files[0]); - if (!empty($GLOBALS['__PHPUNIT_ISOLATION_BLACKLIST']) && - in_array($file, $GLOBALS['__PHPUNIT_ISOLATION_BLACKLIST'], true)) { + foreach (array_reverse($files) as $file) { + if (!empty($GLOBALS['__PHPUNIT_ISOLATION_EXCLUDE_LIST']) && + in_array($file, $GLOBALS['__PHPUNIT_ISOLATION_EXCLUDE_LIST'], true)) { continue; } @@ -84,7 +85,7 @@ final class GlobalState continue; } - if (!$blacklist->isBlacklisted($file) && is_file($file)) { + if (!$excludeList->isExcluded($file) && is_file($file)) { $result = 'require_once \'' . $file . "';\n" . $result; } } @@ -147,11 +148,11 @@ final class GlobalState } } - $blacklist = self::SUPER_GLOBAL_ARRAYS; - $blacklist[] = 'GLOBALS'; + $excludeList = self::SUPER_GLOBAL_ARRAYS; + $excludeList[] = 'GLOBALS'; foreach (array_keys($GLOBALS) as $key) { - if (!$GLOBALS[$key] instanceof Closure && !in_array($key, $blacklist, true)) { + if (!$GLOBALS[$key] instanceof Closure && !in_array($key, $excludeList, true)) { $result .= sprintf( '$GLOBALS[\'%s\'] = %s;' . "\n", $key, diff --git a/vendor/phpunit/phpunit/src/Util/Log/JUnit.php b/vendor/phpunit/phpunit/src/Util/Log/JUnit.php index 710e2c47d..7a97682fc 100644 --- a/vendor/phpunit/phpunit/src/Util/Log/JUnit.php +++ b/vendor/phpunit/phpunit/src/Util/Log/JUnit.php @@ -14,6 +14,7 @@ use function get_class; use function method_exists; use function sprintf; use function str_replace; +use function trim; use DOMDocument; use DOMElement; use PHPUnit\Framework\AssertionFailedError; @@ -133,7 +134,7 @@ final class JUnit extends Printer implements TestListener */ public function addError(Test $test, Throwable $t, float $time): void { - $this->doAddFault($test, $t, $time, 'error'); + $this->doAddFault($test, $t, 'error'); $this->testSuiteErrors[$this->testSuiteLevel]++; } @@ -142,7 +143,7 @@ final class JUnit extends Printer implements TestListener */ public function addWarning(Test $test, Warning $e, float $time): void { - $this->doAddFault($test, $e, $time, 'warning'); + $this->doAddFault($test, $e, 'warning'); $this->testSuiteWarnings[$this->testSuiteLevel]++; } @@ -151,7 +152,7 @@ final class JUnit extends Printer implements TestListener */ public function addFailure(Test $test, AssertionFailedError $e, float $time): void { - $this->doAddFault($test, $e, $time, 'failure'); + $this->doAddFault($test, $e, 'failure'); $this->testSuiteFailures[$this->testSuiteLevel]++; } @@ -168,22 +169,11 @@ final class JUnit extends Printer implements TestListener */ public function addRiskyTest(Test $test, Throwable $t, float $time): void { - if (!$this->reportRiskyTests || $this->currentTestCase === null) { + if (!$this->reportRiskyTests) { return; } - $error = $this->document->createElement( - 'error', - Xml::prepareString( - "Risky Test\n" . - Filter::getFilteredStacktrace($t) - ) - ); - - $error->setAttribute('type', get_class($t)); - - $this->currentTestCase->appendChild($error); - + $this->doAddFault($test, $t, 'error'); $this->testSuiteErrors[$this->testSuiteLevel]++; } @@ -388,7 +378,7 @@ final class JUnit extends Printer implements TestListener return $this->document->saveXML(); } - private function doAddFault(Test $test, Throwable $t, float $time, $type): void + private function doAddFault(Test $test, Throwable $t, string $type): void { if ($this->currentTestCase === null) { return; @@ -400,8 +390,10 @@ final class JUnit extends Printer implements TestListener $buffer = ''; } - $buffer .= TestFailure::exceptionToString($t) . "\n" . - Filter::getFilteredStacktrace($t); + $buffer .= trim( + TestFailure::exceptionToString($t) . "\n" . + Filter::getFilteredStacktrace($t) + ); $fault = $this->document->createElement( $type, diff --git a/vendor/phpunit/phpunit/src/Util/Log/TeamCity.php b/vendor/phpunit/phpunit/src/Util/Log/TeamCity.php index 695760d95..f800ba72d 100644 --- a/vendor/phpunit/phpunit/src/Util/Log/TeamCity.php +++ b/vendor/phpunit/phpunit/src/Util/Log/TeamCity.php @@ -31,7 +31,7 @@ use PHPUnit\Framework\TestFailure; use PHPUnit\Framework\TestResult; use PHPUnit\Framework\TestSuite; use PHPUnit\Framework\Warning; -use PHPUnit\TextUI\ResultPrinter; +use PHPUnit\TextUI\DefaultResultPrinter; use PHPUnit\Util\Exception; use PHPUnit\Util\Filter; use ReflectionClass; @@ -42,7 +42,7 @@ use Throwable; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ -final class TeamCity extends ResultPrinter +final class TeamCity extends DefaultResultPrinter { /** * @var bool @@ -59,9 +59,6 @@ final class TeamCity extends ResultPrinter */ private $flowId; - /** - * @throws \SebastianBergmann\Timer\RuntimeException - */ public function printResult(TestResult $result): void { $this->printHeader($result); @@ -163,7 +160,7 @@ final class TeamCity extends ResultPrinter } } - public function printIgnoredTest($testName, Throwable $t, float $time): void + public function printIgnoredTest(string $testName, Throwable $t, float $time): void { $this->printEvent( 'testIgnored', diff --git a/vendor/phpunit/phpunit/src/Util/PHP/DefaultPhpProcess.php b/vendor/phpunit/phpunit/src/Util/PHP/DefaultPhpProcess.php index b835043d8..c4dc11146 100644 --- a/vendor/phpunit/phpunit/src/Util/PHP/DefaultPhpProcess.php +++ b/vendor/phpunit/phpunit/src/Util/PHP/DefaultPhpProcess.php @@ -214,6 +214,9 @@ class DefaultPhpProcess extends AbstractPhpProcess return ['stdout' => $stdout, 'stderr' => $stderr]; } + /** + * @param resource $pipe + */ protected function process($pipe, string $job): void { fwrite($pipe, $job); diff --git a/vendor/phpunit/phpunit/src/Util/PHP/Template/PhptTestCase.tpl b/vendor/phpunit/phpunit/src/Util/PHP/Template/PhptTestCase.tpl index 14c3e7e6e..f23a0d1ae 100644 --- a/vendor/phpunit/phpunit/src/Util/PHP/Template/PhptTestCase.tpl +++ b/vendor/phpunit/phpunit/src/Util/PHP/Template/PhptTestCase.tpl @@ -1,15 +1,18 @@ {driverMethod}($filter), + $filter + ); + + if ({codeCoverageCacheDirectory}) { + $coverage->cacheStaticAnalysis({codeCoverageCacheDirectory}); + } + $coverage->start(__FILE__); } -register_shutdown_function(function() use ($coverage) { - $output = null; - if ($coverage) { - $output = $coverage->stop(); +register_shutdown_function( + function() use ($coverage) { + $output = null; + + if ($coverage) { + $output = $coverage->stop(); + } + + file_put_contents('{coverageFile}', serialize($output)); } - file_put_contents('{coverageFile}', serialize($output)); -}); +); ob_end_clean(); diff --git a/vendor/phpunit/phpunit/src/Util/PHP/Template/TestCaseClass.tpl b/vendor/phpunit/phpunit/src/Util/PHP/Template/TestCaseClass.tpl index 5d2ea0252..95035e505 100644 --- a/vendor/phpunit/phpunit/src/Util/PHP/Template/TestCaseClass.tpl +++ b/vendor/phpunit/phpunit/src/Util/PHP/Template/TestCaseClass.tpl @@ -1,5 +1,8 @@ setCodeCoverage( - new CodeCoverage( - null, - unserialize('{codeCoverageFilter}') - ) + $filter = unserialize('{codeCoverageFilter}'); + + $codeCoverage = new CodeCoverage( + (new Selector)->{driverMethod}($filter), + $filter ); + + if ({cachesStaticAnalysis}) { + $codeCoverage->cacheStaticAnalysis(unserialize('{codeCoverageCacheDirectory}')); + } + + $result->setCodeCoverage($codeCoverage); } $result->beStrictAboutTestsThatDoNotTestAnything({isStrictAboutTestsThatDoNotTestAnything}); @@ -82,8 +91,10 @@ function __phpunit_run_isolated_test() $configurationFilePath = '{configurationFilePath}'; if ('' !== $configurationFilePath) { - $configuration = PHPUnit\Util\Configuration::getInstance($configurationFilePath); - $configuration->handlePHPConfiguration(); + $configuration = (new Loader)->load($configurationFilePath); + + (new PhpHandler)->handle($configuration->php()); + unset($configuration); } diff --git a/vendor/phpunit/phpunit/src/Util/PHP/Template/TestCaseMethod.tpl b/vendor/phpunit/phpunit/src/Util/PHP/Template/TestCaseMethod.tpl index 9dd6c9203..da824e720 100644 --- a/vendor/phpunit/phpunit/src/Util/PHP/Template/TestCaseMethod.tpl +++ b/vendor/phpunit/phpunit/src/Util/PHP/Template/TestCaseMethod.tpl @@ -1,6 +1,9 @@ setCodeCoverage( - new CodeCoverage( - null, - unserialize('{codeCoverageFilter}') - ) + $filter = unserialize('{codeCoverageFilter}'); + + $codeCoverage = new CodeCoverage( + (new Selector)->{driverMethod}($filter), + $filter ); + + if ({cachesStaticAnalysis}) { + $codeCoverage->cacheStaticAnalysis(unserialize('{codeCoverageCacheDirectory}')); + } + + $result->setCodeCoverage($codeCoverage); } $result->beStrictAboutTestsThatDoNotTestAnything({isStrictAboutTestsThatDoNotTestAnything}); @@ -85,8 +94,10 @@ function __phpunit_run_isolated_test() $configurationFilePath = '{configurationFilePath}'; if ('' !== $configurationFilePath) { - $configuration = PHPUnit\Util\Configuration::getInstance($configurationFilePath); - $configuration->handlePHPConfiguration(); + $configuration = (new Loader)->load($configurationFilePath); + + (new PhpHandler)->handle($configuration->php()); + unset($configuration); } diff --git a/vendor/phpunit/phpunit/src/Util/Printer.php b/vendor/phpunit/phpunit/src/Util/Printer.php index c99abfed5..77b5745ad 100644 --- a/vendor/phpunit/phpunit/src/Util/Printer.php +++ b/vendor/phpunit/phpunit/src/Util/Printer.php @@ -9,6 +9,7 @@ */ namespace PHPUnit\Util; +use const ENT_COMPAT; use const ENT_SUBSTITUTE; use const PHP_SAPI; use function assert; @@ -16,8 +17,6 @@ use function count; use function dirname; use function explode; use function fclose; -use function fflush; -use function flush; use function fopen; use function fsockopen; use function fwrite; @@ -28,7 +27,6 @@ use function sprintf; use function str_replace; use function strncmp; use function strpos; -use PHPUnit\Framework\Exception; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit @@ -36,129 +34,83 @@ use PHPUnit\Framework\Exception; class Printer { /** - * If true, flush output after every write. - * + * @psalm-var closed-resource|resource + */ + private $stream; + + /** * @var bool */ - protected $autoFlush = false; + private $isPhpStream; /** - * @psalm-var resource|closed-resource - */ - protected $out; - - /** - * @var string - */ - protected $outTarget; - - /** - * Constructor. - * * @param null|resource|string $out * * @throws Exception */ public function __construct($out = null) { - if ($out === null) { + if (is_resource($out)) { + $this->stream = $out; + return; } - if (is_string($out) === false) { - $this->out = $out; - + if (!is_string($out)) { return; } if (strpos($out, 'socket://') === 0) { - $out = explode(':', str_replace('socket://', '', $out)); + $tmp = explode(':', str_replace('socket://', '', $out)); - if (count($out) !== 2) { - throw new Exception; + if (count($tmp) !== 2) { + throw new Exception( + sprintf( + '"%s" does not match "socket://hostname:port" format', + $out + ) + ); } - $this->out = fsockopen($out[0], $out[1]); - } else { - if (strpos($out, 'php://') === false && !Filesystem::createDirectory(dirname($out))) { - throw new Exception(sprintf('Directory "%s" was not created', dirname($out))); - } + $this->stream = fsockopen($tmp[0], (int) $tmp[1]); - $this->out = fopen($out, 'wt'); + return; } - $this->outTarget = $out; - } - - /** - * Flush buffer and close output if it's not to a PHP stream. - */ - public function flush(): void - { - if ($this->out && strncmp($this->outTarget, 'php://', 6) !== 0) { - assert(is_resource($this->out)); - - fclose($this->out); + if (strpos($out, 'php://') === false && !Filesystem::createDirectory(dirname($out))) { + throw new Exception( + sprintf( + 'Directory "%s" was not created', + dirname($out) + ) + ); } - } - /** - * Performs a safe, incremental flush. - * - * Do not confuse this function with the flush() function of this class, - * since the flush() function may close the file being written to, rendering - * the current object no longer usable. - */ - public function incrementalFlush(): void - { - if ($this->out) { - assert(is_resource($this->out)); - - fflush($this->out); - } else { - flush(); - } + $this->stream = fopen($out, 'wb'); + $this->isPhpStream = strncmp($out, 'php://', 6) !== 0; } public function write(string $buffer): void { - if ($this->out) { - assert(is_resource($this->out)); + if ($this->stream) { + assert(is_resource($this->stream)); - fwrite($this->out, $buffer); - - if ($this->autoFlush) { - $this->incrementalFlush(); - } + fwrite($this->stream, $buffer); } else { if (PHP_SAPI !== 'cli' && PHP_SAPI !== 'phpdbg') { - $buffer = htmlspecialchars($buffer, ENT_SUBSTITUTE); + $buffer = htmlspecialchars($buffer, ENT_COMPAT | ENT_SUBSTITUTE); } print $buffer; - - if ($this->autoFlush) { - $this->incrementalFlush(); - } } } - /** - * Check auto-flush mode. - */ - public function getAutoFlush(): bool + public function flush(): void { - return $this->autoFlush; - } + if ($this->stream && $this->isPhpStream) { + assert(is_resource($this->stream)); - /** - * Set auto-flushing mode. - * - * If set, *incremental* flushes will be done after each write. This should - * not be confused with the different effects of this class' flush() method. - */ - public function setAutoFlush(bool $autoFlush): void - { - $this->autoFlush = $autoFlush; + fclose($this->stream); + } } } diff --git a/vendor/phpunit/phpunit/src/Util/Test.php b/vendor/phpunit/phpunit/src/Util/Test.php index 4d0e79db0..0778f2f52 100644 --- a/vendor/phpunit/phpunit/src/Util/Test.php +++ b/vendor/phpunit/phpunit/src/Util/Test.php @@ -14,13 +14,10 @@ use const PHP_VERSION; use function addcslashes; use function array_flip; use function array_key_exists; -use function array_keys; use function array_merge; use function array_unique; use function array_unshift; use function class_exists; -use function class_implements; -use function class_parents; use function count; use function explode; use function extension_loaded; @@ -34,15 +31,15 @@ use function method_exists; use function phpversion; use function preg_match; use function preg_replace; -use function range; use function sprintf; -use function str_replace; use function strncmp; use function strpos; -use function trait_exists; +use function strtolower; +use function trim; use function version_compare; use PHPUnit\Framework\Assert; use PHPUnit\Framework\CodeCoverageException; +use PHPUnit\Framework\ExecutionOrderDependency; use PHPUnit\Framework\InvalidCoversTargetException; use PHPUnit\Framework\SelfDescribing; use PHPUnit\Framework\TestCase; @@ -51,8 +48,10 @@ use PHPUnit\Runner\Version; use PHPUnit\Util\Annotation\Registry; use ReflectionClass; use ReflectionException; -use ReflectionFunction; use ReflectionMethod; +use SebastianBergmann\CodeUnit\CodeUnitCollection; +use SebastianBergmann\CodeUnit\InvalidCodeUnitException; +use SebastianBergmann\CodeUnit\Mapper; use SebastianBergmann\Environment\OperatingSystem; /** @@ -143,7 +142,10 @@ final class Test public static function requiresCodeCoverageDataCollection(TestCase $test): bool { - $annotations = $test->getAnnotations(); + $annotations = self::parseTestMethodAnnotations( + get_class($test), + $test->getName(false) + ); // If there is no @covers annotation but a @coversNothing annotation on // the test method then code coverage data does not need to be collected @@ -309,20 +311,6 @@ final class Test return $missing; } - /** - * Returns the expected exception for a test. - * - * @return array|false - * - * @deprecated - * @codeCoverageIgnore - * @psalm-param class-string $className - */ - public static function getExpectedException(string $className, string $methodName) - { - return Registry::getInstance()->forMethod($className, $methodName)->expectedException(); - } - /** * Returns the provided data for a method. * @@ -383,7 +371,11 @@ final class Test ]; } - /** @psalm-param class-string $className */ + /** + * @psalm-param class-string $className + * + * @return ExecutionOrderDependency[] + */ public static function getDependencies(string $className, string $methodName): array { $annotations = self::parseTestMethodAnnotations( @@ -391,15 +383,22 @@ final class Test $methodName ); - $dependencies = $annotations['class']['depends'] ?? []; + $dependsAnnotations = $annotations['class']['depends'] ?? []; if (isset($annotations['method']['depends'])) { - $dependencies = array_merge( - $dependencies, + $dependsAnnotations = array_merge( + $dependsAnnotations, $annotations['method']['depends'] ); } + // Normalize dependency name to className::methodName + $dependencies = []; + + foreach ($dependsAnnotations as $value) { + $dependencies[] = ExecutionOrderDependency::createFromDependsAnnotation($className, $value); + } + return array_unique($dependencies); } @@ -445,6 +444,20 @@ final class Test } } + foreach (['method', 'class'] as $element) { + if (isset($annotations[$element]['covers'])) { + foreach ($annotations[$element]['covers'] as $coversTarget) { + $groups[] = ['__phpunit_covers_' . self::canonicalizeName($coversTarget)]; + } + } + + if (isset($annotations[$element]['uses'])) { + foreach ($annotations[$element]['uses'] as $usesTarget) { + $groups[] = ['__phpunit_uses_' . self::canonicalizeName($usesTarget)]; + } + } + } + return array_unique(array_merge([], ...$groups)); } @@ -542,6 +555,17 @@ final class Test ); } + if ($docBlock->isToBeExecutedAsPreCondition()) { + array_unshift( + self::$hookMethods[$className]['preCondition'], + $method->getName() + ); + } + + if ($docBlock->isToBeExecutedAsPostCondition()) { + self::$hookMethods[$className]['postCondition'][] = $method->getName(); + } + if ($docBlock->isToBeExecutedAfterTest()) { self::$hookMethods[$className]['after'][] = $method->getName(); } @@ -606,7 +630,8 @@ final class Test $list = array_merge($list, $annotations['method'][$mode]); } - $codeList = []; + $codeUnits = CodeUnitCollection::fromArray([]); + $mapper = new Mapper; foreach (array_unique($list) as $element) { if ($classShortcut && strncmp($element, '::', 2) === 0) { @@ -626,19 +651,33 @@ final class Test ); } - $codeList[] = self::resolveElementToReflectionObjects($element); + try { + $codeUnits = $codeUnits->mergeWith($mapper->stringToCodeUnits($element)); + } catch (InvalidCodeUnitException $e) { + throw new InvalidCoversTargetException( + sprintf( + '"@%s %s" is invalid', + $mode, + $element + ), + (int) $e->getCode(), + $e + ); + } } - return self::resolveReflectionObjectsToLines(array_merge([], ...$codeList)); + return $mapper->codeUnitsToSourceLines($codeUnits); } private static function emptyHookMethodsArray(): array { return [ - 'beforeClass' => ['setUpBeforeClass'], - 'before' => ['setUp'], - 'after' => ['tearDown'], - 'afterClass' => ['tearDownAfterClass'], + 'beforeClass' => ['setUpBeforeClass'], + 'before' => ['setUp'], + 'preCondition' => ['assertPreConditions'], + 'postCondition' => ['assertPostConditions'], + 'after' => ['tearDown'], + 'afterClass' => ['tearDownAfterClass'], ]; } @@ -673,200 +712,6 @@ final class Test return null; } - /** - * @throws InvalidCoversTargetException - */ - private static function resolveElementToReflectionObjects(string $element): array - { - $codeToCoverList = []; - - if (function_exists($element) && strpos($element, '\\') !== false) { - try { - $codeToCoverList[] = new ReflectionFunction($element); - // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new Exception( - $e->getMessage(), - (int) $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - } elseif (strpos($element, '::') !== false) { - [$className, $methodName] = explode('::', $element); - - if (isset($methodName[0]) && $methodName[0] === '<') { - $classes = [$className]; - - foreach ($classes as $className) { - if (!class_exists($className) && - !interface_exists($className) && - !trait_exists($className)) { - throw new InvalidCoversTargetException( - sprintf( - 'Trying to @cover or @use not existing class or ' . - 'interface "%s".', - $className - ) - ); - } - - try { - $methods = (new ReflectionClass($className))->getMethods(); - // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new Exception( - $e->getMessage(), - (int) $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - - $inverse = isset($methodName[1]) && $methodName[1] === '!'; - $visibility = 'isPublic'; - - if (strpos($methodName, 'protected')) { - $visibility = 'isProtected'; - } elseif (strpos($methodName, 'private')) { - $visibility = 'isPrivate'; - } - - foreach ($methods as $method) { - if ($inverse && !$method->{$visibility}()) { - $codeToCoverList[] = $method; - } elseif (!$inverse && $method->{$visibility}()) { - $codeToCoverList[] = $method; - } - } - } - } else { - $classes = [$className]; - - foreach ($classes as $className) { - if ($className === '' && function_exists($methodName)) { - try { - $codeToCoverList[] = new ReflectionFunction( - $methodName - ); - // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new Exception( - $e->getMessage(), - (int) $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - } else { - if (!((class_exists($className) || interface_exists($className) || trait_exists($className)) && - method_exists($className, $methodName))) { - throw new InvalidCoversTargetException( - sprintf( - 'Trying to @cover or @use not existing method "%s::%s".', - $className, - $methodName - ) - ); - } - - try { - $codeToCoverList[] = new ReflectionMethod( - $className, - $methodName - ); - // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new Exception( - $e->getMessage(), - (int) $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - } - } - } - } else { - $extended = false; - - if (strpos($element, '') !== false) { - $element = str_replace('', '', $element); - $extended = true; - } - - $classes = [$element]; - - if ($extended) { - $classes = array_merge( - $classes, - class_implements($element), - class_parents($element) - ); - } - - foreach ($classes as $className) { - if (!class_exists($className) && - !interface_exists($className) && - !trait_exists($className)) { - throw new InvalidCoversTargetException( - sprintf( - 'Trying to @cover or @use not existing class or ' . - 'interface "%s".', - $className - ) - ); - } - - try { - $codeToCoverList[] = new ReflectionClass($className); - // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new Exception( - $e->getMessage(), - (int) $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - } - } - - return $codeToCoverList; - } - - private static function resolveReflectionObjectsToLines(array $reflectors): array - { - $result = []; - - foreach ($reflectors as $reflector) { - if ($reflector instanceof ReflectionClass) { - foreach ($reflector->getTraits() as $trait) { - $reflectors[] = $trait; - } - } - } - - foreach ($reflectors as $reflector) { - $filename = $reflector->getFileName(); - - if (!isset($result[$filename])) { - $result[$filename] = []; - } - - $result[$filename] = array_merge( - $result[$filename], - range($reflector->getStartLine(), $reflector->getEndLine()) - ); - } - - foreach ($result as $filename => $lineNumbers) { - $result[$filename] = array_keys(array_flip($lineNumbers)); - } - - return $result; - } - /** * Trims any extensions from version string that follows after * the .[.] format. @@ -931,4 +776,9 @@ final class Test return $a; } + + private static function canonicalizeName(string $name): string + { + return strtolower(trim($name, '\\')); + } } diff --git a/vendor/phpunit/phpunit/src/Util/TestDox/CliTestDoxPrinter.php b/vendor/phpunit/phpunit/src/Util/TestDox/CliTestDoxPrinter.php index 49badb8be..7c0fc1174 100644 --- a/vendor/phpunit/phpunit/src/Util/TestDox/CliTestDoxPrinter.php +++ b/vendor/phpunit/phpunit/src/Util/TestDox/CliTestDoxPrinter.php @@ -27,6 +27,7 @@ use PHPUnit\Framework\TestResult; use PHPUnit\Runner\BaseTestRunner; use PHPUnit\Runner\PhptTestCase; use PHPUnit\Util\Color; +use SebastianBergmann\Timer\ResourceUsageFormatter; use SebastianBergmann\Timer\Timer; use Throwable; @@ -114,8 +115,25 @@ class CliTestDoxPrinter extends TestDoxPrinter private $nonSuccessfulTestResults = []; /** - * @throws \SebastianBergmann\Timer\RuntimeException + * @var Timer */ + private $timer; + + /** + * @param null|resource|string $out + * @param int|string $numberOfColumns + * + * @throws \PHPUnit\Framework\Exception + */ + public function __construct($out = null, bool $verbose = false, string $colors = self::COLOR_DEFAULT, bool $debug = false, $numberOfColumns = 80, bool $reverse = false) + { + parent::__construct($out, $verbose, $colors, $debug, $numberOfColumns, $reverse); + + $this->timer = new Timer; + + $this->timer->start(); + } + public function printResult(TestResult $result): void { $this->printHeader($result); @@ -125,12 +143,9 @@ class CliTestDoxPrinter extends TestDoxPrinter $this->printFooter($result); } - /** - * @throws \SebastianBergmann\Timer\RuntimeException - */ protected function printHeader(TestResult $result): void { - $this->write("\n" . Timer::resourceUsage() . "\n\n"); + $this->write("\n" . (new ResourceUsageFormatter)->resourceUsage($this->timer->stop()) . "\n\n"); } protected function formatClassName(Test $test): string diff --git a/vendor/phpunit/phpunit/src/Util/TestDox/HtmlResultPrinter.php b/vendor/phpunit/phpunit/src/Util/TestDox/HtmlResultPrinter.php index c57480327..d2bcbe527 100644 --- a/vendor/phpunit/phpunit/src/Util/TestDox/HtmlResultPrinter.php +++ b/vendor/phpunit/phpunit/src/Util/TestDox/HtmlResultPrinter.php @@ -10,6 +10,7 @@ namespace PHPUnit\Util\TestDox; use function sprintf; +use PHPUnit\Framework\TestResult; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit @@ -78,6 +79,10 @@ EOT; EOT; + public function printResult(TestResult $result): void + { + } + /** * Handler for 'start run' event. */ @@ -103,7 +108,7 @@ EOT; /** * Handler for 'on test' event. */ - protected function onTest($name, bool $success = true): void + protected function onTest(string $name, bool $success = true): void { $this->write( sprintf( diff --git a/vendor/phpunit/phpunit/src/Util/TestDox/NamePrettifier.php b/vendor/phpunit/phpunit/src/Util/TestDox/NamePrettifier.php index b7da1c2da..630bdd821 100644 --- a/vendor/phpunit/phpunit/src/Util/TestDox/NamePrettifier.php +++ b/vendor/phpunit/phpunit/src/Util/TestDox/NamePrettifier.php @@ -63,7 +63,7 @@ final class NamePrettifier */ private $useColor; - public function __construct($useColor = false) + public function __construct(bool $useColor = false) { $this->useColor = $useColor; } @@ -140,7 +140,11 @@ final class NamePrettifier */ public function prettifyTestCase(TestCase $test): string { - $annotations = $test->getAnnotations(); + $annotations = Test::parseTestMethodAnnotations( + get_class($test), + $test->getName(false) + ); + $annotationWithPlaceholders = false; $callback = static function (string $variable): string { diff --git a/vendor/phpunit/phpunit/src/Util/TestDox/ResultPrinter.php b/vendor/phpunit/phpunit/src/Util/TestDox/ResultPrinter.php index 1c2a5c93d..c4b63644f 100644 --- a/vendor/phpunit/phpunit/src/Util/TestDox/ResultPrinter.php +++ b/vendor/phpunit/phpunit/src/Util/TestDox/ResultPrinter.php @@ -12,20 +12,21 @@ namespace PHPUnit\Util\TestDox; use function get_class; use function in_array; use PHPUnit\Framework\AssertionFailedError; +use PHPUnit\Framework\ErrorTestCase; use PHPUnit\Framework\Test; use PHPUnit\Framework\TestCase; -use PHPUnit\Framework\TestListener; use PHPUnit\Framework\TestSuite; use PHPUnit\Framework\Warning; use PHPUnit\Framework\WarningTestCase; use PHPUnit\Runner\BaseTestRunner; +use PHPUnit\TextUI\ResultPrinter as ResultPrinterInterface; use PHPUnit\Util\Printer; use Throwable; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ -abstract class ResultPrinter extends Printer implements TestListener +abstract class ResultPrinter extends Printer implements ResultPrinterInterface { /** * @var NamePrettifier @@ -289,7 +290,7 @@ abstract class ResultPrinter extends Printer implements TestListener /** * Handler for 'on test' event. */ - protected function onTest($name, bool $success = true): void + protected function onTest(string $name, bool $success = true): void { } @@ -313,7 +314,7 @@ abstract class ResultPrinter extends Printer implements TestListener return false; } - if ($test instanceof WarningTestCase) { + if ($test instanceof ErrorTestCase || $test instanceof WarningTestCase) { return false; } diff --git a/vendor/phpunit/phpunit/src/Util/TestDox/TestDoxPrinter.php b/vendor/phpunit/phpunit/src/Util/TestDox/TestDoxPrinter.php index c19ba2699..088c6e018 100644 --- a/vendor/phpunit/phpunit/src/Util/TestDox/TestDoxPrinter.php +++ b/vendor/phpunit/phpunit/src/Util/TestDox/TestDoxPrinter.php @@ -13,9 +13,11 @@ use const PHP_EOL; use function array_map; use function get_class; use function implode; +use function method_exists; use function preg_split; use function trim; use PHPUnit\Framework\AssertionFailedError; +use PHPUnit\Framework\Reorderable; use PHPUnit\Framework\Test; use PHPUnit\Framework\TestCase; use PHPUnit\Framework\TestResult; @@ -23,14 +25,13 @@ use PHPUnit\Framework\TestSuite; use PHPUnit\Framework\Warning; use PHPUnit\Runner\BaseTestRunner; use PHPUnit\Runner\PhptTestCase; -use PHPUnit\Runner\TestSuiteSorter; -use PHPUnit\TextUI\ResultPrinter; +use PHPUnit\TextUI\DefaultResultPrinter; use Throwable; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ -class TestDoxPrinter extends ResultPrinter +class TestDoxPrinter extends DefaultResultPrinter { /** * @var NamePrettifier @@ -79,6 +80,7 @@ class TestDoxPrinter extends ResultPrinter /** * @param null|resource|string $out + * @param int|string $numberOfColumns * * @throws \PHPUnit\Framework\Exception */ @@ -187,7 +189,7 @@ class TestDoxPrinter extends ResultPrinter */ protected function registerTestResult(Test $test, ?Throwable $t, int $status, float $time, bool $verbose): void { - $testName = TestSuiteSorter::getTestSorterUID($test); + $testName = $test instanceof Reorderable ? $test->sortId() : $test->getName(); $result = [ 'className' => $this->formatClassName($test), @@ -209,7 +211,7 @@ class TestDoxPrinter extends ResultPrinter protected function formatTestName(Test $test): string { - return $test->getName(); + return method_exists($test, 'getName') ? $test->getName() : ''; } protected function formatClassName(Test $test): string diff --git a/vendor/phpunit/phpunit/src/Util/TestDox/TextResultPrinter.php b/vendor/phpunit/phpunit/src/Util/TestDox/TextResultPrinter.php index ee080039a..8a1893e55 100644 --- a/vendor/phpunit/phpunit/src/Util/TestDox/TextResultPrinter.php +++ b/vendor/phpunit/phpunit/src/Util/TestDox/TextResultPrinter.php @@ -9,11 +9,17 @@ */ namespace PHPUnit\Util\TestDox; +use PHPUnit\Framework\TestResult; + /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ final class TextResultPrinter extends ResultPrinter { + public function printResult(TestResult $result): void + { + } + /** * Handler for 'start class' event. */ @@ -25,7 +31,7 @@ final class TextResultPrinter extends ResultPrinter /** * Handler for 'on test' event. */ - protected function onTest($name, bool $success = true): void + protected function onTest(string $name, bool $success = true): void { if ($success) { $this->write(' [x] '); diff --git a/vendor/phpunit/phpunit/src/Util/TestDox/XmlResultPrinter.php b/vendor/phpunit/phpunit/src/Util/TestDox/XmlResultPrinter.php index 7a8d7d769..551c7d431 100644 --- a/vendor/phpunit/phpunit/src/Util/TestDox/XmlResultPrinter.php +++ b/vendor/phpunit/phpunit/src/Util/TestDox/XmlResultPrinter.php @@ -12,6 +12,7 @@ namespace PHPUnit\Util\TestDox; use function array_filter; use function get_class; use function implode; +use function strpos; use DOMDocument; use DOMElement; use PHPUnit\Framework\AssertionFailedError; @@ -21,7 +22,9 @@ use PHPUnit\Framework\TestCase; use PHPUnit\Framework\TestListener; use PHPUnit\Framework\TestSuite; use PHPUnit\Framework\Warning; +use PHPUnit\Framework\WarningTestCase; use PHPUnit\Util\Printer; +use PHPUnit\Util\Test as TestUtil; use ReflectionClass; use ReflectionException; use Throwable; @@ -152,14 +155,14 @@ final class XmlResultPrinter extends Printer implements TestListener */ public function endTest(Test $test, float $time): void { - if (!$test instanceof TestCase) { + if (!$test instanceof TestCase || $test instanceof WarningTestCase) { return; } $groups = array_filter( $test->getGroups(), static function ($group) { - return !($group === 'small' || $group === 'medium' || $group === 'large'); + return !($group === 'small' || $group === 'medium' || $group === 'large' || strpos($group, '__phpunit_') === 0); } ); @@ -182,7 +185,10 @@ final class XmlResultPrinter extends Printer implements TestListener $testNode->appendChild($groupNode); } - $annotations = $test->getAnnotations(); + $annotations = TestUtil::parseTestMethodAnnotations( + get_class($test), + $test->getName(false) + ); foreach (['class', 'method'] as $type) { foreach ($annotations[$type] as $annotation => $values) { diff --git a/vendor/phpunit/phpunit/src/Util/XdebugFilterScriptGenerator.php b/vendor/phpunit/phpunit/src/Util/XdebugFilterScriptGenerator.php index fc3510192..4a57528cc 100644 --- a/vendor/phpunit/phpunit/src/Util/XdebugFilterScriptGenerator.php +++ b/vendor/phpunit/phpunit/src/Util/XdebugFilterScriptGenerator.php @@ -16,16 +16,17 @@ use function implode; use function is_string; use function realpath; use function sprintf; +use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\CodeCoverage as FilterConfiguration; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit + * + * @deprecated */ final class XdebugFilterScriptGenerator { - public function generate(array $filterData): string + public function generate(FilterConfiguration $filter): string { - $items = $this->getWhitelistItems($filterData); - $files = array_map( static function ($item) { return sprintf( @@ -33,7 +34,7 @@ final class XdebugFilterScriptGenerator $item ); }, - $items + $this->getItems($filter) ); $files = implode(",\n", $files); @@ -55,27 +56,23 @@ if (!\\function_exists('xdebug_set_filter')) { EOF; } - private function getWhitelistItems(array $filterData): array + private function getItems(FilterConfiguration $filter): array { $files = []; - if (isset($filterData['include']['directory'])) { - foreach ($filterData['include']['directory'] as $directory) { - $path = realpath($directory['path']); + foreach ($filter->directories() as $directory) { + $path = realpath($directory->path()); - if (is_string($path)) { - $files[] = sprintf( - addslashes('%s' . DIRECTORY_SEPARATOR), - $path - ); - } + if (is_string($path)) { + $files[] = sprintf( + addslashes('%s' . DIRECTORY_SEPARATOR), + $path + ); } } - if (isset($filterData['include']['directory'])) { - foreach ($filterData['include']['file'] as $file) { - $files[] = $file; - } + foreach ($filter->files() as $file) { + $files[] = $file->path(); } return $files; diff --git a/vendor/phpunit/phpunit/src/Util/Xml.php b/vendor/phpunit/phpunit/src/Util/Xml.php index 1bf6a6146..0939e6c5b 100644 --- a/vendor/phpunit/phpunit/src/Util/Xml.php +++ b/vendor/phpunit/phpunit/src/Util/Xml.php @@ -11,29 +11,18 @@ namespace PHPUnit\Util; use const ENT_QUOTES; use function assert; -use function chdir; use function class_exists; -use function dirname; -use function error_reporting; -use function file_get_contents; -use function getcwd; -use function gettype; use function htmlspecialchars; -use function is_string; -use function libxml_get_errors; -use function libxml_use_internal_errors; use function mb_convert_encoding; use function ord; use function preg_replace; use function settype; -use function sprintf; use function strlen; use DOMCharacterData; use DOMDocument; use DOMElement; use DOMNode; use DOMText; -use PHPUnit\Framework\Exception; use ReflectionClass; use ReflectionException; @@ -42,127 +31,17 @@ use ReflectionException; */ final class Xml { + /** + * @deprecated Only used by assertEqualXMLStructure() + */ public static function import(DOMElement $element): DOMElement { return (new DOMDocument)->importNode($element, true); } /** - * Load an $actual document into a DOMDocument. This is called - * from the selector assertions. - * - * If $actual is already a DOMDocument, it is returned with - * no changes. Otherwise, $actual is loaded into a new DOMDocument - * as either HTML or XML, depending on the value of $isHtml. If $isHtml is - * false and $xinclude is true, xinclude is performed on the loaded - * DOMDocument. - * - * Note: prior to PHPUnit 3.3.0, this method loaded a file and - * not a string as it currently does. To load a file into a - * DOMDocument, use loadFile() instead. - * - * @param DOMDocument|string $actual - * - * @throws Exception + * @deprecated Only used by assertEqualXMLStructure() */ - public static function load($actual, bool $isHtml = false, string $filename = '', bool $xinclude = false, bool $strict = false): DOMDocument - { - if ($actual instanceof DOMDocument) { - return $actual; - } - - if (!is_string($actual)) { - throw new Exception('Could not load XML from ' . gettype($actual)); - } - - if ($actual === '') { - throw new Exception('Could not load XML from empty string'); - } - - // Required for XInclude on Windows. - if ($xinclude) { - $cwd = getcwd(); - @chdir(dirname($filename)); - } - - $document = new DOMDocument; - $document->preserveWhiteSpace = false; - - $internal = libxml_use_internal_errors(true); - $message = ''; - $reporting = error_reporting(0); - - if ($filename !== '') { - // Required for XInclude - $document->documentURI = $filename; - } - - if ($isHtml) { - $loaded = $document->loadHTML($actual); - } else { - $loaded = $document->loadXML($actual); - } - - if (!$isHtml && $xinclude) { - $document->xinclude(); - } - - foreach (libxml_get_errors() as $error) { - $message .= "\n" . $error->message; - } - - libxml_use_internal_errors($internal); - error_reporting($reporting); - - if (isset($cwd)) { - @chdir($cwd); - } - - if ($loaded === false || ($strict && $message !== '')) { - if ($filename !== '') { - throw new Exception( - sprintf( - 'Could not load "%s".%s', - $filename, - $message !== '' ? "\n" . $message : '' - ) - ); - } - - if ($message === '') { - $message = 'Could not load XML for unknown reason'; - } - - throw new Exception($message); - } - - return $document; - } - - /** - * Loads an XML (or HTML) file into a DOMDocument object. - * - * @throws Exception - */ - public static function loadFile(string $filename, bool $isHtml = false, bool $xinclude = false, bool $strict = false): DOMDocument - { - $reporting = error_reporting(0); - $contents = file_get_contents($filename); - - error_reporting($reporting); - - if ($contents === false) { - throw new Exception( - sprintf( - 'Could not read "%s".', - $filename - ) - ); - } - - return self::load($contents, $isHtml, $filename, $xinclude, $strict); - } - public static function removeCharacterDataNodes(DOMNode $node): void { if ($node->hasChildNodes()) { diff --git a/vendor/phpunit/phpunit/src/TextUI/Exception.php b/vendor/phpunit/phpunit/src/Util/Xml/Exception.php similarity index 94% rename from vendor/phpunit/phpunit/src/TextUI/Exception.php rename to vendor/phpunit/phpunit/src/Util/Xml/Exception.php index 7c261e58e..09b73d8fa 100644 --- a/vendor/phpunit/phpunit/src/TextUI/Exception.php +++ b/vendor/phpunit/phpunit/src/Util/Xml/Exception.php @@ -7,7 +7,7 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ -namespace PHPUnit\TextUI; +namespace PHPUnit\Util\Xml; use RuntimeException; diff --git a/vendor/phpunit/phpunit/src/Util/Xml/FailedSchemaDetectionResult.php b/vendor/phpunit/phpunit/src/Util/Xml/FailedSchemaDetectionResult.php new file mode 100644 index 000000000..0949f5684 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Util/Xml/FailedSchemaDetectionResult.php @@ -0,0 +1,19 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Util\Xml; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * + * @psalm-immutable + */ +final class FailedSchemaDetectionResult extends SchemaDetectionResult +{ +} diff --git a/vendor/phpunit/phpunit/src/Util/Xml/Loader.php b/vendor/phpunit/phpunit/src/Util/Xml/Loader.php new file mode 100644 index 000000000..8d43d3278 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Util/Xml/Loader.php @@ -0,0 +1,117 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Util\Xml; + +use function chdir; +use function dirname; +use function error_reporting; +use function file_get_contents; +use function getcwd; +use function libxml_get_errors; +use function libxml_use_internal_errors; +use function sprintf; +use DOMDocument; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class Loader +{ + /** + * @throws Exception + */ + public function loadFile(string $filename, bool $isHtml = false, bool $xinclude = false, bool $strict = false): DOMDocument + { + $reporting = error_reporting(0); + $contents = file_get_contents($filename); + + error_reporting($reporting); + + if ($contents === false) { + throw new Exception( + sprintf( + 'Could not read "%s".', + $filename + ) + ); + } + + return $this->load($contents, $isHtml, $filename, $xinclude, $strict); + } + + /** + * @throws Exception + */ + public function load(string $actual, bool $isHtml = false, string $filename = '', bool $xinclude = false, bool $strict = false): DOMDocument + { + if ($actual === '') { + throw new Exception('Could not load XML from empty string'); + } + + // Required for XInclude on Windows. + if ($xinclude) { + $cwd = getcwd(); + @chdir(dirname($filename)); + } + + $document = new DOMDocument; + $document->preserveWhiteSpace = false; + + $internal = libxml_use_internal_errors(true); + $message = ''; + $reporting = error_reporting(0); + + if ($filename !== '') { + // Required for XInclude + $document->documentURI = $filename; + } + + if ($isHtml) { + $loaded = $document->loadHTML($actual); + } else { + $loaded = $document->loadXML($actual); + } + + if (!$isHtml && $xinclude) { + $document->xinclude(); + } + + foreach (libxml_get_errors() as $error) { + $message .= "\n" . $error->message; + } + + libxml_use_internal_errors($internal); + error_reporting($reporting); + + if (isset($cwd)) { + @chdir($cwd); + } + + if ($loaded === false || ($strict && $message !== '')) { + if ($filename !== '') { + throw new Exception( + sprintf( + 'Could not load "%s".%s', + $filename, + $message !== '' ? "\n" . $message : '' + ) + ); + } + + if ($message === '') { + $message = 'Could not load XML for unknown reason'; + } + + throw new Exception($message); + } + + return $document; + } +} diff --git a/vendor/phpunit/phpunit/src/Util/Xml/SchemaDetectionResult.php b/vendor/phpunit/phpunit/src/Util/Xml/SchemaDetectionResult.php new file mode 100644 index 000000000..442aae49c --- /dev/null +++ b/vendor/phpunit/phpunit/src/Util/Xml/SchemaDetectionResult.php @@ -0,0 +1,31 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Util\Xml; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * + * @psalm-immutable + */ +abstract class SchemaDetectionResult +{ + public function detected(): bool + { + return false; + } + + /** + * @throws Exception + */ + public function version(): string + { + throw new Exception('No supported schema was detected'); + } +} diff --git a/vendor/phpunit/phpunit/src/Util/Xml/SchemaDetector.php b/vendor/phpunit/phpunit/src/Util/Xml/SchemaDetector.php new file mode 100644 index 000000000..5864695b4 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Util/Xml/SchemaDetector.php @@ -0,0 +1,39 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Util\Xml; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class SchemaDetector +{ + /** + * @throws Exception + */ + public function detect(string $filename): SchemaDetectionResult + { + $document = (new Loader)->loadFile( + $filename, + false, + true, + true + ); + + foreach (['9.2', '8.5'] as $candidate) { + $schema = (new SchemaFinder)->find($candidate); + + if (!(new Validator)->validate($document, $schema)->hasValidationErrors()) { + return new SuccessfulSchemaDetectionResult($candidate); + } + } + + return new FailedSchemaDetectionResult; + } +} diff --git a/vendor/phpunit/phpunit/src/Util/Xml/SchemaFinder.php b/vendor/phpunit/phpunit/src/Util/Xml/SchemaFinder.php new file mode 100644 index 000000000..1e7b73c59 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Util/Xml/SchemaFinder.php @@ -0,0 +1,53 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Util\Xml; + +use function defined; +use function is_file; +use function sprintf; +use PHPUnit\Runner\Version; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class SchemaFinder +{ + /** + * @throws Exception + */ + public function find(string $version): string + { + if ($version === Version::series()) { + $filename = $this->path() . 'phpunit.xsd'; + } else { + $filename = $this->path() . 'schema/' . $version . '.xsd'; + } + + if (!is_file($filename)) { + throw new Exception( + sprintf( + 'Schema for PHPUnit %s is not available', + $version + ) + ); + } + + return $filename; + } + + private function path(): string + { + if (defined('__PHPUNIT_PHAR_ROOT__')) { + return __PHPUNIT_PHAR_ROOT__ . '/'; + } + + return __DIR__ . '/../../../'; + } +} diff --git a/vendor/phpunit/phpunit/src/Util/Xml/SnapshotNodeList.php b/vendor/phpunit/phpunit/src/Util/Xml/SnapshotNodeList.php new file mode 100644 index 000000000..fdc95abb8 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Util/Xml/SnapshotNodeList.php @@ -0,0 +1,48 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Util\Xml; + +use ArrayIterator; +use Countable; +use DOMNode; +use DOMNodeList; +use IteratorAggregate; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class SnapshotNodeList implements Countable, IteratorAggregate +{ + /** + * @var DOMNode[] + */ + private $nodes = []; + + public static function fromNodeList(DOMNodeList $list): self + { + $snapshot = new self; + + foreach ($list as $node) { + $snapshot->nodes[] = $node; + } + + return $snapshot; + } + + public function count(): int + { + return count($this->nodes); + } + + public function getIterator(): ArrayIterator + { + return new ArrayIterator($this->nodes); + } +} diff --git a/vendor/phpunit/phpunit/src/Util/Xml/SuccessfulSchemaDetectionResult.php b/vendor/phpunit/phpunit/src/Util/Xml/SuccessfulSchemaDetectionResult.php new file mode 100644 index 000000000..8b517e29a --- /dev/null +++ b/vendor/phpunit/phpunit/src/Util/Xml/SuccessfulSchemaDetectionResult.php @@ -0,0 +1,38 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Util\Xml; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * + * @psalm-immutable + */ +final class SuccessfulSchemaDetectionResult extends SchemaDetectionResult +{ + /** + * @var string + */ + private $version; + + public function __construct(string $version) + { + $this->version = $version; + } + + public function detected(): bool + { + return true; + } + + public function version(): string + { + return $this->version; + } +} diff --git a/vendor/phpunit/phpunit/src/Util/Xml/ValidationResult.php b/vendor/phpunit/phpunit/src/Util/Xml/ValidationResult.php new file mode 100644 index 000000000..3292267bd --- /dev/null +++ b/vendor/phpunit/phpunit/src/Util/Xml/ValidationResult.php @@ -0,0 +1,69 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Util\Xml; + +use function sprintf; +use function trim; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + * + * @psalm-immutable + */ +final class ValidationResult +{ + /** + * @psalm-var array> + */ + private $validationErrors = []; + + /** + * @psalm-param array $errors + */ + public static function fromArray(array $errors): self + { + $validationErrors = []; + + foreach ($errors as $error) { + if (!isset($validationErrors[$error->line])) { + $validationErrors[$error->line] = []; + } + + $validationErrors[$error->line][] = trim($error->message); + } + + return new self($validationErrors); + } + + private function __construct(array $validationErrors) + { + $this->validationErrors = $validationErrors; + } + + public function hasValidationErrors(): bool + { + return !empty($this->validationErrors); + } + + public function asString(): string + { + $buffer = ''; + + foreach ($this->validationErrors as $line => $validationErrorsOnLine) { + $buffer .= sprintf(PHP_EOL . ' Line %d:' . PHP_EOL, $line); + + foreach ($validationErrorsOnLine as $validationError) { + $buffer .= sprintf(' - %s' . PHP_EOL, $validationError); + } + } + + return $buffer; + } +} diff --git a/vendor/phpunit/phpunit/src/Util/Xml/Validator.php b/vendor/phpunit/phpunit/src/Util/Xml/Validator.php new file mode 100644 index 000000000..b3c4e05b1 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Util/Xml/Validator.php @@ -0,0 +1,35 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Util\Xml; + +use function file_get_contents; +use function libxml_clear_errors; +use function libxml_get_errors; +use function libxml_use_internal_errors; +use DOMDocument; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class Validator +{ + public function validate(DOMDocument $document, string $xsdFilename): ValidationResult + { + $originalErrorHandling = libxml_use_internal_errors(true); + + $document->schemaValidateSource(file_get_contents($xsdFilename)); + + $errors = libxml_get_errors(); + libxml_clear_errors(); + libxml_use_internal_errors($originalErrorHandling); + + return ValidationResult::fromArray($errors); + } +} diff --git a/vendor/psr/http-client/CHANGELOG.md b/vendor/psr/http-client/CHANGELOG.md new file mode 100644 index 000000000..e2dc25f51 --- /dev/null +++ b/vendor/psr/http-client/CHANGELOG.md @@ -0,0 +1,23 @@ +# Changelog + +All notable changes to this project will be documented in this file, in reverse chronological order by release. + +## 1.0.1 + +Allow installation with PHP 8. No code changes. + +## 1.0.0 + +First stable release. No changes since 0.3.0. + +## 0.3.0 + +Added Interface suffix on exceptions + +## 0.2.0 + +All exceptions are in `Psr\Http\Client` namespace + +## 0.1.0 + +First release diff --git a/vendor/psr/http-client/LICENSE b/vendor/psr/http-client/LICENSE new file mode 100644 index 000000000..cd5e0020a --- /dev/null +++ b/vendor/psr/http-client/LICENSE @@ -0,0 +1,19 @@ +Copyright (c) 2017 PHP Framework Interoperability Group + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vendor/psr/http-client/README.md b/vendor/psr/http-client/README.md new file mode 100644 index 000000000..6876b8403 --- /dev/null +++ b/vendor/psr/http-client/README.md @@ -0,0 +1,12 @@ +HTTP Client +=========== + +This repository holds all the common code related to [PSR-18 (HTTP Client)][psr-url]. + +Note that this is not a HTTP Client implementation of its own. It is merely abstractions that describe the components of a HTTP Client. + +The installable [package][package-url] and [implementations][implementation-url] are listed on Packagist. + +[psr-url]: http://www.php-fig.org/psr/psr-18 +[package-url]: https://packagist.org/packages/psr/http-client +[implementation-url]: https://packagist.org/providers/psr/http-client-implementation diff --git a/vendor/psr/http-client/composer.json b/vendor/psr/http-client/composer.json new file mode 100644 index 000000000..c195f8ff1 --- /dev/null +++ b/vendor/psr/http-client/composer.json @@ -0,0 +1,27 @@ +{ + "name": "psr/http-client", + "description": "Common interface for HTTP clients", + "keywords": ["psr", "psr-18", "http", "http-client"], + "homepage": "https://github.com/php-fig/http-client", + "license": "MIT", + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" + } + ], + "require": { + "php": "^7.0 || ^8.0", + "psr/http-message": "^1.0" + }, + "autoload": { + "psr-4": { + "Psr\\Http\\Client\\": "src/" + } + }, + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + } +} diff --git a/vendor/psr/http-client/src/ClientExceptionInterface.php b/vendor/psr/http-client/src/ClientExceptionInterface.php new file mode 100644 index 000000000..aa0b9cf14 --- /dev/null +++ b/vendor/psr/http-client/src/ClientExceptionInterface.php @@ -0,0 +1,10 @@ +=7.3` + +## [1.0.0] - 2020-08-12 + +* Initial release + +[1.0.0]: https://github.com/sebastianbergmann/cli-parser/compare/bb7bb3297957927962b0a3335befe7b66f7462e9...1.0.0 diff --git a/vendor/sebastian/cli-parser/LICENSE b/vendor/sebastian/cli-parser/LICENSE new file mode 100644 index 000000000..0e33c0591 --- /dev/null +++ b/vendor/sebastian/cli-parser/LICENSE @@ -0,0 +1,33 @@ +sebastian/cli-parser + +Copyright (c) 2020, Sebastian Bergmann . +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: + + * Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + * Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in + the documentation and/or other materials provided with the + distribution. + + * Neither the name of Sebastian Bergmann nor the names of his + contributors may be used to endorse or promote products derived + from this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS +FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN +ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +POSSIBILITY OF SUCH DAMAGE. diff --git a/vendor/sebastian/cli-parser/README.md b/vendor/sebastian/cli-parser/README.md new file mode 100644 index 000000000..39c17a72c --- /dev/null +++ b/vendor/sebastian/cli-parser/README.md @@ -0,0 +1,17 @@ +# sebastian/cli-parser + +Library for parsing `$_SERVER['argv']`, extracted from `phpunit/phpunit`. + +## Installation + +You can add this library as a local, per-project dependency to your project using [Composer](https://getcomposer.org/): + +``` +composer require sebastian/cli-parser +``` + +If you only need this library during development, for instance to run your project's test suite, then you should add it as a development-time dependency: + +``` +composer require --dev sebastian/cli-parser +``` diff --git a/vendor/phpunit/php-token-stream/composer.json b/vendor/sebastian/cli-parser/composer.json similarity index 53% rename from vendor/phpunit/php-token-stream/composer.json rename to vendor/sebastian/cli-parser/composer.json index e0d0b4de7..34c376f91 100644 --- a/vendor/phpunit/php-token-stream/composer.json +++ b/vendor/sebastian/cli-parser/composer.json @@ -1,26 +1,25 @@ { - "name": "phpunit/php-token-stream", - "description": "Wrapper around PHP's tokenizer extension.", + "name": "sebastian/cli-parser", + "description": "Library for parsing CLI options", "type": "library", - "keywords": ["tokenizer"], - "homepage": "https://github.com/sebastianbergmann/php-token-stream/", + "homepage": "https://github.com/sebastianbergmann/cli-parser", "license": "BSD-3-Clause", "authors": [ { "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" + "email": "sebastian@phpunit.de", + "role": "lead" } ], "support": { - "issues": "https://github.com/sebastianbergmann/php-token-stream/issues" + "issues": "https://github.com/sebastianbergmann/cli-parser/issues" }, "prefer-stable": true, "require": { - "php": "^7.3 || ^8.0", - "ext-tokenizer": "*" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^9.0" + "phpunit/phpunit": "^9.3" }, "config": { "platform": { @@ -36,7 +35,7 @@ }, "extra": { "branch-alias": { - "dev-master": "4.0-dev" + "dev-master": "1.0-dev" } } } diff --git a/vendor/sebastian/cli-parser/infection.json b/vendor/sebastian/cli-parser/infection.json new file mode 100644 index 000000000..09546514f --- /dev/null +++ b/vendor/sebastian/cli-parser/infection.json @@ -0,0 +1,12 @@ +{ + "source": { + "directories": [ + "src" + ] + }, + "mutators": { + "@default": true + }, + "minMsi": 100, + "minCoveredMsi": 100 +} diff --git a/vendor/sebastian/cli-parser/src/Parser.php b/vendor/sebastian/cli-parser/src/Parser.php new file mode 100644 index 000000000..a4f728bc6 --- /dev/null +++ b/vendor/sebastian/cli-parser/src/Parser.php @@ -0,0 +1,204 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CliParser; + +use function array_map; +use function array_merge; +use function array_shift; +use function array_slice; +use function assert; +use function count; +use function current; +use function explode; +use function is_array; +use function is_int; +use function is_string; +use function key; +use function next; +use function preg_replace; +use function reset; +use function sort; +use function strlen; +use function strpos; +use function strstr; +use function substr; + +final class Parser +{ + /** + * @psalm-param list $argv + * @psalm-param list $longOptions + * + * @throws AmbiguousOptionException + * @throws RequiredOptionArgumentMissingException + * @throws OptionDoesNotAllowArgumentException + * @throws UnknownOptionException + */ + public function parse(array $argv, string $shortOptions, array $longOptions = null): array + { + if (empty($argv)) { + return [[], []]; + } + + $options = []; + $nonOptions = []; + + if ($longOptions) { + sort($longOptions); + } + + if (isset($argv[0][0]) && $argv[0][0] !== '-') { + array_shift($argv); + } + + reset($argv); + + $argv = array_map('trim', $argv); + + while (false !== $arg = current($argv)) { + $i = key($argv); + + assert(is_int($i)); + + next($argv); + + if ($arg === '') { + continue; + } + + if ($arg === '--') { + $nonOptions = array_merge($nonOptions, array_slice($argv, $i + 1)); + + break; + } + + if ($arg[0] !== '-' || (strlen($arg) > 1 && $arg[1] === '-' && !$longOptions)) { + $nonOptions[] = $arg; + + continue; + } + + if (strlen($arg) > 1 && $arg[1] === '-' && is_array($longOptions)) { + $this->parseLongOption( + substr($arg, 2), + $longOptions, + $options, + $argv + ); + } else { + $this->parseShortOption( + substr($arg, 1), + $shortOptions, + $options, + $argv + ); + } + } + + return [$options, $nonOptions]; + } + + /** + * @throws RequiredOptionArgumentMissingException + */ + private function parseShortOption(string $arg, string $shortOptions, array &$opts, array &$args): void + { + $argLength = strlen($arg); + + for ($i = 0; $i < $argLength; $i++) { + $option = $arg[$i]; + $optionArgument = null; + + if ($arg[$i] === ':' || ($spec = strstr($shortOptions, $option)) === false) { + throw new UnknownOptionException('-' . $option); + } + + assert(is_string($spec)); + + if (strlen($spec) > 1 && $spec[1] === ':') { + if ($i + 1 < $argLength) { + $opts[] = [$option, substr($arg, $i + 1)]; + + break; + } + + if (!(strlen($spec) > 2 && $spec[2] === ':')) { + $optionArgument = current($args); + + if (!$optionArgument) { + throw new RequiredOptionArgumentMissingException('-' . $option); + } + + assert(is_string($optionArgument)); + + next($args); + } + } + + $opts[] = [$option, $optionArgument]; + } + } + + /** + * @psalm-param list $longOptions + * + * @throws AmbiguousOptionException + * @throws RequiredOptionArgumentMissingException + * @throws OptionDoesNotAllowArgumentException + * @throws UnknownOptionException + */ + private function parseLongOption(string $arg, array $longOptions, array &$opts, array &$args): void + { + $count = count($longOptions); + $list = explode('=', $arg); + $option = $list[0]; + $optionArgument = null; + + if (count($list) > 1) { + $optionArgument = $list[1]; + } + + $optionLength = strlen($option); + + foreach ($longOptions as $i => $longOption) { + $opt_start = substr($longOption, 0, $optionLength); + + if ($opt_start !== $option) { + continue; + } + + $opt_rest = substr($longOption, $optionLength); + + if ($opt_rest !== '' && $i + 1 < $count && $option[0] !== '=' && strpos($longOptions[$i + 1], $option) === 0) { + throw new AmbiguousOptionException('--' . $option); + } + + if (substr($longOption, -1) === '=') { + /* @noinspection StrlenInEmptyStringCheckContextInspection */ + if (substr($longOption, -2) !== '==' && !strlen((string) $optionArgument)) { + if (false === $optionArgument = current($args)) { + throw new RequiredOptionArgumentMissingException('--' . $option); + } + + next($args); + } + } elseif ($optionArgument) { + throw new OptionDoesNotAllowArgumentException('--' . $option); + } + + $fullOption = '--' . preg_replace('/={1,2}$/', '', $longOption); + $opts[] = [$fullOption, $optionArgument]; + + return; + } + + throw new UnknownOptionException('--' . $option); + } +} diff --git a/vendor/sebastian/cli-parser/src/exceptions/AmbiguousOptionException.php b/vendor/sebastian/cli-parser/src/exceptions/AmbiguousOptionException.php new file mode 100644 index 000000000..a99f63697 --- /dev/null +++ b/vendor/sebastian/cli-parser/src/exceptions/AmbiguousOptionException.php @@ -0,0 +1,26 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CliParser; + +use function sprintf; +use RuntimeException; + +final class AmbiguousOptionException extends RuntimeException implements Exception +{ + public function __construct(string $option) + { + parent::__construct( + sprintf( + 'Option "%s" is ambiguous', + $option + ) + ); + } +} diff --git a/vendor/sebastian/global-state/tests/_fixture/SnapshotTrait.php b/vendor/sebastian/cli-parser/src/exceptions/Exception.php similarity index 61% rename from vendor/sebastian/global-state/tests/_fixture/SnapshotTrait.php rename to vendor/sebastian/cli-parser/src/exceptions/Exception.php index c3490a6ef..f35ad2457 100644 --- a/vendor/sebastian/global-state/tests/_fixture/SnapshotTrait.php +++ b/vendor/sebastian/cli-parser/src/exceptions/Exception.php @@ -1,14 +1,16 @@ * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ -namespace SebastianBergmann\GlobalState\TestFixture; +namespace SebastianBergmann\CliParser; -trait SnapshotTrait +use Throwable; + +interface Exception extends Throwable { } diff --git a/vendor/sebastian/cli-parser/src/exceptions/OptionDoesNotAllowArgumentException.php b/vendor/sebastian/cli-parser/src/exceptions/OptionDoesNotAllowArgumentException.php new file mode 100644 index 000000000..0aad29ac0 --- /dev/null +++ b/vendor/sebastian/cli-parser/src/exceptions/OptionDoesNotAllowArgumentException.php @@ -0,0 +1,26 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CliParser; + +use function sprintf; +use RuntimeException; + +final class OptionDoesNotAllowArgumentException extends RuntimeException implements Exception +{ + public function __construct(string $option) + { + parent::__construct( + sprintf( + 'Option "%s" does not allow an argument', + $option + ) + ); + } +} diff --git a/vendor/sebastian/cli-parser/src/exceptions/RequiredOptionArgumentMissingException.php b/vendor/sebastian/cli-parser/src/exceptions/RequiredOptionArgumentMissingException.php new file mode 100644 index 000000000..d2a930b62 --- /dev/null +++ b/vendor/sebastian/cli-parser/src/exceptions/RequiredOptionArgumentMissingException.php @@ -0,0 +1,26 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CliParser; + +use function sprintf; +use RuntimeException; + +final class RequiredOptionArgumentMissingException extends RuntimeException implements Exception +{ + public function __construct(string $option) + { + parent::__construct( + sprintf( + 'Required argument for option "%s" is missing', + $option + ) + ); + } +} diff --git a/vendor/sebastian/cli-parser/src/exceptions/UnknownOptionException.php b/vendor/sebastian/cli-parser/src/exceptions/UnknownOptionException.php new file mode 100644 index 000000000..e98d9fd02 --- /dev/null +++ b/vendor/sebastian/cli-parser/src/exceptions/UnknownOptionException.php @@ -0,0 +1,26 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CliParser; + +use function sprintf; +use RuntimeException; + +final class UnknownOptionException extends RuntimeException implements Exception +{ + public function __construct(string $option) + { + parent::__construct( + sprintf( + 'Unknown option "%s"', + $option + ) + ); + } +} diff --git a/vendor/sebastian/code-unit-reverse-lookup/.gitignore b/vendor/sebastian/code-unit-reverse-lookup/.gitignore deleted file mode 100644 index 9e5f1db31..000000000 --- a/vendor/sebastian/code-unit-reverse-lookup/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -/.idea -/composer.lock -/vendor - diff --git a/vendor/sebastian/code-unit-reverse-lookup/.php_cs b/vendor/sebastian/code-unit-reverse-lookup/.php_cs deleted file mode 100644 index b7393bdac..000000000 --- a/vendor/sebastian/code-unit-reverse-lookup/.php_cs +++ /dev/null @@ -1,67 +0,0 @@ -files() - ->in('src') - ->in('tests') - ->name('*.php'); - -return Symfony\CS\Config\Config::create() - ->level(\Symfony\CS\FixerInterface::NONE_LEVEL) - ->fixers( - array( - 'align_double_arrow', - 'align_equals', - 'braces', - 'concat_with_spaces', - 'duplicate_semicolon', - 'elseif', - 'empty_return', - 'encoding', - 'eof_ending', - 'extra_empty_lines', - 'function_call_space', - 'function_declaration', - 'indentation', - 'join_function', - 'line_after_namespace', - 'linefeed', - 'list_commas', - 'lowercase_constants', - 'lowercase_keywords', - 'method_argument_space', - 'multiple_use', - 'namespace_no_leading_whitespace', - 'no_blank_lines_after_class_opening', - 'no_empty_lines_after_phpdocs', - 'parenthesis', - 'php_closing_tag', - 'phpdoc_indent', - 'phpdoc_no_access', - 'phpdoc_no_empty_return', - 'phpdoc_no_package', - 'phpdoc_params', - 'phpdoc_scalar', - 'phpdoc_separation', - 'phpdoc_to_comment', - 'phpdoc_trim', - 'phpdoc_types', - 'phpdoc_var_without_name', - 'remove_lines_between_uses', - 'return', - 'self_accessor', - 'short_array_syntax', - 'short_tag', - 'single_line_after_imports', - 'single_quote', - 'spaces_before_semicolon', - 'spaces_cast', - 'ternary_spaces', - 'trailing_spaces', - 'trim_array_spaces', - 'unused_use', - 'visibility', - 'whitespacy_lines' - ) - ) - ->finder($finder); - diff --git a/vendor/sebastian/code-unit-reverse-lookup/.travis.yml b/vendor/sebastian/code-unit-reverse-lookup/.travis.yml deleted file mode 100644 index 9d9c9d978..000000000 --- a/vendor/sebastian/code-unit-reverse-lookup/.travis.yml +++ /dev/null @@ -1,25 +0,0 @@ -language: php - -php: - - 5.6 - - 7.0 - - 7.0snapshot - - 7.1 - - 7.1snapshot - - master - -sudo: false - -before_install: - - composer self-update - - composer clear-cache - -install: - - travis_retry composer update --no-interaction --no-ansi --no-progress --no-suggest --optimize-autoloader --prefer-stable - -script: - - ./vendor/bin/phpunit - -notifications: - email: false - diff --git a/vendor/sebastian/code-unit-reverse-lookup/ChangeLog.md b/vendor/sebastian/code-unit-reverse-lookup/ChangeLog.md index d136bf58f..43a5db90d 100644 --- a/vendor/sebastian/code-unit-reverse-lookup/ChangeLog.md +++ b/vendor/sebastian/code-unit-reverse-lookup/ChangeLog.md @@ -2,14 +2,37 @@ All notable changes to `sebastianbergmann/code-unit-reverse-lookup` are documented in this file using the [Keep a CHANGELOG](http://keepachangelog.com/) principles. -## [1.0.2] - 2020-11-30 +## [2.0.3] - 2020-09-28 ### Changed -* Changed PHP version constraint in `composer.json` from `^5.6 || ^7.0` to `>=5.6` +* Changed PHP version constraint in `composer.json` from `^7.3 || ^8.0` to `>=7.3` + +## [2.0.2] - 2020-06-26 + +### Added + +* This component is now supported on PHP 8 + +## [2.0.1] - 2020-06-15 + +### Changed + +* Tests etc. are now ignored for archive exports + +## 2.0.0 - 2020-02-07 + +### Removed + +* This component is no longer supported on PHP 5.6, PHP 7.0, PHP 7.1, and PHP 7.2 ## 1.0.0 - 2016-02-13 +### Added + * Initial release -[1.0.2]: https://github.com/sebastianbergmann/code-unit-reverse-lookup/compare/1.0.1...1.0.2 +[2.0.3]: https://github.com/sebastianbergmann/code-unit-reverse-lookup/compare/2.0.2...2.0.3 +[2.0.2]: https://github.com/sebastianbergmann/code-unit-reverse-lookup/compare/2.0.1...2.0.2 +[2.0.1]: https://github.com/sebastianbergmann/code-unit-reverse-lookup/compare/2.0.0...2.0.1 +[2.0.0]: https://github.com/sebastianbergmann/code-unit-reverse-lookup/compare/1.0.0...2.0.0 diff --git a/vendor/sebastian/code-unit-reverse-lookup/LICENSE b/vendor/sebastian/code-unit-reverse-lookup/LICENSE index 8f243844c..dc4bf7019 100644 --- a/vendor/sebastian/code-unit-reverse-lookup/LICENSE +++ b/vendor/sebastian/code-unit-reverse-lookup/LICENSE @@ -1,6 +1,6 @@ code-unit-reverse-lookup -Copyright (c) 2016-2017, Sebastian Bergmann . +Copyright (c) 2016-2020, Sebastian Bergmann . All rights reserved. Redistribution and use in source and binary forms, with or without diff --git a/vendor/sebastian/code-unit-reverse-lookup/README.md b/vendor/sebastian/code-unit-reverse-lookup/README.md index 2bf26afd3..1c0ca235e 100644 --- a/vendor/sebastian/code-unit-reverse-lookup/README.md +++ b/vendor/sebastian/code-unit-reverse-lookup/README.md @@ -1,4 +1,7 @@ -# code-unit-reverse-lookup +# sebastian/code-unit-reverse-lookup + +[![CI Status](https://github.com/sebastianbergmann/code-unit-reverse-lookup/workflows/CI/badge.svg)](https://github.com/sebastianbergmann/code-unit-reverse-lookup/actions) +[![Type Coverage](https://shepherd.dev/github/sebastianbergmann/code-unit-reverse-lookup/coverage.svg)](https://shepherd.dev/github/sebastianbergmann/code-unit-reverse-lookup) Looks up which function or method a line of code belongs to. @@ -6,9 +9,12 @@ Looks up which function or method a line of code belongs to. You can add this library as a local, per-project dependency to your project using [Composer](https://getcomposer.org/): - composer require sebastian/code-unit-reverse-lookup +``` +composer require sebastian/code-unit-reverse-lookup +``` If you only need this library during development, for instance to run your project's test suite, then you should add it as a development-time dependency: - composer require --dev sebastian/code-unit-reverse-lookup - +``` +composer require --dev sebastian/code-unit-reverse-lookup +``` diff --git a/vendor/sebastian/code-unit-reverse-lookup/build.xml b/vendor/sebastian/code-unit-reverse-lookup/build.xml deleted file mode 100644 index 24cf32e89..000000000 --- a/vendor/sebastian/code-unit-reverse-lookup/build.xml +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - diff --git a/vendor/sebastian/code-unit-reverse-lookup/composer.json b/vendor/sebastian/code-unit-reverse-lookup/composer.json index ba32ed635..cff96167a 100644 --- a/vendor/sebastian/code-unit-reverse-lookup/composer.json +++ b/vendor/sebastian/code-unit-reverse-lookup/composer.json @@ -9,11 +9,19 @@ "email": "sebastian@phpunit.de" } ], + "prefer-stable": true, + "config": { + "platform": { + "php": "7.3.0" + }, + "optimize-autoloader": true, + "sort-packages": true + }, "require": { - "php": ">=5.6" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^8.5" + "phpunit/phpunit": "^9.3" }, "autoload": { "classmap": [ @@ -22,7 +30,7 @@ }, "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "2.0-dev" } } } diff --git a/vendor/sebastian/code-unit-reverse-lookup/phpunit.xml b/vendor/sebastian/code-unit-reverse-lookup/phpunit.xml deleted file mode 100644 index 2c0569e4a..000000000 --- a/vendor/sebastian/code-unit-reverse-lookup/phpunit.xml +++ /dev/null @@ -1,21 +0,0 @@ - - - - tests - - - - - src - - - diff --git a/vendor/sebastian/code-unit-reverse-lookup/src/Wizard.php b/vendor/sebastian/code-unit-reverse-lookup/src/Wizard.php index 20f8880fe..35de53981 100644 --- a/vendor/sebastian/code-unit-reverse-lookup/src/Wizard.php +++ b/vendor/sebastian/code-unit-reverse-lookup/src/Wizard.php @@ -1,15 +1,26 @@ - * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\CodeUnitReverseLookup; +use function array_merge; +use function assert; +use function get_declared_classes; +use function get_declared_traits; +use function get_defined_functions; +use function is_array; +use function range; +use ReflectionClass; +use ReflectionFunction; +use ReflectionFunctionAbstract; +use ReflectionMethod; + /** * @since Class available since Release 1.0.0 */ @@ -44,25 +55,31 @@ class Wizard if (isset($this->lookupTable[$filename][$lineNumber])) { return $this->lookupTable[$filename][$lineNumber]; - } else { - return $filename . ':' . $lineNumber; } + + return $filename . ':' . $lineNumber; } - private function updateLookupTable() + private function updateLookupTable(): void { $this->processClassesAndTraits(); $this->processFunctions(); } - private function processClassesAndTraits() + private function processClassesAndTraits(): void { - foreach (array_merge(get_declared_classes(), get_declared_traits()) as $classOrTrait) { + $classes = get_declared_classes(); + $traits = get_declared_traits(); + + assert(is_array($classes)); + assert(is_array($traits)); + + foreach (array_merge($classes, $traits) as $classOrTrait) { if (isset($this->processedClasses[$classOrTrait])) { continue; } - $reflector = new \ReflectionClass($classOrTrait); + $reflector = new ReflectionClass($classOrTrait); foreach ($reflector->getMethods() as $method) { $this->processFunctionOrMethod($method); @@ -72,23 +89,20 @@ class Wizard } } - private function processFunctions() + private function processFunctions(): void { foreach (get_defined_functions()['user'] as $function) { if (isset($this->processedFunctions[$function])) { continue; } - $this->processFunctionOrMethod(new \ReflectionFunction($function)); + $this->processFunctionOrMethod(new ReflectionFunction($function)); $this->processedFunctions[$function] = true; } } - /** - * @param \ReflectionFunctionAbstract $functionOrMethod - */ - private function processFunctionOrMethod(\ReflectionFunctionAbstract $functionOrMethod) + private function processFunctionOrMethod(ReflectionFunctionAbstract $functionOrMethod): void { if ($functionOrMethod->isInternal()) { return; @@ -96,7 +110,7 @@ class Wizard $name = $functionOrMethod->getName(); - if ($functionOrMethod instanceof \ReflectionMethod) { + if ($functionOrMethod instanceof ReflectionMethod) { $name = $functionOrMethod->getDeclaringClass()->getName() . '::' . $name; } diff --git a/vendor/sebastian/code-unit-reverse-lookup/tests/WizardTest.php b/vendor/sebastian/code-unit-reverse-lookup/tests/WizardTest.php deleted file mode 100644 index 711ad2864..000000000 --- a/vendor/sebastian/code-unit-reverse-lookup/tests/WizardTest.php +++ /dev/null @@ -1,45 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\CodeUnitReverseLookup; - -use PHPUnit\Framework\TestCase; - -/** - * @covers SebastianBergmann\CodeUnitReverseLookup\Wizard - */ -class WizardTest extends TestCase -{ - /** - * @var Wizard - */ - private $wizard; - - protected function setUp(): void - { - $this->wizard = new Wizard; - } - - public function testMethodCanBeLookedUp() - { - $this->assertEquals( - __METHOD__, - $this->wizard->lookup(__FILE__, __LINE__) - ); - } - - public function testReturnsFilenameAndLineNumberAsStringWhenNotInCodeUnit() - { - $this->assertEquals( - 'file.php:1', - $this->wizard->lookup('file.php', 1) - ); - } -} diff --git a/vendor/sebastian/code-unit/.psalm/baseline.xml b/vendor/sebastian/code-unit/.psalm/baseline.xml new file mode 100644 index 000000000..e44889190 --- /dev/null +++ b/vendor/sebastian/code-unit/.psalm/baseline.xml @@ -0,0 +1,23 @@ + + + + + $firstPart + $firstPart + $firstPart + $firstPart + $firstPart + $firstPart + $firstPart + $firstPart + $firstPart + $secondPart + $unit + $unit + $unit + $unit + $unit + $unit + + + diff --git a/vendor/sebastian/code-unit/.psalm/config.xml b/vendor/sebastian/code-unit/.psalm/config.xml new file mode 100644 index 000000000..a39e9a4c3 --- /dev/null +++ b/vendor/sebastian/code-unit/.psalm/config.xml @@ -0,0 +1,16 @@ + + + + + + + + + diff --git a/vendor/sebastian/code-unit/ChangeLog.md b/vendor/sebastian/code-unit/ChangeLog.md new file mode 100644 index 000000000..0978e651e --- /dev/null +++ b/vendor/sebastian/code-unit/ChangeLog.md @@ -0,0 +1,65 @@ +# ChangeLog + +All notable changes are documented in this file using the [Keep a CHANGELOG](http://keepachangelog.com/) principles. + +## [1.0.8] - 2020-10-26 + +### Fixed + +* `SebastianBergmann\CodeUnit\Exception` now correctly extends `\Throwable` + +## [1.0.7] - 2020-10-02 + +### Fixed + +* `SebastianBergmann\CodeUnit\Mapper::stringToCodeUnits()` no longer attempts to create `CodeUnit` objects for code units that are not declared in userland + +## [1.0.6] - 2020-09-28 + +### Changed + +* Changed PHP version constraint in `composer.json` from `^7.3 || ^8.0` to `>=7.3` + +## [1.0.5] - 2020-06-26 + +### Fixed + +* [#3](https://github.com/sebastianbergmann/code-unit/issues/3): Regression in 1.0.4 + +## [1.0.4] - 2020-06-26 + +### Added + +* This component is now supported on PHP 8 + +## [1.0.3] - 2020-06-15 + +### Changed + +* Tests etc. are now ignored for archive exports + +## [1.0.2] - 2020-04-30 + +### Fixed + +* `Mapper::stringToCodeUnits()` raised the wrong exception for `Class::method` when a class named `Class` exists but does not have a method named `method` + +## [1.0.1] - 2020-04-27 + +### Fixed + +* [#2](https://github.com/sebastianbergmann/code-unit/issues/2): `Mapper::stringToCodeUnits()` breaks when `ClassName` is used for class that extends built-in class + +## [1.0.0] - 2020-03-30 + +* Initial release + +[1.0.8]: https://github.com/sebastianbergmann/code-unit/compare/1.0.7...1.0.8 +[1.0.7]: https://github.com/sebastianbergmann/code-unit/compare/1.0.6...1.0.7 +[1.0.6]: https://github.com/sebastianbergmann/code-unit/compare/1.0.5...1.0.6 +[1.0.5]: https://github.com/sebastianbergmann/code-unit/compare/1.0.4...1.0.5 +[1.0.4]: https://github.com/sebastianbergmann/code-unit/compare/1.0.3...1.0.4 +[1.0.3]: https://github.com/sebastianbergmann/code-unit/compare/1.0.2...1.0.3 +[1.0.2]: https://github.com/sebastianbergmann/code-unit/compare/1.0.1...1.0.2 +[1.0.1]: https://github.com/sebastianbergmann/code-unit/compare/1.0.0...1.0.1 +[1.0.0]: https://github.com/sebastianbergmann/code-unit/compare/530c3900e5db9bcb8516da545bef0d62536cedaa...1.0.0 diff --git a/vendor/sebastian/code-unit/LICENSE b/vendor/sebastian/code-unit/LICENSE new file mode 100644 index 000000000..b99bc8ac4 --- /dev/null +++ b/vendor/sebastian/code-unit/LICENSE @@ -0,0 +1,33 @@ +sebastian/code-unit + +Copyright (c) 2020, Sebastian Bergmann . +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: + + * Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + * Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in + the documentation and/or other materials provided with the + distribution. + + * Neither the name of Sebastian Bergmann nor the names of his + contributors may be used to endorse or promote products derived + from this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS +FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN +ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +POSSIBILITY OF SUCH DAMAGE. diff --git a/vendor/sebastian/code-unit/README.md b/vendor/sebastian/code-unit/README.md new file mode 100644 index 000000000..d20227a9b --- /dev/null +++ b/vendor/sebastian/code-unit/README.md @@ -0,0 +1,17 @@ +# sebastian/code-unit + +Collection of value objects that represent the PHP code units. + +## Installation + +You can add this library as a local, per-project dependency to your project using [Composer](https://getcomposer.org/): + +``` +composer require sebastian/code-unit +``` + +If you only need this library during development, for instance to run your project's test suite, then you should add it as a development-time dependency: + +``` +composer require --dev sebastian/code-unit +``` diff --git a/vendor/sebastian/code-unit/composer.json b/vendor/sebastian/code-unit/composer.json new file mode 100644 index 000000000..5b86ec589 --- /dev/null +++ b/vendor/sebastian/code-unit/composer.json @@ -0,0 +1,50 @@ +{ + "name": "sebastian/code-unit", + "description": "Collection of value objects that represent the PHP code units", + "type": "library", + "homepage": "https://github.com/sebastianbergmann/code-unit", + "license": "BSD-3-Clause", + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "support": { + "issues": "https://github.com/sebastianbergmann/code-unit/issues" + }, + "prefer-stable": true, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "config": { + "platform": { + "php": "7.3.0" + }, + "optimize-autoloader": true, + "sort-packages": true + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "autoload-dev": { + "classmap": [ + "tests/_fixture" + ], + "files": [ + "tests/_fixture/file_with_multiple_code_units.php", + "tests/_fixture/function.php" + ] + }, + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + } +} diff --git a/vendor/sebastian/code-unit/src/ClassMethodUnit.php b/vendor/sebastian/code-unit/src/ClassMethodUnit.php new file mode 100644 index 000000000..f9ddac29e --- /dev/null +++ b/vendor/sebastian/code-unit/src/ClassMethodUnit.php @@ -0,0 +1,24 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeUnit; + +/** + * @psalm-immutable + */ +final class ClassMethodUnit extends CodeUnit +{ + /** + * @psalm-assert-if-true ClassMethodUnit $this + */ + public function isClassMethod(): bool + { + return true; + } +} diff --git a/vendor/sebastian/code-unit/src/ClassUnit.php b/vendor/sebastian/code-unit/src/ClassUnit.php new file mode 100644 index 000000000..3ba0ee661 --- /dev/null +++ b/vendor/sebastian/code-unit/src/ClassUnit.php @@ -0,0 +1,24 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeUnit; + +/** + * @psalm-immutable + */ +final class ClassUnit extends CodeUnit +{ + /** + * @psalm-assert-if-true ClassUnit $this + */ + public function isClass(): bool + { + return true; + } +} diff --git a/vendor/sebastian/code-unit/src/CodeUnit.php b/vendor/sebastian/code-unit/src/CodeUnit.php new file mode 100644 index 000000000..9e5cceb35 --- /dev/null +++ b/vendor/sebastian/code-unit/src/CodeUnit.php @@ -0,0 +1,445 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeUnit; + +use function range; +use function sprintf; +use ReflectionClass; +use ReflectionFunction; +use ReflectionMethod; + +/** + * @psalm-immutable + */ +abstract class CodeUnit +{ + /** + * @var string + */ + private $name; + + /** + * @var string + */ + private $sourceFileName; + + /** + * @var array + * @psalm-var list + */ + private $sourceLines; + + /** + * @psalm-param class-string $className + * + * @throws InvalidCodeUnitException + * @throws ReflectionException + */ + public static function forClass(string $className): ClassUnit + { + self::ensureUserDefinedClass($className); + + $reflector = self::reflectorForClass($className); + + return new ClassUnit( + $className, + $reflector->getFileName(), + range( + $reflector->getStartLine(), + $reflector->getEndLine() + ) + ); + } + + /** + * @psalm-param class-string $className + * + * @throws InvalidCodeUnitException + * @throws ReflectionException + */ + public static function forClassMethod(string $className, string $methodName): ClassMethodUnit + { + self::ensureUserDefinedClass($className); + + $reflector = self::reflectorForClassMethod($className, $methodName); + + return new ClassMethodUnit( + $className . '::' . $methodName, + $reflector->getFileName(), + range( + $reflector->getStartLine(), + $reflector->getEndLine() + ) + ); + } + + /** + * @psalm-param class-string $interfaceName + * + * @throws InvalidCodeUnitException + * @throws ReflectionException + */ + public static function forInterface(string $interfaceName): InterfaceUnit + { + self::ensureUserDefinedInterface($interfaceName); + + $reflector = self::reflectorForClass($interfaceName); + + return new InterfaceUnit( + $interfaceName, + $reflector->getFileName(), + range( + $reflector->getStartLine(), + $reflector->getEndLine() + ) + ); + } + + /** + * @psalm-param class-string $interfaceName + * + * @throws InvalidCodeUnitException + * @throws ReflectionException + */ + public static function forInterfaceMethod(string $interfaceName, string $methodName): InterfaceMethodUnit + { + self::ensureUserDefinedInterface($interfaceName); + + $reflector = self::reflectorForClassMethod($interfaceName, $methodName); + + return new InterfaceMethodUnit( + $interfaceName . '::' . $methodName, + $reflector->getFileName(), + range( + $reflector->getStartLine(), + $reflector->getEndLine() + ) + ); + } + + /** + * @psalm-param class-string $traitName + * + * @throws InvalidCodeUnitException + * @throws ReflectionException + */ + public static function forTrait(string $traitName): TraitUnit + { + self::ensureUserDefinedTrait($traitName); + + $reflector = self::reflectorForClass($traitName); + + return new TraitUnit( + $traitName, + $reflector->getFileName(), + range( + $reflector->getStartLine(), + $reflector->getEndLine() + ) + ); + } + + /** + * @psalm-param class-string $traitName + * + * @throws InvalidCodeUnitException + * @throws ReflectionException + */ + public static function forTraitMethod(string $traitName, string $methodName): TraitMethodUnit + { + self::ensureUserDefinedTrait($traitName); + + $reflector = self::reflectorForClassMethod($traitName, $methodName); + + return new TraitMethodUnit( + $traitName . '::' . $methodName, + $reflector->getFileName(), + range( + $reflector->getStartLine(), + $reflector->getEndLine() + ) + ); + } + + /** + * @psalm-param callable-string $functionName + * + * @throws InvalidCodeUnitException + * @throws ReflectionException + */ + public static function forFunction(string $functionName): FunctionUnit + { + $reflector = self::reflectorForFunction($functionName); + + if (!$reflector->isUserDefined()) { + throw new InvalidCodeUnitException( + sprintf( + '"%s" is not a user-defined function', + $functionName + ) + ); + } + + return new FunctionUnit( + $functionName, + $reflector->getFileName(), + range( + $reflector->getStartLine(), + $reflector->getEndLine() + ) + ); + } + + /** + * @psalm-param list $sourceLines + */ + private function __construct(string $name, string $sourceFileName, array $sourceLines) + { + $this->name = $name; + $this->sourceFileName = $sourceFileName; + $this->sourceLines = $sourceLines; + } + + public function name(): string + { + return $this->name; + } + + public function sourceFileName(): string + { + return $this->sourceFileName; + } + + /** + * @psalm-return list + */ + public function sourceLines(): array + { + return $this->sourceLines; + } + + public function isClass(): bool + { + return false; + } + + public function isClassMethod(): bool + { + return false; + } + + public function isInterface(): bool + { + return false; + } + + public function isInterfaceMethod(): bool + { + return false; + } + + public function isTrait(): bool + { + return false; + } + + public function isTraitMethod(): bool + { + return false; + } + + public function isFunction(): bool + { + return false; + } + + /** + * @psalm-param class-string $className + * + * @throws InvalidCodeUnitException + */ + private static function ensureUserDefinedClass(string $className): void + { + try { + $reflector = new ReflectionClass($className); + + if ($reflector->isInterface()) { + throw new InvalidCodeUnitException( + sprintf( + '"%s" is an interface and not a class', + $className + ) + ); + } + + if ($reflector->isTrait()) { + throw new InvalidCodeUnitException( + sprintf( + '"%s" is a trait and not a class', + $className + ) + ); + } + + if (!$reflector->isUserDefined()) { + throw new InvalidCodeUnitException( + sprintf( + '"%s" is not a user-defined class', + $className + ) + ); + } + // @codeCoverageIgnoreStart + } catch (\ReflectionException $e) { + throw new ReflectionException( + $e->getMessage(), + (int) $e->getCode(), + $e + ); + } + // @codeCoverageIgnoreEnd + } + + /** + * @psalm-param class-string $interfaceName + * + * @throws InvalidCodeUnitException + */ + private static function ensureUserDefinedInterface(string $interfaceName): void + { + try { + $reflector = new ReflectionClass($interfaceName); + + if (!$reflector->isInterface()) { + throw new InvalidCodeUnitException( + sprintf( + '"%s" is not an interface', + $interfaceName + ) + ); + } + + if (!$reflector->isUserDefined()) { + throw new InvalidCodeUnitException( + sprintf( + '"%s" is not a user-defined interface', + $interfaceName + ) + ); + } + // @codeCoverageIgnoreStart + } catch (\ReflectionException $e) { + throw new ReflectionException( + $e->getMessage(), + (int) $e->getCode(), + $e + ); + } + // @codeCoverageIgnoreEnd + } + + /** + * @psalm-param class-string $traitName + * + * @throws InvalidCodeUnitException + */ + private static function ensureUserDefinedTrait(string $traitName): void + { + try { + $reflector = new ReflectionClass($traitName); + + if (!$reflector->isTrait()) { + throw new InvalidCodeUnitException( + sprintf( + '"%s" is not a trait', + $traitName + ) + ); + } + + // @codeCoverageIgnoreStart + if (!$reflector->isUserDefined()) { + throw new InvalidCodeUnitException( + sprintf( + '"%s" is not a user-defined trait', + $traitName + ) + ); + } + } catch (\ReflectionException $e) { + throw new ReflectionException( + $e->getMessage(), + (int) $e->getCode(), + $e + ); + } + // @codeCoverageIgnoreEnd + } + + /** + * @psalm-param class-string $className + * + * @throws ReflectionException + */ + private static function reflectorForClass(string $className): ReflectionClass + { + try { + return new ReflectionClass($className); + // @codeCoverageIgnoreStart + } catch (\ReflectionException $e) { + throw new ReflectionException( + $e->getMessage(), + (int) $e->getCode(), + $e + ); + } + // @codeCoverageIgnoreEnd + } + + /** + * @psalm-param class-string $className + * + * @throws ReflectionException + */ + private static function reflectorForClassMethod(string $className, string $methodName): ReflectionMethod + { + try { + return new ReflectionMethod($className, $methodName); + // @codeCoverageIgnoreStart + } catch (\ReflectionException $e) { + throw new ReflectionException( + $e->getMessage(), + (int) $e->getCode(), + $e + ); + } + // @codeCoverageIgnoreEnd + } + + /** + * @psalm-param callable-string $functionName + * + * @throws ReflectionException + */ + private static function reflectorForFunction(string $functionName): ReflectionFunction + { + try { + return new ReflectionFunction($functionName); + // @codeCoverageIgnoreStart + } catch (\ReflectionException $e) { + throw new ReflectionException( + $e->getMessage(), + (int) $e->getCode(), + $e + ); + } + // @codeCoverageIgnoreEnd + } +} diff --git a/vendor/sebastian/code-unit/src/CodeUnitCollection.php b/vendor/sebastian/code-unit/src/CodeUnitCollection.php new file mode 100644 index 000000000..f53db8a12 --- /dev/null +++ b/vendor/sebastian/code-unit/src/CodeUnitCollection.php @@ -0,0 +1,84 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeUnit; + +use function array_merge; +use function count; +use Countable; +use IteratorAggregate; + +final class CodeUnitCollection implements Countable, IteratorAggregate +{ + /** + * @psalm-var list + */ + private $codeUnits = []; + + /** + * @psalm-param list $items + */ + public static function fromArray(array $items): self + { + $collection = new self; + + foreach ($items as $item) { + $collection->add($item); + } + + return $collection; + } + + public static function fromList(CodeUnit ...$items): self + { + return self::fromArray($items); + } + + private function __construct() + { + } + + /** + * @psalm-return list + */ + public function asArray(): array + { + return $this->codeUnits; + } + + public function getIterator(): CodeUnitCollectionIterator + { + return new CodeUnitCollectionIterator($this); + } + + public function count(): int + { + return count($this->codeUnits); + } + + public function isEmpty(): bool + { + return empty($this->codeUnits); + } + + public function mergeWith(self $other): self + { + return self::fromArray( + array_merge( + $this->asArray(), + $other->asArray() + ) + ); + } + + private function add(CodeUnit $item): void + { + $this->codeUnits[] = $item; + } +} diff --git a/vendor/sebastian/code-unit/src/CodeUnitCollectionIterator.php b/vendor/sebastian/code-unit/src/CodeUnitCollectionIterator.php new file mode 100644 index 000000000..bdc86d888 --- /dev/null +++ b/vendor/sebastian/code-unit/src/CodeUnitCollectionIterator.php @@ -0,0 +1,55 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeUnit; + +use Iterator; + +final class CodeUnitCollectionIterator implements Iterator +{ + /** + * @psalm-var list + */ + private $codeUnits; + + /** + * @var int + */ + private $position = 0; + + public function __construct(CodeUnitCollection $collection) + { + $this->codeUnits = $collection->asArray(); + } + + public function rewind(): void + { + $this->position = 0; + } + + public function valid(): bool + { + return isset($this->codeUnits[$this->position]); + } + + public function key(): int + { + return $this->position; + } + + public function current(): CodeUnit + { + return $this->codeUnits[$this->position]; + } + + public function next(): void + { + $this->position++; + } +} diff --git a/vendor/sebastian/code-unit/src/FunctionUnit.php b/vendor/sebastian/code-unit/src/FunctionUnit.php new file mode 100644 index 000000000..df76cf195 --- /dev/null +++ b/vendor/sebastian/code-unit/src/FunctionUnit.php @@ -0,0 +1,24 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeUnit; + +/** + * @psalm-immutable + */ +final class FunctionUnit extends CodeUnit +{ + /** + * @psalm-assert-if-true FunctionUnit $this + */ + public function isFunction(): bool + { + return true; + } +} diff --git a/vendor/sebastian/code-unit/src/InterfaceMethodUnit.php b/vendor/sebastian/code-unit/src/InterfaceMethodUnit.php new file mode 100644 index 000000000..fcd44f41a --- /dev/null +++ b/vendor/sebastian/code-unit/src/InterfaceMethodUnit.php @@ -0,0 +1,24 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeUnit; + +/** + * @psalm-immutable + */ +final class InterfaceMethodUnit extends CodeUnit +{ + /** + * @psalm-assert-if-true InterfaceMethod $this + */ + public function isInterfaceMethod(): bool + { + return true; + } +} diff --git a/vendor/sebastian/code-unit/src/InterfaceUnit.php b/vendor/sebastian/code-unit/src/InterfaceUnit.php new file mode 100644 index 000000000..5cf585bfd --- /dev/null +++ b/vendor/sebastian/code-unit/src/InterfaceUnit.php @@ -0,0 +1,24 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeUnit; + +/** + * @psalm-immutable + */ +final class InterfaceUnit extends CodeUnit +{ + /** + * @psalm-assert-if-true InterfaceUnit $this + */ + public function isInterface(): bool + { + return true; + } +} diff --git a/vendor/sebastian/code-unit/src/Mapper.php b/vendor/sebastian/code-unit/src/Mapper.php new file mode 100644 index 000000000..a72b3b0dd --- /dev/null +++ b/vendor/sebastian/code-unit/src/Mapper.php @@ -0,0 +1,414 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeUnit; + +use function array_keys; +use function array_merge; +use function array_unique; +use function array_values; +use function class_exists; +use function explode; +use function function_exists; +use function interface_exists; +use function ksort; +use function method_exists; +use function sort; +use function sprintf; +use function str_replace; +use function strpos; +use function trait_exists; +use ReflectionClass; +use ReflectionFunction; +use ReflectionMethod; + +final class Mapper +{ + /** + * @psalm-return array> + */ + public function codeUnitsToSourceLines(CodeUnitCollection $codeUnits): array + { + $result = []; + + foreach ($codeUnits as $codeUnit) { + $sourceFileName = $codeUnit->sourceFileName(); + + if (!isset($result[$sourceFileName])) { + $result[$sourceFileName] = []; + } + + $result[$sourceFileName] = array_merge($result[$sourceFileName], $codeUnit->sourceLines()); + } + + foreach (array_keys($result) as $sourceFileName) { + $result[$sourceFileName] = array_values(array_unique($result[$sourceFileName])); + + sort($result[$sourceFileName]); + } + + ksort($result); + + return $result; + } + + /** + * @throws InvalidCodeUnitException + * @throws ReflectionException + */ + public function stringToCodeUnits(string $unit): CodeUnitCollection + { + if (strpos($unit, '::') !== false) { + [$firstPart, $secondPart] = explode('::', $unit); + + if (empty($firstPart) && $this->isUserDefinedFunction($secondPart)) { + return CodeUnitCollection::fromList(CodeUnit::forFunction($secondPart)); + } + + if ($this->isUserDefinedClass($firstPart)) { + if ($secondPart === '') { + return $this->publicMethodsOfClass($firstPart); + } + + if ($secondPart === '') { + return $this->protectedAndPrivateMethodsOfClass($firstPart); + } + + if ($secondPart === '') { + return $this->protectedMethodsOfClass($firstPart); + } + + if ($secondPart === '') { + return $this->publicAndPrivateMethodsOfClass($firstPart); + } + + if ($secondPart === '') { + return $this->privateMethodsOfClass($firstPart); + } + + if ($secondPart === '') { + return $this->publicAndProtectedMethodsOfClass($firstPart); + } + + if ($this->isUserDefinedMethod($firstPart, $secondPart)) { + return CodeUnitCollection::fromList(CodeUnit::forClassMethod($firstPart, $secondPart)); + } + } + + if ($this->isUserDefinedInterface($firstPart)) { + return CodeUnitCollection::fromList(CodeUnit::forInterfaceMethod($firstPart, $secondPart)); + } + + if ($this->isUserDefinedTrait($firstPart)) { + return CodeUnitCollection::fromList(CodeUnit::forTraitMethod($firstPart, $secondPart)); + } + } else { + if ($this->isUserDefinedClass($unit)) { + $units = [CodeUnit::forClass($unit)]; + + foreach ($this->reflectorForClass($unit)->getTraits() as $trait) { + if (!$trait->isUserDefined()) { + // @codeCoverageIgnoreStart + continue; + // @codeCoverageIgnoreEnd + } + + $units[] = CodeUnit::forTrait($trait->getName()); + } + + return CodeUnitCollection::fromArray($units); + } + + if ($this->isUserDefinedInterface($unit)) { + return CodeUnitCollection::fromList(CodeUnit::forInterface($unit)); + } + + if ($this->isUserDefinedTrait($unit)) { + return CodeUnitCollection::fromList(CodeUnit::forTrait($unit)); + } + + if ($this->isUserDefinedFunction($unit)) { + return CodeUnitCollection::fromList(CodeUnit::forFunction($unit)); + } + + $unit = str_replace('', '', $unit); + + if ($this->isUserDefinedClass($unit)) { + return $this->classAndParentClassesAndTraits($unit); + } + } + + throw new InvalidCodeUnitException( + sprintf( + '"%s" is not a valid code unit', + $unit + ) + ); + } + + /** + * @psalm-param class-string $className + * + * @throws ReflectionException + */ + private function publicMethodsOfClass(string $className): CodeUnitCollection + { + return $this->methodsOfClass($className, ReflectionMethod::IS_PUBLIC); + } + + /** + * @psalm-param class-string $className + * + * @throws ReflectionException + */ + private function publicAndProtectedMethodsOfClass(string $className): CodeUnitCollection + { + return $this->methodsOfClass($className, ReflectionMethod::IS_PUBLIC | ReflectionMethod::IS_PROTECTED); + } + + /** + * @psalm-param class-string $className + * + * @throws ReflectionException + */ + private function publicAndPrivateMethodsOfClass(string $className): CodeUnitCollection + { + return $this->methodsOfClass($className, ReflectionMethod::IS_PUBLIC | ReflectionMethod::IS_PRIVATE); + } + + /** + * @psalm-param class-string $className + * + * @throws ReflectionException + */ + private function protectedMethodsOfClass(string $className): CodeUnitCollection + { + return $this->methodsOfClass($className, ReflectionMethod::IS_PROTECTED); + } + + /** + * @psalm-param class-string $className + * + * @throws ReflectionException + */ + private function protectedAndPrivateMethodsOfClass(string $className): CodeUnitCollection + { + return $this->methodsOfClass($className, ReflectionMethod::IS_PROTECTED | ReflectionMethod::IS_PRIVATE); + } + + /** + * @psalm-param class-string $className + * + * @throws ReflectionException + */ + private function privateMethodsOfClass(string $className): CodeUnitCollection + { + return $this->methodsOfClass($className, ReflectionMethod::IS_PRIVATE); + } + + /** + * @psalm-param class-string $className + * + * @throws ReflectionException + */ + private function methodsOfClass(string $className, int $filter): CodeUnitCollection + { + $units = []; + + foreach ($this->reflectorForClass($className)->getMethods($filter) as $method) { + if (!$method->isUserDefined()) { + continue; + } + + $units[] = CodeUnit::forClassMethod($className, $method->getName()); + } + + return CodeUnitCollection::fromArray($units); + } + + /** + * @psalm-param class-string $className + * + * @throws ReflectionException + */ + private function classAndParentClassesAndTraits(string $className): CodeUnitCollection + { + $units = [CodeUnit::forClass($className)]; + + $reflector = $this->reflectorForClass($className); + + foreach ($this->reflectorForClass($className)->getTraits() as $trait) { + if (!$trait->isUserDefined()) { + // @codeCoverageIgnoreStart + continue; + // @codeCoverageIgnoreEnd + } + + $units[] = CodeUnit::forTrait($trait->getName()); + } + + while ($reflector = $reflector->getParentClass()) { + if (!$reflector->isUserDefined()) { + break; + } + + $units[] = CodeUnit::forClass($reflector->getName()); + + foreach ($reflector->getTraits() as $trait) { + if (!$trait->isUserDefined()) { + // @codeCoverageIgnoreStart + continue; + // @codeCoverageIgnoreEnd + } + + $units[] = CodeUnit::forTrait($trait->getName()); + } + } + + return CodeUnitCollection::fromArray($units); + } + + /** + * @psalm-param class-string $className + * + * @throws ReflectionException + */ + private function reflectorForClass(string $className): ReflectionClass + { + try { + return new ReflectionClass($className); + // @codeCoverageIgnoreStart + } catch (\ReflectionException $e) { + throw new ReflectionException( + $e->getMessage(), + (int) $e->getCode(), + $e + ); + } + // @codeCoverageIgnoreEnd + } + + /** + * @throws ReflectionException + */ + private function isUserDefinedFunction(string $functionName): bool + { + if (!function_exists($functionName)) { + return false; + } + + try { + return (new ReflectionFunction($functionName))->isUserDefined(); + // @codeCoverageIgnoreStart + } catch (\ReflectionException $e) { + throw new ReflectionException( + $e->getMessage(), + (int) $e->getCode(), + $e + ); + } + // @codeCoverageIgnoreEnd + } + + /** + * @throws ReflectionException + */ + private function isUserDefinedClass(string $className): bool + { + if (!class_exists($className)) { + return false; + } + + try { + return (new ReflectionClass($className))->isUserDefined(); + // @codeCoverageIgnoreStart + } catch (\ReflectionException $e) { + throw new ReflectionException( + $e->getMessage(), + (int) $e->getCode(), + $e + ); + } + // @codeCoverageIgnoreEnd + } + + /** + * @throws ReflectionException + */ + private function isUserDefinedInterface(string $interfaceName): bool + { + if (!interface_exists($interfaceName)) { + return false; + } + + try { + return (new ReflectionClass($interfaceName))->isUserDefined(); + // @codeCoverageIgnoreStart + } catch (\ReflectionException $e) { + throw new ReflectionException( + $e->getMessage(), + (int) $e->getCode(), + $e + ); + } + // @codeCoverageIgnoreEnd + } + + /** + * @throws ReflectionException + */ + private function isUserDefinedTrait(string $traitName): bool + { + if (!trait_exists($traitName)) { + return false; + } + + try { + return (new ReflectionClass($traitName))->isUserDefined(); + // @codeCoverageIgnoreStart + } catch (\ReflectionException $e) { + throw new ReflectionException( + $e->getMessage(), + (int) $e->getCode(), + $e + ); + } + // @codeCoverageIgnoreEnd + } + + /** + * @throws ReflectionException + */ + private function isUserDefinedMethod(string $className, string $methodName): bool + { + if (!class_exists($className)) { + // @codeCoverageIgnoreStart + return false; + // @codeCoverageIgnoreEnd + } + + if (!method_exists($className, $methodName)) { + // @codeCoverageIgnoreStart + return false; + // @codeCoverageIgnoreEnd + } + + try { + return (new ReflectionMethod($className, $methodName))->isUserDefined(); + // @codeCoverageIgnoreStart + } catch (\ReflectionException $e) { + throw new ReflectionException( + $e->getMessage(), + (int) $e->getCode(), + $e + ); + } + // @codeCoverageIgnoreEnd + } +} diff --git a/vendor/sebastian/code-unit/src/TraitMethodUnit.php b/vendor/sebastian/code-unit/src/TraitMethodUnit.php new file mode 100644 index 000000000..a58f7249f --- /dev/null +++ b/vendor/sebastian/code-unit/src/TraitMethodUnit.php @@ -0,0 +1,24 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeUnit; + +/** + * @psalm-immutable + */ +final class TraitMethodUnit extends CodeUnit +{ + /** + * @psalm-assert-if-true TraitMethodUnit $this + */ + public function isTraitMethod(): bool + { + return true; + } +} diff --git a/vendor/sebastian/code-unit/src/TraitUnit.php b/vendor/sebastian/code-unit/src/TraitUnit.php new file mode 100644 index 000000000..abddfc112 --- /dev/null +++ b/vendor/sebastian/code-unit/src/TraitUnit.php @@ -0,0 +1,24 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeUnit; + +/** + * @psalm-immutable + */ +final class TraitUnit extends CodeUnit +{ + /** + * @psalm-assert-if-true TraitUnit $this + */ + public function isTrait(): bool + { + return true; + } +} diff --git a/vendor/sebastian/global-state/tests/_fixture/SnapshotFunctions.php b/vendor/sebastian/code-unit/src/exceptions/Exception.php similarity index 62% rename from vendor/sebastian/global-state/tests/_fixture/SnapshotFunctions.php rename to vendor/sebastian/code-unit/src/exceptions/Exception.php index b3e8d007a..74d0eeef8 100644 --- a/vendor/sebastian/global-state/tests/_fixture/SnapshotFunctions.php +++ b/vendor/sebastian/code-unit/src/exceptions/Exception.php @@ -1,14 +1,16 @@ * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ -namespace SebastianBergmann\GlobalState\TestFixture; +namespace SebastianBergmann\CodeUnit; -function snapshotFunction(): void +use Throwable; + +interface Exception extends Throwable { } diff --git a/vendor/sebastian/code-unit/src/exceptions/InvalidCodeUnitException.php b/vendor/sebastian/code-unit/src/exceptions/InvalidCodeUnitException.php new file mode 100644 index 000000000..60a3da82b --- /dev/null +++ b/vendor/sebastian/code-unit/src/exceptions/InvalidCodeUnitException.php @@ -0,0 +1,16 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeUnit; + +use RuntimeException; + +final class InvalidCodeUnitException extends RuntimeException implements Exception +{ +} diff --git a/vendor/sebastian/code-unit/src/exceptions/NoTraitException.php b/vendor/sebastian/code-unit/src/exceptions/NoTraitException.php new file mode 100644 index 000000000..e9b9b9c7a --- /dev/null +++ b/vendor/sebastian/code-unit/src/exceptions/NoTraitException.php @@ -0,0 +1,16 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeUnit; + +use RuntimeException; + +final class NoTraitException extends RuntimeException implements Exception +{ +} diff --git a/vendor/sebastian/code-unit/src/exceptions/ReflectionException.php b/vendor/sebastian/code-unit/src/exceptions/ReflectionException.php new file mode 100644 index 000000000..232012783 --- /dev/null +++ b/vendor/sebastian/code-unit/src/exceptions/ReflectionException.php @@ -0,0 +1,16 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\CodeUnit; + +use RuntimeException; + +final class ReflectionException extends RuntimeException implements Exception +{ +} diff --git a/vendor/sebastian/comparator/.github/stale.yml b/vendor/sebastian/comparator/.github/stale.yml deleted file mode 100644 index 4eadca327..000000000 --- a/vendor/sebastian/comparator/.github/stale.yml +++ /dev/null @@ -1,40 +0,0 @@ -# Configuration for probot-stale - https://github.com/probot/stale - -# Number of days of inactivity before an Issue or Pull Request becomes stale -daysUntilStale: 60 - -# Number of days of inactivity before a stale Issue or Pull Request is closed. -# Set to false to disable. If disabled, issues still need to be closed manually, but will remain marked as stale. -daysUntilClose: 7 - -# Issues or Pull Requests with these labels will never be considered stale. Set to `[]` to disable -exemptLabels: - - enhancement - -# Set to true to ignore issues in a project (defaults to false) -exemptProjects: false - -# Set to true to ignore issues in a milestone (defaults to false) -exemptMilestones: false - -# Label to use when marking as stale -staleLabel: stale - -# Comment to post when marking as stale. Set to `false` to disable -markComment: > - This issue has been automatically marked as stale because it has not had activity within the last 60 days. It will be closed after 7 days if no further activity occurs. Thank you for your contributions. - -# Comment to post when removing the stale label. -# unmarkComment: > -# Your comment here. - -# Comment to post when closing a stale Issue or Pull Request. -closeComment: > - This issue has been automatically closed because it has not had activity since it was marked as stale. Thank you for your contributions. - -# Limit the number of actions per hour, from 1-30. Default is 30 -limitPerRun: 30 - -# Limit to only `issues` or `pulls` -only: issues - diff --git a/vendor/sebastian/comparator/.gitignore b/vendor/sebastian/comparator/.gitignore deleted file mode 100644 index c3e9d7e3c..000000000 --- a/vendor/sebastian/comparator/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -/.idea -/.php_cs.cache -/composer.lock -/vendor diff --git a/vendor/sebastian/comparator/.php_cs.dist b/vendor/sebastian/comparator/.php_cs.dist deleted file mode 100644 index acf47b357..000000000 --- a/vendor/sebastian/comparator/.php_cs.dist +++ /dev/null @@ -1,189 +0,0 @@ - - -For the full copyright and license information, please view the LICENSE -file that was distributed with this source code. -EOF; - -return PhpCsFixer\Config::create() - ->setRiskyAllowed(true) - ->setRules( - [ - 'align_multiline_comment' => true, - 'array_indentation' => true, - 'array_syntax' => ['syntax' => 'short'], - 'binary_operator_spaces' => [ - 'operators' => [ - '=' => 'align', - '=>' => 'align', - ], - ], - 'blank_line_after_namespace' => true, - 'blank_line_before_statement' => [ - 'statements' => [ - 'break', - 'continue', - 'declare', - 'do', - 'for', - 'foreach', - 'if', - 'include', - 'include_once', - 'require', - 'require_once', - 'return', - 'switch', - 'throw', - 'try', - 'while', - 'yield', - ], - ], - 'braces' => true, - 'cast_spaces' => true, - 'class_attributes_separation' => ['elements' => ['const', 'method', 'property']], - 'combine_consecutive_issets' => true, - 'combine_consecutive_unsets' => true, - 'compact_nullable_typehint' => true, - 'concat_space' => ['spacing' => 'one'], - 'declare_equal_normalize' => ['space' => 'none'], - 'dir_constant' => true, - 'elseif' => true, - 'encoding' => true, - 'full_opening_tag' => true, - 'function_declaration' => true, - 'header_comment' => ['header' => $header, 'separate' => 'none'], - 'indentation_type' => true, - 'is_null' => true, - 'line_ending' => true, - 'list_syntax' => ['syntax' => 'short'], - 'logical_operators' => true, - 'lowercase_cast' => true, - 'lowercase_constants' => true, - 'lowercase_keywords' => true, - 'lowercase_static_reference' => true, - 'magic_constant_casing' => true, - 'method_argument_space' => ['ensure_fully_multiline' => true], - 'modernize_types_casting' => true, - 'multiline_comment_opening_closing' => true, - 'multiline_whitespace_before_semicolons' => true, - 'native_constant_invocation' => true, - 'native_function_casing' => true, - 'native_function_invocation' => true, - 'new_with_braces' => false, - 'no_alias_functions' => true, - 'no_alternative_syntax' => true, - 'no_blank_lines_after_class_opening' => true, - 'no_blank_lines_after_phpdoc' => true, - 'no_blank_lines_before_namespace' => true, - 'no_closing_tag' => true, - 'no_empty_comment' => true, - 'no_empty_phpdoc' => true, - 'no_empty_statement' => true, - 'no_extra_blank_lines' => true, - 'no_homoglyph_names' => true, - 'no_leading_import_slash' => true, - 'no_leading_namespace_whitespace' => true, - 'no_mixed_echo_print' => ['use' => 'print'], - 'no_multiline_whitespace_around_double_arrow' => true, - 'no_null_property_initialization' => true, - 'no_php4_constructor' => true, - 'no_short_bool_cast' => true, - 'no_short_echo_tag' => true, - 'no_singleline_whitespace_before_semicolons' => true, - 'no_spaces_after_function_name' => true, - 'no_spaces_inside_parenthesis' => true, - 'no_superfluous_elseif' => true, - 'no_superfluous_phpdoc_tags' => true, - 'no_trailing_comma_in_list_call' => true, - 'no_trailing_comma_in_singleline_array' => true, - 'no_trailing_whitespace' => true, - 'no_trailing_whitespace_in_comment' => true, - 'no_unneeded_control_parentheses' => true, - 'no_unneeded_curly_braces' => true, - 'no_unneeded_final_method' => true, - 'no_unreachable_default_argument_value' => true, - 'no_unset_on_property' => true, - 'no_unused_imports' => true, - 'no_useless_else' => true, - 'no_useless_return' => true, - 'no_whitespace_before_comma_in_array' => true, - 'no_whitespace_in_blank_line' => true, - 'non_printable_character' => true, - 'normalize_index_brace' => true, - 'object_operator_without_whitespace' => true, - 'ordered_class_elements' => [ - 'order' => [ - 'use_trait', - 'constant_public', - 'constant_protected', - 'constant_private', - 'property_public_static', - 'property_protected_static', - 'property_private_static', - 'property_public', - 'property_protected', - 'property_private', - 'method_public_static', - 'construct', - 'destruct', - 'magic', - 'phpunit', - 'method_public', - 'method_protected', - 'method_private', - 'method_protected_static', - 'method_private_static', - ], - ], - 'ordered_imports' => true, - 'phpdoc_add_missing_param_annotation' => true, - 'phpdoc_align' => true, - 'phpdoc_annotation_without_dot' => true, - 'phpdoc_indent' => true, - 'phpdoc_no_access' => true, - 'phpdoc_no_empty_return' => true, - 'phpdoc_no_package' => true, - 'phpdoc_order' => true, - 'phpdoc_return_self_reference' => true, - 'phpdoc_scalar' => true, - 'phpdoc_separation' => true, - 'phpdoc_single_line_var_spacing' => true, - 'phpdoc_to_comment' => true, - 'phpdoc_trim' => true, - 'phpdoc_trim_consecutive_blank_line_separation' => true, - 'phpdoc_types' => true, - 'phpdoc_types_order' => true, - 'phpdoc_var_without_name' => true, - 'pow_to_exponentiation' => true, - 'protected_to_private' => true, - 'return_assignment' => true, - 'return_type_declaration' => ['space_before' => 'none'], - 'self_accessor' => true, - 'semicolon_after_instruction' => true, - 'set_type_to_cast' => true, - 'short_scalar_cast' => true, - 'simplified_null_return' => true, - 'single_blank_line_at_eof' => true, - 'single_import_per_statement' => true, - 'single_line_after_imports' => true, - 'single_quote' => true, - 'standardize_not_equals' => true, - 'ternary_to_null_coalescing' => true, - 'trim_array_spaces' => true, - 'unary_operator_spaces' => true, - 'visibility_required' => true, - //'void_return' => true, - 'whitespace_after_comma_in_array' => true, - ] - ) - ->setFinder( - PhpCsFixer\Finder::create() - ->files() - ->in(__DIR__ . '/src') - ->in(__DIR__ . '/tests') - ); diff --git a/vendor/sebastian/comparator/.travis.yml b/vendor/sebastian/comparator/.travis.yml deleted file mode 100644 index 7583d0ffc..000000000 --- a/vendor/sebastian/comparator/.travis.yml +++ /dev/null @@ -1,33 +0,0 @@ -language: php - -sudo: false - -php: - - 7.1 - - 7.2 - - master - -env: - matrix: - - DEPENDENCIES="high" - - DEPENDENCIES="low" - global: - - DEFAULT_COMPOSER_FLAGS="--no-interaction --no-ansi --no-progress --no-suggest" - -before_install: - - composer self-update - - composer clear-cache - -install: - - if [[ "$DEPENDENCIES" = 'high' ]]; then travis_retry composer update $DEFAULT_COMPOSER_FLAGS; fi - - if [[ "$DEPENDENCIES" = 'low' ]]; then travis_retry composer update $DEFAULT_COMPOSER_FLAGS --prefer-lowest; fi - -script: - - ./vendor/bin/phpunit --coverage-clover=coverage.xml - -after_success: - - bash <(curl -s https://codecov.io/bash) - -notifications: - email: false - diff --git a/vendor/sebastian/comparator/ChangeLog.md b/vendor/sebastian/comparator/ChangeLog.md index f4d97872c..64c0251c1 100644 --- a/vendor/sebastian/comparator/ChangeLog.md +++ b/vendor/sebastian/comparator/ChangeLog.md @@ -2,11 +2,47 @@ All notable changes are documented in this file using the [Keep a CHANGELOG](http://keepachangelog.com/) principles. -## [3.0.3] - 2020-11-30 +## [4.0.6] - 2020-10-26 + +### Fixed + +* `SebastianBergmann\Comparator\Exception` now correctly extends `\Throwable` + +## [4.0.5] - 2020-09-30 + +### Fixed + +* [#89](https://github.com/sebastianbergmann/comparator/pull/89): Handle PHP 8 `ValueError` + +## [4.0.4] - 2020-09-28 ### Changed -* Changed PHP version constraint in `composer.json` from `^7.1` to `>=7.1` +* Changed PHP version constraint in `composer.json` from `^7.3 || ^8.0` to `>=7.3` + +## [4.0.3] - 2020-06-26 + +### Added + +* This component is now supported on PHP 8 + +## [4.0.2] - 2020-06-15 + +### Fixed + +* [#85](https://github.com/sebastianbergmann/comparator/issues/85): Version 4.0.1 breaks backward compatibility + +## [4.0.1] - 2020-06-15 + +### Changed + +* Tests etc. are now ignored for archive exports + +## [4.0.0] - 2020-02-07 + +### Removed + +* Removed support for PHP 7.1 and PHP 7.2 ## [3.0.2] - 2018-07-12 @@ -18,8 +54,8 @@ All notable changes are documented in this file using the [Keep a CHANGELOG](htt ### Fixed -* Fixed [#53](https://github.com/sebastianbergmann/comparator/pull/53): `DOMNodeComparator` ignores `$ignoreCase` parameter -* Fixed [#58](https://github.com/sebastianbergmann/comparator/pull/58): `ScalarComparator` does not handle extremely ugly string comparison edge cases +* [#53](https://github.com/sebastianbergmann/comparator/pull/53): `DOMNodeComparator` ignores `$ignoreCase` parameter +* [#58](https://github.com/sebastianbergmann/comparator/pull/58): `ScalarComparator` does not handle extremely ugly string comparison edge cases ## [3.0.0] - 2018-04-18 @@ -56,7 +92,13 @@ All notable changes are documented in this file using the [Keep a CHANGELOG](htt * Added `SebastianBergmann\Comparator\Factory::reset()` to unregister all non-default comparators * Added support for `phpunit/phpunit-mock-objects` version `^5.0` -[3.0.3]: https://github.com/sebastianbergmann/comparator/compare/3.0.2...3.0.3 +[4.0.6]: https://github.com/sebastianbergmann/comparator/compare/4.0.5...4.0.6 +[4.0.5]: https://github.com/sebastianbergmann/comparator/compare/4.0.4...4.0.5 +[4.0.4]: https://github.com/sebastianbergmann/comparator/compare/4.0.3...4.0.4 +[4.0.3]: https://github.com/sebastianbergmann/comparator/compare/4.0.2...4.0.3 +[4.0.2]: https://github.com/sebastianbergmann/comparator/compare/4.0.1...4.0.2 +[4.0.1]: https://github.com/sebastianbergmann/comparator/compare/4.0.0...4.0.1 +[4.0.0]: https://github.com/sebastianbergmann/comparator/compare/3.0.2...4.0.0 [3.0.2]: https://github.com/sebastianbergmann/comparator/compare/3.0.1...3.0.2 [3.0.1]: https://github.com/sebastianbergmann/comparator/compare/3.0.0...3.0.1 [3.0.0]: https://github.com/sebastianbergmann/comparator/compare/2.1.3...3.0.0 diff --git a/vendor/sebastian/comparator/LICENSE b/vendor/sebastian/comparator/LICENSE index 46d0f2547..6ad70cbaf 100644 --- a/vendor/sebastian/comparator/LICENSE +++ b/vendor/sebastian/comparator/LICENSE @@ -1,6 +1,6 @@ Comparator -Copyright (c) 2002-2018, Sebastian Bergmann . +Copyright (c) 2002-2020, Sebastian Bergmann . All rights reserved. Redistribution and use in source and binary forms, with or without diff --git a/vendor/sebastian/comparator/README.md b/vendor/sebastian/comparator/README.md index 524211af0..f6002db65 100644 --- a/vendor/sebastian/comparator/README.md +++ b/vendor/sebastian/comparator/README.md @@ -1,6 +1,7 @@ -[![Build Status](https://travis-ci.org/sebastianbergmann/comparator.svg?branch=master)](https://travis-ci.org/sebastianbergmann/comparator) +# sebastian/comparator -# Comparator +[![CI Status](https://github.com/sebastianbergmann/comparator/workflows/CI/badge.svg)](https://github.com/sebastianbergmann/comparator/actions) +[![Type Coverage](https://shepherd.dev/github/sebastianbergmann/comparator/coverage.svg)](https://shepherd.dev/github/sebastianbergmann/comparator) This component provides the functionality to compare PHP values for equality. @@ -8,11 +9,15 @@ This component provides the functionality to compare PHP values for equality. You can add this library as a local, per-project dependency to your project using [Composer](https://getcomposer.org/): - composer require sebastian/comparator +``` +composer require sebastian/comparator +``` If you only need this library during development, for instance to run your project's test suite, then you should add it as a development-time dependency: - composer require --dev sebastian/comparator +``` +composer require --dev sebastian/comparator +``` ## Usage @@ -34,4 +39,3 @@ try { print "Dates don't match"; } ``` - diff --git a/vendor/sebastian/comparator/build.xml b/vendor/sebastian/comparator/build.xml deleted file mode 100644 index 8e2799978..000000000 --- a/vendor/sebastian/comparator/build.xml +++ /dev/null @@ -1,21 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - diff --git a/vendor/sebastian/comparator/composer.json b/vendor/sebastian/comparator/composer.json index 00dfc2977..b758e03c9 100644 --- a/vendor/sebastian/comparator/composer.json +++ b/vendor/sebastian/comparator/composer.json @@ -24,14 +24,17 @@ ], "prefer-stable": true, "require": { - "php": ">=7.1", - "sebastian/diff": "^3.0", - "sebastian/exporter": "^3.1" + "php": ">=7.3", + "sebastian/diff": "^4.0", + "sebastian/exporter": "^4.0" }, "require-dev": { - "phpunit/phpunit": "^8.5" + "phpunit/phpunit": "^9.3" }, "config": { + "platform": { + "php": "7.3.0" + }, "optimize-autoloader": true, "sort-packages": true }, @@ -47,7 +50,7 @@ }, "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "4.0-dev" } } } diff --git a/vendor/sebastian/comparator/phpunit.xml b/vendor/sebastian/comparator/phpunit.xml deleted file mode 100644 index 3e12be416..000000000 --- a/vendor/sebastian/comparator/phpunit.xml +++ /dev/null @@ -1,21 +0,0 @@ - - - - - tests - - - - - - src - - - diff --git a/vendor/sebastian/comparator/src/ArrayComparator.php b/vendor/sebastian/comparator/src/ArrayComparator.php index 4b2fadf9f..5d9fbce6e 100644 --- a/vendor/sebastian/comparator/src/ArrayComparator.php +++ b/vendor/sebastian/comparator/src/ArrayComparator.php @@ -1,4 +1,4 @@ - $value) { unset($remaining[$key]); - if (!\array_key_exists($key, $actual)) { - $expectedAsString .= \sprintf( + if (!array_key_exists($key, $actual)) { + $expectedAsString .= sprintf( " %s => %s\n", $this->exporter->export($key), $this->exporter->shortenedExport($value) @@ -70,25 +81,25 @@ class ArrayComparator extends Comparator $comparator = $this->factory->getComparatorFor($value, $actual[$key]); $comparator->assertEquals($value, $actual[$key], $delta, $canonicalize, $ignoreCase, $processed); - $expectedAsString .= \sprintf( + $expectedAsString .= sprintf( " %s => %s\n", $this->exporter->export($key), $this->exporter->shortenedExport($value) ); - $actualAsString .= \sprintf( + $actualAsString .= sprintf( " %s => %s\n", $this->exporter->export($key), $this->exporter->shortenedExport($actual[$key]) ); } catch (ComparisonFailure $e) { - $expectedAsString .= \sprintf( + $expectedAsString .= sprintf( " %s => %s\n", $this->exporter->export($key), $e->getExpectedAsString() ? $this->indent($e->getExpectedAsString()) : $this->exporter->shortenedExport($e->getExpected()) ); - $actualAsString .= \sprintf( + $actualAsString .= sprintf( " %s => %s\n", $this->exporter->export($key), $e->getActualAsString() ? $this->indent($e->getActualAsString()) : $this->exporter->shortenedExport($e->getActual()) @@ -99,7 +110,7 @@ class ArrayComparator extends Comparator } foreach ($remaining as $key => $value) { - $actualAsString .= \sprintf( + $actualAsString .= sprintf( " %s => %s\n", $this->exporter->export($key), $this->exporter->shortenedExport($value) @@ -125,6 +136,6 @@ class ArrayComparator extends Comparator protected function indent($lines) { - return \trim(\str_replace("\n", "\n ", $lines)); + return trim(str_replace("\n", "\n ", $lines)); } } diff --git a/vendor/sebastian/comparator/src/Comparator.php b/vendor/sebastian/comparator/src/Comparator.php index 661746dc2..e1906c167 100644 --- a/vendor/sebastian/comparator/src/Comparator.php +++ b/vendor/sebastian/comparator/src/Comparator.php @@ -1,4 +1,4 @@ -exporter = new Exporter; } - public function setFactory(Factory $factory) + public function setFactory(Factory $factory)/*: void*/ { $this->factory = $factory; } diff --git a/vendor/sebastian/comparator/src/ComparisonFailure.php b/vendor/sebastian/comparator/src/ComparisonFailure.php index d04328877..857314daa 100644 --- a/vendor/sebastian/comparator/src/ComparisonFailure.php +++ b/vendor/sebastian/comparator/src/ComparisonFailure.php @@ -1,4 +1,4 @@ -nodeToText($expected, true, $ignoreCase); $actualAsString = $this->nodeToText($actual, true, $ignoreCase); @@ -56,7 +59,7 @@ class DOMNodeComparator extends ObjectComparator $expectedAsString, $actualAsString, false, - \sprintf("Failed asserting that two DOM %s are equal.\n", $type) + sprintf("Failed asserting that two DOM %s are equal.\n", $type) ); } } @@ -69,7 +72,11 @@ class DOMNodeComparator extends ObjectComparator { if ($canonicalize) { $document = new DOMDocument; - @$document->loadXML($node->C14N()); + + try { + @$document->loadXML($node->C14N()); + } catch (ValueError $e) { + } $node = $document; } @@ -81,6 +88,6 @@ class DOMNodeComparator extends ObjectComparator $text = $node instanceof DOMDocument ? $node->saveXML() : $document->saveXML($node); - return $ignoreCase ? \strtolower($text) : $text; + return $ignoreCase ? strtolower($text) : $text; } } diff --git a/vendor/sebastian/comparator/src/DateTimeComparator.php b/vendor/sebastian/comparator/src/DateTimeComparator.php index af94b5cdb..0a303b623 100644 --- a/vendor/sebastian/comparator/src/DateTimeComparator.php +++ b/vendor/sebastian/comparator/src/DateTimeComparator.php @@ -1,4 +1,4 @@ -f = $absDelta - \floor($absDelta); + /** @var DateTimeInterface $expected */ + /** @var DateTimeInterface $actual */ + $absDelta = abs($delta); + $delta = new DateInterval(sprintf('PT%dS', $absDelta)); + $delta->f = $absDelta - floor($absDelta); $actualClone = (clone $actual) - ->setTimezone(new \DateTimeZone('UTC')); + ->setTimezone(new DateTimeZone('UTC')); $expectedLower = (clone $expected) - ->setTimezone(new \DateTimeZone('UTC')) + ->setTimezone(new DateTimeZone('UTC')) ->sub($delta); $expectedUpper = (clone $expected) - ->setTimezone(new \DateTimeZone('UTC')) + ->setTimezone(new DateTimeZone('UTC')) ->add($delta); if ($actualClone < $expectedLower || $actualClone > $expectedUpper) { @@ -77,7 +86,7 @@ class DateTimeComparator extends ObjectComparator * 'Invalid DateTimeInterface object' if the provided DateTimeInterface was not properly * initialized. */ - private function dateTimeToString(\DateTimeInterface $datetime): string + private function dateTimeToString(DateTimeInterface $datetime): string { $string = $datetime->format('Y-m-d\TH:i:s.uO'); diff --git a/vendor/sebastian/comparator/src/DoubleComparator.php b/vendor/sebastian/comparator/src/DoubleComparator.php index f2b0c4e12..d90b9e06b 100644 --- a/vendor/sebastian/comparator/src/DoubleComparator.php +++ b/vendor/sebastian/comparator/src/DoubleComparator.php @@ -1,4 +1,4 @@ -customComparators, $comparator); + array_unshift($this->customComparators, $comparator); $comparator->setFactory($this); } @@ -96,7 +100,7 @@ class Factory * * @param Comparator $comparator The comparator to be unregistered */ - public function unregister(Comparator $comparator) + public function unregister(Comparator $comparator)/*: void*/ { foreach ($this->customComparators as $key => $_comparator) { if ($comparator === $_comparator) { @@ -108,12 +112,12 @@ class Factory /** * Unregisters all non-default comparators. */ - public function reset() + public function reset()/*: void*/ { $this->customComparators = []; } - private function registerDefaultComparators() + private function registerDefaultComparators(): void { $this->registerDefaultComparator(new MockObjectComparator); $this->registerDefaultComparator(new DateTimeComparator); @@ -129,7 +133,7 @@ class Factory $this->registerDefaultComparator(new TypeComparator); } - private function registerDefaultComparator(Comparator $comparator) + private function registerDefaultComparator(Comparator $comparator): void { $this->defaultComparators[] = $comparator; diff --git a/vendor/sebastian/comparator/src/MockObjectComparator.php b/vendor/sebastian/comparator/src/MockObjectComparator.php index f439d842f..cb6703161 100644 --- a/vendor/sebastian/comparator/src/MockObjectComparator.php +++ b/vendor/sebastian/comparator/src/MockObjectComparator.php @@ -1,4 +1,4 @@ -isInfinite($actual) && $this->isInfinite($expected)) { + return; } - if ((\is_infinite($actual) xor \is_infinite($expected)) || - (\is_nan($actual) || \is_nan($expected)) || - \abs($actual - $expected) > $delta) { + if (($this->isInfinite($actual) xor $this->isInfinite($expected)) || + ($this->isNan($actual) || $this->isNan($expected)) || + abs($actual - $expected) > $delta) { throw new ComparisonFailure( $expected, $actual, '', '', false, - \sprintf( + sprintf( 'Failed asserting that %s matches expected %s.', $this->exporter->export($actual), $this->exporter->export($expected) @@ -65,4 +73,14 @@ class NumericComparator extends ScalarComparator ); } } + + private function isInfinite($value): bool + { + return is_float($value) && is_infinite($value); + } + + private function isNan($value): bool + { + return is_float($value) && is_nan($value); + } } diff --git a/vendor/sebastian/comparator/src/ObjectComparator.php b/vendor/sebastian/comparator/src/ObjectComparator.php index 54fce8244..9380ba150 100644 --- a/vendor/sebastian/comparator/src/ObjectComparator.php +++ b/vendor/sebastian/comparator/src/ObjectComparator.php @@ -1,4 +1,4 @@ -exporter->export($expected), $this->exporter->export($actual), false, - \sprintf( + sprintf( '%s is not instance of expected class "%s".', $this->exporter->export($actual), - \get_class($expected) + get_class($expected) ) ); } // don't compare twice to allow for cyclic dependencies - if (\in_array([$actual, $expected], $processed, true) || - \in_array([$expected, $actual], $processed, true)) { + if (in_array([$actual, $expected], $processed, true) || + in_array([$expected, $actual], $processed, true)) { return; } @@ -82,8 +88,8 @@ class ObjectComparator extends ArrayComparator $expected, $actual, // replace "Array" with "MyClass object" - \substr_replace($e->getExpectedAsString(), \get_class($expected) . ' Object', 0, 5), - \substr_replace($e->getActualAsString(), \get_class($actual) . ' Object', 0, 5), + substr_replace($e->getExpectedAsString(), get_class($expected) . ' Object', 0, 5), + substr_replace($e->getActualAsString(), get_class($actual) . ' Object', 0, 5), false, 'Failed asserting that two objects are equal.' ); diff --git a/vendor/sebastian/comparator/src/ResourceComparator.php b/vendor/sebastian/comparator/src/ResourceComparator.php index 547182643..7822598b1 100644 --- a/vendor/sebastian/comparator/src/ResourceComparator.php +++ b/vendor/sebastian/comparator/src/ResourceComparator.php @@ -1,4 +1,4 @@ -exporter->export($actual), $this->exporter->export($expected) diff --git a/vendor/sebastian/comparator/src/SplObjectStorageComparator.php b/vendor/sebastian/comparator/src/SplObjectStorageComparator.php index 5900d57f2..d9b6f541a 100644 --- a/vendor/sebastian/comparator/src/SplObjectStorageComparator.php +++ b/vendor/sebastian/comparator/src/SplObjectStorageComparator.php @@ -1,4 +1,4 @@ -contains($object)) { diff --git a/vendor/sebastian/comparator/src/TypeComparator.php b/vendor/sebastian/comparator/src/TypeComparator.php index e7f551f89..b0d38d72e 100644 --- a/vendor/sebastian/comparator/src/TypeComparator.php +++ b/vendor/sebastian/comparator/src/TypeComparator.php @@ -1,4 +1,4 @@ -exporter->shortenedExport($actual), - \gettype($expected) + gettype($expected) ) ); } diff --git a/vendor/sebastian/comparator/tests/_fixture/TestClass.php b/vendor/sebastian/comparator/src/exceptions/Exception.php similarity index 76% rename from vendor/sebastian/comparator/tests/_fixture/TestClass.php rename to vendor/sebastian/comparator/src/exceptions/Exception.php index fd10c1bab..8975aaf1b 100644 --- a/vendor/sebastian/comparator/tests/_fixture/TestClass.php +++ b/vendor/sebastian/comparator/src/exceptions/Exception.php @@ -1,4 +1,4 @@ - * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ -namespace SebastianBergmann\Timer; +namespace SebastianBergmann\Comparator; final class RuntimeException extends \RuntimeException implements Exception { diff --git a/vendor/sebastian/comparator/tests/ArrayComparatorTest.php b/vendor/sebastian/comparator/tests/ArrayComparatorTest.php deleted file mode 100644 index 25906bb59..000000000 --- a/vendor/sebastian/comparator/tests/ArrayComparatorTest.php +++ /dev/null @@ -1,161 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Comparator; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\Comparator\ArrayComparator - * - * @uses \SebastianBergmann\Comparator\Comparator - * @uses \SebastianBergmann\Comparator\Factory - * @uses \SebastianBergmann\Comparator\ComparisonFailure - */ -final class ArrayComparatorTest extends TestCase -{ - /** - * @var ArrayComparator - */ - private $comparator; - - protected function setUp(): void - { - $this->comparator = new ArrayComparator; - $this->comparator->setFactory(new Factory); - } - - public function acceptsFailsProvider() - { - return [ - [[], null], - [null, []], - [null, null] - ]; - } - - public function assertEqualsSucceedsProvider() - { - return [ - [ - ['a' => 1, 'b' => 2], - ['b' => 2, 'a' => 1] - ], - [ - [1], - ['1'] - ], - [ - [3, 2, 1], - [2, 3, 1], - 0, - true - ], - [ - [2.3], - [2.5], - 0.5 - ], - [ - [[2.3]], - [[2.5]], - 0.5 - ], - [ - [new Struct(2.3)], - [new Struct(2.5)], - 0.5 - ], - ]; - } - - public function assertEqualsFailsProvider() - { - return [ - [ - [], - [0 => 1] - ], - [ - [0 => 1], - [] - ], - [ - [0 => null], - [] - ], - [ - [0 => 1, 1 => 2], - [0 => 1, 1 => 3] - ], - [ - ['a', 'b' => [1, 2]], - ['a', 'b' => [2, 1]] - ], - [ - [2.3], - [4.2], - 0.5 - ], - [ - [[2.3]], - [[4.2]], - 0.5 - ], - [ - [new Struct(2.3)], - [new Struct(4.2)], - 0.5 - ] - ]; - } - - public function testAcceptsSucceeds(): void - { - $this->assertTrue( - $this->comparator->accepts([], []) - ); - } - - /** - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual): void - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual, $delta = 0.0, $canonicalize = false): void - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual, $delta, $canonicalize); - } catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual, $delta = 0.0, $canonicalize = false): void - { - $this->expectException(ComparisonFailure::class); - $this->expectExceptionMessage('Failed asserting that two arrays are equal'); - - $this->comparator->assertEquals($expected, $actual, $delta, $canonicalize); - } -} diff --git a/vendor/sebastian/comparator/tests/ComparisonFailureTest.php b/vendor/sebastian/comparator/tests/ComparisonFailureTest.php deleted file mode 100644 index 3b438b761..000000000 --- a/vendor/sebastian/comparator/tests/ComparisonFailureTest.php +++ /dev/null @@ -1,59 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Comparator; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\Comparator\ComparisonFailure - * - * @uses \SebastianBergmann\Comparator\Factory - */ -final class ComparisonFailureTest extends TestCase -{ - public function testComparisonFailure(): void - { - $actual = "\nB\n"; - $expected = "\nA\n"; - $message = 'Test message'; - - $failure = new ComparisonFailure( - $expected, - $actual, - '|' . $expected, - '|' . $actual, - false, - $message - ); - - $this->assertSame($actual, $failure->getActual()); - $this->assertSame($expected, $failure->getExpected()); - $this->assertSame('|' . $actual, $failure->getActualAsString()); - $this->assertSame('|' . $expected, $failure->getExpectedAsString()); - - $diff = ' ---- Expected -+++ Actual -@@ @@ - | --A -+B -'; - $this->assertSame($diff, $failure->getDiff()); - $this->assertSame($message . $diff, $failure->toString()); - } - - public function testDiffNotPossible(): void - { - $failure = new ComparisonFailure('a', 'b', false, false, true, 'test'); - $this->assertSame('', $failure->getDiff()); - $this->assertSame('test', $failure->toString()); - } -} diff --git a/vendor/sebastian/comparator/tests/DOMNodeComparatorTest.php b/vendor/sebastian/comparator/tests/DOMNodeComparatorTest.php deleted file mode 100644 index 18451e0ac..000000000 --- a/vendor/sebastian/comparator/tests/DOMNodeComparatorTest.php +++ /dev/null @@ -1,180 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Comparator; - -use DOMDocument; -use DOMNode; -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\Comparator\DOMNodeComparator - * - * @uses \SebastianBergmann\Comparator\Comparator - * @uses \SebastianBergmann\Comparator\Factory - * @uses \SebastianBergmann\Comparator\ComparisonFailure - */ -final class DOMNodeComparatorTest extends TestCase -{ - /** - * @var DOMNodeComparator - */ - private $comparator; - - protected function setUp(): void - { - $this->comparator = new DOMNodeComparator; - } - - public function acceptsSucceedsProvider() - { - $document = new DOMDocument; - $node = new DOMNode; - - return [ - [$document, $document], - [$node, $node], - [$document, $node], - [$node, $document] - ]; - } - - public function acceptsFailsProvider() - { - $document = new DOMDocument; - - return [ - [$document, null], - [null, $document], - [null, null] - ]; - } - - public function assertEqualsSucceedsProvider() - { - return [ - [ - $this->createDOMDocument(''), - $this->createDOMDocument('') - ], - [ - $this->createDOMDocument(''), - $this->createDOMDocument('') - ], - [ - $this->createDOMDocument(''), - $this->createDOMDocument('') - ], - [ - $this->createDOMDocument("\n \n"), - $this->createDOMDocument('') - ], - [ - $this->createDOMDocument(''), - $this->createDOMDocument(''), - $ignoreCase = true - ], - [ - $this->createDOMDocument(""), - $this->createDOMDocument(""), - ], - ]; - } - - public function assertEqualsFailsProvider() - { - return [ - [ - $this->createDOMDocument(''), - $this->createDOMDocument('') - ], - [ - $this->createDOMDocument(''), - $this->createDOMDocument('') - ], - [ - $this->createDOMDocument(' bar '), - $this->createDOMDocument('') - ], - [ - $this->createDOMDocument(''), - $this->createDOMDocument('') - ], - [ - $this->createDOMDocument(' bar '), - $this->createDOMDocument(' bir ') - ], - [ - $this->createDOMDocument(''), - $this->createDOMDocument('') - ], - [ - $this->createDOMDocument(' bar '), - $this->createDOMDocument(' BAR ') - ] - ]; - } - - /** - * @dataProvider acceptsSucceedsProvider - */ - public function testAcceptsSucceeds($expected, $actual): void - { - $this->assertTrue( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual): void - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual, $ignoreCase = false): void - { - $exception = null; - - try { - $delta = 0.0; - $canonicalize = false; - $this->comparator->assertEquals($expected, $actual, $delta, $canonicalize, $ignoreCase); - } catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual): void - { - $this->expectException(ComparisonFailure::class); - $this->expectExceptionMessage('Failed asserting that two DOM'); - - $this->comparator->assertEquals($expected, $actual); - } - - private function createDOMDocument($content) - { - $document = new DOMDocument; - $document->preserveWhiteSpace = false; - $document->loadXML($content); - - return $document; - } -} diff --git a/vendor/sebastian/comparator/tests/DateTimeComparatorTest.php b/vendor/sebastian/comparator/tests/DateTimeComparatorTest.php deleted file mode 100644 index 41e108619..000000000 --- a/vendor/sebastian/comparator/tests/DateTimeComparatorTest.php +++ /dev/null @@ -1,213 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Comparator; - -use DateTime; -use DateTimeImmutable; -use DateTimeZone; -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\Comparator\DateTimeComparator - * - * @uses \SebastianBergmann\Comparator\Comparator - * @uses \SebastianBergmann\Comparator\Factory - * @uses \SebastianBergmann\Comparator\ComparisonFailure - */ -final class DateTimeComparatorTest extends TestCase -{ - /** - * @var DateTimeComparator - */ - private $comparator; - - protected function setUp(): void - { - $this->comparator = new DateTimeComparator; - } - - public function acceptsFailsProvider() - { - $datetime = new DateTime; - - return [ - [$datetime, null], - [null, $datetime], - [null, null] - ]; - } - - public function assertEqualsSucceedsProvider() - { - return [ - [ - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 04:13:25', new DateTimeZone('America/New_York')), - 10 - ], - [ - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 04:14:40', new DateTimeZone('America/New_York')), - 65 - ], - [ - new DateTime('2013-03-29', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29', new DateTimeZone('America/New_York')) - ], - [ - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 03:13:35', new DateTimeZone('America/Chicago')) - ], - [ - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 03:13:49', new DateTimeZone('America/Chicago')), - 15 - ], - [ - new DateTime('2013-03-30', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 23:00:00', new DateTimeZone('America/Chicago')) - ], - [ - new DateTime('2013-03-30', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 23:01:30', new DateTimeZone('America/Chicago')), - 100 - ], - [ - new DateTime('@1364616000'), - new DateTime('2013-03-29 23:00:00', new DateTimeZone('America/Chicago')) - ], - [ - new DateTime('2013-03-29T05:13:35-0500'), - new DateTime('2013-03-29T04:13:35-0600') - ], - [ - new DateTimeImmutable('2013-03-30', new DateTimeZone('America/New_York')), - new DateTimeImmutable('2013-03-29 23:01:30', new DateTimeZone('America/Chicago')), - 100 - ], - [ - new DateTimeImmutable('2013-03-30 12:00:00', new DateTimeZone('UTC')), - new DateTimeImmutable('2013-03-30 12:00:00.5', new DateTimeZone('UTC')), - 0.5 - ], - ]; - } - - public function assertEqualsFailsProvider() - { - return [ - [ - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 03:13:35', new DateTimeZone('America/New_York')) - ], - [ - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 03:13:35', new DateTimeZone('America/New_York')), - 3500 - ], - [ - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 05:13:35', new DateTimeZone('America/New_York')), - 3500 - ], - [ - new DateTime('2013-03-29', new DateTimeZone('America/New_York')), - new DateTime('2013-03-30', new DateTimeZone('America/New_York')) - ], - [ - new DateTime('2013-03-29', new DateTimeZone('America/New_York')), - new DateTime('2013-03-30', new DateTimeZone('America/New_York')), - 43200 - ], - [ - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/Chicago')), - ], - [ - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/Chicago')), - 3500 - ], - [ - new DateTime('2013-03-30', new DateTimeZone('America/New_York')), - new DateTime('2013-03-30', new DateTimeZone('America/Chicago')) - ], - [ - new DateTime('2013-03-29T05:13:35-0600'), - new DateTime('2013-03-29T04:13:35-0600') - ], - [ - new DateTime('2013-03-29T05:13:35-0600'), - new DateTime('2013-03-29T05:13:35-0500') - ], - ]; - } - - public function testAcceptsSucceeds(): void - { - $this->assertTrue( - $this->comparator->accepts( - new DateTime, - new DateTime - ) - ); - } - - /** - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual): void - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual, $delta = 0.0): void - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual, $delta); - } catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual, $delta = 0.0): void - { - $this->expectException(ComparisonFailure::class); - $this->expectExceptionMessage('Failed asserting that two DateTime objects are equal.'); - - $this->comparator->assertEquals($expected, $actual, $delta); - } - - public function testAcceptsDateTimeInterface(): void - { - $this->assertTrue($this->comparator->accepts(new DateTime, new DateTimeImmutable)); - } - - public function testSupportsDateTimeInterface(): void - { - $this->assertNull( - $this->comparator->assertEquals( - new DateTime('2013-03-29 04:13:35', new DateTimeZone('America/New_York')), - new DateTimeImmutable('2013-03-29 04:13:35', new DateTimeZone('America/New_York')) - ) - ); - } -} diff --git a/vendor/sebastian/comparator/tests/DoubleComparatorTest.php b/vendor/sebastian/comparator/tests/DoubleComparatorTest.php deleted file mode 100644 index 1a577a218..000000000 --- a/vendor/sebastian/comparator/tests/DoubleComparatorTest.php +++ /dev/null @@ -1,135 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Comparator; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\Comparator\DoubleComparator - * - * @uses \SebastianBergmann\Comparator\Comparator - * @uses \SebastianBergmann\Comparator\Factory - * @uses \SebastianBergmann\Comparator\ComparisonFailure - */ -final class DoubleComparatorTest extends TestCase -{ - /** - * @var DoubleComparator - */ - private $comparator; - - protected function setUp(): void - { - $this->comparator = new DoubleComparator; - } - - public function acceptsSucceedsProvider() - { - return [ - [0, 5.0], - [5.0, 0], - ['5', 4.5], - [1.2e3, 7E-10], - [3, \acos(8)], - [\acos(8), 3], - [\acos(8), \acos(8)] - ]; - } - - public function acceptsFailsProvider() - { - return [ - [5, 5], - ['4.5', 5], - [0x539, 02471], - [5.0, false], - [null, 5.0] - ]; - } - - public function assertEqualsSucceedsProvider() - { - return [ - [2.3, 2.3], - ['2.3', 2.3], - [5.0, 5], - [5, 5.0], - [5.0, '5'], - [1.2e3, 1200], - [2.3, 2.5, 0.5], - [3, 3.05, 0.05], - [1.2e3, 1201, 1], - [(string) (1 / 3), 1 - 2 / 3], - [1 / 3, (string) (1 - 2 / 3)] - ]; - } - - public function assertEqualsFailsProvider() - { - return [ - [2.3, 4.2], - ['2.3', 4.2], - [5.0, '4'], - [5.0, 6], - [1.2e3, 1201], - [2.3, 2.5, 0.2], - [3, 3.05, 0.04], - [3, \acos(8)], - [\acos(8), 3], - [\acos(8), \acos(8)] - ]; - } - - /** - * @dataProvider acceptsSucceedsProvider - */ - public function testAcceptsSucceeds($expected, $actual): void - { - $this->assertTrue( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual): void - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual, $delta = 0.0): void - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual, $delta); - } catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual, $delta = 0.0): void - { - $this->expectException(ComparisonFailure::class); - $this->expectExceptionMessage('matches expected'); - - $this->comparator->assertEquals($expected, $actual, $delta); - } -} diff --git a/vendor/sebastian/comparator/tests/ExceptionComparatorTest.php b/vendor/sebastian/comparator/tests/ExceptionComparatorTest.php deleted file mode 100644 index 12330eaa2..000000000 --- a/vendor/sebastian/comparator/tests/ExceptionComparatorTest.php +++ /dev/null @@ -1,136 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Comparator; - -use Exception; -use PHPUnit\Framework\TestCase; -use RuntimeException; - -/** - * @covers \SebastianBergmann\Comparator\ExceptionComparator - * - * @uses \SebastianBergmann\Comparator\Comparator - * @uses \SebastianBergmann\Comparator\Factory - * @uses \SebastianBergmann\Comparator\ComparisonFailure - */ -final class ExceptionComparatorTest extends TestCase -{ - /** - * @var ExceptionComparator - */ - private $comparator; - - protected function setUp(): void - { - $this->comparator = new ExceptionComparator; - $this->comparator->setFactory(new Factory); - } - - public function acceptsSucceedsProvider() - { - return [ - [new Exception, new Exception], - [new RuntimeException, new RuntimeException], - [new Exception, new RuntimeException] - ]; - } - - public function acceptsFailsProvider() - { - return [ - [new Exception, null], - [null, new Exception], - [null, null] - ]; - } - - public function assertEqualsSucceedsProvider() - { - $exception1 = new Exception; - $exception2 = new Exception; - - $exception3 = new RuntimeException('Error', 100); - $exception4 = new RuntimeException('Error', 100); - - return [ - [$exception1, $exception1], - [$exception1, $exception2], - [$exception3, $exception3], - [$exception3, $exception4] - ]; - } - - public function assertEqualsFailsProvider() - { - $typeMessage = 'not instance of expected class'; - $equalMessage = 'Failed asserting that two objects are equal.'; - - $exception1 = new Exception('Error', 100); - $exception2 = new Exception('Error', 101); - $exception3 = new Exception('Errors', 101); - - $exception4 = new RuntimeException('Error', 100); - $exception5 = new RuntimeException('Error', 101); - - return [ - [$exception1, $exception2, $equalMessage], - [$exception1, $exception3, $equalMessage], - [$exception1, $exception4, $typeMessage], - [$exception2, $exception3, $equalMessage], - [$exception4, $exception5, $equalMessage] - ]; - } - - /** - * @dataProvider acceptsSucceedsProvider - */ - public function testAcceptsSucceeds($expected, $actual): void - { - $this->assertTrue( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual): void - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual): void - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual); - } catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual, $message): void - { - $this->expectException(ComparisonFailure::class); - $this->expectExceptionMessage($message); - - $this->comparator->assertEquals($expected, $actual); - } -} diff --git a/vendor/sebastian/comparator/tests/FactoryTest.php b/vendor/sebastian/comparator/tests/FactoryTest.php deleted file mode 100644 index 82f53433e..000000000 --- a/vendor/sebastian/comparator/tests/FactoryTest.php +++ /dev/null @@ -1,117 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Comparator; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\Comparator\Factory - * - * @uses \SebastianBergmann\Comparator\Comparator - * @uses \SebastianBergmann\Comparator\Factory - * @uses \SebastianBergmann\Comparator\ComparisonFailure - */ -final class FactoryTest extends TestCase -{ - public function instanceProvider() - { - $tmpfile = \tmpfile(); - - return [ - [null, null, 'SebastianBergmann\\Comparator\\ScalarComparator'], - [null, true, 'SebastianBergmann\\Comparator\\ScalarComparator'], - [true, null, 'SebastianBergmann\\Comparator\\ScalarComparator'], - [true, true, 'SebastianBergmann\\Comparator\\ScalarComparator'], - [false, false, 'SebastianBergmann\\Comparator\\ScalarComparator'], - [true, false, 'SebastianBergmann\\Comparator\\ScalarComparator'], - [false, true, 'SebastianBergmann\\Comparator\\ScalarComparator'], - ['', '', 'SebastianBergmann\\Comparator\\ScalarComparator'], - ['0', '0', 'SebastianBergmann\\Comparator\\ScalarComparator'], - ['0', 0, 'SebastianBergmann\\Comparator\\NumericComparator'], - [0, '0', 'SebastianBergmann\\Comparator\\NumericComparator'], - [0, 0, 'SebastianBergmann\\Comparator\\NumericComparator'], - [1.0, 0, 'SebastianBergmann\\Comparator\\DoubleComparator'], - [0, 1.0, 'SebastianBergmann\\Comparator\\DoubleComparator'], - [1.0, 1.0, 'SebastianBergmann\\Comparator\\DoubleComparator'], - [[1], [1], 'SebastianBergmann\\Comparator\\ArrayComparator'], - [$tmpfile, $tmpfile, 'SebastianBergmann\\Comparator\\ResourceComparator'], - [new \stdClass, new \stdClass, 'SebastianBergmann\\Comparator\\ObjectComparator'], - [new \DateTime, new \DateTime, 'SebastianBergmann\\Comparator\\DateTimeComparator'], - [new \SplObjectStorage, new \SplObjectStorage, 'SebastianBergmann\\Comparator\\SplObjectStorageComparator'], - [new \Exception, new \Exception, 'SebastianBergmann\\Comparator\\ExceptionComparator'], - [new \DOMDocument, new \DOMDocument, 'SebastianBergmann\\Comparator\\DOMNodeComparator'], - // mixed types - [$tmpfile, [1], 'SebastianBergmann\\Comparator\\TypeComparator'], - [[1], $tmpfile, 'SebastianBergmann\\Comparator\\TypeComparator'], - [$tmpfile, '1', 'SebastianBergmann\\Comparator\\TypeComparator'], - ['1', $tmpfile, 'SebastianBergmann\\Comparator\\TypeComparator'], - [$tmpfile, new \stdClass, 'SebastianBergmann\\Comparator\\TypeComparator'], - [new \stdClass, $tmpfile, 'SebastianBergmann\\Comparator\\TypeComparator'], - [new \stdClass, [1], 'SebastianBergmann\\Comparator\\TypeComparator'], - [[1], new \stdClass, 'SebastianBergmann\\Comparator\\TypeComparator'], - [new \stdClass, '1', 'SebastianBergmann\\Comparator\\TypeComparator'], - ['1', new \stdClass, 'SebastianBergmann\\Comparator\\TypeComparator'], - [new ClassWithToString, '1', 'SebastianBergmann\\Comparator\\ScalarComparator'], - ['1', new ClassWithToString, 'SebastianBergmann\\Comparator\\ScalarComparator'], - [1.0, new \stdClass, 'SebastianBergmann\\Comparator\\TypeComparator'], - [new \stdClass, 1.0, 'SebastianBergmann\\Comparator\\TypeComparator'], - [1.0, [1], 'SebastianBergmann\\Comparator\\TypeComparator'], - [[1], 1.0, 'SebastianBergmann\\Comparator\\TypeComparator'], - ]; - } - - /** - * @dataProvider instanceProvider - */ - public function testGetComparatorFor($a, $b, $expected): void - { - $factory = new Factory; - $actual = $factory->getComparatorFor($a, $b); - $this->assertInstanceOf($expected, $actual); - } - - public function testRegister(): void - { - $comparator = new TestClassComparator; - - $factory = new Factory; - $factory->register($comparator); - - $a = new TestClass; - $b = new TestClass; - $expected = 'SebastianBergmann\\Comparator\\TestClassComparator'; - $actual = $factory->getComparatorFor($a, $b); - - $factory->unregister($comparator); - $this->assertInstanceOf($expected, $actual); - } - - public function testUnregister(): void - { - $comparator = new TestClassComparator; - - $factory = new Factory; - $factory->register($comparator); - $factory->unregister($comparator); - - $a = new TestClass; - $b = new TestClass; - $expected = 'SebastianBergmann\\Comparator\\ObjectComparator'; - $actual = $factory->getComparatorFor($a, $b); - - $this->assertInstanceOf($expected, $actual); - } - - public function testIsSingleton(): void - { - $f = Factory::getInstance(); - $this->assertSame($f, Factory::getInstance()); - } -} diff --git a/vendor/sebastian/comparator/tests/MockObjectComparatorTest.php b/vendor/sebastian/comparator/tests/MockObjectComparatorTest.php deleted file mode 100644 index 922e9d694..000000000 --- a/vendor/sebastian/comparator/tests/MockObjectComparatorTest.php +++ /dev/null @@ -1,168 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Comparator; - -use PHPUnit\Framework\TestCase; -use stdClass; - -/** - * @covers \SebastianBergmann\Comparator\MockObjectComparator - * - * @uses \SebastianBergmann\Comparator\Comparator - * @uses \SebastianBergmann\Comparator\Factory - * @uses \SebastianBergmann\Comparator\ComparisonFailure - */ -final class MockObjectComparatorTest extends TestCase -{ - /** - * @var MockObjectComparator - */ - private $comparator; - - protected function setUp(): void - { - $this->comparator = new MockObjectComparator; - $this->comparator->setFactory(new Factory); - } - - public function acceptsSucceedsProvider() - { - $testmock = $this->createMock(TestClass::class); - $stdmock = $this->createMock(stdClass::class); - - return [ - [$testmock, $testmock], - [$stdmock, $stdmock], - [$stdmock, $testmock] - ]; - } - - public function acceptsFailsProvider() - { - $stdmock = $this->createMock(stdClass::class); - - return [ - [$stdmock, null], - [null, $stdmock], - [null, null] - ]; - } - - public function assertEqualsSucceedsProvider() - { - // cyclic dependencies - $book1 = $this->getMockBuilder(Book::class)->setMethods(null)->getMock(); - $book1->author = $this->getMockBuilder(Author::class)->setMethods(null)->setConstructorArgs(['Terry Pratchett'])->getMock(); - $book1->author->books[] = $book1; - $book2 = $this->getMockBuilder(Book::class)->setMethods(null)->getMock(); - $book2->author = $this->getMockBuilder(Author::class)->setMethods(null)->setConstructorArgs(['Terry Pratchett'])->getMock(); - $book2->author->books[] = $book2; - - $object1 = $this->getMockBuilder(SampleClass::class)->setMethods(null)->setConstructorArgs([4, 8, 15])->getMock(); - $object2 = $this->getMockBuilder(SampleClass::class)->setMethods(null)->setConstructorArgs([4, 8, 15])->getMock(); - - return [ - [$object1, $object1], - [$object1, $object2], - [$book1, $book1], - [$book1, $book2], - [ - $this->getMockBuilder(Struct::class)->setMethods(null)->setConstructorArgs([2.3])->getMock(), - $this->getMockBuilder(Struct::class)->setMethods(null)->setConstructorArgs([2.5])->getMock(), - 0.5 - ] - ]; - } - - public function assertEqualsFailsProvider() - { - $typeMessage = 'is not instance of expected class'; - $equalMessage = 'Failed asserting that two objects are equal.'; - - // cyclic dependencies - $book1 = $this->getMockBuilder(Book::class)->setMethods(null)->getMock(); - $book1->author = $this->getMockBuilder(Author::class)->setMethods(null)->setConstructorArgs(['Terry Pratchett'])->getMock(); - $book1->author->books[] = $book1; - $book2 = $this->getMockBuilder(Book::class)->setMethods(null)->getMock(); - $book1->author = $this->getMockBuilder(Author::class)->setMethods(null)->setConstructorArgs(['Terry Pratch'])->getMock(); - $book2->author->books[] = $book2; - - $book3 = $this->getMockBuilder(Book::class)->setMethods(null)->getMock(); - $book3->author = 'Terry Pratchett'; - $book4 = $this->createMock(stdClass::class); - $book4->author = 'Terry Pratchett'; - - $object1 = $this->getMockBuilder(SampleClass::class)->setMethods(null)->setConstructorArgs([4, 8, 15])->getMock(); - $object2 = $this->getMockBuilder(SampleClass::class)->setMethods(null)->setConstructorArgs([16, 23, 42])->getMock(); - - return [ - [ - $this->getMockBuilder(SampleClass::class)->setMethods(null)->setConstructorArgs([4, 8, 15])->getMock(), - $this->getMockBuilder(SampleClass::class)->setMethods(null)->setConstructorArgs([16, 23, 42])->getMock(), - $equalMessage - ], - [$object1, $object2, $equalMessage], - [$book1, $book2, $equalMessage], - [$book3, $book4, $typeMessage], - [ - $this->getMockBuilder(Struct::class)->setMethods(null)->setConstructorArgs([2.3])->getMock(), - $this->getMockBuilder(Struct::class)->setMethods(null)->setConstructorArgs([4.2])->getMock(), - $equalMessage, - 0.5 - ] - ]; - } - - /** - * @dataProvider acceptsSucceedsProvider - */ - public function testAcceptsSucceeds($expected, $actual): void - { - $this->assertTrue( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual): void - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual, $delta = 0.0): void - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual, $delta); - } catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual, $message, $delta = 0.0): void - { - $this->expectException(ComparisonFailure::class); - $this->expectExceptionMessage($message); - - $this->comparator->assertEquals($expected, $actual, $delta); - } -} diff --git a/vendor/sebastian/comparator/tests/NumericComparatorTest.php b/vendor/sebastian/comparator/tests/NumericComparatorTest.php deleted file mode 100644 index 504172f4a..000000000 --- a/vendor/sebastian/comparator/tests/NumericComparatorTest.php +++ /dev/null @@ -1,123 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Comparator; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\Comparator\NumericComparator - * - * @uses \SebastianBergmann\Comparator\Comparator - * @uses \SebastianBergmann\Comparator\Factory - * @uses \SebastianBergmann\Comparator\ComparisonFailure - */ -final class NumericComparatorTest extends TestCase -{ - /** - * @var NumericComparator - */ - private $comparator; - - protected function setUp(): void - { - $this->comparator = new NumericComparator; - } - - public function acceptsSucceedsProvider() - { - return [ - [5, 10], - [8, '0'], - ['10', 0], - [0x74c3b00c, 42], - [0755, 0777] - ]; - } - - public function acceptsFailsProvider() - { - return [ - ['5', '10'], - [8, 5.0], - [5.0, 8], - [10, null], - [false, 12] - ]; - } - - public function assertEqualsSucceedsProvider() - { - return [ - [1337, 1337], - ['1337', 1337], - [0x539, 1337], - [02471, 1337], - [1337, 1338, 1], - ['1337', 1340, 5], - ]; - } - - public function assertEqualsFailsProvider() - { - return [ - [1337, 1338], - ['1338', 1337], - [0x539, 1338], - [1337, 1339, 1], - ['1337', 1340, 2], - ]; - } - - /** - * @dataProvider acceptsSucceedsProvider - */ - public function testAcceptsSucceeds($expected, $actual): void - { - $this->assertTrue( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual): void - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual, $delta = 0.0): void - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual, $delta); - } catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual, $delta = 0.0): void - { - $this->expectException(ComparisonFailure::class); - $this->expectExceptionMessage('matches expected'); - - $this->comparator->assertEquals($expected, $actual, $delta); - } -} diff --git a/vendor/sebastian/comparator/tests/ObjectComparatorTest.php b/vendor/sebastian/comparator/tests/ObjectComparatorTest.php deleted file mode 100644 index 30ef2306a..000000000 --- a/vendor/sebastian/comparator/tests/ObjectComparatorTest.php +++ /dev/null @@ -1,150 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Comparator; - -use PHPUnit\Framework\TestCase; -use stdClass; - -/** - * @covers \SebastianBergmann\Comparator\ObjectComparator - * - * @uses \SebastianBergmann\Comparator\Comparator - * @uses \SebastianBergmann\Comparator\Factory - * @uses \SebastianBergmann\Comparator\ComparisonFailure - */ -final class ObjectComparatorTest extends TestCase -{ - /** - * @var ObjectComparator - */ - private $comparator; - - protected function setUp(): void - { - $this->comparator = new ObjectComparator; - $this->comparator->setFactory(new Factory); - } - - public function acceptsSucceedsProvider() - { - return [ - [new TestClass, new TestClass], - [new stdClass, new stdClass], - [new stdClass, new TestClass] - ]; - } - - public function acceptsFailsProvider() - { - return [ - [new stdClass, null], - [null, new stdClass], - [null, null] - ]; - } - - public function assertEqualsSucceedsProvider() - { - // cyclic dependencies - $book1 = new Book; - $book1->author = new Author('Terry Pratchett'); - $book1->author->books[] = $book1; - $book2 = new Book; - $book2->author = new Author('Terry Pratchett'); - $book2->author->books[] = $book2; - - $object1 = new SampleClass(4, 8, 15); - $object2 = new SampleClass(4, 8, 15); - - return [ - [$object1, $object1], - [$object1, $object2], - [$book1, $book1], - [$book1, $book2], - [new Struct(2.3), new Struct(2.5), 0.5] - ]; - } - - public function assertEqualsFailsProvider() - { - $typeMessage = 'is not instance of expected class'; - $equalMessage = 'Failed asserting that two objects are equal.'; - - // cyclic dependencies - $book1 = new Book; - $book1->author = new Author('Terry Pratchett'); - $book1->author->books[] = $book1; - $book2 = new Book; - $book2->author = new Author('Terry Pratch'); - $book2->author->books[] = $book2; - - $book3 = new Book; - $book3->author = 'Terry Pratchett'; - $book4 = new stdClass; - $book4->author = 'Terry Pratchett'; - - $object1 = new SampleClass(4, 8, 15); - $object2 = new SampleClass(16, 23, 42); - - return [ - [new SampleClass(4, 8, 15), new SampleClass(16, 23, 42), $equalMessage], - [$object1, $object2, $equalMessage], - [$book1, $book2, $equalMessage], - [$book3, $book4, $typeMessage], - [new Struct(2.3), new Struct(4.2), $equalMessage, 0.5] - ]; - } - - /** - * @dataProvider acceptsSucceedsProvider - */ - public function testAcceptsSucceeds($expected, $actual): void - { - $this->assertTrue( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual): void - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual, $delta = 0.0): void - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual, $delta); - } catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual, $message, $delta = 0.0): void - { - $this->expectException(ComparisonFailure::class); - $this->expectExceptionMessage($message); - - $this->comparator->assertEquals($expected, $actual, $delta); - } -} diff --git a/vendor/sebastian/comparator/tests/ResourceComparatorTest.php b/vendor/sebastian/comparator/tests/ResourceComparatorTest.php deleted file mode 100644 index 158aaa903..000000000 --- a/vendor/sebastian/comparator/tests/ResourceComparatorTest.php +++ /dev/null @@ -1,122 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Comparator; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\Comparator\ResourceComparator - * - * @uses \SebastianBergmann\Comparator\Comparator - * @uses \SebastianBergmann\Comparator\Factory - * @uses \SebastianBergmann\Comparator\ComparisonFailure - */ -final class ResourceComparatorTest extends TestCase -{ - /** - * @var ResourceComparator - */ - private $comparator; - - protected function setUp(): void - { - $this->comparator = new ResourceComparator; - } - - public function acceptsSucceedsProvider() - { - $tmpfile1 = \tmpfile(); - $tmpfile2 = \tmpfile(); - - return [ - [$tmpfile1, $tmpfile1], - [$tmpfile2, $tmpfile2], - [$tmpfile1, $tmpfile2] - ]; - } - - public function acceptsFailsProvider() - { - $tmpfile1 = \tmpfile(); - - return [ - [$tmpfile1, null], - [null, $tmpfile1], - [null, null] - ]; - } - - public function assertEqualsSucceedsProvider() - { - $tmpfile1 = \tmpfile(); - $tmpfile2 = \tmpfile(); - - return [ - [$tmpfile1, $tmpfile1], - [$tmpfile2, $tmpfile2] - ]; - } - - public function assertEqualsFailsProvider() - { - $tmpfile1 = \tmpfile(); - $tmpfile2 = \tmpfile(); - - return [ - [$tmpfile1, $tmpfile2], - [$tmpfile2, $tmpfile1] - ]; - } - - /** - * @dataProvider acceptsSucceedsProvider - */ - public function testAcceptsSucceeds($expected, $actual): void - { - $this->assertTrue( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual): void - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual): void - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual); - } catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual): void - { - $this->expectException(ComparisonFailure::class); - - $this->comparator->assertEquals($expected, $actual); - } -} diff --git a/vendor/sebastian/comparator/tests/ScalarComparatorTest.php b/vendor/sebastian/comparator/tests/ScalarComparatorTest.php deleted file mode 100644 index 11feae274..000000000 --- a/vendor/sebastian/comparator/tests/ScalarComparatorTest.php +++ /dev/null @@ -1,164 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Comparator; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\Comparator\ScalarComparator - * - * @uses \SebastianBergmann\Comparator\Comparator - * @uses \SebastianBergmann\Comparator\Factory - * @uses \SebastianBergmann\Comparator\ComparisonFailure - */ -final class ScalarComparatorTest extends TestCase -{ - /** - * @var ScalarComparator - */ - private $comparator; - - protected function setUp(): void - { - $this->comparator = new ScalarComparator; - } - - public function acceptsSucceedsProvider() - { - return [ - ['string', 'string'], - [new ClassWithToString, 'string'], - ['string', new ClassWithToString], - ['string', null], - [false, 'string'], - [false, true], - [null, false], - [null, null], - ['10', 10], - ['', false], - ['1', true], - [1, true], - [0, false], - [0.1, '0.1'] - ]; - } - - public function acceptsFailsProvider() - { - return [ - [[], []], - ['string', []], - [new ClassWithToString, new ClassWithToString], - [false, new ClassWithToString], - [\tmpfile(), \tmpfile()] - ]; - } - - public function assertEqualsSucceedsProvider() - { - return [ - ['string', 'string'], - [new ClassWithToString, new ClassWithToString], - ['string representation', new ClassWithToString], - [new ClassWithToString, 'string representation'], - ['string', 'STRING', true], - ['STRING', 'string', true], - ['String Representation', new ClassWithToString, true], - [new ClassWithToString, 'String Representation', true], - ['10', 10], - ['', false], - ['1', true], - [1, true], - [0, false], - [0.1, '0.1'], - [false, null], - [false, false], - [true, true], - [null, null] - ]; - } - - public function assertEqualsFailsProvider() - { - $stringException = 'Failed asserting that two strings are equal.'; - $otherException = 'matches expected'; - - return [ - ['string', 'other string', $stringException], - ['string', 'STRING', $stringException], - ['STRING', 'string', $stringException], - ['string', 'other string', $stringException], - // https://github.com/sebastianbergmann/phpunit/issues/1023 - ['9E6666666', '9E7777777', $stringException], - [new ClassWithToString, 'does not match', $otherException], - ['does not match', new ClassWithToString, $otherException], - [0, 'Foobar', $otherException], - ['Foobar', 0, $otherException], - ['10', 25, $otherException], - ['1', false, $otherException], - ['', true, $otherException], - [false, true, $otherException], - [true, false, $otherException], - [null, true, $otherException], - [0, true, $otherException], - ['0', '0.0', $stringException], - ['0.', '0.0', $stringException], - ['0e1', '0e2', $stringException], - ["\n\n\n0.0", ' 0.', $stringException], - ['0.0', '25e-10000', $stringException], - ]; - } - - /** - * @dataProvider acceptsSucceedsProvider - */ - public function testAcceptsSucceeds($expected, $actual): void - { - $this->assertTrue( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual): void - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual, $ignoreCase = false): void - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual, 0.0, false, $ignoreCase); - } catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual, $message): void - { - $this->expectException(ComparisonFailure::class); - $this->expectExceptionMessage($message); - - $this->comparator->assertEquals($expected, $actual); - } -} diff --git a/vendor/sebastian/comparator/tests/SplObjectStorageComparatorTest.php b/vendor/sebastian/comparator/tests/SplObjectStorageComparatorTest.php deleted file mode 100644 index 19cbe716a..000000000 --- a/vendor/sebastian/comparator/tests/SplObjectStorageComparatorTest.php +++ /dev/null @@ -1,145 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Comparator; - -use PHPUnit\Framework\TestCase; -use SplObjectStorage; -use stdClass; - -/** - * @covers \SebastianBergmann\Comparator\SplObjectStorageComparator - * - * @uses \SebastianBergmann\Comparator\Comparator - * @uses \SebastianBergmann\Comparator\Factory - * @uses \SebastianBergmann\Comparator\ComparisonFailure - */ -final class SplObjectStorageComparatorTest extends TestCase -{ - /** - * @var SplObjectStorageComparator - */ - private $comparator; - - protected function setUp(): void - { - $this->comparator = new SplObjectStorageComparator; - } - - public function acceptsFailsProvider() - { - return [ - [new SplObjectStorage, new stdClass], - [new stdClass, new SplObjectStorage], - [new stdClass, new stdClass] - ]; - } - - public function assertEqualsSucceedsProvider() - { - $object1 = new stdClass(); - $object2 = new stdClass(); - - $storage1 = new SplObjectStorage(); - $storage2 = new SplObjectStorage(); - - $storage3 = new SplObjectStorage(); - $storage3->attach($object1); - $storage3->attach($object2); - - $storage4 = new SplObjectStorage(); - $storage4->attach($object2); - $storage4->attach($object1); - - return [ - [$storage1, $storage1], - [$storage1, $storage2], - [$storage3, $storage3], - [$storage3, $storage4] - ]; - } - - public function assertEqualsFailsProvider() - { - $object1 = new stdClass; - $object2 = new stdClass; - - $storage1 = new SplObjectStorage; - - $storage2 = new SplObjectStorage; - $storage2->attach($object1); - - $storage3 = new SplObjectStorage; - $storage3->attach($object2); - $storage3->attach($object1); - - return [ - [$storage1, $storage2], - [$storage1, $storage3], - [$storage2, $storage3], - ]; - } - - public function testAcceptsSucceeds(): void - { - $this->assertTrue( - $this->comparator->accepts( - new SplObjectStorage, - new SplObjectStorage - ) - ); - } - - /** - * @dataProvider acceptsFailsProvider - */ - public function testAcceptsFails($expected, $actual): void - { - $this->assertFalse( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual): void - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual); - } catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual): void - { - $this->expectException(ComparisonFailure::class); - $this->expectExceptionMessage('Failed asserting that two objects are equal.'); - - $this->comparator->assertEquals($expected, $actual); - } - - public function testAssertEqualsFails2(): void - { - $this->expectException(ComparisonFailure::class); - $this->expectExceptionMessage('Failed asserting that two objects are equal.'); - - $t = new SplObjectStorage(); - $t->attach(new \stdClass()); - - $this->comparator->assertEquals($t, new \SplObjectStorage()); - } -} diff --git a/vendor/sebastian/comparator/tests/TypeComparatorTest.php b/vendor/sebastian/comparator/tests/TypeComparatorTest.php deleted file mode 100644 index b8586a5ae..000000000 --- a/vendor/sebastian/comparator/tests/TypeComparatorTest.php +++ /dev/null @@ -1,107 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Comparator; - -use PHPUnit\Framework\TestCase; -use stdClass; - -/** - * @covers \SebastianBergmann\Comparator\TypeComparator - * - * @uses \SebastianBergmann\Comparator\Comparator - * @uses \SebastianBergmann\Comparator\Factory - * @uses \SebastianBergmann\Comparator\ComparisonFailure - */ -final class TypeComparatorTest extends TestCase -{ - /** - * @var TypeComparator - */ - private $comparator; - - protected function setUp(): void - { - $this->comparator = new TypeComparator; - } - - public function acceptsSucceedsProvider() - { - return [ - [true, 1], - [false, [1]], - [null, new stdClass], - [1.0, 5], - ['', ''] - ]; - } - - public function assertEqualsSucceedsProvider() - { - return [ - [true, true], - [true, false], - [false, false], - [null, null], - [new stdClass, new stdClass], - [0, 0], - [1.0, 2.0], - ['hello', 'world'], - ['', ''], - [[], [1, 2, 3]] - ]; - } - - public function assertEqualsFailsProvider() - { - return [ - [true, null], - [null, false], - [1.0, 0], - [new stdClass, []], - ['1', 1] - ]; - } - - /** - * @dataProvider acceptsSucceedsProvider - */ - public function testAcceptsSucceeds($expected, $actual): void - { - $this->assertTrue( - $this->comparator->accepts($expected, $actual) - ); - } - - /** - * @dataProvider assertEqualsSucceedsProvider - */ - public function testAssertEqualsSucceeds($expected, $actual): void - { - $exception = null; - - try { - $this->comparator->assertEquals($expected, $actual); - } catch (ComparisonFailure $exception) { - } - - $this->assertNull($exception, 'Unexpected ComparisonFailure'); - } - - /** - * @dataProvider assertEqualsFailsProvider - */ - public function testAssertEqualsFails($expected, $actual): void - { - $this->expectException(ComparisonFailure::class); - $this->expectExceptionMessage('does not match expected type'); - - $this->comparator->assertEquals($expected, $actual); - } -} diff --git a/vendor/sebastian/comparator/tests/_fixture/Author.php b/vendor/sebastian/comparator/tests/_fixture/Author.php deleted file mode 100644 index efcb6c034..000000000 --- a/vendor/sebastian/comparator/tests/_fixture/Author.php +++ /dev/null @@ -1,26 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Comparator; - -/** - * An author. - */ -class Author -{ - // the order of properties is important for testing the cycle! - public $books = []; - - private $name = ''; - - public function __construct($name) - { - $this->name = $name; - } -} diff --git a/vendor/sebastian/comparator/tests/_fixture/Book.php b/vendor/sebastian/comparator/tests/_fixture/Book.php deleted file mode 100644 index 73a5c1b10..000000000 --- a/vendor/sebastian/comparator/tests/_fixture/Book.php +++ /dev/null @@ -1,19 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Comparator; - -/** - * A book. - */ -class Book -{ - // the order of properties is important for testing the cycle! - public $author; -} diff --git a/vendor/sebastian/comparator/tests/_fixture/ClassWithToString.php b/vendor/sebastian/comparator/tests/_fixture/ClassWithToString.php deleted file mode 100644 index 488e85aef..000000000 --- a/vendor/sebastian/comparator/tests/_fixture/ClassWithToString.php +++ /dev/null @@ -1,18 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Comparator; - -class ClassWithToString -{ - public function __toString() - { - return 'string representation'; - } -} diff --git a/vendor/sebastian/comparator/tests/_fixture/SampleClass.php b/vendor/sebastian/comparator/tests/_fixture/SampleClass.php deleted file mode 100644 index 7e455e8ad..000000000 --- a/vendor/sebastian/comparator/tests/_fixture/SampleClass.php +++ /dev/null @@ -1,29 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Comparator; - -/** - * A sample class. - */ -class SampleClass -{ - public $a; - - protected $b; - - protected $c; - - public function __construct($a, $b, $c) - { - $this->a = $a; - $this->b = $b; - $this->c = $c; - } -} diff --git a/vendor/sebastian/comparator/tests/_fixture/Struct.php b/vendor/sebastian/comparator/tests/_fixture/Struct.php deleted file mode 100644 index 7710de8b3..000000000 --- a/vendor/sebastian/comparator/tests/_fixture/Struct.php +++ /dev/null @@ -1,23 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Comparator; - -/** - * A struct. - */ -class Struct -{ - public $var; - - public function __construct($var) - { - $this->var = $var; - } -} diff --git a/vendor/sebastian/comparator/tests/_fixture/TestClassComparator.php b/vendor/sebastian/comparator/tests/_fixture/TestClassComparator.php deleted file mode 100644 index 014de67db..000000000 --- a/vendor/sebastian/comparator/tests/_fixture/TestClassComparator.php +++ /dev/null @@ -1,14 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Comparator; - -class TestClassComparator extends ObjectComparator -{ -} diff --git a/vendor/sebastian/complexity/.psalm/baseline.xml b/vendor/sebastian/complexity/.psalm/baseline.xml new file mode 100644 index 000000000..77e688e07 --- /dev/null +++ b/vendor/sebastian/complexity/.psalm/baseline.xml @@ -0,0 +1,2 @@ + + diff --git a/vendor/sebastian/complexity/.psalm/config.xml b/vendor/sebastian/complexity/.psalm/config.xml new file mode 100644 index 000000000..8172fe15a --- /dev/null +++ b/vendor/sebastian/complexity/.psalm/config.xml @@ -0,0 +1,16 @@ + + + + + + + + + diff --git a/vendor/sebastian/complexity/ChangeLog.md b/vendor/sebastian/complexity/ChangeLog.md new file mode 100644 index 000000000..cb93ff620 --- /dev/null +++ b/vendor/sebastian/complexity/ChangeLog.md @@ -0,0 +1,30 @@ +# ChangeLog + +All notable changes are documented in this file using the [Keep a CHANGELOG](https://keepachangelog.com/) principles. + +## [2.0.2] - 2020-10-26 + +### Fixed + +* `SebastianBergmann\Complexity\Exception` now correctly extends `\Throwable` + +## [2.0.1] - 2020-09-28 + +### Changed + +* Changed PHP version constraint in `composer.json` from `^7.3 || ^8.0` to `>=7.3` + +## [2.0.0] - 2020-07-25 + +### Removed + +* The `ParentConnectingVisitor` has been removed (it should have been marked as `@internal`) + +## [1.0.0] - 2020-07-22 + +* Initial release + +[2.0.2]: https://github.com/sebastianbergmann/complexity/compare/2.0.1...2.0.2 +[2.0.1]: https://github.com/sebastianbergmann/complexity/compare/2.0.0...2.0.1 +[2.0.0]: https://github.com/sebastianbergmann/complexity/compare/1.0.0...2.0.0 +[1.0.0]: https://github.com/sebastianbergmann/complexity/compare/70ee0ad32d9e2be3f85beffa3e2eb474193f2487...1.0.0 diff --git a/vendor/sebastian/complexity/LICENSE b/vendor/sebastian/complexity/LICENSE new file mode 100644 index 000000000..5f818df69 --- /dev/null +++ b/vendor/sebastian/complexity/LICENSE @@ -0,0 +1,33 @@ +sebastian/complexity + +Copyright (c) 2020, Sebastian Bergmann . +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: + + * Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + * Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in + the documentation and/or other materials provided with the + distribution. + + * Neither the name of Sebastian Bergmann nor the names of his + contributors may be used to endorse or promote products derived + from this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS +FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN +ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +POSSIBILITY OF SUCH DAMAGE. diff --git a/vendor/sebastian/complexity/README.md b/vendor/sebastian/complexity/README.md new file mode 100644 index 000000000..5f53b0b5d --- /dev/null +++ b/vendor/sebastian/complexity/README.md @@ -0,0 +1,22 @@ +# sebastian/complexity + +Library for calculating the complexity of PHP code units. + +[![Latest Stable Version](https://img.shields.io/packagist/v/sebastian/complexity.svg?style=flat-square)](https://packagist.org/packages/sebastian/complexity) +[![Minimum PHP Version](https://img.shields.io/badge/php-%3E%3D%207.3-8892BF.svg?style=flat-square)](https://php.net/) +[![CI Status](https://github.com/sebastianbergmann/complexity/workflows/CI/badge.svg?branch=master&event=push)](https://phpunit.de/build-status.html) +[![Type Coverage](https://shepherd.dev/github/sebastianbergmann/complexity/coverage.svg)](https://shepherd.dev/github/sebastianbergmann/complexity) + +## Installation + +You can add this library as a local, per-project dependency to your project using [Composer](https://getcomposer.org/): + +``` +composer require sebastian/complexity +``` + +If you only need this library during development, for instance to run your project's test suite, then you should add it as a development-time dependency: + +``` +composer require --dev sebastian/complexity +``` diff --git a/vendor/sebastian/complexity/composer.json b/vendor/sebastian/complexity/composer.json new file mode 100644 index 000000000..7aa38314e --- /dev/null +++ b/vendor/sebastian/complexity/composer.json @@ -0,0 +1,41 @@ +{ + "name": "sebastian/complexity", + "description": "Library for calculating the complexity of PHP code units", + "type": "library", + "homepage": "https://github.com/sebastianbergmann/complexity", + "license": "BSD-3-Clause", + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "support": { + "issues": "https://github.com/sebastianbergmann/complexity/issues" + }, + "require": { + "php": ">=7.3", + "nikic/php-parser": "^4.7" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "config": { + "platform": { + "php": "7.3.0" + }, + "optimize-autoloader": true, + "sort-packages": true + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" + } + } +} diff --git a/vendor/sebastian/complexity/src/Calculator.php b/vendor/sebastian/complexity/src/Calculator.php new file mode 100644 index 000000000..9abdcd169 --- /dev/null +++ b/vendor/sebastian/complexity/src/Calculator.php @@ -0,0 +1,88 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\Complexity; + +use PhpParser\Error; +use PhpParser\Lexer; +use PhpParser\Node; +use PhpParser\NodeTraverser; +use PhpParser\NodeVisitor\NameResolver; +use PhpParser\NodeVisitor\ParentConnectingVisitor; +use PhpParser\Parser; +use PhpParser\ParserFactory; + +final class Calculator +{ + /** + * @throws RuntimeException + */ + public function calculateForSourceFile(string $sourceFile): ComplexityCollection + { + return $this->calculateForSourceString(file_get_contents($sourceFile)); + } + + /** + * @throws RuntimeException + */ + public function calculateForSourceString(string $source): ComplexityCollection + { + try { + $nodes = $this->parser()->parse($source); + + assert($nodes !== null); + + return $this->calculateForAbstractSyntaxTree($nodes); + + // @codeCoverageIgnoreStart + } catch (Error $error) { + throw new RuntimeException( + $error->getMessage(), + (int) $error->getCode(), + $error + ); + } + // @codeCoverageIgnoreEnd + } + + /** + * @param Node[] $nodes + * + * @throws RuntimeException + */ + public function calculateForAbstractSyntaxTree(array $nodes): ComplexityCollection + { + $traverser = new NodeTraverser; + $complexityCalculatingVisitor = new ComplexityCalculatingVisitor(true); + + $traverser->addVisitor(new NameResolver); + $traverser->addVisitor(new ParentConnectingVisitor); + $traverser->addVisitor($complexityCalculatingVisitor); + + try { + /* @noinspection UnusedFunctionResultInspection */ + $traverser->traverse($nodes); + // @codeCoverageIgnoreStart + } catch (Error $error) { + throw new RuntimeException( + $error->getMessage(), + (int) $error->getCode(), + $error + ); + } + // @codeCoverageIgnoreEnd + + return $complexityCalculatingVisitor->result(); + } + + private function parser(): Parser + { + return (new ParserFactory)->create(ParserFactory::PREFER_PHP7, new Lexer); + } +} diff --git a/vendor/sebastian/complexity/src/Complexity/Complexity.php b/vendor/sebastian/complexity/src/Complexity/Complexity.php new file mode 100644 index 000000000..dc6708dde --- /dev/null +++ b/vendor/sebastian/complexity/src/Complexity/Complexity.php @@ -0,0 +1,42 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\Complexity; + +/** + * @psalm-immutable + */ +final class Complexity +{ + /** + * @var string + */ + private $name; + + /** + * @var int + */ + private $cyclomaticComplexity; + + public function __construct(string $name, int $cyclomaticComplexity) + { + $this->name = $name; + $this->cyclomaticComplexity = $cyclomaticComplexity; + } + + public function name(): string + { + return $this->name; + } + + public function cyclomaticComplexity(): int + { + return $this->cyclomaticComplexity; + } +} diff --git a/vendor/sebastian/complexity/src/Complexity/ComplexityCollection.php b/vendor/sebastian/complexity/src/Complexity/ComplexityCollection.php new file mode 100644 index 000000000..ccbddbf77 --- /dev/null +++ b/vendor/sebastian/complexity/src/Complexity/ComplexityCollection.php @@ -0,0 +1,72 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\Complexity; + +use function count; +use Countable; +use IteratorAggregate; + +/** + * @psalm-immutable + */ +final class ComplexityCollection implements Countable, IteratorAggregate +{ + /** + * @psalm-var list + */ + private $items = []; + + public static function fromList(Complexity ...$items): self + { + return new self($items); + } + + /** + * @psalm-param list $items + */ + private function __construct(array $items) + { + $this->items = $items; + } + + /** + * @psalm-return list + */ + public function asArray(): array + { + return $this->items; + } + + public function getIterator(): ComplexityCollectionIterator + { + return new ComplexityCollectionIterator($this); + } + + public function count(): int + { + return count($this->items); + } + + public function isEmpty(): bool + { + return empty($this->items); + } + + public function cyclomaticComplexity(): int + { + $cyclomaticComplexity = 0; + + foreach ($this as $item) { + $cyclomaticComplexity += $item->cyclomaticComplexity(); + } + + return $cyclomaticComplexity; + } +} diff --git a/vendor/sebastian/complexity/src/Complexity/ComplexityCollectionIterator.php b/vendor/sebastian/complexity/src/Complexity/ComplexityCollectionIterator.php new file mode 100644 index 000000000..ec39e199f --- /dev/null +++ b/vendor/sebastian/complexity/src/Complexity/ComplexityCollectionIterator.php @@ -0,0 +1,55 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\Complexity; + +use Iterator; + +final class ComplexityCollectionIterator implements Iterator +{ + /** + * @psalm-var list + */ + private $items; + + /** + * @var int + */ + private $position = 0; + + public function __construct(ComplexityCollection $items) + { + $this->items = $items->asArray(); + } + + public function rewind(): void + { + $this->position = 0; + } + + public function valid(): bool + { + return isset($this->items[$this->position]); + } + + public function key(): int + { + return $this->position; + } + + public function current(): Complexity + { + return $this->items[$this->position]; + } + + public function next(): void + { + $this->position++; + } +} diff --git a/vendor/sebastian/complexity/src/Exception/Exception.php b/vendor/sebastian/complexity/src/Exception/Exception.php new file mode 100644 index 000000000..897ecdcf7 --- /dev/null +++ b/vendor/sebastian/complexity/src/Exception/Exception.php @@ -0,0 +1,16 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\Complexity; + +use Throwable; + +interface Exception extends Throwable +{ +} diff --git a/vendor/sebastian/global-state/tests/_fixture/BlacklistedChildClass.php b/vendor/sebastian/complexity/src/Exception/RuntimeException.php similarity index 58% rename from vendor/sebastian/global-state/tests/_fixture/BlacklistedChildClass.php rename to vendor/sebastian/complexity/src/Exception/RuntimeException.php index 585c39660..6c68a6f0f 100644 --- a/vendor/sebastian/global-state/tests/_fixture/BlacklistedChildClass.php +++ b/vendor/sebastian/complexity/src/Exception/RuntimeException.php @@ -1,14 +1,14 @@ * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ -namespace SebastianBergmann\GlobalState\TestFixture; +namespace SebastianBergmann\Complexity; -class BlacklistedChildClass extends BlacklistedClass +final class RuntimeException extends \RuntimeException implements Exception { } diff --git a/vendor/sebastian/complexity/src/Visitor/ComplexityCalculatingVisitor.php b/vendor/sebastian/complexity/src/Visitor/ComplexityCalculatingVisitor.php new file mode 100644 index 000000000..b69f2b09f --- /dev/null +++ b/vendor/sebastian/complexity/src/Visitor/ComplexityCalculatingVisitor.php @@ -0,0 +1,109 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\Complexity; + +use function assert; +use function is_array; +use PhpParser\Node; +use PhpParser\Node\Name; +use PhpParser\Node\Stmt; +use PhpParser\Node\Stmt\Class_; +use PhpParser\Node\Stmt\ClassMethod; +use PhpParser\Node\Stmt\Function_; +use PhpParser\Node\Stmt\Trait_; +use PhpParser\NodeTraverser; +use PhpParser\NodeVisitorAbstract; + +final class ComplexityCalculatingVisitor extends NodeVisitorAbstract +{ + /** + * @psalm-var list + */ + private $result = []; + + /** + * @var bool + */ + private $shortCircuitTraversal; + + public function __construct(bool $shortCircuitTraversal) + { + $this->shortCircuitTraversal = $shortCircuitTraversal; + } + + public function enterNode(Node $node): ?int + { + if (!$node instanceof ClassMethod && !$node instanceof Function_) { + return null; + } + + if ($node instanceof ClassMethod) { + $name = $this->classMethodName($node); + } else { + $name = $this->functionName($node); + } + + $statements = $node->getStmts(); + + assert(is_array($statements)); + + $this->result[] = new Complexity( + $name, + $this->cyclomaticComplexity($statements) + ); + + if ($this->shortCircuitTraversal) { + return NodeTraverser::DONT_TRAVERSE_CHILDREN; + } + + return null; + } + + public function result(): ComplexityCollection + { + return ComplexityCollection::fromList(...$this->result); + } + + /** + * @param Stmt[] $statements + */ + private function cyclomaticComplexity(array $statements): int + { + $traverser = new NodeTraverser; + + $cyclomaticComplexityCalculatingVisitor = new CyclomaticComplexityCalculatingVisitor; + + $traverser->addVisitor($cyclomaticComplexityCalculatingVisitor); + + /* @noinspection UnusedFunctionResultInspection */ + $traverser->traverse($statements); + + return $cyclomaticComplexityCalculatingVisitor->cyclomaticComplexity(); + } + + private function classMethodName(ClassMethod $node): string + { + $parent = $node->getAttribute('parent'); + + assert($parent instanceof Class_ || $parent instanceof Trait_); + assert(isset($parent->namespacedName)); + assert($parent->namespacedName instanceof Name); + + return $parent->namespacedName->toString() . '::' . $node->name->toString(); + } + + private function functionName(Function_ $node): string + { + assert(isset($node->namespacedName)); + assert($node->namespacedName instanceof Name); + + return $node->namespacedName->toString(); + } +} diff --git a/vendor/sebastian/complexity/src/Visitor/CyclomaticComplexityCalculatingVisitor.php b/vendor/sebastian/complexity/src/Visitor/CyclomaticComplexityCalculatingVisitor.php new file mode 100644 index 000000000..d4430876d --- /dev/null +++ b/vendor/sebastian/complexity/src/Visitor/CyclomaticComplexityCalculatingVisitor.php @@ -0,0 +1,59 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\Complexity; + +use function get_class; +use PhpParser\Node; +use PhpParser\Node\Expr\BinaryOp\BooleanAnd; +use PhpParser\Node\Expr\BinaryOp\BooleanOr; +use PhpParser\Node\Expr\BinaryOp\LogicalAnd; +use PhpParser\Node\Expr\BinaryOp\LogicalOr; +use PhpParser\Node\Expr\Ternary; +use PhpParser\Node\Stmt\Case_; +use PhpParser\Node\Stmt\Catch_; +use PhpParser\Node\Stmt\ElseIf_; +use PhpParser\Node\Stmt\For_; +use PhpParser\Node\Stmt\Foreach_; +use PhpParser\Node\Stmt\If_; +use PhpParser\Node\Stmt\While_; +use PhpParser\NodeVisitorAbstract; + +final class CyclomaticComplexityCalculatingVisitor extends NodeVisitorAbstract +{ + /** + * @var int + */ + private $cyclomaticComplexity = 1; + + public function enterNode(Node $node): void + { + /* @noinspection GetClassMissUseInspection */ + switch (get_class($node)) { + case BooleanAnd::class: + case BooleanOr::class: + case Case_::class: + case Catch_::class: + case ElseIf_::class: + case For_::class: + case Foreach_::class: + case If_::class: + case LogicalAnd::class: + case LogicalOr::class: + case Ternary::class: + case While_::class: + $this->cyclomaticComplexity++; + } + } + + public function cyclomaticComplexity(): int + { + return $this->cyclomaticComplexity; + } +} diff --git a/vendor/sebastian/diff/.github/stale.yml b/vendor/sebastian/diff/.github/stale.yml deleted file mode 100644 index 1c523ab30..000000000 --- a/vendor/sebastian/diff/.github/stale.yml +++ /dev/null @@ -1,40 +0,0 @@ -# Configuration for probot-stale - https://github.com/probot/stale - -# Number of days of inactivity before an Issue or Pull Request becomes stale -daysUntilStale: 60 - -# Number of days of inactivity before a stale Issue or Pull Request is closed. -# Set to false to disable. If disabled, issues still need to be closed manually, but will remain marked as stale. -daysUntilClose: 7 - -# Issues or Pull Requests with these labels will never be considered stale. Set to `[]` to disable -exemptLabels: - - enhancement - -# Set to true to ignore issues in a project (defaults to false) -exemptProjects: false - -# Set to true to ignore issues in a milestone (defaults to false) -exemptMilestones: false - -# Label to use when marking as stale -staleLabel: wontfix - -# Comment to post when marking as stale. Set to `false` to disable -markComment: > - This issue has been automatically marked as stale because it has not had activity within the last 60 days. It will be closed after 7 days if no further activity occurs. Thank you for your contributions. - -# Comment to post when removing the stale label. -# unmarkComment: > -# Your comment here. - -# Comment to post when closing a stale Issue or Pull Request. -closeComment: > - This issue has been automatically closed because it has not had activity since it was marked as stale. Thank you for your contributions. - -# Limit the number of actions per hour, from 1-30. Default is 30 -limitPerRun: 30 - -# Limit to only `issues` or `pulls` -only: issues - diff --git a/vendor/sebastian/diff/.gitignore b/vendor/sebastian/diff/.gitignore deleted file mode 100644 index 35dc21185..000000000 --- a/vendor/sebastian/diff/.gitignore +++ /dev/null @@ -1,6 +0,0 @@ -/.idea -/composer.lock -/vendor -/.php_cs.cache -/.phpunit.result.cache -/from.txt.orig \ No newline at end of file diff --git a/vendor/sebastian/diff/.php_cs.dist b/vendor/sebastian/diff/.php_cs.dist deleted file mode 100644 index 921460756..000000000 --- a/vendor/sebastian/diff/.php_cs.dist +++ /dev/null @@ -1,168 +0,0 @@ - - -For the full copyright and license information, please view the LICENSE -file that was distributed with this source code. -EOF; - -return PhpCsFixer\Config::create() - ->setRiskyAllowed(true) - ->setRules( - [ - 'array_syntax' => ['syntax' => 'short'], - 'binary_operator_spaces' => [ - 'operators' => [ - '=' => 'align', - '=>' => 'align', - ], - ], - 'blank_line_after_namespace' => true, - 'blank_line_before_statement' => [ - 'statements' => [ - 'break', - 'continue', - 'declare', - 'do', - 'for', - 'foreach', - 'if', - 'include', - 'include_once', - 'require', - 'require_once', - 'return', - 'switch', - 'throw', - 'try', - 'while', - 'yield', - ], - ], - 'braces' => true, - 'cast_spaces' => true, - 'class_attributes_separation' => ['elements' => ['method']], - 'compact_nullable_typehint' => true, - 'concat_space' => ['spacing' => 'one'], - 'declare_equal_normalize' => ['space' => 'none'], - 'declare_strict_types' => true, - 'dir_constant' => true, - 'elseif' => true, - 'encoding' => true, - 'full_opening_tag' => true, - 'function_declaration' => true, - 'header_comment' => ['header' => $header, 'separate' => 'none'], - 'indentation_type' => true, - 'line_ending' => true, - 'list_syntax' => ['syntax' => 'short'], - 'lowercase_cast' => true, - 'lowercase_constants' => true, - 'lowercase_keywords' => true, - 'magic_constant_casing' => true, - 'method_argument_space' => ['ensure_fully_multiline' => true], - 'modernize_types_casting' => true, - 'native_function_casing' => true, - 'native_function_invocation' => true, - 'no_alias_functions' => true, - 'no_blank_lines_after_class_opening' => true, - 'no_blank_lines_after_phpdoc' => true, - 'no_closing_tag' => true, - 'no_empty_comment' => true, - 'no_empty_phpdoc' => true, - 'no_empty_statement' => true, - 'no_extra_blank_lines' => true, - 'no_homoglyph_names' => true, - 'no_leading_import_slash' => true, - 'no_leading_namespace_whitespace' => true, - 'no_mixed_echo_print' => ['use' => 'print'], - 'no_null_property_initialization' => true, - 'no_short_bool_cast' => true, - 'no_short_echo_tag' => true, - 'no_singleline_whitespace_before_semicolons' => true, - 'no_spaces_after_function_name' => true, - 'no_spaces_inside_parenthesis' => true, - 'no_superfluous_elseif' => true, - 'no_trailing_comma_in_list_call' => true, - 'no_trailing_comma_in_singleline_array' => true, - 'no_trailing_whitespace' => true, - 'no_trailing_whitespace_in_comment' => true, - 'no_unneeded_control_parentheses' => true, - 'no_unneeded_curly_braces' => true, - 'no_unneeded_final_method' => true, - 'no_unreachable_default_argument_value' => true, - 'no_unused_imports' => true, - 'no_useless_else' => true, - 'no_whitespace_before_comma_in_array' => true, - 'no_whitespace_in_blank_line' => true, - 'non_printable_character' => true, - 'normalize_index_brace' => true, - 'object_operator_without_whitespace' => true, - 'ordered_class_elements' => [ - 'order' => [ - 'use_trait', - 'constant_public', - 'constant_protected', - 'constant_private', - 'property_public_static', - 'property_protected_static', - 'property_private_static', - 'property_public', - 'property_protected', - 'property_private', - 'method_public_static', - 'construct', - 'destruct', - 'magic', - 'phpunit', - 'method_public', - 'method_protected', - 'method_private', - 'method_protected_static', - 'method_private_static', - ], - ], - 'ordered_imports' => true, - 'phpdoc_add_missing_param_annotation' => true, - 'phpdoc_align' => true, - 'phpdoc_annotation_without_dot' => true, - 'phpdoc_indent' => true, - 'phpdoc_no_access' => true, - 'phpdoc_no_empty_return' => true, - 'phpdoc_no_package' => true, - 'phpdoc_order' => true, - 'phpdoc_return_self_reference' => true, - 'phpdoc_scalar' => true, - 'phpdoc_separation' => true, - 'phpdoc_single_line_var_spacing' => true, - 'phpdoc_to_comment' => true, - 'phpdoc_trim' => true, - 'phpdoc_types' => true, - 'phpdoc_types_order' => true, - 'phpdoc_var_without_name' => true, - 'pow_to_exponentiation' => true, - 'protected_to_private' => true, - 'return_type_declaration' => ['space_before' => 'none'], - 'self_accessor' => true, - 'short_scalar_cast' => true, - 'simplified_null_return' => true, - 'single_blank_line_at_eof' => true, - 'single_import_per_statement' => true, - 'single_line_after_imports' => true, - 'single_quote' => true, - 'standardize_not_equals' => true, - 'ternary_to_null_coalescing' => true, - 'trim_array_spaces' => true, - 'unary_operator_spaces' => true, - 'visibility_required' => true, - 'void_return' => true, - 'whitespace_after_comma_in_array' => true, - ] - ) - ->setFinder( - PhpCsFixer\Finder::create() - ->files() - ->in(__DIR__ . '/src') - ->in(__DIR__ . '/tests') - ); diff --git a/vendor/sebastian/diff/.travis.yml b/vendor/sebastian/diff/.travis.yml deleted file mode 100644 index 13cd9ff83..000000000 --- a/vendor/sebastian/diff/.travis.yml +++ /dev/null @@ -1,26 +0,0 @@ -language: php - -php: - - 7.1 - - 7.2 - - 7.3 - - master - -sudo: false - -before_install: - - composer self-update - - composer clear-cache - -install: - - travis_retry composer update --no-interaction --no-ansi --no-progress --no-suggest --optimize-autoloader --prefer-stable - -script: - - ./vendor/bin/phpunit --coverage-clover=coverage.xml - -after_success: - - bash <(curl -s https://codecov.io/bash) - -notifications: - email: false - diff --git a/vendor/sebastian/diff/ChangeLog.md b/vendor/sebastian/diff/ChangeLog.md index 88332f7da..9bdcc5b6d 100644 --- a/vendor/sebastian/diff/ChangeLog.md +++ b/vendor/sebastian/diff/ChangeLog.md @@ -2,11 +2,35 @@ All notable changes are documented in this file using the [Keep a CHANGELOG](http://keepachangelog.com/) principles. -## [3.0.3] - 2020-11-30 +## [4.0.4] - 2020-10-26 + +### Fixed + +* `SebastianBergmann\Diff\Exception` now correctly extends `\Throwable` + +## [4.0.3] - 2020-09-28 ### Changed -* Changed PHP version constraint in `composer.json` from `^7.1` to `>=7.1` +* Changed PHP version constraint in `composer.json` from `^7.3 || ^8.0` to `>=7.3` + +## [4.0.2] - 2020-06-30 + +### Added + +* This component is now supported on PHP 8 + +## [4.0.1] - 2020-05-08 + +### Fixed + +* [#99](https://github.com/sebastianbergmann/diff/pull/99): Regression in unified diff output of identical strings + +## [4.0.0] - 2020-02-07 + +### Removed + +* Removed support for PHP 7.1 and PHP 7.2 ## [3.0.2] - 2019-02-04 @@ -34,25 +58,29 @@ All notable changes are documented in this file using the [Keep a CHANGELOG](htt ### Fixed -* Fixed [#70](https://github.com/sebastianbergmann/diff/issues/70): Diffing of arrays no longer works +* [#70](https://github.com/sebastianbergmann/diff/issues/70): Diffing of arrays no longer works ## [2.0.1] - 2017-08-03 ### Fixed -* Fixed [#66](https://github.com/sebastianbergmann/diff/pull/66): Restored backwards compatibility for PHPUnit 6.1.4, 6.2.0, 6.2.1, 6.2.2, and 6.2.3 +* [#66](https://github.com/sebastianbergmann/diff/pull/66): Restored backwards compatibility for PHPUnit 6.1.4, 6.2.0, 6.2.1, 6.2.2, and 6.2.3 ## [2.0.0] - 2017-07-11 [YANKED] ### Added -* Implemented [#64](https://github.com/sebastianbergmann/diff/pull/64): Show line numbers for chunks of a diff +* [#64](https://github.com/sebastianbergmann/diff/pull/64): Show line numbers for chunks of a diff ### Removed * This component is no longer supported on PHP 5.6 -[3.0.3]: https://github.com/sebastianbergmann/diff/compare/3.0.2...3.0.3 +[4.0.4]: https://github.com/sebastianbergmann/diff/compare/4.0.3...4.0.4 +[4.0.3]: https://github.com/sebastianbergmann/diff/compare/4.0.2...4.0.3 +[4.0.2]: https://github.com/sebastianbergmann/diff/compare/4.0.1...4.0.2 +[4.0.1]: https://github.com/sebastianbergmann/diff/compare/4.0.0...4.0.1 +[4.0.0]: https://github.com/sebastianbergmann/diff/compare/3.0.2...4.0.0 [3.0.2]: https://github.com/sebastianbergmann/diff/compare/3.0.1...3.0.2 [3.0.1]: https://github.com/sebastianbergmann/diff/compare/3.0.0...3.0.1 [3.0.0]: https://github.com/sebastianbergmann/diff/compare/2.0...3.0.0 diff --git a/vendor/sebastian/diff/LICENSE b/vendor/sebastian/diff/LICENSE index 3ad1d7c3c..f22f31cf0 100644 --- a/vendor/sebastian/diff/LICENSE +++ b/vendor/sebastian/diff/LICENSE @@ -1,6 +1,6 @@ sebastian/diff -Copyright (c) 2002-2019, Sebastian Bergmann . +Copyright (c) 2002-2020, Sebastian Bergmann . All rights reserved. Redistribution and use in source and binary forms, with or without diff --git a/vendor/sebastian/diff/README.md b/vendor/sebastian/diff/README.md index 78dbecd5d..734b852de 100644 --- a/vendor/sebastian/diff/README.md +++ b/vendor/sebastian/diff/README.md @@ -1,16 +1,23 @@ # sebastian/diff +[![CI Status](https://github.com/sebastianbergmann/diff/workflows/CI/badge.svg)](https://github.com/sebastianbergmann/diff/actions) +[![Type Coverage](https://shepherd.dev/github/sebastianbergmann/diff/coverage.svg)](https://shepherd.dev/github/sebastianbergmann/diff) + Diff implementation for PHP, factored out of PHPUnit into a stand-alone component. ## Installation You can add this library as a local, per-project dependency to your project using [Composer](https://getcomposer.org/): - composer require sebastian/diff +``` +composer require sebastian/diff +``` If you only need this library during development, for instance to run your project's test suite, then you should add it as a development-time dependency: - composer require --dev sebastian/diff +``` +composer require --dev sebastian/diff +``` ### Usage @@ -37,7 +44,7 @@ The code above yields the output below: There are three output builders available in this package: -#### UnifiedDiffOutputBuilder +#### UnifiedDiffOutputBuilder This is default builder, which generates the output close to udiff and is used by PHPUnit. @@ -101,7 +108,7 @@ print $differ->diff('foo', 'bar'); #### DiffOutputBuilderInterface -You can pass any output builder to the `Differ` class as longs as it implements the `DiffOutputBuilderInterface`. +You can pass any output builder to the `Differ` class as longs as it implements the `DiffOutputBuilderInterface`. #### Parsing diff diff --git a/vendor/sebastian/diff/build.xml b/vendor/sebastian/diff/build.xml deleted file mode 100644 index fa7b7e2b9..000000000 --- a/vendor/sebastian/diff/build.xml +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - diff --git a/vendor/sebastian/diff/composer.json b/vendor/sebastian/diff/composer.json index fe2d77fe3..cf92202ba 100644 --- a/vendor/sebastian/diff/composer.json +++ b/vendor/sebastian/diff/composer.json @@ -14,12 +14,20 @@ "email": "mail@kore-nordmann.de" } ], + "prefer-stable": true, + "config": { + "platform": { + "php": "7.3.0" + }, + "optimize-autoloader": true, + "sort-packages": true + }, "require": { - "php": ">=7.1" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^7.5 || ^8.0", - "symfony/process": "^2 || ^3.3 || ^4" + "phpunit/phpunit": "^9.3", + "symfony/process": "^4.2 || ^5" }, "autoload": { "classmap": [ @@ -33,7 +41,7 @@ }, "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "4.0-dev" } } } diff --git a/vendor/sebastian/diff/phpunit.xml b/vendor/sebastian/diff/phpunit.xml deleted file mode 100644 index 3e12be416..000000000 --- a/vendor/sebastian/diff/phpunit.xml +++ /dev/null @@ -1,21 +0,0 @@ - - - - - tests - - - - - - src - - - diff --git a/vendor/sebastian/diff/src/Chunk.php b/vendor/sebastian/diff/src/Chunk.php index d030954ab..16ae34f41 100644 --- a/vendor/sebastian/diff/src/Chunk.php +++ b/vendor/sebastian/diff/src/Chunk.php @@ -7,7 +7,6 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\Diff; final class Chunk diff --git a/vendor/sebastian/diff/src/Diff.php b/vendor/sebastian/diff/src/Diff.php index 3029e5915..17b2084f9 100644 --- a/vendor/sebastian/diff/src/Diff.php +++ b/vendor/sebastian/diff/src/Diff.php @@ -7,7 +7,6 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\Diff; final class Diff @@ -28,8 +27,6 @@ final class Diff private $chunks; /** - * @param string $from - * @param string $to * @param Chunk[] $chunks */ public function __construct(string $from, string $to, array $chunks = []) diff --git a/vendor/sebastian/diff/src/Differ.php b/vendor/sebastian/diff/src/Differ.php index 3c90a5a13..5a4d9d102 100644 --- a/vendor/sebastian/diff/src/Differ.php +++ b/vendor/sebastian/diff/src/Differ.php @@ -7,21 +7,42 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\Diff; +use const PHP_INT_SIZE; +use const PREG_SPLIT_DELIM_CAPTURE; +use const PREG_SPLIT_NO_EMPTY; +use function array_shift; +use function array_unshift; +use function array_values; +use function count; +use function current; +use function end; +use function get_class; +use function gettype; +use function is_array; +use function is_object; +use function is_string; +use function key; +use function min; +use function preg_split; +use function prev; +use function reset; +use function sprintf; +use function substr; use SebastianBergmann\Diff\Output\DiffOutputBuilderInterface; use SebastianBergmann\Diff\Output\UnifiedDiffOutputBuilder; -/** - * Diff implementation. - */ final class Differ { public const OLD = 0; + public const ADDED = 1; + public const REMOVED = 2; + public const DIFF_LINE_END_WARNING = 3; + public const NO_LINE_END_EOF_WARNING = 4; /** @@ -40,16 +61,16 @@ final class Differ $this->outputBuilder = $outputBuilder; } elseif (null === $outputBuilder) { $this->outputBuilder = new UnifiedDiffOutputBuilder; - } elseif (\is_string($outputBuilder)) { + } elseif (is_string($outputBuilder)) { // PHPUnit 6.1.4, 6.2.0, 6.2.1, 6.2.2, and 6.2.3 support // @see https://github.com/sebastianbergmann/phpunit/issues/2734#issuecomment-314514056 // @deprecated $this->outputBuilder = new UnifiedDiffOutputBuilder($outputBuilder); } else { throw new InvalidArgumentException( - \sprintf( + sprintf( 'Expected builder to be an instance of DiffOutputBuilderInterface, or a string, got %s.', - \is_object($outputBuilder) ? 'instance of "' . \get_class($outputBuilder) . '"' : \gettype($outputBuilder) . ' "' . $outputBuilder . '"' + is_object($outputBuilder) ? 'instance of "' . get_class($outputBuilder) . '"' : gettype($outputBuilder) . ' "' . $outputBuilder . '"' ) ); } @@ -58,11 +79,8 @@ final class Differ /** * Returns the diff between two arrays or strings as string. * - * @param array|string $from - * @param array|string $to - * @param null|LongestCommonSubsequenceCalculator $lcs - * - * @return string + * @param array|string $from + * @param array|string $to */ public function diff($from, $to, LongestCommonSubsequenceCalculator $lcs = null): string { @@ -89,20 +107,18 @@ final class Differ * @param array|string $from * @param array|string $to * @param LongestCommonSubsequenceCalculator $lcs - * - * @return array */ public function diffToArray($from, $to, LongestCommonSubsequenceCalculator $lcs = null): array { - if (\is_string($from)) { + if (is_string($from)) { $from = $this->splitStringByLines($from); - } elseif (!\is_array($from)) { + } elseif (!is_array($from)) { throw new InvalidArgumentException('"from" must be an array or string.'); } - if (\is_string($to)) { + if (is_string($to)) { $to = $this->splitStringByLines($to); - } elseif (!\is_array($to)) { + } elseif (!is_array($to)) { throw new InvalidArgumentException('"to" must be an array or string.'); } @@ -112,36 +128,36 @@ final class Differ $lcs = $this->selectLcsImplementation($from, $to); } - $common = $lcs->calculate(\array_values($from), \array_values($to)); + $common = $lcs->calculate(array_values($from), array_values($to)); $diff = []; foreach ($start as $token) { $diff[] = [$token, self::OLD]; } - \reset($from); - \reset($to); + reset($from); + reset($to); foreach ($common as $token) { - while (($fromToken = \reset($from)) !== $token) { - $diff[] = [\array_shift($from), self::REMOVED]; + while (($fromToken = reset($from)) !== $token) { + $diff[] = [array_shift($from), self::REMOVED]; } - while (($toToken = \reset($to)) !== $token) { - $diff[] = [\array_shift($to), self::ADDED]; + while (($toToken = reset($to)) !== $token) { + $diff[] = [array_shift($to), self::ADDED]; } $diff[] = [$token, self::OLD]; - \array_shift($from); - \array_shift($to); + array_shift($from); + array_shift($to); } - while (($token = \array_shift($from)) !== null) { + while (($token = array_shift($from)) !== null) { $diff[] = [$token, self::REMOVED]; } - while (($token = \array_shift($to)) !== null) { + while (($token = array_shift($to)) !== null) { $diff[] = [$token, self::ADDED]; } @@ -150,7 +166,7 @@ final class Differ } if ($this->detectUnmatchedLineEndings($diff)) { - \array_unshift($diff, ["#Warning: Strings contain different line endings!\n", self::DIFF_LINE_END_WARNING]); + array_unshift($diff, ["#Warning: Strings contain different line endings!\n", self::DIFF_LINE_END_WARNING]); } return $diff; @@ -159,13 +175,11 @@ final class Differ /** * Casts variable to string if it is not a string or array. * - * @param mixed $input - * * @return array|string */ private function normalizeDiffInput($input) { - if (!\is_array($input) && !\is_string($input)) { + if (!is_array($input) && !is_string($input)) { return (string) $input; } @@ -174,22 +188,12 @@ final class Differ /** * Checks if input is string, if so it will split it line-by-line. - * - * @param string $input - * - * @return array */ private function splitStringByLines(string $input): array { - return \preg_split('/(.*\R)/', $input, -1, PREG_SPLIT_DELIM_CAPTURE | PREG_SPLIT_NO_EMPTY); + return preg_split('/(.*\R)/', $input, -1, PREG_SPLIT_DELIM_CAPTURE | PREG_SPLIT_NO_EMPTY); } - /** - * @param array $from - * @param array $to - * - * @return LongestCommonSubsequenceCalculator - */ private function selectLcsImplementation(array $from, array $to): LongestCommonSubsequenceCalculator { // We do not want to use the time-efficient implementation if its memory @@ -208,24 +212,17 @@ final class Differ /** * Calculates the estimated memory footprint for the DP-based method. * - * @param array $from - * @param array $to - * * @return float|int */ private function calculateEstimatedFootprint(array $from, array $to) { $itemSize = PHP_INT_SIZE === 4 ? 76 : 144; - return $itemSize * \min(\count($from), \count($to)) ** 2; + return $itemSize * min(count($from), count($to)) ** 2; } /** * Returns true if line ends don't match in a diff. - * - * @param array $diff - * - * @return bool */ private function detectUnmatchedLineEndings(array $diff): bool { @@ -267,11 +264,11 @@ final class Differ private function getLinebreak($line): string { - if (!\is_string($line)) { + if (!is_string($line)) { return ''; } - $lc = \substr($line, -1); + $lc = substr($line, -1); if ("\r" === $lc) { return "\r"; @@ -281,7 +278,7 @@ final class Differ return ''; } - if ("\r\n" === \substr($line, -2)) { + if ("\r\n" === substr($line, -2)) { return "\r\n"; } @@ -293,10 +290,10 @@ final class Differ $start = []; $end = []; - \reset($to); + reset($to); foreach ($from as $k => $v) { - $toK = \key($to); + $toK = key($to); if ($toK === $k && $v === $to[$k]) { $start[$k] = $v; @@ -307,19 +304,19 @@ final class Differ } } - \end($from); - \end($to); + end($from); + end($to); do { - $fromK = \key($from); - $toK = \key($to); + $fromK = key($from); + $toK = key($to); - if (null === $fromK || null === $toK || \current($from) !== \current($to)) { + if (null === $fromK || null === $toK || current($from) !== current($to)) { break; } - \prev($from); - \prev($to); + prev($from); + prev($to); $end = [$fromK => $from[$fromK]] + $end; unset($from[$fromK], $to[$toK]); diff --git a/vendor/sebastian/diff/src/Exception/ConfigurationException.php b/vendor/sebastian/diff/src/Exception/ConfigurationException.php index 78f16fde4..b767b2194 100644 --- a/vendor/sebastian/diff/src/Exception/ConfigurationException.php +++ b/vendor/sebastian/diff/src/Exception/ConfigurationException.php @@ -7,31 +7,29 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\Diff; +use function get_class; +use function gettype; +use function is_object; +use function sprintf; +use Exception; + final class ConfigurationException extends InvalidArgumentException { - /** - * @param string $option - * @param string $expected - * @param mixed $value - * @param int $code - * @param null|\Exception $previous - */ public function __construct( string $option, string $expected, $value, int $code = 0, - \Exception $previous = null + Exception $previous = null ) { parent::__construct( - \sprintf( + sprintf( 'Option "%s" must be %s, got "%s".', $option, $expected, - \is_object($value) ? \get_class($value) : (null === $value ? '' : \gettype($value) . '#' . $value) + is_object($value) ? get_class($value) : (null === $value ? '' : gettype($value) . '#' . $value) ), $code, $previous diff --git a/vendor/sebastian/diff/src/Exception/Exception.php b/vendor/sebastian/diff/src/Exception/Exception.php index 249a2ba01..e20d32036 100644 --- a/vendor/sebastian/diff/src/Exception/Exception.php +++ b/vendor/sebastian/diff/src/Exception/Exception.php @@ -7,9 +7,10 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\Diff; -interface Exception +use Throwable; + +interface Exception extends Throwable { } diff --git a/vendor/sebastian/diff/src/Exception/InvalidArgumentException.php b/vendor/sebastian/diff/src/Exception/InvalidArgumentException.php index 7bca77dc6..846ac3fbd 100644 --- a/vendor/sebastian/diff/src/Exception/InvalidArgumentException.php +++ b/vendor/sebastian/diff/src/Exception/InvalidArgumentException.php @@ -7,7 +7,6 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\Diff; class InvalidArgumentException extends \InvalidArgumentException implements Exception diff --git a/vendor/sebastian/diff/src/Line.php b/vendor/sebastian/diff/src/Line.php index 125bafd3b..3596ed264 100644 --- a/vendor/sebastian/diff/src/Line.php +++ b/vendor/sebastian/diff/src/Line.php @@ -7,13 +7,14 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\Diff; final class Line { public const ADDED = 1; + public const REMOVED = 2; + public const UNCHANGED = 3; /** diff --git a/vendor/sebastian/diff/src/LongestCommonSubsequenceCalculator.php b/vendor/sebastian/diff/src/LongestCommonSubsequenceCalculator.php index 7eb1707ec..dea8fe1cb 100644 --- a/vendor/sebastian/diff/src/LongestCommonSubsequenceCalculator.php +++ b/vendor/sebastian/diff/src/LongestCommonSubsequenceCalculator.php @@ -7,18 +7,12 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\Diff; interface LongestCommonSubsequenceCalculator { /** * Calculates the longest common subsequence of two arrays. - * - * @param array $from - * @param array $to - * - * @return array */ public function calculate(array $from, array $to): array; } diff --git a/vendor/sebastian/diff/src/MemoryEfficientLongestCommonSubsequenceCalculator.php b/vendor/sebastian/diff/src/MemoryEfficientLongestCommonSubsequenceCalculator.php index 82dc20c8a..0b626eaff 100644 --- a/vendor/sebastian/diff/src/MemoryEfficientLongestCommonSubsequenceCalculator.php +++ b/vendor/sebastian/diff/src/MemoryEfficientLongestCommonSubsequenceCalculator.php @@ -7,9 +7,16 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\Diff; +use function array_fill; +use function array_merge; +use function array_reverse; +use function array_slice; +use function count; +use function in_array; +use function max; + final class MemoryEfficientLongestCommonSubsequenceCalculator implements LongestCommonSubsequenceCalculator { /** @@ -17,15 +24,15 @@ final class MemoryEfficientLongestCommonSubsequenceCalculator implements Longest */ public function calculate(array $from, array $to): array { - $cFrom = \count($from); - $cTo = \count($to); + $cFrom = count($from); + $cTo = count($to); if ($cFrom === 0) { return []; } if ($cFrom === 1) { - if (\in_array($from[0], $to, true)) { + if (in_array($from[0], $to, true)) { return [$from[0]]; } @@ -33,10 +40,10 @@ final class MemoryEfficientLongestCommonSubsequenceCalculator implements Longest } $i = (int) ($cFrom / 2); - $fromStart = \array_slice($from, 0, $i); - $fromEnd = \array_slice($from, $i); + $fromStart = array_slice($from, 0, $i); + $fromEnd = array_slice($from, $i); $llB = $this->length($fromStart, $to); - $llE = $this->length(\array_reverse($fromEnd), \array_reverse($to)); + $llE = $this->length(array_reverse($fromEnd), array_reverse($to)); $jMax = 0; $max = 0; @@ -49,10 +56,10 @@ final class MemoryEfficientLongestCommonSubsequenceCalculator implements Longest } } - $toStart = \array_slice($to, 0, $jMax); - $toEnd = \array_slice($to, $jMax); + $toStart = array_slice($to, 0, $jMax); + $toEnd = array_slice($to, $jMax); - return \array_merge( + return array_merge( $this->calculate($fromStart, $toStart), $this->calculate($fromEnd, $toEnd) ); @@ -60,9 +67,9 @@ final class MemoryEfficientLongestCommonSubsequenceCalculator implements Longest private function length(array $from, array $to): array { - $current = \array_fill(0, \count($to) + 1, 0); - $cFrom = \count($from); - $cTo = \count($to); + $current = array_fill(0, count($to) + 1, 0); + $cFrom = count($from); + $cTo = count($to); for ($i = 0; $i < $cFrom; $i++) { $prev = $current; @@ -71,7 +78,7 @@ final class MemoryEfficientLongestCommonSubsequenceCalculator implements Longest if ($from[$i] === $to[$j]) { $current[$j + 1] = $prev[$j] + 1; } else { - $current[$j + 1] = \max($current[$j], $prev[$j + 1]); + $current[$j + 1] = max($current[$j], $prev[$j + 1]); } } } diff --git a/vendor/sebastian/diff/src/Output/AbstractChunkOutputBuilder.php b/vendor/sebastian/diff/src/Output/AbstractChunkOutputBuilder.php index 6e590b0ba..e55757c38 100644 --- a/vendor/sebastian/diff/src/Output/AbstractChunkOutputBuilder.php +++ b/vendor/sebastian/diff/src/Output/AbstractChunkOutputBuilder.php @@ -7,23 +7,19 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\Diff\Output; +use function count; + abstract class AbstractChunkOutputBuilder implements DiffOutputBuilderInterface { /** * Takes input of the diff array and returns the common parts. * Iterates through diff line by line. - * - * @param array $diff - * @param int $lineThreshold - * - * @return array */ protected function getCommonChunks(array $diff, int $lineThreshold = 5): array { - $diffSize = \count($diff); + $diffSize = count($diff); $capturing = false; $chunkStart = 0; $chunkSize = 0; diff --git a/vendor/sebastian/diff/src/Output/DiffOnlyOutputBuilder.php b/vendor/sebastian/diff/src/Output/DiffOnlyOutputBuilder.php index 8a186b53b..f79a935cb 100644 --- a/vendor/sebastian/diff/src/Output/DiffOnlyOutputBuilder.php +++ b/vendor/sebastian/diff/src/Output/DiffOnlyOutputBuilder.php @@ -7,9 +7,13 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\Diff\Output; +use function fclose; +use function fopen; +use function fwrite; +use function stream_get_contents; +use function substr; use SebastianBergmann\Diff\Differ; /** @@ -30,38 +34,38 @@ final class DiffOnlyOutputBuilder implements DiffOutputBuilderInterface public function getDiff(array $diff): string { - $buffer = \fopen('php://memory', 'r+b'); + $buffer = fopen('php://memory', 'r+b'); if ('' !== $this->header) { - \fwrite($buffer, $this->header); + fwrite($buffer, $this->header); - if ("\n" !== \substr($this->header, -1, 1)) { - \fwrite($buffer, "\n"); + if ("\n" !== substr($this->header, -1, 1)) { + fwrite($buffer, "\n"); } } foreach ($diff as $diffEntry) { if ($diffEntry[1] === Differ::ADDED) { - \fwrite($buffer, '+' . $diffEntry[0]); + fwrite($buffer, '+' . $diffEntry[0]); } elseif ($diffEntry[1] === Differ::REMOVED) { - \fwrite($buffer, '-' . $diffEntry[0]); + fwrite($buffer, '-' . $diffEntry[0]); } elseif ($diffEntry[1] === Differ::DIFF_LINE_END_WARNING) { - \fwrite($buffer, ' ' . $diffEntry[0]); + fwrite($buffer, ' ' . $diffEntry[0]); continue; // Warnings should not be tested for line break, it will always be there } else { /* Not changed (old) 0 */ continue; // we didn't write the non changs line, so do not add a line break either } - $lc = \substr($diffEntry[0], -1); + $lc = substr($diffEntry[0], -1); if ($lc !== "\n" && $lc !== "\r") { - \fwrite($buffer, "\n"); // \No newline at end of file + fwrite($buffer, "\n"); // \No newline at end of file } } - $diff = \stream_get_contents($buffer, -1, 0); - \fclose($buffer); + $diff = stream_get_contents($buffer, -1, 0); + fclose($buffer); return $diff; } diff --git a/vendor/sebastian/diff/src/Output/DiffOutputBuilderInterface.php b/vendor/sebastian/diff/src/Output/DiffOutputBuilderInterface.php index f6e6afd46..0e18f9f2e 100644 --- a/vendor/sebastian/diff/src/Output/DiffOutputBuilderInterface.php +++ b/vendor/sebastian/diff/src/Output/DiffOutputBuilderInterface.php @@ -7,7 +7,6 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\Diff\Output; /** diff --git a/vendor/sebastian/diff/src/Output/StrictUnifiedDiffOutputBuilder.php b/vendor/sebastian/diff/src/Output/StrictUnifiedDiffOutputBuilder.php index 941b1a746..9c55ab2aa 100644 --- a/vendor/sebastian/diff/src/Output/StrictUnifiedDiffOutputBuilder.php +++ b/vendor/sebastian/diff/src/Output/StrictUnifiedDiffOutputBuilder.php @@ -7,9 +7,22 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\Diff\Output; +use function array_merge; +use function array_splice; +use function count; +use function fclose; +use function fopen; +use function fwrite; +use function is_bool; +use function is_int; +use function is_string; +use function max; +use function min; +use function sprintf; +use function stream_get_contents; +use function substr; use SebastianBergmann\Diff\ConfigurationException; use SebastianBergmann\Diff\Differ; @@ -29,6 +42,7 @@ final class StrictUnifiedDiffOutputBuilder implements DiffOutputBuilderInterface 'toFile' => null, 'toFileDate' => null, ]; + /** * @var bool */ @@ -56,33 +70,26 @@ final class StrictUnifiedDiffOutputBuilder implements DiffOutputBuilderInterface public function __construct(array $options = []) { - $options = \array_merge(self::$default, $options); + $options = array_merge(self::$default, $options); - if (!\is_bool($options['collapseRanges'])) { + if (!is_bool($options['collapseRanges'])) { throw new ConfigurationException('collapseRanges', 'a bool', $options['collapseRanges']); } - if (!\is_int($options['contextLines']) || $options['contextLines'] < 0) { + if (!is_int($options['contextLines']) || $options['contextLines'] < 0) { throw new ConfigurationException('contextLines', 'an int >= 0', $options['contextLines']); } - if (!\is_int($options['commonLineThreshold']) || $options['commonLineThreshold'] <= 0) { + if (!is_int($options['commonLineThreshold']) || $options['commonLineThreshold'] <= 0) { throw new ConfigurationException('commonLineThreshold', 'an int > 0', $options['commonLineThreshold']); } - foreach (['fromFile', 'toFile'] as $option) { - if (!\is_string($options[$option])) { - throw new ConfigurationException($option, 'a string', $options[$option]); - } - } + $this->assertString($options, 'fromFile'); + $this->assertString($options, 'toFile'); + $this->assertStringOrNull($options, 'fromFileDate'); + $this->assertStringOrNull($options, 'toFileDate'); - foreach (['fromFileDate', 'toFileDate'] as $option) { - if (null !== $options[$option] && !\is_string($options[$option])) { - throw new ConfigurationException($option, 'a string or ', $options[$option]); - } - } - - $this->header = \sprintf( + $this->header = sprintf( "--- %s%s\n+++ %s%s\n", $options['fromFile'], null === $options['fromFileDate'] ? '' : "\t" . $options['fromFileDate'], @@ -97,48 +104,47 @@ final class StrictUnifiedDiffOutputBuilder implements DiffOutputBuilderInterface public function getDiff(array $diff): string { - if (0 === \count($diff)) { + if (0 === count($diff)) { return ''; } $this->changed = false; - $buffer = \fopen('php://memory', 'r+b'); - \fwrite($buffer, $this->header); + $buffer = fopen('php://memory', 'r+b'); + fwrite($buffer, $this->header); $this->writeDiffHunks($buffer, $diff); if (!$this->changed) { - \fclose($buffer); + fclose($buffer); return ''; } - $diff = \stream_get_contents($buffer, -1, 0); + $diff = stream_get_contents($buffer, -1, 0); - \fclose($buffer); + fclose($buffer); // If the last char is not a linebreak: add it. // This might happen when both the `from` and `to` do not have a trailing linebreak - $last = \substr($diff, -1); + $last = substr($diff, -1); return "\n" !== $last && "\r" !== $last ? $diff . "\n" - : $diff - ; + : $diff; } private function writeDiffHunks($output, array $diff): void { // detect "No newline at end of file" and insert into `$diff` if needed - $upperLimit = \count($diff); + $upperLimit = count($diff); if (0 === $diff[$upperLimit - 1][1]) { - $lc = \substr($diff[$upperLimit - 1][0], -1); + $lc = substr($diff[$upperLimit - 1][0], -1); if ("\n" !== $lc) { - \array_splice($diff, $upperLimit, 0, [["\n\\ No newline at end of file\n", Differ::NO_LINE_END_EOF_WARNING]]); + array_splice($diff, $upperLimit, 0, [["\n\\ No newline at end of file\n", Differ::NO_LINE_END_EOF_WARNING]]); } } else { // search back for the last `+` and `-` line, @@ -148,13 +154,13 @@ final class StrictUnifiedDiffOutputBuilder implements DiffOutputBuilderInterface for ($i = $upperLimit - 1; $i >= 0; --$i) { if (isset($toFind[$diff[$i][1]])) { unset($toFind[$diff[$i][1]]); - $lc = \substr($diff[$i][0], -1); + $lc = substr($diff[$i][0], -1); if ("\n" !== $lc) { - \array_splice($diff, $i + 1, 0, [["\n\\ No newline at end of file\n", Differ::NO_LINE_END_EOF_WARNING]]); + array_splice($diff, $i + 1, 0, [["\n\\ No newline at end of file\n", Differ::NO_LINE_END_EOF_WARNING]]); } - if (!\count($toFind)) { + if (!count($toFind)) { break; } } @@ -163,11 +169,13 @@ final class StrictUnifiedDiffOutputBuilder implements DiffOutputBuilderInterface // write hunks to output buffer - $cutOff = \max($this->commonLineThreshold, $this->contextLines); + $cutOff = max($this->commonLineThreshold, $this->contextLines); $hunkCapture = false; $sameCount = $toRange = $fromRange = 0; $toStart = $fromStart = 1; + $i = 0; + /** @var int $i */ foreach ($diff as $i => $entry) { if (0 === $entry[1]) { // same if (false === $hunkCapture) { @@ -184,8 +192,7 @@ final class StrictUnifiedDiffOutputBuilder implements DiffOutputBuilderInterface if ($sameCount === $cutOff) { $contextStartOffset = ($hunkCapture - $this->contextLines) < 0 ? $hunkCapture - : $this->contextLines - ; + : $this->contextLines; // note: $contextEndOffset = $this->contextLines; // @@ -249,12 +256,11 @@ final class StrictUnifiedDiffOutputBuilder implements DiffOutputBuilderInterface $contextStartOffset = $hunkCapture - $this->contextLines < 0 ? $hunkCapture - : $this->contextLines - ; + : $this->contextLines; // prevent trying to write out more common lines than there are in the diff _and_ // do not write more than configured through the context lines - $contextEndOffset = \min($sameCount, $this->contextLines); + $contextEndOffset = min($sameCount, $this->contextLines); $fromRange -= $sameCount; $toRange -= $sameCount; @@ -281,32 +287,32 @@ final class StrictUnifiedDiffOutputBuilder implements DiffOutputBuilderInterface int $toRange, $output ): void { - \fwrite($output, '@@ -' . $fromStart); + fwrite($output, '@@ -' . $fromStart); if (!$this->collapseRanges || 1 !== $fromRange) { - \fwrite($output, ',' . $fromRange); + fwrite($output, ',' . $fromRange); } - \fwrite($output, ' +' . $toStart); + fwrite($output, ' +' . $toStart); if (!$this->collapseRanges || 1 !== $toRange) { - \fwrite($output, ',' . $toRange); + fwrite($output, ',' . $toRange); } - \fwrite($output, " @@\n"); + fwrite($output, " @@\n"); for ($i = $diffStartIndex; $i < $diffEndIndex; ++$i) { if ($diff[$i][1] === Differ::ADDED) { $this->changed = true; - \fwrite($output, '+' . $diff[$i][0]); + fwrite($output, '+' . $diff[$i][0]); } elseif ($diff[$i][1] === Differ::REMOVED) { $this->changed = true; - \fwrite($output, '-' . $diff[$i][0]); + fwrite($output, '-' . $diff[$i][0]); } elseif ($diff[$i][1] === Differ::OLD) { - \fwrite($output, ' ' . $diff[$i][0]); + fwrite($output, ' ' . $diff[$i][0]); } elseif ($diff[$i][1] === Differ::NO_LINE_END_EOF_WARNING) { $this->changed = true; - \fwrite($output, $diff[$i][0]); + fwrite($output, $diff[$i][0]); } //} elseif ($diff[$i][1] === Differ::DIFF_LINE_END_WARNING) { // custom comment inserted by PHPUnit/diff package // skip @@ -315,4 +321,18 @@ final class StrictUnifiedDiffOutputBuilder implements DiffOutputBuilderInterface //} } } + + private function assertString(array $options, string $option): void + { + if (!is_string($options[$option])) { + throw new ConfigurationException($option, 'a string', $options[$option]); + } + } + + private function assertStringOrNull(array $options, string $option): void + { + if (null !== $options[$option] && !is_string($options[$option])) { + throw new ConfigurationException($option, 'a string or ', $options[$option]); + } + } } diff --git a/vendor/sebastian/diff/src/Output/UnifiedDiffOutputBuilder.php b/vendor/sebastian/diff/src/Output/UnifiedDiffOutputBuilder.php index e7f0a9d06..8aae64504 100644 --- a/vendor/sebastian/diff/src/Output/UnifiedDiffOutputBuilder.php +++ b/vendor/sebastian/diff/src/Output/UnifiedDiffOutputBuilder.php @@ -7,9 +7,18 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\Diff\Output; +use function array_splice; +use function count; +use function fclose; +use function fopen; +use function fwrite; +use function max; +use function min; +use function stream_get_contents; +use function strlen; +use function substr; use SebastianBergmann\Diff\Differ; /** @@ -50,45 +59,44 @@ final class UnifiedDiffOutputBuilder extends AbstractChunkOutputBuilder public function getDiff(array $diff): string { - $buffer = \fopen('php://memory', 'r+b'); + $buffer = fopen('php://memory', 'r+b'); if ('' !== $this->header) { - \fwrite($buffer, $this->header); + fwrite($buffer, $this->header); - if ("\n" !== \substr($this->header, -1, 1)) { - \fwrite($buffer, "\n"); + if ("\n" !== substr($this->header, -1, 1)) { + fwrite($buffer, "\n"); } } - if (0 !== \count($diff)) { + if (0 !== count($diff)) { $this->writeDiffHunks($buffer, $diff); } - $diff = \stream_get_contents($buffer, -1, 0); + $diff = stream_get_contents($buffer, -1, 0); - \fclose($buffer); + fclose($buffer); - // If the last char is not a linebreak: add it. + // If the diff is non-empty and last char is not a linebreak: add it. // This might happen when both the `from` and `to` do not have a trailing linebreak - $last = \substr($diff, -1); + $last = substr($diff, -1); - return "\n" !== $last && "\r" !== $last + return 0 !== strlen($diff) && "\n" !== $last && "\r" !== $last ? $diff . "\n" - : $diff - ; + : $diff; } private function writeDiffHunks($output, array $diff): void { // detect "No newline at end of file" and insert into `$diff` if needed - $upperLimit = \count($diff); + $upperLimit = count($diff); if (0 === $diff[$upperLimit - 1][1]) { - $lc = \substr($diff[$upperLimit - 1][0], -1); + $lc = substr($diff[$upperLimit - 1][0], -1); if ("\n" !== $lc) { - \array_splice($diff, $upperLimit, 0, [["\n\\ No newline at end of file\n", Differ::NO_LINE_END_EOF_WARNING]]); + array_splice($diff, $upperLimit, 0, [["\n\\ No newline at end of file\n", Differ::NO_LINE_END_EOF_WARNING]]); } } else { // search back for the last `+` and `-` line, @@ -98,13 +106,13 @@ final class UnifiedDiffOutputBuilder extends AbstractChunkOutputBuilder for ($i = $upperLimit - 1; $i >= 0; --$i) { if (isset($toFind[$diff[$i][1]])) { unset($toFind[$diff[$i][1]]); - $lc = \substr($diff[$i][0], -1); + $lc = substr($diff[$i][0], -1); if ("\n" !== $lc) { - \array_splice($diff, $i + 1, 0, [["\n\\ No newline at end of file\n", Differ::NO_LINE_END_EOF_WARNING]]); + array_splice($diff, $i + 1, 0, [["\n\\ No newline at end of file\n", Differ::NO_LINE_END_EOF_WARNING]]); } - if (!\count($toFind)) { + if (!count($toFind)) { break; } } @@ -113,11 +121,13 @@ final class UnifiedDiffOutputBuilder extends AbstractChunkOutputBuilder // write hunks to output buffer - $cutOff = \max($this->commonLineThreshold, $this->contextLines); + $cutOff = max($this->commonLineThreshold, $this->contextLines); $hunkCapture = false; $sameCount = $toRange = $fromRange = 0; $toStart = $fromStart = 1; + $i = 0; + /** @var int $i */ foreach ($diff as $i => $entry) { if (0 === $entry[1]) { // same if (false === $hunkCapture) { @@ -134,8 +144,7 @@ final class UnifiedDiffOutputBuilder extends AbstractChunkOutputBuilder if ($sameCount === $cutOff) { $contextStartOffset = ($hunkCapture - $this->contextLines) < 0 ? $hunkCapture - : $this->contextLines - ; + : $this->contextLines; // note: $contextEndOffset = $this->contextLines; // @@ -197,12 +206,11 @@ final class UnifiedDiffOutputBuilder extends AbstractChunkOutputBuilder $contextStartOffset = $hunkCapture - $this->contextLines < 0 ? $hunkCapture - : $this->contextLines - ; + : $this->contextLines; // prevent trying to write out more common lines than there are in the diff _and_ // do not write more than configured through the context lines - $contextEndOffset = \min($sameCount, $this->contextLines); + $contextEndOffset = min($sameCount, $this->contextLines); $fromRange -= $sameCount; $toRange -= $sameCount; @@ -230,34 +238,34 @@ final class UnifiedDiffOutputBuilder extends AbstractChunkOutputBuilder $output ): void { if ($this->addLineNumbers) { - \fwrite($output, '@@ -' . $fromStart); + fwrite($output, '@@ -' . $fromStart); if (!$this->collapseRanges || 1 !== $fromRange) { - \fwrite($output, ',' . $fromRange); + fwrite($output, ',' . $fromRange); } - \fwrite($output, ' +' . $toStart); + fwrite($output, ' +' . $toStart); if (!$this->collapseRanges || 1 !== $toRange) { - \fwrite($output, ',' . $toRange); + fwrite($output, ',' . $toRange); } - \fwrite($output, " @@\n"); + fwrite($output, " @@\n"); } else { - \fwrite($output, "@@ @@\n"); + fwrite($output, "@@ @@\n"); } for ($i = $diffStartIndex; $i < $diffEndIndex; ++$i) { if ($diff[$i][1] === Differ::ADDED) { - \fwrite($output, '+' . $diff[$i][0]); + fwrite($output, '+' . $diff[$i][0]); } elseif ($diff[$i][1] === Differ::REMOVED) { - \fwrite($output, '-' . $diff[$i][0]); + fwrite($output, '-' . $diff[$i][0]); } elseif ($diff[$i][1] === Differ::OLD) { - \fwrite($output, ' ' . $diff[$i][0]); + fwrite($output, ' ' . $diff[$i][0]); } elseif ($diff[$i][1] === Differ::NO_LINE_END_EOF_WARNING) { - \fwrite($output, "\n"); // $diff[$i][0] + fwrite($output, "\n"); // $diff[$i][0] } else { /* Not changed (old) Differ::OLD or Warning Differ::DIFF_LINE_END_WARNING */ - \fwrite($output, ' ' . $diff[$i][0]); + fwrite($output, ' ' . $diff[$i][0]); } } } diff --git a/vendor/sebastian/diff/src/Parser.php b/vendor/sebastian/diff/src/Parser.php index 3c52f4365..cc9e38871 100644 --- a/vendor/sebastian/diff/src/Parser.php +++ b/vendor/sebastian/diff/src/Parser.php @@ -7,35 +7,38 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\Diff; +use function array_pop; +use function count; +use function max; +use function preg_match; +use function preg_split; + /** * Unified diff parser. */ final class Parser { /** - * @param string $string - * * @return Diff[] */ public function parse(string $string): array { - $lines = \preg_split('(\r\n|\r|\n)', $string); + $lines = preg_split('(\r\n|\r|\n)', $string); - if (!empty($lines) && $lines[\count($lines) - 1] === '') { - \array_pop($lines); + if (!empty($lines) && $lines[count($lines) - 1] === '') { + array_pop($lines); } - $lineCount = \count($lines); + $lineCount = count($lines); $diffs = []; $diff = null; $collected = []; for ($i = 0; $i < $lineCount; ++$i) { - if (\preg_match('(^---\\s+(?P\\S+))', $lines[$i], $fromMatch) && - \preg_match('(^\\+\\+\\+\\s+(?P\\S+))', $lines[$i + 1], $toMatch)) { + if (preg_match('#^---\h+"?(?P[^\\v\\t"]+)#', $lines[$i], $fromMatch) && + preg_match('#^\\+\\+\\+\\h+"?(?P[^\\v\\t"]+)#', $lines[$i + 1], $toMatch)) { if ($diff !== null) { $this->parseFileDiff($diff, $collected); @@ -47,7 +50,7 @@ final class Parser ++$i; } else { - if (\preg_match('/^(?:diff --git |index [\da-f\.]+|[+-]{3} [ab])/', $lines[$i])) { + if (preg_match('/^(?:diff --git |index [\da-f\.]+|[+-]{3} [ab])/', $lines[$i])) { continue; } @@ -55,7 +58,7 @@ final class Parser } } - if ($diff !== null && \count($collected)) { + if ($diff !== null && count($collected)) { $this->parseFileDiff($diff, $collected); $diffs[] = $diff; @@ -66,16 +69,17 @@ final class Parser private function parseFileDiff(Diff $diff, array $lines): void { - $chunks = []; - $chunk = null; + $chunks = []; + $chunk = null; + $diffLines = []; foreach ($lines as $line) { - if (\preg_match('/^@@\s+-(?P\d+)(?:,\s*(?P\d+))?\s+\+(?P\d+)(?:,\s*(?P\d+))?\s+@@/', $line, $match)) { + if (preg_match('/^@@\s+-(?P\d+)(?:,\s*(?P\d+))?\s+\+(?P\d+)(?:,\s*(?P\d+))?\s+@@/', $line, $match)) { $chunk = new Chunk( (int) $match['start'], - isset($match['startrange']) ? \max(1, (int) $match['startrange']) : 1, + isset($match['startrange']) ? max(1, (int) $match['startrange']) : 1, (int) $match['end'], - isset($match['endrange']) ? \max(1, (int) $match['endrange']) : 1 + isset($match['endrange']) ? max(1, (int) $match['endrange']) : 1 ); $chunks[] = $chunk; @@ -84,7 +88,7 @@ final class Parser continue; } - if (\preg_match('/^(?P[+ -])?(?P.*)/', $line, $match)) { + if (preg_match('/^(?P[+ -])?(?P.*)/', $line, $match)) { $type = Line::UNCHANGED; if ($match['type'] === '+') { diff --git a/vendor/sebastian/diff/src/TimeEfficientLongestCommonSubsequenceCalculator.php b/vendor/sebastian/diff/src/TimeEfficientLongestCommonSubsequenceCalculator.php index 97dadbd58..fd19cac76 100644 --- a/vendor/sebastian/diff/src/TimeEfficientLongestCommonSubsequenceCalculator.php +++ b/vendor/sebastian/diff/src/TimeEfficientLongestCommonSubsequenceCalculator.php @@ -7,9 +7,13 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\Diff; +use function array_reverse; +use function count; +use function max; +use SplFixedArray; + final class TimeEfficientLongestCommonSubsequenceCalculator implements LongestCommonSubsequenceCalculator { /** @@ -18,10 +22,10 @@ final class TimeEfficientLongestCommonSubsequenceCalculator implements LongestCo public function calculate(array $from, array $to): array { $common = []; - $fromLength = \count($from); - $toLength = \count($to); + $fromLength = count($from); + $toLength = count($to); $width = $fromLength + 1; - $matrix = new \SplFixedArray($width * ($toLength + 1)); + $matrix = new SplFixedArray($width * ($toLength + 1)); for ($i = 0; $i <= $fromLength; ++$i) { $matrix[$i] = 0; @@ -34,7 +38,7 @@ final class TimeEfficientLongestCommonSubsequenceCalculator implements LongestCo for ($i = 1; $i <= $fromLength; ++$i) { for ($j = 1; $j <= $toLength; ++$j) { $o = ($j * $width) + $i; - $matrix[$o] = \max( + $matrix[$o] = max( $matrix[$o - 1], $matrix[$o - $width], $from[$i - 1] === $to[$j - 1] ? $matrix[$o - $width - 1] + 1 : 0 @@ -61,6 +65,6 @@ final class TimeEfficientLongestCommonSubsequenceCalculator implements LongestCo } } - return \array_reverse($common); + return array_reverse($common); } } diff --git a/vendor/sebastian/diff/tests/ChunkTest.php b/vendor/sebastian/diff/tests/ChunkTest.php deleted file mode 100644 index 40106c0ee..000000000 --- a/vendor/sebastian/diff/tests/ChunkTest.php +++ /dev/null @@ -1,73 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff; - -use PHPUnit\Framework\TestCase; - -/** - * @covers SebastianBergmann\Diff\Chunk - */ -final class ChunkTest extends TestCase -{ - /** - * @var Chunk - */ - private $chunk; - - protected function setUp(): void - { - $this->chunk = new Chunk; - } - - public function testHasInitiallyNoLines(): void - { - $this->assertSame([], $this->chunk->getLines()); - } - - public function testCanBeCreatedWithoutArguments(): void - { - $this->assertInstanceOf(Chunk::class, $this->chunk); - } - - public function testStartCanBeRetrieved(): void - { - $this->assertSame(0, $this->chunk->getStart()); - } - - public function testStartRangeCanBeRetrieved(): void - { - $this->assertSame(1, $this->chunk->getStartRange()); - } - - public function testEndCanBeRetrieved(): void - { - $this->assertSame(0, $this->chunk->getEnd()); - } - - public function testEndRangeCanBeRetrieved(): void - { - $this->assertSame(1, $this->chunk->getEndRange()); - } - - public function testLinesCanBeRetrieved(): void - { - $this->assertSame([], $this->chunk->getLines()); - } - - public function testLinesCanBeSet(): void - { - $lines = [new Line(Line::ADDED, 'added'), new Line(Line::REMOVED, 'removed')]; - - $this->chunk->setLines($lines); - - $this->assertSame($lines, $this->chunk->getLines()); - } -} diff --git a/vendor/sebastian/diff/tests/DiffTest.php b/vendor/sebastian/diff/tests/DiffTest.php deleted file mode 100644 index 20f76e15d..000000000 --- a/vendor/sebastian/diff/tests/DiffTest.php +++ /dev/null @@ -1,55 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff; - -use PHPUnit\Framework\TestCase; - -/** - * @covers SebastianBergmann\Diff\Diff - * - * @uses SebastianBergmann\Diff\Chunk - */ -final class DiffTest extends TestCase -{ - public function testGettersAfterConstructionWithDefault(): void - { - $from = 'line1a'; - $to = 'line2a'; - $diff = new Diff($from, $to); - - $this->assertSame($from, $diff->getFrom()); - $this->assertSame($to, $diff->getTo()); - $this->assertSame([], $diff->getChunks(), 'Expect chunks to be default value "array()".'); - } - - public function testGettersAfterConstructionWithChunks(): void - { - $from = 'line1b'; - $to = 'line2b'; - $chunks = [new Chunk(), new Chunk(2, 3)]; - - $diff = new Diff($from, $to, $chunks); - - $this->assertSame($from, $diff->getFrom()); - $this->assertSame($to, $diff->getTo()); - $this->assertSame($chunks, $diff->getChunks(), 'Expect chunks to be passed value.'); - } - - public function testSetChunksAfterConstruction(): void - { - $diff = new Diff('line1c', 'line2c'); - $this->assertSame([], $diff->getChunks(), 'Expect chunks to be default value "array()".'); - - $chunks = [new Chunk(), new Chunk(2, 3)]; - $diff->setChunks($chunks); - $this->assertSame($chunks, $diff->getChunks(), 'Expect chunks to be passed value.'); - } -} diff --git a/vendor/sebastian/diff/tests/DifferTest.php b/vendor/sebastian/diff/tests/DifferTest.php deleted file mode 100644 index 5a8962ef0..000000000 --- a/vendor/sebastian/diff/tests/DifferTest.php +++ /dev/null @@ -1,444 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff; - -use PHPUnit\Framework\TestCase; -use SebastianBergmann\Diff\Output\UnifiedDiffOutputBuilder; - -/** - * @covers SebastianBergmann\Diff\Differ - * @covers SebastianBergmann\Diff\Output\UnifiedDiffOutputBuilder - * - * @uses SebastianBergmann\Diff\MemoryEfficientLongestCommonSubsequenceCalculator - * @uses SebastianBergmann\Diff\TimeEfficientLongestCommonSubsequenceCalculator - * @uses SebastianBergmann\Diff\Output\AbstractChunkOutputBuilder - */ -final class DifferTest extends TestCase -{ - /** - * @var Differ - */ - private $differ; - - protected function setUp(): void - { - $this->differ = new Differ; - } - - /** - * @param array $expected - * @param array|string $from - * @param array|string $to - * - * @dataProvider arrayProvider - */ - public function testArrayRepresentationOfDiffCanBeRenderedUsingTimeEfficientLcsImplementation(array $expected, $from, $to): void - { - $this->assertSame($expected, $this->differ->diffToArray($from, $to, new TimeEfficientLongestCommonSubsequenceCalculator)); - } - - /** - * @param string $expected - * @param string $from - * @param string $to - * - * @dataProvider textProvider - */ - public function testTextRepresentationOfDiffCanBeRenderedUsingTimeEfficientLcsImplementation(string $expected, string $from, string $to): void - { - $this->assertSame($expected, $this->differ->diff($from, $to, new TimeEfficientLongestCommonSubsequenceCalculator)); - } - - /** - * @param array $expected - * @param array|string $from - * @param array|string $to - * - * @dataProvider arrayProvider - */ - public function testArrayRepresentationOfDiffCanBeRenderedUsingMemoryEfficientLcsImplementation(array $expected, $from, $to): void - { - $this->assertSame($expected, $this->differ->diffToArray($from, $to, new MemoryEfficientLongestCommonSubsequenceCalculator)); - } - - /** - * @param string $expected - * @param string $from - * @param string $to - * - * @dataProvider textProvider - */ - public function testTextRepresentationOfDiffCanBeRenderedUsingMemoryEfficientLcsImplementation(string $expected, string $from, string $to): void - { - $this->assertSame($expected, $this->differ->diff($from, $to, new MemoryEfficientLongestCommonSubsequenceCalculator)); - } - - public function testTypesOtherThanArrayAndStringCanBePassed(): void - { - $this->assertSame( - "--- Original\n+++ New\n@@ @@\n-1\n+2\n", - $this->differ->diff(1, 2) - ); - } - - public function testArrayDiffs(): void - { - $this->assertSame( - '--- Original -+++ New -@@ @@ --one -+two -', - $this->differ->diff(['one'], ['two']) - ); - } - - public function arrayProvider(): array - { - return [ - [ - [ - ['a', Differ::REMOVED], - ['b', Differ::ADDED], - ], - 'a', - 'b', - ], - [ - [ - ['ba', Differ::REMOVED], - ['bc', Differ::ADDED], - ], - 'ba', - 'bc', - ], - [ - [ - ['ab', Differ::REMOVED], - ['cb', Differ::ADDED], - ], - 'ab', - 'cb', - ], - [ - [ - ['abc', Differ::REMOVED], - ['adc', Differ::ADDED], - ], - 'abc', - 'adc', - ], - [ - [ - ['ab', Differ::REMOVED], - ['abc', Differ::ADDED], - ], - 'ab', - 'abc', - ], - [ - [ - ['bc', Differ::REMOVED], - ['abc', Differ::ADDED], - ], - 'bc', - 'abc', - ], - [ - [ - ['abc', Differ::REMOVED], - ['abbc', Differ::ADDED], - ], - 'abc', - 'abbc', - ], - [ - [ - ['abcdde', Differ::REMOVED], - ['abcde', Differ::ADDED], - ], - 'abcdde', - 'abcde', - ], - 'same start' => [ - [ - [17, Differ::OLD], - ['b', Differ::REMOVED], - ['d', Differ::ADDED], - ], - [30 => 17, 'a' => 'b'], - [30 => 17, 'c' => 'd'], - ], - 'same end' => [ - [ - [1, Differ::REMOVED], - [2, Differ::ADDED], - ['b', Differ::OLD], - ], - [1 => 1, 'a' => 'b'], - [1 => 2, 'a' => 'b'], - ], - 'same start (2), same end (1)' => [ - [ - [17, Differ::OLD], - [2, Differ::OLD], - [4, Differ::REMOVED], - ['a', Differ::ADDED], - [5, Differ::ADDED], - ['x', Differ::OLD], - ], - [30 => 17, 1 => 2, 2 => 4, 'z' => 'x'], - [30 => 17, 1 => 2, 3 => 'a', 2 => 5, 'z' => 'x'], - ], - 'same' => [ - [ - ['x', Differ::OLD], - ], - ['z' => 'x'], - ['z' => 'x'], - ], - 'diff' => [ - [ - ['y', Differ::REMOVED], - ['x', Differ::ADDED], - ], - ['x' => 'y'], - ['z' => 'x'], - ], - 'diff 2' => [ - [ - ['y', Differ::REMOVED], - ['b', Differ::REMOVED], - ['x', Differ::ADDED], - ['d', Differ::ADDED], - ], - ['x' => 'y', 'a' => 'b'], - ['z' => 'x', 'c' => 'd'], - ], - 'test line diff detection' => [ - [ - [ - "#Warning: Strings contain different line endings!\n", - Differ::DIFF_LINE_END_WARNING, - ], - [ - " [ - [ - [ - "#Warning: Strings contain different line endings!\n", - Differ::DIFF_LINE_END_WARNING, - ], - [ - "expectException(InvalidArgumentException::class); - $this->expectExceptionMessageRegExp('#^"from" must be an array or string\.$#'); - - $this->differ->diffToArray(null, ''); - } - - public function testDiffInvalidToType(): void - { - $this->expectException(InvalidArgumentException::class); - $this->expectExceptionMessageRegExp('#^"to" must be an array or string\.$#'); - - $this->differ->diffToArray('', new \stdClass); - } - - /** - * @param array $expected - * @param string $input - * - * @dataProvider provideSplitStringByLinesCases - */ - public function testSplitStringByLines(array $expected, string $input): void - { - $reflection = new \ReflectionObject($this->differ); - $method = $reflection->getMethod('splitStringByLines'); - $method->setAccessible(true); - - $this->assertSame($expected, $method->invoke($this->differ, $input)); - } - - public function provideSplitStringByLinesCases(): array - { - return [ - [ - [], - '', - ], - [ - ['a'], - 'a', - ], - [ - ["a\n"], - "a\n", - ], - [ - ["a\r"], - "a\r", - ], - [ - ["a\r\n"], - "a\r\n", - ], - [ - ["\n"], - "\n", - ], - [ - ["\r"], - "\r", - ], - [ - ["\r\n"], - "\r\n", - ], - [ - [ - "A\n", - "B\n", - "\n", - "C\n", - ], - "A\nB\n\nC\n", - ], - [ - [ - "A\r\n", - "B\n", - "\n", - "C\r", - ], - "A\r\nB\n\nC\r", - ], - [ - [ - "\n", - "A\r\n", - "B\n", - "\n", - 'C', - ], - "\nA\r\nB\n\nC", - ], - ]; - } - - public function testConstructorInvalidArgInt(): void - { - $this->expectException(InvalidArgumentException::class); - $this->expectExceptionMessageRegExp('/^Expected builder to be an instance of DiffOutputBuilderInterface, or a string, got integer "1"\.$/'); - - new Differ(1); - } - - public function testConstructorInvalidArgObject(): void - { - $this->expectException(InvalidArgumentException::class); - $this->expectExceptionMessageRegExp('/^Expected builder to be an instance of DiffOutputBuilderInterface, or a string, got instance of "SplFileInfo"\.$/'); - - new Differ(new \SplFileInfo(__FILE__)); - } -} diff --git a/vendor/sebastian/diff/tests/Exception/ConfigurationExceptionTest.php b/vendor/sebastian/diff/tests/Exception/ConfigurationExceptionTest.php deleted file mode 100644 index 1ce887a73..000000000 --- a/vendor/sebastian/diff/tests/Exception/ConfigurationExceptionTest.php +++ /dev/null @@ -1,41 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff; - -use PHPUnit\Framework\TestCase; - -/** - * @covers SebastianBergmann\Diff\ConfigurationException - */ -final class ConfigurationExceptionTest extends TestCase -{ - public function testConstructWithDefaults(): void - { - $e = new ConfigurationException('test', 'A', 'B'); - - $this->assertSame(0, $e->getCode()); - $this->assertNull($e->getPrevious()); - $this->assertSame('Option "test" must be A, got "string#B".', $e->getMessage()); - } - - public function testConstruct(): void - { - $e = new ConfigurationException( - 'test', - 'integer', - new \SplFileInfo(__FILE__), - 789, - new \BadMethodCallException(__METHOD__) - ); - - $this->assertSame('Option "test" must be integer, got "SplFileInfo".', $e->getMessage()); - } -} diff --git a/vendor/sebastian/diff/tests/Exception/InvalidArgumentExceptionTest.php b/vendor/sebastian/diff/tests/Exception/InvalidArgumentExceptionTest.php deleted file mode 100644 index a112920c4..000000000 --- a/vendor/sebastian/diff/tests/Exception/InvalidArgumentExceptionTest.php +++ /dev/null @@ -1,33 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff; - -use PHPUnit\Framework\TestCase; - -/** - * @covers SebastianBergmann\Diff\InvalidArgumentException - */ -final class InvalidArgumentExceptionTest extends TestCase -{ - public function testInvalidArgumentException(): void - { - $previousException = new \LogicException(); - $message = 'test'; - $code = 123; - - $exception = new InvalidArgumentException($message, $code, $previousException); - - $this->assertInstanceOf(Exception::class, $exception); - $this->assertSame($message, $exception->getMessage()); - $this->assertSame($code, $exception->getCode()); - $this->assertSame($previousException, $exception->getPrevious()); - } -} diff --git a/vendor/sebastian/diff/tests/LineTest.php b/vendor/sebastian/diff/tests/LineTest.php deleted file mode 100644 index 5aca39b25..000000000 --- a/vendor/sebastian/diff/tests/LineTest.php +++ /dev/null @@ -1,44 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff; - -use PHPUnit\Framework\TestCase; - -/** - * @covers SebastianBergmann\Diff\Line - */ -final class LineTest extends TestCase -{ - /** - * @var Line - */ - private $line; - - protected function setUp(): void - { - $this->line = new Line; - } - - public function testCanBeCreatedWithoutArguments(): void - { - $this->assertInstanceOf(Line::class, $this->line); - } - - public function testTypeCanBeRetrieved(): void - { - $this->assertSame(Line::UNCHANGED, $this->line->getType()); - } - - public function testContentCanBeRetrieved(): void - { - $this->assertSame('', $this->line->getContent()); - } -} diff --git a/vendor/sebastian/diff/tests/LongestCommonSubsequenceTest.php b/vendor/sebastian/diff/tests/LongestCommonSubsequenceTest.php deleted file mode 100644 index 28d2809fb..000000000 --- a/vendor/sebastian/diff/tests/LongestCommonSubsequenceTest.php +++ /dev/null @@ -1,201 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff; - -use PHPUnit\Framework\TestCase; - -/** - * @coversNothing - */ -abstract class LongestCommonSubsequenceTest extends TestCase -{ - /** - * @var LongestCommonSubsequenceCalculator - */ - private $implementation; - - /** - * @var string - */ - private $memoryLimit; - - /** - * @var int[] - */ - private $stress_sizes = [1, 2, 3, 100, 500, 1000, 2000]; - - protected function setUp(): void - { - $this->memoryLimit = \ini_get('memory_limit'); - \ini_set('memory_limit', '256M'); - - $this->implementation = $this->createImplementation(); - } - - protected function tearDown(): void - { - \ini_set('memory_limit', $this->memoryLimit); - } - - public function testBothEmpty(): void - { - $from = []; - $to = []; - $common = $this->implementation->calculate($from, $to); - - $this->assertSame([], $common); - } - - public function testIsStrictComparison(): void - { - $from = [ - false, 0, 0.0, '', null, [], - true, 1, 1.0, 'foo', ['foo', 'bar'], ['foo' => 'bar'], - ]; - $to = $from; - $common = $this->implementation->calculate($from, $to); - - $this->assertSame($from, $common); - - $to = [ - false, false, false, false, false, false, - true, true, true, true, true, true, - ]; - - $expected = [ - false, - true, - ]; - - $common = $this->implementation->calculate($from, $to); - - $this->assertSame($expected, $common); - } - - public function testEqualSequences(): void - { - foreach ($this->stress_sizes as $size) { - $range = \range(1, $size); - $from = $range; - $to = $range; - $common = $this->implementation->calculate($from, $to); - - $this->assertSame($range, $common); - } - } - - public function testDistinctSequences(): void - { - $from = ['A']; - $to = ['B']; - $common = $this->implementation->calculate($from, $to); - $this->assertSame([], $common); - - $from = ['A', 'B', 'C']; - $to = ['D', 'E', 'F']; - $common = $this->implementation->calculate($from, $to); - $this->assertSame([], $common); - - foreach ($this->stress_sizes as $size) { - $from = \range(1, $size); - $to = \range($size + 1, $size * 2); - $common = $this->implementation->calculate($from, $to); - $this->assertSame([], $common); - } - } - - public function testCommonSubsequence(): void - { - $from = ['A', 'C', 'E', 'F', 'G']; - $to = ['A', 'B', 'D', 'E', 'H']; - $expected = ['A', 'E']; - $common = $this->implementation->calculate($from, $to); - $this->assertSame($expected, $common); - - $from = ['A', 'C', 'E', 'F', 'G']; - $to = ['B', 'C', 'D', 'E', 'F', 'H']; - $expected = ['C', 'E', 'F']; - $common = $this->implementation->calculate($from, $to); - $this->assertSame($expected, $common); - - foreach ($this->stress_sizes as $size) { - $from = $size < 2 ? [1] : \range(1, $size + 1, 2); - $to = $size < 3 ? [1] : \range(1, $size + 1, 3); - $expected = $size < 6 ? [1] : \range(1, $size + 1, 6); - $common = $this->implementation->calculate($from, $to); - - $this->assertSame($expected, $common); - } - } - - public function testSingleElementSubsequenceAtStart(): void - { - foreach ($this->stress_sizes as $size) { - $from = \range(1, $size); - $to = \array_slice($from, 0, 1); - $common = $this->implementation->calculate($from, $to); - - $this->assertSame($to, $common); - } - } - - public function testSingleElementSubsequenceAtMiddle(): void - { - foreach ($this->stress_sizes as $size) { - $from = \range(1, $size); - $to = \array_slice($from, (int) ($size / 2), 1); - $common = $this->implementation->calculate($from, $to); - - $this->assertSame($to, $common); - } - } - - public function testSingleElementSubsequenceAtEnd(): void - { - foreach ($this->stress_sizes as $size) { - $from = \range(1, $size); - $to = \array_slice($from, $size - 1, 1); - $common = $this->implementation->calculate($from, $to); - - $this->assertSame($to, $common); - } - } - - public function testReversedSequences(): void - { - $from = ['A', 'B']; - $to = ['B', 'A']; - $expected = ['A']; - $common = $this->implementation->calculate($from, $to); - $this->assertSame($expected, $common); - - foreach ($this->stress_sizes as $size) { - $from = \range(1, $size); - $to = \array_reverse($from); - $common = $this->implementation->calculate($from, $to); - - $this->assertSame([1], $common); - } - } - - public function testStrictTypeCalculate(): void - { - $diff = $this->implementation->calculate(['5'], ['05']); - - $this->assertIsArray($diff); - $this->assertCount(0, $diff); - } - - /** - * @return LongestCommonSubsequenceCalculator - */ - abstract protected function createImplementation(): LongestCommonSubsequenceCalculator; -} diff --git a/vendor/sebastian/diff/tests/MemoryEfficientImplementationTest.php b/vendor/sebastian/diff/tests/MemoryEfficientImplementationTest.php deleted file mode 100644 index a8a21e2ea..000000000 --- a/vendor/sebastian/diff/tests/MemoryEfficientImplementationTest.php +++ /dev/null @@ -1,22 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff; - -/** - * @covers SebastianBergmann\Diff\MemoryEfficientLongestCommonSubsequenceCalculator - */ -final class MemoryEfficientImplementationTest extends LongestCommonSubsequenceTest -{ - protected function createImplementation(): LongestCommonSubsequenceCalculator - { - return new MemoryEfficientLongestCommonSubsequenceCalculator; - } -} diff --git a/vendor/sebastian/diff/tests/Output/AbstractChunkOutputBuilderTest.php b/vendor/sebastian/diff/tests/Output/AbstractChunkOutputBuilderTest.php deleted file mode 100644 index ad6ceb2c4..000000000 --- a/vendor/sebastian/diff/tests/Output/AbstractChunkOutputBuilderTest.php +++ /dev/null @@ -1,152 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff\Output; - -use PHPUnit\Framework\TestCase; -use SebastianBergmann\Diff\Differ; - -/** - * @covers SebastianBergmann\Diff\Output\AbstractChunkOutputBuilder - * - * @uses SebastianBergmann\Diff\Differ - * @uses SebastianBergmann\Diff\Output\UnifiedDiffOutputBuilder - * @uses SebastianBergmann\Diff\TimeEfficientLongestCommonSubsequenceCalculator - */ -final class AbstractChunkOutputBuilderTest extends TestCase -{ - /** - * @param array $expected - * @param string $from - * @param string $to - * @param int $lineThreshold - * - * @dataProvider provideGetCommonChunks - */ - public function testGetCommonChunks(array $expected, string $from, string $to, int $lineThreshold = 5): void - { - $output = new class extends AbstractChunkOutputBuilder { - public function getDiff(array $diff): string - { - return ''; - } - - public function getChunks(array $diff, $lineThreshold) - { - return $this->getCommonChunks($diff, $lineThreshold); - } - }; - - $this->assertSame( - $expected, - $output->getChunks((new Differ)->diffToArray($from, $to), $lineThreshold) - ); - } - - public function provideGetCommonChunks(): array - { - return[ - 'same (with default threshold)' => [ - [], - 'A', - 'A', - ], - 'same (threshold 0)' => [ - [0 => 0], - 'A', - 'A', - 0, - ], - 'empty' => [ - [], - '', - '', - ], - 'single line diff' => [ - [], - 'A', - 'B', - ], - 'below threshold I' => [ - [], - "A\nX\nC", - "A\nB\nC", - ], - 'below threshold II' => [ - [], - "A\n\n\n\nX\nC", - "A\n\n\n\nB\nC", - ], - 'below threshold III' => [ - [0 => 5], - "A\n\n\n\n\n\nB", - "A\n\n\n\n\n\nA", - ], - 'same start' => [ - [0 => 5], - "A\n\n\n\n\n\nX\nC", - "A\n\n\n\n\n\nB\nC", - ], - 'same start long' => [ - [0 => 13], - "\n\n\n\n\n\n\n\n\n\n\n\n\n\nA", - "\n\n\n\n\n\n\n\n\n\n\n\n\n\nB", - ], - 'same part in between' => [ - [2 => 8], - "A\n\n\n\n\n\n\nX\nY\nZ\n\n", - "B\n\n\n\n\n\n\nX\nA\nZ\n\n", - ], - 'same trailing' => [ - [2 => 14], - "A\n\n\n\n\n\n\n\n\n\n\n\n\n\n", - "B\n\n\n\n\n\n\n\n\n\n\n\n\n\n", - ], - 'same part in between, same trailing' => [ - [2 => 7, 10 => 15], - "A\n\n\n\n\n\n\nA\n\n\n\n\n\n\n", - "B\n\n\n\n\n\n\nB\n\n\n\n\n\n\n", - ], - 'below custom threshold I' => [ - [], - "A\n\nB", - "A\n\nD", - 2, - ], - 'custom threshold I' => [ - [0 => 1], - "A\n\nB", - "A\n\nD", - 1, - ], - 'custom threshold II' => [ - [], - "A\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n", - "A\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n", - 19, - ], - [ - [3 => 9], - "a\nb\nc\nd\ne\nf\ng\nh\ni\nj\nk", - "a\np\nc\nd\ne\nf\ng\nh\ni\nw\nk", - ], - [ - [0 => 5, 8 => 13], - "A\nA\nA\nA\nA\nA\nX\nC\nC\nC\nC\nC\nC", - "A\nA\nA\nA\nA\nA\nB\nC\nC\nC\nC\nC\nC", - ], - [ - [0 => 5, 8 => 13], - "A\nA\nA\nA\nA\nA\nX\nC\nC\nC\nC\nC\nC\nX", - "A\nA\nA\nA\nA\nA\nB\nC\nC\nC\nC\nC\nC\nY", - ], - ]; - } -} diff --git a/vendor/sebastian/diff/tests/Output/DiffOnlyOutputBuilderTest.php b/vendor/sebastian/diff/tests/Output/DiffOnlyOutputBuilderTest.php deleted file mode 100644 index 87c017601..000000000 --- a/vendor/sebastian/diff/tests/Output/DiffOnlyOutputBuilderTest.php +++ /dev/null @@ -1,76 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff\Output; - -use PHPUnit\Framework\TestCase; -use SebastianBergmann\Diff\Differ; - -/** - * @covers SebastianBergmann\Diff\Output\DiffOnlyOutputBuilder - * - * @uses SebastianBergmann\Diff\Differ - * @uses SebastianBergmann\Diff\TimeEfficientLongestCommonSubsequenceCalculator - */ -final class DiffOnlyOutputBuilderTest extends TestCase -{ - /** - * @param string $expected - * @param string $from - * @param string $to - * @param string $header - * - * @dataProvider textForNoNonDiffLinesProvider - */ - public function testDiffDoNotShowNonDiffLines(string $expected, string $from, string $to, string $header = ''): void - { - $differ = new Differ(new DiffOnlyOutputBuilder($header)); - - $this->assertSame($expected, $differ->diff($from, $to)); - } - - public function textForNoNonDiffLinesProvider(): array - { - return [ - [ - " #Warning: Strings contain different line endings!\n-A\r\n+B\n", - "A\r\n", - "B\n", - ], - [ - "-A\n+B\n", - "\nA", - "\nB", - ], - [ - '', - 'a', - 'a', - ], - [ - "-A\n+C\n", - "A\n\n\nB", - "C\n\n\nB", - ], - [ - "header\n", - 'a', - 'a', - 'header', - ], - [ - "header\n", - 'a', - 'a', - "header\n", - ], - ]; - } -} diff --git a/vendor/sebastian/diff/tests/Output/Integration/StrictUnifiedDiffOutputBuilderIntegrationTest.php b/vendor/sebastian/diff/tests/Output/Integration/StrictUnifiedDiffOutputBuilderIntegrationTest.php deleted file mode 100644 index d15f44578..000000000 --- a/vendor/sebastian/diff/tests/Output/Integration/StrictUnifiedDiffOutputBuilderIntegrationTest.php +++ /dev/null @@ -1,299 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff\Output; - -use PHPUnit\Framework\TestCase; -use SebastianBergmann\Diff\Differ; -use SebastianBergmann\Diff\Utils\FileUtils; -use SebastianBergmann\Diff\Utils\UnifiedDiffAssertTrait; -use Symfony\Component\Process\Process; - -/** - * @covers SebastianBergmann\Diff\Output\StrictUnifiedDiffOutputBuilder - * - * @uses SebastianBergmann\Diff\Differ - * @uses SebastianBergmann\Diff\TimeEfficientLongestCommonSubsequenceCalculator - * - * @requires OS Linux - */ -final class StrictUnifiedDiffOutputBuilderIntegrationTest extends TestCase -{ - use UnifiedDiffAssertTrait; - - private $dir; - - private $fileFrom; - - private $fileTo; - - private $filePatch; - - protected function setUp(): void - { - $this->dir = \realpath(__DIR__ . '/../../fixtures/out') . '/'; - $this->fileFrom = $this->dir . 'from.txt'; - $this->fileTo = $this->dir . 'to.txt'; - $this->filePatch = $this->dir . 'diff.patch'; - - if (!\is_dir($this->dir)) { - throw new \RuntimeException('Integration test working directory not found.'); - } - - $this->cleanUpTempFiles(); - } - - protected function tearDown(): void - { - $this->cleanUpTempFiles(); - } - - /** - * Integration test - * - * - get a file pair - * - create a `diff` between the files - * - test applying the diff using `git apply` - * - test applying the diff using `patch` - * - * @param string $fileFrom - * @param string $fileTo - * - * @dataProvider provideFilePairs - */ - public function testIntegrationUsingPHPFileInVendorGitApply(string $fileFrom, string $fileTo): void - { - $from = FileUtils::getFileContent($fileFrom); - $to = FileUtils::getFileContent($fileTo); - - $diff = (new Differ(new StrictUnifiedDiffOutputBuilder(['fromFile' => 'Original', 'toFile' => 'New'])))->diff($from, $to); - - if ('' === $diff && $from === $to) { - // odd case: test after executing as it is more efficient than to read the files and check the contents every time - $this->addToAssertionCount(1); - - return; - } - - $this->doIntegrationTestGitApply($diff, $from, $to); - } - - /** - * Integration test - * - * - get a file pair - * - create a `diff` between the files - * - test applying the diff using `git apply` - * - test applying the diff using `patch` - * - * @param string $fileFrom - * @param string $fileTo - * - * @dataProvider provideFilePairs - */ - public function testIntegrationUsingPHPFileInVendorPatch(string $fileFrom, string $fileTo): void - { - $from = FileUtils::getFileContent($fileFrom); - $to = FileUtils::getFileContent($fileTo); - - $diff = (new Differ(new StrictUnifiedDiffOutputBuilder(['fromFile' => 'Original', 'toFile' => 'New'])))->diff($from, $to); - - if ('' === $diff && $from === $to) { - // odd case: test after executing as it is more efficient than to read the files and check the contents every time - $this->addToAssertionCount(1); - - return; - } - - $this->doIntegrationTestPatch($diff, $from, $to); - } - - /** - * @param string $expected - * @param string $from - * @param string $to - * - * @dataProvider provideOutputBuildingCases - * @dataProvider provideSample - * @dataProvider provideBasicDiffGeneration - */ - public function testIntegrationOfUnitTestCasesGitApply(string $expected, string $from, string $to): void - { - $this->doIntegrationTestGitApply($expected, $from, $to); - } - - /** - * @param string $expected - * @param string $from - * @param string $to - * - * @dataProvider provideOutputBuildingCases - * @dataProvider provideSample - * @dataProvider provideBasicDiffGeneration - */ - public function testIntegrationOfUnitTestCasesPatch(string $expected, string $from, string $to): void - { - $this->doIntegrationTestPatch($expected, $from, $to); - } - - public function provideOutputBuildingCases(): array - { - return StrictUnifiedDiffOutputBuilderDataProvider::provideOutputBuildingCases(); - } - - public function provideSample(): array - { - return StrictUnifiedDiffOutputBuilderDataProvider::provideSample(); - } - - public function provideBasicDiffGeneration(): array - { - return StrictUnifiedDiffOutputBuilderDataProvider::provideBasicDiffGeneration(); - } - - public function provideFilePairs(): array - { - $cases = []; - $fromFile = __FILE__; - $vendorDir = \realpath(__DIR__ . '/../../../vendor'); - - $fileIterator = new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($vendorDir, \RecursiveDirectoryIterator::SKIP_DOTS)); - - /** @var \SplFileInfo $file */ - foreach ($fileIterator as $file) { - if ('php' !== $file->getExtension()) { - continue; - } - - $toFile = $file->getPathname(); - $cases[\sprintf("Diff file:\n\"%s\"\nvs.\n\"%s\"\n", \realpath($fromFile), \realpath($toFile))] = [$fromFile, $toFile]; - $fromFile = $toFile; - } - - return $cases; - } - - /** - * Compare diff create by builder and against one create by `diff` command. - * - * @param string $diff - * @param string $from - * @param string $to - * - * @dataProvider provideBasicDiffGeneration - */ - public function testIntegrationDiffOutputBuilderVersusDiffCommand(string $diff, string $from, string $to): void - { - $this->assertNotSame('', $diff); - $this->assertValidUnifiedDiffFormat($diff); - - $this->assertNotFalse(\file_put_contents($this->fileFrom, $from)); - $this->assertNotFalse(\file_put_contents($this->fileTo, $to)); - - $p = new Process(\sprintf('diff -u %s %s', \escapeshellarg($this->fileFrom), \escapeshellarg($this->fileTo))); - $p->run(); - $this->assertSame(1, $p->getExitCode()); // note: Process assumes exit code 0 for `isSuccessful`, however `diff` uses the exit code `1` for success with diff - - $output = $p->getOutput(); - - $diffLines = \preg_split('/(.*\R)/', $diff, -1, PREG_SPLIT_DELIM_CAPTURE | PREG_SPLIT_NO_EMPTY); - $diffLines[0] = \preg_replace('#^\-\-\- .*#', '--- /' . $this->fileFrom, $diffLines[0], 1); - $diffLines[1] = \preg_replace('#^\+\+\+ .*#', '+++ /' . $this->fileFrom, $diffLines[1], 1); - $diff = \implode('', $diffLines); - - $outputLines = \preg_split('/(.*\R)/', $output, -1, PREG_SPLIT_DELIM_CAPTURE | PREG_SPLIT_NO_EMPTY); - $outputLines[0] = \preg_replace('#^\-\-\- .*#', '--- /' . $this->fileFrom, $outputLines[0], 1); - $outputLines[1] = \preg_replace('#^\+\+\+ .*#', '+++ /' . $this->fileFrom, $outputLines[1], 1); - $output = \implode('', $outputLines); - - $this->assertSame($diff, $output); - } - - private function doIntegrationTestGitApply(string $diff, string $from, string $to): void - { - $this->assertNotSame('', $diff); - $this->assertValidUnifiedDiffFormat($diff); - - $diff = self::setDiffFileHeader($diff, $this->fileFrom); - - $this->assertNotFalse(\file_put_contents($this->fileFrom, $from)); - $this->assertNotFalse(\file_put_contents($this->filePatch, $diff)); - - $p = new Process(\sprintf( - 'git --git-dir %s apply --check -v --unsafe-paths --ignore-whitespace %s', - \escapeshellarg($this->dir), - \escapeshellarg($this->filePatch) - )); - - $p->run(); - - $this->assertProcessSuccessful($p); - } - - private function doIntegrationTestPatch(string $diff, string $from, string $to): void - { - $this->assertNotSame('', $diff); - $this->assertValidUnifiedDiffFormat($diff); - - $diff = self::setDiffFileHeader($diff, $this->fileFrom); - - $this->assertNotFalse(\file_put_contents($this->fileFrom, $from)); - $this->assertNotFalse(\file_put_contents($this->filePatch, $diff)); - - $command = \sprintf( - 'patch -u --verbose --posix %s < %s', - \escapeshellarg($this->fileFrom), - \escapeshellarg($this->filePatch) - ); - - $p = new Process($command); - $p->run(); - - $this->assertProcessSuccessful($p); - - $this->assertStringEqualsFile( - $this->fileFrom, - $to, - \sprintf('Patch command "%s".', $command) - ); - } - - private function assertProcessSuccessful(Process $p): void - { - $this->assertTrue( - $p->isSuccessful(), - \sprintf( - "Command exec. was not successful:\n\"%s\"\nOutput:\n\"%s\"\nStdErr:\n\"%s\"\nExit code %d.\n", - $p->getCommandLine(), - $p->getOutput(), - $p->getErrorOutput(), - $p->getExitCode() - ) - ); - } - - private function cleanUpTempFiles(): void - { - @\unlink($this->fileFrom . '.orig'); - @\unlink($this->fileFrom . '.rej'); - @\unlink($this->fileFrom); - @\unlink($this->fileTo); - @\unlink($this->filePatch); - } - - private static function setDiffFileHeader(string $diff, string $file): string - { - $diffLines = \preg_split('/(.*\R)/', $diff, -1, PREG_SPLIT_DELIM_CAPTURE | PREG_SPLIT_NO_EMPTY); - $diffLines[0] = \preg_replace('#^\-\-\- .*#', '--- /' . $file, $diffLines[0], 1); - $diffLines[1] = \preg_replace('#^\+\+\+ .*#', '+++ /' . $file, $diffLines[1], 1); - - return \implode('', $diffLines); - } -} diff --git a/vendor/sebastian/diff/tests/Output/Integration/UnifiedDiffOutputBuilderIntegrationTest.php b/vendor/sebastian/diff/tests/Output/Integration/UnifiedDiffOutputBuilderIntegrationTest.php deleted file mode 100644 index c3fe0575b..000000000 --- a/vendor/sebastian/diff/tests/Output/Integration/UnifiedDiffOutputBuilderIntegrationTest.php +++ /dev/null @@ -1,163 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff\Output; - -use PHPUnit\Framework\TestCase; -use SebastianBergmann\Diff\Utils\UnifiedDiffAssertTrait; -use Symfony\Component\Process\Process; - -/** - * @covers SebastianBergmann\Diff\Output\UnifiedDiffOutputBuilder - * - * @uses SebastianBergmann\Diff\Differ - * @uses SebastianBergmann\Diff\TimeEfficientLongestCommonSubsequenceCalculator - * - * @requires OS Linux - */ -final class UnifiedDiffOutputBuilderIntegrationTest extends TestCase -{ - use UnifiedDiffAssertTrait; - - private $dir; - - private $fileFrom; - - private $filePatch; - - protected function setUp(): void - { - $this->dir = \realpath(__DIR__ . '/../../fixtures/out/') . '/'; - $this->fileFrom = $this->dir . 'from.txt'; - $this->filePatch = $this->dir . 'patch.txt'; - - $this->cleanUpTempFiles(); - } - - protected function tearDown(): void - { - $this->cleanUpTempFiles(); - } - - /** - * @dataProvider provideDiffWithLineNumbers - * - * @param mixed $expected - * @param mixed $from - * @param mixed $to - */ - public function testDiffWithLineNumbersPath($expected, $from, $to): void - { - $this->doIntegrationTestPatch($expected, $from, $to); - } - - /** - * @dataProvider provideDiffWithLineNumbers - * - * @param mixed $expected - * @param mixed $from - * @param mixed $to - */ - public function testDiffWithLineNumbersGitApply($expected, $from, $to): void - { - $this->doIntegrationTestGitApply($expected, $from, $to); - } - - public function provideDiffWithLineNumbers() - { - return \array_filter( - UnifiedDiffOutputBuilderDataProvider::provideDiffWithLineNumbers(), - static function ($key) { - return !\is_string($key) || false === \strpos($key, 'non_patch_compat'); - }, - ARRAY_FILTER_USE_KEY - ); - } - - private function doIntegrationTestPatch(string $diff, string $from, string $to): void - { - $this->assertNotSame('', $diff); - $this->assertValidUnifiedDiffFormat($diff); - - $diff = self::setDiffFileHeader($diff, $this->fileFrom); - - $this->assertNotFalse(\file_put_contents($this->fileFrom, $from)); - $this->assertNotFalse(\file_put_contents($this->filePatch, $diff)); - - $command = \sprintf( - 'patch -u --verbose --posix %s < %s', // --posix - \escapeshellarg($this->fileFrom), - \escapeshellarg($this->filePatch) - ); - - $p = new Process($command); - $p->run(); - - $this->assertProcessSuccessful($p); - - $this->assertStringEqualsFile( - $this->fileFrom, - $to, - \sprintf('Patch command "%s".', $command) - ); - } - - private function doIntegrationTestGitApply(string $diff, string $from, string $to): void - { - $this->assertNotSame('', $diff); - $this->assertValidUnifiedDiffFormat($diff); - - $diff = self::setDiffFileHeader($diff, $this->fileFrom); - - $this->assertNotFalse(\file_put_contents($this->fileFrom, $from)); - $this->assertNotFalse(\file_put_contents($this->filePatch, $diff)); - - $command = \sprintf( - 'git --git-dir %s apply --check -v --unsafe-paths --ignore-whitespace %s', - \escapeshellarg($this->dir), - \escapeshellarg($this->filePatch) - ); - - $p = new Process($command); - $p->run(); - - $this->assertProcessSuccessful($p); - } - - private function assertProcessSuccessful(Process $p): void - { - $this->assertTrue( - $p->isSuccessful(), - \sprintf( - "Command exec. was not successful:\n\"%s\"\nOutput:\n\"%s\"\nStdErr:\n\"%s\"\nExit code %d.\n", - $p->getCommandLine(), - $p->getOutput(), - $p->getErrorOutput(), - $p->getExitCode() - ) - ); - } - - private function cleanUpTempFiles(): void - { - @\unlink($this->fileFrom . '.orig'); - @\unlink($this->fileFrom); - @\unlink($this->filePatch); - } - - private static function setDiffFileHeader(string $diff, string $file): string - { - $diffLines = \preg_split('/(.*\R)/', $diff, -1, PREG_SPLIT_DELIM_CAPTURE | PREG_SPLIT_NO_EMPTY); - $diffLines[0] = \preg_replace('#^\-\-\- .*#', '--- /' . $file, $diffLines[0], 1); - $diffLines[1] = \preg_replace('#^\+\+\+ .*#', '+++ /' . $file, $diffLines[1], 1); - - return \implode('', $diffLines); - } -} diff --git a/vendor/sebastian/diff/tests/Output/StrictUnifiedDiffOutputBuilderDataProvider.php b/vendor/sebastian/diff/tests/Output/StrictUnifiedDiffOutputBuilderDataProvider.php deleted file mode 100644 index 56d3a1e24..000000000 --- a/vendor/sebastian/diff/tests/Output/StrictUnifiedDiffOutputBuilderDataProvider.php +++ /dev/null @@ -1,189 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff\Output; - -final class StrictUnifiedDiffOutputBuilderDataProvider -{ - public static function provideOutputBuildingCases(): array - { - return [ - [ -'--- input.txt -+++ output.txt -@@ -1,3 +1,4 @@ -+b - ' . ' - ' . ' - ' . ' -@@ -16,5 +17,4 @@ - ' . ' - ' . ' - ' . ' -- --B -+A -', - "\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nB\n", - "b\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nA\n", - [ - 'fromFile' => 'input.txt', - 'toFile' => 'output.txt', - ], - ], - [ -'--- ' . __FILE__ . "\t2017-10-02 17:38:11.586413675 +0100 -+++ output1.txt\t2017-10-03 12:09:43.086719482 +0100 -@@ -1,1 +1,1 @@ --B -+X -", - "B\n", - "X\n", - [ - 'fromFile' => __FILE__, - 'fromFileDate' => '2017-10-02 17:38:11.586413675 +0100', - 'toFile' => 'output1.txt', - 'toFileDate' => '2017-10-03 12:09:43.086719482 +0100', - 'collapseRanges' => false, - ], - ], - [ -'--- input.txt -+++ output.txt -@@ -1 +1 @@ --B -+X -', - "B\n", - "X\n", - [ - 'fromFile' => 'input.txt', - 'toFile' => 'output.txt', - 'collapseRanges' => true, - ], - ], - ]; - } - - public static function provideSample(): array - { - return [ - [ -'--- input.txt -+++ output.txt -@@ -1,6 +1,6 @@ - 1 - 2 - 3 --4 -+X - 5 - 6 -', - "1\n2\n3\n4\n5\n6\n", - "1\n2\n3\nX\n5\n6\n", - [ - 'fromFile' => 'input.txt', - 'toFile' => 'output.txt', - ], - ], - ]; - } - - public static function provideBasicDiffGeneration(): array - { - return [ - [ -"--- input.txt -+++ output.txt -@@ -1,2 +1 @@ --A --B -+A\rB -", - "A\nB\n", - "A\rB\n", - ], - [ -"--- input.txt -+++ output.txt -@@ -1 +1 @@ -- -+\r -\\ No newline at end of file -", - "\n", - "\r", - ], - [ -"--- input.txt -+++ output.txt -@@ -1 +1 @@ --\r -\\ No newline at end of file -+ -", - "\r", - "\n", - ], - [ -'--- input.txt -+++ output.txt -@@ -1,3 +1,3 @@ - X - A --A -+B -', - "X\nA\nA\n", - "X\nA\nB\n", - ], - [ -'--- input.txt -+++ output.txt -@@ -1,3 +1,3 @@ - X - A --A -\ No newline at end of file -+B -', - "X\nA\nA", - "X\nA\nB\n", - ], - [ -'--- input.txt -+++ output.txt -@@ -1,3 +1,3 @@ - A - A --A -+B -\ No newline at end of file -', - "A\nA\nA\n", - "A\nA\nB", - ], - [ -'--- input.txt -+++ output.txt -@@ -1 +1 @@ --A -\ No newline at end of file -+B -\ No newline at end of file -', - 'A', - 'B', - ], - ]; - } -} diff --git a/vendor/sebastian/diff/tests/Output/StrictUnifiedDiffOutputBuilderTest.php b/vendor/sebastian/diff/tests/Output/StrictUnifiedDiffOutputBuilderTest.php deleted file mode 100644 index 64cb25b2c..000000000 --- a/vendor/sebastian/diff/tests/Output/StrictUnifiedDiffOutputBuilderTest.php +++ /dev/null @@ -1,684 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff\Output; - -use PHPUnit\Framework\TestCase; -use SebastianBergmann\Diff\ConfigurationException; -use SebastianBergmann\Diff\Differ; -use SebastianBergmann\Diff\Utils\UnifiedDiffAssertTrait; - -/** - * @covers SebastianBergmann\Diff\Output\StrictUnifiedDiffOutputBuilder - * - * @uses SebastianBergmann\Diff\Differ - */ -final class StrictUnifiedDiffOutputBuilderTest extends TestCase -{ - use UnifiedDiffAssertTrait; - - /** - * @param string $expected - * @param string $from - * @param string $to - * @param array $options - * - * @dataProvider provideOutputBuildingCases - */ - public function testOutputBuilding(string $expected, string $from, string $to, array $options): void - { - $diff = $this->getDiffer($options)->diff($from, $to); - - $this->assertValidDiffFormat($diff); - $this->assertSame($expected, $diff); - } - - /** - * @param string $expected - * @param string $from - * @param string $to - * @param array $options - * - * @dataProvider provideSample - */ - public function testSample(string $expected, string $from, string $to, array $options): void - { - $diff = $this->getDiffer($options)->diff($from, $to); - - $this->assertValidDiffFormat($diff); - $this->assertSame($expected, $diff); - } - - /** - * {@inheritdoc} - */ - public function assertValidDiffFormat(string $diff): void - { - $this->assertValidUnifiedDiffFormat($diff); - } - - /** - * {@inheritdoc} - */ - public function provideOutputBuildingCases(): array - { - return StrictUnifiedDiffOutputBuilderDataProvider::provideOutputBuildingCases(); - } - - /** - * {@inheritdoc} - */ - public function provideSample(): array - { - return StrictUnifiedDiffOutputBuilderDataProvider::provideSample(); - } - - /** - * @param string $expected - * @param string $from - * @param string $to - * - * @dataProvider provideBasicDiffGeneration - */ - public function testBasicDiffGeneration(string $expected, string $from, string $to): void - { - $diff = $this->getDiffer([ - 'fromFile' => 'input.txt', - 'toFile' => 'output.txt', - ])->diff($from, $to); - - $this->assertValidDiffFormat($diff); - $this->assertSame($expected, $diff); - } - - public function provideBasicDiffGeneration(): array - { - return StrictUnifiedDiffOutputBuilderDataProvider::provideBasicDiffGeneration(); - } - - /** - * @param string $expected - * @param string $from - * @param string $to - * @param array $config - * - * @dataProvider provideConfiguredDiffGeneration - */ - public function testConfiguredDiffGeneration(string $expected, string $from, string $to, array $config = []): void - { - $diff = $this->getDiffer(\array_merge([ - 'fromFile' => 'input.txt', - 'toFile' => 'output.txt', - ], $config))->diff($from, $to); - - $this->assertValidDiffFormat($diff); - $this->assertSame($expected, $diff); - } - - public function provideConfiguredDiffGeneration(): array - { - return [ - [ - '--- input.txt -+++ output.txt -@@ -1 +1 @@ --a -\ No newline at end of file -+b -\ No newline at end of file -', - 'a', - 'b', - ], - [ - '', - "1\n2", - "1\n2", - ], - [ - '', - "1\n", - "1\n", - ], - [ -'--- input.txt -+++ output.txt -@@ -4 +4 @@ --X -+4 -', - "1\n2\n3\nX\n5\n6\n7\n8\n9\n0\n", - "1\n2\n3\n4\n5\n6\n7\n8\n9\n0\n", - [ - 'contextLines' => 0, - ], - ], - [ -'--- input.txt -+++ output.txt -@@ -3,3 +3,3 @@ - 3 --X -+4 - 5 -', - "1\n2\n3\nX\n5\n6\n7\n8\n9\n0\n", - "1\n2\n3\n4\n5\n6\n7\n8\n9\n0\n", - [ - 'contextLines' => 1, - ], - ], - [ -'--- input.txt -+++ output.txt -@@ -1,10 +1,10 @@ - 1 - 2 - 3 --X -+4 - 5 - 6 - 7 - 8 - 9 - 0 -', - "1\n2\n3\nX\n5\n6\n7\n8\n9\n0\n", - "1\n2\n3\n4\n5\n6\n7\n8\n9\n0\n", - [ - 'contextLines' => 999, - ], - ], - [ -'--- input.txt -+++ output.txt -@@ -1,0 +1,2 @@ -+ -+A -', - '', - "\nA\n", - ], - [ -'--- input.txt -+++ output.txt -@@ -1,2 +1,0 @@ -- --A -', - "\nA\n", - '', - ], - [ - '--- input.txt -+++ output.txt -@@ -1,5 +1,5 @@ - 1 --X -+2 - 3 --Y -+4 - 5 -@@ -8,3 +8,3 @@ - 8 --X -+9 - 0 -', - "1\nX\n3\nY\n5\n6\n7\n8\nX\n0\n", - "1\n2\n3\n4\n5\n6\n7\n8\n9\n0\n", - [ - 'commonLineThreshold' => 2, - 'contextLines' => 1, - ], - ], - [ - '--- input.txt -+++ output.txt -@@ -2 +2 @@ --X -+2 -@@ -4 +4 @@ --Y -+4 -@@ -9 +9 @@ --X -+9 -', - "1\nX\n3\nY\n5\n6\n7\n8\nX\n0\n", - "1\n2\n3\n4\n5\n6\n7\n8\n9\n0\n", - [ - 'commonLineThreshold' => 1, - 'contextLines' => 0, - ], - ], - ]; - } - - public function testReUseBuilder(): void - { - $differ = $this->getDiffer([ - 'fromFile' => 'input.txt', - 'toFile' => 'output.txt', - ]); - - $diff = $differ->diff("A\nB\n", "A\nX\n"); - $this->assertSame( -'--- input.txt -+++ output.txt -@@ -1,2 +1,2 @@ - A --B -+X -', - $diff - ); - - $diff = $differ->diff("A\n", "A\n"); - $this->assertSame( - '', - $diff - ); - } - - public function testEmptyDiff(): void - { - $builder = new StrictUnifiedDiffOutputBuilder([ - 'fromFile' => 'input.txt', - 'toFile' => 'output.txt', - ]); - - $this->assertSame( - '', - $builder->getDiff([]) - ); - } - - /** - * @param array $options - * @param string $message - * - * @dataProvider provideInvalidConfiguration - */ - public function testInvalidConfiguration(array $options, string $message): void - { - $this->expectException(ConfigurationException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote($message, '#'))); - - new StrictUnifiedDiffOutputBuilder($options); - } - - public function provideInvalidConfiguration(): array - { - $time = \time(); - - return [ - [ - ['collapseRanges' => 1], - 'Option "collapseRanges" must be a bool, got "integer#1".', - ], - [ - ['contextLines' => 'a'], - 'Option "contextLines" must be an int >= 0, got "string#a".', - ], - [ - ['commonLineThreshold' => -2], - 'Option "commonLineThreshold" must be an int > 0, got "integer#-2".', - ], - [ - ['commonLineThreshold' => 0], - 'Option "commonLineThreshold" must be an int > 0, got "integer#0".', - ], - [ - ['fromFile' => new \SplFileInfo(__FILE__)], - 'Option "fromFile" must be a string, got "SplFileInfo".', - ], - [ - ['fromFile' => null], - 'Option "fromFile" must be a string, got "".', - ], - [ - [ - 'fromFile' => __FILE__, - 'toFile' => 1, - ], - 'Option "toFile" must be a string, got "integer#1".', - ], - [ - [ - 'fromFile' => __FILE__, - 'toFile' => __FILE__, - 'toFileDate' => $time, - ], - 'Option "toFileDate" must be a string or , got "integer#' . $time . '".', - ], - [ - [], - 'Option "fromFile" must be a string, got "".', - ], - ]; - } - - /** - * @param string $expected - * @param string $from - * @param string $to - * @param int $threshold - * - * @dataProvider provideCommonLineThresholdCases - */ - public function testCommonLineThreshold(string $expected, string $from, string $to, int $threshold): void - { - $diff = $this->getDiffer([ - 'fromFile' => 'input.txt', - 'toFile' => 'output.txt', - 'commonLineThreshold' => $threshold, - 'contextLines' => 0, - ])->diff($from, $to); - - $this->assertValidDiffFormat($diff); - $this->assertSame($expected, $diff); - } - - public function provideCommonLineThresholdCases(): array - { - return [ - [ -'--- input.txt -+++ output.txt -@@ -2,3 +2,3 @@ --X -+B - C12 --Y -+D -@@ -7 +7 @@ --X -+Z -', - "A\nX\nC12\nY\nA\nA\nX\n", - "A\nB\nC12\nD\nA\nA\nZ\n", - 2, - ], - [ -'--- input.txt -+++ output.txt -@@ -2 +2 @@ --X -+B -@@ -4 +4 @@ --Y -+D -', - "A\nX\nV\nY\n", - "A\nB\nV\nD\n", - 1, - ], - ]; - } - - /** - * @param string $expected - * @param string $from - * @param string $to - * @param int $contextLines - * @param int $commonLineThreshold - * - * @dataProvider provideContextLineConfigurationCases - */ - public function testContextLineConfiguration(string $expected, string $from, string $to, int $contextLines, int $commonLineThreshold = 6): void - { - $diff = $this->getDiffer([ - 'fromFile' => 'input.txt', - 'toFile' => 'output.txt', - 'contextLines' => $contextLines, - 'commonLineThreshold' => $commonLineThreshold, - ])->diff($from, $to); - - $this->assertValidDiffFormat($diff); - $this->assertSame($expected, $diff); - } - - public function provideContextLineConfigurationCases(): array - { - $from = "A\nB\nC\nD\nE\nF\nX\nG\nH\nI\nJ\nK\nL\nM\n"; - $to = "A\nB\nC\nD\nE\nF\nY\nG\nH\nI\nJ\nK\nL\nM\n"; - - return [ - 'EOF 0' => [ - "--- input.txt\n+++ output.txt\n@@ -3 +3 @@ --X -\\ No newline at end of file -+Y -\\ No newline at end of file -", - "A\nB\nX", - "A\nB\nY", - 0, - ], - 'EOF 1' => [ - "--- input.txt\n+++ output.txt\n@@ -2,2 +2,2 @@ - B --X -\\ No newline at end of file -+Y -\\ No newline at end of file -", - "A\nB\nX", - "A\nB\nY", - 1, -], - 'EOF 2' => [ - "--- input.txt\n+++ output.txt\n@@ -1,3 +1,3 @@ - A - B --X -\\ No newline at end of file -+Y -\\ No newline at end of file -", - "A\nB\nX", - "A\nB\nY", - 2, - ], - 'EOF 200' => [ - "--- input.txt\n+++ output.txt\n@@ -1,3 +1,3 @@ - A - B --X -\\ No newline at end of file -+Y -\\ No newline at end of file -", - "A\nB\nX", - "A\nB\nY", - 200, - ], - 'n/a 0' => [ - "--- input.txt\n+++ output.txt\n@@ -7 +7 @@\n-X\n+Y\n", - $from, - $to, - 0, - ], - 'G' => [ - "--- input.txt\n+++ output.txt\n@@ -6,3 +6,3 @@\n F\n-X\n+Y\n G\n", - $from, - $to, - 1, - ], - 'H' => [ - "--- input.txt\n+++ output.txt\n@@ -5,5 +5,5 @@\n E\n F\n-X\n+Y\n G\n H\n", - $from, - $to, - 2, - ], - 'I' => [ - "--- input.txt\n+++ output.txt\n@@ -4,7 +4,7 @@\n D\n E\n F\n-X\n+Y\n G\n H\n I\n", - $from, - $to, - 3, - ], - 'J' => [ - "--- input.txt\n+++ output.txt\n@@ -3,9 +3,9 @@\n C\n D\n E\n F\n-X\n+Y\n G\n H\n I\n J\n", - $from, - $to, - 4, - ], - 'K' => [ - "--- input.txt\n+++ output.txt\n@@ -2,11 +2,11 @@\n B\n C\n D\n E\n F\n-X\n+Y\n G\n H\n I\n J\n K\n", - $from, - $to, - 5, - ], - 'L' => [ - "--- input.txt\n+++ output.txt\n@@ -1,13 +1,13 @@\n A\n B\n C\n D\n E\n F\n-X\n+Y\n G\n H\n I\n J\n K\n L\n", - $from, - $to, - 6, - ], - 'M' => [ - "--- input.txt\n+++ output.txt\n@@ -1,14 +1,14 @@\n A\n B\n C\n D\n E\n F\n-X\n+Y\n G\n H\n I\n J\n K\n L\n M\n", - $from, - $to, - 7, - ], - 'M no linebreak EOF .1' => [ - "--- input.txt\n+++ output.txt\n@@ -1,14 +1,14 @@\n A\n B\n C\n D\n E\n F\n-X\n+Y\n G\n H\n I\n J\n K\n L\n-M\n+M\n\\ No newline at end of file\n", - $from, - \substr($to, 0, -1), - 7, - ], - 'M no linebreak EOF .2' => [ - "--- input.txt\n+++ output.txt\n@@ -1,14 +1,14 @@\n A\n B\n C\n D\n E\n F\n-X\n+Y\n G\n H\n I\n J\n K\n L\n-M\n\\ No newline at end of file\n+M\n", - \substr($from, 0, -1), - $to, - 7, - ], - 'M no linebreak EOF .3' => [ - "--- input.txt\n+++ output.txt\n@@ -1,14 +1,14 @@\n A\n B\n C\n D\n E\n F\n-X\n+Y\n G\n H\n I\n J\n K\n L\n M\n", - \substr($from, 0, -1), - \substr($to, 0, -1), - 7, - ], - 'M no linebreak EOF .4' => [ - "--- input.txt\n+++ output.txt\n@@ -1,14 +1,14 @@\n A\n B\n C\n D\n E\n F\n-X\n+Y\n G\n H\n I\n J\n K\n L\n M\n\\ No newline at end of file\n", - \substr($from, 0, -1), - \substr($to, 0, -1), - 10000, - 10000, - ], - 'M+1' => [ - "--- input.txt\n+++ output.txt\n@@ -1,14 +1,14 @@\n A\n B\n C\n D\n E\n F\n-X\n+Y\n G\n H\n I\n J\n K\n L\n M\n", - $from, - $to, - 8, - ], - 'M+100' => [ - "--- input.txt\n+++ output.txt\n@@ -1,14 +1,14 @@\n A\n B\n C\n D\n E\n F\n-X\n+Y\n G\n H\n I\n J\n K\n L\n M\n", - $from, - $to, - 107, - ], - '0 II' => [ - "--- input.txt\n+++ output.txt\n@@ -12 +12 @@\n-X\n+Y\n", - "A\nB\nC\nD\nE\nF\nG\nH\nI\nJ\nK\nX\nM\n", - "A\nB\nC\nD\nE\nF\nG\nH\nI\nJ\nK\nY\nM\n", - 0, - 999, - ], - '0\' II' => [ - "--- input.txt\n+++ output.txt\n@@ -12 +12 @@\n-X\n+Y\n", - "A\nB\nC\nD\nE\nF\nG\nH\nI\nJ\nK\nX\nM\nA\nA\nA\nA\nA\n", - "A\nB\nC\nD\nE\nF\nG\nH\nI\nJ\nK\nY\nM\nA\nA\nA\nA\nA\n", - 0, - 999, - ], - '0\'\' II' => [ - "--- input.txt\n+++ output.txt\n@@ -12,2 +12,2 @@\n-X\n-M\n\\ No newline at end of file\n+Y\n+M\n", - "A\nB\nC\nD\nE\nF\nG\nH\nI\nJ\nK\nX\nM", - "A\nB\nC\nD\nE\nF\nG\nH\nI\nJ\nK\nY\nM\n", - 0, - ], - '0\'\'\' II' => [ - "--- input.txt\n+++ output.txt\n@@ -12,2 +12,2 @@\n-X\n-X1\n+Y\n+Y2\n", - "A\nB\nC\nD\nE\nF\nG\nH\nI\nJ\nK\nX\nX1\nM\nA\nA\nA\nA\nA\n", - "A\nB\nC\nD\nE\nF\nG\nH\nI\nJ\nK\nY\nY2\nM\nA\nA\nA\nA\nA\n", - 0, - 999, - ], - '1 II' => [ - "--- input.txt\n+++ output.txt\n@@ -11,3 +11,3 @@\n K\n-X\n+Y\n M\n", - "A\nB\nC\nD\nE\nF\nG\nH\nI\nJ\nK\nX\nM\n", - "A\nB\nC\nD\nE\nF\nG\nH\nI\nJ\nK\nY\nM\n", - 1, - ], - '5 II' => [ - "--- input.txt\n+++ output.txt\n@@ -7,7 +7,7 @@\n G\n H\n I\n J\n K\n-X\n+Y\n M\n", - "A\nB\nC\nD\nE\nF\nG\nH\nI\nJ\nK\nX\nM\n", - "A\nB\nC\nD\nE\nF\nG\nH\nI\nJ\nK\nY\nM\n", - 5, - ], - [ - '--- input.txt -+++ output.txt -@@ -1,28 +1,28 @@ - A --X -+B - V --Y -+D - 1 - A - 2 - A - 3 - A - 4 - A - 8 - A - 9 - A - 5 - A - A - A - A - A - A - A - A - A - A - A -', - "A\nX\nV\nY\n1\nA\n2\nA\n3\nA\n4\nA\n8\nA\n9\nA\n5\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n", - "A\nB\nV\nD\n1\nA\n2\nA\n3\nA\n4\nA\n8\nA\n9\nA\n5\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\nA\n", - 9999, - 99999, - ], - ]; - } - - /** - * Returns a new instance of a Differ with a new instance of the class (DiffOutputBuilderInterface) under test. - * - * @param array $options - * - * @return Differ - */ - private function getDiffer(array $options = []): Differ - { - return new Differ(new StrictUnifiedDiffOutputBuilder($options)); - } -} diff --git a/vendor/sebastian/diff/tests/Output/UnifiedDiffOutputBuilderDataProvider.php b/vendor/sebastian/diff/tests/Output/UnifiedDiffOutputBuilderDataProvider.php deleted file mode 100644 index 391a9b151..000000000 --- a/vendor/sebastian/diff/tests/Output/UnifiedDiffOutputBuilderDataProvider.php +++ /dev/null @@ -1,396 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff\Output; - -final class UnifiedDiffOutputBuilderDataProvider -{ - public static function provideDiffWithLineNumbers(): array - { - return [ - 'diff line 1 non_patch_compat' => [ -'--- Original -+++ New -@@ -1 +1 @@ --AA -+BA -', - 'AA', - 'BA', - ], - 'diff line +1 non_patch_compat' => [ -'--- Original -+++ New -@@ -1 +1,2 @@ --AZ -+ -+B -', - 'AZ', - "\nB", - ], - 'diff line -1 non_patch_compat' => [ -'--- Original -+++ New -@@ -1,2 +1 @@ -- --AF -+B -', - "\nAF", - 'B', - ], - 'II non_patch_compat' => [ -'--- Original -+++ New -@@ -1,4 +1,2 @@ -- -- - A - 1 -', - "\n\nA\n1", - "A\n1", - ], - 'diff last line II - no trailing linebreak non_patch_compat' => [ -'--- Original -+++ New -@@ -5,4 +5,4 @@ - ' . ' - ' . ' - ' . ' --E -+B -', - "A\n\n\n\n\n\n\nE", - "A\n\n\n\n\n\n\nB", - ], - [ - "--- Original\n+++ New\n@@ -1,2 +1 @@\n \n-\n", - "\n\n", - "\n", - ], - 'diff line endings non_patch_compat' => [ - "--- Original\n+++ New\n@@ -1 +1 @@\n #Warning: Strings contain different line endings!\n- [ -'--- Original -+++ New -', - "AT\n", - "AT\n", - ], - [ -'--- Original -+++ New -@@ -1,4 +1,4 @@ --b -+a - ' . ' - ' . ' - ' . ' -', - "b\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n", - "a\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n", - ], - 'diff line @1' => [ -'--- Original -+++ New -@@ -1,2 +1,2 @@ - ' . ' --AG -+B -', - "\nAG\n", - "\nB\n", - ], - 'same multiple lines' => [ -'--- Original -+++ New -@@ -1,4 +1,4 @@ - ' . ' - ' . ' --V -+B - C213 -', - "\n\nV\nC213", - "\n\nB\nC213", - ], - 'diff last line I' => [ -'--- Original -+++ New -@@ -5,4 +5,4 @@ - ' . ' - ' . ' - ' . ' --E -+B -', - "A\n\n\n\n\n\n\nE\n", - "A\n\n\n\n\n\n\nB\n", - ], - 'diff line middle' => [ -'--- Original -+++ New -@@ -5,7 +5,7 @@ - ' . ' - ' . ' - ' . ' --X -+Z - ' . ' - ' . ' - ' . ' -', - "A\n\n\n\n\n\n\nX\n\n\n\n\n\n\nAY", - "A\n\n\n\n\n\n\nZ\n\n\n\n\n\n\nAY", - ], - 'diff last line III' => [ -'--- Original -+++ New -@@ -12,4 +12,4 @@ - ' . ' - ' . ' - ' . ' --A -+B -', - "A\n\n\n\n\n\n\nA\n\n\n\n\n\n\nA\n", - "A\n\n\n\n\n\n\nA\n\n\n\n\n\n\nB\n", - ], - [ -'--- Original -+++ New -@@ -1,8 +1,8 @@ - A --B -+B1 - D - E - EE - F --G -+G1 - H -', - "A\nB\nD\nE\nEE\nF\nG\nH", - "A\nB1\nD\nE\nEE\nF\nG1\nH", - ], - [ -'--- Original -+++ New -@@ -1,4 +1,5 @@ - Z -+ - a - b - c -@@ -7,5 +8,5 @@ - f - g - h --i -+x - j -', -'Z -a -b -c -d -e -f -g -h -i -j -', -'Z - -a -b -c -d -e -f -g -h -x -j -', - ], - [ -'--- Original -+++ New -@@ -1,7 +1,5 @@ -- --a -+b - A --X -- -+Y - ' . ' - A -', - "\na\nA\nX\n\n\nA\n", - "b\nA\nY\n\nA\n", - ], - [ -<< - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff\Output; - -use PHPUnit\Framework\TestCase; -use SebastianBergmann\Diff\Differ; - -/** - * @covers SebastianBergmann\Diff\Output\UnifiedDiffOutputBuilder - * - * @uses SebastianBergmann\Diff\Differ - * @uses SebastianBergmann\Diff\Output\AbstractChunkOutputBuilder - * @uses SebastianBergmann\Diff\TimeEfficientLongestCommonSubsequenceCalculator - */ -final class UnifiedDiffOutputBuilderTest extends TestCase -{ - /** - * @param string $expected - * @param string $from - * @param string $to - * @param string $header - * - * @dataProvider headerProvider - */ - public function testCustomHeaderCanBeUsed(string $expected, string $from, string $to, string $header): void - { - $differ = new Differ(new UnifiedDiffOutputBuilder($header)); - - $this->assertSame( - $expected, - $differ->diff($from, $to) - ); - } - - public function headerProvider(): array - { - return [ - [ - "CUSTOM HEADER\n@@ @@\n-a\n+b\n", - 'a', - 'b', - 'CUSTOM HEADER', - ], - [ - "CUSTOM HEADER\n@@ @@\n-a\n+b\n", - 'a', - 'b', - "CUSTOM HEADER\n", - ], - [ - "CUSTOM HEADER\n\n@@ @@\n-a\n+b\n", - 'a', - 'b', - "CUSTOM HEADER\n\n", - ], - [ - "@@ @@\n-a\n+b\n", - 'a', - 'b', - '', - ], - ]; - } - - /** - * @param string $expected - * @param string $from - * @param string $to - * - * @dataProvider provideDiffWithLineNumbers - */ - public function testDiffWithLineNumbers($expected, $from, $to): void - { - $differ = new Differ(new UnifiedDiffOutputBuilder("--- Original\n+++ New\n", true)); - $this->assertSame($expected, $differ->diff($from, $to)); - } - - public function provideDiffWithLineNumbers(): array - { - return UnifiedDiffOutputBuilderDataProvider::provideDiffWithLineNumbers(); - } -} diff --git a/vendor/sebastian/diff/tests/ParserTest.php b/vendor/sebastian/diff/tests/ParserTest.php deleted file mode 100644 index 69bf4644a..000000000 --- a/vendor/sebastian/diff/tests/ParserTest.php +++ /dev/null @@ -1,170 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff; - -use PHPUnit\Framework\TestCase; -use SebastianBergmann\Diff\Utils\FileUtils; - -/** - * @covers SebastianBergmann\Diff\Parser - * - * @uses SebastianBergmann\Diff\Chunk - * @uses SebastianBergmann\Diff\Diff - * @uses SebastianBergmann\Diff\Line - */ -final class ParserTest extends TestCase -{ - /** - * @var Parser - */ - private $parser; - - protected function setUp(): void - { - $this->parser = new Parser; - } - - public function testParse(): void - { - $content = FileUtils::getFileContent(__DIR__ . '/fixtures/patch.txt'); - - $diffs = $this->parser->parse($content); - - $this->assertContainsOnlyInstancesOf(Diff::class, $diffs); - $this->assertCount(1, $diffs); - - $chunks = $diffs[0]->getChunks(); - $this->assertContainsOnlyInstancesOf(Chunk::class, $chunks); - - $this->assertCount(1, $chunks); - - $this->assertSame(20, $chunks[0]->getStart()); - - $this->assertCount(4, $chunks[0]->getLines()); - } - - public function testParseWithMultipleChunks(): void - { - $content = FileUtils::getFileContent(__DIR__ . '/fixtures/patch2.txt'); - - $diffs = $this->parser->parse($content); - - $this->assertCount(1, $diffs); - - $chunks = $diffs[0]->getChunks(); - $this->assertCount(3, $chunks); - - $this->assertSame(20, $chunks[0]->getStart()); - $this->assertSame(320, $chunks[1]->getStart()); - $this->assertSame(600, $chunks[2]->getStart()); - - $this->assertCount(5, $chunks[0]->getLines()); - $this->assertCount(5, $chunks[1]->getLines()); - $this->assertCount(4, $chunks[2]->getLines()); - } - - public function testParseWithRemovedLines(): void - { - $content = <<parser->parse($content); - $this->assertContainsOnlyInstancesOf(Diff::class, $diffs); - $this->assertCount(1, $diffs); - - $chunks = $diffs[0]->getChunks(); - - $this->assertContainsOnlyInstancesOf(Chunk::class, $chunks); - $this->assertCount(1, $chunks); - - $chunk = $chunks[0]; - $this->assertSame(49, $chunk->getStart()); - $this->assertSame(49, $chunk->getEnd()); - $this->assertSame(9, $chunk->getStartRange()); - $this->assertSame(8, $chunk->getEndRange()); - - $lines = $chunk->getLines(); - $this->assertContainsOnlyInstancesOf(Line::class, $lines); - $this->assertCount(2, $lines); - - /** @var Line $line */ - $line = $lines[0]; - $this->assertSame('A', $line->getContent()); - $this->assertSame(Line::UNCHANGED, $line->getType()); - - $line = $lines[1]; - $this->assertSame('B', $line->getContent()); - $this->assertSame(Line::REMOVED, $line->getType()); - } - - public function testParseDiffForMulitpleFiles(): void - { - $content = <<parser->parse($content); - $this->assertCount(2, $diffs); - - /** @var Diff $diff */ - $diff = $diffs[0]; - $this->assertSame('a/Test.txt', $diff->getFrom()); - $this->assertSame('b/Test.txt', $diff->getTo()); - $this->assertCount(1, $diff->getChunks()); - - $diff = $diffs[1]; - $this->assertSame('a/Test2.txt', $diff->getFrom()); - $this->assertSame('b/Test2.txt', $diff->getTo()); - $this->assertCount(1, $diff->getChunks()); - } - - /** - * @param string $diff - * @param Diff[] $expected - * - * @dataProvider diffProvider - */ - public function testParser(string $diff, array $expected): void - { - $result = $this->parser->parse($diff); - - $this->assertEquals($expected, $result); - } - - public function diffProvider(): array - { - return [ - [ - "--- old.txt 2014-11-04 08:51:02.661868729 +0300\n+++ new.txt 2014-11-04 08:51:02.665868730 +0300\n@@ -1,3 +1,4 @@\n+2222111\n 1111111\n 1111111\n 1111111\n@@ -5,10 +6,8 @@\n 1111111\n 1111111\n 1111111\n +1121211\n 1111111\n -1111111\n -1111111\n -2222222\n 2222222\n 2222222\n 2222222\n@@ -17,5 +16,6 @@\n 2222222\n 2222222\n 2222222\n +2122212\n 2222222\n 2222222\n", - \unserialize(FileUtils::getFileContent(__DIR__ . '/fixtures/serialized_diff.bin')), - ], - ]; - } -} diff --git a/vendor/sebastian/diff/tests/TimeEfficientImplementationTest.php b/vendor/sebastian/diff/tests/TimeEfficientImplementationTest.php deleted file mode 100644 index 2bb683d67..000000000 --- a/vendor/sebastian/diff/tests/TimeEfficientImplementationTest.php +++ /dev/null @@ -1,22 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff; - -/** - * @covers SebastianBergmann\Diff\TimeEfficientLongestCommonSubsequenceCalculator - */ -final class TimeEfficientImplementationTest extends LongestCommonSubsequenceTest -{ - protected function createImplementation(): LongestCommonSubsequenceCalculator - { - return new TimeEfficientLongestCommonSubsequenceCalculator; - } -} diff --git a/vendor/sebastian/diff/tests/Utils/FileUtils.php b/vendor/sebastian/diff/tests/Utils/FileUtils.php deleted file mode 100644 index 36e76fa01..000000000 --- a/vendor/sebastian/diff/tests/Utils/FileUtils.php +++ /dev/null @@ -1,31 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff\Utils; - -final class FileUtils -{ - public static function getFileContent(string $file): string - { - $content = @\file_get_contents($file); - - if (false === $content) { - $error = \error_get_last(); - - throw new \RuntimeException(\sprintf( - 'Failed to read content of file "%s".%s', - $file, - $error ? ' ' . $error['message'] : '' - )); - } - - return $content; - } -} diff --git a/vendor/sebastian/diff/tests/Utils/UnifiedDiffAssertTrait.php b/vendor/sebastian/diff/tests/Utils/UnifiedDiffAssertTrait.php deleted file mode 100644 index 40ab44cc4..000000000 --- a/vendor/sebastian/diff/tests/Utils/UnifiedDiffAssertTrait.php +++ /dev/null @@ -1,277 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff\Utils; - -trait UnifiedDiffAssertTrait -{ - /** - * @param string $diff - * - * @throws \UnexpectedValueException - */ - public function assertValidUnifiedDiffFormat(string $diff): void - { - if ('' === $diff) { - $this->addToAssertionCount(1); - - return; - } - - // test diff ends with a line break - $last = \substr($diff, -1); - - if ("\n" !== $last && "\r" !== $last) { - throw new \UnexpectedValueException(\sprintf('Expected diff to end with a line break, got "%s".', $last)); - } - - $lines = \preg_split('/(.*\R)/', $diff, -1, PREG_SPLIT_DELIM_CAPTURE | PREG_SPLIT_NO_EMPTY); - $lineCount = \count($lines); - $lineNumber = $diffLineFromNumber = $diffLineToNumber = 1; - $fromStart = $fromTillOffset = $toStart = $toTillOffset = -1; - $expectHunkHeader = true; - - // check for header - if ($lineCount > 1) { - $this->unifiedDiffAssertLinePrefix($lines[0], 'Line 1.'); - $this->unifiedDiffAssertLinePrefix($lines[1], 'Line 2.'); - - if ('---' === \substr($lines[0], 0, 3)) { - if ('+++' !== \substr($lines[1], 0, 3)) { - throw new \UnexpectedValueException(\sprintf("Line 1 indicates a header, so line 2 must start with \"+++\".\nLine 1: \"%s\"\nLine 2: \"%s\".", $lines[0], $lines[1])); - } - - $this->unifiedDiffAssertHeaderLine($lines[0], '--- ', 'Line 1.'); - $this->unifiedDiffAssertHeaderLine($lines[1], '+++ ', 'Line 2.'); - - $lineNumber = 3; - } - } - - $endOfLineTypes = []; - $diffClosed = false; - - // assert format of lines, get all hunks, test the line numbers - for (; $lineNumber <= $lineCount; ++$lineNumber) { - if ($diffClosed) { - throw new \UnexpectedValueException(\sprintf('Unexpected line as 2 "No newline" markers have found, ". Line %d.', $lineNumber)); - } - - $line = $lines[$lineNumber - 1]; // line numbers start by 1, array index at 0 - $type = $this->unifiedDiffAssertLinePrefix($line, \sprintf('Line %d.', $lineNumber)); - - if ($expectHunkHeader && '@' !== $type && '\\' !== $type) { - throw new \UnexpectedValueException(\sprintf('Expected hunk start (\'@\'), got "%s". Line %d.', $type, $lineNumber)); - } - - if ('@' === $type) { - if (!$expectHunkHeader) { - throw new \UnexpectedValueException(\sprintf('Unexpected hunk start (\'@\'). Line %d.', $lineNumber)); - } - - $previousHunkFromEnd = $fromStart + $fromTillOffset; - $previousHunkTillEnd = $toStart + $toTillOffset; - - [$fromStart, $fromTillOffset, $toStart, $toTillOffset] = $this->unifiedDiffAssertHunkHeader($line, \sprintf('Line %d.', $lineNumber)); - - // detect overlapping hunks - if ($fromStart < $previousHunkFromEnd) { - throw new \UnexpectedValueException(\sprintf('Unexpected new hunk; "from" (\'-\') start overlaps previous hunk. Line %d.', $lineNumber)); - } - - if ($toStart < $previousHunkTillEnd) { - throw new \UnexpectedValueException(\sprintf('Unexpected new hunk; "to" (\'+\') start overlaps previous hunk. Line %d.', $lineNumber)); - } - - /* valid states; hunks touches against each other: - $fromStart === $previousHunkFromEnd - $toStart === $previousHunkTillEnd - */ - - $diffLineFromNumber = $fromStart; - $diffLineToNumber = $toStart; - $expectHunkHeader = false; - - continue; - } - - if ('-' === $type) { - if (isset($endOfLineTypes['-'])) { - throw new \UnexpectedValueException(\sprintf('Not expected from (\'-\'), already closed by "\\ No newline at end of file". Line %d.', $lineNumber)); - } - - ++$diffLineFromNumber; - } elseif ('+' === $type) { - if (isset($endOfLineTypes['+'])) { - throw new \UnexpectedValueException(\sprintf('Not expected to (\'+\'), already closed by "\\ No newline at end of file". Line %d.', $lineNumber)); - } - - ++$diffLineToNumber; - } elseif (' ' === $type) { - if (isset($endOfLineTypes['-'])) { - throw new \UnexpectedValueException(\sprintf('Not expected same (\' \'), \'-\' already closed by "\\ No newline at end of file". Line %d.', $lineNumber)); - } - - if (isset($endOfLineTypes['+'])) { - throw new \UnexpectedValueException(\sprintf('Not expected same (\' \'), \'+\' already closed by "\\ No newline at end of file". Line %d.', $lineNumber)); - } - - ++$diffLineFromNumber; - ++$diffLineToNumber; - } elseif ('\\' === $type) { - if (!isset($lines[$lineNumber - 2])) { - throw new \UnexpectedValueException(\sprintf('Unexpected "\\ No newline at end of file", it must be preceded by \'+\' or \'-\' line. Line %d.', $lineNumber)); - } - - $previousType = $this->unifiedDiffAssertLinePrefix($lines[$lineNumber - 2], \sprintf('Preceding line of "\\ No newline at end of file" of unexpected format. Line %d.', $lineNumber)); - - if (isset($endOfLineTypes[$previousType])) { - throw new \UnexpectedValueException(\sprintf('Unexpected "\\ No newline at end of file", "%s" was already closed. Line %d.', $type, $lineNumber)); - } - - $endOfLineTypes[$previousType] = true; - $diffClosed = \count($endOfLineTypes) > 1; - } else { - // internal state error - throw new \RuntimeException(\sprintf('Unexpected line type "%s" Line %d.', $type, $lineNumber)); - } - - $expectHunkHeader = - $diffLineFromNumber === ($fromStart + $fromTillOffset) - && $diffLineToNumber === ($toStart + $toTillOffset) - ; - } - - if ( - $diffLineFromNumber !== ($fromStart + $fromTillOffset) - && $diffLineToNumber !== ($toStart + $toTillOffset) - ) { - throw new \UnexpectedValueException(\sprintf('Unexpected EOF, number of lines in hunk "from" (\'-\')) and "to" (\'+\') mismatched. Line %d.', $lineNumber)); - } - - if ($diffLineFromNumber !== ($fromStart + $fromTillOffset)) { - throw new \UnexpectedValueException(\sprintf('Unexpected EOF, number of lines in hunk "from" (\'-\')) mismatched. Line %d.', $lineNumber)); - } - - if ($diffLineToNumber !== ($toStart + $toTillOffset)) { - throw new \UnexpectedValueException(\sprintf('Unexpected EOF, number of lines in hunk "to" (\'+\')) mismatched. Line %d.', $lineNumber)); - } - - $this->addToAssertionCount(1); - } - - /** - * @param string $line - * @param string $message - * - * @return string '+', '-', '@', ' ' or '\' - */ - private function unifiedDiffAssertLinePrefix(string $line, string $message): string - { - $this->unifiedDiffAssertStrLength($line, 2, $message); // 2: line type indicator ('+', '-', ' ' or '\') and a line break - $firstChar = $line[0]; - - if ('+' === $firstChar || '-' === $firstChar || '@' === $firstChar || ' ' === $firstChar) { - return $firstChar; - } - - if ("\\ No newline at end of file\n" === $line) { - return '\\'; - } - - throw new \UnexpectedValueException(\sprintf('Expected line to start with \'@\', \'-\' or \'+\', got "%s". %s', $line, $message)); - } - - private function unifiedDiffAssertStrLength(string $line, int $min, string $message): void - { - $length = \strlen($line); - - if ($length < $min) { - throw new \UnexpectedValueException(\sprintf('Expected string length of minimal %d, got %d. %s', $min, $length, $message)); - } - } - - /** - * Assert valid unified diff header line - * - * Samples: - * - "+++ from1.txt\t2017-08-24 19:51:29.383985722 +0200" - * - "+++ from1.txt" - * - * @param string $line - * @param string $start - * @param string $message - */ - private function unifiedDiffAssertHeaderLine(string $line, string $start, string $message): void - { - if (0 !== \strpos($line, $start)) { - throw new \UnexpectedValueException(\sprintf('Expected header line to start with "%s", got "%s". %s', $start . ' ', $line, $message)); - } - - // sample "+++ from1.txt\t2017-08-24 19:51:29.383985722 +0200\n" - $match = \preg_match( - "/^([^\t]*)(?:[\t]([\\S].*[\\S]))?\n$/", - \substr($line, 4), // 4 === string length of "+++ " / "--- " - $matches - ); - - if (1 !== $match) { - throw new \UnexpectedValueException(\sprintf('Header line does not match expected pattern, got "%s". %s', $line, $message)); - } - - // $file = $matches[1]; - - if (\count($matches) > 2) { - $this->unifiedDiffAssertHeaderDate($matches[2], $message); - } - } - - private function unifiedDiffAssertHeaderDate(string $date, string $message): void - { - // sample "2017-08-24 19:51:29.383985722 +0200" - $match = \preg_match( - '/^([\d]{4})-([01]?[\d])-([0123]?[\d])(:? [\d]{1,2}:[\d]{1,2}(?::[\d]{1,2}(:?\.[\d]+)?)?(?: ([\+\-][\d]{4}))?)?$/', - $date, - $matches - ); - - if (1 !== $match || ($matchesCount = \count($matches)) < 4) { - throw new \UnexpectedValueException(\sprintf('Date of header line does not match expected pattern, got "%s". %s', $date, $message)); - } - - // [$full, $year, $month, $day, $time] = $matches; - } - - /** - * @param string $line - * @param string $message - * - * @return int[] - */ - private function unifiedDiffAssertHunkHeader(string $line, string $message): array - { - if (1 !== \preg_match('#^@@ -([\d]+)((?:,[\d]+)?) \+([\d]+)((?:,[\d]+)?) @@\n$#', $line, $matches)) { - throw new \UnexpectedValueException( - \sprintf( - 'Hunk header line does not match expected pattern, got "%s". %s', - $line, - $message - ) - ); - } - - return [ - (int) $matches[1], - empty($matches[2]) ? 1 : (int) \substr($matches[2], 1), - (int) $matches[3], - empty($matches[4]) ? 1 : (int) \substr($matches[4], 1), - ]; - } -} diff --git a/vendor/sebastian/diff/tests/Utils/UnifiedDiffAssertTraitIntegrationTest.php b/vendor/sebastian/diff/tests/Utils/UnifiedDiffAssertTraitIntegrationTest.php deleted file mode 100644 index c88dc52e7..000000000 --- a/vendor/sebastian/diff/tests/Utils/UnifiedDiffAssertTraitIntegrationTest.php +++ /dev/null @@ -1,129 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff\Utils; - -use PHPUnit\Framework\TestCase; -use Symfony\Component\Process\Process; - -/** - * @requires OS Linux - * - * @coversNothing - */ -final class UnifiedDiffAssertTraitIntegrationTest extends TestCase -{ - use UnifiedDiffAssertTrait; - - private $filePatch; - - protected function setUp(): void - { - $this->filePatch = __DIR__ . '/../fixtures/out/patch.txt'; - - $this->cleanUpTempFiles(); - } - - protected function tearDown(): void - { - $this->cleanUpTempFiles(); - } - - /** - * @param string $fileFrom - * @param string $fileTo - * - * @dataProvider provideFilePairsCases - */ - public function testValidPatches(string $fileFrom, string $fileTo): void - { - $command = \sprintf( - 'diff -u %s %s > %s', - \escapeshellarg(\realpath($fileFrom)), - \escapeshellarg(\realpath($fileTo)), - \escapeshellarg($this->filePatch) - ); - - $p = new Process($command); - $p->run(); - - $exitCode = $p->getExitCode(); - - if (0 === $exitCode) { - // odd case when two files have the same content. Test after executing as it is more efficient than to read the files and check the contents every time. - $this->addToAssertionCount(1); - - return; - } - - $this->assertSame( - 1, // means `diff` found a diff between the files we gave it - $exitCode, - \sprintf( - "Command exec. was not successful:\n\"%s\"\nOutput:\n\"%s\"\nStdErr:\n\"%s\"\nExit code %d.\n", - $command, - $p->getOutput(), - $p->getErrorOutput(), - $p->getExitCode() - ) - ); - - $this->assertValidUnifiedDiffFormat(FileUtils::getFileContent($this->filePatch)); - } - - /** - * @return array> - */ - public function provideFilePairsCases(): array - { - $cases = []; - - // created cases based on dedicated fixtures - $dir = \realpath(__DIR__ . '/../fixtures/UnifiedDiffAssertTraitIntegrationTest'); - $dirLength = \strlen($dir); - - for ($i = 1;; ++$i) { - $fromFile = \sprintf('%s/%d_a.txt', $dir, $i); - $toFile = \sprintf('%s/%d_b.txt', $dir, $i); - - if (!\file_exists($fromFile)) { - break; - } - - $this->assertFileExists($toFile); - $cases[\sprintf("Diff file:\n\"%s\"\nvs.\n\"%s\"\n", \substr(\realpath($fromFile), $dirLength), \substr(\realpath($toFile), $dirLength))] = [$fromFile, $toFile]; - } - - // create cases based on PHP files within the vendor directory for integration testing - $dir = \realpath(__DIR__ . '/../../vendor'); - $dirLength = \strlen($dir); - - $fileIterator = new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($dir, \RecursiveDirectoryIterator::SKIP_DOTS)); - $fromFile = __FILE__; - - /** @var \SplFileInfo $file */ - foreach ($fileIterator as $file) { - if ('php' !== $file->getExtension()) { - continue; - } - - $toFile = $file->getPathname(); - $cases[\sprintf("Diff file:\n\"%s\"\nvs.\n\"%s\"\n", \substr(\realpath($fromFile), $dirLength), \substr(\realpath($toFile), $dirLength))] = [$fromFile, $toFile]; - $fromFile = $toFile; - } - - return $cases; - } - - private function cleanUpTempFiles(): void - { - @\unlink($this->filePatch); - } -} diff --git a/vendor/sebastian/diff/tests/Utils/UnifiedDiffAssertTraitTest.php b/vendor/sebastian/diff/tests/Utils/UnifiedDiffAssertTraitTest.php deleted file mode 100644 index 7d5cc6545..000000000 --- a/vendor/sebastian/diff/tests/Utils/UnifiedDiffAssertTraitTest.php +++ /dev/null @@ -1,434 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\Diff\Utils; - -use PHPUnit\Framework\TestCase; - -/** - * @covers SebastianBergmann\Diff\Utils\UnifiedDiffAssertTrait - */ -final class UnifiedDiffAssertTraitTest extends TestCase -{ - use UnifiedDiffAssertTrait; - - /** - * @param string $diff - * - * @dataProvider provideValidCases - */ - public function testValidCases(string $diff): void - { - $this->assertValidUnifiedDiffFormat($diff); - } - - public function provideValidCases(): array - { - return [ - [ -'--- Original -+++ New -@@ -8 +8 @@ --Z -+U -', - ], - [ -'--- Original -+++ New -@@ -8 +8 @@ --Z -+U -@@ -15 +15 @@ --X -+V -', - ], - 'empty diff. is valid' => [ - '', - ], - ]; - } - - public function testNoLinebreakEnd(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote('Expected diff to end with a line break, got "C".', '#'))); - - $this->assertValidUnifiedDiffFormat("A\nB\nC"); - } - - public function testInvalidStartWithoutHeader(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote("Expected line to start with '@', '-' or '+', got \"A\n\". Line 1.", '#'))); - - $this->assertValidUnifiedDiffFormat("A\n"); - } - - public function testInvalidStartHeader1(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote("Line 1 indicates a header, so line 2 must start with \"+++\".\nLine 1: \"--- A\n\"\nLine 2: \"+ 1\n\".", '#'))); - - $this->assertValidUnifiedDiffFormat("--- A\n+ 1\n"); - } - - public function testInvalidStartHeader2(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote("Header line does not match expected pattern, got \"+++ file X\n\". Line 2.", '#'))); - - $this->assertValidUnifiedDiffFormat("--- A\n+++ file\tX\n"); - } - - public function testInvalidStartHeader3(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote('Date of header line does not match expected pattern, got "[invalid date]". Line 1.', '#'))); - - $this->assertValidUnifiedDiffFormat( -"--- Original\t[invalid date] -+++ New -@@ -1,2 +1,2 @@ --A -+B - " . ' -' - ); - } - - public function testInvalidStartHeader4(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote("Expected header line to start with \"+++ \", got \"+++INVALID\n\". Line 2.", '#'))); - - $this->assertValidUnifiedDiffFormat( -'--- Original -+++INVALID -@@ -1,2 +1,2 @@ --A -+B - ' . ' -' - ); - } - - public function testInvalidLine1(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote("Expected line to start with '@', '-' or '+', got \"1\n\". Line 5.", '#'))); - - $this->assertValidUnifiedDiffFormat( -'--- Original -+++ New -@@ -8 +8 @@ --Z -1 -+U -' - ); - } - - public function testInvalidLine2(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote('Expected string length of minimal 2, got 1. Line 4.', '#'))); - - $this->assertValidUnifiedDiffFormat( -'--- Original -+++ New -@@ -8 +8 @@ - - -' - ); - } - - public function testHunkInvalidFormat(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote("Hunk header line does not match expected pattern, got \"@@ INVALID -1,1 +1,1 @@\n\". Line 3.", '#'))); - - $this->assertValidUnifiedDiffFormat( -'--- Original -+++ New -@@ INVALID -1,1 +1,1 @@ --Z -+U -' - ); - } - - public function testHunkOverlapFrom(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote('Unexpected new hunk; "from" (\'-\') start overlaps previous hunk. Line 6.', '#'))); - - $this->assertValidUnifiedDiffFormat( -'--- Original -+++ New -@@ -8,1 +8,1 @@ --Z -+U -@@ -7,1 +9,1 @@ --Z -+U -' - ); - } - - public function testHunkOverlapTo(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote('Unexpected new hunk; "to" (\'+\') start overlaps previous hunk. Line 6.', '#'))); - - $this->assertValidUnifiedDiffFormat( -'--- Original -+++ New -@@ -8,1 +8,1 @@ --Z -+U -@@ -17,1 +7,1 @@ --Z -+U -' - ); - } - - public function testExpectHunk1(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote('Expected hunk start (\'@\'), got "+". Line 6.', '#'))); - - $this->assertValidUnifiedDiffFormat( -'--- Original -+++ New -@@ -8 +8 @@ --Z -+U -+O -' - ); - } - - public function testExpectHunk2(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote('Unexpected hunk start (\'@\'). Line 6.', '#'))); - - $this->assertValidUnifiedDiffFormat( -'--- Original -+++ New -@@ -8,12 +8,12 @@ - ' . ' - ' . ' -@@ -38,12 +48,12 @@ -' - ); - } - - public function testMisplacedLineAfterComments1(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote('Unexpected line as 2 "No newline" markers have found, ". Line 8.', '#'))); - - $this->assertValidUnifiedDiffFormat( -'--- Original -+++ New -@@ -8 +8 @@ --Z -\ No newline at end of file -+U -\ No newline at end of file -+A -' - ); - } - - public function testMisplacedLineAfterComments2(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote('Unexpected line as 2 "No newline" markers have found, ". Line 7.', '#'))); - - $this->assertValidUnifiedDiffFormat( -'--- Original -+++ New -@@ -8 +8 @@ -+U -\ No newline at end of file -\ No newline at end of file -\ No newline at end of file -' - ); - } - - public function testMisplacedLineAfterComments3(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote('Unexpected line as 2 "No newline" markers have found, ". Line 7.', '#'))); - - $this->assertValidUnifiedDiffFormat( -'--- Original -+++ New -@@ -8 +8 @@ -+U -\ No newline at end of file -\ No newline at end of file -+A -' - ); - } - - public function testMisplacedComment(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote('Unexpected "\ No newline at end of file", it must be preceded by \'+\' or \'-\' line. Line 1.', '#'))); - - $this->assertValidUnifiedDiffFormat( -'\ No newline at end of file -' - ); - } - - public function testUnexpectedDuplicateNoNewLineEOF(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote('Unexpected "\\ No newline at end of file", "\\" was already closed. Line 8.', '#'))); - - $this->assertValidUnifiedDiffFormat( -'--- Original -+++ New -@@ -8,12 +8,12 @@ - ' . ' - ' . ' -\ No newline at end of file - ' . ' -\ No newline at end of file -' - ); - } - - public function testFromAfterClose(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote('Not expected from (\'-\'), already closed by "\ No newline at end of file". Line 6.', '#'))); - - $this->assertValidUnifiedDiffFormat( -'--- Original -+++ New -@@ -8,12 +8,12 @@ --A -\ No newline at end of file --A -\ No newline at end of file -' - ); - } - - public function testSameAfterFromClose(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote('Not expected same (\' \'), \'-\' already closed by "\ No newline at end of file". Line 6.', '#'))); - - $this->assertValidUnifiedDiffFormat( - '--- Original -+++ New -@@ -8,12 +8,12 @@ --A -\ No newline at end of file - A -\ No newline at end of file -' - ); - } - - public function testToAfterClose(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote('Not expected to (\'+\'), already closed by "\ No newline at end of file". Line 6.', '#'))); - - $this->assertValidUnifiedDiffFormat( - '--- Original -+++ New -@@ -8,12 +8,12 @@ -+A -\ No newline at end of file -+A -\ No newline at end of file -' - ); - } - - public function testSameAfterToClose(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote('Not expected same (\' \'), \'+\' already closed by "\ No newline at end of file". Line 6.', '#'))); - - $this->assertValidUnifiedDiffFormat( - '--- Original -+++ New -@@ -8,12 +8,12 @@ -+A -\ No newline at end of file - A -\ No newline at end of file -' - ); - } - - public function testUnexpectedEOFFromMissingLines(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote('Unexpected EOF, number of lines in hunk "from" (\'-\')) mismatched. Line 7.', '#'))); - - $this->assertValidUnifiedDiffFormat( -'--- Original -+++ New -@@ -8,19 +7,2 @@ --A -+B - ' . ' -' - ); - } - - public function testUnexpectedEOFToMissingLines(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote('Unexpected EOF, number of lines in hunk "to" (\'+\')) mismatched. Line 7.', '#'))); - - $this->assertValidUnifiedDiffFormat( -'--- Original -+++ New -@@ -8,2 +7,3 @@ --A -+B - ' . ' -' - ); - } - - public function testUnexpectedEOFBothFromAndToMissingLines(): void - { - $this->expectException(\UnexpectedValueException::class); - $this->expectExceptionMessageRegExp(\sprintf('#^%s$#', \preg_quote('Unexpected EOF, number of lines in hunk "from" (\'-\')) and "to" (\'+\') mismatched. Line 7.', '#'))); - - $this->assertValidUnifiedDiffFormat( -'--- Original -+++ New -@@ -1,12 +1,14 @@ --A -+B - ' . ' -' - ); - } -} diff --git a/vendor/sebastian/diff/tests/fixtures/.editorconfig b/vendor/sebastian/diff/tests/fixtures/.editorconfig deleted file mode 100644 index 78b36ca08..000000000 --- a/vendor/sebastian/diff/tests/fixtures/.editorconfig +++ /dev/null @@ -1 +0,0 @@ -root = true diff --git a/vendor/sebastian/diff/tests/fixtures/UnifiedDiffAssertTraitIntegrationTest/1_a.txt b/vendor/sebastian/diff/tests/fixtures/UnifiedDiffAssertTraitIntegrationTest/1_a.txt deleted file mode 100644 index 2e65efe2a..000000000 --- a/vendor/sebastian/diff/tests/fixtures/UnifiedDiffAssertTraitIntegrationTest/1_a.txt +++ /dev/null @@ -1 +0,0 @@ -a \ No newline at end of file diff --git a/vendor/sebastian/diff/tests/fixtures/UnifiedDiffAssertTraitIntegrationTest/1_b.txt b/vendor/sebastian/diff/tests/fixtures/UnifiedDiffAssertTraitIntegrationTest/1_b.txt deleted file mode 100644 index e69de29bb..000000000 diff --git a/vendor/sebastian/diff/tests/fixtures/UnifiedDiffAssertTraitIntegrationTest/2_a.txt b/vendor/sebastian/diff/tests/fixtures/UnifiedDiffAssertTraitIntegrationTest/2_a.txt deleted file mode 100644 index c7fe26e98..000000000 --- a/vendor/sebastian/diff/tests/fixtures/UnifiedDiffAssertTraitIntegrationTest/2_a.txt +++ /dev/null @@ -1,35 +0,0 @@ -a -a -a -a -a -a -a -a -a -a -a -a -a -a -a -a -a -a -a -a -a -a -a -a -a -a -a -a -a -a -a -a -a -a -a \ No newline at end of file diff --git a/vendor/sebastian/diff/tests/fixtures/UnifiedDiffAssertTraitIntegrationTest/2_b.txt b/vendor/sebastian/diff/tests/fixtures/UnifiedDiffAssertTraitIntegrationTest/2_b.txt deleted file mode 100644 index 377a70f80..000000000 --- a/vendor/sebastian/diff/tests/fixtures/UnifiedDiffAssertTraitIntegrationTest/2_b.txt +++ /dev/null @@ -1,18 +0,0 @@ -a -a -a -a -a -a -a -a -a -a -b -a -a -a -a -a -a -c \ No newline at end of file diff --git a/vendor/sebastian/diff/tests/fixtures/out/.editorconfig b/vendor/sebastian/diff/tests/fixtures/out/.editorconfig deleted file mode 100644 index 78b36ca08..000000000 --- a/vendor/sebastian/diff/tests/fixtures/out/.editorconfig +++ /dev/null @@ -1 +0,0 @@ -root = true diff --git a/vendor/sebastian/diff/tests/fixtures/out/.gitignore b/vendor/sebastian/diff/tests/fixtures/out/.gitignore deleted file mode 100644 index f6f7a4784..000000000 --- a/vendor/sebastian/diff/tests/fixtures/out/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -# reset all ignore rules to create sandbox for integration test -!/** \ No newline at end of file diff --git a/vendor/sebastian/diff/tests/fixtures/patch.txt b/vendor/sebastian/diff/tests/fixtures/patch.txt deleted file mode 100644 index 144b61d01..000000000 --- a/vendor/sebastian/diff/tests/fixtures/patch.txt +++ /dev/null @@ -1,9 +0,0 @@ -diff --git a/Foo.php b/Foo.php -index abcdefg..abcdefh 100644 ---- a/Foo.php -+++ b/Foo.php -@@ -20,4 +20,5 @@ class Foo - const ONE = 1; - const TWO = 2; -+ const THREE = 3; - const FOUR = 4; diff --git a/vendor/sebastian/diff/tests/fixtures/patch2.txt b/vendor/sebastian/diff/tests/fixtures/patch2.txt deleted file mode 100644 index 41fbc9597..000000000 --- a/vendor/sebastian/diff/tests/fixtures/patch2.txt +++ /dev/null @@ -1,21 +0,0 @@ -diff --git a/Foo.php b/Foo.php -index abcdefg..abcdefh 100644 ---- a/Foo.php -+++ b/Foo.php -@@ -20,4 +20,5 @@ class Foo - const ONE = 1; - const TWO = 2; -+ const THREE = 3; - const FOUR = 4; - -@@ -320,4 +320,5 @@ class Foo - const A = 'A'; - const B = 'B'; -+ const C = 'C'; - const D = 'D'; - -@@ -600,4 +600,5 @@ class Foo - public function doSomething() { - -+ return 'foo'; - } diff --git a/vendor/sebastian/diff/tests/fixtures/serialized_diff.bin b/vendor/sebastian/diff/tests/fixtures/serialized_diff.bin deleted file mode 100644 index 377404d442d6e690beef8f276a647492d1b5c850..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 4143 zcmeH~O;5ux42Jt#az&t}X}jUxfFlwTT)C7j8x>oM)*wLB{yVn2l_Jqk4K)W+snR4n zeQd{hy#yreQkcYd;7>t3=%*yNX=1MQcC|^2dAv!NOMVGZu**Ry5MG0sx7=nM5$Axr zW$VR-{jl^)$rd-89h{7QFP*{`r}^`ndC5hb5ZfV&S#1>8WGx`%FdDXIJ1@7%7SU6X zh#ySqNh;>|iCJm#Q514RrV1Zz7RL`L#I8$gXoIYF76`V!xwu>ilV z#AN2#&sUC;GNYn;a5kQ2#%jZd0Ke|zl2VFzPl;_jbVGBaiNVCcE6FBOL4hMnetz - -For the full copyright and license information, please view the LICENSE -file that was distributed with this source code. -EOF; - -return PhpCsFixer\Config::create() - ->setRiskyAllowed(true) - ->setRules( - [ - 'align_multiline_comment' => true, - 'array_indentation' => true, - 'array_syntax' => ['syntax' => 'short'], - 'binary_operator_spaces' => [ - 'operators' => [ - '=' => 'align', - '=>' => 'align', - ], - ], - 'blank_line_after_namespace' => true, - 'blank_line_before_statement' => [ - 'statements' => [ - 'break', - 'continue', - 'declare', - 'do', - 'for', - 'foreach', - 'if', - 'include', - 'include_once', - 'require', - 'require_once', - 'return', - 'switch', - 'throw', - 'try', - 'while', - 'yield', - ], - ], - 'braces' => true, - 'cast_spaces' => true, - 'class_attributes_separation' => ['elements' => ['const', 'method', 'property']], - 'combine_consecutive_issets' => true, - 'combine_consecutive_unsets' => true, - 'combine_nested_dirname' => true, - 'compact_nullable_typehint' => true, - 'concat_space' => ['spacing' => 'one'], - 'declare_equal_normalize' => ['space' => 'none'], - 'declare_strict_types' => true, - 'dir_constant' => true, - 'elseif' => true, - 'encoding' => true, - 'full_opening_tag' => true, - 'function_declaration' => true, - 'header_comment' => ['header' => $header, 'separate' => 'none'], - 'indentation_type' => true, - 'is_null' => true, - 'line_ending' => true, - 'list_syntax' => ['syntax' => 'short'], - 'logical_operators' => true, - 'lowercase_cast' => true, - 'lowercase_constants' => true, - 'lowercase_keywords' => true, - 'lowercase_static_reference' => true, - 'magic_constant_casing' => true, - 'method_argument_space' => ['ensure_fully_multiline' => true], - 'modernize_types_casting' => true, - 'multiline_comment_opening_closing' => true, - 'multiline_whitespace_before_semicolons' => true, - 'native_constant_invocation' => true, - 'native_function_casing' => true, - 'native_function_invocation' => true, - 'new_with_braces' => false, - 'no_alias_functions' => true, - 'no_alternative_syntax' => true, - 'no_blank_lines_after_class_opening' => true, - 'no_blank_lines_after_phpdoc' => true, - 'no_blank_lines_before_namespace' => true, - 'no_closing_tag' => true, - 'no_empty_comment' => true, - 'no_empty_phpdoc' => true, - 'no_empty_statement' => true, - 'no_extra_blank_lines' => true, - 'no_homoglyph_names' => true, - 'no_leading_import_slash' => true, - 'no_leading_namespace_whitespace' => true, - 'no_mixed_echo_print' => ['use' => 'print'], - 'no_multiline_whitespace_around_double_arrow' => true, - 'no_null_property_initialization' => true, - 'no_php4_constructor' => true, - 'no_short_bool_cast' => true, - 'no_short_echo_tag' => true, - 'no_singleline_whitespace_before_semicolons' => true, - 'no_spaces_after_function_name' => true, - 'no_spaces_inside_parenthesis' => true, - 'no_superfluous_elseif' => true, - 'no_superfluous_phpdoc_tags' => true, - 'no_trailing_comma_in_list_call' => true, - 'no_trailing_comma_in_singleline_array' => true, - 'no_trailing_whitespace' => true, - 'no_trailing_whitespace_in_comment' => true, - 'no_unneeded_control_parentheses' => true, - 'no_unneeded_curly_braces' => true, - 'no_unneeded_final_method' => true, - 'no_unreachable_default_argument_value' => true, - 'no_unset_on_property' => true, - 'no_unused_imports' => true, - 'no_useless_else' => true, - 'no_useless_return' => true, - 'no_whitespace_before_comma_in_array' => true, - 'no_whitespace_in_blank_line' => true, - 'non_printable_character' => true, - 'normalize_index_brace' => true, - 'object_operator_without_whitespace' => true, - 'ordered_class_elements' => [ - 'order' => [ - 'use_trait', - 'constant_public', - 'constant_protected', - 'constant_private', - 'property_public_static', - 'property_protected_static', - 'property_private_static', - 'property_public', - 'property_protected', - 'property_private', - 'method_public_static', - 'construct', - 'destruct', - 'magic', - 'phpunit', - 'method_public', - 'method_protected', - 'method_private', - 'method_protected_static', - 'method_private_static', - ], - ], - 'ordered_imports' => true, - 'phpdoc_add_missing_param_annotation' => true, - 'phpdoc_align' => true, - 'phpdoc_annotation_without_dot' => true, - 'phpdoc_indent' => true, - 'phpdoc_no_access' => true, - 'phpdoc_no_empty_return' => true, - 'phpdoc_no_package' => true, - 'phpdoc_order' => true, - 'phpdoc_return_self_reference' => true, - 'phpdoc_scalar' => true, - 'phpdoc_separation' => true, - 'phpdoc_single_line_var_spacing' => true, - 'phpdoc_to_comment' => true, - 'phpdoc_trim' => true, - 'phpdoc_trim_consecutive_blank_line_separation' => true, - 'phpdoc_types' => true, - 'phpdoc_types_order' => true, - 'phpdoc_var_without_name' => true, - 'pow_to_exponentiation' => true, - 'protected_to_private' => true, - 'random_api_migration' => true, - 'return_assignment' => true, - 'return_type_declaration' => ['space_before' => 'none'], - 'self_accessor' => true, - 'semicolon_after_instruction' => true, - 'set_type_to_cast' => true, - 'short_scalar_cast' => true, - 'simplified_null_return' => true, - 'single_blank_line_at_eof' => true, - 'single_import_per_statement' => true, - 'single_line_after_imports' => true, - 'single_quote' => true, - 'standardize_not_equals' => true, - 'ternary_to_null_coalescing' => true, - 'trailing_comma_in_multiline_array' => true, - 'trim_array_spaces' => true, - 'unary_operator_spaces' => true, - 'visibility_required' => [ - 'elements' => [ - 'const', - 'method', - 'property', - ], - ], - 'void_return' => true, - 'whitespace_after_comma_in_array' => true, - ] - ) - ->setFinder( - PhpCsFixer\Finder::create() - ->files() - ->in(__DIR__ . '/src') - ->in(__DIR__ . '/tests') - ); diff --git a/vendor/sebastian/environment/.travis.yml b/vendor/sebastian/environment/.travis.yml deleted file mode 100644 index e066fa935..000000000 --- a/vendor/sebastian/environment/.travis.yml +++ /dev/null @@ -1,28 +0,0 @@ -language: php - -php: - - 7.1 - - 7.2 - - 7.3 - - 7.4snapshot - -env: - matrix: - - DRIVER="phpdbg" - - DRIVER="xdebug" - -before_install: - - composer clear-cache - -install: - - travis_retry composer update --no-interaction --no-ansi --no-progress --no-suggest - -script: - - if [[ "$DRIVER" = 'phpdbg' ]]; then phpdbg -qrr vendor/bin/phpunit --coverage-clover=coverage.xml; fi - - if [[ "$DRIVER" != 'phpdbg' ]]; then vendor/bin/phpunit --coverage-clover=coverage.xml; fi - -after_success: - - bash <(curl -s https://codecov.io/bash) - -notifications: - email: false diff --git a/vendor/sebastian/environment/ChangeLog.md b/vendor/sebastian/environment/ChangeLog.md index 172a8db8c..67daf0356 100644 --- a/vendor/sebastian/environment/ChangeLog.md +++ b/vendor/sebastian/environment/ChangeLog.md @@ -2,27 +2,63 @@ All notable changes in `sebastianbergmann/environment` are documented in this file using the [Keep a CHANGELOG](http://keepachangelog.com/) principles. -## [4.2.4] - 2020-11-30 +## [5.1.3] - 2020-09-28 ### Changed -* Changed PHP version constraint in `composer.json` from `^7.1` to `>=7.1` +* Changed PHP version constraint in `composer.json` from `^7.3 || ^8.0` to `>=7.3` + +## [5.1.2] - 2020-06-26 + +### Added + +* This component is now supported on PHP 8 + +## [5.1.1] - 2020-06-15 + +### Changed + +* Tests etc. are now ignored for archive exports + +## [5.1.0] - 2020-04-14 + +### Added + +* `Runtime::performsJustInTimeCompilation()` returns `true` if PHP 8's JIT is active, `false` otherwise + +## [5.0.2] - 2020-03-31 + +### Fixed + +* [#55](https://github.com/sebastianbergmann/environment/issues/55): `stty` command is executed even if no tty is available + +## [5.0.1] - 2020-02-19 + +### Changed + +* `Runtime::getNameWithVersionAndCodeCoverageDriver()` now prioritizes PCOV over Xdebug when both extensions are loaded (just like php-code-coverage does) + +## [5.0.0] - 2020-02-07 + +### Removed + +* This component is no longer supported on PHP 7.1 and PHP 7.2 ## [4.2.3] - 2019-11-20 ### Changed -* Implemented [#50](https://github.com/sebastianbergmann/environment/pull/50): Windows improvements to console capabilities +* [#50](https://github.com/sebastianbergmann/environment/pull/50): Windows improvements to console capabilities ### Fixed -* Fixed [#49](https://github.com/sebastianbergmann/environment/issues/49): Detection how OpCache handles docblocks does not work correctly when PHPDBG is used +* [#49](https://github.com/sebastianbergmann/environment/issues/49): Detection how OpCache handles docblocks does not work correctly when PHPDBG is used ## [4.2.2] - 2019-05-05 ### Fixed -* Fixed [#44](https://github.com/sebastianbergmann/environment/pull/44): `TypeError` in `Console::getNumberOfColumnsInteractive()` +* [#44](https://github.com/sebastianbergmann/environment/pull/44): `TypeError` in `Console::getNumberOfColumnsInteractive()` ## [4.2.1] - 2019-04-25 @@ -34,20 +70,20 @@ All notable changes in `sebastianbergmann/environment` are documented in this fi ### Added -* Implemented [#36](https://github.com/sebastianbergmann/environment/pull/36): `Runtime::getCurrentSettings()` +* [#36](https://github.com/sebastianbergmann/environment/pull/36): `Runtime::getCurrentSettings()` ## [4.1.0] - 2019-02-01 ### Added * Implemented `Runtime::getNameWithVersionAndCodeCoverageDriver()` method -* Implemented [#34](https://github.com/sebastianbergmann/environment/pull/34): Support for PCOV extension +* [#34](https://github.com/sebastianbergmann/environment/pull/34): Support for PCOV extension ## [4.0.2] - 2019-01-28 ### Fixed -* Fixed [#33](https://github.com/sebastianbergmann/environment/issues/33): `Runtime::discardsComments()` returns true too eagerly +* [#33](https://github.com/sebastianbergmann/environment/issues/33): `Runtime::discardsComments()` returns true too eagerly ### Removed @@ -57,13 +93,13 @@ All notable changes in `sebastianbergmann/environment` are documented in this fi ### Fixed -* Fixed [#31](https://github.com/sebastianbergmann/environment/issues/31): Regressions in `Console` class +* [#31](https://github.com/sebastianbergmann/environment/issues/31): Regressions in `Console` class ## [4.0.0] - 2018-10-23 [YANKED] ### Fixed -* Fixed [#25](https://github.com/sebastianbergmann/environment/pull/25): `Console::hasColorSupport()` does not work on Windows +* [#25](https://github.com/sebastianbergmann/environment/pull/25): `Console::hasColorSupport()` does not work on Windows ### Removed @@ -73,25 +109,25 @@ All notable changes in `sebastianbergmann/environment` are documented in this fi ### Added -* Implemented [#21](https://github.com/sebastianbergmann/environment/issues/21): Equivalent of `PHP_OS_FAMILY` (for PHP < 7.2) +* [#21](https://github.com/sebastianbergmann/environment/issues/21): Equivalent of `PHP_OS_FAMILY` (for PHP < 7.2) ## [3.0.4] - 2017-06-20 ### Fixed -* Fixed [#20](https://github.com/sebastianbergmann/environment/pull/20): PHP 7 mode of HHVM not forced +* [#20](https://github.com/sebastianbergmann/environment/pull/20): PHP 7 mode of HHVM not forced ## [3.0.3] - 2017-05-18 ### Fixed -* Fixed [#18](https://github.com/sebastianbergmann/environment/issues/18): `Uncaught TypeError: preg_match() expects parameter 2 to be string, null given` +* [#18](https://github.com/sebastianbergmann/environment/issues/18): `Uncaught TypeError: preg_match() expects parameter 2 to be string, null given` ## [3.0.2] - 2017-04-21 ### Fixed -* Fixed [#17](https://github.com/sebastianbergmann/environment/issues/17): `Uncaught TypeError: trim() expects parameter 1 to be string, boolean given` +* [#17](https://github.com/sebastianbergmann/environment/issues/17): `Uncaught TypeError: trim() expects parameter 1 to be string, boolean given` ## [3.0.1] - 2017-04-21 @@ -109,19 +145,25 @@ All notable changes in `sebastianbergmann/environment` are documented in this fi * This component is no longer supported on PHP 5.6 -[4.2.4]: https://github.com/sebastianbergmann/phpunit/compare/4.2.3...4.2.4 -[4.2.3]: https://github.com/sebastianbergmann/phpunit/compare/4.2.2...4.2.3 -[4.2.2]: https://github.com/sebastianbergmann/phpunit/compare/4.2.1...4.2.2 -[4.2.1]: https://github.com/sebastianbergmann/phpunit/compare/4.2.0...4.2.1 -[4.2.0]: https://github.com/sebastianbergmann/phpunit/compare/4.1.0...4.2.0 -[4.1.0]: https://github.com/sebastianbergmann/phpunit/compare/4.0.2...4.1.0 -[4.0.2]: https://github.com/sebastianbergmann/phpunit/compare/4.0.1...4.0.2 -[4.0.1]: https://github.com/sebastianbergmann/phpunit/compare/66691f8e2dc4641909166b275a9a4f45c0e89092...4.0.1 -[4.0.0]: https://github.com/sebastianbergmann/phpunit/compare/3.1.0...66691f8e2dc4641909166b275a9a4f45c0e89092 -[3.1.0]: https://github.com/sebastianbergmann/phpunit/compare/3.0...3.1.0 -[3.0.4]: https://github.com/sebastianbergmann/phpunit/compare/3.0.3...3.0.4 -[3.0.3]: https://github.com/sebastianbergmann/phpunit/compare/3.0.2...3.0.3 -[3.0.2]: https://github.com/sebastianbergmann/phpunit/compare/3.0.1...3.0.2 -[3.0.1]: https://github.com/sebastianbergmann/phpunit/compare/3.0.0...3.0.1 -[3.0.0]: https://github.com/sebastianbergmann/phpunit/compare/2.0...3.0.0 +[5.1.3]: https://github.com/sebastianbergmann/environment/compare/5.1.2...5.1.3 +[5.1.2]: https://github.com/sebastianbergmann/environment/compare/5.1.1...5.1.2 +[5.1.1]: https://github.com/sebastianbergmann/environment/compare/5.1.0...5.1.1 +[5.1.0]: https://github.com/sebastianbergmann/environment/compare/5.0.2...5.1.0 +[5.0.2]: https://github.com/sebastianbergmann/environment/compare/5.0.1...5.0.2 +[5.0.1]: https://github.com/sebastianbergmann/environment/compare/5.0.0...5.0.1 +[5.0.0]: https://github.com/sebastianbergmann/environment/compare/4.2.3...5.0.0 +[4.2.3]: https://github.com/sebastianbergmann/environment/compare/4.2.2...4.2.3 +[4.2.2]: https://github.com/sebastianbergmann/environment/compare/4.2.1...4.2.2 +[4.2.1]: https://github.com/sebastianbergmann/environment/compare/4.2.0...4.2.1 +[4.2.0]: https://github.com/sebastianbergmann/environment/compare/4.1.0...4.2.0 +[4.1.0]: https://github.com/sebastianbergmann/environment/compare/4.0.2...4.1.0 +[4.0.2]: https://github.com/sebastianbergmann/environment/compare/4.0.1...4.0.2 +[4.0.1]: https://github.com/sebastianbergmann/environment/compare/66691f8e2dc4641909166b275a9a4f45c0e89092...4.0.1 +[4.0.0]: https://github.com/sebastianbergmann/environment/compare/3.1.0...66691f8e2dc4641909166b275a9a4f45c0e89092 +[3.1.0]: https://github.com/sebastianbergmann/environment/compare/3.0...3.1.0 +[3.0.4]: https://github.com/sebastianbergmann/environment/compare/3.0.3...3.0.4 +[3.0.3]: https://github.com/sebastianbergmann/environment/compare/3.0.2...3.0.3 +[3.0.2]: https://github.com/sebastianbergmann/environment/compare/3.0.1...3.0.2 +[3.0.1]: https://github.com/sebastianbergmann/environment/compare/3.0.0...3.0.1 +[3.0.0]: https://github.com/sebastianbergmann/environment/compare/2.0...3.0.0 diff --git a/vendor/sebastian/environment/LICENSE b/vendor/sebastian/environment/LICENSE index 3291fbdfa..c58093991 100644 --- a/vendor/sebastian/environment/LICENSE +++ b/vendor/sebastian/environment/LICENSE @@ -1,6 +1,6 @@ sebastian/environment -Copyright (c) 2014-2019, Sebastian Bergmann . +Copyright (c) 2014-2020, Sebastian Bergmann . All rights reserved. Redistribution and use in source and binary forms, with or without diff --git a/vendor/sebastian/environment/README.md b/vendor/sebastian/environment/README.md index 3e854af35..24a9831e4 100644 --- a/vendor/sebastian/environment/README.md +++ b/vendor/sebastian/environment/README.md @@ -1,17 +1,22 @@ # sebastian/environment -This component provides functionality that helps writing PHP code that has runtime-specific (PHP / HHVM) execution paths. - [![Latest Stable Version](https://img.shields.io/packagist/v/sebastian/environment.svg?style=flat-square)](https://packagist.org/packages/sebastian/environment) [![Minimum PHP Version](https://img.shields.io/badge/php-%3E%3D%207.1-8892BF.svg?style=flat-square)](https://php.net/) -[![Build Status](https://travis-ci.org/sebastianbergmann/environment.svg?branch=master)](https://travis-ci.org/sebastianbergmann/environment) +[![CI Status](https://github.com/sebastianbergmann/environment/workflows/CI/badge.svg)](https://github.com/sebastianbergmann/environment/actions) +[![Type Coverage](https://shepherd.dev/github/sebastianbergmann/environment/coverage.svg)](https://shepherd.dev/github/sebastianbergmann/environment) + +This component provides functionality that helps writing PHP code that has runtime-specific (PHP / HHVM) execution paths. ## Installation You can add this library as a local, per-project dependency to your project using [Composer](https://getcomposer.org/): - composer require sebastian/environment +``` +composer require sebastian/environment +``` If you only need this library during development, for instance to run your project's test suite, then you should add it as a development-time dependency: - composer require --dev sebastian/environment +``` +composer require --dev sebastian/environment +``` diff --git a/vendor/sebastian/environment/build.xml b/vendor/sebastian/environment/build.xml deleted file mode 100644 index 591a58bbf..000000000 --- a/vendor/sebastian/environment/build.xml +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - - - - - - - - - - - - - - diff --git a/vendor/sebastian/environment/composer.json b/vendor/sebastian/environment/composer.json index d02bb384a..d50dcfd78 100644 --- a/vendor/sebastian/environment/composer.json +++ b/vendor/sebastian/environment/composer.json @@ -11,15 +11,18 @@ } ], "config": { + "platform": { + "php": "7.3.0" + }, "optimize-autoloader": true, "sort-packages": true }, "prefer-stable": true, "require": { - "php": ">=7.1" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^7.5" + "phpunit/phpunit": "^9.3" }, "suggest": { "ext-posix": "*" @@ -31,7 +34,7 @@ }, "extra": { "branch-alias": { - "dev-master": "4.2-dev" + "dev-master": "5.1-dev" } } } diff --git a/vendor/sebastian/environment/phpunit.xml b/vendor/sebastian/environment/phpunit.xml deleted file mode 100644 index 01852650c..000000000 --- a/vendor/sebastian/environment/phpunit.xml +++ /dev/null @@ -1,20 +0,0 @@ - - - - - tests - - - - - - src - - - diff --git a/vendor/sebastian/environment/src/Console.php b/vendor/sebastian/environment/src/Console.php index 947dacfc7..c4a2348f0 100644 --- a/vendor/sebastian/environment/src/Console.php +++ b/vendor/sebastian/environment/src/Console.php @@ -9,6 +9,26 @@ */ namespace SebastianBergmann\Environment; +use const DIRECTORY_SEPARATOR; +use const STDIN; +use const STDOUT; +use function defined; +use function fclose; +use function fstat; +use function function_exists; +use function getenv; +use function is_resource; +use function is_string; +use function posix_isatty; +use function preg_match; +use function proc_close; +use function proc_open; +use function sapi_windows_vt100_support; +use function shell_exec; +use function stream_get_contents; +use function stream_isatty; +use function trim; + final class Console { /** @@ -34,26 +54,26 @@ final class Console */ public function hasColorSupport(): bool { - if ('Hyper' === \getenv('TERM_PROGRAM')) { + if ('Hyper' === getenv('TERM_PROGRAM')) { return true; } if ($this->isWindows()) { // @codeCoverageIgnoreStart - return (\defined('STDOUT') && \function_exists('sapi_windows_vt100_support') && @\sapi_windows_vt100_support(\STDOUT)) - || false !== \getenv('ANSICON') - || 'ON' === \getenv('ConEmuANSI') - || 'xterm' === \getenv('TERM'); + return (defined('STDOUT') && function_exists('sapi_windows_vt100_support') && @sapi_windows_vt100_support(STDOUT)) + || false !== getenv('ANSICON') + || 'ON' === getenv('ConEmuANSI') + || 'xterm' === getenv('TERM'); // @codeCoverageIgnoreEnd } - if (!\defined('STDOUT')) { + if (!defined('STDOUT')) { // @codeCoverageIgnoreStart return false; // @codeCoverageIgnoreEnd } - return $this->isInteractive(\STDOUT); + return $this->isInteractive(STDOUT); } /** @@ -63,7 +83,7 @@ final class Console */ public function getNumberOfColumns(): int { - if (!$this->isInteractive(\defined('STDIN') ? \STDIN : self::STDIN)) { + if (!$this->isInteractive(defined('STDIN') ? STDIN : self::STDIN)) { return 80; } @@ -84,23 +104,28 @@ final class Console */ public function isInteractive($fileDescriptor = self::STDOUT): bool { - if (\is_resource($fileDescriptor)) { + if (is_resource($fileDescriptor)) { // These functions require a descriptor that is a real resource, not a numeric ID of it - if (\function_exists('stream_isatty') && @\stream_isatty($fileDescriptor)) { + if (function_exists('stream_isatty') && @stream_isatty($fileDescriptor)) { return true; } - $stat = @\fstat(\STDOUT); // Check if formatted mode is S_IFCHR - return $stat ? 0020000 === ($stat['mode'] & 0170000) : false; + if (function_exists('fstat') && @stream_isatty($fileDescriptor)) { + $stat = @fstat(STDOUT); + + return $stat ? 0020000 === ($stat['mode'] & 0170000) : false; + } + + return false; } - return \function_exists('posix_isatty') && @\posix_isatty($fileDescriptor); + return function_exists('posix_isatty') && @posix_isatty($fileDescriptor); } private function isWindows(): bool { - return \DIRECTORY_SEPARATOR === '\\'; + return DIRECTORY_SEPARATOR === '\\'; } /** @@ -108,13 +133,13 @@ final class Console */ private function getNumberOfColumnsInteractive(): int { - if (\function_exists('shell_exec') && \preg_match('#\d+ (\d+)#', \shell_exec('stty size') ?: '', $match) === 1) { + if (function_exists('shell_exec') && preg_match('#\d+ (\d+)#', shell_exec('stty size') ?: '', $match) === 1) { if ((int) $match[1] > 0) { return (int) $match[1]; } } - if (\function_exists('shell_exec') && \preg_match('#columns = (\d+);#', \shell_exec('stty') ?: '', $match) === 1) { + if (function_exists('shell_exec') && preg_match('#columns = (\d+);#', shell_exec('stty') ?: '', $match) === 1) { if ((int) $match[1] > 0) { return (int) $match[1]; } @@ -128,13 +153,13 @@ final class Console */ private function getNumberOfColumnsWindows(): int { - $ansicon = \getenv('ANSICON'); + $ansicon = getenv('ANSICON'); $columns = 80; - if (\is_string($ansicon) && \preg_match('/^(\d+)x\d+ \(\d+x(\d+)\)$/', \trim($ansicon), $matches)) { - $columns = $matches[1]; - } elseif (\function_exists('proc_open')) { - $process = \proc_open( + if (is_string($ansicon) && preg_match('/^(\d+)x\d+ \(\d+x(\d+)\)$/', trim($ansicon), $matches)) { + $columns = (int) $matches[1]; + } elseif (function_exists('proc_open')) { + $process = proc_open( 'mode CON', [ 1 => ['pipe', 'w'], @@ -146,15 +171,15 @@ final class Console ['suppress_errors' => true] ); - if (\is_resource($process)) { - $info = \stream_get_contents($pipes[1]); + if (is_resource($process)) { + $info = stream_get_contents($pipes[1]); - \fclose($pipes[1]); - \fclose($pipes[2]); - \proc_close($process); + fclose($pipes[1]); + fclose($pipes[2]); + proc_close($process); - if (\preg_match('/--------+\r?\n.+?(\d+)\r?\n.+?(\d+)\r?\n/', $info, $matches)) { - $columns = $matches[2]; + if (preg_match('/--------+\r?\n.+?(\d+)\r?\n.+?(\d+)\r?\n/', $info, $matches)) { + $columns = (int) $matches[2]; } } } diff --git a/vendor/sebastian/environment/src/OperatingSystem.php b/vendor/sebastian/environment/src/OperatingSystem.php index 67a35bc9a..1f3ebca7c 100644 --- a/vendor/sebastian/environment/src/OperatingSystem.php +++ b/vendor/sebastian/environment/src/OperatingSystem.php @@ -9,6 +9,11 @@ */ namespace SebastianBergmann\Environment; +use const DIRECTORY_SEPARATOR; +use const PHP_OS; +use const PHP_OS_FAMILY; +use function defined; + final class OperatingSystem { /** @@ -17,15 +22,15 @@ final class OperatingSystem */ public function getFamily(): string { - if (\defined('PHP_OS_FAMILY')) { - return \PHP_OS_FAMILY; + if (defined('PHP_OS_FAMILY')) { + return PHP_OS_FAMILY; } - if (\DIRECTORY_SEPARATOR === '\\') { + if (DIRECTORY_SEPARATOR === '\\') { return 'Windows'; } - switch (\PHP_OS) { + switch (PHP_OS) { case 'Darwin': return 'Darwin'; diff --git a/vendor/sebastian/environment/src/Runtime.php b/vendor/sebastian/environment/src/Runtime.php index 0cbc4db67..311aefcb6 100644 --- a/vendor/sebastian/environment/src/Runtime.php +++ b/vendor/sebastian/environment/src/Runtime.php @@ -9,6 +9,27 @@ */ namespace SebastianBergmann\Environment; +use const PHP_BINARY; +use const PHP_BINDIR; +use const PHP_MAJOR_VERSION; +use const PHP_SAPI; +use const PHP_VERSION; +use function array_map; +use function array_merge; +use function defined; +use function escapeshellarg; +use function explode; +use function extension_loaded; +use function getenv; +use function ini_get; +use function is_readable; +use function parse_ini_file; +use function php_ini_loaded_file; +use function php_ini_scanned_files; +use function phpversion; +use function sprintf; +use function strpos; + /** * Utility class for HHVM/PHP environment handling. */ @@ -29,27 +50,41 @@ final class Runtime } /** - * Returns true when Zend OPcache is loaded, enabled, and is configured to discard comments. + * Returns true when Zend OPcache is loaded, enabled, + * and is configured to discard comments. */ public function discardsComments(): bool { - if (!\extension_loaded('Zend OPcache')) { + if (!$this->isOpcacheActive()) { return false; } - if (\ini_get('opcache.save_comments') !== '0') { + if (ini_get('opcache.save_comments') !== '0') { return false; } - if ((\PHP_SAPI === 'cli' || \PHP_SAPI === 'phpdbg') && \ini_get('opcache.enable_cli') === '1') { - return true; + return true; + } + + /** + * Returns true when Zend OPcache is loaded, enabled, + * and is configured to perform just-in-time compilation. + */ + public function performsJustInTimeCompilation(): bool + { + if (PHP_MAJOR_VERSION < 8) { + return false; } - if (\PHP_SAPI !== 'cli' && \PHP_SAPI !== 'phpdbg' && \ini_get('opcache.enable') === '1') { - return true; + if (!$this->isOpcacheActive()) { + return false; } - return false; + if (strpos(ini_get('opcache.jit'), '0') === 0) { + return false; + } + + return true; } /** @@ -61,30 +96,30 @@ final class Runtime // HHVM if (self::$binary === null && $this->isHHVM()) { // @codeCoverageIgnoreStart - if ((self::$binary = \getenv('PHP_BINARY')) === false) { - self::$binary = \PHP_BINARY; + if ((self::$binary = getenv('PHP_BINARY')) === false) { + self::$binary = PHP_BINARY; } - self::$binary = \escapeshellarg(self::$binary) . ' --php' . + self::$binary = escapeshellarg(self::$binary) . ' --php' . ' -d hhvm.php7.all=1'; // @codeCoverageIgnoreEnd } - if (self::$binary === null && \PHP_BINARY !== '') { - self::$binary = \escapeshellarg(\PHP_BINARY); + if (self::$binary === null && PHP_BINARY !== '') { + self::$binary = escapeshellarg(PHP_BINARY); } if (self::$binary === null) { // @codeCoverageIgnoreStart $possibleBinaryLocations = [ - \PHP_BINDIR . '/php', - \PHP_BINDIR . '/php-cli.exe', - \PHP_BINDIR . '/php.exe', + PHP_BINDIR . '/php', + PHP_BINDIR . '/php-cli.exe', + PHP_BINDIR . '/php.exe', ]; foreach ($possibleBinaryLocations as $binary) { - if (\is_readable($binary)) { - self::$binary = \escapeshellarg($binary); + if (is_readable($binary)) { + self::$binary = escapeshellarg($binary); break; } @@ -112,19 +147,19 @@ final class Runtime return $this->getNameWithVersion(); } - if ($this->hasXdebug()) { - return \sprintf( - '%s with Xdebug %s', + if ($this->hasPCOV()) { + return sprintf( + '%s with PCOV %s', $this->getNameWithVersion(), - \phpversion('xdebug') + phpversion('pcov') ); } - if ($this->hasPCOV()) { - return \sprintf( - '%s with PCOV %s', + if ($this->hasXdebug()) { + return sprintf( + '%s with Xdebug %s', $this->getNameWithVersion(), - \phpversion('pcov') + phpversion('xdebug') ); } } @@ -165,7 +200,7 @@ final class Runtime // @codeCoverageIgnoreEnd } - return \PHP_VERSION; + return PHP_VERSION; } /** @@ -173,7 +208,7 @@ final class Runtime */ public function hasXdebug(): bool { - return ($this->isPHP() || $this->isHHVM()) && \extension_loaded('xdebug'); + return ($this->isPHP() || $this->isHHVM()) && extension_loaded('xdebug'); } /** @@ -181,7 +216,7 @@ final class Runtime */ public function isHHVM(): bool { - return \defined('HHVM_VERSION'); + return defined('HHVM_VERSION'); } /** @@ -197,7 +232,7 @@ final class Runtime */ public function isPHPDBG(): bool { - return \PHP_SAPI === 'phpdbg' && !$this->isHHVM(); + return PHP_SAPI === 'phpdbg' && !$this->isHHVM(); } /** @@ -210,11 +245,11 @@ final class Runtime } /** - * Returns true when the runtime used is PHP with PCOV loaded and enabled + * Returns true when the runtime used is PHP with PCOV loaded and enabled. */ public function hasPCOV(): bool { - return $this->isPHP() && \extension_loaded('pcov') && \ini_get('pcov.enabled'); + return $this->isPHP() && extension_loaded('pcov') && ini_get('pcov.enabled'); } /** @@ -234,32 +269,49 @@ final class Runtime $diff = []; $files = []; - if ($file = \php_ini_loaded_file()) { + if ($file = php_ini_loaded_file()) { $files[] = $file; } - if ($scanned = \php_ini_scanned_files()) { - $files = \array_merge( + if ($scanned = php_ini_scanned_files()) { + $files = array_merge( $files, - \array_map( + array_map( 'trim', - \explode(",\n", $scanned) + explode(",\n", $scanned) ) ); } foreach ($files as $ini) { - $config = \parse_ini_file($ini, true); + $config = parse_ini_file($ini, true); foreach ($values as $value) { - $set = \ini_get($value); + $set = ini_get($value); if (isset($config[$value]) && $set != $config[$value]) { - $diff[] = \sprintf('%s=%s', $value, $set); + $diff[] = sprintf('%s=%s', $value, $set); } } } return $diff; } + + private function isOpcacheActive(): bool + { + if (!extension_loaded('Zend OPcache')) { + return false; + } + + if ((PHP_SAPI === 'cli' || PHP_SAPI === 'phpdbg') && ini_get('opcache.enable_cli') === '1') { + return true; + } + + if (PHP_SAPI !== 'cli' && PHP_SAPI !== 'phpdbg' && ini_get('opcache.enable') === '1') { + return true; + } + + return false; + } } diff --git a/vendor/sebastian/environment/tests/ConsoleTest.php b/vendor/sebastian/environment/tests/ConsoleTest.php deleted file mode 100644 index e7f670469..000000000 --- a/vendor/sebastian/environment/tests/ConsoleTest.php +++ /dev/null @@ -1,64 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Environment; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\Environment\Console - */ -final class ConsoleTest extends TestCase -{ - /** - * @var \SebastianBergmann\Environment\Console - */ - private $console; - - protected function setUp(): void - { - $this->console = new Console; - } - - /** - * @todo Now that this component is PHP 7-only and uses return type declarations - * this test makes even less sense than before - */ - public function testCanDetectIfStdoutIsInteractiveByDefault(): void - { - $this->assertIsBool($this->console->isInteractive()); - } - - /** - * @todo Now that this component is PHP 7-only and uses return type declarations - * this test makes even less sense than before - */ - public function testCanDetectIfFileDescriptorIsInteractive(): void - { - $this->assertIsBool($this->console->isInteractive(\STDOUT)); - } - - /** - * @todo Now that this component is PHP 7-only and uses return type declarations - * this test makes even less sense than before - */ - public function testCanDetectColorSupport(): void - { - $this->assertIsBool($this->console->hasColorSupport()); - } - - /** - * @todo Now that this component is PHP 7-only and uses return type declarations - * this test makes even less sense than before - */ - public function testCanDetectNumberOfColumns(): void - { - $this->assertIsInt($this->console->getNumberOfColumns()); - } -} diff --git a/vendor/sebastian/environment/tests/OperatingSystemTest.php b/vendor/sebastian/environment/tests/OperatingSystemTest.php deleted file mode 100644 index f48618e0a..000000000 --- a/vendor/sebastian/environment/tests/OperatingSystemTest.php +++ /dev/null @@ -1,60 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Environment; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\Environment\OperatingSystem - */ -final class OperatingSystemTest extends TestCase -{ - /** - * @var \SebastianBergmann\Environment\OperatingSystem - */ - private $os; - - protected function setUp(): void - { - $this->os = new OperatingSystem; - } - - /** - * @requires OS Linux - */ - public function testFamilyCanBeRetrieved(): void - { - $this->assertEquals('Linux', $this->os->getFamily()); - } - - /** - * @requires OS Darwin - */ - public function testFamilyReturnsDarwinWhenRunningOnDarwin(): void - { - $this->assertEquals('Darwin', $this->os->getFamily()); - } - - /** - * @requires OS Windows - */ - public function testGetFamilyReturnsWindowsWhenRunningOnWindows(): void - { - $this->assertSame('Windows', $this->os->getFamily()); - } - - /** - * @requires PHP 7.2.0 - */ - public function testGetFamilyReturnsPhpOsFamilyWhenRunningOnPhp72AndGreater(): void - { - $this->assertSame(\PHP_OS_FAMILY, $this->os->getFamily()); - } -} diff --git a/vendor/sebastian/environment/tests/RuntimeTest.php b/vendor/sebastian/environment/tests/RuntimeTest.php deleted file mode 100644 index 12be2e596..000000000 --- a/vendor/sebastian/environment/tests/RuntimeTest.php +++ /dev/null @@ -1,165 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Environment; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\Environment\Runtime - */ -final class RuntimeTest extends TestCase -{ - /** - * @var \SebastianBergmann\Environment\Runtime - */ - private $env; - - protected function setUp(): void - { - $this->env = new Runtime; - } - - /** - * @requires extension xdebug - */ - public function testCanCollectCodeCoverageWhenXdebugExtensionIsEnabled(): void - { - $this->assertTrue($this->env->canCollectCodeCoverage()); - } - - /** - * @requires extension pcov - */ - public function testCanCollectCodeCoverageWhenPcovExtensionIsEnabled(): void - { - $this->assertTrue($this->env->canCollectCodeCoverage()); - } - - public function testCanCollectCodeCoverageWhenRunningOnPhpdbg(): void - { - $this->markTestSkippedWhenNotRunningOnPhpdbg(); - - $this->assertTrue($this->env->canCollectCodeCoverage()); - } - - public function testBinaryCanBeRetrieved(): void - { - $this->assertNotEmpty($this->env->getBinary()); - } - - /** - * @requires PHP - */ - public function testIsHhvmReturnsFalseWhenRunningOnPhp(): void - { - $this->assertFalse($this->env->isHHVM()); - } - - /** - * @requires PHP - */ - public function testIsPhpReturnsTrueWhenRunningOnPhp(): void - { - $this->markTestSkippedWhenRunningOnPhpdbg(); - - $this->assertTrue($this->env->isPHP()); - } - - /** - * @requires extension pcov - */ - public function testPCOVCanBeDetected(): void - { - $this->assertTrue($this->env->hasPCOV()); - } - - public function testPhpdbgCanBeDetected(): void - { - $this->markTestSkippedWhenNotRunningOnPhpdbg(); - - $this->assertTrue($this->env->hasPHPDBGCodeCoverage()); - } - - /** - * @requires extension xdebug - */ - public function testXdebugCanBeDetected(): void - { - $this->markTestSkippedWhenRunningOnPhpdbg(); - - $this->assertTrue($this->env->hasXdebug()); - } - - public function testNameAndVersionCanBeRetrieved(): void - { - $this->assertNotEmpty($this->env->getNameWithVersion()); - } - - public function testGetNameReturnsPhpdbgWhenRunningOnPhpdbg(): void - { - $this->markTestSkippedWhenNotRunningOnPhpdbg(); - - $this->assertSame('PHPDBG', $this->env->getName()); - } - - /** - * @requires PHP - */ - public function testGetNameReturnsPhpdbgWhenRunningOnPhp(): void - { - $this->markTestSkippedWhenRunningOnPhpdbg(); - - $this->assertSame('PHP', $this->env->getName()); - } - - public function testNameAndCodeCoverageDriverCanBeRetrieved(): void - { - $this->assertNotEmpty($this->env->getNameWithVersionAndCodeCoverageDriver()); - } - - /** - * @requires PHP - */ - public function testGetVersionReturnsPhpVersionWhenRunningPhp(): void - { - $this->assertSame(\PHP_VERSION, $this->env->getVersion()); - } - - /** - * @requires PHP - */ - public function testGetVendorUrlReturnsPhpDotNetWhenRunningPhp(): void - { - $this->assertSame('https://secure.php.net/', $this->env->getVendorUrl()); - } - - private function markTestSkippedWhenNotRunningOnPhpdbg(): void - { - if ($this->isRunningOnPhpdbg()) { - return; - } - - $this->markTestSkipped('PHPDBG is required.'); - } - - private function markTestSkippedWhenRunningOnPhpdbg(): void - { - if (!$this->isRunningOnPhpdbg()) { - return; - } - - $this->markTestSkipped('Cannot run on PHPDBG'); - } - - private function isRunningOnPhpdbg(): bool - { - return \PHP_SAPI === 'phpdbg'; - } -} diff --git a/vendor/sebastian/exporter/.github/FUNDING.yml b/vendor/sebastian/exporter/.github/FUNDING.yml deleted file mode 100644 index b19ea81a0..000000000 --- a/vendor/sebastian/exporter/.github/FUNDING.yml +++ /dev/null @@ -1 +0,0 @@ -patreon: s_bergmann diff --git a/vendor/sebastian/exporter/.gitignore b/vendor/sebastian/exporter/.gitignore deleted file mode 100644 index c79ecfa8b..000000000 --- a/vendor/sebastian/exporter/.gitignore +++ /dev/null @@ -1,5 +0,0 @@ -/.idea -/composer.lock -/vendor -/.php_cs -/.php_cs.cache diff --git a/vendor/sebastian/exporter/.php_cs.dist b/vendor/sebastian/exporter/.php_cs.dist deleted file mode 100644 index c072f5b11..000000000 --- a/vendor/sebastian/exporter/.php_cs.dist +++ /dev/null @@ -1,190 +0,0 @@ - - -For the full copyright and license information, please view the LICENSE -file that was distributed with this source code. -EOF; - -return PhpCsFixer\Config::create() - ->setRiskyAllowed(true) - ->setRules( - [ - 'align_multiline_comment' => true, - 'array_indentation' => true, - 'array_syntax' => ['syntax' => 'short'], - 'binary_operator_spaces' => [ - 'operators' => [ - '=' => 'align', - '=>' => 'align', - ], - ], - 'blank_line_after_namespace' => true, - 'blank_line_before_statement' => [ - 'statements' => [ - 'break', - 'continue', - 'declare', - 'do', - 'for', - 'foreach', - 'if', - 'include', - 'include_once', - 'require', - 'require_once', - 'return', - 'switch', - 'throw', - 'try', - 'while', - 'yield', - ], - ], - 'braces' => true, - 'cast_spaces' => true, - 'class_attributes_separation' => ['elements' => ['const', 'method', 'property']], - 'combine_consecutive_issets' => true, - 'combine_consecutive_unsets' => true, - 'compact_nullable_typehint' => true, - 'concat_space' => ['spacing' => 'one'], - 'declare_equal_normalize' => ['space' => 'none'], - 'declare_strict_types' => true, - 'dir_constant' => true, - 'elseif' => true, - 'encoding' => true, - 'full_opening_tag' => true, - 'function_declaration' => true, - 'header_comment' => ['header' => $header, 'separate' => 'none'], - 'indentation_type' => true, - 'is_null' => true, - 'line_ending' => true, - 'list_syntax' => ['syntax' => 'short'], - 'logical_operators' => true, - 'lowercase_cast' => true, - 'lowercase_constants' => true, - 'lowercase_keywords' => true, - 'lowercase_static_reference' => true, - 'magic_constant_casing' => true, - 'method_argument_space' => ['ensure_fully_multiline' => true], - 'modernize_types_casting' => true, - 'multiline_comment_opening_closing' => true, - 'multiline_whitespace_before_semicolons' => true, - 'native_constant_invocation' => true, - 'native_function_casing' => true, - 'native_function_invocation' => true, - 'new_with_braces' => false, - 'no_alias_functions' => true, - 'no_alternative_syntax' => true, - 'no_blank_lines_after_class_opening' => true, - 'no_blank_lines_after_phpdoc' => true, - 'no_blank_lines_before_namespace' => true, - 'no_closing_tag' => true, - 'no_empty_comment' => true, - 'no_empty_phpdoc' => true, - 'no_empty_statement' => true, - 'no_extra_blank_lines' => true, - 'no_homoglyph_names' => true, - 'no_leading_import_slash' => true, - 'no_leading_namespace_whitespace' => true, - 'no_mixed_echo_print' => ['use' => 'print'], - 'no_multiline_whitespace_around_double_arrow' => true, - 'no_null_property_initialization' => true, - 'no_php4_constructor' => true, - 'no_short_bool_cast' => true, - 'no_short_echo_tag' => true, - 'no_singleline_whitespace_before_semicolons' => true, - 'no_spaces_after_function_name' => true, - 'no_spaces_inside_parenthesis' => true, - 'no_superfluous_elseif' => true, - 'no_superfluous_phpdoc_tags' => true, - 'no_trailing_comma_in_list_call' => true, - 'no_trailing_comma_in_singleline_array' => true, - 'no_trailing_whitespace' => true, - 'no_trailing_whitespace_in_comment' => true, - 'no_unneeded_control_parentheses' => true, - 'no_unneeded_curly_braces' => true, - 'no_unneeded_final_method' => true, - 'no_unreachable_default_argument_value' => true, - 'no_unset_on_property' => true, - 'no_unused_imports' => true, - 'no_useless_else' => true, - 'no_useless_return' => true, - 'no_whitespace_before_comma_in_array' => true, - 'no_whitespace_in_blank_line' => true, - 'non_printable_character' => true, - 'normalize_index_brace' => true, - 'object_operator_without_whitespace' => true, - 'ordered_class_elements' => [ - 'order' => [ - 'use_trait', - 'constant_public', - 'constant_protected', - 'constant_private', - 'property_public_static', - 'property_protected_static', - 'property_private_static', - 'property_public', - 'property_protected', - 'property_private', - 'method_public_static', - 'construct', - 'destruct', - 'magic', - 'phpunit', - 'method_public', - 'method_protected', - 'method_private', - 'method_protected_static', - 'method_private_static', - ], - ], - 'ordered_imports' => true, - 'phpdoc_add_missing_param_annotation' => true, - 'phpdoc_align' => true, - 'phpdoc_annotation_without_dot' => true, - 'phpdoc_indent' => true, - 'phpdoc_no_access' => true, - 'phpdoc_no_empty_return' => true, - 'phpdoc_no_package' => true, - 'phpdoc_order' => true, - 'phpdoc_return_self_reference' => true, - 'phpdoc_scalar' => true, - 'phpdoc_separation' => true, - 'phpdoc_single_line_var_spacing' => true, - 'phpdoc_to_comment' => true, - 'phpdoc_trim' => true, - 'phpdoc_trim_consecutive_blank_line_separation' => true, - 'phpdoc_types' => true, - 'phpdoc_types_order' => true, - 'phpdoc_var_without_name' => true, - 'pow_to_exponentiation' => true, - 'protected_to_private' => true, - 'return_assignment' => true, - 'return_type_declaration' => ['space_before' => 'none'], - 'self_accessor' => true, - 'semicolon_after_instruction' => true, - 'set_type_to_cast' => true, - 'short_scalar_cast' => true, - 'simplified_null_return' => true, - 'single_blank_line_at_eof' => true, - 'single_import_per_statement' => true, - 'single_line_after_imports' => true, - 'single_quote' => true, - 'standardize_not_equals' => true, - 'ternary_to_null_coalescing' => true, - 'trim_array_spaces' => true, - 'unary_operator_spaces' => true, - 'visibility_required' => true, - //'void_return' => true, - 'whitespace_after_comma_in_array' => true, - ] - ) - ->setFinder( - PhpCsFixer\Finder::create() - ->files() - ->in(__DIR__ . '/src') - ->in(__DIR__ . '/tests') - ); diff --git a/vendor/sebastian/exporter/.travis.yml b/vendor/sebastian/exporter/.travis.yml deleted file mode 100644 index 7f3e35bb8..000000000 --- a/vendor/sebastian/exporter/.travis.yml +++ /dev/null @@ -1,24 +0,0 @@ -language: php - -php: - - 7.0 - - 7.1 - - 7.2 - - 7.3 - - 7.4snapshot - -before_install: - - composer self-update - - composer clear-cache - -install: - - travis_retry composer update --no-interaction --no-ansi --no-progress --no-suggest --optimize-autoloader --prefer-stable - -script: - - ./vendor/bin/phpunit --coverage-clover=coverage.xml - -after_success: - - bash <(curl -s https://codecov.io/bash) - -notifications: - email: false diff --git a/vendor/sebastian/exporter/ChangeLog.md b/vendor/sebastian/exporter/ChangeLog.md index 150eeaa15..913912c59 100644 --- a/vendor/sebastian/exporter/ChangeLog.md +++ b/vendor/sebastian/exporter/ChangeLog.md @@ -2,11 +2,29 @@ All notable changes are documented in this file using the [Keep a CHANGELOG](https://keepachangelog.com/) principles. -## [3.1.3] - 2020-11-30 +## [4.0.3] - 2020-09-28 ### Changed -* Changed PHP version constraint in `composer.json` from `^7.0` to `>=7.0` +* Changed PHP version constraint in `composer.json` from `^7.3 || ^8.0` to `>=7.3` + +## [4.0.2] - 2020-06-26 + +### Added + +* This component is now supported on PHP 8 + +## [4.0.1] - 2020-06-15 + +### Changed + +* Tests etc. are now ignored for archive exports + +## [4.0.0] - 2020-02-07 + +### Removed + +* This component is no longer supported on PHP 7.0, PHP 7.1, and PHP 7.2 ## [3.1.2] - 2019-09-14 @@ -18,5 +36,8 @@ All notable changes are documented in this file using the [Keep a CHANGELOG](htt * Remove HHVM-specific code that is no longer needed -[3.1.3]: https://github.com/sebastianbergmann/exporter/compare/3.1.2...3.1.3 +[4.0.3]: https://github.com/sebastianbergmann/exporter/compare/4.0.2...4.0.3 +[4.0.2]: https://github.com/sebastianbergmann/exporter/compare/4.0.1...4.0.2 +[4.0.1]: https://github.com/sebastianbergmann/exporter/compare/4.0.0...4.0.1 +[4.0.0]: https://github.com/sebastianbergmann/exporter/compare/3.1.2...4.0.0 [3.1.2]: https://github.com/sebastianbergmann/exporter/compare/3.1.1...3.1.2 diff --git a/vendor/sebastian/exporter/LICENSE b/vendor/sebastian/exporter/LICENSE index f77dc5af5..aa33509cf 100644 --- a/vendor/sebastian/exporter/LICENSE +++ b/vendor/sebastian/exporter/LICENSE @@ -1,6 +1,6 @@ Exporter -Copyright (c) 2002-2019, Sebastian Bergmann . +Copyright (c) 2002-2020, Sebastian Bergmann . All rights reserved. Redistribution and use in source and binary forms, with or without diff --git a/vendor/sebastian/exporter/README.md b/vendor/sebastian/exporter/README.md index 4c838ab3b..ed8719f56 100644 --- a/vendor/sebastian/exporter/README.md +++ b/vendor/sebastian/exporter/README.md @@ -1,10 +1,24 @@ -Exporter -======== +# sebastian/exporter -[![Build Status](https://secure.travis-ci.org/sebastianbergmann/exporter.png?branch=master)](https://travis-ci.org/sebastianbergmann/exporter) +[![CI Status](https://github.com/sebastianbergmann/exporter/workflows/CI/badge.svg)](https://github.com/sebastianbergmann/exporter/actions) +[![Type Coverage](https://shepherd.dev/github/sebastianbergmann/exporter/coverage.svg)](https://shepherd.dev/github/sebastianbergmann/exporter) This component provides the functionality to export PHP variables for visualization. +## Installation + +You can add this library as a local, per-project dependency to your project using [Composer](https://getcomposer.org/): + +``` +composer require sebastian/exporter +``` + +If you only need this library during development, for instance to run your project's test suite, then you should add it as a development-time dependency: + +``` +composer require --dev sebastian/exporter +``` + ## Usage Exporting: @@ -158,14 +172,3 @@ space LONG_STRING ); ``` - -## Installation - -You can add this library as a local, per-project dependency to your project using [Composer](https://getcomposer.org/): - - composer require sebastian/exporter - -If you only need this library during development, for instance to run your project's test suite, then you should add it as a development-time dependency: - - composer require --dev sebastian/exporter - diff --git a/vendor/sebastian/exporter/build.xml b/vendor/sebastian/exporter/build.xml deleted file mode 100644 index c835c8a4e..000000000 --- a/vendor/sebastian/exporter/build.xml +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - - - - - - - - - - - - - - diff --git a/vendor/sebastian/exporter/composer.json b/vendor/sebastian/exporter/composer.json index 50e3be75c..477d5edd1 100644 --- a/vendor/sebastian/exporter/composer.json +++ b/vendor/sebastian/exporter/composer.json @@ -27,16 +27,19 @@ } ], "config": { + "platform": { + "php": "7.3.0" + }, "optimize-autoloader": true, "sort-packages": true }, "prefer-stable": true, "require": { - "php": ">=7.0", - "sebastian/recursion-context": "^3.0" + "php": ">=7.3", + "sebastian/recursion-context": "^4.0" }, "require-dev": { - "phpunit/phpunit": "^6.0", + "phpunit/phpunit": "^9.3", "ext-mbstring": "*" }, "autoload": { @@ -46,7 +49,7 @@ }, "extra": { "branch-alias": { - "dev-master": "3.1.x-dev" + "dev-master": "4.0-dev" } } } diff --git a/vendor/sebastian/exporter/phpunit.xml b/vendor/sebastian/exporter/phpunit.xml deleted file mode 100644 index 68febeb04..000000000 --- a/vendor/sebastian/exporter/phpunit.xml +++ /dev/null @@ -1,19 +0,0 @@ - - - - tests - - - - - src - - - diff --git a/vendor/sebastian/exporter/src/Exporter.php b/vendor/sebastian/exporter/src/Exporter.php index ea31b8091..e6fff5a49 100644 --- a/vendor/sebastian/exporter/src/Exporter.php +++ b/vendor/sebastian/exporter/src/Exporter.php @@ -1,6 +1,6 @@ * @@ -9,7 +9,29 @@ */ namespace SebastianBergmann\Exporter; +use function bin2hex; +use function count; +use function function_exists; +use function get_class; +use function get_resource_type; +use function implode; +use function is_array; +use function is_float; +use function is_object; +use function is_resource; +use function is_string; +use function mb_strlen; +use function mb_substr; +use function preg_match; +use function spl_object_hash; +use function sprintf; +use function str_repeat; +use function str_replace; +use function strlen; +use function substr; +use function var_export; use SebastianBergmann\RecursionContext\Context; +use SplObjectStorage; /** * A nifty utility for visualizing PHP variables. @@ -25,7 +47,7 @@ use SebastianBergmann\RecursionContext\Context; class Exporter { /** - * Exports a value as a string + * Exports a value as a string. * * The output of this method is similar to the output of print_r(), but * improved in various aspects: @@ -65,11 +87,11 @@ class Exporter $context->add($data); foreach ($array as $key => $value) { - if (\is_array($value)) { + if (is_array($value)) { if ($context->contains($data[$key]) !== false) { $result[] = '*RECURSION*'; } else { - $result[] = \sprintf( + $result[] = sprintf( 'array(%s)', $this->shortenedRecursiveExport($data[$key], $context) ); @@ -79,11 +101,11 @@ class Exporter } } - return \implode(', ', $result); + return implode(', ', $result); } /** - * Exports a value into a single-line string + * Exports a value into a single-line string. * * The output of this method is similar to the output of * SebastianBergmann\Exporter\Exporter::export(). @@ -97,34 +119,34 @@ class Exporter */ public function shortenedExport($value) { - if (\is_string($value)) { - $string = \str_replace("\n", '', $this->export($value)); + if (is_string($value)) { + $string = str_replace("\n", '', $this->export($value)); - if (\function_exists('mb_strlen')) { - if (\mb_strlen($string) > 40) { - $string = \mb_substr($string, 0, 30) . '...' . \mb_substr($string, -7); + if (function_exists('mb_strlen')) { + if (mb_strlen($string) > 40) { + $string = mb_substr($string, 0, 30) . '...' . mb_substr($string, -7); } } else { - if (\strlen($string) > 40) { - $string = \substr($string, 0, 30) . '...' . \substr($string, -7); + if (strlen($string) > 40) { + $string = substr($string, 0, 30) . '...' . substr($string, -7); } } return $string; } - if (\is_object($value)) { - return \sprintf( + if (is_object($value)) { + return sprintf( '%s Object (%s)', - \get_class($value), - \count($this->toArray($value)) > 0 ? '...' : '' + get_class($value), + count($this->toArray($value)) > 0 ? '...' : '' ); } - if (\is_array($value)) { - return \sprintf( + if (is_array($value)) { + return sprintf( 'Array (%s)', - \count($value) > 0 ? '...' : '' + count($value) > 0 ? '...' : '' ); } @@ -139,7 +161,7 @@ class Exporter */ public function toArray($value) { - if (!\is_object($value)) { + if (!is_object($value)) { return (array) $value; } @@ -157,7 +179,7 @@ class Exporter // private $property => "\0Classname\0property" // protected $property => "\0*\0property" // public $property => "property" - if (\preg_match('/^\0.+\0(.+)$/', (string) $key, $matches)) { + if (preg_match('/^\0.+\0(.+)$/', (string) $key, $matches)) { $key = $matches[1]; } @@ -172,9 +194,9 @@ class Exporter // Some internal classes like SplObjectStorage don't work with the // above (fast) mechanism nor with reflection in Zend. // Format the output similarly to print_r() in this case - if ($value instanceof \SplObjectStorage) { + if ($value instanceof SplObjectStorage) { foreach ($value as $key => $val) { - $array[\spl_object_hash($val)] = [ + $array[spl_object_hash($val)] = [ 'obj' => $val, 'inf' => $value->getInfo(), ]; @@ -185,7 +207,7 @@ class Exporter } /** - * Recursive implementation of export + * Recursive implementation of export. * * @param mixed $value The value to export * @param int $indentation The indentation level of the 2nd+ line @@ -209,29 +231,29 @@ class Exporter return 'false'; } - if (\is_float($value) && (float) ((int) $value) === $value) { + if (is_float($value) && (float) ((int) $value) === $value) { return "$value.0"; } - if (\is_resource($value)) { - return \sprintf( + if (is_resource($value)) { + return sprintf( 'resource(%d) of type (%s)', $value, - \get_resource_type($value) + get_resource_type($value) ); } - if (\is_string($value)) { + if (is_string($value)) { // Match for most non printable chars somewhat taking multibyte chars into account - if (\preg_match('/[^\x09-\x0d\x1b\x20-\xff]/', $value)) { - return 'Binary String: 0x' . \bin2hex($value); + if (preg_match('/[^\x09-\x0d\x1b\x20-\xff]/', $value)) { + return 'Binary String: 0x' . bin2hex($value); } return "'" . - \str_replace( + str_replace( '', "\n", - \str_replace( + str_replace( ["\r\n", "\n\r", "\r", "\n"], ['\r\n', '\n\r', '\r', '\n'], $value @@ -240,13 +262,13 @@ class Exporter "'"; } - $whitespace = \str_repeat(' ', (int)(4 * $indentation)); + $whitespace = str_repeat(' ', (int) (4 * $indentation)); if (!$processed) { $processed = new Context; } - if (\is_array($value)) { + if (is_array($value)) { if (($key = $processed->contains($value)) !== false) { return 'Array &' . $key; } @@ -255,9 +277,9 @@ class Exporter $key = $processed->add($value); $values = ''; - if (\count($array) > 0) { + if (count($array) > 0) { foreach ($array as $k => $v) { - $values .= \sprintf( + $values .= sprintf( '%s %s => %s' . "\n", $whitespace, $this->recursiveExport($k, $indentation), @@ -268,23 +290,23 @@ class Exporter $values = "\n" . $values . $whitespace; } - return \sprintf('Array &%s (%s)', $key, $values); + return sprintf('Array &%s (%s)', $key, $values); } - if (\is_object($value)) { - $class = \get_class($value); + if (is_object($value)) { + $class = get_class($value); if ($hash = $processed->contains($value)) { - return \sprintf('%s Object &%s', $class, $hash); + return sprintf('%s Object &%s', $class, $hash); } $hash = $processed->add($value); $values = ''; $array = $this->toArray($value); - if (\count($array) > 0) { + if (count($array) > 0) { foreach ($array as $k => $v) { - $values .= \sprintf( + $values .= sprintf( '%s %s => %s' . "\n", $whitespace, $this->recursiveExport($k, $indentation), @@ -295,9 +317,9 @@ class Exporter $values = "\n" . $values . $whitespace; } - return \sprintf('%s Object &%s (%s)', $class, $hash, $values); + return sprintf('%s Object &%s (%s)', $class, $hash, $values); } - return \var_export($value, true); + return var_export($value, true); } } diff --git a/vendor/sebastian/exporter/tests/ExporterTest.php b/vendor/sebastian/exporter/tests/ExporterTest.php deleted file mode 100644 index 7fac74cce..000000000 --- a/vendor/sebastian/exporter/tests/ExporterTest.php +++ /dev/null @@ -1,432 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Exporter; - -use PHPUnit\Framework\TestCase; -use SebastianBergmann\RecursionContext\Context; - -/** - * @covers SebastianBergmann\Exporter\Exporter - */ -class ExporterTest extends TestCase -{ - /** - * @var Exporter - */ - private $exporter; - - protected function setUp() - { - $this->exporter = new Exporter; - } - - public function exportProvider() - { - $obj2 = new \stdClass; - $obj2->foo = 'bar'; - - $obj3 = (object) [1, 2, "Test\r\n", 4, 5, 6, 7, 8]; - - $obj = new \stdClass; - //@codingStandardsIgnoreStart - $obj->null = null; - //@codingStandardsIgnoreEnd - $obj->boolean = true; - $obj->integer = 1; - $obj->double = 1.2; - $obj->string = '1'; - $obj->text = "this\nis\na\nvery\nvery\nvery\nvery\nvery\nvery\rlong\n\rtext"; - $obj->object = $obj2; - $obj->objectagain = $obj2; - $obj->array = ['foo' => 'bar']; - $obj->self = $obj; - - $storage = new \SplObjectStorage; - $storage->attach($obj2); - $storage->foo = $obj2; - - return [ - 'export null' => [null, 'null'], - 'export boolean true' => [true, 'true'], - 'export boolean false' => [false, 'false'], - 'export int 1' => [1, '1'], - 'export float 1.0' => [1.0, '1.0'], - 'export float 1.2' => [1.2, '1.2'], - 'export stream' => [\fopen('php://memory', 'r'), 'resource(%d) of type (stream)'], - 'export numeric string' => ['1', "'1'"], - 'export multidimentional array' => [[[1, 2, 3], [3, 4, 5]], - << Array &1 ( - 0 => 1 - 1 => 2 - 2 => 3 - ) - 1 => Array &2 ( - 0 => 3 - 1 => 4 - 2 => 5 - ) -) -EOF - ], - // \n\r and \r is converted to \n - 'export multiline text' => ["this\nis\na\nvery\nvery\nvery\nvery\nvery\nvery\rlong\n\rtext", - << [new \stdClass, 'stdClass Object &%x ()'], - 'export non empty stdclass' => [$obj, - << null - 'boolean' => true - 'integer' => 1 - 'double' => 1.2 - 'string' => '1' - 'text' => 'this\\n -is\\n -a\\n -very\\n -very\\n -very\\n -very\\n -very\\n -very\\r -long\\n\\r -text' - 'object' => stdClass Object &%x ( - 'foo' => 'bar' - ) - 'objectagain' => stdClass Object &%x - 'array' => Array &%d ( - 'foo' => 'bar' - ) - 'self' => stdClass Object &%x -) -EOF - ], - 'export empty array' => [[], 'Array &%d ()'], - 'export splObjectStorage' => [$storage, - << stdClass Object &%x ( - 'foo' => 'bar' - ) - '%x' => Array &0 ( - 'obj' => stdClass Object &%x - 'inf' => null - ) -) -EOF - ], - 'export stdClass with numeric properties' => [$obj3, - << 1 - 1 => 2 - 2 => 'Test\\r\\n -' - 3 => 4 - 4 => 5 - 5 => 6 - 6 => 7 - 7 => 8 -) -EOF - ], - [ - \chr(0) . \chr(1) . \chr(2) . \chr(3) . \chr(4) . \chr(5), - 'Binary String: 0x000102030405' - ], - [ - \implode('', \array_map('chr', \range(0x0e, 0x1f))), - 'Binary String: 0x0e0f101112131415161718191a1b1c1d1e1f' - ], - [ - \chr(0x00) . \chr(0x09), - 'Binary String: 0x0009' - ], - [ - '', - "''" - ], - 'export Exception without trace' => [ - new \Exception('The exception message', 42), - << 'The exception message' - 'string' => '' - 'code' => 42 - 'file' => '%s/tests/ExporterTest.php' - 'line' => %d - 'previous' => null -) -EOF - ], - 'export Error without trace' => [ - new \Error('The exception message', 42), - << 'The exception message' - 'string' => '' - 'code' => 42 - 'file' => '%s/tests/ExporterTest.php' - 'line' => %d - 'previous' => null -) -EOF - ], - ]; - } - - /** - * @dataProvider exportProvider - */ - public function testExport($value, $expected) - { - $this->assertStringMatchesFormat( - $expected, - $this->trimNewline($this->exporter->export($value)) - ); - } - - public function testExport2() - { - if (\PHP_VERSION === '5.3.3') { - $this->markTestSkipped('Skipped due to "Nesting level too deep - recursive dependency?" fatal error'); - } - - $obj = new \stdClass; - $obj->foo = 'bar'; - - $array = [ - 0 => 0, - 'null' => null, - 'boolean' => true, - 'integer' => 1, - 'double' => 1.2, - 'string' => '1', - 'text' => "this\nis\na\nvery\nvery\nvery\nvery\nvery\nvery\rlong\n\rtext", - 'object' => $obj, - 'objectagain' => $obj, - 'array' => ['foo' => 'bar'], - ]; - - $array['self'] = &$array; - - $expected = << 0 - 'null' => null - 'boolean' => true - 'integer' => 1 - 'double' => 1.2 - 'string' => '1' - 'text' => 'this\\n -is\\n -a\\n -very\\n -very\\n -very\\n -very\\n -very\\n -very\\r -long\\n\\r -text' - 'object' => stdClass Object &%x ( - 'foo' => 'bar' - ) - 'objectagain' => stdClass Object &%x - 'array' => Array &%d ( - 'foo' => 'bar' - ) - 'self' => Array &%d ( - 0 => 0 - 'null' => null - 'boolean' => true - 'integer' => 1 - 'double' => 1.2 - 'string' => '1' - 'text' => 'this\\n -is\\n -a\\n -very\\n -very\\n -very\\n -very\\n -very\\n -very\\r -long\\n\\r -text' - 'object' => stdClass Object &%x - 'objectagain' => stdClass Object &%x - 'array' => Array &%d ( - 'foo' => 'bar' - ) - 'self' => Array &%d - ) -) -EOF; - - $this->assertStringMatchesFormat( - $expected, - $this->trimNewline($this->exporter->export($array)) - ); - } - - public function shortenedExportProvider() - { - $obj = new \stdClass; - $obj->foo = 'bar'; - - $array = [ - 'foo' => 'bar', - ]; - - return [ - 'shortened export null' => [null, 'null'], - 'shortened export boolean true' => [true, 'true'], - 'shortened export integer 1' => [1, '1'], - 'shortened export float 1.0' => [1.0, '1.0'], - 'shortened export float 1.2' => [1.2, '1.2'], - 'shortened export numeric string' => ['1', "'1'"], - // \n\r and \r is converted to \n - 'shortened export multilinestring' => ["this\nis\na\nvery\nvery\nvery\nvery\nvery\nvery\rlong\n\rtext", "'this\\nis\\na\\nvery\\nvery\\nvery...\\rtext'"], - 'shortened export empty stdClass' => [new \stdClass, 'stdClass Object ()'], - 'shortened export not empty stdClass' => [$obj, 'stdClass Object (...)'], - 'shortened export empty array' => [[], 'Array ()'], - 'shortened export not empty array' => [$array, 'Array (...)'], - ]; - } - - /** - * @dataProvider shortenedExportProvider - */ - public function testShortenedExport($value, $expected) - { - $this->assertSame( - $expected, - $this->trimNewline($this->exporter->shortenedExport($value)) - ); - } - - /** - * @requires extension mbstring - */ - public function testShortenedExportForMultibyteCharacters() - { - $oldMbLanguage = \mb_language(); - \mb_language('Japanese'); - $oldMbInternalEncoding = \mb_internal_encoding(); - \mb_internal_encoding('UTF-8'); - - try { - $this->assertSame( - "'いろはにほへとちりぬるをわかよたれそつねならむうゐのおくや...しゑひもせす'", - $this->trimNewline($this->exporter->shortenedExport('いろはにほへとちりぬるをわかよたれそつねならむうゐのおくやまけふこえてあさきゆめみしゑひもせす')) - ); - } catch (\Exception $e) { - \mb_internal_encoding($oldMbInternalEncoding); - \mb_language($oldMbLanguage); - - throw $e; - } - - \mb_internal_encoding($oldMbInternalEncoding); - \mb_language($oldMbLanguage); - } - - public function provideNonBinaryMultibyteStrings() - { - return [ - [\implode('', \array_map('chr', \range(0x09, 0x0d))), 9], - [\implode('', \array_map('chr', \range(0x20, 0x7f))), 96], - [\implode('', \array_map('chr', \range(0x80, 0xff))), 128], - ]; - } - - /** - * @dataProvider provideNonBinaryMultibyteStrings - */ - public function testNonBinaryStringExport($value, $expectedLength) - { - $this->assertRegExp( - "~'.{{$expectedLength}}'\$~s", - $this->exporter->export($value) - ); - } - - public function testNonObjectCanBeReturnedAsArray() - { - $this->assertEquals([true], $this->exporter->toArray(true)); - } - - public function testIgnoreKeysInValue() - { - // Find out what the actual use case was with the PHP bug - $array = []; - $array["\0gcdata"] = ''; - - $this->assertEquals([], $this->exporter->toArray((object) $array)); - } - - private function trimNewline($string) - { - return \preg_replace('/[ ]*\n/', "\n", $string); - } - - /** - * @dataProvider shortenedRecursiveExportProvider - */ - public function testShortenedRecursiveExport(array $value, string $expected) - { - $this->assertEquals($expected, $this->exporter->shortenedRecursiveExport($value)); - } - - public function shortenedRecursiveExportProvider() - { - return [ - 'export null' => [[null], 'null'], - 'export boolean true' => [[true], 'true'], - 'export boolean false' => [[false], 'false'], - 'export int 1' => [[1], '1'], - 'export float 1.0' => [[1.0], '1.0'], - 'export float 1.2' => [[1.2], '1.2'], - 'export numeric string' => [['1'], "'1'"], - 'export with numeric array key' => [[2 => 1], '1'], - 'export with assoc array key' => [['foo' => 'bar'], '\'bar\''], - 'export multidimentional array' => [[[1, 2, 3], [3, 4, 5]], 'array(1, 2, 3), array(3, 4, 5)'], - 'export object' => [[new \stdClass], 'stdClass Object ()'], - ]; - } - - public function testShortenedRecursiveOccurredRecursion() - { - $recursiveValue = [1]; - $context = new Context(); - $context->add($recursiveValue); - - $value = [$recursiveValue]; - - $this->assertEquals('*RECURSION*', $this->exporter->shortenedRecursiveExport($value, $context)); - } -} diff --git a/vendor/sebastian/global-state/.github/stale.yml b/vendor/sebastian/global-state/.github/stale.yml deleted file mode 100644 index 4eadca327..000000000 --- a/vendor/sebastian/global-state/.github/stale.yml +++ /dev/null @@ -1,40 +0,0 @@ -# Configuration for probot-stale - https://github.com/probot/stale - -# Number of days of inactivity before an Issue or Pull Request becomes stale -daysUntilStale: 60 - -# Number of days of inactivity before a stale Issue or Pull Request is closed. -# Set to false to disable. If disabled, issues still need to be closed manually, but will remain marked as stale. -daysUntilClose: 7 - -# Issues or Pull Requests with these labels will never be considered stale. Set to `[]` to disable -exemptLabels: - - enhancement - -# Set to true to ignore issues in a project (defaults to false) -exemptProjects: false - -# Set to true to ignore issues in a milestone (defaults to false) -exemptMilestones: false - -# Label to use when marking as stale -staleLabel: stale - -# Comment to post when marking as stale. Set to `false` to disable -markComment: > - This issue has been automatically marked as stale because it has not had activity within the last 60 days. It will be closed after 7 days if no further activity occurs. Thank you for your contributions. - -# Comment to post when removing the stale label. -# unmarkComment: > -# Your comment here. - -# Comment to post when closing a stale Issue or Pull Request. -closeComment: > - This issue has been automatically closed because it has not had activity since it was marked as stale. Thank you for your contributions. - -# Limit the number of actions per hour, from 1-30. Default is 30 -limitPerRun: 30 - -# Limit to only `issues` or `pulls` -only: issues - diff --git a/vendor/sebastian/global-state/.gitignore b/vendor/sebastian/global-state/.gitignore deleted file mode 100644 index 96c0f28a6..000000000 --- a/vendor/sebastian/global-state/.gitignore +++ /dev/null @@ -1,6 +0,0 @@ -/.idea -/.php_cs -/.php_cs.cache -/.phpunit.result.cache -/composer.lock -/vendor diff --git a/vendor/sebastian/global-state/.php_cs.dist b/vendor/sebastian/global-state/.php_cs.dist deleted file mode 100644 index c42d7e8b7..000000000 --- a/vendor/sebastian/global-state/.php_cs.dist +++ /dev/null @@ -1,197 +0,0 @@ - - -For the full copyright and license information, please view the LICENSE -file that was distributed with this source code. -EOF; - -return PhpCsFixer\Config::create() - ->setRiskyAllowed(true) - ->setRules( - [ - 'align_multiline_comment' => true, - 'array_indentation' => true, - 'array_syntax' => ['syntax' => 'short'], - 'binary_operator_spaces' => [ - 'operators' => [ - '=' => 'align', - '=>' => 'align', - ], - ], - 'blank_line_after_namespace' => true, - 'blank_line_before_statement' => [ - 'statements' => [ - 'break', - 'continue', - 'declare', - 'do', - 'for', - 'foreach', - 'if', - 'include', - 'include_once', - 'require', - 'require_once', - 'return', - 'switch', - 'throw', - 'try', - 'while', - 'yield', - ], - ], - 'braces' => true, - 'cast_spaces' => true, - 'class_attributes_separation' => ['elements' => ['const', 'method', 'property']], - 'combine_consecutive_issets' => true, - 'combine_consecutive_unsets' => true, - 'compact_nullable_typehint' => true, - 'concat_space' => ['spacing' => 'one'], - 'declare_equal_normalize' => ['space' => 'none'], - 'declare_strict_types' => true, - 'dir_constant' => true, - 'elseif' => true, - 'encoding' => true, - 'full_opening_tag' => true, - 'function_declaration' => true, - 'header_comment' => ['header' => $header, 'separate' => 'none'], - 'indentation_type' => true, - 'is_null' => true, - 'line_ending' => true, - 'list_syntax' => ['syntax' => 'short'], - 'logical_operators' => true, - 'lowercase_cast' => true, - 'lowercase_constants' => true, - 'lowercase_keywords' => true, - 'lowercase_static_reference' => true, - 'magic_constant_casing' => true, - 'method_argument_space' => ['ensure_fully_multiline' => true], - 'modernize_types_casting' => true, - 'multiline_comment_opening_closing' => true, - 'multiline_whitespace_before_semicolons' => true, - 'native_constant_invocation' => true, - 'native_function_casing' => true, - 'native_function_invocation' => true, - 'new_with_braces' => false, - 'no_alias_functions' => true, - 'no_alternative_syntax' => true, - 'no_blank_lines_after_class_opening' => true, - 'no_blank_lines_after_phpdoc' => true, - 'no_blank_lines_before_namespace' => true, - 'no_closing_tag' => true, - 'no_empty_comment' => true, - 'no_empty_phpdoc' => true, - 'no_empty_statement' => true, - 'no_extra_blank_lines' => true, - 'no_homoglyph_names' => true, - 'no_leading_import_slash' => true, - 'no_leading_namespace_whitespace' => true, - 'no_mixed_echo_print' => ['use' => 'print'], - 'no_multiline_whitespace_around_double_arrow' => true, - 'no_null_property_initialization' => true, - 'no_php4_constructor' => true, - 'no_short_bool_cast' => true, - 'no_short_echo_tag' => true, - 'no_singleline_whitespace_before_semicolons' => true, - 'no_spaces_after_function_name' => true, - 'no_spaces_inside_parenthesis' => true, - 'no_superfluous_elseif' => true, - 'no_superfluous_phpdoc_tags' => true, - 'no_trailing_comma_in_list_call' => true, - 'no_trailing_comma_in_singleline_array' => true, - 'no_trailing_whitespace' => true, - 'no_trailing_whitespace_in_comment' => true, - 'no_unneeded_control_parentheses' => true, - 'no_unneeded_curly_braces' => true, - 'no_unneeded_final_method' => true, - 'no_unreachable_default_argument_value' => true, - 'no_unset_on_property' => true, - 'no_unused_imports' => true, - 'no_useless_else' => true, - 'no_useless_return' => true, - 'no_whitespace_before_comma_in_array' => true, - 'no_whitespace_in_blank_line' => true, - 'non_printable_character' => true, - 'normalize_index_brace' => true, - 'object_operator_without_whitespace' => true, - 'ordered_class_elements' => [ - 'order' => [ - 'use_trait', - 'constant_public', - 'constant_protected', - 'constant_private', - 'property_public_static', - 'property_protected_static', - 'property_private_static', - 'property_public', - 'property_protected', - 'property_private', - 'method_public_static', - 'construct', - 'destruct', - 'magic', - 'phpunit', - 'method_public', - 'method_protected', - 'method_private', - 'method_protected_static', - 'method_private_static', - ], - ], - 'ordered_imports' => true, - 'phpdoc_add_missing_param_annotation' => true, - 'phpdoc_align' => true, - 'phpdoc_annotation_without_dot' => true, - 'phpdoc_indent' => true, - 'phpdoc_no_access' => true, - 'phpdoc_no_empty_return' => true, - 'phpdoc_no_package' => true, - 'phpdoc_order' => true, - 'phpdoc_return_self_reference' => true, - 'phpdoc_scalar' => true, - 'phpdoc_separation' => true, - 'phpdoc_single_line_var_spacing' => true, - 'phpdoc_to_comment' => true, - 'phpdoc_trim' => true, - 'phpdoc_trim_consecutive_blank_line_separation' => true, - 'phpdoc_types' => ['groups' => ['simple', 'meta']], - 'phpdoc_types_order' => true, - 'phpdoc_var_without_name' => true, - 'pow_to_exponentiation' => true, - 'protected_to_private' => true, - 'return_assignment' => true, - 'return_type_declaration' => ['space_before' => 'none'], - 'self_accessor' => true, - 'semicolon_after_instruction' => true, - 'set_type_to_cast' => true, - 'short_scalar_cast' => true, - 'simplified_null_return' => true, - 'single_blank_line_at_eof' => true, - 'single_import_per_statement' => true, - 'single_line_after_imports' => true, - 'single_quote' => true, - 'standardize_not_equals' => true, - 'ternary_to_null_coalescing' => true, - 'trailing_comma_in_multiline_array' => true, - 'trim_array_spaces' => true, - 'unary_operator_spaces' => true, - 'visibility_required' => [ - 'elements' => [ - 'const', - 'method', - 'property', - ], - ], - 'void_return' => true, - 'whitespace_after_comma_in_array' => true, - ] - ) - ->setFinder( - PhpCsFixer\Finder::create() - ->files() - ->in(__DIR__ . '/src') - ->in(__DIR__ . '/tests') - ); diff --git a/vendor/sebastian/global-state/.travis.yml b/vendor/sebastian/global-state/.travis.yml deleted file mode 100644 index 3a8412783..000000000 --- a/vendor/sebastian/global-state/.travis.yml +++ /dev/null @@ -1,24 +0,0 @@ -language: php - -php: - - 7.2 - - 7.3 - - master - -sudo: false - -before_install: - - composer self-update - - composer clear-cache - -install: - - travis_retry composer update --no-interaction --no-ansi --no-progress --no-suggest - -script: - - ./vendor/bin/phpunit --coverage-clover=coverage.xml - -after_success: - - bash <(curl -s https://codecov.io/bash) - -notifications: - email: false diff --git a/vendor/sebastian/global-state/ChangeLog.md b/vendor/sebastian/global-state/ChangeLog.md index 095cd55e9..e6114f903 100644 --- a/vendor/sebastian/global-state/ChangeLog.md +++ b/vendor/sebastian/global-state/ChangeLog.md @@ -2,11 +2,29 @@ All notable changes in `sebastian/global-state` are documented in this file using the [Keep a CHANGELOG](https://keepachangelog.com/) principles. -## [3.0.1] - 2020-11-30 +## [5.0.2] - 2020-10-26 + +### Fixed + +* `SebastianBergmann\GlobalState\Exception` now correctly extends `\Throwable` + +## [5.0.1] - 2020-09-28 ### Changed -* Changed PHP version constraint in `composer.json` from `^7.2` to `>=7.2` +* Changed PHP version constraint in `composer.json` from `^7.3 || ^8.0` to `>=7.3` + +## [5.0.0] - 2020-08-07 + +### Changed + +* The `SebastianBergmann\GlobalState\Blacklist` class has been renamed to `SebastianBergmann\GlobalState\ExcludeList` + +## [4.0.0] - 2020-02-07 + +### Removed + +* This component is no longer supported on PHP 7.2 ## [3.0.0] - 2019-02-01 @@ -18,6 +36,9 @@ All notable changes in `sebastian/global-state` are documented in this file usin * This component is no longer supported on PHP 7.0 and PHP 7.1 -[3.0.1]: https://github.com/sebastianbergmann/phpunit/compare/3.0.0...3.0.1 -[3.0.0]: https://github.com/sebastianbergmann/phpunit/compare/2.0.0...3.0.0 +[5.0.2]: https://github.com/sebastianbergmann/global-state/compare/5.0.1...5.0.2 +[5.0.1]: https://github.com/sebastianbergmann/global-state/compare/5.0.0...5.0.1 +[5.0.0]: https://github.com/sebastianbergmann/global-state/compare/4.0.0...5.0.0 +[4.0.0]: https://github.com/sebastianbergmann/global-state/compare/3.0.0...4.0.0 +[3.0.0]: https://github.com/sebastianbergmann/global-state/compare/2.0.0...3.0.0 diff --git a/vendor/sebastian/global-state/LICENSE b/vendor/sebastian/global-state/LICENSE index 1756a1ff7..f492960e6 100644 --- a/vendor/sebastian/global-state/LICENSE +++ b/vendor/sebastian/global-state/LICENSE @@ -1,6 +1,6 @@ sebastian/global-state -Copyright (c) 2001-2019, Sebastian Bergmann . +Copyright (c) 2001-2020, Sebastian Bergmann . All rights reserved. Redistribution and use in source and binary forms, with or without diff --git a/vendor/sebastian/global-state/README.md b/vendor/sebastian/global-state/README.md index a804f85c0..af15bedde 100644 --- a/vendor/sebastian/global-state/README.md +++ b/vendor/sebastian/global-state/README.md @@ -1,16 +1,20 @@ -# global-state +# sebastian/global-state + +[![CI Status](https://github.com/sebastianbergmann/global-state/workflows/CI/badge.svg)](https://github.com/sebastianbergmann/global-state/actions) +[![Type Coverage](https://shepherd.dev/github/sebastianbergmann/global-state/coverage.svg)](https://shepherd.dev/github/sebastianbergmann/global-state) Snapshotting of global state, factored out of PHPUnit into a stand-alone component. -[![Build Status](https://travis-ci.org/sebastianbergmann/global-state.svg?branch=master)](https://travis-ci.org/sebastianbergmann/global-state) - ## Installation You can add this library as a local, per-project dependency to your project using [Composer](https://getcomposer.org/): - composer require sebastian/global-state +``` +composer require sebastian/global-state +``` If you only need this library during development, for instance to run your project's test suite, then you should add it as a development-time dependency: - composer require --dev sebastian/global-state - +``` +composer require --dev sebastian/global-state +``` diff --git a/vendor/sebastian/global-state/build.xml b/vendor/sebastian/global-state/build.xml deleted file mode 100644 index 35c179054..000000000 --- a/vendor/sebastian/global-state/build.xml +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - - - - - - - - - - - - - - diff --git a/vendor/sebastian/global-state/composer.json b/vendor/sebastian/global-state/composer.json index 0cbc33d7b..0fef446a6 100644 --- a/vendor/sebastian/global-state/composer.json +++ b/vendor/sebastian/global-state/composer.json @@ -12,17 +12,20 @@ ], "prefer-stable": true, "config": { + "platform": { + "php": "7.3.0" + }, "optimize-autoloader": true, "sort-packages": true }, "require": { - "php": ">=7.2", - "sebastian/object-reflector": "^1.1.1", - "sebastian/recursion-context": "^3.0" + "php": ">=7.3", + "sebastian/object-reflector": "^2.0", + "sebastian/recursion-context": "^4.0" }, "require-dev": { "ext-dom": "*", - "phpunit/phpunit": "^8.0" + "phpunit/phpunit": "^9.3" }, "suggest": { "ext-uopz": "*" @@ -42,7 +45,7 @@ }, "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "5.0-dev" } } } diff --git a/vendor/sebastian/global-state/phpunit.xml b/vendor/sebastian/global-state/phpunit.xml deleted file mode 100644 index c02c9bc6a..000000000 --- a/vendor/sebastian/global-state/phpunit.xml +++ /dev/null @@ -1,27 +0,0 @@ - - - - - tests - - - - - - - - - - - src - - - diff --git a/vendor/sebastian/global-state/src/CodeExporter.php b/vendor/sebastian/global-state/src/CodeExporter.php index 860457b13..8e1f23f05 100644 --- a/vendor/sebastian/global-state/src/CodeExporter.php +++ b/vendor/sebastian/global-state/src/CodeExporter.php @@ -9,6 +9,13 @@ */ namespace SebastianBergmann\GlobalState; +use const PHP_EOL; +use function is_array; +use function is_scalar; +use function serialize; +use function sprintf; +use function var_export; + /** * Exports parts of a Snapshot as PHP code. */ @@ -19,7 +26,7 @@ final class CodeExporter $result = ''; foreach ($snapshot->constants() as $name => $value) { - $result .= \sprintf( + $result .= sprintf( 'if (!defined(\'%s\')) define(\'%s\', %s);' . "\n", $name, $name, @@ -32,11 +39,11 @@ final class CodeExporter public function globalVariables(Snapshot $snapshot): string { - $result = '$GLOBALS = [];' . \PHP_EOL; + $result = '$GLOBALS = [];' . PHP_EOL; foreach ($snapshot->globalVariables() as $name => $value) { - $result .= \sprintf( - '$GLOBALS[%s] = %s;' . \PHP_EOL, + $result .= sprintf( + '$GLOBALS[%s] = %s;' . PHP_EOL, $this->exportVariable($name), $this->exportVariable($value) ); @@ -50,7 +57,7 @@ final class CodeExporter $result = ''; foreach ($snapshot->iniSettings() as $key => $value) { - $result .= \sprintf( + $result .= sprintf( '@ini_set(%s, %s);' . "\n", $this->exportVariable($key), $this->exportVariable($value) @@ -62,12 +69,12 @@ final class CodeExporter private function exportVariable($variable): string { - if (\is_scalar($variable) || null === $variable || - (\is_array($variable) && $this->arrayOnlyContainsScalars($variable))) { - return \var_export($variable, true); + if (is_scalar($variable) || null === $variable || + (is_array($variable) && $this->arrayOnlyContainsScalars($variable))) { + return var_export($variable, true); } - return 'unserialize(' . \var_export(\serialize($variable), true) . ')'; + return 'unserialize(' . var_export(serialize($variable), true) . ')'; } private function arrayOnlyContainsScalars(array $array): bool @@ -75,9 +82,9 @@ final class CodeExporter $result = true; foreach ($array as $element) { - if (\is_array($element)) { + if (is_array($element)) { $result = $this->arrayOnlyContainsScalars($element); - } elseif (!\is_scalar($element) && null !== $element) { + } elseif (!is_scalar($element) && null !== $element) { $result = false; } diff --git a/vendor/sebastian/global-state/src/Blacklist.php b/vendor/sebastian/global-state/src/ExcludeList.php similarity index 84% rename from vendor/sebastian/global-state/src/Blacklist.php rename to vendor/sebastian/global-state/src/ExcludeList.php index ce8f25c2f..424385d2b 100644 --- a/vendor/sebastian/global-state/src/Blacklist.php +++ b/vendor/sebastian/global-state/src/ExcludeList.php @@ -9,10 +9,11 @@ */ namespace SebastianBergmann\GlobalState; -/** - * A blacklist for global state elements that should not be snapshotted. - */ -final class Blacklist +use function in_array; +use function strpos; +use ReflectionClass; + +final class ExcludeList { /** * @var array @@ -78,24 +79,24 @@ final class Blacklist $this->staticAttributes[$className][$attributeName] = true; } - public function isGlobalVariableBlacklisted(string $variableName): bool + public function isGlobalVariableExcluded(string $variableName): bool { return isset($this->globalVariables[$variableName]); } - public function isStaticAttributeBlacklisted(string $className, string $attributeName): bool + public function isStaticAttributeExcluded(string $className, string $attributeName): bool { - if (\in_array($className, $this->classes)) { + if (in_array($className, $this->classes)) { return true; } foreach ($this->classNamePrefixes as $prefix) { - if (\strpos($className, $prefix) === 0) { + if (strpos($className, $prefix) === 0) { return true; } } - $class = new \ReflectionClass($className); + $class = new ReflectionClass($className); foreach ($this->parentClasses as $type) { if ($class->isSubclassOf($type)) { diff --git a/vendor/sebastian/global-state/src/Restorer.php b/vendor/sebastian/global-state/src/Restorer.php index ed55d9fe0..99cc4a69e 100644 --- a/vendor/sebastian/global-state/src/Restorer.php +++ b/vendor/sebastian/global-state/src/Restorer.php @@ -9,6 +9,17 @@ */ namespace SebastianBergmann\GlobalState; +use function array_diff; +use function array_key_exists; +use function array_keys; +use function array_merge; +use function function_exists; +use function get_defined_functions; +use function in_array; +use function is_array; +use ReflectionClass; +use ReflectionProperty; + /** * Restorer of snapshots of global state. */ @@ -23,13 +34,13 @@ class Restorer */ public function restoreFunctions(Snapshot $snapshot): void { - if (!\function_exists('uopz_delete')) { + if (!function_exists('uopz_delete')) { throw new RuntimeException('The uopz_delete() function is required for this operation'); } - $functions = \get_defined_functions(); + $functions = get_defined_functions(); - foreach (\array_diff($functions['user'], $snapshot->functions()) as $function) { + foreach (array_diff($functions['user'], $snapshot->functions()) as $function) { uopz_delete($function); } } @@ -47,11 +58,11 @@ class Restorer $globalVariables = $snapshot->globalVariables(); - foreach (\array_keys($GLOBALS) as $key) { + foreach (array_keys($GLOBALS) as $key) { if ($key !== 'GLOBALS' && - !\in_array($key, $superGlobalArrays) && - !$snapshot->blacklist()->isGlobalVariableBlacklisted($key)) { - if (\array_key_exists($key, $globalVariables)) { + !in_array($key, $superGlobalArrays) && + !$snapshot->excludeList()->isGlobalVariableExcluded($key)) { + if (array_key_exists($key, $globalVariables)) { $GLOBALS[$key] = $globalVariables[$key]; } else { unset($GLOBALS[$key]); @@ -65,21 +76,21 @@ class Restorer */ public function restoreStaticAttributes(Snapshot $snapshot): void { - $current = new Snapshot($snapshot->blacklist(), false, false, false, false, true, false, false, false, false); - $newClasses = \array_diff($current->classes(), $snapshot->classes()); + $current = new Snapshot($snapshot->excludeList(), false, false, false, false, true, false, false, false, false); + $newClasses = array_diff($current->classes(), $snapshot->classes()); unset($current); foreach ($snapshot->staticAttributes() as $className => $staticAttributes) { foreach ($staticAttributes as $name => $value) { - $reflector = new \ReflectionProperty($className, $name); + $reflector = new ReflectionProperty($className, $name); $reflector->setAccessible(true); $reflector->setValue($value); } } foreach ($newClasses as $className) { - $class = new \ReflectionClass($className); + $class = new ReflectionClass($className); $defaults = $class->getDefaultProperties(); foreach ($class->getProperties() as $attribute) { @@ -89,7 +100,7 @@ class Restorer $name = $attribute->getName(); - if ($snapshot->blacklist()->isStaticAttributeBlacklisted($className, $name)) { + if ($snapshot->excludeList()->isStaticAttributeExcluded($className, $name)) { continue; } @@ -111,10 +122,10 @@ class Restorer $superGlobalVariables = $snapshot->superGlobalVariables(); if (isset($GLOBALS[$superGlobalArray]) && - \is_array($GLOBALS[$superGlobalArray]) && + is_array($GLOBALS[$superGlobalArray]) && isset($superGlobalVariables[$superGlobalArray])) { - $keys = \array_keys( - \array_merge( + $keys = array_keys( + array_merge( $GLOBALS[$superGlobalArray], $superGlobalVariables[$superGlobalArray] ) diff --git a/vendor/sebastian/global-state/src/Snapshot.php b/vendor/sebastian/global-state/src/Snapshot.php index 5a0e5c7a9..e7bdf2469 100644 --- a/vendor/sebastian/global-state/src/Snapshot.php +++ b/vendor/sebastian/global-state/src/Snapshot.php @@ -9,8 +9,28 @@ */ namespace SebastianBergmann\GlobalState; +use function array_keys; +use function array_merge; +use function array_reverse; +use function func_get_args; +use function get_declared_classes; +use function get_declared_interfaces; +use function get_declared_traits; +use function get_defined_constants; +use function get_defined_functions; +use function get_included_files; +use function in_array; +use function ini_get_all; +use function is_array; +use function is_object; +use function is_resource; +use function is_scalar; +use function serialize; +use function unserialize; +use ReflectionClass; use SebastianBergmann\ObjectReflector\ObjectReflector; use SebastianBergmann\RecursionContext\Context; +use Throwable; /** * A snapshot of global state. @@ -18,9 +38,9 @@ use SebastianBergmann\RecursionContext\Context; class Snapshot { /** - * @var Blacklist + * @var ExcludeList */ - private $blacklist; + private $excludeList; /** * @var array @@ -80,13 +100,9 @@ class Snapshot /** * Creates a snapshot of the current global state. */ - public function __construct(Blacklist $blacklist = null, bool $includeGlobalVariables = true, bool $includeStaticAttributes = true, bool $includeConstants = true, bool $includeFunctions = true, bool $includeClasses = true, bool $includeInterfaces = true, bool $includeTraits = true, bool $includeIniSettings = true, bool $includeIncludedFiles = true) + public function __construct(ExcludeList $excludeList = null, bool $includeGlobalVariables = true, bool $includeStaticAttributes = true, bool $includeConstants = true, bool $includeFunctions = true, bool $includeClasses = true, bool $includeInterfaces = true, bool $includeTraits = true, bool $includeIniSettings = true, bool $includeIncludedFiles = true) { - if ($blacklist === null) { - $blacklist = new Blacklist; - } - - $this->blacklist = $blacklist; + $this->excludeList = $excludeList ?: new ExcludeList; if ($includeConstants) { $this->snapshotConstants(); @@ -114,19 +130,19 @@ class Snapshot } if ($includeIniSettings) { - $this->iniSettings = \ini_get_all(null, false); + $this->iniSettings = ini_get_all(null, false); } if ($includeIncludedFiles) { - $this->includedFiles = \get_included_files(); + $this->includedFiles = get_included_files(); } - $this->traits = \get_declared_traits(); + $this->traits = get_declared_traits(); } - public function blacklist(): Blacklist + public function excludeList(): ExcludeList { - return $this->blacklist; + return $this->excludeList; } public function globalVariables(): array @@ -189,7 +205,7 @@ class Snapshot */ private function snapshotConstants(): void { - $constants = \get_defined_constants(true); + $constants = get_defined_constants(true); if (isset($constants['user'])) { $this->constants = $constants['user']; @@ -201,7 +217,7 @@ class Snapshot */ private function snapshotFunctions(): void { - $functions = \get_defined_functions(); + $functions = get_defined_functions(); $this->functions = $functions['user']; } @@ -211,8 +227,8 @@ class Snapshot */ private function snapshotClasses(): void { - foreach (\array_reverse(\get_declared_classes()) as $className) { - $class = new \ReflectionClass($className); + foreach (array_reverse(get_declared_classes()) as $className) { + $class = new ReflectionClass($className); if (!$class->isUserDefined()) { break; @@ -221,7 +237,7 @@ class Snapshot $this->classes[] = $className; } - $this->classes = \array_reverse($this->classes); + $this->classes = array_reverse($this->classes); } /** @@ -229,8 +245,8 @@ class Snapshot */ private function snapshotInterfaces(): void { - foreach (\array_reverse(\get_declared_interfaces()) as $interfaceName) { - $class = new \ReflectionClass($interfaceName); + foreach (array_reverse(get_declared_interfaces()) as $interfaceName) { + $class = new ReflectionClass($interfaceName); if (!$class->isUserDefined()) { break; @@ -239,7 +255,7 @@ class Snapshot $this->interfaces[] = $interfaceName; } - $this->interfaces = \array_reverse($this->interfaces); + $this->interfaces = array_reverse($this->interfaces); } /** @@ -253,13 +269,13 @@ class Snapshot $this->snapshotSuperGlobalArray($superGlobalArray); } - foreach (\array_keys($GLOBALS) as $key) { + foreach (array_keys($GLOBALS) as $key) { if ($key !== 'GLOBALS' && - !\in_array($key, $superGlobalArrays) && + !in_array($key, $superGlobalArrays) && $this->canBeSerialized($GLOBALS[$key]) && - !$this->blacklist->isGlobalVariableBlacklisted($key)) { + !$this->excludeList->isGlobalVariableExcluded($key)) { /* @noinspection UnserializeExploitsInspection */ - $this->globalVariables[$key] = \unserialize(\serialize($GLOBALS[$key])); + $this->globalVariables[$key] = unserialize(serialize($GLOBALS[$key])); } } } @@ -271,10 +287,10 @@ class Snapshot { $this->superGlobalVariables[$superGlobalArray] = []; - if (isset($GLOBALS[$superGlobalArray]) && \is_array($GLOBALS[$superGlobalArray])) { + if (isset($GLOBALS[$superGlobalArray]) && is_array($GLOBALS[$superGlobalArray])) { foreach ($GLOBALS[$superGlobalArray] as $key => $value) { /* @noinspection UnserializeExploitsInspection */ - $this->superGlobalVariables[$superGlobalArray][$key] = \unserialize(\serialize($value)); + $this->superGlobalVariables[$superGlobalArray][$key] = unserialize(serialize($value)); } } } @@ -285,14 +301,14 @@ class Snapshot private function snapshotStaticAttributes(): void { foreach ($this->classes as $className) { - $class = new \ReflectionClass($className); + $class = new ReflectionClass($className); $snapshot = []; foreach ($class->getProperties() as $attribute) { if ($attribute->isStatic()) { $name = $attribute->getName(); - if ($this->blacklist->isStaticAttributeBlacklisted($className, $name)) { + if ($this->excludeList->isStaticAttributeExcluded($className, $name)) { continue; } @@ -301,7 +317,7 @@ class Snapshot if ($this->canBeSerialized($value)) { /* @noinspection UnserializeExploitsInspection */ - $snapshot[$name] = \unserialize(\serialize($value)); + $snapshot[$name] = unserialize(serialize($value)); } } } @@ -330,29 +346,29 @@ class Snapshot private function canBeSerialized($variable): bool { - if (\is_scalar($variable) || $variable === null) { + if (is_scalar($variable) || $variable === null) { return true; } - if (\is_resource($variable)) { + if (is_resource($variable)) { return false; } foreach ($this->enumerateObjectsAndResources($variable) as $value) { - if (\is_resource($value)) { + if (is_resource($value)) { return false; } - if (\is_object($value)) { - $class = new \ReflectionClass($value); + if (is_object($value)) { + $class = new ReflectionClass($value); if ($class->isAnonymous()) { return false; } try { - @\serialize($value); - } catch (\Throwable $t) { + @serialize($value); + } catch (Throwable $t) { return false; } } @@ -363,8 +379,8 @@ class Snapshot private function enumerateObjectsAndResources($variable): array { - if (isset(\func_get_args()[1])) { - $processed = \func_get_args()[1]; + if (isset(func_get_args()[1])) { + $processed = func_get_args()[1]; } else { $processed = new Context; } @@ -378,15 +394,15 @@ class Snapshot $array = $variable; $processed->add($variable); - if (\is_array($variable)) { + if (is_array($variable)) { foreach ($array as $element) { - if (!\is_array($element) && !\is_object($element) && !\is_resource($element)) { + if (!is_array($element) && !is_object($element) && !is_resource($element)) { continue; } - if (!\is_resource($element)) { + if (!is_resource($element)) { /** @noinspection SlowArrayOperationsInLoopInspection */ - $result = \array_merge( + $result = array_merge( $result, $this->enumerateObjectsAndResources($element, $processed) ); @@ -398,13 +414,13 @@ class Snapshot $result[] = $variable; foreach ((new ObjectReflector)->getAttributes($variable) as $value) { - if (!\is_array($value) && !\is_object($value) && !\is_resource($value)) { + if (!is_array($value) && !is_object($value) && !is_resource($value)) { continue; } - if (!\is_resource($value)) { + if (!is_resource($value)) { /** @noinspection SlowArrayOperationsInLoopInspection */ - $result = \array_merge( + $result = array_merge( $result, $this->enumerateObjectsAndResources($value, $processed) ); diff --git a/vendor/sebastian/global-state/src/exceptions/Exception.php b/vendor/sebastian/global-state/src/exceptions/Exception.php index d8fd3c3aa..94432008e 100644 --- a/vendor/sebastian/global-state/src/exceptions/Exception.php +++ b/vendor/sebastian/global-state/src/exceptions/Exception.php @@ -9,6 +9,8 @@ */ namespace SebastianBergmann\GlobalState; -interface Exception +use Throwable; + +interface Exception extends Throwable { } diff --git a/vendor/sebastian/global-state/tests/BlacklistTest.php b/vendor/sebastian/global-state/tests/BlacklistTest.php deleted file mode 100644 index 4d1b64d38..000000000 --- a/vendor/sebastian/global-state/tests/BlacklistTest.php +++ /dev/null @@ -1,117 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\GlobalState; - -use PHPUnit\Framework\TestCase; -use SebastianBergmann\GlobalState\TestFixture\BlacklistedChildClass; -use SebastianBergmann\GlobalState\TestFixture\BlacklistedClass; -use SebastianBergmann\GlobalState\TestFixture\BlacklistedImplementor; -use SebastianBergmann\GlobalState\TestFixture\BlacklistedInterface; - -/** - * @covers \SebastianBergmann\GlobalState\Blacklist - */ -final class BlacklistTest extends TestCase -{ - /** - * @var \SebastianBergmann\GlobalState\Blacklist - */ - private $blacklist; - - protected function setUp(): void - { - $this->blacklist = new Blacklist; - } - - public function testGlobalVariableThatIsNotBlacklistedIsNotTreatedAsBlacklisted(): void - { - $this->assertFalse($this->blacklist->isGlobalVariableBlacklisted('variable')); - } - - public function testGlobalVariableCanBeBlacklisted(): void - { - $this->blacklist->addGlobalVariable('variable'); - - $this->assertTrue($this->blacklist->isGlobalVariableBlacklisted('variable')); - } - - public function testStaticAttributeThatIsNotBlacklistedIsNotTreatedAsBlacklisted(): void - { - $this->assertFalse( - $this->blacklist->isStaticAttributeBlacklisted( - BlacklistedClass::class, - 'attribute' - ) - ); - } - - public function testClassCanBeBlacklisted(): void - { - $this->blacklist->addClass(BlacklistedClass::class); - - $this->assertTrue( - $this->blacklist->isStaticAttributeBlacklisted( - BlacklistedClass::class, - 'attribute' - ) - ); - } - - public function testSubclassesCanBeBlacklisted(): void - { - $this->blacklist->addSubclassesOf(BlacklistedClass::class); - - $this->assertTrue( - $this->blacklist->isStaticAttributeBlacklisted( - BlacklistedChildClass::class, - 'attribute' - ) - ); - } - - public function testImplementorsCanBeBlacklisted(): void - { - $this->blacklist->addImplementorsOf(BlacklistedInterface::class); - - $this->assertTrue( - $this->blacklist->isStaticAttributeBlacklisted( - BlacklistedImplementor::class, - 'attribute' - ) - ); - } - - public function testClassNamePrefixesCanBeBlacklisted(): void - { - $this->blacklist->addClassNamePrefix('SebastianBergmann\GlobalState'); - - $this->assertTrue( - $this->blacklist->isStaticAttributeBlacklisted( - BlacklistedClass::class, - 'attribute' - ) - ); - } - - public function testStaticAttributeCanBeBlacklisted(): void - { - $this->blacklist->addStaticAttribute( - BlacklistedClass::class, - 'attribute' - ); - - $this->assertTrue( - $this->blacklist->isStaticAttributeBlacklisted( - BlacklistedClass::class, - 'attribute' - ) - ); - } -} diff --git a/vendor/sebastian/global-state/tests/CodeExporterTest.php b/vendor/sebastian/global-state/tests/CodeExporterTest.php deleted file mode 100644 index b121d7e26..000000000 --- a/vendor/sebastian/global-state/tests/CodeExporterTest.php +++ /dev/null @@ -1,35 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\GlobalState; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\GlobalState\CodeExporter - */ -final class CodeExporterTest extends TestCase -{ - /** - * @runInSeparateProcess - */ - public function testCanExportGlobalVariablesToCode(): void - { - $GLOBALS = ['foo' => 'bar']; - - $snapshot = new Snapshot(null, true, false, false, false, false, false, false, false, false); - - $exporter = new CodeExporter; - - $this->assertEquals( - '$GLOBALS = [];' . \PHP_EOL . '$GLOBALS[\'foo\'] = \'bar\';' . \PHP_EOL, - $exporter->globalVariables($snapshot) - ); - } -} diff --git a/vendor/sebastian/global-state/tests/RestorerTest.php b/vendor/sebastian/global-state/tests/RestorerTest.php deleted file mode 100644 index 6dcb94e99..000000000 --- a/vendor/sebastian/global-state/tests/RestorerTest.php +++ /dev/null @@ -1,68 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\GlobalState; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\GlobalState\Restorer - * - * @uses \SebastianBergmann\GlobalState\Blacklist - * @uses \SebastianBergmann\GlobalState\Snapshot - */ -final class RestorerTest extends TestCase -{ - public static function setUpBeforeClass(): void - { - $GLOBALS['varBool'] = false; - $GLOBALS['varNull'] = null; - $_GET['varGet'] = 0; - } - - public function testRestorerGlobalVariable(): void - { - $snapshot = new Snapshot(null, true, false, false, false, false, false, false, false, false); - $restorer = new Restorer; - $restorer->restoreGlobalVariables($snapshot); - - $this->assertArrayHasKey('varBool', $GLOBALS); - $this->assertEquals(false, $GLOBALS['varBool']); - $this->assertArrayHasKey('varNull', $GLOBALS); - $this->assertEquals(null, $GLOBALS['varNull']); - $this->assertArrayHasKey('varGet', $_GET); - $this->assertEquals(0, $_GET['varGet']); - } - - /** - * @backupGlobals enabled - */ - public function testIntegrationRestorerGlobalVariables(): void - { - $this->assertArrayHasKey('varBool', $GLOBALS); - $this->assertEquals(false, $GLOBALS['varBool']); - $this->assertArrayHasKey('varNull', $GLOBALS); - $this->assertEquals(null, $GLOBALS['varNull']); - $this->assertArrayHasKey('varGet', $_GET); - $this->assertEquals(0, $_GET['varGet']); - } - - /** - * @depends testIntegrationRestorerGlobalVariables - */ - public function testIntegrationRestorerGlobalVariables2(): void - { - $this->assertArrayHasKey('varBool', $GLOBALS); - $this->assertEquals(false, $GLOBALS['varBool']); - $this->assertArrayHasKey('varNull', $GLOBALS); - $this->assertEquals(null, $GLOBALS['varNull']); - $this->assertArrayHasKey('varGet', $_GET); - $this->assertEquals(0, $_GET['varGet']); - } -} diff --git a/vendor/sebastian/global-state/tests/SnapshotTest.php b/vendor/sebastian/global-state/tests/SnapshotTest.php deleted file mode 100644 index 56d584979..000000000 --- a/vendor/sebastian/global-state/tests/SnapshotTest.php +++ /dev/null @@ -1,120 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\GlobalState; - -use PHPUnit\Framework\TestCase; -use SebastianBergmann\GlobalState\TestFixture\BlacklistedInterface; -use SebastianBergmann\GlobalState\TestFixture\SnapshotClass; -use SebastianBergmann\GlobalState\TestFixture\SnapshotTrait; - -/** - * @covers \SebastianBergmann\GlobalState\Snapshot - * - * @uses \SebastianBergmann\GlobalState\Blacklist - */ -final class SnapshotTest extends TestCase -{ - /** - * @var Blacklist - */ - private $blacklist; - - protected function setUp(): void - { - $this->blacklist = new Blacklist; - } - - public function testStaticAttributes(): void - { - SnapshotClass::init(); - - $this->blacklistAllLoadedClassesExceptSnapshotClass(); - - $snapshot = new Snapshot($this->blacklist, false, true, false, false, false, false, false, false, false); - - $expected = [ - SnapshotClass::class => [ - 'string' => 'string', - 'objects' => [new \stdClass], - ], - ]; - - $this->assertEquals($expected, $snapshot->staticAttributes()); - } - - public function testConstants(): void - { - $snapshot = new Snapshot($this->blacklist, false, false, true, false, false, false, false, false, false); - - $this->assertArrayHasKey('GLOBALSTATE_TESTSUITE', $snapshot->constants()); - } - - public function testFunctions(): void - { - $snapshot = new Snapshot($this->blacklist, false, false, false, true, false, false, false, false, false); - $functions = $snapshot->functions(); - - $this->assertContains('sebastianbergmann\globalstate\testfixture\snapshotfunction', $functions); - $this->assertNotContains('assert', $functions); - } - - public function testClasses(): void - { - $snapshot = new Snapshot($this->blacklist, false, false, false, false, true, false, false, false, false); - $classes = $snapshot->classes(); - - $this->assertContains(TestCase::class, $classes); - $this->assertNotContains(Exception::class, $classes); - } - - public function testInterfaces(): void - { - $snapshot = new Snapshot($this->blacklist, false, false, false, false, false, true, false, false, false); - $interfaces = $snapshot->interfaces(); - - $this->assertContains(BlacklistedInterface::class, $interfaces); - $this->assertNotContains(\Countable::class, $interfaces); - } - - public function testTraits(): void - { - \spl_autoload_call('SebastianBergmann\GlobalState\TestFixture\SnapshotTrait'); - - $snapshot = new Snapshot($this->blacklist, false, false, false, false, false, false, true, false, false); - - $this->assertContains(SnapshotTrait::class, $snapshot->traits()); - } - - public function testIniSettings(): void - { - $snapshot = new Snapshot($this->blacklist, false, false, false, false, false, false, false, true, false); - $iniSettings = $snapshot->iniSettings(); - - $this->assertArrayHasKey('date.timezone', $iniSettings); - $this->assertEquals('Etc/UTC', $iniSettings['date.timezone']); - } - - public function testIncludedFiles(): void - { - $snapshot = new Snapshot($this->blacklist, false, false, false, false, false, false, false, false, true); - $this->assertContains(__FILE__, $snapshot->includedFiles()); - } - - private function blacklistAllLoadedClassesExceptSnapshotClass(): void - { - foreach (\get_declared_classes() as $class) { - if ($class === SnapshotClass::class) { - continue; - } - - $this->blacklist->addClass($class); - } - } -} diff --git a/vendor/sebastian/global-state/tests/_fixture/BlacklistedImplementor.php b/vendor/sebastian/global-state/tests/_fixture/BlacklistedImplementor.php deleted file mode 100644 index c42751edd..000000000 --- a/vendor/sebastian/global-state/tests/_fixture/BlacklistedImplementor.php +++ /dev/null @@ -1,15 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\GlobalState\TestFixture; - -class BlacklistedImplementor implements BlacklistedInterface -{ - private static $attribute; -} diff --git a/vendor/sebastian/global-state/tests/_fixture/SnapshotClass.php b/vendor/sebastian/global-state/tests/_fixture/SnapshotClass.php deleted file mode 100644 index bf3305d59..000000000 --- a/vendor/sebastian/global-state/tests/_fixture/SnapshotClass.php +++ /dev/null @@ -1,35 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\GlobalState\TestFixture; - -class SnapshotClass -{ - private static $string = 'string'; - - private static $closures = []; - - private static $files = []; - - private static $resources = []; - - private static $objects = []; - - public static function init(): void - { - self::$closures[] = function (): void { - }; - - self::$files[] = new \SplFileInfo(__FILE__); - - self::$resources[] = \fopen('php://memory', 'r'); - - self::$objects[] = new \stdClass; - } -} diff --git a/vendor/sebastian/lines-of-code/.psalm/baseline.xml b/vendor/sebastian/lines-of-code/.psalm/baseline.xml new file mode 100644 index 000000000..77e688e07 --- /dev/null +++ b/vendor/sebastian/lines-of-code/.psalm/baseline.xml @@ -0,0 +1,2 @@ + + diff --git a/vendor/sebastian/lines-of-code/.psalm/config.xml b/vendor/sebastian/lines-of-code/.psalm/config.xml new file mode 100644 index 000000000..15abef058 --- /dev/null +++ b/vendor/sebastian/lines-of-code/.psalm/config.xml @@ -0,0 +1,16 @@ + + + + + + + + + diff --git a/vendor/sebastian/lines-of-code/ChangeLog.md b/vendor/sebastian/lines-of-code/ChangeLog.md new file mode 100644 index 000000000..39bcaad49 --- /dev/null +++ b/vendor/sebastian/lines-of-code/ChangeLog.md @@ -0,0 +1,34 @@ +# ChangeLog + +All notable changes are documented in this file using the [Keep a CHANGELOG](https://keepachangelog.com/) principles. + +## [1.0.3] - 2020-11-28 + +### Fixed + +* Files that do not contain a newline were not handled correctly + +### Changed + +* A line of code is no longer considered to be a Logical Line of Code if it does not contain an `Expr` node + +## [1.0.2] - 2020-10-26 + +### Fixed + +* `SebastianBergmann\LinesOfCode\Exception` now correctly extends `\Throwable` + +## [1.0.1] - 2020-09-28 + +### Changed + +* Changed PHP version constraint in `composer.json` from `^7.3 || ^8.0` to `>=7.3` + +## [1.0.0] - 2020-07-22 + +* Initial release + +[1.0.3]: https://github.com/sebastianbergmann/lines-of-code/compare/1.0.2...1.0.3 +[1.0.2]: https://github.com/sebastianbergmann/lines-of-code/compare/1.0.1...1.0.2 +[1.0.1]: https://github.com/sebastianbergmann/lines-of-code/compare/1.0.0...1.0.1 +[1.0.0]: https://github.com/sebastianbergmann/lines-of-code/compare/f959e71f00e591288acc024afe9cb966c6cf9bd6...1.0.0 diff --git a/vendor/sebastian/lines-of-code/LICENSE b/vendor/sebastian/lines-of-code/LICENSE new file mode 100644 index 000000000..d170181fa --- /dev/null +++ b/vendor/sebastian/lines-of-code/LICENSE @@ -0,0 +1,33 @@ +sebastian/lines-of-code + +Copyright (c) 2020, Sebastian Bergmann . +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: + + * Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + * Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in + the documentation and/or other materials provided with the + distribution. + + * Neither the name of Sebastian Bergmann nor the names of his + contributors may be used to endorse or promote products derived + from this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS +FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN +ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +POSSIBILITY OF SUCH DAMAGE. diff --git a/vendor/sebastian/lines-of-code/README.md b/vendor/sebastian/lines-of-code/README.md new file mode 100644 index 000000000..9457ef5a7 --- /dev/null +++ b/vendor/sebastian/lines-of-code/README.md @@ -0,0 +1,22 @@ +# sebastian/lines-of-code + +Library for counting the lines of code in PHP source code. + +[![Latest Stable Version](https://img.shields.io/packagist/v/sebastian/lines-of-code.svg?style=flat-square)](https://packagist.org/packages/sebastian/lines-of-code) +[![Minimum PHP Version](https://img.shields.io/badge/php-%3E%3D%207.3-8892BF.svg?style=flat-square)](https://php.net/) +[![CI Status](https://github.com/sebastianbergmann/lines-of-code/workflows/CI/badge.svg?branch=master&event=push)](https://phpunit.de/build-status.html) +[![Type Coverage](https://shepherd.dev/github/sebastianbergmann/lines-of-code/coverage.svg)](https://shepherd.dev/github/sebastianbergmann/lines-of-code) + +## Installation + +You can add this library as a local, per-project dependency to your project using [Composer](https://getcomposer.org/): + +``` +composer require sebastian/lines-of-code +``` + +If you only need this library during development, for instance to run your project's test suite, then you should add it as a development-time dependency: + +``` +composer require --dev sebastian/lines-of-code +``` diff --git a/vendor/sebastian/lines-of-code/composer.json b/vendor/sebastian/lines-of-code/composer.json new file mode 100644 index 000000000..95bb9e363 --- /dev/null +++ b/vendor/sebastian/lines-of-code/composer.json @@ -0,0 +1,42 @@ +{ + "name": "sebastian/lines-of-code", + "description": "Library for counting the lines of code in PHP source code", + "type": "library", + "homepage": "https://github.com/sebastianbergmann/lines-of-code", + "license": "BSD-3-Clause", + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "support": { + "issues": "https://github.com/sebastianbergmann/lines-of-code/issues" + }, + "prefer-stable": true, + "require": { + "php": ">=7.3", + "nikic/php-parser": "^4.6" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "config": { + "platform": { + "php": "7.3.0" + }, + "optimize-autoloader": true, + "sort-packages": true + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + } +} diff --git a/vendor/sebastian/lines-of-code/src/Counter.php b/vendor/sebastian/lines-of-code/src/Counter.php new file mode 100644 index 000000000..cfe5e20a7 --- /dev/null +++ b/vendor/sebastian/lines-of-code/src/Counter.php @@ -0,0 +1,91 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\LinesOfCode; + +use function substr_count; +use PhpParser\Error; +use PhpParser\Lexer; +use PhpParser\Node; +use PhpParser\NodeTraverser; +use PhpParser\Parser; +use PhpParser\ParserFactory; + +final class Counter +{ + /** + * @throws RuntimeException + */ + public function countInSourceFile(string $sourceFile): LinesOfCode + { + return $this->countInSourceString(file_get_contents($sourceFile)); + } + + /** + * @throws RuntimeException + */ + public function countInSourceString(string $source): LinesOfCode + { + $linesOfCode = substr_count($source, "\n"); + + if ($linesOfCode === 0 && !empty($source)) { + $linesOfCode = 1; + } + + try { + $nodes = $this->parser()->parse($source); + + assert($nodes !== null); + + return $this->countInAbstractSyntaxTree($linesOfCode, $nodes); + + // @codeCoverageIgnoreStart + } catch (Error $error) { + throw new RuntimeException( + $error->getMessage(), + (int) $error->getCode(), + $error + ); + } + // @codeCoverageIgnoreEnd + } + + /** + * @param Node[] $nodes + * + * @throws RuntimeException + */ + public function countInAbstractSyntaxTree(int $linesOfCode, array $nodes): LinesOfCode + { + $traverser = new NodeTraverser; + $visitor = new LineCountingVisitor($linesOfCode); + + $traverser->addVisitor($visitor); + + try { + /* @noinspection UnusedFunctionResultInspection */ + $traverser->traverse($nodes); + // @codeCoverageIgnoreStart + } catch (Error $error) { + throw new RuntimeException( + $error->getMessage(), + (int) $error->getCode(), + $error + ); + } + // @codeCoverageIgnoreEnd + + return $visitor->result(); + } + + private function parser(): Parser + { + return (new ParserFactory)->create(ParserFactory::PREFER_PHP7, new Lexer); + } +} diff --git a/vendor/sebastian/lines-of-code/src/Exception/Exception.php b/vendor/sebastian/lines-of-code/src/Exception/Exception.php new file mode 100644 index 000000000..11d543aa7 --- /dev/null +++ b/vendor/sebastian/lines-of-code/src/Exception/Exception.php @@ -0,0 +1,16 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\LinesOfCode; + +use Throwable; + +interface Exception extends Throwable +{ +} diff --git a/vendor/sebastian/lines-of-code/src/Exception/IllogicalValuesException.php b/vendor/sebastian/lines-of-code/src/Exception/IllogicalValuesException.php new file mode 100644 index 000000000..46a5c1b1f --- /dev/null +++ b/vendor/sebastian/lines-of-code/src/Exception/IllogicalValuesException.php @@ -0,0 +1,16 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\LinesOfCode; + +use LogicException; + +final class IllogicalValuesException extends LogicException implements Exception +{ +} diff --git a/vendor/sebastian/lines-of-code/src/Exception/NegativeValueException.php b/vendor/sebastian/lines-of-code/src/Exception/NegativeValueException.php new file mode 100644 index 000000000..40d27e1f0 --- /dev/null +++ b/vendor/sebastian/lines-of-code/src/Exception/NegativeValueException.php @@ -0,0 +1,16 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\LinesOfCode; + +use InvalidArgumentException; + +final class NegativeValueException extends InvalidArgumentException implements Exception +{ +} diff --git a/vendor/sebastian/global-state/tests/_fixture/BlacklistedClass.php b/vendor/sebastian/lines-of-code/src/Exception/RuntimeException.php similarity index 57% rename from vendor/sebastian/global-state/tests/_fixture/BlacklistedClass.php rename to vendor/sebastian/lines-of-code/src/Exception/RuntimeException.php index c1dc25983..4e6d66d0d 100644 --- a/vendor/sebastian/global-state/tests/_fixture/BlacklistedClass.php +++ b/vendor/sebastian/lines-of-code/src/Exception/RuntimeException.php @@ -1,15 +1,14 @@ * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ -namespace SebastianBergmann\GlobalState\TestFixture; +namespace SebastianBergmann\LinesOfCode; -class BlacklistedClass +final class RuntimeException extends \RuntimeException implements Exception { - private static $attribute; } diff --git a/vendor/sebastian/lines-of-code/src/LineCountingVisitor.php b/vendor/sebastian/lines-of-code/src/LineCountingVisitor.php new file mode 100644 index 000000000..ff433b2fc --- /dev/null +++ b/vendor/sebastian/lines-of-code/src/LineCountingVisitor.php @@ -0,0 +1,82 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\LinesOfCode; + +use function array_merge; +use function array_unique; +use function count; +use PhpParser\Comment; +use PhpParser\Node; +use PhpParser\Node\Expr; +use PhpParser\NodeVisitorAbstract; + +final class LineCountingVisitor extends NodeVisitorAbstract +{ + /** + * @var int + */ + private $linesOfCode; + + /** + * @var Comment[] + */ + private $comments = []; + + /** + * @var int[] + */ + private $linesWithStatements = []; + + public function __construct(int $linesOfCode) + { + $this->linesOfCode = $linesOfCode; + } + + public function enterNode(Node $node): void + { + $this->comments = array_merge($this->comments, $node->getComments()); + + if (!$node instanceof Expr) { + return; + } + + $this->linesWithStatements[] = $node->getStartLine(); + } + + public function result(): LinesOfCode + { + $commentLinesOfCode = 0; + + foreach ($this->comments() as $comment) { + $commentLinesOfCode += ($comment->getEndLine() - $comment->getStartLine() + 1); + } + + return new LinesOfCode( + $this->linesOfCode, + $commentLinesOfCode, + $this->linesOfCode - $commentLinesOfCode, + count(array_unique($this->linesWithStatements)) + ); + } + + /** + * @return Comment[] + */ + private function comments(): array + { + $comments = []; + + foreach ($this->comments as $comment) { + $comments[$comment->getStartLine() . '_' . $comment->getStartTokenPos() . '_' . $comment->getEndLine() . '_' . $comment->getEndTokenPos()] = $comment; + } + + return $comments; + } +} diff --git a/vendor/sebastian/lines-of-code/src/LinesOfCode.php b/vendor/sebastian/lines-of-code/src/LinesOfCode.php new file mode 100644 index 000000000..41829981a --- /dev/null +++ b/vendor/sebastian/lines-of-code/src/LinesOfCode.php @@ -0,0 +1,98 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\LinesOfCode; + +/** + * @psalm-immutable + */ +final class LinesOfCode +{ + /** + * @var int + */ + private $linesOfCode; + + /** + * @var int + */ + private $commentLinesOfCode; + + /** + * @var int + */ + private $nonCommentLinesOfCode; + + /** + * @var int + */ + private $logicalLinesOfCode; + + /** + * @throws IllogicalValuesException + * @throws NegativeValueException + */ + public function __construct(int $linesOfCode, int $commentLinesOfCode, int $nonCommentLinesOfCode, int $logicalLinesOfCode) + { + if ($linesOfCode < 0) { + throw new NegativeValueException('$linesOfCode must not be negative'); + } + + if ($commentLinesOfCode < 0) { + throw new NegativeValueException('$commentLinesOfCode must not be negative'); + } + + if ($nonCommentLinesOfCode < 0) { + throw new NegativeValueException('$nonCommentLinesOfCode must not be negative'); + } + + if ($logicalLinesOfCode < 0) { + throw new NegativeValueException('$logicalLinesOfCode must not be negative'); + } + + if ($linesOfCode - $commentLinesOfCode !== $nonCommentLinesOfCode) { + throw new IllogicalValuesException('$linesOfCode !== $commentLinesOfCode + $nonCommentLinesOfCode'); + } + + $this->linesOfCode = $linesOfCode; + $this->commentLinesOfCode = $commentLinesOfCode; + $this->nonCommentLinesOfCode = $nonCommentLinesOfCode; + $this->logicalLinesOfCode = $logicalLinesOfCode; + } + + public function linesOfCode(): int + { + return $this->linesOfCode; + } + + public function commentLinesOfCode(): int + { + return $this->commentLinesOfCode; + } + + public function nonCommentLinesOfCode(): int + { + return $this->nonCommentLinesOfCode; + } + + public function logicalLinesOfCode(): int + { + return $this->logicalLinesOfCode; + } + + public function plus(self $other): self + { + return new self( + $this->linesOfCode() + $other->linesOfCode(), + $this->commentLinesOfCode() + $other->commentLinesOfCode(), + $this->nonCommentLinesOfCode() + $other->nonCommentLinesOfCode(), + $this->logicalLinesOfCode() + $other->logicalLinesOfCode(), + ); + } +} diff --git a/vendor/sebastian/object-enumerator/.gitignore b/vendor/sebastian/object-enumerator/.gitignore deleted file mode 100644 index 5d748a85c..000000000 --- a/vendor/sebastian/object-enumerator/.gitignore +++ /dev/null @@ -1,8 +0,0 @@ -.idea -composer.lock -composer.phar -vendor/ -cache.properties -build/LICENSE -build/README.md -build/*.tgz diff --git a/vendor/sebastian/object-enumerator/.php_cs b/vendor/sebastian/object-enumerator/.php_cs deleted file mode 100644 index b7393bdac..000000000 --- a/vendor/sebastian/object-enumerator/.php_cs +++ /dev/null @@ -1,67 +0,0 @@ -files() - ->in('src') - ->in('tests') - ->name('*.php'); - -return Symfony\CS\Config\Config::create() - ->level(\Symfony\CS\FixerInterface::NONE_LEVEL) - ->fixers( - array( - 'align_double_arrow', - 'align_equals', - 'braces', - 'concat_with_spaces', - 'duplicate_semicolon', - 'elseif', - 'empty_return', - 'encoding', - 'eof_ending', - 'extra_empty_lines', - 'function_call_space', - 'function_declaration', - 'indentation', - 'join_function', - 'line_after_namespace', - 'linefeed', - 'list_commas', - 'lowercase_constants', - 'lowercase_keywords', - 'method_argument_space', - 'multiple_use', - 'namespace_no_leading_whitespace', - 'no_blank_lines_after_class_opening', - 'no_empty_lines_after_phpdocs', - 'parenthesis', - 'php_closing_tag', - 'phpdoc_indent', - 'phpdoc_no_access', - 'phpdoc_no_empty_return', - 'phpdoc_no_package', - 'phpdoc_params', - 'phpdoc_scalar', - 'phpdoc_separation', - 'phpdoc_to_comment', - 'phpdoc_trim', - 'phpdoc_types', - 'phpdoc_var_without_name', - 'remove_lines_between_uses', - 'return', - 'self_accessor', - 'short_array_syntax', - 'short_tag', - 'single_line_after_imports', - 'single_quote', - 'spaces_before_semicolon', - 'spaces_cast', - 'ternary_spaces', - 'trailing_spaces', - 'trim_array_spaces', - 'unused_use', - 'visibility', - 'whitespacy_lines' - ) - ) - ->finder($finder); - diff --git a/vendor/sebastian/object-enumerator/.psalm/baseline.xml b/vendor/sebastian/object-enumerator/.psalm/baseline.xml new file mode 100644 index 000000000..180b3f803 --- /dev/null +++ b/vendor/sebastian/object-enumerator/.psalm/baseline.xml @@ -0,0 +1,9 @@ + + + + + !is_array($variable) && !is_object($variable) + is_object($variable) + + + diff --git a/vendor/sebastian/object-enumerator/.psalm/config.xml b/vendor/sebastian/object-enumerator/.psalm/config.xml new file mode 100644 index 000000000..2a4b16f22 --- /dev/null +++ b/vendor/sebastian/object-enumerator/.psalm/config.xml @@ -0,0 +1,16 @@ + + + + + + + + + diff --git a/vendor/sebastian/object-enumerator/.travis.yml b/vendor/sebastian/object-enumerator/.travis.yml deleted file mode 100644 index 5ea0f5311..000000000 --- a/vendor/sebastian/object-enumerator/.travis.yml +++ /dev/null @@ -1,26 +0,0 @@ -language: php - -php: - - 7.0 - - 7.0snapshot - - 7.1 - - 7.1snapshot - - master - -sudo: false - -before_install: - - composer self-update - - composer clear-cache - -install: - - travis_retry composer update --no-interaction --no-ansi --no-progress --no-suggest --optimize-autoloader --prefer-stable - -script: - - ./vendor/bin/phpunit --coverage-clover=coverage.xml - -after_success: - - bash <(curl -s https://codecov.io/bash) - -notifications: - email: false diff --git a/vendor/sebastian/object-enumerator/ChangeLog.md b/vendor/sebastian/object-enumerator/ChangeLog.md index 2bf007bd6..886554189 100644 --- a/vendor/sebastian/object-enumerator/ChangeLog.md +++ b/vendor/sebastian/object-enumerator/ChangeLog.md @@ -2,11 +2,35 @@ All notable changes to `sebastianbergmann/object-enumerator` are documented in this file using the [Keep a CHANGELOG](http://keepachangelog.com/) principles. -## [3.0.4] - 2020-11-30 +## [4.0.4] - 2020-10-26 + +### Fixed + +* `SebastianBergmann\ObjectEnumerator\Exception` now correctly extends `\Throwable` + +## [4.0.3] - 2020-09-28 ### Changed -* Changed PHP version constraint in `composer.json` from `^7.0` to `>=7.0` +* Changed PHP version constraint in `composer.json` from `^7.3 || ^8.0` to `>=7.3` + +## [4.0.2] - 2020-06-26 + +### Added + +* This component is now supported on PHP 8 + +## [4.0.1] - 2020-06-15 + +### Changed + +* Tests etc. are now ignored for archive exports + +## [4.0.0] - 2020-02-07 + +### Removed + +* This component is no longer supported on PHP 7.0, PHP 7.1, and PHP 7.2 ## [3.0.3] - 2017-08-03 @@ -50,7 +74,11 @@ All notable changes to `sebastianbergmann/object-enumerator` are documented in t * Initial release -[3.0.4]: https://github.com/sebastianbergmann/object-enumerator/compare/3.0.3...3.0.4 +[4.0.4]: https://github.com/sebastianbergmann/object-enumerator/compare/4.0.3...4.0.4 +[4.0.3]: https://github.com/sebastianbergmann/object-enumerator/compare/4.0.2...4.0.3 +[4.0.2]: https://github.com/sebastianbergmann/object-enumerator/compare/4.0.1...4.0.2 +[4.0.1]: https://github.com/sebastianbergmann/object-enumerator/compare/4.0.0...4.0.1 +[4.0.0]: https://github.com/sebastianbergmann/object-enumerator/compare/3.0.3...4.0.0 [3.0.3]: https://github.com/sebastianbergmann/object-enumerator/compare/3.0.2...3.0.3 [3.0.2]: https://github.com/sebastianbergmann/object-enumerator/compare/3.0.1...3.0.2 [3.0.1]: https://github.com/sebastianbergmann/object-enumerator/compare/3.0.0...3.0.1 diff --git a/vendor/sebastian/object-enumerator/LICENSE b/vendor/sebastian/object-enumerator/LICENSE index ab8b70489..1389ad396 100644 --- a/vendor/sebastian/object-enumerator/LICENSE +++ b/vendor/sebastian/object-enumerator/LICENSE @@ -1,6 +1,6 @@ Object Enumerator -Copyright (c) 2016-2017, Sebastian Bergmann . +Copyright (c) 2016-2020, Sebastian Bergmann . All rights reserved. Redistribution and use in source and binary forms, with or without diff --git a/vendor/sebastian/object-enumerator/README.md b/vendor/sebastian/object-enumerator/README.md index be6f2dd26..afca0177b 100644 --- a/vendor/sebastian/object-enumerator/README.md +++ b/vendor/sebastian/object-enumerator/README.md @@ -1,4 +1,7 @@ -# Object Enumerator +# sebastian/object-enumerator + +[![CI Status](https://github.com/sebastianbergmann/object-enumerator/workflows/CI/badge.svg)](https://github.com/sebastianbergmann/object-enumerator/actions) +[![Type Coverage](https://shepherd.dev/github/sebastianbergmann/object-enumerator/coverage.svg)](https://shepherd.dev/github/sebastianbergmann/object-enumerator) Traverses array structures and object graphs to enumerate all referenced objects. @@ -6,9 +9,12 @@ Traverses array structures and object graphs to enumerate all referenced objects You can add this library as a local, per-project dependency to your project using [Composer](https://getcomposer.org/): - composer require sebastian/object-enumerator +``` +composer require sebastian/object-enumerator +``` If you only need this library during development, for instance to run your project's test suite, then you should add it as a development-time dependency: - composer require --dev sebastian/object-enumerator - +``` +composer require --dev sebastian/object-enumerator +``` diff --git a/vendor/sebastian/object-enumerator/build.xml b/vendor/sebastian/object-enumerator/build.xml deleted file mode 100644 index 086694f67..000000000 --- a/vendor/sebastian/object-enumerator/build.xml +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - diff --git a/vendor/sebastian/object-enumerator/composer.json b/vendor/sebastian/object-enumerator/composer.json index 33a946597..d68a21330 100644 --- a/vendor/sebastian/object-enumerator/composer.json +++ b/vendor/sebastian/object-enumerator/composer.json @@ -9,13 +9,21 @@ "email": "sebastian@phpunit.de" } ], + "prefer-stable": true, + "config": { + "platform": { + "php": "7.3.0" + }, + "optimize-autoloader": true, + "sort-packages": true + }, "require": { - "php": ">=7.0", - "sebastian/object-reflector": "^1.1.1", - "sebastian/recursion-context": "^3.0" + "php": ">=7.3", + "sebastian/object-reflector": "^2.0", + "sebastian/recursion-context": "^4.0" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^9.3" }, "autoload": { "classmap": [ @@ -29,7 +37,7 @@ }, "extra": { "branch-alias": { - "dev-master": "3.0.x-dev" + "dev-master": "4.0-dev" } } } diff --git a/vendor/sebastian/object-enumerator/phpunit.xml b/vendor/sebastian/object-enumerator/phpunit.xml index c401ba82c..7be976b13 100644 --- a/vendor/sebastian/object-enumerator/phpunit.xml +++ b/vendor/sebastian/object-enumerator/phpunit.xml @@ -1,20 +1,24 @@ - - tests - + + + tests + + - - + + src - - + + diff --git a/vendor/sebastian/object-enumerator/src/Enumerator.php b/vendor/sebastian/object-enumerator/src/Enumerator.php index 3a40f6d98..de75d17c5 100644 --- a/vendor/sebastian/object-enumerator/src/Enumerator.php +++ b/vendor/sebastian/object-enumerator/src/Enumerator.php @@ -1,15 +1,18 @@ - * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\ObjectEnumerator; +use function array_merge; +use function func_get_args; +use function is_array; +use function is_object; use SebastianBergmann\ObjectReflector\ObjectReflector; use SebastianBergmann\RecursionContext\Context; diff --git a/vendor/sebastian/object-enumerator/src/Exception.php b/vendor/sebastian/object-enumerator/src/Exception.php index 903b0b110..2f09d70aa 100644 --- a/vendor/sebastian/object-enumerator/src/Exception.php +++ b/vendor/sebastian/object-enumerator/src/Exception.php @@ -1,15 +1,16 @@ - * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\ObjectEnumerator; -interface Exception +use Throwable; + +interface Exception extends Throwable { } diff --git a/vendor/sebastian/object-enumerator/src/InvalidArgumentException.php b/vendor/sebastian/object-enumerator/src/InvalidArgumentException.php index 5250c1a16..ce2037cdb 100644 --- a/vendor/sebastian/object-enumerator/src/InvalidArgumentException.php +++ b/vendor/sebastian/object-enumerator/src/InvalidArgumentException.php @@ -1,13 +1,12 @@ - * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - namespace SebastianBergmann\ObjectEnumerator; class InvalidArgumentException extends \InvalidArgumentException implements Exception diff --git a/vendor/sebastian/object-enumerator/tests/EnumeratorTest.php b/vendor/sebastian/object-enumerator/tests/EnumeratorTest.php deleted file mode 100644 index a6bd29a6a..000000000 --- a/vendor/sebastian/object-enumerator/tests/EnumeratorTest.php +++ /dev/null @@ -1,139 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\ObjectEnumerator; - -use SebastianBergmann\ObjectEnumerator\Fixtures\ExceptionThrower; -use PHPUnit\Framework\TestCase; - -/** - * @covers SebastianBergmann\ObjectEnumerator\Enumerator - */ -class EnumeratorTest extends TestCase -{ - /** - * @var Enumerator - */ - private $enumerator; - - protected function setUp() - { - $this->enumerator = new Enumerator; - } - - public function testEnumeratesSingleObject() - { - $a = new \stdClass; - - $objects = $this->enumerator->enumerate($a); - - $this->assertCount(1, $objects); - $this->assertSame($a, $objects[0]); - } - - public function testEnumeratesArrayWithSingleObject() - { - $a = new \stdClass; - - $objects = $this->enumerator->enumerate([$a]); - - $this->assertCount(1, $objects); - $this->assertSame($a, $objects[0]); - } - - public function testEnumeratesArrayWithTwoReferencesToTheSameObject() - { - $a = new \stdClass; - - $objects = $this->enumerator->enumerate([$a, $a]); - - $this->assertCount(1, $objects); - $this->assertSame($a, $objects[0]); - } - - public function testEnumeratesArrayOfObjects() - { - $a = new \stdClass; - $b = new \stdClass; - - $objects = $this->enumerator->enumerate([$a, $b, null]); - - $this->assertCount(2, $objects); - $this->assertSame($a, $objects[0]); - $this->assertSame($b, $objects[1]); - } - - public function testEnumeratesObjectWithAggregatedObject() - { - $a = new \stdClass; - $b = new \stdClass; - - $a->b = $b; - $a->c = null; - - $objects = $this->enumerator->enumerate($a); - - $this->assertCount(2, $objects); - $this->assertSame($a, $objects[0]); - $this->assertSame($b, $objects[1]); - } - - public function testEnumeratesObjectWithAggregatedObjectsInArray() - { - $a = new \stdClass; - $b = new \stdClass; - - $a->b = [$b]; - - $objects = $this->enumerator->enumerate($a); - - $this->assertCount(2, $objects); - $this->assertSame($a, $objects[0]); - $this->assertSame($b, $objects[1]); - } - - public function testEnumeratesObjectsWithCyclicReferences() - { - $a = new \stdClass; - $b = new \stdClass; - - $a->b = $b; - $b->a = $a; - - $objects = $this->enumerator->enumerate([$a, $b]); - - $this->assertCount(2, $objects); - $this->assertSame($a, $objects[0]); - $this->assertSame($b, $objects[1]); - } - - public function testEnumeratesClassThatThrowsException() - { - $thrower = new ExceptionThrower(); - - $objects = $this->enumerator->enumerate($thrower); - - $this->assertSame($thrower, $objects[0]); - } - - public function testExceptionIsRaisedForInvalidArgument() - { - $this->expectException(InvalidArgumentException::class); - - $this->enumerator->enumerate(null); - } - - public function testExceptionIsRaisedForInvalidArgument2() - { - $this->expectException(InvalidArgumentException::class); - - $this->enumerator->enumerate([], ''); - } -} diff --git a/vendor/sebastian/object-enumerator/tests/_fixture/ExceptionThrower.php b/vendor/sebastian/object-enumerator/tests/_fixture/ExceptionThrower.php deleted file mode 100644 index a75f58522..000000000 --- a/vendor/sebastian/object-enumerator/tests/_fixture/ExceptionThrower.php +++ /dev/null @@ -1,28 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\ObjectEnumerator\Fixtures; - -use RuntimeException; - -class ExceptionThrower -{ - private $property; - - public function __construct() - { - unset($this->property); - } - - public function __get($property) - { - throw new RuntimeException; - } -} diff --git a/vendor/sebastian/object-reflector/.gitignore b/vendor/sebastian/object-reflector/.gitignore deleted file mode 100644 index c3e9d7e3c..000000000 --- a/vendor/sebastian/object-reflector/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -/.idea -/.php_cs.cache -/composer.lock -/vendor diff --git a/vendor/sebastian/object-reflector/.php_cs b/vendor/sebastian/object-reflector/.php_cs deleted file mode 100644 index cb814f395..000000000 --- a/vendor/sebastian/object-reflector/.php_cs +++ /dev/null @@ -1,79 +0,0 @@ - - -For the full copyright and license information, please view the LICENSE -file that was distributed with this source code. -EOF; - -return PhpCsFixer\Config::create() - ->setRiskyAllowed(true) - ->setRules( - [ - 'array_syntax' => ['syntax' => 'short'], - 'binary_operator_spaces' => [ - 'align_double_arrow' => true, - 'align_equals' => true - ], - 'blank_line_after_namespace' => true, - 'blank_line_before_return' => true, - 'braces' => true, - 'cast_spaces' => true, - 'concat_space' => ['spacing' => 'one'], - 'declare_strict_types' => true, - 'elseif' => true, - 'encoding' => true, - 'full_opening_tag' => true, - 'function_declaration' => true, - #'header_comment' => ['header' => $header, 'separate' => 'none'], - 'indentation_type' => true, - 'line_ending' => true, - 'lowercase_constants' => true, - 'lowercase_keywords' => true, - 'method_argument_space' => true, - 'no_alias_functions' => true, - 'no_blank_lines_after_class_opening' => true, - 'no_blank_lines_after_phpdoc' => true, - 'no_closing_tag' => true, - 'no_empty_phpdoc' => true, - 'no_empty_statement' => true, - 'no_extra_consecutive_blank_lines' => true, - 'no_leading_namespace_whitespace' => true, - 'no_singleline_whitespace_before_semicolons' => true, - 'no_spaces_after_function_name' => true, - 'no_spaces_inside_parenthesis' => true, - 'no_trailing_comma_in_list_call' => true, - 'no_trailing_whitespace' => true, - 'no_unused_imports' => true, - 'no_whitespace_in_blank_line' => true, - 'phpdoc_align' => true, - 'phpdoc_indent' => true, - 'phpdoc_no_access' => true, - 'phpdoc_no_empty_return' => true, - 'phpdoc_no_package' => true, - 'phpdoc_scalar' => true, - 'phpdoc_separation' => true, - 'phpdoc_to_comment' => true, - 'phpdoc_trim' => true, - 'phpdoc_types' => true, - 'phpdoc_var_without_name' => true, - 'self_accessor' => true, - 'simplified_null_return' => true, - 'single_blank_line_at_eof' => true, - 'single_import_per_statement' => true, - 'single_line_after_imports' => true, - 'single_quote' => true, - 'ternary_operator_spaces' => true, - 'trim_array_spaces' => true, - 'visibility_required' => true, - ] - ) - ->setFinder( - PhpCsFixer\Finder::create() - ->files() - ->in(__DIR__ . '/src') - ->in(__DIR__ . '/tests') - ->name('*.php') - ); diff --git a/vendor/sebastian/object-reflector/.psalm/baseline.xml b/vendor/sebastian/object-reflector/.psalm/baseline.xml new file mode 100644 index 000000000..965c12757 --- /dev/null +++ b/vendor/sebastian/object-reflector/.psalm/baseline.xml @@ -0,0 +1,8 @@ + + + + + is_object($object) + + + diff --git a/vendor/sebastian/object-reflector/.psalm/config.xml b/vendor/sebastian/object-reflector/.psalm/config.xml new file mode 100644 index 000000000..2a4b16f22 --- /dev/null +++ b/vendor/sebastian/object-reflector/.psalm/config.xml @@ -0,0 +1,16 @@ + + + + + + + + + diff --git a/vendor/sebastian/object-reflector/.travis.yml b/vendor/sebastian/object-reflector/.travis.yml deleted file mode 100644 index 5ea0f5311..000000000 --- a/vendor/sebastian/object-reflector/.travis.yml +++ /dev/null @@ -1,26 +0,0 @@ -language: php - -php: - - 7.0 - - 7.0snapshot - - 7.1 - - 7.1snapshot - - master - -sudo: false - -before_install: - - composer self-update - - composer clear-cache - -install: - - travis_retry composer update --no-interaction --no-ansi --no-progress --no-suggest --optimize-autoloader --prefer-stable - -script: - - ./vendor/bin/phpunit --coverage-clover=coverage.xml - -after_success: - - bash <(curl -s https://codecov.io/bash) - -notifications: - email: false diff --git a/vendor/sebastian/object-reflector/ChangeLog.md b/vendor/sebastian/object-reflector/ChangeLog.md index 89b034628..7fa62e90f 100644 --- a/vendor/sebastian/object-reflector/ChangeLog.md +++ b/vendor/sebastian/object-reflector/ChangeLog.md @@ -2,17 +2,41 @@ All notable changes to `sebastianbergmann/object-reflector` are documented in this file using the [Keep a CHANGELOG](http://keepachangelog.com/) principles. -## 1.1.2 - 2020-11-30 +## [2.0.4] - 2020-10-26 + +### Fixed + +* `SebastianBergmann\ObjectReflector\Exception` now correctly extends `\Throwable` + +## [2.0.3] - 2020-09-28 ### Changed -* Changed PHP version constraint in `composer.json` from `^7.0` to `>=7.1` +* Changed PHP version constraint in `composer.json` from `^7.3 || ^8.0` to `>=7.3` -## 1.1.1 - 2017-03-29 +## [2.0.2] - 2020-06-26 -* Fixed [#1](https://github.com/sebastianbergmann/object-reflector/issues/1): Attributes that with non-string names are not handled correctly +### Added -## 1.1.0 - 2017-03-16 +* This component is now supported on PHP 8 + +## [2.0.1] - 2020-06-15 + +### Changed + +* Tests etc. are now ignored for archive exports + +## [2.0.0] - 2020-02-07 + +### Removed + +* This component is no longer supported on PHP 7.0, PHP 7.1, and PHP 7.2 + +## [1.1.1] - 2017-03-29 + +* Fixed [#1](https://github.com/sebastianbergmann/object-reflector/issues/1): Attributes with non-string names are not handled correctly + +## [1.1.0] - 2017-03-16 ### Changed @@ -22,6 +46,10 @@ All notable changes to `sebastianbergmann/object-reflector` are documented in th * Initial release -[1.1.2]: https://github.com/sebastianbergmann/object-enumerator/compare/1.1.1...1.1.2 -[1.1.1]: https://github.com/sebastianbergmann/object-enumerator/compare/1.1.0...1.1.1 -[1.1.0]: https://github.com/sebastianbergmann/object-enumerator/compare/1.0.0...1.1.0 +[2.0.4]: https://github.com/sebastianbergmann/object-reflector/compare/2.0.3...2.0.4 +[2.0.3]: https://github.com/sebastianbergmann/object-reflector/compare/2.0.2...2.0.3 +[2.0.2]: https://github.com/sebastianbergmann/object-reflector/compare/2.0.1...2.0.2 +[2.0.1]: https://github.com/sebastianbergmann/object-reflector/compare/2.0.0...2.0.1 +[2.0.0]: https://github.com/sebastianbergmann/object-reflector/compare/1.1.1...2.0.0 +[1.1.1]: https://github.com/sebastianbergmann/object-reflector/compare/1.1.0...1.1.1 +[1.1.0]: https://github.com/sebastianbergmann/object-reflector/compare/1.0.0...1.1.0 diff --git a/vendor/sebastian/object-reflector/LICENSE b/vendor/sebastian/object-reflector/LICENSE index 54b1fd831..a80c16192 100644 --- a/vendor/sebastian/object-reflector/LICENSE +++ b/vendor/sebastian/object-reflector/LICENSE @@ -1,6 +1,6 @@ Object Reflector -Copyright (c) 2017, Sebastian Bergmann . +Copyright (c) 2017-2020, Sebastian Bergmann . All rights reserved. Redistribution and use in source and binary forms, with or without diff --git a/vendor/sebastian/object-reflector/README.md b/vendor/sebastian/object-reflector/README.md index 13b24f1f8..b7d5ae95f 100644 --- a/vendor/sebastian/object-reflector/README.md +++ b/vendor/sebastian/object-reflector/README.md @@ -1,4 +1,7 @@ -# Object Reflector +# sebastian/object-reflector + +[![CI Status](https://github.com/sebastianbergmann/object-reflector/workflows/CI/badge.svg)](https://github.com/sebastianbergmann/object-reflector/actions) +[![Type Coverage](https://shepherd.dev/github/sebastianbergmann/object-reflector/coverage.svg)](https://shepherd.dev/github/sebastianbergmann/object-reflector) Allows reflection of object attributes, including inherited and non-public ones. @@ -6,9 +9,12 @@ Allows reflection of object attributes, including inherited and non-public ones. You can add this library as a local, per-project dependency to your project using [Composer](https://getcomposer.org/): - composer require sebastian/object-reflector +``` +composer require sebastian/object-reflector +``` If you only need this library during development, for instance to run your project's test suite, then you should add it as a development-time dependency: - composer require --dev sebastian/object-reflector - +``` +composer require --dev sebastian/object-reflector +``` diff --git a/vendor/sebastian/object-reflector/build.xml b/vendor/sebastian/object-reflector/build.xml deleted file mode 100644 index 3368432aa..000000000 --- a/vendor/sebastian/object-reflector/build.xml +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - diff --git a/vendor/sebastian/object-reflector/composer.json b/vendor/sebastian/object-reflector/composer.json index 14b7c5c6c..36a337885 100644 --- a/vendor/sebastian/object-reflector/composer.json +++ b/vendor/sebastian/object-reflector/composer.json @@ -9,11 +9,19 @@ "email": "sebastian@phpunit.de" } ], + "prefer-stable": true, + "config": { + "platform": { + "php": "7.3.0" + }, + "optimize-autoloader": true, + "sort-packages": true + }, "require": { - "php": ">=7.0" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^9.3" }, "autoload": { "classmap": [ @@ -27,7 +35,7 @@ }, "extra": { "branch-alias": { - "dev-master": "1.1-dev" + "dev-master": "2.0-dev" } } } diff --git a/vendor/sebastian/object-reflector/phpunit.xml b/vendor/sebastian/object-reflector/phpunit.xml deleted file mode 100644 index 68febeb04..000000000 --- a/vendor/sebastian/object-reflector/phpunit.xml +++ /dev/null @@ -1,19 +0,0 @@ - - - - tests - - - - - src - - - diff --git a/vendor/sebastian/object-reflector/src/Exception.php b/vendor/sebastian/object-reflector/src/Exception.php index 9964b0924..36f8efeca 100644 --- a/vendor/sebastian/object-reflector/src/Exception.php +++ b/vendor/sebastian/object-reflector/src/Exception.php @@ -1,17 +1,16 @@ - * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - -declare(strict_types=1); - namespace SebastianBergmann\ObjectReflector; -interface Exception +use Throwable; + +interface Exception extends Throwable { } diff --git a/vendor/sebastian/object-reflector/src/InvalidArgumentException.php b/vendor/sebastian/object-reflector/src/InvalidArgumentException.php index e63c5d5ee..34b4cca19 100644 --- a/vendor/sebastian/object-reflector/src/InvalidArgumentException.php +++ b/vendor/sebastian/object-reflector/src/InvalidArgumentException.php @@ -1,15 +1,12 @@ - * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - -declare(strict_types=1); - namespace SebastianBergmann\ObjectReflector; class InvalidArgumentException extends \InvalidArgumentException implements Exception diff --git a/vendor/sebastian/object-reflector/src/ObjectReflector.php b/vendor/sebastian/object-reflector/src/ObjectReflector.php index 8b0390ad4..4abb5f55f 100644 --- a/vendor/sebastian/object-reflector/src/ObjectReflector.php +++ b/vendor/sebastian/object-reflector/src/ObjectReflector.php @@ -1,24 +1,24 @@ - * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ - -declare(strict_types=1); - namespace SebastianBergmann\ObjectReflector; +use function count; +use function explode; +use function get_class; +use function is_object; + class ObjectReflector { /** * @param object $object * - * @return array - * * @throws InvalidArgumentException */ public function getAttributes($object): array diff --git a/vendor/sebastian/object-reflector/tests/ObjectReflectorTest.php b/vendor/sebastian/object-reflector/tests/ObjectReflectorTest.php deleted file mode 100644 index ba0d97fc1..000000000 --- a/vendor/sebastian/object-reflector/tests/ObjectReflectorTest.php +++ /dev/null @@ -1,70 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -declare(strict_types=1); - -namespace SebastianBergmann\ObjectReflector; - -use PHPUnit\Framework\TestCase; -use SebastianBergmann\ObjectReflector\TestFixture\ChildClass; -use SebastianBergmann\ObjectReflector\TestFixture\ClassWithIntegerAttributeName; - -/** - * @covers SebastianBergmann\ObjectReflector\ObjectReflector - */ -class ObjectReflectorTest extends TestCase -{ - /** - * @var ObjectReflector - */ - private $objectReflector; - - protected function setUp()/*: void */ - { - $this->objectReflector = new ObjectReflector; - } - - public function testReflectsAttributesOfObject()/*: void */ - { - $o = new ChildClass; - - $this->assertEquals( - [ - 'privateInChild' => 'private', - 'protectedInChild' => 'protected', - 'publicInChild' => 'public', - 'undeclared' => 'undeclared', - 'SebastianBergmann\ObjectReflector\TestFixture\ParentClass::privateInParent' => 'private', - 'SebastianBergmann\ObjectReflector\TestFixture\ParentClass::protectedInParent' => 'protected', - 'SebastianBergmann\ObjectReflector\TestFixture\ParentClass::publicInParent' => 'public', - ], - $this->objectReflector->getAttributes($o) - ); - } - - public function testReflectsAttributeWithIntegerName()/*: void */ - { - $o = new ClassWithIntegerAttributeName; - - $this->assertEquals( - [ - 1 => 2 - ], - $this->objectReflector->getAttributes($o) - ); - } - - public function testRaisesExceptionWhenPassedArgumentIsNotAnObject()/*: void */ - { - $this->expectException(InvalidArgumentException::class); - - $this->objectReflector->getAttributes(null); - } -} diff --git a/vendor/sebastian/object-reflector/tests/_fixture/ChildClass.php b/vendor/sebastian/object-reflector/tests/_fixture/ChildClass.php deleted file mode 100644 index 5ee05f36a..000000000 --- a/vendor/sebastian/object-reflector/tests/_fixture/ChildClass.php +++ /dev/null @@ -1,25 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -declare(strict_types=1); - -namespace SebastianBergmann\ObjectReflector\TestFixture; - -class ChildClass extends ParentClass -{ - private $privateInChild = 'private'; - private $protectedInChild = 'protected'; - private $publicInChild = 'public'; - - public function __construct() - { - $this->undeclared = 'undeclared'; - } -} diff --git a/vendor/sebastian/object-reflector/tests/_fixture/ClassWithIntegerAttributeName.php b/vendor/sebastian/object-reflector/tests/_fixture/ClassWithIntegerAttributeName.php deleted file mode 100644 index ee49df3b1..000000000 --- a/vendor/sebastian/object-reflector/tests/_fixture/ClassWithIntegerAttributeName.php +++ /dev/null @@ -1,22 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -declare(strict_types=1); - -namespace SebastianBergmann\ObjectReflector\TestFixture; - -class ClassWithIntegerAttributeName -{ - public function __construct() - { - $i = 1; - $this->$i = 2; - } -} diff --git a/vendor/sebastian/object-reflector/tests/_fixture/ParentClass.php b/vendor/sebastian/object-reflector/tests/_fixture/ParentClass.php deleted file mode 100644 index b6886be95..000000000 --- a/vendor/sebastian/object-reflector/tests/_fixture/ParentClass.php +++ /dev/null @@ -1,20 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -declare(strict_types=1); - -namespace SebastianBergmann\ObjectReflector\TestFixture; - -class ParentClass -{ - private $privateInParent = 'private'; - private $protectedInParent = 'protected'; - private $publicInParent = 'public'; -} diff --git a/vendor/sebastian/recursion-context/.gitignore b/vendor/sebastian/recursion-context/.gitignore deleted file mode 100644 index 77aae3df6..000000000 --- a/vendor/sebastian/recursion-context/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -/.idea -/composer.lock -/vendor diff --git a/vendor/sebastian/recursion-context/.psalm/baseline.xml b/vendor/sebastian/recursion-context/.psalm/baseline.xml new file mode 100644 index 000000000..b946db1a5 --- /dev/null +++ b/vendor/sebastian/recursion-context/.psalm/baseline.xml @@ -0,0 +1,8 @@ + + + + + is_array($array) + + + diff --git a/vendor/sebastian/recursion-context/.psalm/config.xml b/vendor/sebastian/recursion-context/.psalm/config.xml new file mode 100644 index 000000000..2a4b16f22 --- /dev/null +++ b/vendor/sebastian/recursion-context/.psalm/config.xml @@ -0,0 +1,16 @@ + + + + + + + + + diff --git a/vendor/sebastian/recursion-context/.travis.yml b/vendor/sebastian/recursion-context/.travis.yml deleted file mode 100644 index ee0e40b21..000000000 --- a/vendor/sebastian/recursion-context/.travis.yml +++ /dev/null @@ -1,23 +0,0 @@ -language: php - -php: - - 7.0 - - 7.0snapshot - - 7.1 - - 7.1snapshot - - master - -sudo: false - -before_install: - - composer self-update - - composer clear-cache - -install: - - travis_retry composer update --no-interaction --no-ansi --no-progress --no-suggest --optimize-autoloader --prefer-stable - -script: - - ./vendor/bin/phpunit - -notifications: - email: false diff --git a/vendor/sebastian/recursion-context/ChangeLog.md b/vendor/sebastian/recursion-context/ChangeLog.md new file mode 100644 index 000000000..2fbacc2c3 --- /dev/null +++ b/vendor/sebastian/recursion-context/ChangeLog.md @@ -0,0 +1,33 @@ +# ChangeLog + +All notable changes are documented in this file using the [Keep a CHANGELOG](https://keepachangelog.com/) principles. + +## [4.0.4] - 2020-10-26 + +### Fixed + +* `SebastianBergmann\RecursionContext\Exception` now correctly extends `\Throwable` + +## [4.0.3] - 2020-09-28 + +### Changed + +* [#21](https://github.com/sebastianbergmann/recursion-context/pull/21): Add type annotations for in/out parameters +* Changed PHP version constraint in `composer.json` from `^7.3 || ^8.0` to `>=7.3` + +## [4.0.2] - 2020-06-26 + +### Added + +* This component is now supported on PHP 8 + +## [4.0.1] - 2020-06-15 + +### Changed + +* Tests etc. are now ignored for archive exports + +[4.0.4]: https://github.com/sebastianbergmann/recursion-context/compare/4.0.3...4.0.4 +[4.0.3]: https://github.com/sebastianbergmann/recursion-context/compare/4.0.2...4.0.3 +[4.0.2]: https://github.com/sebastianbergmann/recursion-context/compare/4.0.1...4.0.2 +[4.0.1]: https://github.com/sebastianbergmann/recursion-context/compare/4.0.0...4.0.1 diff --git a/vendor/sebastian/recursion-context/LICENSE b/vendor/sebastian/recursion-context/LICENSE index 00bfec5e8..0faffbbb2 100644 --- a/vendor/sebastian/recursion-context/LICENSE +++ b/vendor/sebastian/recursion-context/LICENSE @@ -1,6 +1,6 @@ Recursion Context -Copyright (c) 2002-2017, Sebastian Bergmann . +Copyright (c) 2002-2020, Sebastian Bergmann . All rights reserved. Redistribution and use in source and binary forms, with or without diff --git a/vendor/sebastian/recursion-context/README.md b/vendor/sebastian/recursion-context/README.md index 0b8949626..8e4d2a084 100644 --- a/vendor/sebastian/recursion-context/README.md +++ b/vendor/sebastian/recursion-context/README.md @@ -1,14 +1,18 @@ -# Recursion Context +# sebastian/recursion-context -... +[![CI Status](https://github.com/sebastianbergmann/recursion-context/workflows/CI/badge.svg)](https://github.com/sebastianbergmann/recursion-context/actions) +[![Type Coverage](https://shepherd.dev/github/sebastianbergmann/recursion-context/coverage.svg)](https://shepherd.dev/github/sebastianbergmann/recursion-context) ## Installation You can add this library as a local, per-project dependency to your project using [Composer](https://getcomposer.org/): - composer require sebastian/recursion-context +``` +composer require sebastian/recursion-context +``` If you only need this library during development, for instance to run your project's test suite, then you should add it as a development-time dependency: - composer require --dev sebastian/recursion-context - +``` +composer require --dev sebastian/recursion-context +``` diff --git a/vendor/sebastian/recursion-context/build.xml b/vendor/sebastian/recursion-context/build.xml deleted file mode 100644 index 896bd34ea..000000000 --- a/vendor/sebastian/recursion-context/build.xml +++ /dev/null @@ -1,21 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - diff --git a/vendor/sebastian/recursion-context/composer.json b/vendor/sebastian/recursion-context/composer.json index f2bef3621..8a5408232 100644 --- a/vendor/sebastian/recursion-context/composer.json +++ b/vendor/sebastian/recursion-context/composer.json @@ -17,11 +17,19 @@ "email": "aharvey@php.net" } ], + "prefer-stable": true, + "config": { + "platform": { + "php": "7.3.0" + }, + "optimize-autoloader": true, + "sort-packages": true + }, "require": { - "php": ">=7.0" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^9.3" }, "autoload": { "classmap": [ @@ -30,7 +38,7 @@ }, "extra": { "branch-alias": { - "dev-master": "3.0.x-dev" + "dev-master": "4.0-dev" } } } diff --git a/vendor/sebastian/recursion-context/phpunit.xml b/vendor/sebastian/recursion-context/phpunit.xml deleted file mode 100644 index 68febeb04..000000000 --- a/vendor/sebastian/recursion-context/phpunit.xml +++ /dev/null @@ -1,19 +0,0 @@ - - - - tests - - - - - src - - - diff --git a/vendor/sebastian/recursion-context/src/Context.php b/vendor/sebastian/recursion-context/src/Context.php index 0b4b8a0dd..87fe7b04f 100644 --- a/vendor/sebastian/recursion-context/src/Context.php +++ b/vendor/sebastian/recursion-context/src/Context.php @@ -1,4 +1,4 @@ -arrays = array(); - $this->objects = new \SplObjectStorage; + $this->arrays = []; + $this->objects = new SplObjectStorage; + } + + /** + * @codeCoverageIgnore + */ + public function __destruct() + { + foreach ($this->arrays as &$array) { + if (is_array($array)) { + array_pop($array); + array_pop($array); + } + } } /** * Adds a value to the context. * - * @param array|object $value The value to add. - * - * @return int|string The ID of the stored value, either as a string or integer. + * @param array|object $value the value to add * * @throws InvalidArgumentException Thrown if $value is not an array or object + * + * @return bool|int|string the ID of the stored value, either as a string or integer + * + * @psalm-template T + * @psalm-param T $value + * @param-out T $value */ public function add(&$value) { if (is_array($value)) { return $this->addArray($value); - } elseif (is_object($value)) { + } + + if (is_object($value)) { return $this->addObject($value); } @@ -60,17 +89,23 @@ final class Context /** * Checks if the given value exists within the context. * - * @param array|object $value The value to check. - * - * @return int|string|false The string or integer ID of the stored value if it has already been seen, or false if the value is not stored. + * @param array|object $value the value to check * * @throws InvalidArgumentException Thrown if $value is not an array or object + * + * @return false|int|string the string or integer ID of the stored value if it has already been seen, or false if the value is not stored + * + * @psalm-template T + * @psalm-param T $value + * @param-out T $value */ public function contains(&$value) { if (is_array($value)) { return $this->containsArray($value); - } elseif (is_object($value)) { + } + + if (is_object($value)) { return $this->containsObject($value); } @@ -80,8 +115,6 @@ final class Context } /** - * @param array $array - * * @return bool|int */ private function addArray(array &$array) @@ -117,10 +150,8 @@ final class Context /** * @param object $object - * - * @return string */ - private function addObject($object) + private function addObject($object): string { if (!$this->objects->contains($object)) { $this->objects->attach($object); @@ -130,9 +161,7 @@ final class Context } /** - * @param array $array - * - * @return int|false + * @return false|int */ private function containsArray(array &$array) { @@ -144,7 +173,7 @@ final class Context /** * @param object $value * - * @return string|false + * @return false|string */ private function containsObject($value) { @@ -154,14 +183,4 @@ final class Context return false; } - - public function __destruct() - { - foreach ($this->arrays as &$array) { - if (is_array($array)) { - array_pop($array); - array_pop($array); - } - } - } } diff --git a/vendor/sebastian/recursion-context/src/Exception.php b/vendor/sebastian/recursion-context/src/Exception.php index 4a1557ba3..e3a9c017d 100644 --- a/vendor/sebastian/recursion-context/src/Exception.php +++ b/vendor/sebastian/recursion-context/src/Exception.php @@ -1,4 +1,4 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace SebastianBergmann\RecursionContext; - -use PHPUnit\Framework\TestCase; - -/** - * @covers SebastianBergmann\RecursionContext\Context - */ -class ContextTest extends TestCase -{ - /** - * @var \SebastianBergmann\RecursionContext\Context - */ - private $context; - - protected function setUp() - { - $this->context = new Context(); - } - - public function failsProvider() - { - return array( - array(true), - array(false), - array(null), - array('string'), - array(1), - array(1.5), - array(fopen('php://memory', 'r')) - ); - } - - public function valuesProvider() - { - $obj2 = new \stdClass(); - $obj2->foo = 'bar'; - - $obj3 = (object) array(1,2,"Test\r\n",4,5,6,7,8); - - $obj = new \stdClass(); - //@codingStandardsIgnoreStart - $obj->null = null; - //@codingStandardsIgnoreEnd - $obj->boolean = true; - $obj->integer = 1; - $obj->double = 1.2; - $obj->string = '1'; - $obj->text = "this\nis\na\nvery\nvery\nvery\nvery\nvery\nvery\rlong\n\rtext"; - $obj->object = $obj2; - $obj->objectagain = $obj2; - $obj->array = array('foo' => 'bar'); - $obj->array2 = array(1,2,3,4,5,6); - $obj->array3 = array($obj, $obj2, $obj3); - $obj->self = $obj; - - $storage = new \SplObjectStorage(); - $storage->attach($obj2); - $storage->foo = $obj2; - - return array( - array($obj, spl_object_hash($obj)), - array($obj2, spl_object_hash($obj2)), - array($obj3, spl_object_hash($obj3)), - array($storage, spl_object_hash($storage)), - array($obj->array, 0), - array($obj->array2, 0), - array($obj->array3, 0) - ); - } - - /** - * @covers SebastianBergmann\RecursionContext\Context::add - * @uses SebastianBergmann\RecursionContext\InvalidArgumentException - * @dataProvider failsProvider - */ - public function testAddFails($value) - { - $this->expectException(Exception::class); - $this->expectExceptionMessage('Only arrays and objects are supported'); - - $this->context->add($value); - } - - /** - * @covers SebastianBergmann\RecursionContext\Context::contains - * @uses SebastianBergmann\RecursionContext\InvalidArgumentException - * @dataProvider failsProvider - */ - public function testContainsFails($value) - { - $this->expectException(Exception::class); - $this->expectExceptionMessage('Only arrays and objects are supported'); - - $this->context->contains($value); - } - - /** - * @covers SebastianBergmann\RecursionContext\Context::add - * @dataProvider valuesProvider - */ - public function testAdd($value, $key) - { - $this->assertEquals($key, $this->context->add($value)); - - // Test we get the same key on subsequent adds - $this->assertEquals($key, $this->context->add($value)); - } - - /** - * @covers SebastianBergmann\RecursionContext\Context::contains - * @uses SebastianBergmann\RecursionContext\Context::add - * @depends testAdd - * @dataProvider valuesProvider - */ - public function testContainsFound($value, $key) - { - $this->context->add($value); - $this->assertEquals($key, $this->context->contains($value)); - - // Test we get the same key on subsequent calls - $this->assertEquals($key, $this->context->contains($value)); - } - - /** - * @covers SebastianBergmann\RecursionContext\Context::contains - * @dataProvider valuesProvider - */ - public function testContainsNotFound($value) - { - $this->assertFalse($this->context->contains($value)); - } -} diff --git a/vendor/phpunit/php-token-stream/.gitattributes b/vendor/sebastian/resource-operations/.gitattributes similarity index 53% rename from vendor/phpunit/php-token-stream/.gitattributes rename to vendor/sebastian/resource-operations/.gitattributes index a88b8c68e..85e55ebca 100644 --- a/vendor/phpunit/php-token-stream/.gitattributes +++ b/vendor/sebastian/resource-operations/.gitattributes @@ -1,12 +1,7 @@ /.github export-ignore -/.phive export-ignore /.php_cs.dist export-ignore -/.psalm export-ignore -/bin export-ignore /build.xml export-ignore /phpunit.xml export-ignore /tests export-ignore -/tools export-ignore -/tools/* binary *.php diff=php diff --git a/vendor/sebastian/resource-operations/.github/stale.yml b/vendor/sebastian/resource-operations/.github/stale.yml deleted file mode 100644 index 4eadca327..000000000 --- a/vendor/sebastian/resource-operations/.github/stale.yml +++ /dev/null @@ -1,40 +0,0 @@ -# Configuration for probot-stale - https://github.com/probot/stale - -# Number of days of inactivity before an Issue or Pull Request becomes stale -daysUntilStale: 60 - -# Number of days of inactivity before a stale Issue or Pull Request is closed. -# Set to false to disable. If disabled, issues still need to be closed manually, but will remain marked as stale. -daysUntilClose: 7 - -# Issues or Pull Requests with these labels will never be considered stale. Set to `[]` to disable -exemptLabels: - - enhancement - -# Set to true to ignore issues in a project (defaults to false) -exemptProjects: false - -# Set to true to ignore issues in a milestone (defaults to false) -exemptMilestones: false - -# Label to use when marking as stale -staleLabel: stale - -# Comment to post when marking as stale. Set to `false` to disable -markComment: > - This issue has been automatically marked as stale because it has not had activity within the last 60 days. It will be closed after 7 days if no further activity occurs. Thank you for your contributions. - -# Comment to post when removing the stale label. -# unmarkComment: > -# Your comment here. - -# Comment to post when closing a stale Issue or Pull Request. -closeComment: > - This issue has been automatically closed because it has not had activity since it was marked as stale. Thank you for your contributions. - -# Limit the number of actions per hour, from 1-30. Default is 30 -limitPerRun: 30 - -# Limit to only `issues` or `pulls` -only: issues - diff --git a/vendor/sebastian/resource-operations/.gitignore b/vendor/sebastian/resource-operations/.gitignore index 4f9b2392f..a086c7819 100644 --- a/vendor/sebastian/resource-operations/.gitignore +++ b/vendor/sebastian/resource-operations/.gitignore @@ -3,3 +3,4 @@ /build/FunctionSignatureMap.php /composer.lock /vendor +/.phpunit.result.cache diff --git a/vendor/sebastian/resource-operations/.php_cs.dist b/vendor/sebastian/resource-operations/.php_cs.dist deleted file mode 100644 index 22641a643..000000000 --- a/vendor/sebastian/resource-operations/.php_cs.dist +++ /dev/null @@ -1,191 +0,0 @@ - - -For the full copyright and license information, please view the LICENSE -file that was distributed with this source code. -EOF; - -return PhpCsFixer\Config::create() - ->setRiskyAllowed(true) - ->setRules( - [ - 'align_multiline_comment' => true, - 'array_indentation' => true, - 'array_syntax' => ['syntax' => 'short'], - 'binary_operator_spaces' => [ - 'operators' => [ - '=' => 'align', - '=>' => 'align', - ], - ], - 'blank_line_after_namespace' => true, - 'blank_line_before_statement' => [ - 'statements' => [ - 'break', - 'continue', - 'declare', - 'do', - 'for', - 'foreach', - 'if', - 'include', - 'include_once', - 'require', - 'require_once', - 'return', - 'switch', - 'throw', - 'try', - 'while', - 'yield', - ], - ], - 'braces' => true, - 'cast_spaces' => true, - 'class_attributes_separation' => ['elements' => ['const', 'method', 'property']], - 'combine_consecutive_issets' => true, - 'combine_consecutive_unsets' => true, - 'compact_nullable_typehint' => true, - 'concat_space' => ['spacing' => 'one'], - 'declare_equal_normalize' => ['space' => 'none'], - 'declare_strict_types' => true, - 'dir_constant' => true, - 'elseif' => true, - 'encoding' => true, - 'full_opening_tag' => true, - 'function_declaration' => true, - 'header_comment' => ['header' => $header, 'separate' => 'none'], - 'indentation_type' => true, - 'is_null' => true, - 'line_ending' => true, - 'list_syntax' => ['syntax' => 'short'], - 'logical_operators' => true, - 'lowercase_cast' => true, - 'lowercase_constants' => true, - 'lowercase_keywords' => true, - 'lowercase_static_reference' => true, - 'magic_constant_casing' => true, - 'method_argument_space' => ['ensure_fully_multiline' => true], - 'modernize_types_casting' => true, - 'multiline_comment_opening_closing' => true, - 'multiline_whitespace_before_semicolons' => true, - 'native_constant_invocation' => true, - 'native_function_casing' => true, - 'native_function_invocation' => true, - 'new_with_braces' => false, - 'no_alias_functions' => true, - 'no_alternative_syntax' => true, - 'no_blank_lines_after_class_opening' => true, - 'no_blank_lines_after_phpdoc' => true, - 'no_blank_lines_before_namespace' => true, - 'no_closing_tag' => true, - 'no_empty_comment' => true, - 'no_empty_phpdoc' => true, - 'no_empty_statement' => true, - 'no_extra_blank_lines' => true, - 'no_homoglyph_names' => true, - 'no_leading_import_slash' => true, - 'no_leading_namespace_whitespace' => true, - 'no_mixed_echo_print' => ['use' => 'print'], - 'no_multiline_whitespace_around_double_arrow' => true, - 'no_null_property_initialization' => true, - 'no_php4_constructor' => true, - 'no_short_bool_cast' => true, - 'no_short_echo_tag' => true, - 'no_singleline_whitespace_before_semicolons' => true, - 'no_spaces_after_function_name' => true, - 'no_spaces_inside_parenthesis' => true, - 'no_superfluous_elseif' => true, - 'no_superfluous_phpdoc_tags' => true, - 'no_trailing_comma_in_list_call' => true, - 'no_trailing_comma_in_singleline_array' => true, - 'no_trailing_whitespace' => true, - 'no_trailing_whitespace_in_comment' => true, - 'no_unneeded_control_parentheses' => true, - 'no_unneeded_curly_braces' => true, - 'no_unneeded_final_method' => true, - 'no_unreachable_default_argument_value' => true, - 'no_unset_on_property' => true, - 'no_unused_imports' => true, - 'no_useless_else' => true, - 'no_useless_return' => true, - 'no_whitespace_before_comma_in_array' => true, - 'no_whitespace_in_blank_line' => true, - 'non_printable_character' => true, - 'normalize_index_brace' => true, - 'object_operator_without_whitespace' => true, - 'ordered_class_elements' => [ - 'order' => [ - 'use_trait', - 'constant_public', - 'constant_protected', - 'constant_private', - 'property_public_static', - 'property_protected_static', - 'property_private_static', - 'property_public', - 'property_protected', - 'property_private', - 'method_public_static', - 'construct', - 'destruct', - 'magic', - 'phpunit', - 'method_public', - 'method_protected', - 'method_private', - 'method_protected_static', - 'method_private_static', - ], - ], - 'ordered_imports' => true, - 'phpdoc_add_missing_param_annotation' => true, - 'phpdoc_align' => true, - 'phpdoc_annotation_without_dot' => true, - 'phpdoc_indent' => true, - 'phpdoc_no_access' => true, - 'phpdoc_no_empty_return' => true, - 'phpdoc_no_package' => true, - 'phpdoc_order' => true, - 'phpdoc_return_self_reference' => true, - 'phpdoc_scalar' => true, - 'phpdoc_separation' => true, - 'phpdoc_single_line_var_spacing' => true, - 'phpdoc_to_comment' => true, - 'phpdoc_trim' => true, - 'phpdoc_trim_consecutive_blank_line_separation' => true, - 'phpdoc_types' => true, - 'phpdoc_types_order' => true, - 'phpdoc_var_without_name' => true, - 'pow_to_exponentiation' => true, - 'protected_to_private' => true, - 'return_assignment' => true, - 'return_type_declaration' => ['space_before' => 'none'], - 'self_accessor' => true, - 'semicolon_after_instruction' => true, - 'set_type_to_cast' => true, - 'short_scalar_cast' => true, - 'simplified_null_return' => true, - 'single_blank_line_at_eof' => true, - 'single_import_per_statement' => true, - 'single_line_after_imports' => true, - 'single_quote' => true, - 'standardize_not_equals' => true, - 'ternary_to_null_coalescing' => true, - 'trailing_comma_in_multiline_array' => true, - 'trim_array_spaces' => true, - 'unary_operator_spaces' => true, - 'visibility_required' => true, - 'void_return' => true, - 'whitespace_after_comma_in_array' => true, - ] - ) - ->setFinder( - PhpCsFixer\Finder::create() - ->files() - ->in(__DIR__ . '/src') - ->in(__DIR__ . '/tests') - ); diff --git a/vendor/sebastian/resource-operations/ChangeLog.md b/vendor/sebastian/resource-operations/ChangeLog.md index 311f2d4b0..e6dc73922 100644 --- a/vendor/sebastian/resource-operations/ChangeLog.md +++ b/vendor/sebastian/resource-operations/ChangeLog.md @@ -2,11 +2,29 @@ All notable changes are documented in this file using the [Keep a CHANGELOG](https://keepachangelog.com/) principles. -## [2.0.2] - 2020-11-30 +## [3.0.3] - 2020-09-28 ### Changed -* Changed PHP version constraint in `composer.json` from `^7.1` to `>=7.1` +* Changed PHP version constraint in `composer.json` from `^7.3 || ^8.0` to `>=7.3` + +## [3.0.2] - 2020-06-26 + +### Added + +* This component is now supported on PHP 8 + +## [3.0.1] - 2020-06-15 + +### Changed + +* Tests etc. are now ignored for archive exports + +## [3.0.0] - 2020-02-07 + +### Removed + +* This component is no longer supported on PHP 7.1 and PHP 7.2 ## [2.0.1] - 2018-10-04 @@ -28,6 +46,9 @@ All notable changes are documented in this file using the [Keep a CHANGELOG](htt * Initial release -[2.0.2]: https://github.com/sebastianbergmann/comparator/compare/2.0.1...2.0.2 -[2.0.1]: https://github.com/sebastianbergmann/comparator/compare/2.0.0...2.0.1 -[2.0.0]: https://github.com/sebastianbergmann/comparator/compare/1.0.0...2.0.0 +[3.0.3]: https://github.com/sebastianbergmann/comparator/resource-operations/3.0.2...3.0.3 +[3.0.2]: https://github.com/sebastianbergmann/comparator/resource-operations/3.0.1...3.0.2 +[3.0.1]: https://github.com/sebastianbergmann/comparator/resource-operations/3.0.0...3.0.1 +[3.0.0]: https://github.com/sebastianbergmann/comparator/resource-operations/2.0.1...3.0.0 +[2.0.1]: https://github.com/sebastianbergmann/comparator/resource-operations/2.0.0...2.0.1 +[2.0.0]: https://github.com/sebastianbergmann/comparator/resource-operations/1.0.0...2.0.0 diff --git a/vendor/sebastian/resource-operations/LICENSE b/vendor/sebastian/resource-operations/LICENSE index 272721811..dccd6b074 100644 --- a/vendor/sebastian/resource-operations/LICENSE +++ b/vendor/sebastian/resource-operations/LICENSE @@ -1,6 +1,6 @@ Resource Operations -Copyright (c) 2015-2018, Sebastian Bergmann . +Copyright (c) 2015-2020, Sebastian Bergmann . All rights reserved. Redistribution and use in source and binary forms, with or without diff --git a/vendor/sebastian/resource-operations/build.xml b/vendor/sebastian/resource-operations/build.xml deleted file mode 100644 index 695ffa88e..000000000 --- a/vendor/sebastian/resource-operations/build.xml +++ /dev/null @@ -1,38 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/vendor/sebastian/resource-operations/composer.json b/vendor/sebastian/resource-operations/composer.json index 733a3f829..870be3c12 100644 --- a/vendor/sebastian/resource-operations/composer.json +++ b/vendor/sebastian/resource-operations/composer.json @@ -9,8 +9,12 @@ "email": "sebastian@phpunit.de" } ], + "prefer-stable": true, "require": { - "php": ">=7.1" + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.0" }, "autoload": { "classmap": [ @@ -19,14 +23,14 @@ }, "config": { "platform": { - "php": "7.1.0" + "php": "7.3.0" }, "optimize-autoloader": true, "sort-packages": true }, "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-master": "3.0-dev" } } } diff --git a/vendor/sebastian/resource-operations/tests/ResourceOperationsTest.php b/vendor/sebastian/resource-operations/tests/ResourceOperationsTest.php deleted file mode 100644 index f05ea0d50..000000000 --- a/vendor/sebastian/resource-operations/tests/ResourceOperationsTest.php +++ /dev/null @@ -1,26 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\ResourceOperations; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\ResourceOperations\ResourceOperations - */ -final class ResourceOperationsTest extends TestCase -{ - public function testGetFunctions(): void - { - $functions = ResourceOperations::getFunctions(); - - $this->assertInternalType('array', $functions); - $this->assertContains('fopen', $functions); - } -} diff --git a/vendor/sebastian/type/.gitattributes b/vendor/sebastian/type/.gitattributes deleted file mode 100644 index 15e41cb1b..000000000 --- a/vendor/sebastian/type/.gitattributes +++ /dev/null @@ -1,2 +0,0 @@ -/tools export-ignore - diff --git a/vendor/sebastian/type/.github/FUNDING.yml b/vendor/sebastian/type/.github/FUNDING.yml deleted file mode 100644 index b19ea81a0..000000000 --- a/vendor/sebastian/type/.github/FUNDING.yml +++ /dev/null @@ -1 +0,0 @@ -patreon: s_bergmann diff --git a/vendor/sebastian/type/.gitignore b/vendor/sebastian/type/.gitignore deleted file mode 100644 index 832c68a7b..000000000 --- a/vendor/sebastian/type/.gitignore +++ /dev/null @@ -1,72 +0,0 @@ -/.php_cs -/.php_cs.cache -/.phpunit.result.cache -/composer.lock -/vendor - -# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio and WebStorm -# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839 - -# User-specific stuff -.idea/**/workspace.xml -.idea/**/tasks.xml -.idea/**/usage.statistics.xml -.idea/**/dictionaries -.idea/**/shelf - -# Generated files -.idea/**/contentModel.xml - -# Sensitive or high-churn files -.idea/**/dataSources/ -.idea/**/dataSources.ids -.idea/**/dataSources.local.xml -.idea/**/sqlDataSources.xml -.idea/**/dynamic.xml -.idea/**/uiDesigner.xml -.idea/**/dbnavigator.xml - -# Gradle -.idea/**/gradle.xml -.idea/**/libraries - -# Gradle and Maven with auto-import -# When using Gradle or Maven with auto-import, you should exclude module files, -# since they will be recreated, and may cause churn. Uncomment if using -# auto-import. -# .idea/modules.xml -# .idea/*.iml -# .idea/modules - -# CMake -cmake-build-*/ - -# Mongo Explorer plugin -.idea/**/mongoSettings.xml - -# File-based project format -*.iws - -# IntelliJ -out/ - -# mpeltonen/sbt-idea plugin -.idea_modules/ - -# JIRA plugin -atlassian-ide-plugin.xml - -# Cursive Clojure plugin -.idea/replstate.xml - -# Crashlytics plugin (for Android Studio and IntelliJ) -com_crashlytics_export_strings.xml -crashlytics.properties -crashlytics-build.properties -fabric.properties - -# Editor-based Rest Client -.idea/httpRequests - -# Android studio 3.1+ serialized cache file -.idea/caches/build_file_checksums.ser diff --git a/vendor/sebastian/type/.idea/inspectionProfiles/Project_Default.xml b/vendor/sebastian/type/.idea/inspectionProfiles/Project_Default.xml deleted file mode 100644 index 272394b89..000000000 --- a/vendor/sebastian/type/.idea/inspectionProfiles/Project_Default.xml +++ /dev/null @@ -1,499 +0,0 @@ - - - - \ No newline at end of file diff --git a/vendor/sebastian/type/.idea/misc.xml b/vendor/sebastian/type/.idea/misc.xml deleted file mode 100644 index 28a804d89..000000000 --- a/vendor/sebastian/type/.idea/misc.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - \ No newline at end of file diff --git a/vendor/sebastian/type/.idea/modules.xml b/vendor/sebastian/type/.idea/modules.xml deleted file mode 100644 index cfc6039c3..000000000 --- a/vendor/sebastian/type/.idea/modules.xml +++ /dev/null @@ -1,8 +0,0 @@ - - - - - - - - \ No newline at end of file diff --git a/vendor/sebastian/type/.idea/php-inspections-ea-ultimate.xml b/vendor/sebastian/type/.idea/php-inspections-ea-ultimate.xml deleted file mode 100644 index 26c2a682b..000000000 --- a/vendor/sebastian/type/.idea/php-inspections-ea-ultimate.xml +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/vendor/sebastian/type/.idea/php.xml b/vendor/sebastian/type/.idea/php.xml deleted file mode 100644 index b4dab6653..000000000 --- a/vendor/sebastian/type/.idea/php.xml +++ /dev/null @@ -1,42 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/vendor/sebastian/type/.idea/type.iml b/vendor/sebastian/type/.idea/type.iml deleted file mode 100644 index 24c4e4042..000000000 --- a/vendor/sebastian/type/.idea/type.iml +++ /dev/null @@ -1,40 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/vendor/sebastian/type/.idea/vcs.xml b/vendor/sebastian/type/.idea/vcs.xml deleted file mode 100644 index 94a25f7f4..000000000 --- a/vendor/sebastian/type/.idea/vcs.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/vendor/sebastian/type/.php_cs.dist b/vendor/sebastian/type/.php_cs.dist deleted file mode 100644 index 00eae398f..000000000 --- a/vendor/sebastian/type/.php_cs.dist +++ /dev/null @@ -1,200 +0,0 @@ - - -For the full copyright and license information, please view the LICENSE -file that was distributed with this source code. -EOF; - -return PhpCsFixer\Config::create() - ->setRiskyAllowed(true) - ->setRules( - [ - 'align_multiline_comment' => true, - 'array_indentation' => true, - 'array_syntax' => ['syntax' => 'short'], - 'binary_operator_spaces' => [ - 'operators' => [ - '=' => 'align', - '=>' => 'align', - ], - ], - 'blank_line_after_namespace' => true, - 'blank_line_before_statement' => [ - 'statements' => [ - 'break', - 'continue', - 'declare', - 'do', - 'for', - 'foreach', - 'if', - 'include', - 'include_once', - 'require', - 'require_once', - 'return', - 'switch', - 'throw', - 'try', - 'while', - 'yield', - ], - ], - 'braces' => true, - 'cast_spaces' => true, - 'class_attributes_separation' => ['elements' => ['const', 'method', 'property']], - 'combine_consecutive_issets' => true, - 'combine_consecutive_unsets' => true, - 'compact_nullable_typehint' => true, - 'concat_space' => ['spacing' => 'one'], - 'declare_equal_normalize' => ['space' => 'none'], - 'declare_strict_types' => true, - 'dir_constant' => true, - 'elseif' => true, - 'encoding' => true, - 'full_opening_tag' => true, - 'function_declaration' => true, - 'header_comment' => ['header' => $header, 'separate' => 'none'], - 'indentation_type' => true, - 'is_null' => true, - 'line_ending' => true, - 'list_syntax' => ['syntax' => 'short'], - 'logical_operators' => true, - 'lowercase_cast' => true, - 'lowercase_constants' => true, - 'lowercase_keywords' => true, - 'lowercase_static_reference' => true, - 'magic_constant_casing' => true, - 'method_argument_space' => ['ensure_fully_multiline' => true], - 'modernize_types_casting' => true, - 'multiline_comment_opening_closing' => true, - 'multiline_whitespace_before_semicolons' => true, - 'native_constant_invocation' => true, - 'native_function_casing' => true, - 'native_function_invocation' => true, - 'new_with_braces' => false, - 'no_alias_functions' => true, - 'no_alternative_syntax' => true, - 'no_blank_lines_after_class_opening' => true, - 'no_blank_lines_after_phpdoc' => true, - 'no_blank_lines_before_namespace' => true, - 'no_closing_tag' => true, - 'no_empty_comment' => true, - 'no_empty_phpdoc' => true, - 'no_empty_statement' => true, - 'no_extra_blank_lines' => true, - 'no_homoglyph_names' => true, - 'no_leading_import_slash' => true, - 'no_leading_namespace_whitespace' => true, - 'no_mixed_echo_print' => ['use' => 'print'], - 'no_multiline_whitespace_around_double_arrow' => true, - 'no_null_property_initialization' => true, - 'no_php4_constructor' => true, - 'no_short_bool_cast' => true, - 'no_short_echo_tag' => true, - 'no_singleline_whitespace_before_semicolons' => true, - 'no_spaces_after_function_name' => true, - 'no_spaces_inside_parenthesis' => true, - 'no_superfluous_elseif' => true, - 'no_superfluous_phpdoc_tags' => true, - 'no_trailing_comma_in_list_call' => true, - 'no_trailing_comma_in_singleline_array' => true, - 'no_trailing_whitespace' => true, - 'no_trailing_whitespace_in_comment' => true, - 'no_unneeded_control_parentheses' => true, - 'no_unneeded_curly_braces' => true, - 'no_unneeded_final_method' => true, - 'no_unreachable_default_argument_value' => true, - 'no_unset_on_property' => true, - 'no_unused_imports' => true, - 'no_useless_else' => true, - 'no_useless_return' => true, - 'no_whitespace_before_comma_in_array' => true, - 'no_whitespace_in_blank_line' => true, - 'non_printable_character' => true, - 'normalize_index_brace' => true, - 'object_operator_without_whitespace' => true, - 'ordered_class_elements' => [ - 'order' => [ - 'use_trait', - 'constant_public', - 'constant_protected', - 'constant_private', - 'property_public_static', - 'property_protected_static', - 'property_private_static', - 'property_public', - 'property_protected', - 'property_private', - 'method_public_static', - 'construct', - 'destruct', - 'magic', - 'phpunit', - 'method_public', - 'method_protected', - 'method_private', - 'method_protected_static', - 'method_private_static', - ], - ], - 'ordered_imports' => true, - 'ordered_interfaces' => [ - 'direction' => 'ascend', - 'order' => 'alpha', - ], - 'phpdoc_add_missing_param_annotation' => true, - 'phpdoc_align' => true, - 'phpdoc_annotation_without_dot' => true, - 'phpdoc_indent' => true, - 'phpdoc_no_access' => true, - 'phpdoc_no_empty_return' => true, - 'phpdoc_no_package' => true, - 'phpdoc_order' => true, - 'phpdoc_return_self_reference' => true, - 'phpdoc_scalar' => true, - 'phpdoc_separation' => true, - 'phpdoc_single_line_var_spacing' => true, - 'phpdoc_to_comment' => true, - 'phpdoc_trim' => true, - 'phpdoc_trim_consecutive_blank_line_separation' => true, - 'phpdoc_types' => ['groups' => ['simple', 'meta']], - 'phpdoc_types_order' => true, - 'phpdoc_var_without_name' => true, - 'pow_to_exponentiation' => true, - 'protected_to_private' => true, - 'return_assignment' => true, - 'return_type_declaration' => ['space_before' => 'none'], - 'semicolon_after_instruction' => true, - 'set_type_to_cast' => true, - 'short_scalar_cast' => true, - 'simplified_null_return' => true, - 'single_blank_line_at_eof' => true, - 'single_import_per_statement' => true, - 'single_line_after_imports' => true, - 'single_quote' => true, - 'standardize_not_equals' => true, - 'ternary_to_null_coalescing' => true, - 'trailing_comma_in_multiline_array' => true, - 'trim_array_spaces' => true, - 'unary_operator_spaces' => true, - 'visibility_required' => [ - 'elements' => [ - 'const', - 'method', - 'property', - ], - ], - 'void_return' => true, - 'whitespace_after_comma_in_array' => true, - ] - ) - ->setFinder( - PhpCsFixer\Finder::create() - ->files() - ->in(__DIR__ . '/src') - ->in(__DIR__ . '/tests') - ); diff --git a/vendor/sebastian/type/.travis.yml b/vendor/sebastian/type/.travis.yml deleted file mode 100644 index 961341b36..000000000 --- a/vendor/sebastian/type/.travis.yml +++ /dev/null @@ -1,53 +0,0 @@ -language: php - -php: - - 7.2 - - 7.3 - - 7.4snapshot - - nightly - -matrix: - allow_failures: - - php: master - fast_finish: true - -env: - matrix: - - DEPENDENCIES="high" - - DEPENDENCIES="low" - global: - - DEFAULT_COMPOSER_FLAGS="--no-interaction --no-ansi --no-progress --no-suggest" - -before_install: - - ./tools/composer clear-cache - -install: - - if [[ "$DEPENDENCIES" = 'high' ]]; then travis_retry ./tools/composer update $DEFAULT_COMPOSER_FLAGS; fi - - if [[ "$DEPENDENCIES" = 'low' ]]; then travis_retry ./tools/composer update $DEFAULT_COMPOSER_FLAGS --prefer-lowest; fi - -script: - - ./vendor/bin/phpunit --coverage-clover=coverage.xml - -after_success: - - bash <(curl -s https://codecov.io/bash) - -notifications: - email: false - -jobs: - include: - - stage: "Static Code Analysis" - php: 7.3 - env: php-cs-fixer - install: - - phpenv config-rm xdebug.ini - script: - - ./tools/php-cs-fixer fix --dry-run -v --show-progress=dots --diff-format=udiff - - stage: "Static Code Analysis" - php: 7.3 - env: psalm - install: - - phpenv config-rm xdebug.ini - script: - - travis_retry ./tools/composer update $DEFAULT_COMPOSER_FLAGS - - ./tools/psalm --shepherd --stats diff --git a/vendor/sebastian/type/ChangeLog.md b/vendor/sebastian/type/ChangeLog.md index 3618db10f..a8aff5534 100644 --- a/vendor/sebastian/type/ChangeLog.md +++ b/vendor/sebastian/type/ChangeLog.md @@ -2,17 +2,69 @@ All notable changes are documented in this file using the [Keep a CHANGELOG](http://keepachangelog.com/) principles. -## [1.1.4] - 2020-11-30 +## [2.3.1] - 2020-10-26 + +### Fixed + +* `SebastianBergmann\Type\Exception` now correctly extends `\Throwable` + +## [2.3.0] - 2020-10-06 + +### Added + +* [#14](https://github.com/sebastianbergmann/type/issues/14): Support for `static` return type that is introduced in PHP 8 + +## [2.2.2] - 2020-09-28 ### Changed -* Changed PHP version constraint in `composer.json` from `^7.2` to `>=7.2` +* Changed PHP version constraint in `composer.json` from `^7.3 || ^8.0` to `>=7.3` + +## [2.2.1] - 2020-07-05 + +### Fixed + +* Fixed handling of `mixed` type in `ReflectionMapper::fromMethodReturnType()` + +## [2.2.0] - 2020-07-05 + +### Added + +* Added `MixedType` object for representing PHP 8's `mixed` type + +## [2.1.1] - 2020-06-26 + +### Added + +* This component is now supported on PHP 8 + +## [2.1.0] - 2020-06-01 + +### Added + +* Added `UnionType` object for representing PHP 8's Union Types +* Added `ReflectionMapper::fromMethodReturnType()` for mapping `\ReflectionMethod::getReturnType()` to a `Type` object +* Added `Type::name()` for retrieving the name of a type +* Added `Type::asString()` for retrieving a textual representation of a type + +### Changed + +* Deprecated `Type::getReturnTypeDeclaration()` (use `Type::asString()` instead and prefix its result with `': '`) +* Deprecated `TypeName::getNamespaceName()` (use `TypeName::namespaceName()` instead) +* Deprecated `TypeName::getSimpleName()` (use `TypeName::simpleName()` instead) +* Deprecated `TypeName::getQualifiedName()` (use `TypeName::qualifiedName()` instead) + +## [2.0.0] - 2020-02-07 + +### Removed + +* This component is no longer supported on PHP 7.2 ## [1.1.3] - 2019-07-02 ### Fixed -* Fixed class name comparison in `ObjectType` to be case insensitive +* Fixed class name comparison in `ObjectType` to be case-insensitive ## [1.1.2] - 2019-06-19 @@ -37,7 +89,14 @@ All notable changes are documented in this file using the [Keep a CHANGELOG](htt * Initial release based on [code contributed by Michel Hartmann to PHPUnit](https://github.com/sebastianbergmann/phpunit/pull/3673) -[1.1.4]: https://github.com/sebastianbergmann/type/compare/1.1.3...1.1.4 +[2.3.1]: https://github.com/sebastianbergmann/type/compare/2.3.0...2.3.1 +[2.3.0]: https://github.com/sebastianbergmann/type/compare/2.2.2...2.3.0 +[2.2.2]: https://github.com/sebastianbergmann/type/compare/2.2.1...2.2.2 +[2.2.1]: https://github.com/sebastianbergmann/type/compare/2.2.0...2.2.1 +[2.2.0]: https://github.com/sebastianbergmann/type/compare/2.1.1...2.2.0 +[2.1.1]: https://github.com/sebastianbergmann/type/compare/2.1.0...2.1.1 +[2.1.0]: https://github.com/sebastianbergmann/type/compare/2.0.0...2.1.0 +[2.0.0]: https://github.com/sebastianbergmann/type/compare/1.1.3...2.0.0 [1.1.3]: https://github.com/sebastianbergmann/type/compare/1.1.2...1.1.3 [1.1.2]: https://github.com/sebastianbergmann/type/compare/1.1.1...1.1.2 [1.1.1]: https://github.com/sebastianbergmann/type/compare/1.1.0...1.1.1 diff --git a/vendor/sebastian/type/LICENSE b/vendor/sebastian/type/LICENSE index c58cd4ef1..b840591a9 100644 --- a/vendor/sebastian/type/LICENSE +++ b/vendor/sebastian/type/LICENSE @@ -1,6 +1,6 @@ sebastian/type -Copyright (c) 2019, Sebastian Bergmann . +Copyright (c) 2019-2020, Sebastian Bergmann . All rights reserved. Redistribution and use in source and binary forms, with or without diff --git a/vendor/sebastian/type/README.md b/vendor/sebastian/type/README.md index c7c8da64e..1036ce7a7 100644 --- a/vendor/sebastian/type/README.md +++ b/vendor/sebastian/type/README.md @@ -1,5 +1,8 @@ # sebastian/type +[![CI Status](https://github.com/sebastianbergmann/type/workflows/CI/badge.svg)](https://github.com/sebastianbergmann/type/actions) +[![Type Coverage](https://shepherd.dev/github/sebastianbergmann/type/coverage.svg)](https://shepherd.dev/github/sebastianbergmann/type) + Collection of value objects that represent the types of the PHP type system. ## Installation diff --git a/vendor/sebastian/type/build.xml b/vendor/sebastian/type/build.xml deleted file mode 100644 index d08143050..000000000 --- a/vendor/sebastian/type/build.xml +++ /dev/null @@ -1,31 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/vendor/sebastian/type/composer.json b/vendor/sebastian/type/composer.json index 5a2d6222b..b02d8e92a 100644 --- a/vendor/sebastian/type/composer.json +++ b/vendor/sebastian/type/composer.json @@ -16,14 +16,14 @@ }, "prefer-stable": true, "require": { - "php": ">=7.2" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^8.2" + "phpunit/phpunit": "^9.3" }, "config": { "platform": { - "php": "7.2.0" + "php": "7.3.0" }, "optimize-autoloader": true, "sort-packages": true @@ -43,7 +43,7 @@ }, "extra": { "branch-alias": { - "dev-master": "1.1-dev" + "dev-master": "2.3-dev" } } } diff --git a/vendor/sebastian/type/phive.xml b/vendor/sebastian/type/phive.xml deleted file mode 100644 index 8c97a1546..000000000 --- a/vendor/sebastian/type/phive.xml +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/vendor/sebastian/type/phpunit.xml b/vendor/sebastian/type/phpunit.xml deleted file mode 100644 index 0007cf7ea..000000000 --- a/vendor/sebastian/type/phpunit.xml +++ /dev/null @@ -1,23 +0,0 @@ - - - - - tests/unit - - - - - - src - - - diff --git a/vendor/sebastian/type/psalm.xml b/vendor/sebastian/type/psalm.xml deleted file mode 100644 index c94bb67e7..000000000 --- a/vendor/sebastian/type/psalm.xml +++ /dev/null @@ -1,53 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/vendor/sebastian/type/src/CallableType.php b/vendor/sebastian/type/src/CallableType.php index 28b5df8c9..026762eaf 100644 --- a/vendor/sebastian/type/src/CallableType.php +++ b/vendor/sebastian/type/src/CallableType.php @@ -9,6 +9,20 @@ */ namespace SebastianBergmann\Type; +use function assert; +use function class_exists; +use function count; +use function explode; +use function function_exists; +use function is_array; +use function is_object; +use function is_string; +use function strpos; +use Closure; +use ReflectionClass; +use ReflectionException; +use ReflectionObject; + final class CallableType extends Type { /** @@ -61,9 +75,9 @@ final class CallableType extends Type return false; } - public function getReturnTypeDeclaration(): string + public function name(): string { - return ': ' . ($this->allowsNull ? '?' : '') . 'callable'; + return 'callable'; } public function allowsNull(): bool @@ -73,7 +87,7 @@ final class CallableType extends Type private function isClosure(ObjectType $type): bool { - return !$type->className()->isNamespaced() && $type->className()->getSimpleName() === \Closure::class; + return !$type->className()->isNamespaced() && $type->className()->simpleName() === Closure::class; } /** @@ -81,10 +95,13 @@ final class CallableType extends Type */ private function hasInvokeMethod(ObjectType $type): bool { + $className = $type->className()->qualifiedName(); + assert(class_exists($className)); + try { - $class = new \ReflectionClass($type->className()->getQualifiedName()); + $class = new ReflectionClass($className); // @codeCoverageIgnoreStart - } catch (\ReflectionException $e) { + } catch (ReflectionException $e) { throw new RuntimeException( $e->getMessage(), (int) $e->getCode(), @@ -102,65 +119,63 @@ final class CallableType extends Type private function isFunction(SimpleType $type): bool { - if (!\is_string($type->value())) { + if (!is_string($type->value())) { return false; } - return \function_exists($type->value()); + return function_exists($type->value()); } private function isObjectCallback(SimpleType $type): bool { - if (!\is_array($type->value())) { + if (!is_array($type->value())) { return false; } - if (\count($type->value()) !== 2) { + if (count($type->value()) !== 2) { return false; } - if (!\is_object($type->value()[0]) || !\is_string($type->value()[1])) { + if (!is_object($type->value()[0]) || !is_string($type->value()[1])) { return false; } [$object, $methodName] = $type->value(); - $reflector = new \ReflectionObject($object); - - return $reflector->hasMethod($methodName); + return (new ReflectionObject($object))->hasMethod($methodName); } private function isClassCallback(SimpleType $type): bool { - if (!\is_string($type->value()) && !\is_array($type->value())) { + if (!is_string($type->value()) && !is_array($type->value())) { return false; } - if (\is_string($type->value())) { - if (\strpos($type->value(), '::') === false) { + if (is_string($type->value())) { + if (strpos($type->value(), '::') === false) { return false; } - [$className, $methodName] = \explode('::', $type->value()); + [$className, $methodName] = explode('::', $type->value()); } - if (\is_array($type->value())) { - if (\count($type->value()) !== 2) { + if (is_array($type->value())) { + if (count($type->value()) !== 2) { return false; } - if (!\is_string($type->value()[0]) || !\is_string($type->value()[1])) { + if (!is_string($type->value()[0]) || !is_string($type->value()[1])) { return false; } [$className, $methodName] = $type->value(); } - \assert(isset($className) && \is_string($className)); - \assert(isset($methodName) && \is_string($methodName)); + assert(isset($className) && is_string($className) && class_exists($className)); + assert(isset($methodName) && is_string($methodName)); try { - $class = new \ReflectionClass($className); + $class = new ReflectionClass($className); if ($class->hasMethod($methodName)) { $method = $class->getMethod($methodName); @@ -168,7 +183,7 @@ final class CallableType extends Type return $method->isPublic() && $method->isStatic(); } // @codeCoverageIgnoreStart - } catch (\ReflectionException $e) { + } catch (ReflectionException $e) { throw new RuntimeException( $e->getMessage(), (int) $e->getCode(), diff --git a/vendor/sebastian/type/src/GenericObjectType.php b/vendor/sebastian/type/src/GenericObjectType.php index 7e0a6d2b9..6871008bd 100644 --- a/vendor/sebastian/type/src/GenericObjectType.php +++ b/vendor/sebastian/type/src/GenericObjectType.php @@ -34,9 +34,9 @@ final class GenericObjectType extends Type return true; } - public function getReturnTypeDeclaration(): string + public function name(): string { - return ': ' . ($this->allowsNull ? '?' : '') . 'object'; + return 'object'; } public function allowsNull(): bool diff --git a/vendor/sebastian/type/src/IterableType.php b/vendor/sebastian/type/src/IterableType.php index 49830d3e1..c5bc6627b 100644 --- a/vendor/sebastian/type/src/IterableType.php +++ b/vendor/sebastian/type/src/IterableType.php @@ -9,6 +9,12 @@ */ namespace SebastianBergmann\Type; +use function assert; +use function class_exists; +use function is_iterable; +use ReflectionClass; +use ReflectionException; + final class IterableType extends Type { /** @@ -35,14 +41,17 @@ final class IterableType extends Type } if ($other instanceof SimpleType) { - return \is_iterable($other->value()); + return is_iterable($other->value()); } if ($other instanceof ObjectType) { + $className = $other->className()->qualifiedName(); + assert(class_exists($className)); + try { - return (new \ReflectionClass($other->className()->getQualifiedName()))->isIterable(); + return (new ReflectionClass($className))->isIterable(); // @codeCoverageIgnoreStart - } catch (\ReflectionException $e) { + } catch (ReflectionException $e) { throw new RuntimeException( $e->getMessage(), (int) $e->getCode(), @@ -55,9 +64,9 @@ final class IterableType extends Type return false; } - public function getReturnTypeDeclaration(): string + public function name(): string { - return ': ' . ($this->allowsNull ? '?' : '') . 'iterable'; + return 'iterable'; } public function allowsNull(): bool diff --git a/vendor/sebastian/type/src/MixedType.php b/vendor/sebastian/type/src/MixedType.php new file mode 100644 index 000000000..7ad9191da --- /dev/null +++ b/vendor/sebastian/type/src/MixedType.php @@ -0,0 +1,33 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\Type; + +final class MixedType extends Type +{ + public function isAssignable(Type $other): bool + { + return !$other instanceof VoidType; + } + + public function asString(): string + { + return 'mixed'; + } + + public function name(): string + { + return 'mixed'; + } + + public function allowsNull(): bool + { + return true; + } +} diff --git a/vendor/sebastian/type/src/NullType.php b/vendor/sebastian/type/src/NullType.php index 0efe10764..8481fceb8 100644 --- a/vendor/sebastian/type/src/NullType.php +++ b/vendor/sebastian/type/src/NullType.php @@ -16,6 +16,21 @@ final class NullType extends Type return !($other instanceof VoidType); } + public function name(): string + { + return 'null'; + } + + public function asString(): string + { + return 'null'; + } + + /** + * @deprecated + * + * @codeCoverageIgnore + */ public function getReturnTypeDeclaration(): string { return ''; diff --git a/vendor/sebastian/type/src/ObjectType.php b/vendor/sebastian/type/src/ObjectType.php index 9a8d99e0d..c71273cb4 100644 --- a/vendor/sebastian/type/src/ObjectType.php +++ b/vendor/sebastian/type/src/ObjectType.php @@ -9,6 +9,9 @@ */ namespace SebastianBergmann\Type; +use function is_subclass_of; +use function strcasecmp; + final class ObjectType extends Type { /** @@ -34,11 +37,11 @@ final class ObjectType extends Type } if ($other instanceof self) { - if (0 === \strcasecmp($this->className->getQualifiedName(), $other->className->getQualifiedName())) { + if (0 === strcasecmp($this->className->qualifiedName(), $other->className->qualifiedName())) { return true; } - if (\is_subclass_of($other->className->getQualifiedName(), $this->className->getQualifiedName(), true)) { + if (is_subclass_of($other->className->qualifiedName(), $this->className->qualifiedName(), true)) { return true; } } @@ -46,9 +49,9 @@ final class ObjectType extends Type return false; } - public function getReturnTypeDeclaration(): string + public function name(): string { - return ': ' . ($this->allowsNull ? '?' : '') . $this->className->getQualifiedName(); + return $this->className->qualifiedName(); } public function allowsNull(): bool diff --git a/vendor/sebastian/type/src/ReflectionMapper.php b/vendor/sebastian/type/src/ReflectionMapper.php new file mode 100644 index 000000000..c3dc9b9a4 --- /dev/null +++ b/vendor/sebastian/type/src/ReflectionMapper.php @@ -0,0 +1,96 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\Type; + +use function assert; +use function sprintf; +use ReflectionMethod; +use ReflectionNamedType; +use ReflectionUnionType; + +final class ReflectionMapper +{ + public function fromMethodReturnType(ReflectionMethod $method): Type + { + if (!$method->hasReturnType()) { + return new UnknownType; + } + + $returnType = $method->getReturnType(); + + assert($returnType instanceof ReflectionNamedType || $returnType instanceof ReflectionUnionType); + + if ($returnType instanceof ReflectionNamedType) { + if ($returnType->getName() === 'self') { + return ObjectType::fromName( + $method->getDeclaringClass()->getName(), + $returnType->allowsNull() + ); + } + + if ($returnType->getName() === 'static') { + return new StaticType( + TypeName::fromReflection($method->getDeclaringClass()), + $returnType->allowsNull() + ); + } + + if ($returnType->getName() === 'mixed') { + return new MixedType; + } + + if ($returnType->getName() === 'parent') { + $parentClass = $method->getDeclaringClass()->getParentClass(); + + // @codeCoverageIgnoreStart + if ($parentClass === false) { + throw new RuntimeException( + sprintf( + '%s::%s() has a "parent" return type declaration but %s does not have a parent class', + $method->getDeclaringClass()->getName(), + $method->getName(), + $method->getDeclaringClass()->getName() + ) + ); + } + // @codeCoverageIgnoreEnd + + return ObjectType::fromName( + $parentClass->getName(), + $returnType->allowsNull() + ); + } + + return Type::fromName( + $returnType->getName(), + $returnType->allowsNull() + ); + } + + assert($returnType instanceof ReflectionUnionType); + + $types = []; + + foreach ($returnType->getTypes() as $type) { + assert($type instanceof ReflectionNamedType); + + if ($type->getName() === 'self') { + $types[] = ObjectType::fromName( + $method->getDeclaringClass()->getName(), + false + ); + } else { + $types[] = Type::fromName($type->getName(), false); + } + } + + return new UnionType(...$types); + } +} diff --git a/vendor/sebastian/type/src/SimpleType.php b/vendor/sebastian/type/src/SimpleType.php index 07662b8f4..dbb4f0c4e 100644 --- a/vendor/sebastian/type/src/SimpleType.php +++ b/vendor/sebastian/type/src/SimpleType.php @@ -9,6 +9,8 @@ */ namespace SebastianBergmann\Type; +use function strtolower; + final class SimpleType extends Type { /** @@ -46,9 +48,9 @@ final class SimpleType extends Type return false; } - public function getReturnTypeDeclaration(): string + public function name(): string { - return ': ' . ($this->allowsNull ? '?' : '') . $this->name; + return $this->name; } public function allowsNull(): bool @@ -63,7 +65,7 @@ final class SimpleType extends Type private function normalize(string $name): string { - $name = \strtolower($name); + $name = strtolower($name); switch ($name) { case 'boolean': diff --git a/vendor/sebastian/type/src/StaticType.php b/vendor/sebastian/type/src/StaticType.php new file mode 100644 index 000000000..6833094d1 --- /dev/null +++ b/vendor/sebastian/type/src/StaticType.php @@ -0,0 +1,60 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\Type; + +final class StaticType extends Type +{ + /** + * @var TypeName + */ + private $className; + + /** + * @var bool + */ + private $allowsNull; + + public function __construct(TypeName $className, bool $allowsNull) + { + $this->className = $className; + $this->allowsNull = $allowsNull; + } + + public function isAssignable(Type $other): bool + { + if ($this->allowsNull && $other instanceof NullType) { + return true; + } + + if (!$other instanceof ObjectType) { + return false; + } + + if (0 === strcasecmp($this->className->qualifiedName(), $other->className()->qualifiedName())) { + return true; + } + + if (is_subclass_of($other->className()->qualifiedName(), $this->className->qualifiedName(), true)) { + return true; + } + + return false; + } + + public function name(): string + { + return 'static'; + } + + public function allowsNull(): bool + { + return $this->allowsNull; + } +} diff --git a/vendor/sebastian/type/src/Type.php b/vendor/sebastian/type/src/Type.php index df7dce680..cf64923b4 100644 --- a/vendor/sebastian/type/src/Type.php +++ b/vendor/sebastian/type/src/Type.php @@ -9,14 +9,18 @@ */ namespace SebastianBergmann\Type; +use function get_class; +use function gettype; +use function strtolower; + abstract class Type { public static function fromValue($value, bool $allowsNull): self { - $typeName = \gettype($value); + $typeName = gettype($value); if ($typeName === 'object') { - return new ObjectType(TypeName::fromQualifiedName(\get_class($value)), $allowsNull); + return new ObjectType(TypeName::fromQualifiedName(get_class($value)), $allowsNull); } $type = self::fromName($typeName, $allowsNull); @@ -30,7 +34,7 @@ abstract class Type public static function fromName(string $typeName, bool $allowsNull): self { - switch (\strtolower($typeName)) { + switch (strtolower($typeName)) { case 'callable': return new CallableType($allowsNull); @@ -67,9 +71,24 @@ abstract class Type } } + public function asString(): string + { + return ($this->allowsNull() ? '?' : '') . $this->name(); + } + + /** + * @deprecated + * + * @codeCoverageIgnore + */ + public function getReturnTypeDeclaration(): string + { + return ': ' . $this->asString(); + } + abstract public function isAssignable(Type $other): bool; - abstract public function getReturnTypeDeclaration(): string; + abstract public function name(): string; abstract public function allowsNull(): bool; } diff --git a/vendor/sebastian/type/src/TypeName.php b/vendor/sebastian/type/src/TypeName.php index fbbe36e34..b076e89e0 100644 --- a/vendor/sebastian/type/src/TypeName.php +++ b/vendor/sebastian/type/src/TypeName.php @@ -9,6 +9,12 @@ */ namespace SebastianBergmann\Type; +use function array_pop; +use function explode; +use function implode; +use function substr; +use ReflectionClass; + final class TypeName { /** @@ -24,18 +30,18 @@ final class TypeName public static function fromQualifiedName(string $fullClassName): self { if ($fullClassName[0] === '\\') { - $fullClassName = \substr($fullClassName, 1); + $fullClassName = substr($fullClassName, 1); } - $classNameParts = \explode('\\', $fullClassName); + $classNameParts = explode('\\', $fullClassName); - $simpleName = \array_pop($classNameParts); - $namespaceName = \implode('\\', $classNameParts); + $simpleName = array_pop($classNameParts); + $namespaceName = implode('\\', $classNameParts); return new self($namespaceName, $simpleName); } - public static function fromReflection(\ReflectionClass $type): self + public static function fromReflection(ReflectionClass $type): self { return new self( $type->getNamespaceName(), @@ -53,23 +59,53 @@ final class TypeName $this->simpleName = $simpleName; } - public function getNamespaceName(): ?string + public function namespaceName(): ?string { return $this->namespaceName; } - public function getSimpleName(): string + public function simpleName(): string { return $this->simpleName; } - public function getQualifiedName(): string + public function qualifiedName(): string { return $this->namespaceName === null ? $this->simpleName : $this->namespaceName . '\\' . $this->simpleName; } + /** + * @deprecated Use namespaceName() instead + * + * @codeCoverageIgnore + */ + public function getNamespaceName(): ?string + { + return $this->namespaceName(); + } + + /** + * @deprecated Use simpleName() instead + * + * @codeCoverageIgnore + */ + public function getSimpleName(): string + { + return $this->simpleName(); + } + + /** + * @deprecated Use qualifiedName() instead + * + * @codeCoverageIgnore + */ + public function getQualifiedName(): string + { + return $this->qualifiedName(); + } + public function isNamespaced(): bool { return $this->namespaceName !== null; diff --git a/vendor/sebastian/type/src/UnionType.php b/vendor/sebastian/type/src/UnionType.php new file mode 100644 index 000000000..10c4a49b5 --- /dev/null +++ b/vendor/sebastian/type/src/UnionType.php @@ -0,0 +1,115 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace SebastianBergmann\Type; + +use function count; +use function implode; +use function sort; + +final class UnionType extends Type +{ + /** + * @psalm-var list + */ + private $types; + + /** + * @throws RuntimeException + */ + public function __construct(Type ...$types) + { + $this->ensureMinimumOfTwoTypes(...$types); + $this->ensureOnlyValidTypes(...$types); + + $this->types = $types; + } + + public function isAssignable(Type $other): bool + { + foreach ($this->types as $type) { + if ($type->isAssignable($other)) { + return true; + } + } + + return false; + } + + public function asString(): string + { + return $this->name(); + } + + /** + * @deprecated + * + * @codeCoverageIgnore + */ + public function getReturnTypeDeclaration(): string + { + return ': ' . $this->name(); + } + + public function name(): string + { + $types = []; + + foreach ($this->types as $type) { + $types[] = $type->name(); + } + + sort($types); + + return implode('|', $types); + } + + public function allowsNull(): bool + { + foreach ($this->types as $type) { + if ($type instanceof NullType) { + return true; + } + } + + return false; + } + + /** + * @throws RuntimeException + */ + private function ensureMinimumOfTwoTypes(Type ...$types): void + { + if (count($types) < 2) { + throw new RuntimeException( + 'A union type must be composed of at least two types' + ); + } + } + + /** + * @throws RuntimeException + */ + private function ensureOnlyValidTypes(Type ...$types): void + { + foreach ($types as $type) { + if ($type instanceof UnknownType) { + throw new RuntimeException( + 'A union type must not be composed of an unknown type' + ); + } + + if ($type instanceof VoidType) { + throw new RuntimeException( + 'A union type must not be composed of a void type' + ); + } + } + } +} diff --git a/vendor/sebastian/type/src/UnknownType.php b/vendor/sebastian/type/src/UnknownType.php index 859f01de4..dde4c6788 100644 --- a/vendor/sebastian/type/src/UnknownType.php +++ b/vendor/sebastian/type/src/UnknownType.php @@ -16,6 +16,21 @@ final class UnknownType extends Type return true; } + public function name(): string + { + return 'unknown type'; + } + + public function asString(): string + { + return ''; + } + + /** + * @deprecated + * + * @codeCoverageIgnore + */ public function getReturnTypeDeclaration(): string { return ''; diff --git a/vendor/sebastian/type/src/VoidType.php b/vendor/sebastian/type/src/VoidType.php index f6fabaadc..18c017564 100644 --- a/vendor/sebastian/type/src/VoidType.php +++ b/vendor/sebastian/type/src/VoidType.php @@ -16,9 +16,9 @@ final class VoidType extends Type return $other instanceof self; } - public function getReturnTypeDeclaration(): string + public function name(): string { - return ': void'; + return 'void'; } public function allowsNull(): bool diff --git a/vendor/sebastian/type/src/exception/Exception.php b/vendor/sebastian/type/src/exception/Exception.php index 9f0de24de..e0e7ee579 100644 --- a/vendor/sebastian/type/src/exception/Exception.php +++ b/vendor/sebastian/type/src/exception/Exception.php @@ -9,6 +9,8 @@ */ namespace SebastianBergmann\Type; -interface Exception +use Throwable; + +interface Exception extends Throwable { } diff --git a/vendor/sebastian/type/tests/_fixture/ChildClass.php b/vendor/sebastian/type/tests/_fixture/ChildClass.php deleted file mode 100644 index 41e424549..000000000 --- a/vendor/sebastian/type/tests/_fixture/ChildClass.php +++ /dev/null @@ -1,14 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Type\TestFixture; - -class ChildClass extends ParentClass -{ -} diff --git a/vendor/sebastian/type/tests/_fixture/ClassWithCallbackMethods.php b/vendor/sebastian/type/tests/_fixture/ClassWithCallbackMethods.php deleted file mode 100644 index 46137b464..000000000 --- a/vendor/sebastian/type/tests/_fixture/ClassWithCallbackMethods.php +++ /dev/null @@ -1,21 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Type\TestFixture; - -final class ClassWithCallbackMethods -{ - public static function staticCallback(): void - { - } - - public function nonStaticCallback(): void - { - } -} diff --git a/vendor/sebastian/type/tests/_fixture/ClassWithInvokeMethod.php b/vendor/sebastian/type/tests/_fixture/ClassWithInvokeMethod.php deleted file mode 100644 index 1765570b1..000000000 --- a/vendor/sebastian/type/tests/_fixture/ClassWithInvokeMethod.php +++ /dev/null @@ -1,17 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Type\TestFixture; - -final class ClassWithInvokeMethod -{ - public function __invoke(): void - { - } -} diff --git a/vendor/sebastian/type/tests/_fixture/Iterator.php b/vendor/sebastian/type/tests/_fixture/Iterator.php deleted file mode 100644 index e234dbe85..000000000 --- a/vendor/sebastian/type/tests/_fixture/Iterator.php +++ /dev/null @@ -1,33 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Type\TestFixture; - -final class Iterator implements \Iterator -{ - public function current(): void - { - } - - public function next(): void - { - } - - public function key(): void - { - } - - public function valid(): void - { - } - - public function rewind(): void - { - } -} diff --git a/vendor/sebastian/type/tests/_fixture/ParentClass.php b/vendor/sebastian/type/tests/_fixture/ParentClass.php deleted file mode 100644 index 4c28a5ea4..000000000 --- a/vendor/sebastian/type/tests/_fixture/ParentClass.php +++ /dev/null @@ -1,17 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Type\TestFixture; - -class ParentClass -{ - public function foo(): void - { - } -} diff --git a/vendor/sebastian/type/tests/_fixture/callback_function.php b/vendor/sebastian/type/tests/_fixture/callback_function.php deleted file mode 100644 index 8dc1807d2..000000000 --- a/vendor/sebastian/type/tests/_fixture/callback_function.php +++ /dev/null @@ -1,14 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Type\TestFixture; - -function callback_function(): void -{ -} diff --git a/vendor/sebastian/type/tests/unit/CallableTypeTest.php b/vendor/sebastian/type/tests/unit/CallableTypeTest.php deleted file mode 100644 index 126ceddd0..000000000 --- a/vendor/sebastian/type/tests/unit/CallableTypeTest.php +++ /dev/null @@ -1,150 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Type; - -use PHPUnit\Framework\TestCase; -use SebastianBergmann\Type\TestFixture\ClassWithCallbackMethods; -use SebastianBergmann\Type\TestFixture\ClassWithInvokeMethod; - -/** - * @covers \SebastianBergmann\Type\CallableType - * - * @uses \SebastianBergmann\Type\Type - * @uses \SebastianBergmann\Type\ObjectType - * @uses \SebastianBergmann\Type\SimpleType - * @uses \SebastianBergmann\Type\TypeName - */ -final class CallableTypeTest extends TestCase -{ - /** - * @var CallableType - */ - private $type; - - protected function setUp(): void - { - $this->type = new CallableType(false); - } - - public function testMayDisallowNull(): void - { - $this->assertFalse($this->type->allowsNull()); - } - - public function testCanGenerateReturnTypeDeclaration(): void - { - $this->assertEquals(': callable', $this->type->getReturnTypeDeclaration()); - } - - public function testMayAllowNull(): void - { - $type = new CallableType(true); - - $this->assertTrue($type->allowsNull()); - } - - public function testCanGenerateNullableReturnTypeDeclaration(): void - { - $type = new CallableType(true); - - $this->assertEquals(': ?callable', $type->getReturnTypeDeclaration()); - } - - public function testNullCanBeAssignedToNullableCallable(): void - { - $type = new CallableType(true); - - $this->assertTrue($type->isAssignable(new NullType)); - } - - public function testCallableCanBeAssignedToCallable(): void - { - $this->assertTrue($this->type->isAssignable(new CallableType(false))); - } - - public function testClosureCanBeAssignedToCallable(): void - { - $this->assertTrue( - $this->type->isAssignable( - new ObjectType( - TypeName::fromQualifiedName(\Closure::class), - false - ) - ) - ); - } - - public function testInvokableCanBeAssignedToCallable(): void - { - $this->assertTrue( - $this->type->isAssignable( - new ObjectType( - TypeName::fromQualifiedName(ClassWithInvokeMethod::class), - false - ) - ) - ); - } - - public function testStringWithFunctionNameCanBeAssignedToCallable(): void - { - $this->assertTrue( - $this->type->isAssignable( - Type::fromValue('SebastianBergmann\Type\TestFixture\callback_function', false) - ) - ); - } - - public function testStringWithClassNameAndStaticMethodNameCanBeAssignedToCallable(): void - { - $this->assertTrue( - $this->type->isAssignable( - Type::fromValue(ClassWithCallbackMethods::class . '::staticCallback', false) - ) - ); - } - - public function testArrayWithClassNameAndStaticMethodNameCanBeAssignedToCallable(): void - { - $this->assertTrue( - $this->type->isAssignable( - Type::fromValue([ClassWithCallbackMethods::class, 'staticCallback'], false) - ) - ); - } - - public function testArrayWithClassNameAndInstanceMethodNameCanBeAssignedToCallable(): void - { - $this->assertTrue( - $this->type->isAssignable( - Type::fromValue([new ClassWithCallbackMethods, 'nonStaticCallback'], false) - ) - ); - } - - public function testSomethingThatIsNotCallableCannotBeAssignedToCallable(): void - { - $this->assertFalse( - $this->type->isAssignable( - Type::fromValue(null, false) - ) - ); - } - - public function testObjectWithoutInvokeMethodCannotBeAssignedToCallable(): void - { - $this->assertFalse( - $this->type->isAssignable( - Type::fromValue(new class { - }, false) - ) - ); - } -} diff --git a/vendor/sebastian/type/tests/unit/GenericObjectTypeTest.php b/vendor/sebastian/type/tests/unit/GenericObjectTypeTest.php deleted file mode 100644 index 2017371d1..000000000 --- a/vendor/sebastian/type/tests/unit/GenericObjectTypeTest.php +++ /dev/null @@ -1,86 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Type; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\Type\GenericObjectType - * - * @uses \SebastianBergmann\Type\Type - * @uses \SebastianBergmann\Type\ObjectType - * @uses \SebastianBergmann\Type\SimpleType - * @uses \SebastianBergmann\Type\TypeName - */ -final class GenericObjectTypeTest extends TestCase -{ - /** - * @var GenericObjectType - */ - private $type; - - protected function setUp(): void - { - $this->type = new GenericObjectType(false); - } - - public function testMayDisallowNull(): void - { - $this->assertFalse($this->type->allowsNull()); - } - - public function testCanGenerateReturnTypeDeclaration(): void - { - $this->assertEquals(': object', $this->type->getReturnTypeDeclaration()); - } - - public function testMayAllowNull(): void - { - $type = new GenericObjectType(true); - - $this->assertTrue($type->allowsNull()); - } - - public function testCanGenerateNullableReturnTypeDeclaration(): void - { - $type = new GenericObjectType(true); - - $this->assertEquals(': ?object', $type->getReturnTypeDeclaration()); - } - - public function testObjectCanBeAssignedToGenericObject(): void - { - $this->assertTrue( - $this->type->isAssignable( - new ObjectType(TypeName::fromQualifiedName(\stdClass::class), false) - ) - ); - } - - public function testNullCanBeAssignedToNullableGenericObject(): void - { - $type = new GenericObjectType(true); - - $this->assertTrue( - $type->isAssignable( - new NullType - ) - ); - } - - public function testNonObjectCannotBeAssignedToGenericObject(): void - { - $this->assertFalse( - $this->type->isAssignable( - new SimpleType('bool', false) - ) - ); - } -} diff --git a/vendor/sebastian/type/tests/unit/IterableTypeTest.php b/vendor/sebastian/type/tests/unit/IterableTypeTest.php deleted file mode 100644 index 5493222f2..000000000 --- a/vendor/sebastian/type/tests/unit/IterableTypeTest.php +++ /dev/null @@ -1,97 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Type; - -use PHPUnit\Framework\TestCase; -use SebastianBergmann\Type\TestFixture\Iterator; - -/** - * @covers \SebastianBergmann\Type\IterableType - * - * @uses \SebastianBergmann\Type\Type - * @uses \SebastianBergmann\Type\TypeName - * @uses \SebastianBergmann\Type\ObjectType - * @uses \SebastianBergmann\Type\SimpleType - */ -final class IterableTypeTest extends TestCase -{ - /** - * @var IterableType - */ - private $type; - - protected function setUp(): void - { - $this->type = new IterableType(false); - } - - public function testMayDisallowNull(): void - { - $this->assertFalse($this->type->allowsNull()); - } - - public function testCanGenerateReturnTypeDeclaration(): void - { - $this->assertEquals(': iterable', $this->type->getReturnTypeDeclaration()); - } - - public function testMayAllowNull(): void - { - $type = new IterableType(true); - - $this->assertTrue($type->allowsNull()); - } - - public function testCanGenerateNullableReturnTypeDeclaration(): void - { - $type = new IterableType(true); - - $this->assertEquals(': ?iterable', $type->getReturnTypeDeclaration()); - } - - public function testNullCanBeAssignedToNullableIterable(): void - { - $type = new IterableType(true); - - $this->assertTrue($type->isAssignable(new NullType)); - } - - public function testIterableCanBeAssignedToIterable(): void - { - $this->assertTrue($this->type->isAssignable(new IterableType(false))); - } - - public function testArrayCanBeAssignedToIterable(): void - { - $this->assertTrue( - $this->type->isAssignable( - Type::fromValue([], false) - ) - ); - } - - public function testIteratorCanBeAssignedToIterable(): void - { - $this->assertTrue( - $this->type->isAssignable( - Type::fromValue(new Iterator, false) - ) - ); - } - - public function testSomethingThatIsNotIterableCannotBeAssignedToIterable(): void - { - $this->assertFalse( - $this->type->isAssignable( - Type::fromValue(null, false) - ) - ); - } -} diff --git a/vendor/sebastian/type/tests/unit/NullTypeTest.php b/vendor/sebastian/type/tests/unit/NullTypeTest.php deleted file mode 100644 index 7f4862eb3..000000000 --- a/vendor/sebastian/type/tests/unit/NullTypeTest.php +++ /dev/null @@ -1,72 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Type; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\Type\NullType - */ -final class NullTypeTest extends TestCase -{ - /** - * @var NullType - */ - private $type; - - protected function setUp(): void - { - $this->type = new NullType; - } - - /** - * @dataProvider assignableTypes - */ - public function testIsAssignable(Type $assignableType): void - { - $this->assertTrue($this->type->isAssignable($assignableType)); - } - - public function assignableTypes(): array - { - return [ - [new SimpleType('int', false)], - [new SimpleType('int', true)], - [new ObjectType(TypeName::fromQualifiedName(self::class), false)], - [new ObjectType(TypeName::fromQualifiedName(self::class), true)], - [new UnknownType], - ]; - } - - /** - * @dataProvider notAssignable - */ - public function testIsNotAssignable(Type $assignedType): void - { - $this->assertFalse($this->type->isAssignable($assignedType)); - } - - public function notAssignable(): array - { - return [ - 'void' => [new VoidType], - ]; - } - - public function testAllowsNull(): void - { - $this->assertTrue($this->type->allowsNull()); - } - - public function testCanGenerateReturnTypeDeclaration(): void - { - $this->assertEquals('', $this->type->getReturnTypeDeclaration()); - } -} diff --git a/vendor/sebastian/type/tests/unit/ObjectTypeTest.php b/vendor/sebastian/type/tests/unit/ObjectTypeTest.php deleted file mode 100644 index bbf64bb31..000000000 --- a/vendor/sebastian/type/tests/unit/ObjectTypeTest.php +++ /dev/null @@ -1,140 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Type; - -use PHPUnit\Framework\TestCase; -use SebastianBergmann\Type\TestFixture\ChildClass; -use SebastianBergmann\Type\TestFixture\ParentClass; - -/** - * @covers \SebastianBergmann\Type\ObjectType - * - * @uses \SebastianBergmann\Type\TypeName - * @uses \SebastianBergmann\Type\Type - * @uses \SebastianBergmann\Type\SimpleType - */ -final class ObjectTypeTest extends TestCase -{ - /** - * @var ObjectType - */ - private $childClass; - - /** - * @var ObjectType - */ - private $parentClass; - - protected function setUp(): void - { - $this->childClass = new ObjectType( - TypeName::fromQualifiedName(ChildClass::class), - false - ); - - $this->parentClass = new ObjectType( - TypeName::fromQualifiedName(ParentClass::class), - false - ); - } - - public function testParentIsNotAssignableToChild(): void - { - $this->assertFalse($this->childClass->isAssignable($this->parentClass)); - } - - public function testChildIsAssignableToParent(): void - { - $this->assertTrue($this->parentClass->isAssignable($this->childClass)); - } - - public function testClassIsAssignableToSelf(): void - { - $this->assertTrue($this->parentClass->isAssignable($this->parentClass)); - } - - public function testSimpleTypeIsNotAssignableToClass(): void - { - $this->assertFalse($this->parentClass->isAssignable(new SimpleType('int', false))); - } - - public function testClassFromOneNamespaceIsNotAssignableToClassInOtherNamespace(): void - { - $classFromNamespaceA = new ObjectType( - TypeName::fromQualifiedName(\someNamespaceA\NamespacedClass::class), - false - ); - - $classFromNamespaceB = new ObjectType( - TypeName::fromQualifiedName(\someNamespaceB\NamespacedClass::class), - false - ); - $this->assertFalse($classFromNamespaceA->isAssignable($classFromNamespaceB)); - } - - public function testClassIsAssignableToSelfCaseInsensitively(): void - { - $classLowercased = new ObjectType( - TypeName::fromQualifiedName(\strtolower(ParentClass::class)), - false - ); - - $this->assertTrue($this->parentClass->isAssignable($classLowercased)); - } - - public function testNullIsAssignableToNullableType(): void - { - $someClass = new ObjectType( - TypeName::fromQualifiedName(ParentClass::class), - true - ); - $this->assertTrue($someClass->isAssignable(Type::fromValue(null, true))); - } - - public function testNullIsNotAssignableToNotNullableType(): void - { - $someClass = new ObjectType( - TypeName::fromQualifiedName(ParentClass::class), - false - ); - - $this->assertFalse($someClass->isAssignable(Type::fromValue(null, true))); - } - - public function testPreservesNullNotAllowed(): void - { - $someClass = new ObjectType( - TypeName::fromQualifiedName(ParentClass::class), - false - ); - - $this->assertFalse($someClass->allowsNull()); - } - - public function testPreservesNullAllowed(): void - { - $someClass = new ObjectType( - TypeName::fromQualifiedName(ParentClass::class), - true - ); - - $this->assertTrue($someClass->allowsNull()); - } - - public function testCanGenerateReturnTypeDeclaration(): void - { - $this->assertEquals(': SebastianBergmann\Type\TestFixture\ParentClass', $this->parentClass->getReturnTypeDeclaration()); - } - - public function testHasClassName(): void - { - $this->assertEquals('SebastianBergmann\Type\TestFixture\ParentClass', $this->parentClass->className()->getQualifiedName()); - } -} diff --git a/vendor/sebastian/type/tests/unit/SimpleTypeTest.php b/vendor/sebastian/type/tests/unit/SimpleTypeTest.php deleted file mode 100644 index d795e8c28..000000000 --- a/vendor/sebastian/type/tests/unit/SimpleTypeTest.php +++ /dev/null @@ -1,162 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Type; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\Type\SimpleType - * - * @uses \SebastianBergmann\Type\Type - */ -final class SimpleTypeTest extends TestCase -{ - public function testCanBeBool(): void - { - $type = new SimpleType('bool', false); - - $this->assertSame(': bool', $type->getReturnTypeDeclaration()); - } - - public function testCanBeBoolean(): void - { - $type = new SimpleType('boolean', false); - - $this->assertSame(': bool', $type->getReturnTypeDeclaration()); - } - - public function testCanBeDouble(): void - { - $type = new SimpleType('double', false); - - $this->assertSame(': float', $type->getReturnTypeDeclaration()); - } - - public function testCanBeFloat(): void - { - $type = new SimpleType('float', false); - - $this->assertSame(': float', $type->getReturnTypeDeclaration()); - } - - public function testCanBeReal(): void - { - $type = new SimpleType('real', false); - - $this->assertSame(': float', $type->getReturnTypeDeclaration()); - } - - public function testCanBeInt(): void - { - $type = new SimpleType('int', false); - - $this->assertSame(': int', $type->getReturnTypeDeclaration()); - } - - public function testCanBeInteger(): void - { - $type = new SimpleType('integer', false); - - $this->assertSame(': int', $type->getReturnTypeDeclaration()); - } - - public function testCanBeArray(): void - { - $type = new SimpleType('array', false); - - $this->assertSame(': array', $type->getReturnTypeDeclaration()); - } - - public function testCanBeArray2(): void - { - $type = new SimpleType('[]', false); - - $this->assertSame(': array', $type->getReturnTypeDeclaration()); - } - - public function testMayAllowNull(): void - { - $type = new SimpleType('bool', true); - - $this->assertTrue($type->allowsNull()); - $this->assertSame(': ?bool', $type->getReturnTypeDeclaration()); - } - - public function testMayNotAllowNull(): void - { - $type = new SimpleType('bool', false); - - $this->assertFalse($type->allowsNull()); - } - - /** - * @dataProvider assignablePairs - */ - public function testIsAssignable(Type $assignTo, Type $assignedType): void - { - $this->assertTrue($assignTo->isAssignable($assignedType)); - } - - public function assignablePairs(): array - { - return [ - 'nullable to not nullable' => [new SimpleType('int', false), new SimpleType('int', true)], - 'not nullable to nullable' => [new SimpleType('int', true), new SimpleType('int', false)], - 'nullable to nullable' => [new SimpleType('int', true), new SimpleType('int', true)], - 'not nullable to not nullable' => [new SimpleType('int', false), new SimpleType('int', false)], - 'null to not nullable' => [new SimpleType('int', true), new NullType], - ]; - } - - /** - * @dataProvider notAssignablePairs - */ - public function testIsNotAssignable(Type $assignTo, Type $assignedType): void - { - $this->assertFalse($assignTo->isAssignable($assignedType)); - } - - public function notAssignablePairs(): array - { - return [ - 'null to not nullable' => [new SimpleType('int', false), new NullType], - 'int to boolean' => [new SimpleType('boolean', false), new SimpleType('int', false)], - 'object' => [new SimpleType('boolean', false), new ObjectType(TypeName::fromQualifiedName(\stdClass::class), true)], - 'unknown type' => [new SimpleType('boolean', false), new UnknownType], - 'void' => [new SimpleType('boolean', false), new VoidType], - ]; - } - - /** - * @dataProvider returnTypes - */ - public function testReturnTypeDeclaration(Type $type, string $returnType): void - { - $this->assertEquals($type->getReturnTypeDeclaration(), $returnType); - } - - public function returnTypes(): array - { - return [ - '[]' => [new SimpleType('[]', false), ': array'], - 'array' => [new SimpleType('array', false), ': array'], - '?array' => [new SimpleType('array', true), ': ?array'], - 'boolean' => [new SimpleType('boolean', false), ': bool'], - 'real' => [new SimpleType('real', false), ': float'], - 'double' => [new SimpleType('double', false), ': float'], - 'integer' => [new SimpleType('integer', false), ': int'], - ]; - } - - public function testCanHaveValue(): void - { - $this->assertSame('string', Type::fromValue('string', false)->value()); - } -} diff --git a/vendor/sebastian/type/tests/unit/TypeNameTest.php b/vendor/sebastian/type/tests/unit/TypeNameTest.php deleted file mode 100644 index 4e24a9ab9..000000000 --- a/vendor/sebastian/type/tests/unit/TypeNameTest.php +++ /dev/null @@ -1,59 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Type; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\Type\TypeName - */ -final class TypeNameTest extends TestCase -{ - public function testFromReflection(): void - { - $class = new \ReflectionClass(TypeName::class); - $typeName = TypeName::fromReflection($class); - - $this->assertTrue($typeName->isNamespaced()); - $this->assertEquals('SebastianBergmann\\Type', $typeName->getNamespaceName()); - $this->assertEquals(TypeName::class, $typeName->getQualifiedName()); - $this->assertEquals('TypeName', $typeName->getSimpleName()); - } - - public function testFromQualifiedName(): void - { - $typeName = TypeName::fromQualifiedName('PHPUnit\\Framework\\MockObject\\TypeName'); - - $this->assertTrue($typeName->isNamespaced()); - $this->assertEquals('PHPUnit\\Framework\\MockObject', $typeName->getNamespaceName()); - $this->assertEquals('PHPUnit\\Framework\\MockObject\\TypeName', $typeName->getQualifiedName()); - $this->assertEquals('TypeName', $typeName->getSimpleName()); - } - - public function testFromQualifiedNameWithLeadingSeparator(): void - { - $typeName = TypeName::fromQualifiedName('\\Foo\\Bar'); - - $this->assertTrue($typeName->isNamespaced()); - $this->assertEquals('Foo', $typeName->getNamespaceName()); - $this->assertEquals('Foo\\Bar', $typeName->getQualifiedName()); - $this->assertEquals('Bar', $typeName->getSimpleName()); - } - - public function testFromQualifiedNameWithoutNamespace(): void - { - $typeName = TypeName::fromQualifiedName('Bar'); - - $this->assertFalse($typeName->isNamespaced()); - $this->assertNull($typeName->getNamespaceName()); - $this->assertEquals('Bar', $typeName->getQualifiedName()); - $this->assertEquals('Bar', $typeName->getSimpleName()); - } -} diff --git a/vendor/sebastian/type/tests/unit/TypeTest.php b/vendor/sebastian/type/tests/unit/TypeTest.php deleted file mode 100644 index 5bc4b7d51..000000000 --- a/vendor/sebastian/type/tests/unit/TypeTest.php +++ /dev/null @@ -1,85 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Type; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\Type\Type - * - * @uses \SebastianBergmann\Type\SimpleType - * @uses \SebastianBergmann\Type\GenericObjectType - * @uses \SebastianBergmann\Type\ObjectType - * @uses \SebastianBergmann\Type\TypeName - * @uses \SebastianBergmann\Type\CallableType - * @uses \SebastianBergmann\Type\IterableType - */ -final class TypeTest extends TestCase -{ - /** - * @dataProvider valuesToNullableType - */ - public function testTypeMappingFromValue($value, bool $allowsNull, Type $expectedType): void - { - $this->assertEquals($expectedType, Type::fromValue($value, $allowsNull)); - } - - public function valuesToNullableType(): array - { - return [ - '?null' => [null, true, new NullType], - 'null' => [null, false, new NullType], - '?integer' => [1, true, new SimpleType('int', true, 1)], - 'integer' => [1, false, new SimpleType('int', false, 1)], - '?boolean' => [true, true, new SimpleType('bool', true, true)], - 'boolean' => [true, false, new SimpleType('bool', false, true)], - '?object' => [new \stdClass, true, new ObjectType(TypeName::fromQualifiedName(\stdClass::class), true)], - 'object' => [new \stdClass, false, new ObjectType(TypeName::fromQualifiedName(\stdClass::class), false)], - ]; - } - - /** - * @dataProvider namesToTypes - */ - public function testTypeMappingFromName(string $typeName, bool $allowsNull, $expectedType): void - { - $this->assertEquals($expectedType, Type::fromName($typeName, $allowsNull)); - } - - public function namesToTypes(): array - { - return [ - '?void' => ['void', true, new VoidType], - 'void' => ['void', false, new VoidType], - '?null' => ['null', true, new NullType], - 'null' => ['null', true, new NullType], - '?int' => ['int', true, new SimpleType('int', true)], - '?integer' => ['integer', true, new SimpleType('int', true)], - 'int' => ['int', false, new SimpleType('int', false)], - 'bool' => ['bool', false, new SimpleType('bool', false)], - 'boolean' => ['boolean', false, new SimpleType('bool', false)], - 'object' => ['object', false, new GenericObjectType(false)], - 'real' => ['real', false, new SimpleType('float', false)], - 'double' => ['double', false, new SimpleType('float', false)], - 'float' => ['float', false, new SimpleType('float', false)], - 'string' => ['string', false, new SimpleType('string', false)], - 'array' => ['array', false, new SimpleType('array', false)], - 'resource' => ['resource', false, new SimpleType('resource', false)], - 'resource (closed)' => ['resource (closed)', false, new SimpleType('resource (closed)', false)], - 'unknown type' => ['unknown type', false, new UnknownType], - '?classname' => [\stdClass::class, true, new ObjectType(TypeName::fromQualifiedName(\stdClass::class), true)], - 'classname' => [\stdClass::class, false, new ObjectType(TypeName::fromQualifiedName(\stdClass::class), false)], - 'callable' => ['callable', false, new CallableType(false)], - '?callable' => ['callable', true, new CallableType(true)], - 'iterable' => ['iterable', false, new IterableType(false)], - '?iterable' => ['iterable', true, new IterableType(true)], - ]; - } -} diff --git a/vendor/sebastian/type/tests/unit/UnknownTypeTest.php b/vendor/sebastian/type/tests/unit/UnknownTypeTest.php deleted file mode 100644 index bfa90f60b..000000000 --- a/vendor/sebastian/type/tests/unit/UnknownTypeTest.php +++ /dev/null @@ -1,58 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Type; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\Type\UnknownType - */ -final class UnknownTypeTest extends TestCase -{ - /** - * @var UnknownType - */ - private $type; - - protected function setUp(): void - { - $this->type = new UnknownType; - } - - /** - * @dataProvider assignableTypes - */ - public function testIsAssignable(Type $assignableType): void - { - $this->assertTrue($this->type->isAssignable($assignableType)); - } - - public function assignableTypes(): array - { - return [ - [new SimpleType('int', false)], - [new SimpleType('int', true)], - [new VoidType], - [new ObjectType(TypeName::fromQualifiedName(self::class), false)], - [new ObjectType(TypeName::fromQualifiedName(self::class), true)], - [new UnknownType], - ]; - } - - public function testAllowsNull(): void - { - $this->assertTrue($this->type->allowsNull()); - } - - public function testReturnTypeDeclaration(): void - { - $this->assertEquals('', $this->type->getReturnTypeDeclaration()); - } -} diff --git a/vendor/sebastian/type/tests/unit/VoidTypeTest.php b/vendor/sebastian/type/tests/unit/VoidTypeTest.php deleted file mode 100644 index 794052fdd..000000000 --- a/vendor/sebastian/type/tests/unit/VoidTypeTest.php +++ /dev/null @@ -1,70 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace SebastianBergmann\Type; - -use PHPUnit\Framework\TestCase; - -/** - * @covers \SebastianBergmann\Type\VoidType - */ -final class VoidTypeTest extends TestCase -{ - /** - * @dataProvider assignableTypes - */ - public function testIsAssignable(Type $assignableType): void - { - $type = new VoidType; - - $this->assertTrue($type->isAssignable($assignableType)); - } - - public function assignableTypes(): array - { - return [ - [new VoidType], - ]; - } - - /** - * @dataProvider notAssignableTypes - */ - public function testIsNotAssignable(Type $assignableType): void - { - $type = new VoidType; - - $this->assertFalse($type->isAssignable($assignableType)); - } - - public function notAssignableTypes(): array - { - return [ - [new SimpleType('int', false)], - [new SimpleType('int', true)], - [new ObjectType(TypeName::fromQualifiedName(self::class), false)], - [new ObjectType(TypeName::fromQualifiedName(self::class), true)], - [new UnknownType], - ]; - } - - public function testNotAllowNull(): void - { - $type = new VoidType; - - $this->assertFalse($type->allowsNull()); - } - - public function testCanGenerateReturnTypeDeclaration(): void - { - $type = new VoidType; - - $this->assertEquals(': void', $type->getReturnTypeDeclaration()); - } -} diff --git a/vendor/sebastian/version/.gitattributes b/vendor/sebastian/version/.gitattributes index 461090b7e..54b895305 100644 --- a/vendor/sebastian/version/.gitattributes +++ b/vendor/sebastian/version/.gitattributes @@ -1 +1,4 @@ +/.github export-ignore +/.php_cs.dist export-ignore + *.php diff=php diff --git a/vendor/sebastian/version/.gitignore b/vendor/sebastian/version/.gitignore index a09c56df5..ff5ec9a0e 100644 --- a/vendor/sebastian/version/.gitignore +++ b/vendor/sebastian/version/.gitignore @@ -1 +1,2 @@ +/.php_cs.cache /.idea diff --git a/vendor/sebastian/version/.php_cs b/vendor/sebastian/version/.php_cs deleted file mode 100644 index 8cbc57c79..000000000 --- a/vendor/sebastian/version/.php_cs +++ /dev/null @@ -1,66 +0,0 @@ -files() - ->in('src') - ->name('*.php'); - -return Symfony\CS\Config\Config::create() - ->level(\Symfony\CS\FixerInterface::NONE_LEVEL) - ->fixers( - array( - 'align_double_arrow', - 'align_equals', - 'braces', - 'concat_with_spaces', - 'duplicate_semicolon', - 'elseif', - 'empty_return', - 'encoding', - 'eof_ending', - 'extra_empty_lines', - 'function_call_space', - 'function_declaration', - 'indentation', - 'join_function', - 'line_after_namespace', - 'linefeed', - 'list_commas', - 'lowercase_constants', - 'lowercase_keywords', - 'method_argument_space', - 'multiple_use', - 'namespace_no_leading_whitespace', - 'no_blank_lines_after_class_opening', - 'no_empty_lines_after_phpdocs', - 'parenthesis', - 'php_closing_tag', - 'phpdoc_indent', - 'phpdoc_no_access', - 'phpdoc_no_empty_return', - 'phpdoc_no_package', - 'phpdoc_params', - 'phpdoc_scalar', - 'phpdoc_separation', - 'phpdoc_to_comment', - 'phpdoc_trim', - 'phpdoc_types', - 'phpdoc_var_without_name', - 'remove_lines_between_uses', - 'return', - 'self_accessor', - 'short_array_syntax', - 'short_tag', - 'single_line_after_imports', - 'single_quote', - 'spaces_before_semicolon', - 'spaces_cast', - 'ternary_spaces', - 'trailing_spaces', - 'trim_array_spaces', - 'unused_use', - 'visibility', - 'whitespacy_lines' - ) - ) - ->finder($finder); - diff --git a/vendor/sebastian/version/ChangeLog.md b/vendor/sebastian/version/ChangeLog.md new file mode 100644 index 000000000..10fd9a1a5 --- /dev/null +++ b/vendor/sebastian/version/ChangeLog.md @@ -0,0 +1,25 @@ +# ChangeLog + +All notable changes are documented in this file using the [Keep a CHANGELOG](https://keepachangelog.com/) principles. + +## [3.0.2] - 2020-09-28 + +### Changed + +* Changed PHP version constraint in `composer.json` from `^7.3 || ^8.0` to `>=7.3` + +## [3.0.1] - 2020-06-26 + +### Added + +* This component is now supported on PHP 8 + +## [3.0.0] - 2020-01-21 + +### Removed + +* This component is no longer supported on PHP 7.1 and PHP 7.2 + +[3.0.2]: https://github.com/sebastianbergmann/version/compare/3.0.1...3.0.2 +[3.0.1]: https://github.com/sebastianbergmann/version/compare/3.0.0...3.0.1 +[3.0.0]: https://github.com/sebastianbergmann/version/compare/2.0.1...3.0.0 diff --git a/vendor/sebastian/version/LICENSE b/vendor/sebastian/version/LICENSE index 5b79c41f6..aa6bca299 100644 --- a/vendor/sebastian/version/LICENSE +++ b/vendor/sebastian/version/LICENSE @@ -1,6 +1,6 @@ Version -Copyright (c) 2013-2015, Sebastian Bergmann . +Copyright (c) 2013-2020, Sebastian Bergmann . All rights reserved. Redistribution and use in source and binary forms, with or without diff --git a/vendor/sebastian/version/composer.json b/vendor/sebastian/version/composer.json index 3b87814c1..e76dbf412 100644 --- a/vendor/sebastian/version/composer.json +++ b/vendor/sebastian/version/composer.json @@ -13,8 +13,16 @@ "support": { "issues": "https://github.com/sebastianbergmann/version/issues" }, + "config": { + "platform": { + "php": "7.3.0" + }, + "optimize-autoloader": true, + "sort-packages": true + }, + "prefer-stable": true, "require": { - "php": ">=5.6" + "php": ">=7.3" }, "autoload": { "classmap": [ @@ -23,7 +31,7 @@ }, "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "3.0-dev" } } } diff --git a/vendor/sebastian/version/src/Version.php b/vendor/sebastian/version/src/Version.php index fc4cfecbf..53ae7894e 100644 --- a/vendor/sebastian/version/src/Version.php +++ b/vendor/sebastian/version/src/Version.php @@ -1,6 +1,6 @@ * @@ -10,10 +10,7 @@ namespace SebastianBergmann; -/** - * @since Class available since Release 1.0.0 - */ -class Version +final class Version { /** * @var string @@ -30,23 +27,16 @@ class Version */ private $version; - /** - * @param string $release - * @param string $path - */ - public function __construct($release, $path) + public function __construct(string $release, string $path) { $this->release = $release; $this->path = $path; } - /** - * @return string - */ - public function getVersion() + public function getVersion(): string { if ($this->version === null) { - if (count(explode('.', $this->release)) == 3) { + if (\substr_count($this->release, '.') + 1 === 3) { $this->version = $this->release; } else { $this->version = $this->release . '-dev'; @@ -55,12 +45,12 @@ class Version $git = $this->getGitInformation($this->path); if ($git) { - if (count(explode('.', $this->release)) == 3) { + if (\substr_count($this->release, '.') + 1 === 3) { $this->version = $git; } else { - $git = explode('-', $git); + $git = \explode('-', $git); - $this->version = $this->release . '-' . end($git); + $this->version = $this->release . '-' . \end($git); } } } @@ -69,17 +59,15 @@ class Version } /** - * @param string $path - * * @return bool|string */ - private function getGitInformation($path) + private function getGitInformation(string $path) { - if (!is_dir($path . DIRECTORY_SEPARATOR . '.git')) { + if (!\is_dir($path . DIRECTORY_SEPARATOR . '.git')) { return false; } - $process = proc_open( + $process = \proc_open( 'git describe --tags', [ 1 => ['pipe', 'w'], @@ -89,16 +77,16 @@ class Version $path ); - if (!is_resource($process)) { + if (!\is_resource($process)) { return false; } - $result = trim(stream_get_contents($pipes[1])); + $result = \trim(\stream_get_contents($pipes[1])); - fclose($pipes[1]); - fclose($pipes[2]); + \fclose($pipes[1]); + \fclose($pipes[2]); - $returnCode = proc_close($process); + $returnCode = \proc_close($process); if ($returnCode !== 0) { return false; diff --git a/vendor/spatie/laravel-schedule-monitor/.php_cs b/vendor/spatie/laravel-schedule-monitor/.php_cs.dist similarity index 100% rename from vendor/spatie/laravel-schedule-monitor/.php_cs rename to vendor/spatie/laravel-schedule-monitor/.php_cs.dist diff --git a/vendor/spatie/laravel-schedule-monitor/CHANGELOG.md b/vendor/spatie/laravel-schedule-monitor/CHANGELOG.md index c0b9eb04c..ac553fe78 100644 --- a/vendor/spatie/laravel-schedule-monitor/CHANGELOG.md +++ b/vendor/spatie/laravel-schedule-monitor/CHANGELOG.md @@ -2,6 +2,28 @@ All notable changes to `laravel-schedule-monitor` will be documented in this file +## 2.3.0 - 2021-05-13 + +- add `storeOutputInDb` + +## 2.2.1 - 2021-03-29 + +- upgrade to latest lorisleiva/cron-translator version (#40) + +## 2.2.0 - 2021-01-15 + +- throw an exception if pinging Oh Dear has failed [#37](https://github.com/spatie/laravel-schedule-monitor/pull/37) +- pass 0 instead of null parameters to Oh dear for Background tasks [#37](https://github.com/spatie/laravel-schedule-monitor/pull/37) + +## 2.1.0 - 2020-12-04 + +- add support for PHP 8 + +## 2.0.2 - 2020-10-14 + +- drop support for Laravel 7 +- fix command description + ## 2.0.1 - 2020-10-06 - report right exit code for scheduled tasks in background diff --git a/vendor/spatie/laravel-schedule-monitor/CONTRIBUTING.md b/vendor/spatie/laravel-schedule-monitor/CONTRIBUTING.md deleted file mode 100644 index b4ae1c4a7..000000000 --- a/vendor/spatie/laravel-schedule-monitor/CONTRIBUTING.md +++ /dev/null @@ -1,55 +0,0 @@ -# Contributing - -Contributions are **welcome** and will be fully **credited**. - -Please read and understand the contribution guide before creating an issue or pull request. - -## Etiquette - -This project is open source, and as such, the maintainers give their free time to build and maintain the source code -held within. They make the code freely available in the hope that it will be of use to other developers. It would be -extremely unfair for them to suffer abuse or anger for their hard work. - -Please be considerate towards maintainers when raising issues or presenting pull requests. Let's show the -world that developers are civilized and selfless people. - -It's the duty of the maintainer to ensure that all submissions to the project are of sufficient -quality to benefit the project. Many developers have different skillsets, strengths, and weaknesses. Respect the maintainer's decision, and do not be upset or abusive if your submission is not used. - -## Viability - -When requesting or submitting new features, first consider whether it might be useful to others. Open -source projects are used by many developers, who may have entirely different needs to your own. Think about -whether or not your feature is likely to be used by other users of the project. - -## Procedure - -Before filing an issue: - -- Attempt to replicate the problem, to ensure that it wasn't a coincidental incident. -- Check to make sure your feature suggestion isn't already present within the project. -- Check the pull requests tab to ensure that the bug doesn't have a fix in progress. -- Check the pull requests tab to ensure that the feature isn't already in progress. - -Before submitting a pull request: - -- Check the codebase to ensure that your feature doesn't already exist. -- Check the pull requests to ensure that another person hasn't already submitted the feature or fix. - -## Requirements - -If the project maintainer has any additional requirements, you will find them listed here. - -- **[PSR-2 Coding Standard](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-2-coding-style-guide.md)** - The easiest way to apply the conventions is to install [PHP Code Sniffer](https://pear.php.net/package/PHP_CodeSniffer). - -- **Add tests!** - Your patch won't be accepted if it doesn't have tests. - -- **Document any change in behaviour** - Make sure the `README.md` and any other relevant documentation are kept up-to-date. - -- **Consider our release cycle** - We try to follow [SemVer v2.0.0](https://semver.org/). Randomly breaking public APIs is not an option. - -- **One pull request per feature** - If you want to do more than one thing, send multiple pull requests. - -- **Send coherent history** - Make sure each individual commit in your pull request is meaningful. If you had to make multiple intermediate commits while developing, please [squash them](https://www.git-scm.com/book/en/v2/Git-Tools-Rewriting-History#Changing-Multiple-Commit-Messages) before submitting. - -**Happy coding**! diff --git a/vendor/spatie/laravel-schedule-monitor/README.md b/vendor/spatie/laravel-schedule-monitor/README.md index 6dacb6041..a923c84c1 100644 --- a/vendor/spatie/laravel-schedule-monitor/README.md +++ b/vendor/spatie/laravel-schedule-monitor/README.md @@ -12,9 +12,7 @@ This package can also sync your schedule with [Oh Dear](https://ohdear.app). Oh ## Support us -Learn how to create a package like this one, by watching our premium video course: - -[![Laravel Package training](https://spatie.be/github/package-training.jpg)](https://laravelpackage.training) +[](https://spatie.be/github-ad-click/laravel-schedule-monitor) We invest a lot of resources into creating [best in class open source packages](https://spatie.be/open-source). You can support us by [buying one of our paid products](https://spatie.be/open-source/support-us). @@ -184,6 +182,21 @@ protected function schedule(Schedule $schedule) } ``` +### Storing output in the database + +You can store the output by tacking on `storeOutputInDb` when scheduling the task. + +```php +// in app/Console/Kernel.php + +protected function schedule(Schedule $schedule) +{ + $schedule->command('your-command')->daily()->storeOutputInDb(); +} +``` + +The output will be stored in the `monitored_scheduled_task_log_items` table, in the `output` key of the `meta` column. + ### Getting notified when a scheduled task doesn't finish in time This package can sync your schedule with the [Oh Dear](https://ohdear.app) cron check. Oh Dear will send you a notification whenever a scheduled task does not finish on time. @@ -245,7 +258,7 @@ We assume that, when your scheduled tasks do not run properly, a scheduled task These services can notify you when scheduled tasks do not run properly: - [Oh Dear](https://ohdear.app) -- [thenping.me](https://thenping.me) (in closed beta) +- [thenping.me](https://thenping.me) - [Cronbox](https://cronbox.app) - [Healthchecks.io](https://healthchecks.io) - [Cronitor](https://cronitor.io) @@ -266,7 +279,7 @@ Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed re ## Contributing -Please see [CONTRIBUTING](CONTRIBUTING.md) for details. +Please see [CONTRIBUTING](.github/CONTRIBUTING.md) for details. ## Security diff --git a/vendor/spatie/laravel-schedule-monitor/composer.json b/vendor/spatie/laravel-schedule-monitor/composer.json index 34f8f68de..a6d037f25 100644 --- a/vendor/spatie/laravel-schedule-monitor/composer.json +++ b/vendor/spatie/laravel-schedule-monitor/composer.json @@ -16,19 +16,20 @@ } ], "require": { - "php": "^7.4", - "illuminate/bus": "^7.19|^8.0", - "lorisleiva/cron-translator": "^0.1.1" + "php": "^7.4|^8.0", + "illuminate/bus": "^8.0", + "nesbot/carbon": "^2.41.3", + "lorisleiva/cron-translator": "^0.2.0" }, "require-dev": { - "friendsofphp/php-cs-fixer": "^2.16", "laravel/legacy-factories": "^1.0.4", "ohdearapp/ohdear-php-sdk": "^3.0", - "orchestra/testbench": "^5.0|^6.0", - "phpunit/phpunit": "^9.0", + "orchestra/testbench": "^6.8", + "phpunit/phpunit": "^9.3", "spatie/phpunit-snapshot-assertions": "^4.2", "spatie/test-time": "^1.2", - "vimeo/psalm": "^3.11" + "vimeo/psalm": "^4.0", + "mockery/mockery": "^1.4" }, "suggest": { "ohdearapp/ohdear-php-sdk": "Needed to sync your schedule with Oh Dear" diff --git a/vendor/spatie/laravel-schedule-monitor/src/Commands/CleanLogCommand.php b/vendor/spatie/laravel-schedule-monitor/src/Commands/CleanLogCommand.php index a481def4e..19077c93b 100644 --- a/vendor/spatie/laravel-schedule-monitor/src/Commands/CleanLogCommand.php +++ b/vendor/spatie/laravel-schedule-monitor/src/Commands/CleanLogCommand.php @@ -10,7 +10,7 @@ class CleanLogCommand extends Command { public $signature = 'schedule-monitor:clean'; - public $description = 'Display monitored scheduled tasks'; + public $description = 'Clean up old records from the schedule monitor log.'; public function handle() { diff --git a/vendor/spatie/laravel-schedule-monitor/src/EventHandlers/BackgroundCommandListener.php b/vendor/spatie/laravel-schedule-monitor/src/EventHandlers/BackgroundCommandListener.php index df0a63dfa..d6975b5f3 100644 --- a/vendor/spatie/laravel-schedule-monitor/src/EventHandlers/BackgroundCommandListener.php +++ b/vendor/spatie/laravel-schedule-monitor/src/EventHandlers/BackgroundCommandListener.php @@ -22,17 +22,17 @@ class BackgroundCommandListener $task ->then( function () use ($task) { - if (! $monitoredTask = MonitoredScheduledTask::findForTask($task)) { - return; + if (! $monitoredTask = MonitoredScheduledTask::findForTask($task)) { + return; + } + + $event = new ScheduledTaskFinished( + $task, + 0 + ); + + $monitoredTask->markAsFinished($event); } - - $event = new ScheduledTaskFinished( - $task, - 0 - ); - - $monitoredTask->markAsFinished($event); - } ); }); } diff --git a/vendor/spatie/laravel-schedule-monitor/src/Jobs/PingOhDearJob.php b/vendor/spatie/laravel-schedule-monitor/src/Jobs/PingOhDearJob.php index f9ce09ecb..8c7e385e1 100644 --- a/vendor/spatie/laravel-schedule-monitor/src/Jobs/PingOhDearJob.php +++ b/vendor/spatie/laravel-schedule-monitor/src/Jobs/PingOhDearJob.php @@ -34,7 +34,8 @@ class PingOhDearJob implements ShouldQueue return; } - Http::post($payload->url(), $payload->data()); + $response = Http::post($payload->url(), $payload->data()); + $response->throw(); $this->logItem->monitoredScheduledTask->update(['last_pinged_at' => now()]); } diff --git a/vendor/spatie/laravel-schedule-monitor/src/Models/MonitoredScheduledTask.php b/vendor/spatie/laravel-schedule-monitor/src/Models/MonitoredScheduledTask.php index 106e540d8..b2c121fe5 100644 --- a/vendor/spatie/laravel-schedule-monitor/src/Models/MonitoredScheduledTask.php +++ b/vendor/spatie/laravel-schedule-monitor/src/Models/MonitoredScheduledTask.php @@ -91,9 +91,10 @@ class MonitoredScheduledTask extends Model $logItem = $this->createLogItem(MonitoredScheduledTaskLogItem::TYPE_FINISHED); $logItem->updateMeta([ - 'runtime' => $event->task->runInBackground ? null : $event->runtime, + 'runtime' => $event->task->runInBackground ? 0 : $event->runtime, 'exit_code' => $event->task->exitCode, - 'memory' => $event->task->runInBackground ? null : memory_get_usage(true), + 'memory' => $event->task->runInBackground ? 0 : memory_get_usage(true), + 'output' => $this->getEventTaskOutput($event), ]); $this->update(['last_finished_at' => now()]); @@ -160,7 +161,7 @@ class MonitoredScheduledTask extends Model if (! in_array($logItem->type, [ MonitoredScheduledTaskLogItem::TYPE_FAILED, MonitoredScheduledTaskLogItem::TYPE_FINISHED, - ])) { + ], true)) { return $this; } @@ -175,4 +176,30 @@ class MonitoredScheduledTask extends Model 'type' => $type, ]); } + + /** + * @param ScheduledTaskFailed|ScheduledTaskFinished $event + */ + protected function getEventTaskOutput($event): ?string + { + if (! ($event->task->storeOutputInDb ?? false)) { + return null; + } + + if (is_null($event->task->output)) { + return null; + } + + if ($event->task->output === $event->task->getDefaultOutput()) { + return null; + } + + if (! is_file($event->task->output)) { + return null; + } + + $output = file_get_contents($event->task->output); + + return $output ?: null; + } } diff --git a/vendor/spatie/laravel-schedule-monitor/src/ScheduleMonitorServiceProvider.php b/vendor/spatie/laravel-schedule-monitor/src/ScheduleMonitorServiceProvider.php index 3fb3d9580..166cfc94b 100644 --- a/vendor/spatie/laravel-schedule-monitor/src/ScheduleMonitorServiceProvider.php +++ b/vendor/spatie/laravel-schedule-monitor/src/ScheduleMonitorServiceProvider.php @@ -103,6 +103,14 @@ class ScheduleMonitorServiceProvider extends ServiceProvider return $this; }); + SchedulerEvent::macro('storeOutputInDb', function () { + $this->storeOutputInDb = true; + /** @psalm-suppress UndefinedMethod */ + $this->ensureOutputIsBeingCaptured(); + + return $this; + }); + return $this; } } diff --git a/vendor/spatie/laravel-schedule-monitor/src/Support/ScheduledTasks/Tasks/ClosureTask.php b/vendor/spatie/laravel-schedule-monitor/src/Support/ScheduledTasks/Tasks/ClosureTask.php index 86761be0c..df8db4e49 100644 --- a/vendor/spatie/laravel-schedule-monitor/src/Support/ScheduledTasks/Tasks/ClosureTask.php +++ b/vendor/spatie/laravel-schedule-monitor/src/Support/ScheduledTasks/Tasks/ClosureTask.php @@ -13,7 +13,7 @@ class ClosureTask extends Task return false; } - return $event->getSummaryForDisplay() === 'Closure'; + return in_array($event->getSummaryForDisplay(), ['Closure', 'Callback']); } public function type(): string diff --git a/vendor/symfony/css-selector/XPath/Extension/NodeExtension.php b/vendor/symfony/css-selector/XPath/Extension/NodeExtension.php index 0e138229e..aa6f3f704 100644 --- a/vendor/symfony/css-selector/XPath/Extension/NodeExtension.php +++ b/vendor/symfony/css-selector/XPath/Extension/NodeExtension.php @@ -157,7 +157,7 @@ class NodeExtension extends AbstractExtension { $element = $node->getElement(); - if ($this->hasFlag(self::ELEMENT_NAME_IN_LOWER_CASE)) { + if ($element && $this->hasFlag(self::ELEMENT_NAME_IN_LOWER_CASE)) { $element = strtolower($element); } diff --git a/vendor/symfony/finder/Comparator/NumberComparator.php b/vendor/symfony/finder/Comparator/NumberComparator.php index 78e1bd3b3..657118fb6 100644 --- a/vendor/symfony/finder/Comparator/NumberComparator.php +++ b/vendor/symfony/finder/Comparator/NumberComparator.php @@ -41,8 +41,8 @@ class NumberComparator extends Comparator */ public function __construct(?string $test) { - if (!preg_match('#^\s*(==|!=|[<>]=?)?\s*([0-9\.]+)\s*([kmg]i?)?\s*$#i', $test, $matches)) { - throw new \InvalidArgumentException(sprintf('Don\'t understand "%s" as a number test.', $test)); + if (null === $test || !preg_match('#^\s*(==|!=|[<>]=?)?\s*([0-9\.]+)\s*([kmg]i?)?\s*$#i', $test, $matches)) { + throw new \InvalidArgumentException(sprintf('Don\'t understand "%s" as a number test.', $test ?? 'null')); } $target = $matches[2]; diff --git a/vendor/symfony/finder/Gitignore.php b/vendor/symfony/finder/Gitignore.php index 5bd682949..304aba9e5 100644 --- a/vendor/symfony/finder/Gitignore.php +++ b/vendor/symfony/finder/Gitignore.php @@ -68,20 +68,16 @@ class Gitignore $isAbsolute = false; } - $parts = array_map(function (string $v): string { - $v = preg_quote(str_replace('\\', '', $v), '~'); - $v = preg_replace_callback('~\\\\\[([^\[\]]*)\\\\\]~', function (array $matches): string { - return '['.str_replace('\\-', '-', $matches[1]).']'; - }, $v); - $v = preg_replace('~\\\\\*\\\\\*~', '[^/]+(?:/[^/]+)*', $v); - $v = preg_replace('~\\\\\*~', '[^/]*', $v); - $v = preg_replace('~\\\\\?~', '[^/]', $v); - - return $v; - }, explode('/', $gitignoreLine)); + $regex = preg_quote(str_replace('\\', '', $gitignoreLine), '~'); + $regex = preg_replace_callback('~\\\\\[((?:\\\\!)?)([^\[\]]*)\\\\\]~', function (array $matches): string { + return '['.('' !== $matches[1] ? '^' : '').str_replace('\\-', '-', $matches[2]).']'; + }, $regex); + $regex = preg_replace('~(?:(?:\\\\\*){2,}(/?))+~', '(?:(?:(?!//).(?name][$p->name])) { diff --git a/vendor/symfony/http-kernel/EventListener/RouterListener.php b/vendor/symfony/http-kernel/EventListener/RouterListener.php index c10897a9e..54f7cb02c 100644 --- a/vendor/symfony/http-kernel/EventListener/RouterListener.php +++ b/vendor/symfony/http-kernel/EventListener/RouterListener.php @@ -164,7 +164,7 @@ class RouterListener implements EventSubscriberInterface private function createWelcomeResponse(): Response { $version = Kernel::VERSION; - $projectDir = realpath($this->projectDir).\DIRECTORY_SEPARATOR; + $projectDir = realpath((string) $this->projectDir).\DIRECTORY_SEPARATOR; $docVersion = substr(Kernel::VERSION, 0, 3); ob_start(); diff --git a/vendor/symfony/http-kernel/Kernel.php b/vendor/symfony/http-kernel/Kernel.php index 5a48ccf9e..91ce455fe 100644 --- a/vendor/symfony/http-kernel/Kernel.php +++ b/vendor/symfony/http-kernel/Kernel.php @@ -74,11 +74,11 @@ abstract class Kernel implements KernelInterface, RebootableInterface, Terminabl private static $freshCache = []; - public const VERSION = '5.2.8'; - public const VERSION_ID = 50208; + public const VERSION = '5.2.9'; + public const VERSION_ID = 50209; public const MAJOR_VERSION = 5; public const MINOR_VERSION = 2; - public const RELEASE_VERSION = 8; + public const RELEASE_VERSION = 9; public const EXTRA_VERSION = ''; public const END_OF_MAINTENANCE = '07/2021'; diff --git a/vendor/symfony/mime/Email.php b/vendor/symfony/mime/Email.php index 851749880..acccf69e3 100644 --- a/vendor/symfony/mime/Email.php +++ b/vendor/symfony/mime/Email.php @@ -266,7 +266,7 @@ class Email extends Message */ public function getPriority(): int { - [$priority] = sscanf($this->getHeaders()->getHeaderBody('X-Priority'), '%[1-5]'); + [$priority] = sscanf($this->getHeaders()->getHeaderBody('X-Priority') ?? '', '%[1-5]'); return $priority ?? 3; } diff --git a/vendor/symfony/polyfill-ctype/composer.json b/vendor/symfony/polyfill-ctype/composer.json index 995978c0a..f0621a3b6 100644 --- a/vendor/symfony/polyfill-ctype/composer.json +++ b/vendor/symfony/polyfill-ctype/composer.json @@ -28,7 +28,7 @@ "minimum-stability": "dev", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", diff --git a/vendor/symfony/polyfill-iconv/Resources/charset/translit.php b/vendor/symfony/polyfill-iconv/Resources/charset/translit.php index 779db649c..f322ff0d2 100644 --- a/vendor/symfony/polyfill-iconv/Resources/charset/translit.php +++ b/vendor/symfony/polyfill-iconv/Resources/charset/translit.php @@ -3995,8 +3995,8 @@ return array ( '₣' => 'Fr.', '₤' => 'L.', '₧' => 'Pts', - '₺' => 'TL', '₹' => 'Rs', + '₺' => 'TL', '℗' => '(P)', '℘' => 'P', '℞' => 'Rx', @@ -4043,6 +4043,8 @@ return array ( '―' => '-', '︱' => '-', '︲' => '-', + '¡' => '!', + '¿' => '?', '˂' => '<', '˃' => '>', '˄' => '^', @@ -4087,6 +4089,7 @@ return array ( '﹀' => '>', '﹇' => '[', '﹈' => ']', + '±' => '+/-', '×' => '*', '÷' => '/', '˖' => '+', diff --git a/vendor/symfony/polyfill-iconv/bootstrap80.php b/vendor/symfony/polyfill-iconv/bootstrap80.php index c46eb487b..cf8955745 100644 --- a/vendor/symfony/polyfill-iconv/bootstrap80.php +++ b/vendor/symfony/polyfill-iconv/bootstrap80.php @@ -51,7 +51,7 @@ if (extension_loaded('mbstring')) { function iconv_strrpos(?string $haystack, ?string $needle, ?string $encoding = null): int|false { null === $encoding && $encoding = p\Iconv::$internalEncoding; return mb_strrpos((string) $haystack, (string) $needle, 0, $encoding); } } if (!function_exists('iconv_substr')) { - function iconv_substr(?string $string, ?int $offset, ?int $length = null, ?string $encoding = null): string|false { null === $encoding && $encoding = p\Iconv::$internalEncoding; return mb_substr((string) $string, (int) $offset, (int) $length, $encoding); } + function iconv_substr(?string $string, ?int $offset, ?int $length = null, ?string $encoding = null): string|false { null === $encoding && $encoding = p\Iconv::$internalEncoding; return mb_substr((string) $string, (int) $offset, $length, $encoding); } } if (!function_exists('iconv_mime_decode')) { function iconv_mime_decode($string, $mode = 0, $encoding = null) { null === $encoding && $encoding = p\Iconv::$internalEncoding; return mb_decode_mimeheader($string, $mode, $encoding); } @@ -72,7 +72,7 @@ if (extension_loaded('mbstring')) { function iconv_strrpos(?string $haystack, ?string $needle, ?string $encoding = null): int|false { return p\Iconv::iconv_strrpos((string) $haystack, (string) $needle, $encoding); } } if (!function_exists('iconv_substr')) { - function iconv_substr(?string $string, ?int $offset, ?int $length = null, ?string $encoding = null): string|false { return p\Iconv::iconv_substr((string) $string, (string) $offset, (int) $length, $encoding); } + function iconv_substr(?string $string, ?int $offset, ?int $length = null, ?string $encoding = null): string|false { return p\Iconv::iconv_substr((string) $string, (string) $offset, $length, $encoding); } } if (!function_exists('iconv_mime_decode')) { function iconv_mime_decode(?string $string, ?int $mode = 0, ?string $encoding = null): string|false { return p\Iconv::iconv_mime_decode((string) $string, (int) $mode, $encoding); } diff --git a/vendor/symfony/polyfill-iconv/composer.json b/vendor/symfony/polyfill-iconv/composer.json index 4669f3f1b..17483e00a 100644 --- a/vendor/symfony/polyfill-iconv/composer.json +++ b/vendor/symfony/polyfill-iconv/composer.json @@ -28,7 +28,7 @@ "minimum-stability": "dev", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", diff --git a/vendor/symfony/polyfill-intl-grapheme/bootstrap80.php b/vendor/symfony/polyfill-intl-grapheme/bootstrap80.php index 53b452979..b8c078677 100644 --- a/vendor/symfony/polyfill-intl-grapheme/bootstrap80.php +++ b/vendor/symfony/polyfill-intl-grapheme/bootstrap80.php @@ -46,5 +46,5 @@ if (!function_exists('grapheme_strstr')) { function grapheme_strstr(?string $haystack, ?string $needle, ?bool $beforeNeedle = false): string|false { return p\Grapheme::grapheme_strstr((string) $haystack, (string) $needle, (bool) $beforeNeedle); } } if (!function_exists('grapheme_substr')) { - function grapheme_substr(?string $string, ?int $offset, ?int $length = null): string|false { return p\Grapheme::grapheme_substr((string) $string, (int) $offset, (int) $length); } + function grapheme_substr(?string $string, ?int $offset, ?int $length = null): string|false { return p\Grapheme::grapheme_substr((string) $string, (int) $offset, $length); } } diff --git a/vendor/symfony/polyfill-intl-grapheme/composer.json b/vendor/symfony/polyfill-intl-grapheme/composer.json index 5ca4e3b95..02c98ee30 100644 --- a/vendor/symfony/polyfill-intl-grapheme/composer.json +++ b/vendor/symfony/polyfill-intl-grapheme/composer.json @@ -28,7 +28,7 @@ "minimum-stability": "dev", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", diff --git a/vendor/symfony/polyfill-intl-idn/Resources/unidata/Regex.php b/vendor/symfony/polyfill-intl-idn/Resources/unidata/Regex.php index c4b9778e5..5c1c51dde 100644 --- a/vendor/symfony/polyfill-intl-idn/Resources/unidata/Regex.php +++ b/vendor/symfony/polyfill-intl-idn/Resources/unidata/Regex.php @@ -7,18 +7,18 @@ namespace Symfony\Polyfill\Intl\Idn\Resources\unidata; */ final class Regex { - public const COMBINING_MARK = '/^[\x{0300}-\x{036F}\x{0483}-\x{0487}\x{0488}-\x{0489}\x{0591}-\x{05BD}\x{05BF}\x{05C1}-\x{05C2}\x{05C4}-\x{05C5}\x{05C7}\x{0610}-\x{061A}\x{064B}-\x{065F}\x{0670}\x{06D6}-\x{06DC}\x{06DF}-\x{06E4}\x{06E7}-\x{06E8}\x{06EA}-\x{06ED}\x{0711}\x{0730}-\x{074A}\x{07A6}-\x{07B0}\x{07EB}-\x{07F3}\x{07FD}\x{0816}-\x{0819}\x{081B}-\x{0823}\x{0825}-\x{0827}\x{0829}-\x{082D}\x{0859}-\x{085B}\x{08D3}-\x{08E1}\x{08E3}-\x{0902}\x{0903}\x{093A}\x{093B}\x{093C}\x{093E}-\x{0940}\x{0941}-\x{0948}\x{0949}-\x{094C}\x{094D}\x{094E}-\x{094F}\x{0951}-\x{0957}\x{0962}-\x{0963}\x{0981}\x{0982}-\x{0983}\x{09BC}\x{09BE}-\x{09C0}\x{09C1}-\x{09C4}\x{09C7}-\x{09C8}\x{09CB}-\x{09CC}\x{09CD}\x{09D7}\x{09E2}-\x{09E3}\x{09FE}\x{0A01}-\x{0A02}\x{0A03}\x{0A3C}\x{0A3E}-\x{0A40}\x{0A41}-\x{0A42}\x{0A47}-\x{0A48}\x{0A4B}-\x{0A4D}\x{0A51}\x{0A70}-\x{0A71}\x{0A75}\x{0A81}-\x{0A82}\x{0A83}\x{0ABC}\x{0ABE}-\x{0AC0}\x{0AC1}-\x{0AC5}\x{0AC7}-\x{0AC8}\x{0AC9}\x{0ACB}-\x{0ACC}\x{0ACD}\x{0AE2}-\x{0AE3}\x{0AFA}-\x{0AFF}\x{0B01}\x{0B02}-\x{0B03}\x{0B3C}\x{0B3E}\x{0B3F}\x{0B40}\x{0B41}-\x{0B44}\x{0B47}-\x{0B48}\x{0B4B}-\x{0B4C}\x{0B4D}\x{0B55}-\x{0B56}\x{0B57}\x{0B62}-\x{0B63}\x{0B82}\x{0BBE}-\x{0BBF}\x{0BC0}\x{0BC1}-\x{0BC2}\x{0BC6}-\x{0BC8}\x{0BCA}-\x{0BCC}\x{0BCD}\x{0BD7}\x{0C00}\x{0C01}-\x{0C03}\x{0C04}\x{0C3E}-\x{0C40}\x{0C41}-\x{0C44}\x{0C46}-\x{0C48}\x{0C4A}-\x{0C4D}\x{0C55}-\x{0C56}\x{0C62}-\x{0C63}\x{0C81}\x{0C82}-\x{0C83}\x{0CBC}\x{0CBE}\x{0CBF}\x{0CC0}-\x{0CC4}\x{0CC6}\x{0CC7}-\x{0CC8}\x{0CCA}-\x{0CCB}\x{0CCC}-\x{0CCD}\x{0CD5}-\x{0CD6}\x{0CE2}-\x{0CE3}\x{0D00}-\x{0D01}\x{0D02}-\x{0D03}\x{0D3B}-\x{0D3C}\x{0D3E}-\x{0D40}\x{0D41}-\x{0D44}\x{0D46}-\x{0D48}\x{0D4A}-\x{0D4C}\x{0D4D}\x{0D57}\x{0D62}-\x{0D63}\x{0D81}\x{0D82}-\x{0D83}\x{0DCA}\x{0DCF}-\x{0DD1}\x{0DD2}-\x{0DD4}\x{0DD6}\x{0DD8}-\x{0DDF}\x{0DF2}-\x{0DF3}\x{0E31}\x{0E34}-\x{0E3A}\x{0E47}-\x{0E4E}\x{0EB1}\x{0EB4}-\x{0EBC}\x{0EC8}-\x{0ECD}\x{0F18}-\x{0F19}\x{0F35}\x{0F37}\x{0F39}\x{0F3E}-\x{0F3F}\x{0F71}-\x{0F7E}\x{0F7F}\x{0F80}-\x{0F84}\x{0F86}-\x{0F87}\x{0F8D}-\x{0F97}\x{0F99}-\x{0FBC}\x{0FC6}\x{102B}-\x{102C}\x{102D}-\x{1030}\x{1031}\x{1032}-\x{1037}\x{1038}\x{1039}-\x{103A}\x{103B}-\x{103C}\x{103D}-\x{103E}\x{1056}-\x{1057}\x{1058}-\x{1059}\x{105E}-\x{1060}\x{1062}-\x{1064}\x{1067}-\x{106D}\x{1071}-\x{1074}\x{1082}\x{1083}-\x{1084}\x{1085}-\x{1086}\x{1087}-\x{108C}\x{108D}\x{108F}\x{109A}-\x{109C}\x{109D}\x{135D}-\x{135F}\x{1712}-\x{1714}\x{1732}-\x{1734}\x{1752}-\x{1753}\x{1772}-\x{1773}\x{17B4}-\x{17B5}\x{17B6}\x{17B7}-\x{17BD}\x{17BE}-\x{17C5}\x{17C6}\x{17C7}-\x{17C8}\x{17C9}-\x{17D3}\x{17DD}\x{180B}-\x{180D}\x{1885}-\x{1886}\x{18A9}\x{1920}-\x{1922}\x{1923}-\x{1926}\x{1927}-\x{1928}\x{1929}-\x{192B}\x{1930}-\x{1931}\x{1932}\x{1933}-\x{1938}\x{1939}-\x{193B}\x{1A17}-\x{1A18}\x{1A19}-\x{1A1A}\x{1A1B}\x{1A55}\x{1A56}\x{1A57}\x{1A58}-\x{1A5E}\x{1A60}\x{1A61}\x{1A62}\x{1A63}-\x{1A64}\x{1A65}-\x{1A6C}\x{1A6D}-\x{1A72}\x{1A73}-\x{1A7C}\x{1A7F}\x{1AB0}-\x{1ABD}\x{1ABE}\x{1ABF}-\x{1AC0}\x{1B00}-\x{1B03}\x{1B04}\x{1B34}\x{1B35}\x{1B36}-\x{1B3A}\x{1B3B}\x{1B3C}\x{1B3D}-\x{1B41}\x{1B42}\x{1B43}-\x{1B44}\x{1B6B}-\x{1B73}\x{1B80}-\x{1B81}\x{1B82}\x{1BA1}\x{1BA2}-\x{1BA5}\x{1BA6}-\x{1BA7}\x{1BA8}-\x{1BA9}\x{1BAA}\x{1BAB}-\x{1BAD}\x{1BE6}\x{1BE7}\x{1BE8}-\x{1BE9}\x{1BEA}-\x{1BEC}\x{1BED}\x{1BEE}\x{1BEF}-\x{1BF1}\x{1BF2}-\x{1BF3}\x{1C24}-\x{1C2B}\x{1C2C}-\x{1C33}\x{1C34}-\x{1C35}\x{1C36}-\x{1C37}\x{1CD0}-\x{1CD2}\x{1CD4}-\x{1CE0}\x{1CE1}\x{1CE2}-\x{1CE8}\x{1CED}\x{1CF4}\x{1CF7}\x{1CF8}-\x{1CF9}\x{1DC0}-\x{1DF9}\x{1DFB}-\x{1DFF}\x{20D0}-\x{20DC}\x{20DD}-\x{20E0}\x{20E1}\x{20E2}-\x{20E4}\x{20E5}-\x{20F0}\x{2CEF}-\x{2CF1}\x{2D7F}\x{2DE0}-\x{2DFF}\x{302A}-\x{302D}\x{302E}-\x{302F}\x{3099}-\x{309A}\x{A66F}\x{A670}-\x{A672}\x{A674}-\x{A67D}\x{A69E}-\x{A69F}\x{A6F0}-\x{A6F1}\x{A802}\x{A806}\x{A80B}\x{A823}-\x{A824}\x{A825}-\x{A826}\x{A827}\x{A82C}\x{A880}-\x{A881}\x{A8B4}-\x{A8C3}\x{A8C4}-\x{A8C5}\x{A8E0}-\x{A8F1}\x{A8FF}\x{A926}-\x{A92D}\x{A947}-\x{A951}\x{A952}-\x{A953}\x{A980}-\x{A982}\x{A983}\x{A9B3}\x{A9B4}-\x{A9B5}\x{A9B6}-\x{A9B9}\x{A9BA}-\x{A9BB}\x{A9BC}-\x{A9BD}\x{A9BE}-\x{A9C0}\x{A9E5}\x{AA29}-\x{AA2E}\x{AA2F}-\x{AA30}\x{AA31}-\x{AA32}\x{AA33}-\x{AA34}\x{AA35}-\x{AA36}\x{AA43}\x{AA4C}\x{AA4D}\x{AA7B}\x{AA7C}\x{AA7D}\x{AAB0}\x{AAB2}-\x{AAB4}\x{AAB7}-\x{AAB8}\x{AABE}-\x{AABF}\x{AAC1}\x{AAEB}\x{AAEC}-\x{AAED}\x{AAEE}-\x{AAEF}\x{AAF5}\x{AAF6}\x{ABE3}-\x{ABE4}\x{ABE5}\x{ABE6}-\x{ABE7}\x{ABE8}\x{ABE9}-\x{ABEA}\x{ABEC}\x{ABED}\x{FB1E}\x{FE00}-\x{FE0F}\x{FE20}-\x{FE2F}\x{101FD}\x{102E0}\x{10376}-\x{1037A}\x{10A01}-\x{10A03}\x{10A05}-\x{10A06}\x{10A0C}-\x{10A0F}\x{10A38}-\x{10A3A}\x{10A3F}\x{10AE5}-\x{10AE6}\x{10D24}-\x{10D27}\x{10EAB}-\x{10EAC}\x{10F46}-\x{10F50}\x{11000}\x{11001}\x{11002}\x{11038}-\x{11046}\x{1107F}-\x{11081}\x{11082}\x{110B0}-\x{110B2}\x{110B3}-\x{110B6}\x{110B7}-\x{110B8}\x{110B9}-\x{110BA}\x{11100}-\x{11102}\x{11127}-\x{1112B}\x{1112C}\x{1112D}-\x{11134}\x{11145}-\x{11146}\x{11173}\x{11180}-\x{11181}\x{11182}\x{111B3}-\x{111B5}\x{111B6}-\x{111BE}\x{111BF}-\x{111C0}\x{111C9}-\x{111CC}\x{111CE}\x{111CF}\x{1122C}-\x{1122E}\x{1122F}-\x{11231}\x{11232}-\x{11233}\x{11234}\x{11235}\x{11236}-\x{11237}\x{1123E}\x{112DF}\x{112E0}-\x{112E2}\x{112E3}-\x{112EA}\x{11300}-\x{11301}\x{11302}-\x{11303}\x{1133B}-\x{1133C}\x{1133E}-\x{1133F}\x{11340}\x{11341}-\x{11344}\x{11347}-\x{11348}\x{1134B}-\x{1134D}\x{11357}\x{11362}-\x{11363}\x{11366}-\x{1136C}\x{11370}-\x{11374}\x{11435}-\x{11437}\x{11438}-\x{1143F}\x{11440}-\x{11441}\x{11442}-\x{11444}\x{11445}\x{11446}\x{1145E}\x{114B0}-\x{114B2}\x{114B3}-\x{114B8}\x{114B9}\x{114BA}\x{114BB}-\x{114BE}\x{114BF}-\x{114C0}\x{114C1}\x{114C2}-\x{114C3}\x{115AF}-\x{115B1}\x{115B2}-\x{115B5}\x{115B8}-\x{115BB}\x{115BC}-\x{115BD}\x{115BE}\x{115BF}-\x{115C0}\x{115DC}-\x{115DD}\x{11630}-\x{11632}\x{11633}-\x{1163A}\x{1163B}-\x{1163C}\x{1163D}\x{1163E}\x{1163F}-\x{11640}\x{116AB}\x{116AC}\x{116AD}\x{116AE}-\x{116AF}\x{116B0}-\x{116B5}\x{116B6}\x{116B7}\x{1171D}-\x{1171F}\x{11720}-\x{11721}\x{11722}-\x{11725}\x{11726}\x{11727}-\x{1172B}\x{1182C}-\x{1182E}\x{1182F}-\x{11837}\x{11838}\x{11839}-\x{1183A}\x{11930}-\x{11935}\x{11937}-\x{11938}\x{1193B}-\x{1193C}\x{1193D}\x{1193E}\x{11940}\x{11942}\x{11943}\x{119D1}-\x{119D3}\x{119D4}-\x{119D7}\x{119DA}-\x{119DB}\x{119DC}-\x{119DF}\x{119E0}\x{119E4}\x{11A01}-\x{11A0A}\x{11A33}-\x{11A38}\x{11A39}\x{11A3B}-\x{11A3E}\x{11A47}\x{11A51}-\x{11A56}\x{11A57}-\x{11A58}\x{11A59}-\x{11A5B}\x{11A8A}-\x{11A96}\x{11A97}\x{11A98}-\x{11A99}\x{11C2F}\x{11C30}-\x{11C36}\x{11C38}-\x{11C3D}\x{11C3E}\x{11C3F}\x{11C92}-\x{11CA7}\x{11CA9}\x{11CAA}-\x{11CB0}\x{11CB1}\x{11CB2}-\x{11CB3}\x{11CB4}\x{11CB5}-\x{11CB6}\x{11D31}-\x{11D36}\x{11D3A}\x{11D3C}-\x{11D3D}\x{11D3F}-\x{11D45}\x{11D47}\x{11D8A}-\x{11D8E}\x{11D90}-\x{11D91}\x{11D93}-\x{11D94}\x{11D95}\x{11D96}\x{11D97}\x{11EF3}-\x{11EF4}\x{11EF5}-\x{11EF6}\x{16AF0}-\x{16AF4}\x{16B30}-\x{16B36}\x{16F4F}\x{16F51}-\x{16F87}\x{16F8F}-\x{16F92}\x{16FE4}\x{16FF0}-\x{16FF1}\x{1BC9D}-\x{1BC9E}\x{1D165}-\x{1D166}\x{1D167}-\x{1D169}\x{1D16D}-\x{1D172}\x{1D17B}-\x{1D182}\x{1D185}-\x{1D18B}\x{1D1AA}-\x{1D1AD}\x{1D242}-\x{1D244}\x{1DA00}-\x{1DA36}\x{1DA3B}-\x{1DA6C}\x{1DA75}\x{1DA84}\x{1DA9B}-\x{1DA9F}\x{1DAA1}-\x{1DAAF}\x{1E000}-\x{1E006}\x{1E008}-\x{1E018}\x{1E01B}-\x{1E021}\x{1E023}-\x{1E024}\x{1E026}-\x{1E02A}\x{1E130}-\x{1E136}\x{1E2EC}-\x{1E2EF}\x{1E8D0}-\x{1E8D6}\x{1E944}-\x{1E94A}\x{E0100}-\x{E01EF}]/u'; + const COMBINING_MARK = '/^[\x{0300}-\x{036F}\x{0483}-\x{0487}\x{0488}-\x{0489}\x{0591}-\x{05BD}\x{05BF}\x{05C1}-\x{05C2}\x{05C4}-\x{05C5}\x{05C7}\x{0610}-\x{061A}\x{064B}-\x{065F}\x{0670}\x{06D6}-\x{06DC}\x{06DF}-\x{06E4}\x{06E7}-\x{06E8}\x{06EA}-\x{06ED}\x{0711}\x{0730}-\x{074A}\x{07A6}-\x{07B0}\x{07EB}-\x{07F3}\x{07FD}\x{0816}-\x{0819}\x{081B}-\x{0823}\x{0825}-\x{0827}\x{0829}-\x{082D}\x{0859}-\x{085B}\x{08D3}-\x{08E1}\x{08E3}-\x{0902}\x{0903}\x{093A}\x{093B}\x{093C}\x{093E}-\x{0940}\x{0941}-\x{0948}\x{0949}-\x{094C}\x{094D}\x{094E}-\x{094F}\x{0951}-\x{0957}\x{0962}-\x{0963}\x{0981}\x{0982}-\x{0983}\x{09BC}\x{09BE}-\x{09C0}\x{09C1}-\x{09C4}\x{09C7}-\x{09C8}\x{09CB}-\x{09CC}\x{09CD}\x{09D7}\x{09E2}-\x{09E3}\x{09FE}\x{0A01}-\x{0A02}\x{0A03}\x{0A3C}\x{0A3E}-\x{0A40}\x{0A41}-\x{0A42}\x{0A47}-\x{0A48}\x{0A4B}-\x{0A4D}\x{0A51}\x{0A70}-\x{0A71}\x{0A75}\x{0A81}-\x{0A82}\x{0A83}\x{0ABC}\x{0ABE}-\x{0AC0}\x{0AC1}-\x{0AC5}\x{0AC7}-\x{0AC8}\x{0AC9}\x{0ACB}-\x{0ACC}\x{0ACD}\x{0AE2}-\x{0AE3}\x{0AFA}-\x{0AFF}\x{0B01}\x{0B02}-\x{0B03}\x{0B3C}\x{0B3E}\x{0B3F}\x{0B40}\x{0B41}-\x{0B44}\x{0B47}-\x{0B48}\x{0B4B}-\x{0B4C}\x{0B4D}\x{0B55}-\x{0B56}\x{0B57}\x{0B62}-\x{0B63}\x{0B82}\x{0BBE}-\x{0BBF}\x{0BC0}\x{0BC1}-\x{0BC2}\x{0BC6}-\x{0BC8}\x{0BCA}-\x{0BCC}\x{0BCD}\x{0BD7}\x{0C00}\x{0C01}-\x{0C03}\x{0C04}\x{0C3E}-\x{0C40}\x{0C41}-\x{0C44}\x{0C46}-\x{0C48}\x{0C4A}-\x{0C4D}\x{0C55}-\x{0C56}\x{0C62}-\x{0C63}\x{0C81}\x{0C82}-\x{0C83}\x{0CBC}\x{0CBE}\x{0CBF}\x{0CC0}-\x{0CC4}\x{0CC6}\x{0CC7}-\x{0CC8}\x{0CCA}-\x{0CCB}\x{0CCC}-\x{0CCD}\x{0CD5}-\x{0CD6}\x{0CE2}-\x{0CE3}\x{0D00}-\x{0D01}\x{0D02}-\x{0D03}\x{0D3B}-\x{0D3C}\x{0D3E}-\x{0D40}\x{0D41}-\x{0D44}\x{0D46}-\x{0D48}\x{0D4A}-\x{0D4C}\x{0D4D}\x{0D57}\x{0D62}-\x{0D63}\x{0D81}\x{0D82}-\x{0D83}\x{0DCA}\x{0DCF}-\x{0DD1}\x{0DD2}-\x{0DD4}\x{0DD6}\x{0DD8}-\x{0DDF}\x{0DF2}-\x{0DF3}\x{0E31}\x{0E34}-\x{0E3A}\x{0E47}-\x{0E4E}\x{0EB1}\x{0EB4}-\x{0EBC}\x{0EC8}-\x{0ECD}\x{0F18}-\x{0F19}\x{0F35}\x{0F37}\x{0F39}\x{0F3E}-\x{0F3F}\x{0F71}-\x{0F7E}\x{0F7F}\x{0F80}-\x{0F84}\x{0F86}-\x{0F87}\x{0F8D}-\x{0F97}\x{0F99}-\x{0FBC}\x{0FC6}\x{102B}-\x{102C}\x{102D}-\x{1030}\x{1031}\x{1032}-\x{1037}\x{1038}\x{1039}-\x{103A}\x{103B}-\x{103C}\x{103D}-\x{103E}\x{1056}-\x{1057}\x{1058}-\x{1059}\x{105E}-\x{1060}\x{1062}-\x{1064}\x{1067}-\x{106D}\x{1071}-\x{1074}\x{1082}\x{1083}-\x{1084}\x{1085}-\x{1086}\x{1087}-\x{108C}\x{108D}\x{108F}\x{109A}-\x{109C}\x{109D}\x{135D}-\x{135F}\x{1712}-\x{1714}\x{1732}-\x{1734}\x{1752}-\x{1753}\x{1772}-\x{1773}\x{17B4}-\x{17B5}\x{17B6}\x{17B7}-\x{17BD}\x{17BE}-\x{17C5}\x{17C6}\x{17C7}-\x{17C8}\x{17C9}-\x{17D3}\x{17DD}\x{180B}-\x{180D}\x{1885}-\x{1886}\x{18A9}\x{1920}-\x{1922}\x{1923}-\x{1926}\x{1927}-\x{1928}\x{1929}-\x{192B}\x{1930}-\x{1931}\x{1932}\x{1933}-\x{1938}\x{1939}-\x{193B}\x{1A17}-\x{1A18}\x{1A19}-\x{1A1A}\x{1A1B}\x{1A55}\x{1A56}\x{1A57}\x{1A58}-\x{1A5E}\x{1A60}\x{1A61}\x{1A62}\x{1A63}-\x{1A64}\x{1A65}-\x{1A6C}\x{1A6D}-\x{1A72}\x{1A73}-\x{1A7C}\x{1A7F}\x{1AB0}-\x{1ABD}\x{1ABE}\x{1ABF}-\x{1AC0}\x{1B00}-\x{1B03}\x{1B04}\x{1B34}\x{1B35}\x{1B36}-\x{1B3A}\x{1B3B}\x{1B3C}\x{1B3D}-\x{1B41}\x{1B42}\x{1B43}-\x{1B44}\x{1B6B}-\x{1B73}\x{1B80}-\x{1B81}\x{1B82}\x{1BA1}\x{1BA2}-\x{1BA5}\x{1BA6}-\x{1BA7}\x{1BA8}-\x{1BA9}\x{1BAA}\x{1BAB}-\x{1BAD}\x{1BE6}\x{1BE7}\x{1BE8}-\x{1BE9}\x{1BEA}-\x{1BEC}\x{1BED}\x{1BEE}\x{1BEF}-\x{1BF1}\x{1BF2}-\x{1BF3}\x{1C24}-\x{1C2B}\x{1C2C}-\x{1C33}\x{1C34}-\x{1C35}\x{1C36}-\x{1C37}\x{1CD0}-\x{1CD2}\x{1CD4}-\x{1CE0}\x{1CE1}\x{1CE2}-\x{1CE8}\x{1CED}\x{1CF4}\x{1CF7}\x{1CF8}-\x{1CF9}\x{1DC0}-\x{1DF9}\x{1DFB}-\x{1DFF}\x{20D0}-\x{20DC}\x{20DD}-\x{20E0}\x{20E1}\x{20E2}-\x{20E4}\x{20E5}-\x{20F0}\x{2CEF}-\x{2CF1}\x{2D7F}\x{2DE0}-\x{2DFF}\x{302A}-\x{302D}\x{302E}-\x{302F}\x{3099}-\x{309A}\x{A66F}\x{A670}-\x{A672}\x{A674}-\x{A67D}\x{A69E}-\x{A69F}\x{A6F0}-\x{A6F1}\x{A802}\x{A806}\x{A80B}\x{A823}-\x{A824}\x{A825}-\x{A826}\x{A827}\x{A82C}\x{A880}-\x{A881}\x{A8B4}-\x{A8C3}\x{A8C4}-\x{A8C5}\x{A8E0}-\x{A8F1}\x{A8FF}\x{A926}-\x{A92D}\x{A947}-\x{A951}\x{A952}-\x{A953}\x{A980}-\x{A982}\x{A983}\x{A9B3}\x{A9B4}-\x{A9B5}\x{A9B6}-\x{A9B9}\x{A9BA}-\x{A9BB}\x{A9BC}-\x{A9BD}\x{A9BE}-\x{A9C0}\x{A9E5}\x{AA29}-\x{AA2E}\x{AA2F}-\x{AA30}\x{AA31}-\x{AA32}\x{AA33}-\x{AA34}\x{AA35}-\x{AA36}\x{AA43}\x{AA4C}\x{AA4D}\x{AA7B}\x{AA7C}\x{AA7D}\x{AAB0}\x{AAB2}-\x{AAB4}\x{AAB7}-\x{AAB8}\x{AABE}-\x{AABF}\x{AAC1}\x{AAEB}\x{AAEC}-\x{AAED}\x{AAEE}-\x{AAEF}\x{AAF5}\x{AAF6}\x{ABE3}-\x{ABE4}\x{ABE5}\x{ABE6}-\x{ABE7}\x{ABE8}\x{ABE9}-\x{ABEA}\x{ABEC}\x{ABED}\x{FB1E}\x{FE00}-\x{FE0F}\x{FE20}-\x{FE2F}\x{101FD}\x{102E0}\x{10376}-\x{1037A}\x{10A01}-\x{10A03}\x{10A05}-\x{10A06}\x{10A0C}-\x{10A0F}\x{10A38}-\x{10A3A}\x{10A3F}\x{10AE5}-\x{10AE6}\x{10D24}-\x{10D27}\x{10EAB}-\x{10EAC}\x{10F46}-\x{10F50}\x{11000}\x{11001}\x{11002}\x{11038}-\x{11046}\x{1107F}-\x{11081}\x{11082}\x{110B0}-\x{110B2}\x{110B3}-\x{110B6}\x{110B7}-\x{110B8}\x{110B9}-\x{110BA}\x{11100}-\x{11102}\x{11127}-\x{1112B}\x{1112C}\x{1112D}-\x{11134}\x{11145}-\x{11146}\x{11173}\x{11180}-\x{11181}\x{11182}\x{111B3}-\x{111B5}\x{111B6}-\x{111BE}\x{111BF}-\x{111C0}\x{111C9}-\x{111CC}\x{111CE}\x{111CF}\x{1122C}-\x{1122E}\x{1122F}-\x{11231}\x{11232}-\x{11233}\x{11234}\x{11235}\x{11236}-\x{11237}\x{1123E}\x{112DF}\x{112E0}-\x{112E2}\x{112E3}-\x{112EA}\x{11300}-\x{11301}\x{11302}-\x{11303}\x{1133B}-\x{1133C}\x{1133E}-\x{1133F}\x{11340}\x{11341}-\x{11344}\x{11347}-\x{11348}\x{1134B}-\x{1134D}\x{11357}\x{11362}-\x{11363}\x{11366}-\x{1136C}\x{11370}-\x{11374}\x{11435}-\x{11437}\x{11438}-\x{1143F}\x{11440}-\x{11441}\x{11442}-\x{11444}\x{11445}\x{11446}\x{1145E}\x{114B0}-\x{114B2}\x{114B3}-\x{114B8}\x{114B9}\x{114BA}\x{114BB}-\x{114BE}\x{114BF}-\x{114C0}\x{114C1}\x{114C2}-\x{114C3}\x{115AF}-\x{115B1}\x{115B2}-\x{115B5}\x{115B8}-\x{115BB}\x{115BC}-\x{115BD}\x{115BE}\x{115BF}-\x{115C0}\x{115DC}-\x{115DD}\x{11630}-\x{11632}\x{11633}-\x{1163A}\x{1163B}-\x{1163C}\x{1163D}\x{1163E}\x{1163F}-\x{11640}\x{116AB}\x{116AC}\x{116AD}\x{116AE}-\x{116AF}\x{116B0}-\x{116B5}\x{116B6}\x{116B7}\x{1171D}-\x{1171F}\x{11720}-\x{11721}\x{11722}-\x{11725}\x{11726}\x{11727}-\x{1172B}\x{1182C}-\x{1182E}\x{1182F}-\x{11837}\x{11838}\x{11839}-\x{1183A}\x{11930}-\x{11935}\x{11937}-\x{11938}\x{1193B}-\x{1193C}\x{1193D}\x{1193E}\x{11940}\x{11942}\x{11943}\x{119D1}-\x{119D3}\x{119D4}-\x{119D7}\x{119DA}-\x{119DB}\x{119DC}-\x{119DF}\x{119E0}\x{119E4}\x{11A01}-\x{11A0A}\x{11A33}-\x{11A38}\x{11A39}\x{11A3B}-\x{11A3E}\x{11A47}\x{11A51}-\x{11A56}\x{11A57}-\x{11A58}\x{11A59}-\x{11A5B}\x{11A8A}-\x{11A96}\x{11A97}\x{11A98}-\x{11A99}\x{11C2F}\x{11C30}-\x{11C36}\x{11C38}-\x{11C3D}\x{11C3E}\x{11C3F}\x{11C92}-\x{11CA7}\x{11CA9}\x{11CAA}-\x{11CB0}\x{11CB1}\x{11CB2}-\x{11CB3}\x{11CB4}\x{11CB5}-\x{11CB6}\x{11D31}-\x{11D36}\x{11D3A}\x{11D3C}-\x{11D3D}\x{11D3F}-\x{11D45}\x{11D47}\x{11D8A}-\x{11D8E}\x{11D90}-\x{11D91}\x{11D93}-\x{11D94}\x{11D95}\x{11D96}\x{11D97}\x{11EF3}-\x{11EF4}\x{11EF5}-\x{11EF6}\x{16AF0}-\x{16AF4}\x{16B30}-\x{16B36}\x{16F4F}\x{16F51}-\x{16F87}\x{16F8F}-\x{16F92}\x{16FE4}\x{16FF0}-\x{16FF1}\x{1BC9D}-\x{1BC9E}\x{1D165}-\x{1D166}\x{1D167}-\x{1D169}\x{1D16D}-\x{1D172}\x{1D17B}-\x{1D182}\x{1D185}-\x{1D18B}\x{1D1AA}-\x{1D1AD}\x{1D242}-\x{1D244}\x{1DA00}-\x{1DA36}\x{1DA3B}-\x{1DA6C}\x{1DA75}\x{1DA84}\x{1DA9B}-\x{1DA9F}\x{1DAA1}-\x{1DAAF}\x{1E000}-\x{1E006}\x{1E008}-\x{1E018}\x{1E01B}-\x{1E021}\x{1E023}-\x{1E024}\x{1E026}-\x{1E02A}\x{1E130}-\x{1E136}\x{1E2EC}-\x{1E2EF}\x{1E8D0}-\x{1E8D6}\x{1E944}-\x{1E94A}\x{E0100}-\x{E01EF}]/u'; - public const RTL_LABEL = '/[\x{0590}\x{05BE}\x{05C0}\x{05C3}\x{05C6}\x{05C8}-\x{05CF}\x{05D0}-\x{05EA}\x{05EB}-\x{05EE}\x{05EF}-\x{05F2}\x{05F3}-\x{05F4}\x{05F5}-\x{05FF}\x{0600}-\x{0605}\x{0608}\x{060B}\x{060D}\x{061B}\x{061C}\x{061D}\x{061E}-\x{061F}\x{0620}-\x{063F}\x{0640}\x{0641}-\x{064A}\x{0660}-\x{0669}\x{066B}-\x{066C}\x{066D}\x{066E}-\x{066F}\x{0671}-\x{06D3}\x{06D4}\x{06D5}\x{06DD}\x{06E5}-\x{06E6}\x{06EE}-\x{06EF}\x{06FA}-\x{06FC}\x{06FD}-\x{06FE}\x{06FF}\x{0700}-\x{070D}\x{070E}\x{070F}\x{0710}\x{0712}-\x{072F}\x{074B}-\x{074C}\x{074D}-\x{07A5}\x{07B1}\x{07B2}-\x{07BF}\x{07C0}-\x{07C9}\x{07CA}-\x{07EA}\x{07F4}-\x{07F5}\x{07FA}\x{07FB}-\x{07FC}\x{07FE}-\x{07FF}\x{0800}-\x{0815}\x{081A}\x{0824}\x{0828}\x{082E}-\x{082F}\x{0830}-\x{083E}\x{083F}\x{0840}-\x{0858}\x{085C}-\x{085D}\x{085E}\x{085F}\x{0860}-\x{086A}\x{086B}-\x{086F}\x{0870}-\x{089F}\x{08A0}-\x{08B4}\x{08B5}\x{08B6}-\x{08C7}\x{08C8}-\x{08D2}\x{08E2}\x{200F}\x{FB1D}\x{FB1F}-\x{FB28}\x{FB2A}-\x{FB36}\x{FB37}\x{FB38}-\x{FB3C}\x{FB3D}\x{FB3E}\x{FB3F}\x{FB40}-\x{FB41}\x{FB42}\x{FB43}-\x{FB44}\x{FB45}\x{FB46}-\x{FB4F}\x{FB50}-\x{FBB1}\x{FBB2}-\x{FBC1}\x{FBC2}-\x{FBD2}\x{FBD3}-\x{FD3D}\x{FD40}-\x{FD4F}\x{FD50}-\x{FD8F}\x{FD90}-\x{FD91}\x{FD92}-\x{FDC7}\x{FDC8}-\x{FDCF}\x{FDF0}-\x{FDFB}\x{FDFC}\x{FDFE}-\x{FDFF}\x{FE70}-\x{FE74}\x{FE75}\x{FE76}-\x{FEFC}\x{FEFD}-\x{FEFE}\x{10800}-\x{10805}\x{10806}-\x{10807}\x{10808}\x{10809}\x{1080A}-\x{10835}\x{10836}\x{10837}-\x{10838}\x{10839}-\x{1083B}\x{1083C}\x{1083D}-\x{1083E}\x{1083F}-\x{10855}\x{10856}\x{10857}\x{10858}-\x{1085F}\x{10860}-\x{10876}\x{10877}-\x{10878}\x{10879}-\x{1087F}\x{10880}-\x{1089E}\x{1089F}-\x{108A6}\x{108A7}-\x{108AF}\x{108B0}-\x{108DF}\x{108E0}-\x{108F2}\x{108F3}\x{108F4}-\x{108F5}\x{108F6}-\x{108FA}\x{108FB}-\x{108FF}\x{10900}-\x{10915}\x{10916}-\x{1091B}\x{1091C}-\x{1091E}\x{10920}-\x{10939}\x{1093A}-\x{1093E}\x{1093F}\x{10940}-\x{1097F}\x{10980}-\x{109B7}\x{109B8}-\x{109BB}\x{109BC}-\x{109BD}\x{109BE}-\x{109BF}\x{109C0}-\x{109CF}\x{109D0}-\x{109D1}\x{109D2}-\x{109FF}\x{10A00}\x{10A04}\x{10A07}-\x{10A0B}\x{10A10}-\x{10A13}\x{10A14}\x{10A15}-\x{10A17}\x{10A18}\x{10A19}-\x{10A35}\x{10A36}-\x{10A37}\x{10A3B}-\x{10A3E}\x{10A40}-\x{10A48}\x{10A49}-\x{10A4F}\x{10A50}-\x{10A58}\x{10A59}-\x{10A5F}\x{10A60}-\x{10A7C}\x{10A7D}-\x{10A7E}\x{10A7F}\x{10A80}-\x{10A9C}\x{10A9D}-\x{10A9F}\x{10AA0}-\x{10ABF}\x{10AC0}-\x{10AC7}\x{10AC8}\x{10AC9}-\x{10AE4}\x{10AE7}-\x{10AEA}\x{10AEB}-\x{10AEF}\x{10AF0}-\x{10AF6}\x{10AF7}-\x{10AFF}\x{10B00}-\x{10B35}\x{10B36}-\x{10B38}\x{10B40}-\x{10B55}\x{10B56}-\x{10B57}\x{10B58}-\x{10B5F}\x{10B60}-\x{10B72}\x{10B73}-\x{10B77}\x{10B78}-\x{10B7F}\x{10B80}-\x{10B91}\x{10B92}-\x{10B98}\x{10B99}-\x{10B9C}\x{10B9D}-\x{10BA8}\x{10BA9}-\x{10BAF}\x{10BB0}-\x{10BFF}\x{10C00}-\x{10C48}\x{10C49}-\x{10C7F}\x{10C80}-\x{10CB2}\x{10CB3}-\x{10CBF}\x{10CC0}-\x{10CF2}\x{10CF3}-\x{10CF9}\x{10CFA}-\x{10CFF}\x{10D00}-\x{10D23}\x{10D28}-\x{10D2F}\x{10D30}-\x{10D39}\x{10D3A}-\x{10D3F}\x{10D40}-\x{10E5F}\x{10E60}-\x{10E7E}\x{10E7F}\x{10E80}-\x{10EA9}\x{10EAA}\x{10EAD}\x{10EAE}-\x{10EAF}\x{10EB0}-\x{10EB1}\x{10EB2}-\x{10EFF}\x{10F00}-\x{10F1C}\x{10F1D}-\x{10F26}\x{10F27}\x{10F28}-\x{10F2F}\x{10F30}-\x{10F45}\x{10F51}-\x{10F54}\x{10F55}-\x{10F59}\x{10F5A}-\x{10F6F}\x{10F70}-\x{10FAF}\x{10FB0}-\x{10FC4}\x{10FC5}-\x{10FCB}\x{10FCC}-\x{10FDF}\x{10FE0}-\x{10FF6}\x{10FF7}-\x{10FFF}\x{1E800}-\x{1E8C4}\x{1E8C5}-\x{1E8C6}\x{1E8C7}-\x{1E8CF}\x{1E8D7}-\x{1E8FF}\x{1E900}-\x{1E943}\x{1E94B}\x{1E94C}-\x{1E94F}\x{1E950}-\x{1E959}\x{1E95A}-\x{1E95D}\x{1E95E}-\x{1E95F}\x{1E960}-\x{1EC6F}\x{1EC70}\x{1EC71}-\x{1ECAB}\x{1ECAC}\x{1ECAD}-\x{1ECAF}\x{1ECB0}\x{1ECB1}-\x{1ECB4}\x{1ECB5}-\x{1ECBF}\x{1ECC0}-\x{1ECFF}\x{1ED00}\x{1ED01}-\x{1ED2D}\x{1ED2E}\x{1ED2F}-\x{1ED3D}\x{1ED3E}-\x{1ED4F}\x{1ED50}-\x{1EDFF}\x{1EE00}-\x{1EE03}\x{1EE04}\x{1EE05}-\x{1EE1F}\x{1EE20}\x{1EE21}-\x{1EE22}\x{1EE23}\x{1EE24}\x{1EE25}-\x{1EE26}\x{1EE27}\x{1EE28}\x{1EE29}-\x{1EE32}\x{1EE33}\x{1EE34}-\x{1EE37}\x{1EE38}\x{1EE39}\x{1EE3A}\x{1EE3B}\x{1EE3C}-\x{1EE41}\x{1EE42}\x{1EE43}-\x{1EE46}\x{1EE47}\x{1EE48}\x{1EE49}\x{1EE4A}\x{1EE4B}\x{1EE4C}\x{1EE4D}-\x{1EE4F}\x{1EE50}\x{1EE51}-\x{1EE52}\x{1EE53}\x{1EE54}\x{1EE55}-\x{1EE56}\x{1EE57}\x{1EE58}\x{1EE59}\x{1EE5A}\x{1EE5B}\x{1EE5C}\x{1EE5D}\x{1EE5E}\x{1EE5F}\x{1EE60}\x{1EE61}-\x{1EE62}\x{1EE63}\x{1EE64}\x{1EE65}-\x{1EE66}\x{1EE67}-\x{1EE6A}\x{1EE6B}\x{1EE6C}-\x{1EE72}\x{1EE73}\x{1EE74}-\x{1EE77}\x{1EE78}\x{1EE79}-\x{1EE7C}\x{1EE7D}\x{1EE7E}\x{1EE7F}\x{1EE80}-\x{1EE89}\x{1EE8A}\x{1EE8B}-\x{1EE9B}\x{1EE9C}-\x{1EEA0}\x{1EEA1}-\x{1EEA3}\x{1EEA4}\x{1EEA5}-\x{1EEA9}\x{1EEAA}\x{1EEAB}-\x{1EEBB}\x{1EEBC}-\x{1EEEF}\x{1EEF2}-\x{1EEFF}\x{1EF00}-\x{1EFFF}]/u'; + const RTL_LABEL = '/[\x{0590}\x{05BE}\x{05C0}\x{05C3}\x{05C6}\x{05C8}-\x{05CF}\x{05D0}-\x{05EA}\x{05EB}-\x{05EE}\x{05EF}-\x{05F2}\x{05F3}-\x{05F4}\x{05F5}-\x{05FF}\x{0600}-\x{0605}\x{0608}\x{060B}\x{060D}\x{061B}\x{061C}\x{061D}\x{061E}-\x{061F}\x{0620}-\x{063F}\x{0640}\x{0641}-\x{064A}\x{0660}-\x{0669}\x{066B}-\x{066C}\x{066D}\x{066E}-\x{066F}\x{0671}-\x{06D3}\x{06D4}\x{06D5}\x{06DD}\x{06E5}-\x{06E6}\x{06EE}-\x{06EF}\x{06FA}-\x{06FC}\x{06FD}-\x{06FE}\x{06FF}\x{0700}-\x{070D}\x{070E}\x{070F}\x{0710}\x{0712}-\x{072F}\x{074B}-\x{074C}\x{074D}-\x{07A5}\x{07B1}\x{07B2}-\x{07BF}\x{07C0}-\x{07C9}\x{07CA}-\x{07EA}\x{07F4}-\x{07F5}\x{07FA}\x{07FB}-\x{07FC}\x{07FE}-\x{07FF}\x{0800}-\x{0815}\x{081A}\x{0824}\x{0828}\x{082E}-\x{082F}\x{0830}-\x{083E}\x{083F}\x{0840}-\x{0858}\x{085C}-\x{085D}\x{085E}\x{085F}\x{0860}-\x{086A}\x{086B}-\x{086F}\x{0870}-\x{089F}\x{08A0}-\x{08B4}\x{08B5}\x{08B6}-\x{08C7}\x{08C8}-\x{08D2}\x{08E2}\x{200F}\x{FB1D}\x{FB1F}-\x{FB28}\x{FB2A}-\x{FB36}\x{FB37}\x{FB38}-\x{FB3C}\x{FB3D}\x{FB3E}\x{FB3F}\x{FB40}-\x{FB41}\x{FB42}\x{FB43}-\x{FB44}\x{FB45}\x{FB46}-\x{FB4F}\x{FB50}-\x{FBB1}\x{FBB2}-\x{FBC1}\x{FBC2}-\x{FBD2}\x{FBD3}-\x{FD3D}\x{FD40}-\x{FD4F}\x{FD50}-\x{FD8F}\x{FD90}-\x{FD91}\x{FD92}-\x{FDC7}\x{FDC8}-\x{FDCF}\x{FDF0}-\x{FDFB}\x{FDFC}\x{FDFE}-\x{FDFF}\x{FE70}-\x{FE74}\x{FE75}\x{FE76}-\x{FEFC}\x{FEFD}-\x{FEFE}\x{10800}-\x{10805}\x{10806}-\x{10807}\x{10808}\x{10809}\x{1080A}-\x{10835}\x{10836}\x{10837}-\x{10838}\x{10839}-\x{1083B}\x{1083C}\x{1083D}-\x{1083E}\x{1083F}-\x{10855}\x{10856}\x{10857}\x{10858}-\x{1085F}\x{10860}-\x{10876}\x{10877}-\x{10878}\x{10879}-\x{1087F}\x{10880}-\x{1089E}\x{1089F}-\x{108A6}\x{108A7}-\x{108AF}\x{108B0}-\x{108DF}\x{108E0}-\x{108F2}\x{108F3}\x{108F4}-\x{108F5}\x{108F6}-\x{108FA}\x{108FB}-\x{108FF}\x{10900}-\x{10915}\x{10916}-\x{1091B}\x{1091C}-\x{1091E}\x{10920}-\x{10939}\x{1093A}-\x{1093E}\x{1093F}\x{10940}-\x{1097F}\x{10980}-\x{109B7}\x{109B8}-\x{109BB}\x{109BC}-\x{109BD}\x{109BE}-\x{109BF}\x{109C0}-\x{109CF}\x{109D0}-\x{109D1}\x{109D2}-\x{109FF}\x{10A00}\x{10A04}\x{10A07}-\x{10A0B}\x{10A10}-\x{10A13}\x{10A14}\x{10A15}-\x{10A17}\x{10A18}\x{10A19}-\x{10A35}\x{10A36}-\x{10A37}\x{10A3B}-\x{10A3E}\x{10A40}-\x{10A48}\x{10A49}-\x{10A4F}\x{10A50}-\x{10A58}\x{10A59}-\x{10A5F}\x{10A60}-\x{10A7C}\x{10A7D}-\x{10A7E}\x{10A7F}\x{10A80}-\x{10A9C}\x{10A9D}-\x{10A9F}\x{10AA0}-\x{10ABF}\x{10AC0}-\x{10AC7}\x{10AC8}\x{10AC9}-\x{10AE4}\x{10AE7}-\x{10AEA}\x{10AEB}-\x{10AEF}\x{10AF0}-\x{10AF6}\x{10AF7}-\x{10AFF}\x{10B00}-\x{10B35}\x{10B36}-\x{10B38}\x{10B40}-\x{10B55}\x{10B56}-\x{10B57}\x{10B58}-\x{10B5F}\x{10B60}-\x{10B72}\x{10B73}-\x{10B77}\x{10B78}-\x{10B7F}\x{10B80}-\x{10B91}\x{10B92}-\x{10B98}\x{10B99}-\x{10B9C}\x{10B9D}-\x{10BA8}\x{10BA9}-\x{10BAF}\x{10BB0}-\x{10BFF}\x{10C00}-\x{10C48}\x{10C49}-\x{10C7F}\x{10C80}-\x{10CB2}\x{10CB3}-\x{10CBF}\x{10CC0}-\x{10CF2}\x{10CF3}-\x{10CF9}\x{10CFA}-\x{10CFF}\x{10D00}-\x{10D23}\x{10D28}-\x{10D2F}\x{10D30}-\x{10D39}\x{10D3A}-\x{10D3F}\x{10D40}-\x{10E5F}\x{10E60}-\x{10E7E}\x{10E7F}\x{10E80}-\x{10EA9}\x{10EAA}\x{10EAD}\x{10EAE}-\x{10EAF}\x{10EB0}-\x{10EB1}\x{10EB2}-\x{10EFF}\x{10F00}-\x{10F1C}\x{10F1D}-\x{10F26}\x{10F27}\x{10F28}-\x{10F2F}\x{10F30}-\x{10F45}\x{10F51}-\x{10F54}\x{10F55}-\x{10F59}\x{10F5A}-\x{10F6F}\x{10F70}-\x{10FAF}\x{10FB0}-\x{10FC4}\x{10FC5}-\x{10FCB}\x{10FCC}-\x{10FDF}\x{10FE0}-\x{10FF6}\x{10FF7}-\x{10FFF}\x{1E800}-\x{1E8C4}\x{1E8C5}-\x{1E8C6}\x{1E8C7}-\x{1E8CF}\x{1E8D7}-\x{1E8FF}\x{1E900}-\x{1E943}\x{1E94B}\x{1E94C}-\x{1E94F}\x{1E950}-\x{1E959}\x{1E95A}-\x{1E95D}\x{1E95E}-\x{1E95F}\x{1E960}-\x{1EC6F}\x{1EC70}\x{1EC71}-\x{1ECAB}\x{1ECAC}\x{1ECAD}-\x{1ECAF}\x{1ECB0}\x{1ECB1}-\x{1ECB4}\x{1ECB5}-\x{1ECBF}\x{1ECC0}-\x{1ECFF}\x{1ED00}\x{1ED01}-\x{1ED2D}\x{1ED2E}\x{1ED2F}-\x{1ED3D}\x{1ED3E}-\x{1ED4F}\x{1ED50}-\x{1EDFF}\x{1EE00}-\x{1EE03}\x{1EE04}\x{1EE05}-\x{1EE1F}\x{1EE20}\x{1EE21}-\x{1EE22}\x{1EE23}\x{1EE24}\x{1EE25}-\x{1EE26}\x{1EE27}\x{1EE28}\x{1EE29}-\x{1EE32}\x{1EE33}\x{1EE34}-\x{1EE37}\x{1EE38}\x{1EE39}\x{1EE3A}\x{1EE3B}\x{1EE3C}-\x{1EE41}\x{1EE42}\x{1EE43}-\x{1EE46}\x{1EE47}\x{1EE48}\x{1EE49}\x{1EE4A}\x{1EE4B}\x{1EE4C}\x{1EE4D}-\x{1EE4F}\x{1EE50}\x{1EE51}-\x{1EE52}\x{1EE53}\x{1EE54}\x{1EE55}-\x{1EE56}\x{1EE57}\x{1EE58}\x{1EE59}\x{1EE5A}\x{1EE5B}\x{1EE5C}\x{1EE5D}\x{1EE5E}\x{1EE5F}\x{1EE60}\x{1EE61}-\x{1EE62}\x{1EE63}\x{1EE64}\x{1EE65}-\x{1EE66}\x{1EE67}-\x{1EE6A}\x{1EE6B}\x{1EE6C}-\x{1EE72}\x{1EE73}\x{1EE74}-\x{1EE77}\x{1EE78}\x{1EE79}-\x{1EE7C}\x{1EE7D}\x{1EE7E}\x{1EE7F}\x{1EE80}-\x{1EE89}\x{1EE8A}\x{1EE8B}-\x{1EE9B}\x{1EE9C}-\x{1EEA0}\x{1EEA1}-\x{1EEA3}\x{1EEA4}\x{1EEA5}-\x{1EEA9}\x{1EEAA}\x{1EEAB}-\x{1EEBB}\x{1EEBC}-\x{1EEEF}\x{1EEF2}-\x{1EEFF}\x{1EF00}-\x{1EFFF}]/u'; - public const BIDI_STEP_1_LTR = '/^[^\x{0000}-\x{0008}\x{0009}\x{000A}\x{000B}\x{000C}\x{000D}\x{000E}-\x{001B}\x{001C}-\x{001E}\x{001F}\x{0020}\x{0021}-\x{0022}\x{0023}\x{0024}\x{0025}\x{0026}-\x{0027}\x{0028}\x{0029}\x{002A}\x{002B}\x{002C}\x{002D}\x{002E}-\x{002F}\x{0030}-\x{0039}\x{003A}\x{003B}\x{003C}-\x{003E}\x{003F}-\x{0040}\x{005B}\x{005C}\x{005D}\x{005E}\x{005F}\x{0060}\x{007B}\x{007C}\x{007D}\x{007E}\x{007F}-\x{0084}\x{0085}\x{0086}-\x{009F}\x{00A0}\x{00A1}\x{00A2}-\x{00A5}\x{00A6}\x{00A7}\x{00A8}\x{00A9}\x{00AB}\x{00AC}\x{00AD}\x{00AE}\x{00AF}\x{00B0}\x{00B1}\x{00B2}-\x{00B3}\x{00B4}\x{00B6}-\x{00B7}\x{00B8}\x{00B9}\x{00BB}\x{00BC}-\x{00BE}\x{00BF}\x{00D7}\x{00F7}\x{02B9}-\x{02BA}\x{02C2}-\x{02C5}\x{02C6}-\x{02CF}\x{02D2}-\x{02DF}\x{02E5}-\x{02EB}\x{02EC}\x{02ED}\x{02EF}-\x{02FF}\x{0300}-\x{036F}\x{0374}\x{0375}\x{037E}\x{0384}-\x{0385}\x{0387}\x{03F6}\x{0483}-\x{0487}\x{0488}-\x{0489}\x{058A}\x{058D}-\x{058E}\x{058F}\x{0590}\x{0591}-\x{05BD}\x{05BE}\x{05BF}\x{05C0}\x{05C1}-\x{05C2}\x{05C3}\x{05C4}-\x{05C5}\x{05C6}\x{05C7}\x{05C8}-\x{05CF}\x{05D0}-\x{05EA}\x{05EB}-\x{05EE}\x{05EF}-\x{05F2}\x{05F3}-\x{05F4}\x{05F5}-\x{05FF}\x{0600}-\x{0605}\x{0606}-\x{0607}\x{0608}\x{0609}-\x{060A}\x{060B}\x{060C}\x{060D}\x{060E}-\x{060F}\x{0610}-\x{061A}\x{061B}\x{061C}\x{061D}\x{061E}-\x{061F}\x{0620}-\x{063F}\x{0640}\x{0641}-\x{064A}\x{064B}-\x{065F}\x{0660}-\x{0669}\x{066A}\x{066B}-\x{066C}\x{066D}\x{066E}-\x{066F}\x{0670}\x{0671}-\x{06D3}\x{06D4}\x{06D5}\x{06D6}-\x{06DC}\x{06DD}\x{06DE}\x{06DF}-\x{06E4}\x{06E5}-\x{06E6}\x{06E7}-\x{06E8}\x{06E9}\x{06EA}-\x{06ED}\x{06EE}-\x{06EF}\x{06F0}-\x{06F9}\x{06FA}-\x{06FC}\x{06FD}-\x{06FE}\x{06FF}\x{0700}-\x{070D}\x{070E}\x{070F}\x{0710}\x{0711}\x{0712}-\x{072F}\x{0730}-\x{074A}\x{074B}-\x{074C}\x{074D}-\x{07A5}\x{07A6}-\x{07B0}\x{07B1}\x{07B2}-\x{07BF}\x{07C0}-\x{07C9}\x{07CA}-\x{07EA}\x{07EB}-\x{07F3}\x{07F4}-\x{07F5}\x{07F6}\x{07F7}-\x{07F9}\x{07FA}\x{07FB}-\x{07FC}\x{07FD}\x{07FE}-\x{07FF}\x{0800}-\x{0815}\x{0816}-\x{0819}\x{081A}\x{081B}-\x{0823}\x{0824}\x{0825}-\x{0827}\x{0828}\x{0829}-\x{082D}\x{082E}-\x{082F}\x{0830}-\x{083E}\x{083F}\x{0840}-\x{0858}\x{0859}-\x{085B}\x{085C}-\x{085D}\x{085E}\x{085F}\x{0860}-\x{086A}\x{086B}-\x{086F}\x{0870}-\x{089F}\x{08A0}-\x{08B4}\x{08B5}\x{08B6}-\x{08C7}\x{08C8}-\x{08D2}\x{08D3}-\x{08E1}\x{08E2}\x{08E3}-\x{0902}\x{093A}\x{093C}\x{0941}-\x{0948}\x{094D}\x{0951}-\x{0957}\x{0962}-\x{0963}\x{0981}\x{09BC}\x{09C1}-\x{09C4}\x{09CD}\x{09E2}-\x{09E3}\x{09F2}-\x{09F3}\x{09FB}\x{09FE}\x{0A01}-\x{0A02}\x{0A3C}\x{0A41}-\x{0A42}\x{0A47}-\x{0A48}\x{0A4B}-\x{0A4D}\x{0A51}\x{0A70}-\x{0A71}\x{0A75}\x{0A81}-\x{0A82}\x{0ABC}\x{0AC1}-\x{0AC5}\x{0AC7}-\x{0AC8}\x{0ACD}\x{0AE2}-\x{0AE3}\x{0AF1}\x{0AFA}-\x{0AFF}\x{0B01}\x{0B3C}\x{0B3F}\x{0B41}-\x{0B44}\x{0B4D}\x{0B55}-\x{0B56}\x{0B62}-\x{0B63}\x{0B82}\x{0BC0}\x{0BCD}\x{0BF3}-\x{0BF8}\x{0BF9}\x{0BFA}\x{0C00}\x{0C04}\x{0C3E}-\x{0C40}\x{0C46}-\x{0C48}\x{0C4A}-\x{0C4D}\x{0C55}-\x{0C56}\x{0C62}-\x{0C63}\x{0C78}-\x{0C7E}\x{0C81}\x{0CBC}\x{0CCC}-\x{0CCD}\x{0CE2}-\x{0CE3}\x{0D00}-\x{0D01}\x{0D3B}-\x{0D3C}\x{0D41}-\x{0D44}\x{0D4D}\x{0D62}-\x{0D63}\x{0D81}\x{0DCA}\x{0DD2}-\x{0DD4}\x{0DD6}\x{0E31}\x{0E34}-\x{0E3A}\x{0E3F}\x{0E47}-\x{0E4E}\x{0EB1}\x{0EB4}-\x{0EBC}\x{0EC8}-\x{0ECD}\x{0F18}-\x{0F19}\x{0F35}\x{0F37}\x{0F39}\x{0F3A}\x{0F3B}\x{0F3C}\x{0F3D}\x{0F71}-\x{0F7E}\x{0F80}-\x{0F84}\x{0F86}-\x{0F87}\x{0F8D}-\x{0F97}\x{0F99}-\x{0FBC}\x{0FC6}\x{102D}-\x{1030}\x{1032}-\x{1037}\x{1039}-\x{103A}\x{103D}-\x{103E}\x{1058}-\x{1059}\x{105E}-\x{1060}\x{1071}-\x{1074}\x{1082}\x{1085}-\x{1086}\x{108D}\x{109D}\x{135D}-\x{135F}\x{1390}-\x{1399}\x{1400}\x{1680}\x{169B}\x{169C}\x{1712}-\x{1714}\x{1732}-\x{1734}\x{1752}-\x{1753}\x{1772}-\x{1773}\x{17B4}-\x{17B5}\x{17B7}-\x{17BD}\x{17C6}\x{17C9}-\x{17D3}\x{17DB}\x{17DD}\x{17F0}-\x{17F9}\x{1800}-\x{1805}\x{1806}\x{1807}-\x{180A}\x{180B}-\x{180D}\x{180E}\x{1885}-\x{1886}\x{18A9}\x{1920}-\x{1922}\x{1927}-\x{1928}\x{1932}\x{1939}-\x{193B}\x{1940}\x{1944}-\x{1945}\x{19DE}-\x{19FF}\x{1A17}-\x{1A18}\x{1A1B}\x{1A56}\x{1A58}-\x{1A5E}\x{1A60}\x{1A62}\x{1A65}-\x{1A6C}\x{1A73}-\x{1A7C}\x{1A7F}\x{1AB0}-\x{1ABD}\x{1ABE}\x{1ABF}-\x{1AC0}\x{1B00}-\x{1B03}\x{1B34}\x{1B36}-\x{1B3A}\x{1B3C}\x{1B42}\x{1B6B}-\x{1B73}\x{1B80}-\x{1B81}\x{1BA2}-\x{1BA5}\x{1BA8}-\x{1BA9}\x{1BAB}-\x{1BAD}\x{1BE6}\x{1BE8}-\x{1BE9}\x{1BED}\x{1BEF}-\x{1BF1}\x{1C2C}-\x{1C33}\x{1C36}-\x{1C37}\x{1CD0}-\x{1CD2}\x{1CD4}-\x{1CE0}\x{1CE2}-\x{1CE8}\x{1CED}\x{1CF4}\x{1CF8}-\x{1CF9}\x{1DC0}-\x{1DF9}\x{1DFB}-\x{1DFF}\x{1FBD}\x{1FBF}-\x{1FC1}\x{1FCD}-\x{1FCF}\x{1FDD}-\x{1FDF}\x{1FED}-\x{1FEF}\x{1FFD}-\x{1FFE}\x{2000}-\x{200A}\x{200B}-\x{200D}\x{200F}\x{2010}-\x{2015}\x{2016}-\x{2017}\x{2018}\x{2019}\x{201A}\x{201B}-\x{201C}\x{201D}\x{201E}\x{201F}\x{2020}-\x{2027}\x{2028}\x{2029}\x{202A}\x{202B}\x{202C}\x{202D}\x{202E}\x{202F}\x{2030}-\x{2034}\x{2035}-\x{2038}\x{2039}\x{203A}\x{203B}-\x{203E}\x{203F}-\x{2040}\x{2041}-\x{2043}\x{2044}\x{2045}\x{2046}\x{2047}-\x{2051}\x{2052}\x{2053}\x{2054}\x{2055}-\x{205E}\x{205F}\x{2060}-\x{2064}\x{2065}\x{2066}\x{2067}\x{2068}\x{2069}\x{206A}-\x{206F}\x{2070}\x{2074}-\x{2079}\x{207A}-\x{207B}\x{207C}\x{207D}\x{207E}\x{2080}-\x{2089}\x{208A}-\x{208B}\x{208C}\x{208D}\x{208E}\x{20A0}-\x{20BF}\x{20C0}-\x{20CF}\x{20D0}-\x{20DC}\x{20DD}-\x{20E0}\x{20E1}\x{20E2}-\x{20E4}\x{20E5}-\x{20F0}\x{2100}-\x{2101}\x{2103}-\x{2106}\x{2108}-\x{2109}\x{2114}\x{2116}-\x{2117}\x{2118}\x{211E}-\x{2123}\x{2125}\x{2127}\x{2129}\x{212E}\x{213A}-\x{213B}\x{2140}-\x{2144}\x{214A}\x{214B}\x{214C}-\x{214D}\x{2150}-\x{215F}\x{2189}\x{218A}-\x{218B}\x{2190}-\x{2194}\x{2195}-\x{2199}\x{219A}-\x{219B}\x{219C}-\x{219F}\x{21A0}\x{21A1}-\x{21A2}\x{21A3}\x{21A4}-\x{21A5}\x{21A6}\x{21A7}-\x{21AD}\x{21AE}\x{21AF}-\x{21CD}\x{21CE}-\x{21CF}\x{21D0}-\x{21D1}\x{21D2}\x{21D3}\x{21D4}\x{21D5}-\x{21F3}\x{21F4}-\x{2211}\x{2212}\x{2213}\x{2214}-\x{22FF}\x{2300}-\x{2307}\x{2308}\x{2309}\x{230A}\x{230B}\x{230C}-\x{231F}\x{2320}-\x{2321}\x{2322}-\x{2328}\x{2329}\x{232A}\x{232B}-\x{2335}\x{237B}\x{237C}\x{237D}-\x{2394}\x{2396}-\x{239A}\x{239B}-\x{23B3}\x{23B4}-\x{23DB}\x{23DC}-\x{23E1}\x{23E2}-\x{2426}\x{2440}-\x{244A}\x{2460}-\x{2487}\x{2488}-\x{249B}\x{24EA}-\x{24FF}\x{2500}-\x{25B6}\x{25B7}\x{25B8}-\x{25C0}\x{25C1}\x{25C2}-\x{25F7}\x{25F8}-\x{25FF}\x{2600}-\x{266E}\x{266F}\x{2670}-\x{26AB}\x{26AD}-\x{2767}\x{2768}\x{2769}\x{276A}\x{276B}\x{276C}\x{276D}\x{276E}\x{276F}\x{2770}\x{2771}\x{2772}\x{2773}\x{2774}\x{2775}\x{2776}-\x{2793}\x{2794}-\x{27BF}\x{27C0}-\x{27C4}\x{27C5}\x{27C6}\x{27C7}-\x{27E5}\x{27E6}\x{27E7}\x{27E8}\x{27E9}\x{27EA}\x{27EB}\x{27EC}\x{27ED}\x{27EE}\x{27EF}\x{27F0}-\x{27FF}\x{2900}-\x{2982}\x{2983}\x{2984}\x{2985}\x{2986}\x{2987}\x{2988}\x{2989}\x{298A}\x{298B}\x{298C}\x{298D}\x{298E}\x{298F}\x{2990}\x{2991}\x{2992}\x{2993}\x{2994}\x{2995}\x{2996}\x{2997}\x{2998}\x{2999}-\x{29D7}\x{29D8}\x{29D9}\x{29DA}\x{29DB}\x{29DC}-\x{29FB}\x{29FC}\x{29FD}\x{29FE}-\x{2AFF}\x{2B00}-\x{2B2F}\x{2B30}-\x{2B44}\x{2B45}-\x{2B46}\x{2B47}-\x{2B4C}\x{2B4D}-\x{2B73}\x{2B76}-\x{2B95}\x{2B97}-\x{2BFF}\x{2CE5}-\x{2CEA}\x{2CEF}-\x{2CF1}\x{2CF9}-\x{2CFC}\x{2CFD}\x{2CFE}-\x{2CFF}\x{2D7F}\x{2DE0}-\x{2DFF}\x{2E00}-\x{2E01}\x{2E02}\x{2E03}\x{2E04}\x{2E05}\x{2E06}-\x{2E08}\x{2E09}\x{2E0A}\x{2E0B}\x{2E0C}\x{2E0D}\x{2E0E}-\x{2E16}\x{2E17}\x{2E18}-\x{2E19}\x{2E1A}\x{2E1B}\x{2E1C}\x{2E1D}\x{2E1E}-\x{2E1F}\x{2E20}\x{2E21}\x{2E22}\x{2E23}\x{2E24}\x{2E25}\x{2E26}\x{2E27}\x{2E28}\x{2E29}\x{2E2A}-\x{2E2E}\x{2E2F}\x{2E30}-\x{2E39}\x{2E3A}-\x{2E3B}\x{2E3C}-\x{2E3F}\x{2E40}\x{2E41}\x{2E42}\x{2E43}-\x{2E4F}\x{2E50}-\x{2E51}\x{2E52}\x{2E80}-\x{2E99}\x{2E9B}-\x{2EF3}\x{2F00}-\x{2FD5}\x{2FF0}-\x{2FFB}\x{3000}\x{3001}-\x{3003}\x{3004}\x{3008}\x{3009}\x{300A}\x{300B}\x{300C}\x{300D}\x{300E}\x{300F}\x{3010}\x{3011}\x{3012}-\x{3013}\x{3014}\x{3015}\x{3016}\x{3017}\x{3018}\x{3019}\x{301A}\x{301B}\x{301C}\x{301D}\x{301E}-\x{301F}\x{3020}\x{302A}-\x{302D}\x{3030}\x{3036}-\x{3037}\x{303D}\x{303E}-\x{303F}\x{3099}-\x{309A}\x{309B}-\x{309C}\x{30A0}\x{30FB}\x{31C0}-\x{31E3}\x{321D}-\x{321E}\x{3250}\x{3251}-\x{325F}\x{327C}-\x{327E}\x{32B1}-\x{32BF}\x{32CC}-\x{32CF}\x{3377}-\x{337A}\x{33DE}-\x{33DF}\x{33FF}\x{4DC0}-\x{4DFF}\x{A490}-\x{A4C6}\x{A60D}-\x{A60F}\x{A66F}\x{A670}-\x{A672}\x{A673}\x{A674}-\x{A67D}\x{A67E}\x{A67F}\x{A69E}-\x{A69F}\x{A6F0}-\x{A6F1}\x{A700}-\x{A716}\x{A717}-\x{A71F}\x{A720}-\x{A721}\x{A788}\x{A802}\x{A806}\x{A80B}\x{A825}-\x{A826}\x{A828}-\x{A82B}\x{A82C}\x{A838}\x{A839}\x{A874}-\x{A877}\x{A8C4}-\x{A8C5}\x{A8E0}-\x{A8F1}\x{A8FF}\x{A926}-\x{A92D}\x{A947}-\x{A951}\x{A980}-\x{A982}\x{A9B3}\x{A9B6}-\x{A9B9}\x{A9BC}-\x{A9BD}\x{A9E5}\x{AA29}-\x{AA2E}\x{AA31}-\x{AA32}\x{AA35}-\x{AA36}\x{AA43}\x{AA4C}\x{AA7C}\x{AAB0}\x{AAB2}-\x{AAB4}\x{AAB7}-\x{AAB8}\x{AABE}-\x{AABF}\x{AAC1}\x{AAEC}-\x{AAED}\x{AAF6}\x{AB6A}-\x{AB6B}\x{ABE5}\x{ABE8}\x{ABED}\x{FB1D}\x{FB1E}\x{FB1F}-\x{FB28}\x{FB29}\x{FB2A}-\x{FB36}\x{FB37}\x{FB38}-\x{FB3C}\x{FB3D}\x{FB3E}\x{FB3F}\x{FB40}-\x{FB41}\x{FB42}\x{FB43}-\x{FB44}\x{FB45}\x{FB46}-\x{FB4F}\x{FB50}-\x{FBB1}\x{FBB2}-\x{FBC1}\x{FBC2}-\x{FBD2}\x{FBD3}-\x{FD3D}\x{FD3E}\x{FD3F}\x{FD40}-\x{FD4F}\x{FD50}-\x{FD8F}\x{FD90}-\x{FD91}\x{FD92}-\x{FDC7}\x{FDC8}-\x{FDCF}\x{FDD0}-\x{FDEF}\x{FDF0}-\x{FDFB}\x{FDFC}\x{FDFD}\x{FDFE}-\x{FDFF}\x{FE00}-\x{FE0F}\x{FE10}-\x{FE16}\x{FE17}\x{FE18}\x{FE19}\x{FE20}-\x{FE2F}\x{FE30}\x{FE31}-\x{FE32}\x{FE33}-\x{FE34}\x{FE35}\x{FE36}\x{FE37}\x{FE38}\x{FE39}\x{FE3A}\x{FE3B}\x{FE3C}\x{FE3D}\x{FE3E}\x{FE3F}\x{FE40}\x{FE41}\x{FE42}\x{FE43}\x{FE44}\x{FE45}-\x{FE46}\x{FE47}\x{FE48}\x{FE49}-\x{FE4C}\x{FE4D}-\x{FE4F}\x{FE50}\x{FE51}\x{FE52}\x{FE54}\x{FE55}\x{FE56}-\x{FE57}\x{FE58}\x{FE59}\x{FE5A}\x{FE5B}\x{FE5C}\x{FE5D}\x{FE5E}\x{FE5F}\x{FE60}-\x{FE61}\x{FE62}\x{FE63}\x{FE64}-\x{FE66}\x{FE68}\x{FE69}\x{FE6A}\x{FE6B}\x{FE70}-\x{FE74}\x{FE75}\x{FE76}-\x{FEFC}\x{FEFD}-\x{FEFE}\x{FEFF}\x{FF01}-\x{FF02}\x{FF03}\x{FF04}\x{FF05}\x{FF06}-\x{FF07}\x{FF08}\x{FF09}\x{FF0A}\x{FF0B}\x{FF0C}\x{FF0D}\x{FF0E}-\x{FF0F}\x{FF10}-\x{FF19}\x{FF1A}\x{FF1B}\x{FF1C}-\x{FF1E}\x{FF1F}-\x{FF20}\x{FF3B}\x{FF3C}\x{FF3D}\x{FF3E}\x{FF3F}\x{FF40}\x{FF5B}\x{FF5C}\x{FF5D}\x{FF5E}\x{FF5F}\x{FF60}\x{FF61}\x{FF62}\x{FF63}\x{FF64}-\x{FF65}\x{FFE0}-\x{FFE1}\x{FFE2}\x{FFE3}\x{FFE4}\x{FFE5}-\x{FFE6}\x{FFE8}\x{FFE9}-\x{FFEC}\x{FFED}-\x{FFEE}\x{FFF0}-\x{FFF8}\x{FFF9}-\x{FFFB}\x{FFFC}-\x{FFFD}\x{FFFE}-\x{FFFF}\x{10101}\x{10140}-\x{10174}\x{10175}-\x{10178}\x{10179}-\x{10189}\x{1018A}-\x{1018B}\x{1018C}\x{10190}-\x{1019C}\x{101A0}\x{101FD}\x{102E0}\x{102E1}-\x{102FB}\x{10376}-\x{1037A}\x{10800}-\x{10805}\x{10806}-\x{10807}\x{10808}\x{10809}\x{1080A}-\x{10835}\x{10836}\x{10837}-\x{10838}\x{10839}-\x{1083B}\x{1083C}\x{1083D}-\x{1083E}\x{1083F}-\x{10855}\x{10856}\x{10857}\x{10858}-\x{1085F}\x{10860}-\x{10876}\x{10877}-\x{10878}\x{10879}-\x{1087F}\x{10880}-\x{1089E}\x{1089F}-\x{108A6}\x{108A7}-\x{108AF}\x{108B0}-\x{108DF}\x{108E0}-\x{108F2}\x{108F3}\x{108F4}-\x{108F5}\x{108F6}-\x{108FA}\x{108FB}-\x{108FF}\x{10900}-\x{10915}\x{10916}-\x{1091B}\x{1091C}-\x{1091E}\x{1091F}\x{10920}-\x{10939}\x{1093A}-\x{1093E}\x{1093F}\x{10940}-\x{1097F}\x{10980}-\x{109B7}\x{109B8}-\x{109BB}\x{109BC}-\x{109BD}\x{109BE}-\x{109BF}\x{109C0}-\x{109CF}\x{109D0}-\x{109D1}\x{109D2}-\x{109FF}\x{10A00}\x{10A01}-\x{10A03}\x{10A04}\x{10A05}-\x{10A06}\x{10A07}-\x{10A0B}\x{10A0C}-\x{10A0F}\x{10A10}-\x{10A13}\x{10A14}\x{10A15}-\x{10A17}\x{10A18}\x{10A19}-\x{10A35}\x{10A36}-\x{10A37}\x{10A38}-\x{10A3A}\x{10A3B}-\x{10A3E}\x{10A3F}\x{10A40}-\x{10A48}\x{10A49}-\x{10A4F}\x{10A50}-\x{10A58}\x{10A59}-\x{10A5F}\x{10A60}-\x{10A7C}\x{10A7D}-\x{10A7E}\x{10A7F}\x{10A80}-\x{10A9C}\x{10A9D}-\x{10A9F}\x{10AA0}-\x{10ABF}\x{10AC0}-\x{10AC7}\x{10AC8}\x{10AC9}-\x{10AE4}\x{10AE5}-\x{10AE6}\x{10AE7}-\x{10AEA}\x{10AEB}-\x{10AEF}\x{10AF0}-\x{10AF6}\x{10AF7}-\x{10AFF}\x{10B00}-\x{10B35}\x{10B36}-\x{10B38}\x{10B39}-\x{10B3F}\x{10B40}-\x{10B55}\x{10B56}-\x{10B57}\x{10B58}-\x{10B5F}\x{10B60}-\x{10B72}\x{10B73}-\x{10B77}\x{10B78}-\x{10B7F}\x{10B80}-\x{10B91}\x{10B92}-\x{10B98}\x{10B99}-\x{10B9C}\x{10B9D}-\x{10BA8}\x{10BA9}-\x{10BAF}\x{10BB0}-\x{10BFF}\x{10C00}-\x{10C48}\x{10C49}-\x{10C7F}\x{10C80}-\x{10CB2}\x{10CB3}-\x{10CBF}\x{10CC0}-\x{10CF2}\x{10CF3}-\x{10CF9}\x{10CFA}-\x{10CFF}\x{10D00}-\x{10D23}\x{10D24}-\x{10D27}\x{10D28}-\x{10D2F}\x{10D30}-\x{10D39}\x{10D3A}-\x{10D3F}\x{10D40}-\x{10E5F}\x{10E60}-\x{10E7E}\x{10E7F}\x{10E80}-\x{10EA9}\x{10EAA}\x{10EAB}-\x{10EAC}\x{10EAD}\x{10EAE}-\x{10EAF}\x{10EB0}-\x{10EB1}\x{10EB2}-\x{10EFF}\x{10F00}-\x{10F1C}\x{10F1D}-\x{10F26}\x{10F27}\x{10F28}-\x{10F2F}\x{10F30}-\x{10F45}\x{10F46}-\x{10F50}\x{10F51}-\x{10F54}\x{10F55}-\x{10F59}\x{10F5A}-\x{10F6F}\x{10F70}-\x{10FAF}\x{10FB0}-\x{10FC4}\x{10FC5}-\x{10FCB}\x{10FCC}-\x{10FDF}\x{10FE0}-\x{10FF6}\x{10FF7}-\x{10FFF}\x{11001}\x{11038}-\x{11046}\x{11052}-\x{11065}\x{1107F}-\x{11081}\x{110B3}-\x{110B6}\x{110B9}-\x{110BA}\x{11100}-\x{11102}\x{11127}-\x{1112B}\x{1112D}-\x{11134}\x{11173}\x{11180}-\x{11181}\x{111B6}-\x{111BE}\x{111C9}-\x{111CC}\x{111CF}\x{1122F}-\x{11231}\x{11234}\x{11236}-\x{11237}\x{1123E}\x{112DF}\x{112E3}-\x{112EA}\x{11300}-\x{11301}\x{1133B}-\x{1133C}\x{11340}\x{11366}-\x{1136C}\x{11370}-\x{11374}\x{11438}-\x{1143F}\x{11442}-\x{11444}\x{11446}\x{1145E}\x{114B3}-\x{114B8}\x{114BA}\x{114BF}-\x{114C0}\x{114C2}-\x{114C3}\x{115B2}-\x{115B5}\x{115BC}-\x{115BD}\x{115BF}-\x{115C0}\x{115DC}-\x{115DD}\x{11633}-\x{1163A}\x{1163D}\x{1163F}-\x{11640}\x{11660}-\x{1166C}\x{116AB}\x{116AD}\x{116B0}-\x{116B5}\x{116B7}\x{1171D}-\x{1171F}\x{11722}-\x{11725}\x{11727}-\x{1172B}\x{1182F}-\x{11837}\x{11839}-\x{1183A}\x{1193B}-\x{1193C}\x{1193E}\x{11943}\x{119D4}-\x{119D7}\x{119DA}-\x{119DB}\x{119E0}\x{11A01}-\x{11A06}\x{11A09}-\x{11A0A}\x{11A33}-\x{11A38}\x{11A3B}-\x{11A3E}\x{11A47}\x{11A51}-\x{11A56}\x{11A59}-\x{11A5B}\x{11A8A}-\x{11A96}\x{11A98}-\x{11A99}\x{11C30}-\x{11C36}\x{11C38}-\x{11C3D}\x{11C92}-\x{11CA7}\x{11CAA}-\x{11CB0}\x{11CB2}-\x{11CB3}\x{11CB5}-\x{11CB6}\x{11D31}-\x{11D36}\x{11D3A}\x{11D3C}-\x{11D3D}\x{11D3F}-\x{11D45}\x{11D47}\x{11D90}-\x{11D91}\x{11D95}\x{11D97}\x{11EF3}-\x{11EF4}\x{11FD5}-\x{11FDC}\x{11FDD}-\x{11FE0}\x{11FE1}-\x{11FF1}\x{16AF0}-\x{16AF4}\x{16B30}-\x{16B36}\x{16F4F}\x{16F8F}-\x{16F92}\x{16FE2}\x{16FE4}\x{1BC9D}-\x{1BC9E}\x{1BCA0}-\x{1BCA3}\x{1D167}-\x{1D169}\x{1D173}-\x{1D17A}\x{1D17B}-\x{1D182}\x{1D185}-\x{1D18B}\x{1D1AA}-\x{1D1AD}\x{1D200}-\x{1D241}\x{1D242}-\x{1D244}\x{1D245}\x{1D300}-\x{1D356}\x{1D6DB}\x{1D715}\x{1D74F}\x{1D789}\x{1D7C3}\x{1D7CE}-\x{1D7FF}\x{1DA00}-\x{1DA36}\x{1DA3B}-\x{1DA6C}\x{1DA75}\x{1DA84}\x{1DA9B}-\x{1DA9F}\x{1DAA1}-\x{1DAAF}\x{1E000}-\x{1E006}\x{1E008}-\x{1E018}\x{1E01B}-\x{1E021}\x{1E023}-\x{1E024}\x{1E026}-\x{1E02A}\x{1E130}-\x{1E136}\x{1E2EC}-\x{1E2EF}\x{1E2FF}\x{1E800}-\x{1E8C4}\x{1E8C5}-\x{1E8C6}\x{1E8C7}-\x{1E8CF}\x{1E8D0}-\x{1E8D6}\x{1E8D7}-\x{1E8FF}\x{1E900}-\x{1E943}\x{1E944}-\x{1E94A}\x{1E94B}\x{1E94C}-\x{1E94F}\x{1E950}-\x{1E959}\x{1E95A}-\x{1E95D}\x{1E95E}-\x{1E95F}\x{1E960}-\x{1EC6F}\x{1EC70}\x{1EC71}-\x{1ECAB}\x{1ECAC}\x{1ECAD}-\x{1ECAF}\x{1ECB0}\x{1ECB1}-\x{1ECB4}\x{1ECB5}-\x{1ECBF}\x{1ECC0}-\x{1ECFF}\x{1ED00}\x{1ED01}-\x{1ED2D}\x{1ED2E}\x{1ED2F}-\x{1ED3D}\x{1ED3E}-\x{1ED4F}\x{1ED50}-\x{1EDFF}\x{1EE00}-\x{1EE03}\x{1EE04}\x{1EE05}-\x{1EE1F}\x{1EE20}\x{1EE21}-\x{1EE22}\x{1EE23}\x{1EE24}\x{1EE25}-\x{1EE26}\x{1EE27}\x{1EE28}\x{1EE29}-\x{1EE32}\x{1EE33}\x{1EE34}-\x{1EE37}\x{1EE38}\x{1EE39}\x{1EE3A}\x{1EE3B}\x{1EE3C}-\x{1EE41}\x{1EE42}\x{1EE43}-\x{1EE46}\x{1EE47}\x{1EE48}\x{1EE49}\x{1EE4A}\x{1EE4B}\x{1EE4C}\x{1EE4D}-\x{1EE4F}\x{1EE50}\x{1EE51}-\x{1EE52}\x{1EE53}\x{1EE54}\x{1EE55}-\x{1EE56}\x{1EE57}\x{1EE58}\x{1EE59}\x{1EE5A}\x{1EE5B}\x{1EE5C}\x{1EE5D}\x{1EE5E}\x{1EE5F}\x{1EE60}\x{1EE61}-\x{1EE62}\x{1EE63}\x{1EE64}\x{1EE65}-\x{1EE66}\x{1EE67}-\x{1EE6A}\x{1EE6B}\x{1EE6C}-\x{1EE72}\x{1EE73}\x{1EE74}-\x{1EE77}\x{1EE78}\x{1EE79}-\x{1EE7C}\x{1EE7D}\x{1EE7E}\x{1EE7F}\x{1EE80}-\x{1EE89}\x{1EE8A}\x{1EE8B}-\x{1EE9B}\x{1EE9C}-\x{1EEA0}\x{1EEA1}-\x{1EEA3}\x{1EEA4}\x{1EEA5}-\x{1EEA9}\x{1EEAA}\x{1EEAB}-\x{1EEBB}\x{1EEBC}-\x{1EEEF}\x{1EEF0}-\x{1EEF1}\x{1EEF2}-\x{1EEFF}\x{1EF00}-\x{1EFFF}\x{1F000}-\x{1F02B}\x{1F030}-\x{1F093}\x{1F0A0}-\x{1F0AE}\x{1F0B1}-\x{1F0BF}\x{1F0C1}-\x{1F0CF}\x{1F0D1}-\x{1F0F5}\x{1F100}-\x{1F10A}\x{1F10B}-\x{1F10C}\x{1F10D}-\x{1F10F}\x{1F12F}\x{1F16A}-\x{1F16F}\x{1F1AD}\x{1F260}-\x{1F265}\x{1F300}-\x{1F3FA}\x{1F3FB}-\x{1F3FF}\x{1F400}-\x{1F6D7}\x{1F6E0}-\x{1F6EC}\x{1F6F0}-\x{1F6FC}\x{1F700}-\x{1F773}\x{1F780}-\x{1F7D8}\x{1F7E0}-\x{1F7EB}\x{1F800}-\x{1F80B}\x{1F810}-\x{1F847}\x{1F850}-\x{1F859}\x{1F860}-\x{1F887}\x{1F890}-\x{1F8AD}\x{1F8B0}-\x{1F8B1}\x{1F900}-\x{1F978}\x{1F97A}-\x{1F9CB}\x{1F9CD}-\x{1FA53}\x{1FA60}-\x{1FA6D}\x{1FA70}-\x{1FA74}\x{1FA78}-\x{1FA7A}\x{1FA80}-\x{1FA86}\x{1FA90}-\x{1FAA8}\x{1FAB0}-\x{1FAB6}\x{1FAC0}-\x{1FAC2}\x{1FAD0}-\x{1FAD6}\x{1FB00}-\x{1FB92}\x{1FB94}-\x{1FBCA}\x{1FBF0}-\x{1FBF9}\x{1FFFE}-\x{1FFFF}\x{2FFFE}-\x{2FFFF}\x{3FFFE}-\x{3FFFF}\x{4FFFE}-\x{4FFFF}\x{5FFFE}-\x{5FFFF}\x{6FFFE}-\x{6FFFF}\x{7FFFE}-\x{7FFFF}\x{8FFFE}-\x{8FFFF}\x{9FFFE}-\x{9FFFF}\x{AFFFE}-\x{AFFFF}\x{BFFFE}-\x{BFFFF}\x{CFFFE}-\x{CFFFF}\x{DFFFE}-\x{E0000}\x{E0001}\x{E0002}-\x{E001F}\x{E0020}-\x{E007F}\x{E0080}-\x{E00FF}\x{E0100}-\x{E01EF}\x{E01F0}-\x{E0FFF}\x{EFFFE}-\x{EFFFF}\x{FFFFE}-\x{FFFFF}\x{10FFFE}-\x{10FFFF}]/u'; - public const BIDI_STEP_1_RTL = '/^[\x{0590}\x{05BE}\x{05C0}\x{05C3}\x{05C6}\x{05C8}-\x{05CF}\x{05D0}-\x{05EA}\x{05EB}-\x{05EE}\x{05EF}-\x{05F2}\x{05F3}-\x{05F4}\x{05F5}-\x{05FF}\x{0608}\x{060B}\x{060D}\x{061B}\x{061C}\x{061D}\x{061E}-\x{061F}\x{0620}-\x{063F}\x{0640}\x{0641}-\x{064A}\x{066D}\x{066E}-\x{066F}\x{0671}-\x{06D3}\x{06D4}\x{06D5}\x{06E5}-\x{06E6}\x{06EE}-\x{06EF}\x{06FA}-\x{06FC}\x{06FD}-\x{06FE}\x{06FF}\x{0700}-\x{070D}\x{070E}\x{070F}\x{0710}\x{0712}-\x{072F}\x{074B}-\x{074C}\x{074D}-\x{07A5}\x{07B1}\x{07B2}-\x{07BF}\x{07C0}-\x{07C9}\x{07CA}-\x{07EA}\x{07F4}-\x{07F5}\x{07FA}\x{07FB}-\x{07FC}\x{07FE}-\x{07FF}\x{0800}-\x{0815}\x{081A}\x{0824}\x{0828}\x{082E}-\x{082F}\x{0830}-\x{083E}\x{083F}\x{0840}-\x{0858}\x{085C}-\x{085D}\x{085E}\x{085F}\x{0860}-\x{086A}\x{086B}-\x{086F}\x{0870}-\x{089F}\x{08A0}-\x{08B4}\x{08B5}\x{08B6}-\x{08C7}\x{08C8}-\x{08D2}\x{200F}\x{FB1D}\x{FB1F}-\x{FB28}\x{FB2A}-\x{FB36}\x{FB37}\x{FB38}-\x{FB3C}\x{FB3D}\x{FB3E}\x{FB3F}\x{FB40}-\x{FB41}\x{FB42}\x{FB43}-\x{FB44}\x{FB45}\x{FB46}-\x{FB4F}\x{FB50}-\x{FBB1}\x{FBB2}-\x{FBC1}\x{FBC2}-\x{FBD2}\x{FBD3}-\x{FD3D}\x{FD40}-\x{FD4F}\x{FD50}-\x{FD8F}\x{FD90}-\x{FD91}\x{FD92}-\x{FDC7}\x{FDC8}-\x{FDCF}\x{FDF0}-\x{FDFB}\x{FDFC}\x{FDFE}-\x{FDFF}\x{FE70}-\x{FE74}\x{FE75}\x{FE76}-\x{FEFC}\x{FEFD}-\x{FEFE}\x{10800}-\x{10805}\x{10806}-\x{10807}\x{10808}\x{10809}\x{1080A}-\x{10835}\x{10836}\x{10837}-\x{10838}\x{10839}-\x{1083B}\x{1083C}\x{1083D}-\x{1083E}\x{1083F}-\x{10855}\x{10856}\x{10857}\x{10858}-\x{1085F}\x{10860}-\x{10876}\x{10877}-\x{10878}\x{10879}-\x{1087F}\x{10880}-\x{1089E}\x{1089F}-\x{108A6}\x{108A7}-\x{108AF}\x{108B0}-\x{108DF}\x{108E0}-\x{108F2}\x{108F3}\x{108F4}-\x{108F5}\x{108F6}-\x{108FA}\x{108FB}-\x{108FF}\x{10900}-\x{10915}\x{10916}-\x{1091B}\x{1091C}-\x{1091E}\x{10920}-\x{10939}\x{1093A}-\x{1093E}\x{1093F}\x{10940}-\x{1097F}\x{10980}-\x{109B7}\x{109B8}-\x{109BB}\x{109BC}-\x{109BD}\x{109BE}-\x{109BF}\x{109C0}-\x{109CF}\x{109D0}-\x{109D1}\x{109D2}-\x{109FF}\x{10A00}\x{10A04}\x{10A07}-\x{10A0B}\x{10A10}-\x{10A13}\x{10A14}\x{10A15}-\x{10A17}\x{10A18}\x{10A19}-\x{10A35}\x{10A36}-\x{10A37}\x{10A3B}-\x{10A3E}\x{10A40}-\x{10A48}\x{10A49}-\x{10A4F}\x{10A50}-\x{10A58}\x{10A59}-\x{10A5F}\x{10A60}-\x{10A7C}\x{10A7D}-\x{10A7E}\x{10A7F}\x{10A80}-\x{10A9C}\x{10A9D}-\x{10A9F}\x{10AA0}-\x{10ABF}\x{10AC0}-\x{10AC7}\x{10AC8}\x{10AC9}-\x{10AE4}\x{10AE7}-\x{10AEA}\x{10AEB}-\x{10AEF}\x{10AF0}-\x{10AF6}\x{10AF7}-\x{10AFF}\x{10B00}-\x{10B35}\x{10B36}-\x{10B38}\x{10B40}-\x{10B55}\x{10B56}-\x{10B57}\x{10B58}-\x{10B5F}\x{10B60}-\x{10B72}\x{10B73}-\x{10B77}\x{10B78}-\x{10B7F}\x{10B80}-\x{10B91}\x{10B92}-\x{10B98}\x{10B99}-\x{10B9C}\x{10B9D}-\x{10BA8}\x{10BA9}-\x{10BAF}\x{10BB0}-\x{10BFF}\x{10C00}-\x{10C48}\x{10C49}-\x{10C7F}\x{10C80}-\x{10CB2}\x{10CB3}-\x{10CBF}\x{10CC0}-\x{10CF2}\x{10CF3}-\x{10CF9}\x{10CFA}-\x{10CFF}\x{10D00}-\x{10D23}\x{10D28}-\x{10D2F}\x{10D3A}-\x{10D3F}\x{10D40}-\x{10E5F}\x{10E7F}\x{10E80}-\x{10EA9}\x{10EAA}\x{10EAD}\x{10EAE}-\x{10EAF}\x{10EB0}-\x{10EB1}\x{10EB2}-\x{10EFF}\x{10F00}-\x{10F1C}\x{10F1D}-\x{10F26}\x{10F27}\x{10F28}-\x{10F2F}\x{10F30}-\x{10F45}\x{10F51}-\x{10F54}\x{10F55}-\x{10F59}\x{10F5A}-\x{10F6F}\x{10F70}-\x{10FAF}\x{10FB0}-\x{10FC4}\x{10FC5}-\x{10FCB}\x{10FCC}-\x{10FDF}\x{10FE0}-\x{10FF6}\x{10FF7}-\x{10FFF}\x{1E800}-\x{1E8C4}\x{1E8C5}-\x{1E8C6}\x{1E8C7}-\x{1E8CF}\x{1E8D7}-\x{1E8FF}\x{1E900}-\x{1E943}\x{1E94B}\x{1E94C}-\x{1E94F}\x{1E950}-\x{1E959}\x{1E95A}-\x{1E95D}\x{1E95E}-\x{1E95F}\x{1E960}-\x{1EC6F}\x{1EC70}\x{1EC71}-\x{1ECAB}\x{1ECAC}\x{1ECAD}-\x{1ECAF}\x{1ECB0}\x{1ECB1}-\x{1ECB4}\x{1ECB5}-\x{1ECBF}\x{1ECC0}-\x{1ECFF}\x{1ED00}\x{1ED01}-\x{1ED2D}\x{1ED2E}\x{1ED2F}-\x{1ED3D}\x{1ED3E}-\x{1ED4F}\x{1ED50}-\x{1EDFF}\x{1EE00}-\x{1EE03}\x{1EE04}\x{1EE05}-\x{1EE1F}\x{1EE20}\x{1EE21}-\x{1EE22}\x{1EE23}\x{1EE24}\x{1EE25}-\x{1EE26}\x{1EE27}\x{1EE28}\x{1EE29}-\x{1EE32}\x{1EE33}\x{1EE34}-\x{1EE37}\x{1EE38}\x{1EE39}\x{1EE3A}\x{1EE3B}\x{1EE3C}-\x{1EE41}\x{1EE42}\x{1EE43}-\x{1EE46}\x{1EE47}\x{1EE48}\x{1EE49}\x{1EE4A}\x{1EE4B}\x{1EE4C}\x{1EE4D}-\x{1EE4F}\x{1EE50}\x{1EE51}-\x{1EE52}\x{1EE53}\x{1EE54}\x{1EE55}-\x{1EE56}\x{1EE57}\x{1EE58}\x{1EE59}\x{1EE5A}\x{1EE5B}\x{1EE5C}\x{1EE5D}\x{1EE5E}\x{1EE5F}\x{1EE60}\x{1EE61}-\x{1EE62}\x{1EE63}\x{1EE64}\x{1EE65}-\x{1EE66}\x{1EE67}-\x{1EE6A}\x{1EE6B}\x{1EE6C}-\x{1EE72}\x{1EE73}\x{1EE74}-\x{1EE77}\x{1EE78}\x{1EE79}-\x{1EE7C}\x{1EE7D}\x{1EE7E}\x{1EE7F}\x{1EE80}-\x{1EE89}\x{1EE8A}\x{1EE8B}-\x{1EE9B}\x{1EE9C}-\x{1EEA0}\x{1EEA1}-\x{1EEA3}\x{1EEA4}\x{1EEA5}-\x{1EEA9}\x{1EEAA}\x{1EEAB}-\x{1EEBB}\x{1EEBC}-\x{1EEEF}\x{1EEF2}-\x{1EEFF}\x{1EF00}-\x{1EFFF}]/u'; - public const BIDI_STEP_2 = '/[^\x{0000}-\x{0008}\x{000E}-\x{001B}\x{0021}-\x{0022}\x{0023}\x{0024}\x{0025}\x{0026}-\x{0027}\x{0028}\x{0029}\x{002A}\x{002B}\x{002C}\x{002D}\x{002E}-\x{002F}\x{0030}-\x{0039}\x{003A}\x{003B}\x{003C}-\x{003E}\x{003F}-\x{0040}\x{005B}\x{005C}\x{005D}\x{005E}\x{005F}\x{0060}\x{007B}\x{007C}\x{007D}\x{007E}\x{007F}-\x{0084}\x{0086}-\x{009F}\x{00A0}\x{00A1}\x{00A2}-\x{00A5}\x{00A6}\x{00A7}\x{00A8}\x{00A9}\x{00AB}\x{00AC}\x{00AD}\x{00AE}\x{00AF}\x{00B0}\x{00B1}\x{00B2}-\x{00B3}\x{00B4}\x{00B6}-\x{00B7}\x{00B8}\x{00B9}\x{00BB}\x{00BC}-\x{00BE}\x{00BF}\x{00D7}\x{00F7}\x{02B9}-\x{02BA}\x{02C2}-\x{02C5}\x{02C6}-\x{02CF}\x{02D2}-\x{02DF}\x{02E5}-\x{02EB}\x{02EC}\x{02ED}\x{02EF}-\x{02FF}\x{0300}-\x{036F}\x{0374}\x{0375}\x{037E}\x{0384}-\x{0385}\x{0387}\x{03F6}\x{0483}-\x{0487}\x{0488}-\x{0489}\x{058A}\x{058D}-\x{058E}\x{058F}\x{0590}\x{0591}-\x{05BD}\x{05BE}\x{05BF}\x{05C0}\x{05C1}-\x{05C2}\x{05C3}\x{05C4}-\x{05C5}\x{05C6}\x{05C7}\x{05C8}-\x{05CF}\x{05D0}-\x{05EA}\x{05EB}-\x{05EE}\x{05EF}-\x{05F2}\x{05F3}-\x{05F4}\x{05F5}-\x{05FF}\x{0600}-\x{0605}\x{0606}-\x{0607}\x{0608}\x{0609}-\x{060A}\x{060B}\x{060C}\x{060D}\x{060E}-\x{060F}\x{0610}-\x{061A}\x{061B}\x{061C}\x{061D}\x{061E}-\x{061F}\x{0620}-\x{063F}\x{0640}\x{0641}-\x{064A}\x{064B}-\x{065F}\x{0660}-\x{0669}\x{066A}\x{066B}-\x{066C}\x{066D}\x{066E}-\x{066F}\x{0670}\x{0671}-\x{06D3}\x{06D4}\x{06D5}\x{06D6}-\x{06DC}\x{06DD}\x{06DE}\x{06DF}-\x{06E4}\x{06E5}-\x{06E6}\x{06E7}-\x{06E8}\x{06E9}\x{06EA}-\x{06ED}\x{06EE}-\x{06EF}\x{06F0}-\x{06F9}\x{06FA}-\x{06FC}\x{06FD}-\x{06FE}\x{06FF}\x{0700}-\x{070D}\x{070E}\x{070F}\x{0710}\x{0711}\x{0712}-\x{072F}\x{0730}-\x{074A}\x{074B}-\x{074C}\x{074D}-\x{07A5}\x{07A6}-\x{07B0}\x{07B1}\x{07B2}-\x{07BF}\x{07C0}-\x{07C9}\x{07CA}-\x{07EA}\x{07EB}-\x{07F3}\x{07F4}-\x{07F5}\x{07F6}\x{07F7}-\x{07F9}\x{07FA}\x{07FB}-\x{07FC}\x{07FD}\x{07FE}-\x{07FF}\x{0800}-\x{0815}\x{0816}-\x{0819}\x{081A}\x{081B}-\x{0823}\x{0824}\x{0825}-\x{0827}\x{0828}\x{0829}-\x{082D}\x{082E}-\x{082F}\x{0830}-\x{083E}\x{083F}\x{0840}-\x{0858}\x{0859}-\x{085B}\x{085C}-\x{085D}\x{085E}\x{085F}\x{0860}-\x{086A}\x{086B}-\x{086F}\x{0870}-\x{089F}\x{08A0}-\x{08B4}\x{08B5}\x{08B6}-\x{08C7}\x{08C8}-\x{08D2}\x{08D3}-\x{08E1}\x{08E2}\x{08E3}-\x{0902}\x{093A}\x{093C}\x{0941}-\x{0948}\x{094D}\x{0951}-\x{0957}\x{0962}-\x{0963}\x{0981}\x{09BC}\x{09C1}-\x{09C4}\x{09CD}\x{09E2}-\x{09E3}\x{09F2}-\x{09F3}\x{09FB}\x{09FE}\x{0A01}-\x{0A02}\x{0A3C}\x{0A41}-\x{0A42}\x{0A47}-\x{0A48}\x{0A4B}-\x{0A4D}\x{0A51}\x{0A70}-\x{0A71}\x{0A75}\x{0A81}-\x{0A82}\x{0ABC}\x{0AC1}-\x{0AC5}\x{0AC7}-\x{0AC8}\x{0ACD}\x{0AE2}-\x{0AE3}\x{0AF1}\x{0AFA}-\x{0AFF}\x{0B01}\x{0B3C}\x{0B3F}\x{0B41}-\x{0B44}\x{0B4D}\x{0B55}-\x{0B56}\x{0B62}-\x{0B63}\x{0B82}\x{0BC0}\x{0BCD}\x{0BF3}-\x{0BF8}\x{0BF9}\x{0BFA}\x{0C00}\x{0C04}\x{0C3E}-\x{0C40}\x{0C46}-\x{0C48}\x{0C4A}-\x{0C4D}\x{0C55}-\x{0C56}\x{0C62}-\x{0C63}\x{0C78}-\x{0C7E}\x{0C81}\x{0CBC}\x{0CCC}-\x{0CCD}\x{0CE2}-\x{0CE3}\x{0D00}-\x{0D01}\x{0D3B}-\x{0D3C}\x{0D41}-\x{0D44}\x{0D4D}\x{0D62}-\x{0D63}\x{0D81}\x{0DCA}\x{0DD2}-\x{0DD4}\x{0DD6}\x{0E31}\x{0E34}-\x{0E3A}\x{0E3F}\x{0E47}-\x{0E4E}\x{0EB1}\x{0EB4}-\x{0EBC}\x{0EC8}-\x{0ECD}\x{0F18}-\x{0F19}\x{0F35}\x{0F37}\x{0F39}\x{0F3A}\x{0F3B}\x{0F3C}\x{0F3D}\x{0F71}-\x{0F7E}\x{0F80}-\x{0F84}\x{0F86}-\x{0F87}\x{0F8D}-\x{0F97}\x{0F99}-\x{0FBC}\x{0FC6}\x{102D}-\x{1030}\x{1032}-\x{1037}\x{1039}-\x{103A}\x{103D}-\x{103E}\x{1058}-\x{1059}\x{105E}-\x{1060}\x{1071}-\x{1074}\x{1082}\x{1085}-\x{1086}\x{108D}\x{109D}\x{135D}-\x{135F}\x{1390}-\x{1399}\x{1400}\x{169B}\x{169C}\x{1712}-\x{1714}\x{1732}-\x{1734}\x{1752}-\x{1753}\x{1772}-\x{1773}\x{17B4}-\x{17B5}\x{17B7}-\x{17BD}\x{17C6}\x{17C9}-\x{17D3}\x{17DB}\x{17DD}\x{17F0}-\x{17F9}\x{1800}-\x{1805}\x{1806}\x{1807}-\x{180A}\x{180B}-\x{180D}\x{180E}\x{1885}-\x{1886}\x{18A9}\x{1920}-\x{1922}\x{1927}-\x{1928}\x{1932}\x{1939}-\x{193B}\x{1940}\x{1944}-\x{1945}\x{19DE}-\x{19FF}\x{1A17}-\x{1A18}\x{1A1B}\x{1A56}\x{1A58}-\x{1A5E}\x{1A60}\x{1A62}\x{1A65}-\x{1A6C}\x{1A73}-\x{1A7C}\x{1A7F}\x{1AB0}-\x{1ABD}\x{1ABE}\x{1ABF}-\x{1AC0}\x{1B00}-\x{1B03}\x{1B34}\x{1B36}-\x{1B3A}\x{1B3C}\x{1B42}\x{1B6B}-\x{1B73}\x{1B80}-\x{1B81}\x{1BA2}-\x{1BA5}\x{1BA8}-\x{1BA9}\x{1BAB}-\x{1BAD}\x{1BE6}\x{1BE8}-\x{1BE9}\x{1BED}\x{1BEF}-\x{1BF1}\x{1C2C}-\x{1C33}\x{1C36}-\x{1C37}\x{1CD0}-\x{1CD2}\x{1CD4}-\x{1CE0}\x{1CE2}-\x{1CE8}\x{1CED}\x{1CF4}\x{1CF8}-\x{1CF9}\x{1DC0}-\x{1DF9}\x{1DFB}-\x{1DFF}\x{1FBD}\x{1FBF}-\x{1FC1}\x{1FCD}-\x{1FCF}\x{1FDD}-\x{1FDF}\x{1FED}-\x{1FEF}\x{1FFD}-\x{1FFE}\x{200B}-\x{200D}\x{200F}\x{2010}-\x{2015}\x{2016}-\x{2017}\x{2018}\x{2019}\x{201A}\x{201B}-\x{201C}\x{201D}\x{201E}\x{201F}\x{2020}-\x{2027}\x{202F}\x{2030}-\x{2034}\x{2035}-\x{2038}\x{2039}\x{203A}\x{203B}-\x{203E}\x{203F}-\x{2040}\x{2041}-\x{2043}\x{2044}\x{2045}\x{2046}\x{2047}-\x{2051}\x{2052}\x{2053}\x{2054}\x{2055}-\x{205E}\x{2060}-\x{2064}\x{2065}\x{206A}-\x{206F}\x{2070}\x{2074}-\x{2079}\x{207A}-\x{207B}\x{207C}\x{207D}\x{207E}\x{2080}-\x{2089}\x{208A}-\x{208B}\x{208C}\x{208D}\x{208E}\x{20A0}-\x{20BF}\x{20C0}-\x{20CF}\x{20D0}-\x{20DC}\x{20DD}-\x{20E0}\x{20E1}\x{20E2}-\x{20E4}\x{20E5}-\x{20F0}\x{2100}-\x{2101}\x{2103}-\x{2106}\x{2108}-\x{2109}\x{2114}\x{2116}-\x{2117}\x{2118}\x{211E}-\x{2123}\x{2125}\x{2127}\x{2129}\x{212E}\x{213A}-\x{213B}\x{2140}-\x{2144}\x{214A}\x{214B}\x{214C}-\x{214D}\x{2150}-\x{215F}\x{2189}\x{218A}-\x{218B}\x{2190}-\x{2194}\x{2195}-\x{2199}\x{219A}-\x{219B}\x{219C}-\x{219F}\x{21A0}\x{21A1}-\x{21A2}\x{21A3}\x{21A4}-\x{21A5}\x{21A6}\x{21A7}-\x{21AD}\x{21AE}\x{21AF}-\x{21CD}\x{21CE}-\x{21CF}\x{21D0}-\x{21D1}\x{21D2}\x{21D3}\x{21D4}\x{21D5}-\x{21F3}\x{21F4}-\x{2211}\x{2212}\x{2213}\x{2214}-\x{22FF}\x{2300}-\x{2307}\x{2308}\x{2309}\x{230A}\x{230B}\x{230C}-\x{231F}\x{2320}-\x{2321}\x{2322}-\x{2328}\x{2329}\x{232A}\x{232B}-\x{2335}\x{237B}\x{237C}\x{237D}-\x{2394}\x{2396}-\x{239A}\x{239B}-\x{23B3}\x{23B4}-\x{23DB}\x{23DC}-\x{23E1}\x{23E2}-\x{2426}\x{2440}-\x{244A}\x{2460}-\x{2487}\x{2488}-\x{249B}\x{24EA}-\x{24FF}\x{2500}-\x{25B6}\x{25B7}\x{25B8}-\x{25C0}\x{25C1}\x{25C2}-\x{25F7}\x{25F8}-\x{25FF}\x{2600}-\x{266E}\x{266F}\x{2670}-\x{26AB}\x{26AD}-\x{2767}\x{2768}\x{2769}\x{276A}\x{276B}\x{276C}\x{276D}\x{276E}\x{276F}\x{2770}\x{2771}\x{2772}\x{2773}\x{2774}\x{2775}\x{2776}-\x{2793}\x{2794}-\x{27BF}\x{27C0}-\x{27C4}\x{27C5}\x{27C6}\x{27C7}-\x{27E5}\x{27E6}\x{27E7}\x{27E8}\x{27E9}\x{27EA}\x{27EB}\x{27EC}\x{27ED}\x{27EE}\x{27EF}\x{27F0}-\x{27FF}\x{2900}-\x{2982}\x{2983}\x{2984}\x{2985}\x{2986}\x{2987}\x{2988}\x{2989}\x{298A}\x{298B}\x{298C}\x{298D}\x{298E}\x{298F}\x{2990}\x{2991}\x{2992}\x{2993}\x{2994}\x{2995}\x{2996}\x{2997}\x{2998}\x{2999}-\x{29D7}\x{29D8}\x{29D9}\x{29DA}\x{29DB}\x{29DC}-\x{29FB}\x{29FC}\x{29FD}\x{29FE}-\x{2AFF}\x{2B00}-\x{2B2F}\x{2B30}-\x{2B44}\x{2B45}-\x{2B46}\x{2B47}-\x{2B4C}\x{2B4D}-\x{2B73}\x{2B76}-\x{2B95}\x{2B97}-\x{2BFF}\x{2CE5}-\x{2CEA}\x{2CEF}-\x{2CF1}\x{2CF9}-\x{2CFC}\x{2CFD}\x{2CFE}-\x{2CFF}\x{2D7F}\x{2DE0}-\x{2DFF}\x{2E00}-\x{2E01}\x{2E02}\x{2E03}\x{2E04}\x{2E05}\x{2E06}-\x{2E08}\x{2E09}\x{2E0A}\x{2E0B}\x{2E0C}\x{2E0D}\x{2E0E}-\x{2E16}\x{2E17}\x{2E18}-\x{2E19}\x{2E1A}\x{2E1B}\x{2E1C}\x{2E1D}\x{2E1E}-\x{2E1F}\x{2E20}\x{2E21}\x{2E22}\x{2E23}\x{2E24}\x{2E25}\x{2E26}\x{2E27}\x{2E28}\x{2E29}\x{2E2A}-\x{2E2E}\x{2E2F}\x{2E30}-\x{2E39}\x{2E3A}-\x{2E3B}\x{2E3C}-\x{2E3F}\x{2E40}\x{2E41}\x{2E42}\x{2E43}-\x{2E4F}\x{2E50}-\x{2E51}\x{2E52}\x{2E80}-\x{2E99}\x{2E9B}-\x{2EF3}\x{2F00}-\x{2FD5}\x{2FF0}-\x{2FFB}\x{3001}-\x{3003}\x{3004}\x{3008}\x{3009}\x{300A}\x{300B}\x{300C}\x{300D}\x{300E}\x{300F}\x{3010}\x{3011}\x{3012}-\x{3013}\x{3014}\x{3015}\x{3016}\x{3017}\x{3018}\x{3019}\x{301A}\x{301B}\x{301C}\x{301D}\x{301E}-\x{301F}\x{3020}\x{302A}-\x{302D}\x{3030}\x{3036}-\x{3037}\x{303D}\x{303E}-\x{303F}\x{3099}-\x{309A}\x{309B}-\x{309C}\x{30A0}\x{30FB}\x{31C0}-\x{31E3}\x{321D}-\x{321E}\x{3250}\x{3251}-\x{325F}\x{327C}-\x{327E}\x{32B1}-\x{32BF}\x{32CC}-\x{32CF}\x{3377}-\x{337A}\x{33DE}-\x{33DF}\x{33FF}\x{4DC0}-\x{4DFF}\x{A490}-\x{A4C6}\x{A60D}-\x{A60F}\x{A66F}\x{A670}-\x{A672}\x{A673}\x{A674}-\x{A67D}\x{A67E}\x{A67F}\x{A69E}-\x{A69F}\x{A6F0}-\x{A6F1}\x{A700}-\x{A716}\x{A717}-\x{A71F}\x{A720}-\x{A721}\x{A788}\x{A802}\x{A806}\x{A80B}\x{A825}-\x{A826}\x{A828}-\x{A82B}\x{A82C}\x{A838}\x{A839}\x{A874}-\x{A877}\x{A8C4}-\x{A8C5}\x{A8E0}-\x{A8F1}\x{A8FF}\x{A926}-\x{A92D}\x{A947}-\x{A951}\x{A980}-\x{A982}\x{A9B3}\x{A9B6}-\x{A9B9}\x{A9BC}-\x{A9BD}\x{A9E5}\x{AA29}-\x{AA2E}\x{AA31}-\x{AA32}\x{AA35}-\x{AA36}\x{AA43}\x{AA4C}\x{AA7C}\x{AAB0}\x{AAB2}-\x{AAB4}\x{AAB7}-\x{AAB8}\x{AABE}-\x{AABF}\x{AAC1}\x{AAEC}-\x{AAED}\x{AAF6}\x{AB6A}-\x{AB6B}\x{ABE5}\x{ABE8}\x{ABED}\x{FB1D}\x{FB1E}\x{FB1F}-\x{FB28}\x{FB29}\x{FB2A}-\x{FB36}\x{FB37}\x{FB38}-\x{FB3C}\x{FB3D}\x{FB3E}\x{FB3F}\x{FB40}-\x{FB41}\x{FB42}\x{FB43}-\x{FB44}\x{FB45}\x{FB46}-\x{FB4F}\x{FB50}-\x{FBB1}\x{FBB2}-\x{FBC1}\x{FBC2}-\x{FBD2}\x{FBD3}-\x{FD3D}\x{FD3E}\x{FD3F}\x{FD40}-\x{FD4F}\x{FD50}-\x{FD8F}\x{FD90}-\x{FD91}\x{FD92}-\x{FDC7}\x{FDC8}-\x{FDCF}\x{FDD0}-\x{FDEF}\x{FDF0}-\x{FDFB}\x{FDFC}\x{FDFD}\x{FDFE}-\x{FDFF}\x{FE00}-\x{FE0F}\x{FE10}-\x{FE16}\x{FE17}\x{FE18}\x{FE19}\x{FE20}-\x{FE2F}\x{FE30}\x{FE31}-\x{FE32}\x{FE33}-\x{FE34}\x{FE35}\x{FE36}\x{FE37}\x{FE38}\x{FE39}\x{FE3A}\x{FE3B}\x{FE3C}\x{FE3D}\x{FE3E}\x{FE3F}\x{FE40}\x{FE41}\x{FE42}\x{FE43}\x{FE44}\x{FE45}-\x{FE46}\x{FE47}\x{FE48}\x{FE49}-\x{FE4C}\x{FE4D}-\x{FE4F}\x{FE50}\x{FE51}\x{FE52}\x{FE54}\x{FE55}\x{FE56}-\x{FE57}\x{FE58}\x{FE59}\x{FE5A}\x{FE5B}\x{FE5C}\x{FE5D}\x{FE5E}\x{FE5F}\x{FE60}-\x{FE61}\x{FE62}\x{FE63}\x{FE64}-\x{FE66}\x{FE68}\x{FE69}\x{FE6A}\x{FE6B}\x{FE70}-\x{FE74}\x{FE75}\x{FE76}-\x{FEFC}\x{FEFD}-\x{FEFE}\x{FEFF}\x{FF01}-\x{FF02}\x{FF03}\x{FF04}\x{FF05}\x{FF06}-\x{FF07}\x{FF08}\x{FF09}\x{FF0A}\x{FF0B}\x{FF0C}\x{FF0D}\x{FF0E}-\x{FF0F}\x{FF10}-\x{FF19}\x{FF1A}\x{FF1B}\x{FF1C}-\x{FF1E}\x{FF1F}-\x{FF20}\x{FF3B}\x{FF3C}\x{FF3D}\x{FF3E}\x{FF3F}\x{FF40}\x{FF5B}\x{FF5C}\x{FF5D}\x{FF5E}\x{FF5F}\x{FF60}\x{FF61}\x{FF62}\x{FF63}\x{FF64}-\x{FF65}\x{FFE0}-\x{FFE1}\x{FFE2}\x{FFE3}\x{FFE4}\x{FFE5}-\x{FFE6}\x{FFE8}\x{FFE9}-\x{FFEC}\x{FFED}-\x{FFEE}\x{FFF0}-\x{FFF8}\x{FFF9}-\x{FFFB}\x{FFFC}-\x{FFFD}\x{FFFE}-\x{FFFF}\x{10101}\x{10140}-\x{10174}\x{10175}-\x{10178}\x{10179}-\x{10189}\x{1018A}-\x{1018B}\x{1018C}\x{10190}-\x{1019C}\x{101A0}\x{101FD}\x{102E0}\x{102E1}-\x{102FB}\x{10376}-\x{1037A}\x{10800}-\x{10805}\x{10806}-\x{10807}\x{10808}\x{10809}\x{1080A}-\x{10835}\x{10836}\x{10837}-\x{10838}\x{10839}-\x{1083B}\x{1083C}\x{1083D}-\x{1083E}\x{1083F}-\x{10855}\x{10856}\x{10857}\x{10858}-\x{1085F}\x{10860}-\x{10876}\x{10877}-\x{10878}\x{10879}-\x{1087F}\x{10880}-\x{1089E}\x{1089F}-\x{108A6}\x{108A7}-\x{108AF}\x{108B0}-\x{108DF}\x{108E0}-\x{108F2}\x{108F3}\x{108F4}-\x{108F5}\x{108F6}-\x{108FA}\x{108FB}-\x{108FF}\x{10900}-\x{10915}\x{10916}-\x{1091B}\x{1091C}-\x{1091E}\x{1091F}\x{10920}-\x{10939}\x{1093A}-\x{1093E}\x{1093F}\x{10940}-\x{1097F}\x{10980}-\x{109B7}\x{109B8}-\x{109BB}\x{109BC}-\x{109BD}\x{109BE}-\x{109BF}\x{109C0}-\x{109CF}\x{109D0}-\x{109D1}\x{109D2}-\x{109FF}\x{10A00}\x{10A01}-\x{10A03}\x{10A04}\x{10A05}-\x{10A06}\x{10A07}-\x{10A0B}\x{10A0C}-\x{10A0F}\x{10A10}-\x{10A13}\x{10A14}\x{10A15}-\x{10A17}\x{10A18}\x{10A19}-\x{10A35}\x{10A36}-\x{10A37}\x{10A38}-\x{10A3A}\x{10A3B}-\x{10A3E}\x{10A3F}\x{10A40}-\x{10A48}\x{10A49}-\x{10A4F}\x{10A50}-\x{10A58}\x{10A59}-\x{10A5F}\x{10A60}-\x{10A7C}\x{10A7D}-\x{10A7E}\x{10A7F}\x{10A80}-\x{10A9C}\x{10A9D}-\x{10A9F}\x{10AA0}-\x{10ABF}\x{10AC0}-\x{10AC7}\x{10AC8}\x{10AC9}-\x{10AE4}\x{10AE5}-\x{10AE6}\x{10AE7}-\x{10AEA}\x{10AEB}-\x{10AEF}\x{10AF0}-\x{10AF6}\x{10AF7}-\x{10AFF}\x{10B00}-\x{10B35}\x{10B36}-\x{10B38}\x{10B39}-\x{10B3F}\x{10B40}-\x{10B55}\x{10B56}-\x{10B57}\x{10B58}-\x{10B5F}\x{10B60}-\x{10B72}\x{10B73}-\x{10B77}\x{10B78}-\x{10B7F}\x{10B80}-\x{10B91}\x{10B92}-\x{10B98}\x{10B99}-\x{10B9C}\x{10B9D}-\x{10BA8}\x{10BA9}-\x{10BAF}\x{10BB0}-\x{10BFF}\x{10C00}-\x{10C48}\x{10C49}-\x{10C7F}\x{10C80}-\x{10CB2}\x{10CB3}-\x{10CBF}\x{10CC0}-\x{10CF2}\x{10CF3}-\x{10CF9}\x{10CFA}-\x{10CFF}\x{10D00}-\x{10D23}\x{10D24}-\x{10D27}\x{10D28}-\x{10D2F}\x{10D30}-\x{10D39}\x{10D3A}-\x{10D3F}\x{10D40}-\x{10E5F}\x{10E60}-\x{10E7E}\x{10E7F}\x{10E80}-\x{10EA9}\x{10EAA}\x{10EAB}-\x{10EAC}\x{10EAD}\x{10EAE}-\x{10EAF}\x{10EB0}-\x{10EB1}\x{10EB2}-\x{10EFF}\x{10F00}-\x{10F1C}\x{10F1D}-\x{10F26}\x{10F27}\x{10F28}-\x{10F2F}\x{10F30}-\x{10F45}\x{10F46}-\x{10F50}\x{10F51}-\x{10F54}\x{10F55}-\x{10F59}\x{10F5A}-\x{10F6F}\x{10F70}-\x{10FAF}\x{10FB0}-\x{10FC4}\x{10FC5}-\x{10FCB}\x{10FCC}-\x{10FDF}\x{10FE0}-\x{10FF6}\x{10FF7}-\x{10FFF}\x{11001}\x{11038}-\x{11046}\x{11052}-\x{11065}\x{1107F}-\x{11081}\x{110B3}-\x{110B6}\x{110B9}-\x{110BA}\x{11100}-\x{11102}\x{11127}-\x{1112B}\x{1112D}-\x{11134}\x{11173}\x{11180}-\x{11181}\x{111B6}-\x{111BE}\x{111C9}-\x{111CC}\x{111CF}\x{1122F}-\x{11231}\x{11234}\x{11236}-\x{11237}\x{1123E}\x{112DF}\x{112E3}-\x{112EA}\x{11300}-\x{11301}\x{1133B}-\x{1133C}\x{11340}\x{11366}-\x{1136C}\x{11370}-\x{11374}\x{11438}-\x{1143F}\x{11442}-\x{11444}\x{11446}\x{1145E}\x{114B3}-\x{114B8}\x{114BA}\x{114BF}-\x{114C0}\x{114C2}-\x{114C3}\x{115B2}-\x{115B5}\x{115BC}-\x{115BD}\x{115BF}-\x{115C0}\x{115DC}-\x{115DD}\x{11633}-\x{1163A}\x{1163D}\x{1163F}-\x{11640}\x{11660}-\x{1166C}\x{116AB}\x{116AD}\x{116B0}-\x{116B5}\x{116B7}\x{1171D}-\x{1171F}\x{11722}-\x{11725}\x{11727}-\x{1172B}\x{1182F}-\x{11837}\x{11839}-\x{1183A}\x{1193B}-\x{1193C}\x{1193E}\x{11943}\x{119D4}-\x{119D7}\x{119DA}-\x{119DB}\x{119E0}\x{11A01}-\x{11A06}\x{11A09}-\x{11A0A}\x{11A33}-\x{11A38}\x{11A3B}-\x{11A3E}\x{11A47}\x{11A51}-\x{11A56}\x{11A59}-\x{11A5B}\x{11A8A}-\x{11A96}\x{11A98}-\x{11A99}\x{11C30}-\x{11C36}\x{11C38}-\x{11C3D}\x{11C92}-\x{11CA7}\x{11CAA}-\x{11CB0}\x{11CB2}-\x{11CB3}\x{11CB5}-\x{11CB6}\x{11D31}-\x{11D36}\x{11D3A}\x{11D3C}-\x{11D3D}\x{11D3F}-\x{11D45}\x{11D47}\x{11D90}-\x{11D91}\x{11D95}\x{11D97}\x{11EF3}-\x{11EF4}\x{11FD5}-\x{11FDC}\x{11FDD}-\x{11FE0}\x{11FE1}-\x{11FF1}\x{16AF0}-\x{16AF4}\x{16B30}-\x{16B36}\x{16F4F}\x{16F8F}-\x{16F92}\x{16FE2}\x{16FE4}\x{1BC9D}-\x{1BC9E}\x{1BCA0}-\x{1BCA3}\x{1D167}-\x{1D169}\x{1D173}-\x{1D17A}\x{1D17B}-\x{1D182}\x{1D185}-\x{1D18B}\x{1D1AA}-\x{1D1AD}\x{1D200}-\x{1D241}\x{1D242}-\x{1D244}\x{1D245}\x{1D300}-\x{1D356}\x{1D6DB}\x{1D715}\x{1D74F}\x{1D789}\x{1D7C3}\x{1D7CE}-\x{1D7FF}\x{1DA00}-\x{1DA36}\x{1DA3B}-\x{1DA6C}\x{1DA75}\x{1DA84}\x{1DA9B}-\x{1DA9F}\x{1DAA1}-\x{1DAAF}\x{1E000}-\x{1E006}\x{1E008}-\x{1E018}\x{1E01B}-\x{1E021}\x{1E023}-\x{1E024}\x{1E026}-\x{1E02A}\x{1E130}-\x{1E136}\x{1E2EC}-\x{1E2EF}\x{1E2FF}\x{1E800}-\x{1E8C4}\x{1E8C5}-\x{1E8C6}\x{1E8C7}-\x{1E8CF}\x{1E8D0}-\x{1E8D6}\x{1E8D7}-\x{1E8FF}\x{1E900}-\x{1E943}\x{1E944}-\x{1E94A}\x{1E94B}\x{1E94C}-\x{1E94F}\x{1E950}-\x{1E959}\x{1E95A}-\x{1E95D}\x{1E95E}-\x{1E95F}\x{1E960}-\x{1EC6F}\x{1EC70}\x{1EC71}-\x{1ECAB}\x{1ECAC}\x{1ECAD}-\x{1ECAF}\x{1ECB0}\x{1ECB1}-\x{1ECB4}\x{1ECB5}-\x{1ECBF}\x{1ECC0}-\x{1ECFF}\x{1ED00}\x{1ED01}-\x{1ED2D}\x{1ED2E}\x{1ED2F}-\x{1ED3D}\x{1ED3E}-\x{1ED4F}\x{1ED50}-\x{1EDFF}\x{1EE00}-\x{1EE03}\x{1EE04}\x{1EE05}-\x{1EE1F}\x{1EE20}\x{1EE21}-\x{1EE22}\x{1EE23}\x{1EE24}\x{1EE25}-\x{1EE26}\x{1EE27}\x{1EE28}\x{1EE29}-\x{1EE32}\x{1EE33}\x{1EE34}-\x{1EE37}\x{1EE38}\x{1EE39}\x{1EE3A}\x{1EE3B}\x{1EE3C}-\x{1EE41}\x{1EE42}\x{1EE43}-\x{1EE46}\x{1EE47}\x{1EE48}\x{1EE49}\x{1EE4A}\x{1EE4B}\x{1EE4C}\x{1EE4D}-\x{1EE4F}\x{1EE50}\x{1EE51}-\x{1EE52}\x{1EE53}\x{1EE54}\x{1EE55}-\x{1EE56}\x{1EE57}\x{1EE58}\x{1EE59}\x{1EE5A}\x{1EE5B}\x{1EE5C}\x{1EE5D}\x{1EE5E}\x{1EE5F}\x{1EE60}\x{1EE61}-\x{1EE62}\x{1EE63}\x{1EE64}\x{1EE65}-\x{1EE66}\x{1EE67}-\x{1EE6A}\x{1EE6B}\x{1EE6C}-\x{1EE72}\x{1EE73}\x{1EE74}-\x{1EE77}\x{1EE78}\x{1EE79}-\x{1EE7C}\x{1EE7D}\x{1EE7E}\x{1EE7F}\x{1EE80}-\x{1EE89}\x{1EE8A}\x{1EE8B}-\x{1EE9B}\x{1EE9C}-\x{1EEA0}\x{1EEA1}-\x{1EEA3}\x{1EEA4}\x{1EEA5}-\x{1EEA9}\x{1EEAA}\x{1EEAB}-\x{1EEBB}\x{1EEBC}-\x{1EEEF}\x{1EEF0}-\x{1EEF1}\x{1EEF2}-\x{1EEFF}\x{1EF00}-\x{1EFFF}\x{1F000}-\x{1F02B}\x{1F030}-\x{1F093}\x{1F0A0}-\x{1F0AE}\x{1F0B1}-\x{1F0BF}\x{1F0C1}-\x{1F0CF}\x{1F0D1}-\x{1F0F5}\x{1F100}-\x{1F10A}\x{1F10B}-\x{1F10C}\x{1F10D}-\x{1F10F}\x{1F12F}\x{1F16A}-\x{1F16F}\x{1F1AD}\x{1F260}-\x{1F265}\x{1F300}-\x{1F3FA}\x{1F3FB}-\x{1F3FF}\x{1F400}-\x{1F6D7}\x{1F6E0}-\x{1F6EC}\x{1F6F0}-\x{1F6FC}\x{1F700}-\x{1F773}\x{1F780}-\x{1F7D8}\x{1F7E0}-\x{1F7EB}\x{1F800}-\x{1F80B}\x{1F810}-\x{1F847}\x{1F850}-\x{1F859}\x{1F860}-\x{1F887}\x{1F890}-\x{1F8AD}\x{1F8B0}-\x{1F8B1}\x{1F900}-\x{1F978}\x{1F97A}-\x{1F9CB}\x{1F9CD}-\x{1FA53}\x{1FA60}-\x{1FA6D}\x{1FA70}-\x{1FA74}\x{1FA78}-\x{1FA7A}\x{1FA80}-\x{1FA86}\x{1FA90}-\x{1FAA8}\x{1FAB0}-\x{1FAB6}\x{1FAC0}-\x{1FAC2}\x{1FAD0}-\x{1FAD6}\x{1FB00}-\x{1FB92}\x{1FB94}-\x{1FBCA}\x{1FBF0}-\x{1FBF9}\x{1FFFE}-\x{1FFFF}\x{2FFFE}-\x{2FFFF}\x{3FFFE}-\x{3FFFF}\x{4FFFE}-\x{4FFFF}\x{5FFFE}-\x{5FFFF}\x{6FFFE}-\x{6FFFF}\x{7FFFE}-\x{7FFFF}\x{8FFFE}-\x{8FFFF}\x{9FFFE}-\x{9FFFF}\x{AFFFE}-\x{AFFFF}\x{BFFFE}-\x{BFFFF}\x{CFFFE}-\x{CFFFF}\x{DFFFE}-\x{E0000}\x{E0001}\x{E0002}-\x{E001F}\x{E0020}-\x{E007F}\x{E0080}-\x{E00FF}\x{E0100}-\x{E01EF}\x{E01F0}-\x{E0FFF}\x{EFFFE}-\x{EFFFF}\x{FFFFE}-\x{FFFFF}\x{10FFFE}-\x{10FFFF}]/u'; - public const BIDI_STEP_3 = '/[\x{0030}-\x{0039}\x{00B2}-\x{00B3}\x{00B9}\x{0590}\x{05BE}\x{05C0}\x{05C3}\x{05C6}\x{05C8}-\x{05CF}\x{05D0}-\x{05EA}\x{05EB}-\x{05EE}\x{05EF}-\x{05F2}\x{05F3}-\x{05F4}\x{05F5}-\x{05FF}\x{0600}-\x{0605}\x{0608}\x{060B}\x{060D}\x{061B}\x{061C}\x{061D}\x{061E}-\x{061F}\x{0620}-\x{063F}\x{0640}\x{0641}-\x{064A}\x{0660}-\x{0669}\x{066B}-\x{066C}\x{066D}\x{066E}-\x{066F}\x{0671}-\x{06D3}\x{06D4}\x{06D5}\x{06DD}\x{06E5}-\x{06E6}\x{06EE}-\x{06EF}\x{06F0}-\x{06F9}\x{06FA}-\x{06FC}\x{06FD}-\x{06FE}\x{06FF}\x{0700}-\x{070D}\x{070E}\x{070F}\x{0710}\x{0712}-\x{072F}\x{074B}-\x{074C}\x{074D}-\x{07A5}\x{07B1}\x{07B2}-\x{07BF}\x{07C0}-\x{07C9}\x{07CA}-\x{07EA}\x{07F4}-\x{07F5}\x{07FA}\x{07FB}-\x{07FC}\x{07FE}-\x{07FF}\x{0800}-\x{0815}\x{081A}\x{0824}\x{0828}\x{082E}-\x{082F}\x{0830}-\x{083E}\x{083F}\x{0840}-\x{0858}\x{085C}-\x{085D}\x{085E}\x{085F}\x{0860}-\x{086A}\x{086B}-\x{086F}\x{0870}-\x{089F}\x{08A0}-\x{08B4}\x{08B5}\x{08B6}-\x{08C7}\x{08C8}-\x{08D2}\x{08E2}\x{200F}\x{2070}\x{2074}-\x{2079}\x{2080}-\x{2089}\x{2488}-\x{249B}\x{FB1D}\x{FB1F}-\x{FB28}\x{FB2A}-\x{FB36}\x{FB37}\x{FB38}-\x{FB3C}\x{FB3D}\x{FB3E}\x{FB3F}\x{FB40}-\x{FB41}\x{FB42}\x{FB43}-\x{FB44}\x{FB45}\x{FB46}-\x{FB4F}\x{FB50}-\x{FBB1}\x{FBB2}-\x{FBC1}\x{FBC2}-\x{FBD2}\x{FBD3}-\x{FD3D}\x{FD40}-\x{FD4F}\x{FD50}-\x{FD8F}\x{FD90}-\x{FD91}\x{FD92}-\x{FDC7}\x{FDC8}-\x{FDCF}\x{FDF0}-\x{FDFB}\x{FDFC}\x{FDFE}-\x{FDFF}\x{FE70}-\x{FE74}\x{FE75}\x{FE76}-\x{FEFC}\x{FEFD}-\x{FEFE}\x{FF10}-\x{FF19}\x{102E1}-\x{102FB}\x{10800}-\x{10805}\x{10806}-\x{10807}\x{10808}\x{10809}\x{1080A}-\x{10835}\x{10836}\x{10837}-\x{10838}\x{10839}-\x{1083B}\x{1083C}\x{1083D}-\x{1083E}\x{1083F}-\x{10855}\x{10856}\x{10857}\x{10858}-\x{1085F}\x{10860}-\x{10876}\x{10877}-\x{10878}\x{10879}-\x{1087F}\x{10880}-\x{1089E}\x{1089F}-\x{108A6}\x{108A7}-\x{108AF}\x{108B0}-\x{108DF}\x{108E0}-\x{108F2}\x{108F3}\x{108F4}-\x{108F5}\x{108F6}-\x{108FA}\x{108FB}-\x{108FF}\x{10900}-\x{10915}\x{10916}-\x{1091B}\x{1091C}-\x{1091E}\x{10920}-\x{10939}\x{1093A}-\x{1093E}\x{1093F}\x{10940}-\x{1097F}\x{10980}-\x{109B7}\x{109B8}-\x{109BB}\x{109BC}-\x{109BD}\x{109BE}-\x{109BF}\x{109C0}-\x{109CF}\x{109D0}-\x{109D1}\x{109D2}-\x{109FF}\x{10A00}\x{10A04}\x{10A07}-\x{10A0B}\x{10A10}-\x{10A13}\x{10A14}\x{10A15}-\x{10A17}\x{10A18}\x{10A19}-\x{10A35}\x{10A36}-\x{10A37}\x{10A3B}-\x{10A3E}\x{10A40}-\x{10A48}\x{10A49}-\x{10A4F}\x{10A50}-\x{10A58}\x{10A59}-\x{10A5F}\x{10A60}-\x{10A7C}\x{10A7D}-\x{10A7E}\x{10A7F}\x{10A80}-\x{10A9C}\x{10A9D}-\x{10A9F}\x{10AA0}-\x{10ABF}\x{10AC0}-\x{10AC7}\x{10AC8}\x{10AC9}-\x{10AE4}\x{10AE7}-\x{10AEA}\x{10AEB}-\x{10AEF}\x{10AF0}-\x{10AF6}\x{10AF7}-\x{10AFF}\x{10B00}-\x{10B35}\x{10B36}-\x{10B38}\x{10B40}-\x{10B55}\x{10B56}-\x{10B57}\x{10B58}-\x{10B5F}\x{10B60}-\x{10B72}\x{10B73}-\x{10B77}\x{10B78}-\x{10B7F}\x{10B80}-\x{10B91}\x{10B92}-\x{10B98}\x{10B99}-\x{10B9C}\x{10B9D}-\x{10BA8}\x{10BA9}-\x{10BAF}\x{10BB0}-\x{10BFF}\x{10C00}-\x{10C48}\x{10C49}-\x{10C7F}\x{10C80}-\x{10CB2}\x{10CB3}-\x{10CBF}\x{10CC0}-\x{10CF2}\x{10CF3}-\x{10CF9}\x{10CFA}-\x{10CFF}\x{10D00}-\x{10D23}\x{10D28}-\x{10D2F}\x{10D30}-\x{10D39}\x{10D3A}-\x{10D3F}\x{10D40}-\x{10E5F}\x{10E60}-\x{10E7E}\x{10E7F}\x{10E80}-\x{10EA9}\x{10EAA}\x{10EAD}\x{10EAE}-\x{10EAF}\x{10EB0}-\x{10EB1}\x{10EB2}-\x{10EFF}\x{10F00}-\x{10F1C}\x{10F1D}-\x{10F26}\x{10F27}\x{10F28}-\x{10F2F}\x{10F30}-\x{10F45}\x{10F51}-\x{10F54}\x{10F55}-\x{10F59}\x{10F5A}-\x{10F6F}\x{10F70}-\x{10FAF}\x{10FB0}-\x{10FC4}\x{10FC5}-\x{10FCB}\x{10FCC}-\x{10FDF}\x{10FE0}-\x{10FF6}\x{10FF7}-\x{10FFF}\x{1D7CE}-\x{1D7FF}\x{1E800}-\x{1E8C4}\x{1E8C5}-\x{1E8C6}\x{1E8C7}-\x{1E8CF}\x{1E8D7}-\x{1E8FF}\x{1E900}-\x{1E943}\x{1E94B}\x{1E94C}-\x{1E94F}\x{1E950}-\x{1E959}\x{1E95A}-\x{1E95D}\x{1E95E}-\x{1E95F}\x{1E960}-\x{1EC6F}\x{1EC70}\x{1EC71}-\x{1ECAB}\x{1ECAC}\x{1ECAD}-\x{1ECAF}\x{1ECB0}\x{1ECB1}-\x{1ECB4}\x{1ECB5}-\x{1ECBF}\x{1ECC0}-\x{1ECFF}\x{1ED00}\x{1ED01}-\x{1ED2D}\x{1ED2E}\x{1ED2F}-\x{1ED3D}\x{1ED3E}-\x{1ED4F}\x{1ED50}-\x{1EDFF}\x{1EE00}-\x{1EE03}\x{1EE04}\x{1EE05}-\x{1EE1F}\x{1EE20}\x{1EE21}-\x{1EE22}\x{1EE23}\x{1EE24}\x{1EE25}-\x{1EE26}\x{1EE27}\x{1EE28}\x{1EE29}-\x{1EE32}\x{1EE33}\x{1EE34}-\x{1EE37}\x{1EE38}\x{1EE39}\x{1EE3A}\x{1EE3B}\x{1EE3C}-\x{1EE41}\x{1EE42}\x{1EE43}-\x{1EE46}\x{1EE47}\x{1EE48}\x{1EE49}\x{1EE4A}\x{1EE4B}\x{1EE4C}\x{1EE4D}-\x{1EE4F}\x{1EE50}\x{1EE51}-\x{1EE52}\x{1EE53}\x{1EE54}\x{1EE55}-\x{1EE56}\x{1EE57}\x{1EE58}\x{1EE59}\x{1EE5A}\x{1EE5B}\x{1EE5C}\x{1EE5D}\x{1EE5E}\x{1EE5F}\x{1EE60}\x{1EE61}-\x{1EE62}\x{1EE63}\x{1EE64}\x{1EE65}-\x{1EE66}\x{1EE67}-\x{1EE6A}\x{1EE6B}\x{1EE6C}-\x{1EE72}\x{1EE73}\x{1EE74}-\x{1EE77}\x{1EE78}\x{1EE79}-\x{1EE7C}\x{1EE7D}\x{1EE7E}\x{1EE7F}\x{1EE80}-\x{1EE89}\x{1EE8A}\x{1EE8B}-\x{1EE9B}\x{1EE9C}-\x{1EEA0}\x{1EEA1}-\x{1EEA3}\x{1EEA4}\x{1EEA5}-\x{1EEA9}\x{1EEAA}\x{1EEAB}-\x{1EEBB}\x{1EEBC}-\x{1EEEF}\x{1EEF2}-\x{1EEFF}\x{1EF00}-\x{1EFFF}\x{1F100}-\x{1F10A}\x{1FBF0}-\x{1FBF9}][\x{0300}-\x{036F}\x{0483}-\x{0487}\x{0488}-\x{0489}\x{0591}-\x{05BD}\x{05BF}\x{05C1}-\x{05C2}\x{05C4}-\x{05C5}\x{05C7}\x{0610}-\x{061A}\x{064B}-\x{065F}\x{0670}\x{06D6}-\x{06DC}\x{06DF}-\x{06E4}\x{06E7}-\x{06E8}\x{06EA}-\x{06ED}\x{0711}\x{0730}-\x{074A}\x{07A6}-\x{07B0}\x{07EB}-\x{07F3}\x{07FD}\x{0816}-\x{0819}\x{081B}-\x{0823}\x{0825}-\x{0827}\x{0829}-\x{082D}\x{0859}-\x{085B}\x{08D3}-\x{08E1}\x{08E3}-\x{0902}\x{093A}\x{093C}\x{0941}-\x{0948}\x{094D}\x{0951}-\x{0957}\x{0962}-\x{0963}\x{0981}\x{09BC}\x{09C1}-\x{09C4}\x{09CD}\x{09E2}-\x{09E3}\x{09FE}\x{0A01}-\x{0A02}\x{0A3C}\x{0A41}-\x{0A42}\x{0A47}-\x{0A48}\x{0A4B}-\x{0A4D}\x{0A51}\x{0A70}-\x{0A71}\x{0A75}\x{0A81}-\x{0A82}\x{0ABC}\x{0AC1}-\x{0AC5}\x{0AC7}-\x{0AC8}\x{0ACD}\x{0AE2}-\x{0AE3}\x{0AFA}-\x{0AFF}\x{0B01}\x{0B3C}\x{0B3F}\x{0B41}-\x{0B44}\x{0B4D}\x{0B55}-\x{0B56}\x{0B62}-\x{0B63}\x{0B82}\x{0BC0}\x{0BCD}\x{0C00}\x{0C04}\x{0C3E}-\x{0C40}\x{0C46}-\x{0C48}\x{0C4A}-\x{0C4D}\x{0C55}-\x{0C56}\x{0C62}-\x{0C63}\x{0C81}\x{0CBC}\x{0CCC}-\x{0CCD}\x{0CE2}-\x{0CE3}\x{0D00}-\x{0D01}\x{0D3B}-\x{0D3C}\x{0D41}-\x{0D44}\x{0D4D}\x{0D62}-\x{0D63}\x{0D81}\x{0DCA}\x{0DD2}-\x{0DD4}\x{0DD6}\x{0E31}\x{0E34}-\x{0E3A}\x{0E47}-\x{0E4E}\x{0EB1}\x{0EB4}-\x{0EBC}\x{0EC8}-\x{0ECD}\x{0F18}-\x{0F19}\x{0F35}\x{0F37}\x{0F39}\x{0F71}-\x{0F7E}\x{0F80}-\x{0F84}\x{0F86}-\x{0F87}\x{0F8D}-\x{0F97}\x{0F99}-\x{0FBC}\x{0FC6}\x{102D}-\x{1030}\x{1032}-\x{1037}\x{1039}-\x{103A}\x{103D}-\x{103E}\x{1058}-\x{1059}\x{105E}-\x{1060}\x{1071}-\x{1074}\x{1082}\x{1085}-\x{1086}\x{108D}\x{109D}\x{135D}-\x{135F}\x{1712}-\x{1714}\x{1732}-\x{1734}\x{1752}-\x{1753}\x{1772}-\x{1773}\x{17B4}-\x{17B5}\x{17B7}-\x{17BD}\x{17C6}\x{17C9}-\x{17D3}\x{17DD}\x{180B}-\x{180D}\x{1885}-\x{1886}\x{18A9}\x{1920}-\x{1922}\x{1927}-\x{1928}\x{1932}\x{1939}-\x{193B}\x{1A17}-\x{1A18}\x{1A1B}\x{1A56}\x{1A58}-\x{1A5E}\x{1A60}\x{1A62}\x{1A65}-\x{1A6C}\x{1A73}-\x{1A7C}\x{1A7F}\x{1AB0}-\x{1ABD}\x{1ABE}\x{1ABF}-\x{1AC0}\x{1B00}-\x{1B03}\x{1B34}\x{1B36}-\x{1B3A}\x{1B3C}\x{1B42}\x{1B6B}-\x{1B73}\x{1B80}-\x{1B81}\x{1BA2}-\x{1BA5}\x{1BA8}-\x{1BA9}\x{1BAB}-\x{1BAD}\x{1BE6}\x{1BE8}-\x{1BE9}\x{1BED}\x{1BEF}-\x{1BF1}\x{1C2C}-\x{1C33}\x{1C36}-\x{1C37}\x{1CD0}-\x{1CD2}\x{1CD4}-\x{1CE0}\x{1CE2}-\x{1CE8}\x{1CED}\x{1CF4}\x{1CF8}-\x{1CF9}\x{1DC0}-\x{1DF9}\x{1DFB}-\x{1DFF}\x{20D0}-\x{20DC}\x{20DD}-\x{20E0}\x{20E1}\x{20E2}-\x{20E4}\x{20E5}-\x{20F0}\x{2CEF}-\x{2CF1}\x{2D7F}\x{2DE0}-\x{2DFF}\x{302A}-\x{302D}\x{3099}-\x{309A}\x{A66F}\x{A670}-\x{A672}\x{A674}-\x{A67D}\x{A69E}-\x{A69F}\x{A6F0}-\x{A6F1}\x{A802}\x{A806}\x{A80B}\x{A825}-\x{A826}\x{A82C}\x{A8C4}-\x{A8C5}\x{A8E0}-\x{A8F1}\x{A8FF}\x{A926}-\x{A92D}\x{A947}-\x{A951}\x{A980}-\x{A982}\x{A9B3}\x{A9B6}-\x{A9B9}\x{A9BC}-\x{A9BD}\x{A9E5}\x{AA29}-\x{AA2E}\x{AA31}-\x{AA32}\x{AA35}-\x{AA36}\x{AA43}\x{AA4C}\x{AA7C}\x{AAB0}\x{AAB2}-\x{AAB4}\x{AAB7}-\x{AAB8}\x{AABE}-\x{AABF}\x{AAC1}\x{AAEC}-\x{AAED}\x{AAF6}\x{ABE5}\x{ABE8}\x{ABED}\x{FB1E}\x{FE00}-\x{FE0F}\x{FE20}-\x{FE2F}\x{101FD}\x{102E0}\x{10376}-\x{1037A}\x{10A01}-\x{10A03}\x{10A05}-\x{10A06}\x{10A0C}-\x{10A0F}\x{10A38}-\x{10A3A}\x{10A3F}\x{10AE5}-\x{10AE6}\x{10D24}-\x{10D27}\x{10EAB}-\x{10EAC}\x{10F46}-\x{10F50}\x{11001}\x{11038}-\x{11046}\x{1107F}-\x{11081}\x{110B3}-\x{110B6}\x{110B9}-\x{110BA}\x{11100}-\x{11102}\x{11127}-\x{1112B}\x{1112D}-\x{11134}\x{11173}\x{11180}-\x{11181}\x{111B6}-\x{111BE}\x{111C9}-\x{111CC}\x{111CF}\x{1122F}-\x{11231}\x{11234}\x{11236}-\x{11237}\x{1123E}\x{112DF}\x{112E3}-\x{112EA}\x{11300}-\x{11301}\x{1133B}-\x{1133C}\x{11340}\x{11366}-\x{1136C}\x{11370}-\x{11374}\x{11438}-\x{1143F}\x{11442}-\x{11444}\x{11446}\x{1145E}\x{114B3}-\x{114B8}\x{114BA}\x{114BF}-\x{114C0}\x{114C2}-\x{114C3}\x{115B2}-\x{115B5}\x{115BC}-\x{115BD}\x{115BF}-\x{115C0}\x{115DC}-\x{115DD}\x{11633}-\x{1163A}\x{1163D}\x{1163F}-\x{11640}\x{116AB}\x{116AD}\x{116B0}-\x{116B5}\x{116B7}\x{1171D}-\x{1171F}\x{11722}-\x{11725}\x{11727}-\x{1172B}\x{1182F}-\x{11837}\x{11839}-\x{1183A}\x{1193B}-\x{1193C}\x{1193E}\x{11943}\x{119D4}-\x{119D7}\x{119DA}-\x{119DB}\x{119E0}\x{11A01}-\x{11A06}\x{11A09}-\x{11A0A}\x{11A33}-\x{11A38}\x{11A3B}-\x{11A3E}\x{11A47}\x{11A51}-\x{11A56}\x{11A59}-\x{11A5B}\x{11A8A}-\x{11A96}\x{11A98}-\x{11A99}\x{11C30}-\x{11C36}\x{11C38}-\x{11C3D}\x{11C92}-\x{11CA7}\x{11CAA}-\x{11CB0}\x{11CB2}-\x{11CB3}\x{11CB5}-\x{11CB6}\x{11D31}-\x{11D36}\x{11D3A}\x{11D3C}-\x{11D3D}\x{11D3F}-\x{11D45}\x{11D47}\x{11D90}-\x{11D91}\x{11D95}\x{11D97}\x{11EF3}-\x{11EF4}\x{16AF0}-\x{16AF4}\x{16B30}-\x{16B36}\x{16F4F}\x{16F8F}-\x{16F92}\x{16FE4}\x{1BC9D}-\x{1BC9E}\x{1D167}-\x{1D169}\x{1D17B}-\x{1D182}\x{1D185}-\x{1D18B}\x{1D1AA}-\x{1D1AD}\x{1D242}-\x{1D244}\x{1DA00}-\x{1DA36}\x{1DA3B}-\x{1DA6C}\x{1DA75}\x{1DA84}\x{1DA9B}-\x{1DA9F}\x{1DAA1}-\x{1DAAF}\x{1E000}-\x{1E006}\x{1E008}-\x{1E018}\x{1E01B}-\x{1E021}\x{1E023}-\x{1E024}\x{1E026}-\x{1E02A}\x{1E130}-\x{1E136}\x{1E2EC}-\x{1E2EF}\x{1E8D0}-\x{1E8D6}\x{1E944}-\x{1E94A}\x{E0100}-\x{E01EF}]*$/u'; - public const BIDI_STEP_4_AN = '/[\x{0600}-\x{0605}\x{0660}-\x{0669}\x{066B}-\x{066C}\x{06DD}\x{08E2}\x{10D30}-\x{10D39}\x{10E60}-\x{10E7E}]/u'; - public const BIDI_STEP_4_EN = '/[\x{0030}-\x{0039}\x{00B2}-\x{00B3}\x{00B9}\x{06F0}-\x{06F9}\x{2070}\x{2074}-\x{2079}\x{2080}-\x{2089}\x{2488}-\x{249B}\x{FF10}-\x{FF19}\x{102E1}-\x{102FB}\x{1D7CE}-\x{1D7FF}\x{1F100}-\x{1F10A}\x{1FBF0}-\x{1FBF9}]/u'; - public const BIDI_STEP_5 = '/[\x{0009}\x{000A}\x{000B}\x{000C}\x{000D}\x{001C}-\x{001E}\x{001F}\x{0020}\x{0085}\x{0590}\x{05BE}\x{05C0}\x{05C3}\x{05C6}\x{05C8}-\x{05CF}\x{05D0}-\x{05EA}\x{05EB}-\x{05EE}\x{05EF}-\x{05F2}\x{05F3}-\x{05F4}\x{05F5}-\x{05FF}\x{0600}-\x{0605}\x{0608}\x{060B}\x{060D}\x{061B}\x{061C}\x{061D}\x{061E}-\x{061F}\x{0620}-\x{063F}\x{0640}\x{0641}-\x{064A}\x{0660}-\x{0669}\x{066B}-\x{066C}\x{066D}\x{066E}-\x{066F}\x{0671}-\x{06D3}\x{06D4}\x{06D5}\x{06DD}\x{06E5}-\x{06E6}\x{06EE}-\x{06EF}\x{06FA}-\x{06FC}\x{06FD}-\x{06FE}\x{06FF}\x{0700}-\x{070D}\x{070E}\x{070F}\x{0710}\x{0712}-\x{072F}\x{074B}-\x{074C}\x{074D}-\x{07A5}\x{07B1}\x{07B2}-\x{07BF}\x{07C0}-\x{07C9}\x{07CA}-\x{07EA}\x{07F4}-\x{07F5}\x{07FA}\x{07FB}-\x{07FC}\x{07FE}-\x{07FF}\x{0800}-\x{0815}\x{081A}\x{0824}\x{0828}\x{082E}-\x{082F}\x{0830}-\x{083E}\x{083F}\x{0840}-\x{0858}\x{085C}-\x{085D}\x{085E}\x{085F}\x{0860}-\x{086A}\x{086B}-\x{086F}\x{0870}-\x{089F}\x{08A0}-\x{08B4}\x{08B5}\x{08B6}-\x{08C7}\x{08C8}-\x{08D2}\x{08E2}\x{1680}\x{2000}-\x{200A}\x{200F}\x{2028}\x{2029}\x{202A}\x{202B}\x{202C}\x{202D}\x{202E}\x{205F}\x{2066}\x{2067}\x{2068}\x{2069}\x{3000}\x{FB1D}\x{FB1F}-\x{FB28}\x{FB2A}-\x{FB36}\x{FB37}\x{FB38}-\x{FB3C}\x{FB3D}\x{FB3E}\x{FB3F}\x{FB40}-\x{FB41}\x{FB42}\x{FB43}-\x{FB44}\x{FB45}\x{FB46}-\x{FB4F}\x{FB50}-\x{FBB1}\x{FBB2}-\x{FBC1}\x{FBC2}-\x{FBD2}\x{FBD3}-\x{FD3D}\x{FD40}-\x{FD4F}\x{FD50}-\x{FD8F}\x{FD90}-\x{FD91}\x{FD92}-\x{FDC7}\x{FDC8}-\x{FDCF}\x{FDF0}-\x{FDFB}\x{FDFC}\x{FDFE}-\x{FDFF}\x{FE70}-\x{FE74}\x{FE75}\x{FE76}-\x{FEFC}\x{FEFD}-\x{FEFE}\x{10800}-\x{10805}\x{10806}-\x{10807}\x{10808}\x{10809}\x{1080A}-\x{10835}\x{10836}\x{10837}-\x{10838}\x{10839}-\x{1083B}\x{1083C}\x{1083D}-\x{1083E}\x{1083F}-\x{10855}\x{10856}\x{10857}\x{10858}-\x{1085F}\x{10860}-\x{10876}\x{10877}-\x{10878}\x{10879}-\x{1087F}\x{10880}-\x{1089E}\x{1089F}-\x{108A6}\x{108A7}-\x{108AF}\x{108B0}-\x{108DF}\x{108E0}-\x{108F2}\x{108F3}\x{108F4}-\x{108F5}\x{108F6}-\x{108FA}\x{108FB}-\x{108FF}\x{10900}-\x{10915}\x{10916}-\x{1091B}\x{1091C}-\x{1091E}\x{10920}-\x{10939}\x{1093A}-\x{1093E}\x{1093F}\x{10940}-\x{1097F}\x{10980}-\x{109B7}\x{109B8}-\x{109BB}\x{109BC}-\x{109BD}\x{109BE}-\x{109BF}\x{109C0}-\x{109CF}\x{109D0}-\x{109D1}\x{109D2}-\x{109FF}\x{10A00}\x{10A04}\x{10A07}-\x{10A0B}\x{10A10}-\x{10A13}\x{10A14}\x{10A15}-\x{10A17}\x{10A18}\x{10A19}-\x{10A35}\x{10A36}-\x{10A37}\x{10A3B}-\x{10A3E}\x{10A40}-\x{10A48}\x{10A49}-\x{10A4F}\x{10A50}-\x{10A58}\x{10A59}-\x{10A5F}\x{10A60}-\x{10A7C}\x{10A7D}-\x{10A7E}\x{10A7F}\x{10A80}-\x{10A9C}\x{10A9D}-\x{10A9F}\x{10AA0}-\x{10ABF}\x{10AC0}-\x{10AC7}\x{10AC8}\x{10AC9}-\x{10AE4}\x{10AE7}-\x{10AEA}\x{10AEB}-\x{10AEF}\x{10AF0}-\x{10AF6}\x{10AF7}-\x{10AFF}\x{10B00}-\x{10B35}\x{10B36}-\x{10B38}\x{10B40}-\x{10B55}\x{10B56}-\x{10B57}\x{10B58}-\x{10B5F}\x{10B60}-\x{10B72}\x{10B73}-\x{10B77}\x{10B78}-\x{10B7F}\x{10B80}-\x{10B91}\x{10B92}-\x{10B98}\x{10B99}-\x{10B9C}\x{10B9D}-\x{10BA8}\x{10BA9}-\x{10BAF}\x{10BB0}-\x{10BFF}\x{10C00}-\x{10C48}\x{10C49}-\x{10C7F}\x{10C80}-\x{10CB2}\x{10CB3}-\x{10CBF}\x{10CC0}-\x{10CF2}\x{10CF3}-\x{10CF9}\x{10CFA}-\x{10CFF}\x{10D00}-\x{10D23}\x{10D28}-\x{10D2F}\x{10D30}-\x{10D39}\x{10D3A}-\x{10D3F}\x{10D40}-\x{10E5F}\x{10E60}-\x{10E7E}\x{10E7F}\x{10E80}-\x{10EA9}\x{10EAA}\x{10EAD}\x{10EAE}-\x{10EAF}\x{10EB0}-\x{10EB1}\x{10EB2}-\x{10EFF}\x{10F00}-\x{10F1C}\x{10F1D}-\x{10F26}\x{10F27}\x{10F28}-\x{10F2F}\x{10F30}-\x{10F45}\x{10F51}-\x{10F54}\x{10F55}-\x{10F59}\x{10F5A}-\x{10F6F}\x{10F70}-\x{10FAF}\x{10FB0}-\x{10FC4}\x{10FC5}-\x{10FCB}\x{10FCC}-\x{10FDF}\x{10FE0}-\x{10FF6}\x{10FF7}-\x{10FFF}\x{1E800}-\x{1E8C4}\x{1E8C5}-\x{1E8C6}\x{1E8C7}-\x{1E8CF}\x{1E8D7}-\x{1E8FF}\x{1E900}-\x{1E943}\x{1E94B}\x{1E94C}-\x{1E94F}\x{1E950}-\x{1E959}\x{1E95A}-\x{1E95D}\x{1E95E}-\x{1E95F}\x{1E960}-\x{1EC6F}\x{1EC70}\x{1EC71}-\x{1ECAB}\x{1ECAC}\x{1ECAD}-\x{1ECAF}\x{1ECB0}\x{1ECB1}-\x{1ECB4}\x{1ECB5}-\x{1ECBF}\x{1ECC0}-\x{1ECFF}\x{1ED00}\x{1ED01}-\x{1ED2D}\x{1ED2E}\x{1ED2F}-\x{1ED3D}\x{1ED3E}-\x{1ED4F}\x{1ED50}-\x{1EDFF}\x{1EE00}-\x{1EE03}\x{1EE04}\x{1EE05}-\x{1EE1F}\x{1EE20}\x{1EE21}-\x{1EE22}\x{1EE23}\x{1EE24}\x{1EE25}-\x{1EE26}\x{1EE27}\x{1EE28}\x{1EE29}-\x{1EE32}\x{1EE33}\x{1EE34}-\x{1EE37}\x{1EE38}\x{1EE39}\x{1EE3A}\x{1EE3B}\x{1EE3C}-\x{1EE41}\x{1EE42}\x{1EE43}-\x{1EE46}\x{1EE47}\x{1EE48}\x{1EE49}\x{1EE4A}\x{1EE4B}\x{1EE4C}\x{1EE4D}-\x{1EE4F}\x{1EE50}\x{1EE51}-\x{1EE52}\x{1EE53}\x{1EE54}\x{1EE55}-\x{1EE56}\x{1EE57}\x{1EE58}\x{1EE59}\x{1EE5A}\x{1EE5B}\x{1EE5C}\x{1EE5D}\x{1EE5E}\x{1EE5F}\x{1EE60}\x{1EE61}-\x{1EE62}\x{1EE63}\x{1EE64}\x{1EE65}-\x{1EE66}\x{1EE67}-\x{1EE6A}\x{1EE6B}\x{1EE6C}-\x{1EE72}\x{1EE73}\x{1EE74}-\x{1EE77}\x{1EE78}\x{1EE79}-\x{1EE7C}\x{1EE7D}\x{1EE7E}\x{1EE7F}\x{1EE80}-\x{1EE89}\x{1EE8A}\x{1EE8B}-\x{1EE9B}\x{1EE9C}-\x{1EEA0}\x{1EEA1}-\x{1EEA3}\x{1EEA4}\x{1EEA5}-\x{1EEA9}\x{1EEAA}\x{1EEAB}-\x{1EEBB}\x{1EEBC}-\x{1EEEF}\x{1EEF2}-\x{1EEFF}\x{1EF00}-\x{1EFFF}]/u'; - public const BIDI_STEP_6 = '/[^\x{0000}-\x{0008}\x{0009}\x{000A}\x{000B}\x{000C}\x{000D}\x{000E}-\x{001B}\x{001C}-\x{001E}\x{001F}\x{0020}\x{0021}-\x{0022}\x{0023}\x{0024}\x{0025}\x{0026}-\x{0027}\x{0028}\x{0029}\x{002A}\x{002B}\x{002C}\x{002D}\x{002E}-\x{002F}\x{003A}\x{003B}\x{003C}-\x{003E}\x{003F}-\x{0040}\x{005B}\x{005C}\x{005D}\x{005E}\x{005F}\x{0060}\x{007B}\x{007C}\x{007D}\x{007E}\x{007F}-\x{0084}\x{0085}\x{0086}-\x{009F}\x{00A0}\x{00A1}\x{00A2}-\x{00A5}\x{00A6}\x{00A7}\x{00A8}\x{00A9}\x{00AB}\x{00AC}\x{00AD}\x{00AE}\x{00AF}\x{00B0}\x{00B1}\x{00B4}\x{00B6}-\x{00B7}\x{00B8}\x{00BB}\x{00BC}-\x{00BE}\x{00BF}\x{00D7}\x{00F7}\x{02B9}-\x{02BA}\x{02C2}-\x{02C5}\x{02C6}-\x{02CF}\x{02D2}-\x{02DF}\x{02E5}-\x{02EB}\x{02EC}\x{02ED}\x{02EF}-\x{02FF}\x{0300}-\x{036F}\x{0374}\x{0375}\x{037E}\x{0384}-\x{0385}\x{0387}\x{03F6}\x{0483}-\x{0487}\x{0488}-\x{0489}\x{058A}\x{058D}-\x{058E}\x{058F}\x{0590}\x{0591}-\x{05BD}\x{05BE}\x{05BF}\x{05C0}\x{05C1}-\x{05C2}\x{05C3}\x{05C4}-\x{05C5}\x{05C6}\x{05C7}\x{05C8}-\x{05CF}\x{05D0}-\x{05EA}\x{05EB}-\x{05EE}\x{05EF}-\x{05F2}\x{05F3}-\x{05F4}\x{05F5}-\x{05FF}\x{0600}-\x{0605}\x{0606}-\x{0607}\x{0608}\x{0609}-\x{060A}\x{060B}\x{060C}\x{060D}\x{060E}-\x{060F}\x{0610}-\x{061A}\x{061B}\x{061C}\x{061D}\x{061E}-\x{061F}\x{0620}-\x{063F}\x{0640}\x{0641}-\x{064A}\x{064B}-\x{065F}\x{0660}-\x{0669}\x{066A}\x{066B}-\x{066C}\x{066D}\x{066E}-\x{066F}\x{0670}\x{0671}-\x{06D3}\x{06D4}\x{06D5}\x{06D6}-\x{06DC}\x{06DD}\x{06DE}\x{06DF}-\x{06E4}\x{06E5}-\x{06E6}\x{06E7}-\x{06E8}\x{06E9}\x{06EA}-\x{06ED}\x{06EE}-\x{06EF}\x{06FA}-\x{06FC}\x{06FD}-\x{06FE}\x{06FF}\x{0700}-\x{070D}\x{070E}\x{070F}\x{0710}\x{0711}\x{0712}-\x{072F}\x{0730}-\x{074A}\x{074B}-\x{074C}\x{074D}-\x{07A5}\x{07A6}-\x{07B0}\x{07B1}\x{07B2}-\x{07BF}\x{07C0}-\x{07C9}\x{07CA}-\x{07EA}\x{07EB}-\x{07F3}\x{07F4}-\x{07F5}\x{07F6}\x{07F7}-\x{07F9}\x{07FA}\x{07FB}-\x{07FC}\x{07FD}\x{07FE}-\x{07FF}\x{0800}-\x{0815}\x{0816}-\x{0819}\x{081A}\x{081B}-\x{0823}\x{0824}\x{0825}-\x{0827}\x{0828}\x{0829}-\x{082D}\x{082E}-\x{082F}\x{0830}-\x{083E}\x{083F}\x{0840}-\x{0858}\x{0859}-\x{085B}\x{085C}-\x{085D}\x{085E}\x{085F}\x{0860}-\x{086A}\x{086B}-\x{086F}\x{0870}-\x{089F}\x{08A0}-\x{08B4}\x{08B5}\x{08B6}-\x{08C7}\x{08C8}-\x{08D2}\x{08D3}-\x{08E1}\x{08E2}\x{08E3}-\x{0902}\x{093A}\x{093C}\x{0941}-\x{0948}\x{094D}\x{0951}-\x{0957}\x{0962}-\x{0963}\x{0981}\x{09BC}\x{09C1}-\x{09C4}\x{09CD}\x{09E2}-\x{09E3}\x{09F2}-\x{09F3}\x{09FB}\x{09FE}\x{0A01}-\x{0A02}\x{0A3C}\x{0A41}-\x{0A42}\x{0A47}-\x{0A48}\x{0A4B}-\x{0A4D}\x{0A51}\x{0A70}-\x{0A71}\x{0A75}\x{0A81}-\x{0A82}\x{0ABC}\x{0AC1}-\x{0AC5}\x{0AC7}-\x{0AC8}\x{0ACD}\x{0AE2}-\x{0AE3}\x{0AF1}\x{0AFA}-\x{0AFF}\x{0B01}\x{0B3C}\x{0B3F}\x{0B41}-\x{0B44}\x{0B4D}\x{0B55}-\x{0B56}\x{0B62}-\x{0B63}\x{0B82}\x{0BC0}\x{0BCD}\x{0BF3}-\x{0BF8}\x{0BF9}\x{0BFA}\x{0C00}\x{0C04}\x{0C3E}-\x{0C40}\x{0C46}-\x{0C48}\x{0C4A}-\x{0C4D}\x{0C55}-\x{0C56}\x{0C62}-\x{0C63}\x{0C78}-\x{0C7E}\x{0C81}\x{0CBC}\x{0CCC}-\x{0CCD}\x{0CE2}-\x{0CE3}\x{0D00}-\x{0D01}\x{0D3B}-\x{0D3C}\x{0D41}-\x{0D44}\x{0D4D}\x{0D62}-\x{0D63}\x{0D81}\x{0DCA}\x{0DD2}-\x{0DD4}\x{0DD6}\x{0E31}\x{0E34}-\x{0E3A}\x{0E3F}\x{0E47}-\x{0E4E}\x{0EB1}\x{0EB4}-\x{0EBC}\x{0EC8}-\x{0ECD}\x{0F18}-\x{0F19}\x{0F35}\x{0F37}\x{0F39}\x{0F3A}\x{0F3B}\x{0F3C}\x{0F3D}\x{0F71}-\x{0F7E}\x{0F80}-\x{0F84}\x{0F86}-\x{0F87}\x{0F8D}-\x{0F97}\x{0F99}-\x{0FBC}\x{0FC6}\x{102D}-\x{1030}\x{1032}-\x{1037}\x{1039}-\x{103A}\x{103D}-\x{103E}\x{1058}-\x{1059}\x{105E}-\x{1060}\x{1071}-\x{1074}\x{1082}\x{1085}-\x{1086}\x{108D}\x{109D}\x{135D}-\x{135F}\x{1390}-\x{1399}\x{1400}\x{1680}\x{169B}\x{169C}\x{1712}-\x{1714}\x{1732}-\x{1734}\x{1752}-\x{1753}\x{1772}-\x{1773}\x{17B4}-\x{17B5}\x{17B7}-\x{17BD}\x{17C6}\x{17C9}-\x{17D3}\x{17DB}\x{17DD}\x{17F0}-\x{17F9}\x{1800}-\x{1805}\x{1806}\x{1807}-\x{180A}\x{180B}-\x{180D}\x{180E}\x{1885}-\x{1886}\x{18A9}\x{1920}-\x{1922}\x{1927}-\x{1928}\x{1932}\x{1939}-\x{193B}\x{1940}\x{1944}-\x{1945}\x{19DE}-\x{19FF}\x{1A17}-\x{1A18}\x{1A1B}\x{1A56}\x{1A58}-\x{1A5E}\x{1A60}\x{1A62}\x{1A65}-\x{1A6C}\x{1A73}-\x{1A7C}\x{1A7F}\x{1AB0}-\x{1ABD}\x{1ABE}\x{1ABF}-\x{1AC0}\x{1B00}-\x{1B03}\x{1B34}\x{1B36}-\x{1B3A}\x{1B3C}\x{1B42}\x{1B6B}-\x{1B73}\x{1B80}-\x{1B81}\x{1BA2}-\x{1BA5}\x{1BA8}-\x{1BA9}\x{1BAB}-\x{1BAD}\x{1BE6}\x{1BE8}-\x{1BE9}\x{1BED}\x{1BEF}-\x{1BF1}\x{1C2C}-\x{1C33}\x{1C36}-\x{1C37}\x{1CD0}-\x{1CD2}\x{1CD4}-\x{1CE0}\x{1CE2}-\x{1CE8}\x{1CED}\x{1CF4}\x{1CF8}-\x{1CF9}\x{1DC0}-\x{1DF9}\x{1DFB}-\x{1DFF}\x{1FBD}\x{1FBF}-\x{1FC1}\x{1FCD}-\x{1FCF}\x{1FDD}-\x{1FDF}\x{1FED}-\x{1FEF}\x{1FFD}-\x{1FFE}\x{2000}-\x{200A}\x{200B}-\x{200D}\x{200F}\x{2010}-\x{2015}\x{2016}-\x{2017}\x{2018}\x{2019}\x{201A}\x{201B}-\x{201C}\x{201D}\x{201E}\x{201F}\x{2020}-\x{2027}\x{2028}\x{2029}\x{202A}\x{202B}\x{202C}\x{202D}\x{202E}\x{202F}\x{2030}-\x{2034}\x{2035}-\x{2038}\x{2039}\x{203A}\x{203B}-\x{203E}\x{203F}-\x{2040}\x{2041}-\x{2043}\x{2044}\x{2045}\x{2046}\x{2047}-\x{2051}\x{2052}\x{2053}\x{2054}\x{2055}-\x{205E}\x{205F}\x{2060}-\x{2064}\x{2065}\x{2066}\x{2067}\x{2068}\x{2069}\x{206A}-\x{206F}\x{207A}-\x{207B}\x{207C}\x{207D}\x{207E}\x{208A}-\x{208B}\x{208C}\x{208D}\x{208E}\x{20A0}-\x{20BF}\x{20C0}-\x{20CF}\x{20D0}-\x{20DC}\x{20DD}-\x{20E0}\x{20E1}\x{20E2}-\x{20E4}\x{20E5}-\x{20F0}\x{2100}-\x{2101}\x{2103}-\x{2106}\x{2108}-\x{2109}\x{2114}\x{2116}-\x{2117}\x{2118}\x{211E}-\x{2123}\x{2125}\x{2127}\x{2129}\x{212E}\x{213A}-\x{213B}\x{2140}-\x{2144}\x{214A}\x{214B}\x{214C}-\x{214D}\x{2150}-\x{215F}\x{2189}\x{218A}-\x{218B}\x{2190}-\x{2194}\x{2195}-\x{2199}\x{219A}-\x{219B}\x{219C}-\x{219F}\x{21A0}\x{21A1}-\x{21A2}\x{21A3}\x{21A4}-\x{21A5}\x{21A6}\x{21A7}-\x{21AD}\x{21AE}\x{21AF}-\x{21CD}\x{21CE}-\x{21CF}\x{21D0}-\x{21D1}\x{21D2}\x{21D3}\x{21D4}\x{21D5}-\x{21F3}\x{21F4}-\x{2211}\x{2212}\x{2213}\x{2214}-\x{22FF}\x{2300}-\x{2307}\x{2308}\x{2309}\x{230A}\x{230B}\x{230C}-\x{231F}\x{2320}-\x{2321}\x{2322}-\x{2328}\x{2329}\x{232A}\x{232B}-\x{2335}\x{237B}\x{237C}\x{237D}-\x{2394}\x{2396}-\x{239A}\x{239B}-\x{23B3}\x{23B4}-\x{23DB}\x{23DC}-\x{23E1}\x{23E2}-\x{2426}\x{2440}-\x{244A}\x{2460}-\x{2487}\x{24EA}-\x{24FF}\x{2500}-\x{25B6}\x{25B7}\x{25B8}-\x{25C0}\x{25C1}\x{25C2}-\x{25F7}\x{25F8}-\x{25FF}\x{2600}-\x{266E}\x{266F}\x{2670}-\x{26AB}\x{26AD}-\x{2767}\x{2768}\x{2769}\x{276A}\x{276B}\x{276C}\x{276D}\x{276E}\x{276F}\x{2770}\x{2771}\x{2772}\x{2773}\x{2774}\x{2775}\x{2776}-\x{2793}\x{2794}-\x{27BF}\x{27C0}-\x{27C4}\x{27C5}\x{27C6}\x{27C7}-\x{27E5}\x{27E6}\x{27E7}\x{27E8}\x{27E9}\x{27EA}\x{27EB}\x{27EC}\x{27ED}\x{27EE}\x{27EF}\x{27F0}-\x{27FF}\x{2900}-\x{2982}\x{2983}\x{2984}\x{2985}\x{2986}\x{2987}\x{2988}\x{2989}\x{298A}\x{298B}\x{298C}\x{298D}\x{298E}\x{298F}\x{2990}\x{2991}\x{2992}\x{2993}\x{2994}\x{2995}\x{2996}\x{2997}\x{2998}\x{2999}-\x{29D7}\x{29D8}\x{29D9}\x{29DA}\x{29DB}\x{29DC}-\x{29FB}\x{29FC}\x{29FD}\x{29FE}-\x{2AFF}\x{2B00}-\x{2B2F}\x{2B30}-\x{2B44}\x{2B45}-\x{2B46}\x{2B47}-\x{2B4C}\x{2B4D}-\x{2B73}\x{2B76}-\x{2B95}\x{2B97}-\x{2BFF}\x{2CE5}-\x{2CEA}\x{2CEF}-\x{2CF1}\x{2CF9}-\x{2CFC}\x{2CFD}\x{2CFE}-\x{2CFF}\x{2D7F}\x{2DE0}-\x{2DFF}\x{2E00}-\x{2E01}\x{2E02}\x{2E03}\x{2E04}\x{2E05}\x{2E06}-\x{2E08}\x{2E09}\x{2E0A}\x{2E0B}\x{2E0C}\x{2E0D}\x{2E0E}-\x{2E16}\x{2E17}\x{2E18}-\x{2E19}\x{2E1A}\x{2E1B}\x{2E1C}\x{2E1D}\x{2E1E}-\x{2E1F}\x{2E20}\x{2E21}\x{2E22}\x{2E23}\x{2E24}\x{2E25}\x{2E26}\x{2E27}\x{2E28}\x{2E29}\x{2E2A}-\x{2E2E}\x{2E2F}\x{2E30}-\x{2E39}\x{2E3A}-\x{2E3B}\x{2E3C}-\x{2E3F}\x{2E40}\x{2E41}\x{2E42}\x{2E43}-\x{2E4F}\x{2E50}-\x{2E51}\x{2E52}\x{2E80}-\x{2E99}\x{2E9B}-\x{2EF3}\x{2F00}-\x{2FD5}\x{2FF0}-\x{2FFB}\x{3000}\x{3001}-\x{3003}\x{3004}\x{3008}\x{3009}\x{300A}\x{300B}\x{300C}\x{300D}\x{300E}\x{300F}\x{3010}\x{3011}\x{3012}-\x{3013}\x{3014}\x{3015}\x{3016}\x{3017}\x{3018}\x{3019}\x{301A}\x{301B}\x{301C}\x{301D}\x{301E}-\x{301F}\x{3020}\x{302A}-\x{302D}\x{3030}\x{3036}-\x{3037}\x{303D}\x{303E}-\x{303F}\x{3099}-\x{309A}\x{309B}-\x{309C}\x{30A0}\x{30FB}\x{31C0}-\x{31E3}\x{321D}-\x{321E}\x{3250}\x{3251}-\x{325F}\x{327C}-\x{327E}\x{32B1}-\x{32BF}\x{32CC}-\x{32CF}\x{3377}-\x{337A}\x{33DE}-\x{33DF}\x{33FF}\x{4DC0}-\x{4DFF}\x{A490}-\x{A4C6}\x{A60D}-\x{A60F}\x{A66F}\x{A670}-\x{A672}\x{A673}\x{A674}-\x{A67D}\x{A67E}\x{A67F}\x{A69E}-\x{A69F}\x{A6F0}-\x{A6F1}\x{A700}-\x{A716}\x{A717}-\x{A71F}\x{A720}-\x{A721}\x{A788}\x{A802}\x{A806}\x{A80B}\x{A825}-\x{A826}\x{A828}-\x{A82B}\x{A82C}\x{A838}\x{A839}\x{A874}-\x{A877}\x{A8C4}-\x{A8C5}\x{A8E0}-\x{A8F1}\x{A8FF}\x{A926}-\x{A92D}\x{A947}-\x{A951}\x{A980}-\x{A982}\x{A9B3}\x{A9B6}-\x{A9B9}\x{A9BC}-\x{A9BD}\x{A9E5}\x{AA29}-\x{AA2E}\x{AA31}-\x{AA32}\x{AA35}-\x{AA36}\x{AA43}\x{AA4C}\x{AA7C}\x{AAB0}\x{AAB2}-\x{AAB4}\x{AAB7}-\x{AAB8}\x{AABE}-\x{AABF}\x{AAC1}\x{AAEC}-\x{AAED}\x{AAF6}\x{AB6A}-\x{AB6B}\x{ABE5}\x{ABE8}\x{ABED}\x{FB1D}\x{FB1E}\x{FB1F}-\x{FB28}\x{FB29}\x{FB2A}-\x{FB36}\x{FB37}\x{FB38}-\x{FB3C}\x{FB3D}\x{FB3E}\x{FB3F}\x{FB40}-\x{FB41}\x{FB42}\x{FB43}-\x{FB44}\x{FB45}\x{FB46}-\x{FB4F}\x{FB50}-\x{FBB1}\x{FBB2}-\x{FBC1}\x{FBC2}-\x{FBD2}\x{FBD3}-\x{FD3D}\x{FD3E}\x{FD3F}\x{FD40}-\x{FD4F}\x{FD50}-\x{FD8F}\x{FD90}-\x{FD91}\x{FD92}-\x{FDC7}\x{FDC8}-\x{FDCF}\x{FDD0}-\x{FDEF}\x{FDF0}-\x{FDFB}\x{FDFC}\x{FDFD}\x{FDFE}-\x{FDFF}\x{FE00}-\x{FE0F}\x{FE10}-\x{FE16}\x{FE17}\x{FE18}\x{FE19}\x{FE20}-\x{FE2F}\x{FE30}\x{FE31}-\x{FE32}\x{FE33}-\x{FE34}\x{FE35}\x{FE36}\x{FE37}\x{FE38}\x{FE39}\x{FE3A}\x{FE3B}\x{FE3C}\x{FE3D}\x{FE3E}\x{FE3F}\x{FE40}\x{FE41}\x{FE42}\x{FE43}\x{FE44}\x{FE45}-\x{FE46}\x{FE47}\x{FE48}\x{FE49}-\x{FE4C}\x{FE4D}-\x{FE4F}\x{FE50}\x{FE51}\x{FE52}\x{FE54}\x{FE55}\x{FE56}-\x{FE57}\x{FE58}\x{FE59}\x{FE5A}\x{FE5B}\x{FE5C}\x{FE5D}\x{FE5E}\x{FE5F}\x{FE60}-\x{FE61}\x{FE62}\x{FE63}\x{FE64}-\x{FE66}\x{FE68}\x{FE69}\x{FE6A}\x{FE6B}\x{FE70}-\x{FE74}\x{FE75}\x{FE76}-\x{FEFC}\x{FEFD}-\x{FEFE}\x{FEFF}\x{FF01}-\x{FF02}\x{FF03}\x{FF04}\x{FF05}\x{FF06}-\x{FF07}\x{FF08}\x{FF09}\x{FF0A}\x{FF0B}\x{FF0C}\x{FF0D}\x{FF0E}-\x{FF0F}\x{FF1A}\x{FF1B}\x{FF1C}-\x{FF1E}\x{FF1F}-\x{FF20}\x{FF3B}\x{FF3C}\x{FF3D}\x{FF3E}\x{FF3F}\x{FF40}\x{FF5B}\x{FF5C}\x{FF5D}\x{FF5E}\x{FF5F}\x{FF60}\x{FF61}\x{FF62}\x{FF63}\x{FF64}-\x{FF65}\x{FFE0}-\x{FFE1}\x{FFE2}\x{FFE3}\x{FFE4}\x{FFE5}-\x{FFE6}\x{FFE8}\x{FFE9}-\x{FFEC}\x{FFED}-\x{FFEE}\x{FFF0}-\x{FFF8}\x{FFF9}-\x{FFFB}\x{FFFC}-\x{FFFD}\x{FFFE}-\x{FFFF}\x{10101}\x{10140}-\x{10174}\x{10175}-\x{10178}\x{10179}-\x{10189}\x{1018A}-\x{1018B}\x{1018C}\x{10190}-\x{1019C}\x{101A0}\x{101FD}\x{102E0}\x{10376}-\x{1037A}\x{10800}-\x{10805}\x{10806}-\x{10807}\x{10808}\x{10809}\x{1080A}-\x{10835}\x{10836}\x{10837}-\x{10838}\x{10839}-\x{1083B}\x{1083C}\x{1083D}-\x{1083E}\x{1083F}-\x{10855}\x{10856}\x{10857}\x{10858}-\x{1085F}\x{10860}-\x{10876}\x{10877}-\x{10878}\x{10879}-\x{1087F}\x{10880}-\x{1089E}\x{1089F}-\x{108A6}\x{108A7}-\x{108AF}\x{108B0}-\x{108DF}\x{108E0}-\x{108F2}\x{108F3}\x{108F4}-\x{108F5}\x{108F6}-\x{108FA}\x{108FB}-\x{108FF}\x{10900}-\x{10915}\x{10916}-\x{1091B}\x{1091C}-\x{1091E}\x{1091F}\x{10920}-\x{10939}\x{1093A}-\x{1093E}\x{1093F}\x{10940}-\x{1097F}\x{10980}-\x{109B7}\x{109B8}-\x{109BB}\x{109BC}-\x{109BD}\x{109BE}-\x{109BF}\x{109C0}-\x{109CF}\x{109D0}-\x{109D1}\x{109D2}-\x{109FF}\x{10A00}\x{10A01}-\x{10A03}\x{10A04}\x{10A05}-\x{10A06}\x{10A07}-\x{10A0B}\x{10A0C}-\x{10A0F}\x{10A10}-\x{10A13}\x{10A14}\x{10A15}-\x{10A17}\x{10A18}\x{10A19}-\x{10A35}\x{10A36}-\x{10A37}\x{10A38}-\x{10A3A}\x{10A3B}-\x{10A3E}\x{10A3F}\x{10A40}-\x{10A48}\x{10A49}-\x{10A4F}\x{10A50}-\x{10A58}\x{10A59}-\x{10A5F}\x{10A60}-\x{10A7C}\x{10A7D}-\x{10A7E}\x{10A7F}\x{10A80}-\x{10A9C}\x{10A9D}-\x{10A9F}\x{10AA0}-\x{10ABF}\x{10AC0}-\x{10AC7}\x{10AC8}\x{10AC9}-\x{10AE4}\x{10AE5}-\x{10AE6}\x{10AE7}-\x{10AEA}\x{10AEB}-\x{10AEF}\x{10AF0}-\x{10AF6}\x{10AF7}-\x{10AFF}\x{10B00}-\x{10B35}\x{10B36}-\x{10B38}\x{10B39}-\x{10B3F}\x{10B40}-\x{10B55}\x{10B56}-\x{10B57}\x{10B58}-\x{10B5F}\x{10B60}-\x{10B72}\x{10B73}-\x{10B77}\x{10B78}-\x{10B7F}\x{10B80}-\x{10B91}\x{10B92}-\x{10B98}\x{10B99}-\x{10B9C}\x{10B9D}-\x{10BA8}\x{10BA9}-\x{10BAF}\x{10BB0}-\x{10BFF}\x{10C00}-\x{10C48}\x{10C49}-\x{10C7F}\x{10C80}-\x{10CB2}\x{10CB3}-\x{10CBF}\x{10CC0}-\x{10CF2}\x{10CF3}-\x{10CF9}\x{10CFA}-\x{10CFF}\x{10D00}-\x{10D23}\x{10D24}-\x{10D27}\x{10D28}-\x{10D2F}\x{10D30}-\x{10D39}\x{10D3A}-\x{10D3F}\x{10D40}-\x{10E5F}\x{10E60}-\x{10E7E}\x{10E7F}\x{10E80}-\x{10EA9}\x{10EAA}\x{10EAB}-\x{10EAC}\x{10EAD}\x{10EAE}-\x{10EAF}\x{10EB0}-\x{10EB1}\x{10EB2}-\x{10EFF}\x{10F00}-\x{10F1C}\x{10F1D}-\x{10F26}\x{10F27}\x{10F28}-\x{10F2F}\x{10F30}-\x{10F45}\x{10F46}-\x{10F50}\x{10F51}-\x{10F54}\x{10F55}-\x{10F59}\x{10F5A}-\x{10F6F}\x{10F70}-\x{10FAF}\x{10FB0}-\x{10FC4}\x{10FC5}-\x{10FCB}\x{10FCC}-\x{10FDF}\x{10FE0}-\x{10FF6}\x{10FF7}-\x{10FFF}\x{11001}\x{11038}-\x{11046}\x{11052}-\x{11065}\x{1107F}-\x{11081}\x{110B3}-\x{110B6}\x{110B9}-\x{110BA}\x{11100}-\x{11102}\x{11127}-\x{1112B}\x{1112D}-\x{11134}\x{11173}\x{11180}-\x{11181}\x{111B6}-\x{111BE}\x{111C9}-\x{111CC}\x{111CF}\x{1122F}-\x{11231}\x{11234}\x{11236}-\x{11237}\x{1123E}\x{112DF}\x{112E3}-\x{112EA}\x{11300}-\x{11301}\x{1133B}-\x{1133C}\x{11340}\x{11366}-\x{1136C}\x{11370}-\x{11374}\x{11438}-\x{1143F}\x{11442}-\x{11444}\x{11446}\x{1145E}\x{114B3}-\x{114B8}\x{114BA}\x{114BF}-\x{114C0}\x{114C2}-\x{114C3}\x{115B2}-\x{115B5}\x{115BC}-\x{115BD}\x{115BF}-\x{115C0}\x{115DC}-\x{115DD}\x{11633}-\x{1163A}\x{1163D}\x{1163F}-\x{11640}\x{11660}-\x{1166C}\x{116AB}\x{116AD}\x{116B0}-\x{116B5}\x{116B7}\x{1171D}-\x{1171F}\x{11722}-\x{11725}\x{11727}-\x{1172B}\x{1182F}-\x{11837}\x{11839}-\x{1183A}\x{1193B}-\x{1193C}\x{1193E}\x{11943}\x{119D4}-\x{119D7}\x{119DA}-\x{119DB}\x{119E0}\x{11A01}-\x{11A06}\x{11A09}-\x{11A0A}\x{11A33}-\x{11A38}\x{11A3B}-\x{11A3E}\x{11A47}\x{11A51}-\x{11A56}\x{11A59}-\x{11A5B}\x{11A8A}-\x{11A96}\x{11A98}-\x{11A99}\x{11C30}-\x{11C36}\x{11C38}-\x{11C3D}\x{11C92}-\x{11CA7}\x{11CAA}-\x{11CB0}\x{11CB2}-\x{11CB3}\x{11CB5}-\x{11CB6}\x{11D31}-\x{11D36}\x{11D3A}\x{11D3C}-\x{11D3D}\x{11D3F}-\x{11D45}\x{11D47}\x{11D90}-\x{11D91}\x{11D95}\x{11D97}\x{11EF3}-\x{11EF4}\x{11FD5}-\x{11FDC}\x{11FDD}-\x{11FE0}\x{11FE1}-\x{11FF1}\x{16AF0}-\x{16AF4}\x{16B30}-\x{16B36}\x{16F4F}\x{16F8F}-\x{16F92}\x{16FE2}\x{16FE4}\x{1BC9D}-\x{1BC9E}\x{1BCA0}-\x{1BCA3}\x{1D167}-\x{1D169}\x{1D173}-\x{1D17A}\x{1D17B}-\x{1D182}\x{1D185}-\x{1D18B}\x{1D1AA}-\x{1D1AD}\x{1D200}-\x{1D241}\x{1D242}-\x{1D244}\x{1D245}\x{1D300}-\x{1D356}\x{1D6DB}\x{1D715}\x{1D74F}\x{1D789}\x{1D7C3}\x{1DA00}-\x{1DA36}\x{1DA3B}-\x{1DA6C}\x{1DA75}\x{1DA84}\x{1DA9B}-\x{1DA9F}\x{1DAA1}-\x{1DAAF}\x{1E000}-\x{1E006}\x{1E008}-\x{1E018}\x{1E01B}-\x{1E021}\x{1E023}-\x{1E024}\x{1E026}-\x{1E02A}\x{1E130}-\x{1E136}\x{1E2EC}-\x{1E2EF}\x{1E2FF}\x{1E800}-\x{1E8C4}\x{1E8C5}-\x{1E8C6}\x{1E8C7}-\x{1E8CF}\x{1E8D0}-\x{1E8D6}\x{1E8D7}-\x{1E8FF}\x{1E900}-\x{1E943}\x{1E944}-\x{1E94A}\x{1E94B}\x{1E94C}-\x{1E94F}\x{1E950}-\x{1E959}\x{1E95A}-\x{1E95D}\x{1E95E}-\x{1E95F}\x{1E960}-\x{1EC6F}\x{1EC70}\x{1EC71}-\x{1ECAB}\x{1ECAC}\x{1ECAD}-\x{1ECAF}\x{1ECB0}\x{1ECB1}-\x{1ECB4}\x{1ECB5}-\x{1ECBF}\x{1ECC0}-\x{1ECFF}\x{1ED00}\x{1ED01}-\x{1ED2D}\x{1ED2E}\x{1ED2F}-\x{1ED3D}\x{1ED3E}-\x{1ED4F}\x{1ED50}-\x{1EDFF}\x{1EE00}-\x{1EE03}\x{1EE04}\x{1EE05}-\x{1EE1F}\x{1EE20}\x{1EE21}-\x{1EE22}\x{1EE23}\x{1EE24}\x{1EE25}-\x{1EE26}\x{1EE27}\x{1EE28}\x{1EE29}-\x{1EE32}\x{1EE33}\x{1EE34}-\x{1EE37}\x{1EE38}\x{1EE39}\x{1EE3A}\x{1EE3B}\x{1EE3C}-\x{1EE41}\x{1EE42}\x{1EE43}-\x{1EE46}\x{1EE47}\x{1EE48}\x{1EE49}\x{1EE4A}\x{1EE4B}\x{1EE4C}\x{1EE4D}-\x{1EE4F}\x{1EE50}\x{1EE51}-\x{1EE52}\x{1EE53}\x{1EE54}\x{1EE55}-\x{1EE56}\x{1EE57}\x{1EE58}\x{1EE59}\x{1EE5A}\x{1EE5B}\x{1EE5C}\x{1EE5D}\x{1EE5E}\x{1EE5F}\x{1EE60}\x{1EE61}-\x{1EE62}\x{1EE63}\x{1EE64}\x{1EE65}-\x{1EE66}\x{1EE67}-\x{1EE6A}\x{1EE6B}\x{1EE6C}-\x{1EE72}\x{1EE73}\x{1EE74}-\x{1EE77}\x{1EE78}\x{1EE79}-\x{1EE7C}\x{1EE7D}\x{1EE7E}\x{1EE7F}\x{1EE80}-\x{1EE89}\x{1EE8A}\x{1EE8B}-\x{1EE9B}\x{1EE9C}-\x{1EEA0}\x{1EEA1}-\x{1EEA3}\x{1EEA4}\x{1EEA5}-\x{1EEA9}\x{1EEAA}\x{1EEAB}-\x{1EEBB}\x{1EEBC}-\x{1EEEF}\x{1EEF0}-\x{1EEF1}\x{1EEF2}-\x{1EEFF}\x{1EF00}-\x{1EFFF}\x{1F000}-\x{1F02B}\x{1F030}-\x{1F093}\x{1F0A0}-\x{1F0AE}\x{1F0B1}-\x{1F0BF}\x{1F0C1}-\x{1F0CF}\x{1F0D1}-\x{1F0F5}\x{1F10B}-\x{1F10C}\x{1F10D}-\x{1F10F}\x{1F12F}\x{1F16A}-\x{1F16F}\x{1F1AD}\x{1F260}-\x{1F265}\x{1F300}-\x{1F3FA}\x{1F3FB}-\x{1F3FF}\x{1F400}-\x{1F6D7}\x{1F6E0}-\x{1F6EC}\x{1F6F0}-\x{1F6FC}\x{1F700}-\x{1F773}\x{1F780}-\x{1F7D8}\x{1F7E0}-\x{1F7EB}\x{1F800}-\x{1F80B}\x{1F810}-\x{1F847}\x{1F850}-\x{1F859}\x{1F860}-\x{1F887}\x{1F890}-\x{1F8AD}\x{1F8B0}-\x{1F8B1}\x{1F900}-\x{1F978}\x{1F97A}-\x{1F9CB}\x{1F9CD}-\x{1FA53}\x{1FA60}-\x{1FA6D}\x{1FA70}-\x{1FA74}\x{1FA78}-\x{1FA7A}\x{1FA80}-\x{1FA86}\x{1FA90}-\x{1FAA8}\x{1FAB0}-\x{1FAB6}\x{1FAC0}-\x{1FAC2}\x{1FAD0}-\x{1FAD6}\x{1FB00}-\x{1FB92}\x{1FB94}-\x{1FBCA}\x{1FFFE}-\x{1FFFF}\x{2FFFE}-\x{2FFFF}\x{3FFFE}-\x{3FFFF}\x{4FFFE}-\x{4FFFF}\x{5FFFE}-\x{5FFFF}\x{6FFFE}-\x{6FFFF}\x{7FFFE}-\x{7FFFF}\x{8FFFE}-\x{8FFFF}\x{9FFFE}-\x{9FFFF}\x{AFFFE}-\x{AFFFF}\x{BFFFE}-\x{BFFFF}\x{CFFFE}-\x{CFFFF}\x{DFFFE}-\x{E0000}\x{E0001}\x{E0002}-\x{E001F}\x{E0020}-\x{E007F}\x{E0080}-\x{E00FF}\x{E0100}-\x{E01EF}\x{E01F0}-\x{E0FFF}\x{EFFFE}-\x{EFFFF}\x{FFFFE}-\x{FFFFF}\x{10FFFE}-\x{10FFFF}][\x{0300}-\x{036F}\x{0483}-\x{0487}\x{0488}-\x{0489}\x{0591}-\x{05BD}\x{05BF}\x{05C1}-\x{05C2}\x{05C4}-\x{05C5}\x{05C7}\x{0610}-\x{061A}\x{064B}-\x{065F}\x{0670}\x{06D6}-\x{06DC}\x{06DF}-\x{06E4}\x{06E7}-\x{06E8}\x{06EA}-\x{06ED}\x{0711}\x{0730}-\x{074A}\x{07A6}-\x{07B0}\x{07EB}-\x{07F3}\x{07FD}\x{0816}-\x{0819}\x{081B}-\x{0823}\x{0825}-\x{0827}\x{0829}-\x{082D}\x{0859}-\x{085B}\x{08D3}-\x{08E1}\x{08E3}-\x{0902}\x{093A}\x{093C}\x{0941}-\x{0948}\x{094D}\x{0951}-\x{0957}\x{0962}-\x{0963}\x{0981}\x{09BC}\x{09C1}-\x{09C4}\x{09CD}\x{09E2}-\x{09E3}\x{09FE}\x{0A01}-\x{0A02}\x{0A3C}\x{0A41}-\x{0A42}\x{0A47}-\x{0A48}\x{0A4B}-\x{0A4D}\x{0A51}\x{0A70}-\x{0A71}\x{0A75}\x{0A81}-\x{0A82}\x{0ABC}\x{0AC1}-\x{0AC5}\x{0AC7}-\x{0AC8}\x{0ACD}\x{0AE2}-\x{0AE3}\x{0AFA}-\x{0AFF}\x{0B01}\x{0B3C}\x{0B3F}\x{0B41}-\x{0B44}\x{0B4D}\x{0B55}-\x{0B56}\x{0B62}-\x{0B63}\x{0B82}\x{0BC0}\x{0BCD}\x{0C00}\x{0C04}\x{0C3E}-\x{0C40}\x{0C46}-\x{0C48}\x{0C4A}-\x{0C4D}\x{0C55}-\x{0C56}\x{0C62}-\x{0C63}\x{0C81}\x{0CBC}\x{0CCC}-\x{0CCD}\x{0CE2}-\x{0CE3}\x{0D00}-\x{0D01}\x{0D3B}-\x{0D3C}\x{0D41}-\x{0D44}\x{0D4D}\x{0D62}-\x{0D63}\x{0D81}\x{0DCA}\x{0DD2}-\x{0DD4}\x{0DD6}\x{0E31}\x{0E34}-\x{0E3A}\x{0E47}-\x{0E4E}\x{0EB1}\x{0EB4}-\x{0EBC}\x{0EC8}-\x{0ECD}\x{0F18}-\x{0F19}\x{0F35}\x{0F37}\x{0F39}\x{0F71}-\x{0F7E}\x{0F80}-\x{0F84}\x{0F86}-\x{0F87}\x{0F8D}-\x{0F97}\x{0F99}-\x{0FBC}\x{0FC6}\x{102D}-\x{1030}\x{1032}-\x{1037}\x{1039}-\x{103A}\x{103D}-\x{103E}\x{1058}-\x{1059}\x{105E}-\x{1060}\x{1071}-\x{1074}\x{1082}\x{1085}-\x{1086}\x{108D}\x{109D}\x{135D}-\x{135F}\x{1712}-\x{1714}\x{1732}-\x{1734}\x{1752}-\x{1753}\x{1772}-\x{1773}\x{17B4}-\x{17B5}\x{17B7}-\x{17BD}\x{17C6}\x{17C9}-\x{17D3}\x{17DD}\x{180B}-\x{180D}\x{1885}-\x{1886}\x{18A9}\x{1920}-\x{1922}\x{1927}-\x{1928}\x{1932}\x{1939}-\x{193B}\x{1A17}-\x{1A18}\x{1A1B}\x{1A56}\x{1A58}-\x{1A5E}\x{1A60}\x{1A62}\x{1A65}-\x{1A6C}\x{1A73}-\x{1A7C}\x{1A7F}\x{1AB0}-\x{1ABD}\x{1ABE}\x{1ABF}-\x{1AC0}\x{1B00}-\x{1B03}\x{1B34}\x{1B36}-\x{1B3A}\x{1B3C}\x{1B42}\x{1B6B}-\x{1B73}\x{1B80}-\x{1B81}\x{1BA2}-\x{1BA5}\x{1BA8}-\x{1BA9}\x{1BAB}-\x{1BAD}\x{1BE6}\x{1BE8}-\x{1BE9}\x{1BED}\x{1BEF}-\x{1BF1}\x{1C2C}-\x{1C33}\x{1C36}-\x{1C37}\x{1CD0}-\x{1CD2}\x{1CD4}-\x{1CE0}\x{1CE2}-\x{1CE8}\x{1CED}\x{1CF4}\x{1CF8}-\x{1CF9}\x{1DC0}-\x{1DF9}\x{1DFB}-\x{1DFF}\x{20D0}-\x{20DC}\x{20DD}-\x{20E0}\x{20E1}\x{20E2}-\x{20E4}\x{20E5}-\x{20F0}\x{2CEF}-\x{2CF1}\x{2D7F}\x{2DE0}-\x{2DFF}\x{302A}-\x{302D}\x{3099}-\x{309A}\x{A66F}\x{A670}-\x{A672}\x{A674}-\x{A67D}\x{A69E}-\x{A69F}\x{A6F0}-\x{A6F1}\x{A802}\x{A806}\x{A80B}\x{A825}-\x{A826}\x{A82C}\x{A8C4}-\x{A8C5}\x{A8E0}-\x{A8F1}\x{A8FF}\x{A926}-\x{A92D}\x{A947}-\x{A951}\x{A980}-\x{A982}\x{A9B3}\x{A9B6}-\x{A9B9}\x{A9BC}-\x{A9BD}\x{A9E5}\x{AA29}-\x{AA2E}\x{AA31}-\x{AA32}\x{AA35}-\x{AA36}\x{AA43}\x{AA4C}\x{AA7C}\x{AAB0}\x{AAB2}-\x{AAB4}\x{AAB7}-\x{AAB8}\x{AABE}-\x{AABF}\x{AAC1}\x{AAEC}-\x{AAED}\x{AAF6}\x{ABE5}\x{ABE8}\x{ABED}\x{FB1E}\x{FE00}-\x{FE0F}\x{FE20}-\x{FE2F}\x{101FD}\x{102E0}\x{10376}-\x{1037A}\x{10A01}-\x{10A03}\x{10A05}-\x{10A06}\x{10A0C}-\x{10A0F}\x{10A38}-\x{10A3A}\x{10A3F}\x{10AE5}-\x{10AE6}\x{10D24}-\x{10D27}\x{10EAB}-\x{10EAC}\x{10F46}-\x{10F50}\x{11001}\x{11038}-\x{11046}\x{1107F}-\x{11081}\x{110B3}-\x{110B6}\x{110B9}-\x{110BA}\x{11100}-\x{11102}\x{11127}-\x{1112B}\x{1112D}-\x{11134}\x{11173}\x{11180}-\x{11181}\x{111B6}-\x{111BE}\x{111C9}-\x{111CC}\x{111CF}\x{1122F}-\x{11231}\x{11234}\x{11236}-\x{11237}\x{1123E}\x{112DF}\x{112E3}-\x{112EA}\x{11300}-\x{11301}\x{1133B}-\x{1133C}\x{11340}\x{11366}-\x{1136C}\x{11370}-\x{11374}\x{11438}-\x{1143F}\x{11442}-\x{11444}\x{11446}\x{1145E}\x{114B3}-\x{114B8}\x{114BA}\x{114BF}-\x{114C0}\x{114C2}-\x{114C3}\x{115B2}-\x{115B5}\x{115BC}-\x{115BD}\x{115BF}-\x{115C0}\x{115DC}-\x{115DD}\x{11633}-\x{1163A}\x{1163D}\x{1163F}-\x{11640}\x{116AB}\x{116AD}\x{116B0}-\x{116B5}\x{116B7}\x{1171D}-\x{1171F}\x{11722}-\x{11725}\x{11727}-\x{1172B}\x{1182F}-\x{11837}\x{11839}-\x{1183A}\x{1193B}-\x{1193C}\x{1193E}\x{11943}\x{119D4}-\x{119D7}\x{119DA}-\x{119DB}\x{119E0}\x{11A01}-\x{11A06}\x{11A09}-\x{11A0A}\x{11A33}-\x{11A38}\x{11A3B}-\x{11A3E}\x{11A47}\x{11A51}-\x{11A56}\x{11A59}-\x{11A5B}\x{11A8A}-\x{11A96}\x{11A98}-\x{11A99}\x{11C30}-\x{11C36}\x{11C38}-\x{11C3D}\x{11C92}-\x{11CA7}\x{11CAA}-\x{11CB0}\x{11CB2}-\x{11CB3}\x{11CB5}-\x{11CB6}\x{11D31}-\x{11D36}\x{11D3A}\x{11D3C}-\x{11D3D}\x{11D3F}-\x{11D45}\x{11D47}\x{11D90}-\x{11D91}\x{11D95}\x{11D97}\x{11EF3}-\x{11EF4}\x{16AF0}-\x{16AF4}\x{16B30}-\x{16B36}\x{16F4F}\x{16F8F}-\x{16F92}\x{16FE4}\x{1BC9D}-\x{1BC9E}\x{1D167}-\x{1D169}\x{1D17B}-\x{1D182}\x{1D185}-\x{1D18B}\x{1D1AA}-\x{1D1AD}\x{1D242}-\x{1D244}\x{1DA00}-\x{1DA36}\x{1DA3B}-\x{1DA6C}\x{1DA75}\x{1DA84}\x{1DA9B}-\x{1DA9F}\x{1DAA1}-\x{1DAAF}\x{1E000}-\x{1E006}\x{1E008}-\x{1E018}\x{1E01B}-\x{1E021}\x{1E023}-\x{1E024}\x{1E026}-\x{1E02A}\x{1E130}-\x{1E136}\x{1E2EC}-\x{1E2EF}\x{1E8D0}-\x{1E8D6}\x{1E944}-\x{1E94A}\x{E0100}-\x{E01EF}]*$/u'; + const BIDI_STEP_1_LTR = '/^[^\x{0000}-\x{0008}\x{0009}\x{000A}\x{000B}\x{000C}\x{000D}\x{000E}-\x{001B}\x{001C}-\x{001E}\x{001F}\x{0020}\x{0021}-\x{0022}\x{0023}\x{0024}\x{0025}\x{0026}-\x{0027}\x{0028}\x{0029}\x{002A}\x{002B}\x{002C}\x{002D}\x{002E}-\x{002F}\x{0030}-\x{0039}\x{003A}\x{003B}\x{003C}-\x{003E}\x{003F}-\x{0040}\x{005B}\x{005C}\x{005D}\x{005E}\x{005F}\x{0060}\x{007B}\x{007C}\x{007D}\x{007E}\x{007F}-\x{0084}\x{0085}\x{0086}-\x{009F}\x{00A0}\x{00A1}\x{00A2}-\x{00A5}\x{00A6}\x{00A7}\x{00A8}\x{00A9}\x{00AB}\x{00AC}\x{00AD}\x{00AE}\x{00AF}\x{00B0}\x{00B1}\x{00B2}-\x{00B3}\x{00B4}\x{00B6}-\x{00B7}\x{00B8}\x{00B9}\x{00BB}\x{00BC}-\x{00BE}\x{00BF}\x{00D7}\x{00F7}\x{02B9}-\x{02BA}\x{02C2}-\x{02C5}\x{02C6}-\x{02CF}\x{02D2}-\x{02DF}\x{02E5}-\x{02EB}\x{02EC}\x{02ED}\x{02EF}-\x{02FF}\x{0300}-\x{036F}\x{0374}\x{0375}\x{037E}\x{0384}-\x{0385}\x{0387}\x{03F6}\x{0483}-\x{0487}\x{0488}-\x{0489}\x{058A}\x{058D}-\x{058E}\x{058F}\x{0590}\x{0591}-\x{05BD}\x{05BE}\x{05BF}\x{05C0}\x{05C1}-\x{05C2}\x{05C3}\x{05C4}-\x{05C5}\x{05C6}\x{05C7}\x{05C8}-\x{05CF}\x{05D0}-\x{05EA}\x{05EB}-\x{05EE}\x{05EF}-\x{05F2}\x{05F3}-\x{05F4}\x{05F5}-\x{05FF}\x{0600}-\x{0605}\x{0606}-\x{0607}\x{0608}\x{0609}-\x{060A}\x{060B}\x{060C}\x{060D}\x{060E}-\x{060F}\x{0610}-\x{061A}\x{061B}\x{061C}\x{061D}\x{061E}-\x{061F}\x{0620}-\x{063F}\x{0640}\x{0641}-\x{064A}\x{064B}-\x{065F}\x{0660}-\x{0669}\x{066A}\x{066B}-\x{066C}\x{066D}\x{066E}-\x{066F}\x{0670}\x{0671}-\x{06D3}\x{06D4}\x{06D5}\x{06D6}-\x{06DC}\x{06DD}\x{06DE}\x{06DF}-\x{06E4}\x{06E5}-\x{06E6}\x{06E7}-\x{06E8}\x{06E9}\x{06EA}-\x{06ED}\x{06EE}-\x{06EF}\x{06F0}-\x{06F9}\x{06FA}-\x{06FC}\x{06FD}-\x{06FE}\x{06FF}\x{0700}-\x{070D}\x{070E}\x{070F}\x{0710}\x{0711}\x{0712}-\x{072F}\x{0730}-\x{074A}\x{074B}-\x{074C}\x{074D}-\x{07A5}\x{07A6}-\x{07B0}\x{07B1}\x{07B2}-\x{07BF}\x{07C0}-\x{07C9}\x{07CA}-\x{07EA}\x{07EB}-\x{07F3}\x{07F4}-\x{07F5}\x{07F6}\x{07F7}-\x{07F9}\x{07FA}\x{07FB}-\x{07FC}\x{07FD}\x{07FE}-\x{07FF}\x{0800}-\x{0815}\x{0816}-\x{0819}\x{081A}\x{081B}-\x{0823}\x{0824}\x{0825}-\x{0827}\x{0828}\x{0829}-\x{082D}\x{082E}-\x{082F}\x{0830}-\x{083E}\x{083F}\x{0840}-\x{0858}\x{0859}-\x{085B}\x{085C}-\x{085D}\x{085E}\x{085F}\x{0860}-\x{086A}\x{086B}-\x{086F}\x{0870}-\x{089F}\x{08A0}-\x{08B4}\x{08B5}\x{08B6}-\x{08C7}\x{08C8}-\x{08D2}\x{08D3}-\x{08E1}\x{08E2}\x{08E3}-\x{0902}\x{093A}\x{093C}\x{0941}-\x{0948}\x{094D}\x{0951}-\x{0957}\x{0962}-\x{0963}\x{0981}\x{09BC}\x{09C1}-\x{09C4}\x{09CD}\x{09E2}-\x{09E3}\x{09F2}-\x{09F3}\x{09FB}\x{09FE}\x{0A01}-\x{0A02}\x{0A3C}\x{0A41}-\x{0A42}\x{0A47}-\x{0A48}\x{0A4B}-\x{0A4D}\x{0A51}\x{0A70}-\x{0A71}\x{0A75}\x{0A81}-\x{0A82}\x{0ABC}\x{0AC1}-\x{0AC5}\x{0AC7}-\x{0AC8}\x{0ACD}\x{0AE2}-\x{0AE3}\x{0AF1}\x{0AFA}-\x{0AFF}\x{0B01}\x{0B3C}\x{0B3F}\x{0B41}-\x{0B44}\x{0B4D}\x{0B55}-\x{0B56}\x{0B62}-\x{0B63}\x{0B82}\x{0BC0}\x{0BCD}\x{0BF3}-\x{0BF8}\x{0BF9}\x{0BFA}\x{0C00}\x{0C04}\x{0C3E}-\x{0C40}\x{0C46}-\x{0C48}\x{0C4A}-\x{0C4D}\x{0C55}-\x{0C56}\x{0C62}-\x{0C63}\x{0C78}-\x{0C7E}\x{0C81}\x{0CBC}\x{0CCC}-\x{0CCD}\x{0CE2}-\x{0CE3}\x{0D00}-\x{0D01}\x{0D3B}-\x{0D3C}\x{0D41}-\x{0D44}\x{0D4D}\x{0D62}-\x{0D63}\x{0D81}\x{0DCA}\x{0DD2}-\x{0DD4}\x{0DD6}\x{0E31}\x{0E34}-\x{0E3A}\x{0E3F}\x{0E47}-\x{0E4E}\x{0EB1}\x{0EB4}-\x{0EBC}\x{0EC8}-\x{0ECD}\x{0F18}-\x{0F19}\x{0F35}\x{0F37}\x{0F39}\x{0F3A}\x{0F3B}\x{0F3C}\x{0F3D}\x{0F71}-\x{0F7E}\x{0F80}-\x{0F84}\x{0F86}-\x{0F87}\x{0F8D}-\x{0F97}\x{0F99}-\x{0FBC}\x{0FC6}\x{102D}-\x{1030}\x{1032}-\x{1037}\x{1039}-\x{103A}\x{103D}-\x{103E}\x{1058}-\x{1059}\x{105E}-\x{1060}\x{1071}-\x{1074}\x{1082}\x{1085}-\x{1086}\x{108D}\x{109D}\x{135D}-\x{135F}\x{1390}-\x{1399}\x{1400}\x{1680}\x{169B}\x{169C}\x{1712}-\x{1714}\x{1732}-\x{1734}\x{1752}-\x{1753}\x{1772}-\x{1773}\x{17B4}-\x{17B5}\x{17B7}-\x{17BD}\x{17C6}\x{17C9}-\x{17D3}\x{17DB}\x{17DD}\x{17F0}-\x{17F9}\x{1800}-\x{1805}\x{1806}\x{1807}-\x{180A}\x{180B}-\x{180D}\x{180E}\x{1885}-\x{1886}\x{18A9}\x{1920}-\x{1922}\x{1927}-\x{1928}\x{1932}\x{1939}-\x{193B}\x{1940}\x{1944}-\x{1945}\x{19DE}-\x{19FF}\x{1A17}-\x{1A18}\x{1A1B}\x{1A56}\x{1A58}-\x{1A5E}\x{1A60}\x{1A62}\x{1A65}-\x{1A6C}\x{1A73}-\x{1A7C}\x{1A7F}\x{1AB0}-\x{1ABD}\x{1ABE}\x{1ABF}-\x{1AC0}\x{1B00}-\x{1B03}\x{1B34}\x{1B36}-\x{1B3A}\x{1B3C}\x{1B42}\x{1B6B}-\x{1B73}\x{1B80}-\x{1B81}\x{1BA2}-\x{1BA5}\x{1BA8}-\x{1BA9}\x{1BAB}-\x{1BAD}\x{1BE6}\x{1BE8}-\x{1BE9}\x{1BED}\x{1BEF}-\x{1BF1}\x{1C2C}-\x{1C33}\x{1C36}-\x{1C37}\x{1CD0}-\x{1CD2}\x{1CD4}-\x{1CE0}\x{1CE2}-\x{1CE8}\x{1CED}\x{1CF4}\x{1CF8}-\x{1CF9}\x{1DC0}-\x{1DF9}\x{1DFB}-\x{1DFF}\x{1FBD}\x{1FBF}-\x{1FC1}\x{1FCD}-\x{1FCF}\x{1FDD}-\x{1FDF}\x{1FED}-\x{1FEF}\x{1FFD}-\x{1FFE}\x{2000}-\x{200A}\x{200B}-\x{200D}\x{200F}\x{2010}-\x{2015}\x{2016}-\x{2017}\x{2018}\x{2019}\x{201A}\x{201B}-\x{201C}\x{201D}\x{201E}\x{201F}\x{2020}-\x{2027}\x{2028}\x{2029}\x{202A}\x{202B}\x{202C}\x{202D}\x{202E}\x{202F}\x{2030}-\x{2034}\x{2035}-\x{2038}\x{2039}\x{203A}\x{203B}-\x{203E}\x{203F}-\x{2040}\x{2041}-\x{2043}\x{2044}\x{2045}\x{2046}\x{2047}-\x{2051}\x{2052}\x{2053}\x{2054}\x{2055}-\x{205E}\x{205F}\x{2060}-\x{2064}\x{2065}\x{2066}\x{2067}\x{2068}\x{2069}\x{206A}-\x{206F}\x{2070}\x{2074}-\x{2079}\x{207A}-\x{207B}\x{207C}\x{207D}\x{207E}\x{2080}-\x{2089}\x{208A}-\x{208B}\x{208C}\x{208D}\x{208E}\x{20A0}-\x{20BF}\x{20C0}-\x{20CF}\x{20D0}-\x{20DC}\x{20DD}-\x{20E0}\x{20E1}\x{20E2}-\x{20E4}\x{20E5}-\x{20F0}\x{2100}-\x{2101}\x{2103}-\x{2106}\x{2108}-\x{2109}\x{2114}\x{2116}-\x{2117}\x{2118}\x{211E}-\x{2123}\x{2125}\x{2127}\x{2129}\x{212E}\x{213A}-\x{213B}\x{2140}-\x{2144}\x{214A}\x{214B}\x{214C}-\x{214D}\x{2150}-\x{215F}\x{2189}\x{218A}-\x{218B}\x{2190}-\x{2194}\x{2195}-\x{2199}\x{219A}-\x{219B}\x{219C}-\x{219F}\x{21A0}\x{21A1}-\x{21A2}\x{21A3}\x{21A4}-\x{21A5}\x{21A6}\x{21A7}-\x{21AD}\x{21AE}\x{21AF}-\x{21CD}\x{21CE}-\x{21CF}\x{21D0}-\x{21D1}\x{21D2}\x{21D3}\x{21D4}\x{21D5}-\x{21F3}\x{21F4}-\x{2211}\x{2212}\x{2213}\x{2214}-\x{22FF}\x{2300}-\x{2307}\x{2308}\x{2309}\x{230A}\x{230B}\x{230C}-\x{231F}\x{2320}-\x{2321}\x{2322}-\x{2328}\x{2329}\x{232A}\x{232B}-\x{2335}\x{237B}\x{237C}\x{237D}-\x{2394}\x{2396}-\x{239A}\x{239B}-\x{23B3}\x{23B4}-\x{23DB}\x{23DC}-\x{23E1}\x{23E2}-\x{2426}\x{2440}-\x{244A}\x{2460}-\x{2487}\x{2488}-\x{249B}\x{24EA}-\x{24FF}\x{2500}-\x{25B6}\x{25B7}\x{25B8}-\x{25C0}\x{25C1}\x{25C2}-\x{25F7}\x{25F8}-\x{25FF}\x{2600}-\x{266E}\x{266F}\x{2670}-\x{26AB}\x{26AD}-\x{2767}\x{2768}\x{2769}\x{276A}\x{276B}\x{276C}\x{276D}\x{276E}\x{276F}\x{2770}\x{2771}\x{2772}\x{2773}\x{2774}\x{2775}\x{2776}-\x{2793}\x{2794}-\x{27BF}\x{27C0}-\x{27C4}\x{27C5}\x{27C6}\x{27C7}-\x{27E5}\x{27E6}\x{27E7}\x{27E8}\x{27E9}\x{27EA}\x{27EB}\x{27EC}\x{27ED}\x{27EE}\x{27EF}\x{27F0}-\x{27FF}\x{2900}-\x{2982}\x{2983}\x{2984}\x{2985}\x{2986}\x{2987}\x{2988}\x{2989}\x{298A}\x{298B}\x{298C}\x{298D}\x{298E}\x{298F}\x{2990}\x{2991}\x{2992}\x{2993}\x{2994}\x{2995}\x{2996}\x{2997}\x{2998}\x{2999}-\x{29D7}\x{29D8}\x{29D9}\x{29DA}\x{29DB}\x{29DC}-\x{29FB}\x{29FC}\x{29FD}\x{29FE}-\x{2AFF}\x{2B00}-\x{2B2F}\x{2B30}-\x{2B44}\x{2B45}-\x{2B46}\x{2B47}-\x{2B4C}\x{2B4D}-\x{2B73}\x{2B76}-\x{2B95}\x{2B97}-\x{2BFF}\x{2CE5}-\x{2CEA}\x{2CEF}-\x{2CF1}\x{2CF9}-\x{2CFC}\x{2CFD}\x{2CFE}-\x{2CFF}\x{2D7F}\x{2DE0}-\x{2DFF}\x{2E00}-\x{2E01}\x{2E02}\x{2E03}\x{2E04}\x{2E05}\x{2E06}-\x{2E08}\x{2E09}\x{2E0A}\x{2E0B}\x{2E0C}\x{2E0D}\x{2E0E}-\x{2E16}\x{2E17}\x{2E18}-\x{2E19}\x{2E1A}\x{2E1B}\x{2E1C}\x{2E1D}\x{2E1E}-\x{2E1F}\x{2E20}\x{2E21}\x{2E22}\x{2E23}\x{2E24}\x{2E25}\x{2E26}\x{2E27}\x{2E28}\x{2E29}\x{2E2A}-\x{2E2E}\x{2E2F}\x{2E30}-\x{2E39}\x{2E3A}-\x{2E3B}\x{2E3C}-\x{2E3F}\x{2E40}\x{2E41}\x{2E42}\x{2E43}-\x{2E4F}\x{2E50}-\x{2E51}\x{2E52}\x{2E80}-\x{2E99}\x{2E9B}-\x{2EF3}\x{2F00}-\x{2FD5}\x{2FF0}-\x{2FFB}\x{3000}\x{3001}-\x{3003}\x{3004}\x{3008}\x{3009}\x{300A}\x{300B}\x{300C}\x{300D}\x{300E}\x{300F}\x{3010}\x{3011}\x{3012}-\x{3013}\x{3014}\x{3015}\x{3016}\x{3017}\x{3018}\x{3019}\x{301A}\x{301B}\x{301C}\x{301D}\x{301E}-\x{301F}\x{3020}\x{302A}-\x{302D}\x{3030}\x{3036}-\x{3037}\x{303D}\x{303E}-\x{303F}\x{3099}-\x{309A}\x{309B}-\x{309C}\x{30A0}\x{30FB}\x{31C0}-\x{31E3}\x{321D}-\x{321E}\x{3250}\x{3251}-\x{325F}\x{327C}-\x{327E}\x{32B1}-\x{32BF}\x{32CC}-\x{32CF}\x{3377}-\x{337A}\x{33DE}-\x{33DF}\x{33FF}\x{4DC0}-\x{4DFF}\x{A490}-\x{A4C6}\x{A60D}-\x{A60F}\x{A66F}\x{A670}-\x{A672}\x{A673}\x{A674}-\x{A67D}\x{A67E}\x{A67F}\x{A69E}-\x{A69F}\x{A6F0}-\x{A6F1}\x{A700}-\x{A716}\x{A717}-\x{A71F}\x{A720}-\x{A721}\x{A788}\x{A802}\x{A806}\x{A80B}\x{A825}-\x{A826}\x{A828}-\x{A82B}\x{A82C}\x{A838}\x{A839}\x{A874}-\x{A877}\x{A8C4}-\x{A8C5}\x{A8E0}-\x{A8F1}\x{A8FF}\x{A926}-\x{A92D}\x{A947}-\x{A951}\x{A980}-\x{A982}\x{A9B3}\x{A9B6}-\x{A9B9}\x{A9BC}-\x{A9BD}\x{A9E5}\x{AA29}-\x{AA2E}\x{AA31}-\x{AA32}\x{AA35}-\x{AA36}\x{AA43}\x{AA4C}\x{AA7C}\x{AAB0}\x{AAB2}-\x{AAB4}\x{AAB7}-\x{AAB8}\x{AABE}-\x{AABF}\x{AAC1}\x{AAEC}-\x{AAED}\x{AAF6}\x{AB6A}-\x{AB6B}\x{ABE5}\x{ABE8}\x{ABED}\x{FB1D}\x{FB1E}\x{FB1F}-\x{FB28}\x{FB29}\x{FB2A}-\x{FB36}\x{FB37}\x{FB38}-\x{FB3C}\x{FB3D}\x{FB3E}\x{FB3F}\x{FB40}-\x{FB41}\x{FB42}\x{FB43}-\x{FB44}\x{FB45}\x{FB46}-\x{FB4F}\x{FB50}-\x{FBB1}\x{FBB2}-\x{FBC1}\x{FBC2}-\x{FBD2}\x{FBD3}-\x{FD3D}\x{FD3E}\x{FD3F}\x{FD40}-\x{FD4F}\x{FD50}-\x{FD8F}\x{FD90}-\x{FD91}\x{FD92}-\x{FDC7}\x{FDC8}-\x{FDCF}\x{FDD0}-\x{FDEF}\x{FDF0}-\x{FDFB}\x{FDFC}\x{FDFD}\x{FDFE}-\x{FDFF}\x{FE00}-\x{FE0F}\x{FE10}-\x{FE16}\x{FE17}\x{FE18}\x{FE19}\x{FE20}-\x{FE2F}\x{FE30}\x{FE31}-\x{FE32}\x{FE33}-\x{FE34}\x{FE35}\x{FE36}\x{FE37}\x{FE38}\x{FE39}\x{FE3A}\x{FE3B}\x{FE3C}\x{FE3D}\x{FE3E}\x{FE3F}\x{FE40}\x{FE41}\x{FE42}\x{FE43}\x{FE44}\x{FE45}-\x{FE46}\x{FE47}\x{FE48}\x{FE49}-\x{FE4C}\x{FE4D}-\x{FE4F}\x{FE50}\x{FE51}\x{FE52}\x{FE54}\x{FE55}\x{FE56}-\x{FE57}\x{FE58}\x{FE59}\x{FE5A}\x{FE5B}\x{FE5C}\x{FE5D}\x{FE5E}\x{FE5F}\x{FE60}-\x{FE61}\x{FE62}\x{FE63}\x{FE64}-\x{FE66}\x{FE68}\x{FE69}\x{FE6A}\x{FE6B}\x{FE70}-\x{FE74}\x{FE75}\x{FE76}-\x{FEFC}\x{FEFD}-\x{FEFE}\x{FEFF}\x{FF01}-\x{FF02}\x{FF03}\x{FF04}\x{FF05}\x{FF06}-\x{FF07}\x{FF08}\x{FF09}\x{FF0A}\x{FF0B}\x{FF0C}\x{FF0D}\x{FF0E}-\x{FF0F}\x{FF10}-\x{FF19}\x{FF1A}\x{FF1B}\x{FF1C}-\x{FF1E}\x{FF1F}-\x{FF20}\x{FF3B}\x{FF3C}\x{FF3D}\x{FF3E}\x{FF3F}\x{FF40}\x{FF5B}\x{FF5C}\x{FF5D}\x{FF5E}\x{FF5F}\x{FF60}\x{FF61}\x{FF62}\x{FF63}\x{FF64}-\x{FF65}\x{FFE0}-\x{FFE1}\x{FFE2}\x{FFE3}\x{FFE4}\x{FFE5}-\x{FFE6}\x{FFE8}\x{FFE9}-\x{FFEC}\x{FFED}-\x{FFEE}\x{FFF0}-\x{FFF8}\x{FFF9}-\x{FFFB}\x{FFFC}-\x{FFFD}\x{FFFE}-\x{FFFF}\x{10101}\x{10140}-\x{10174}\x{10175}-\x{10178}\x{10179}-\x{10189}\x{1018A}-\x{1018B}\x{1018C}\x{10190}-\x{1019C}\x{101A0}\x{101FD}\x{102E0}\x{102E1}-\x{102FB}\x{10376}-\x{1037A}\x{10800}-\x{10805}\x{10806}-\x{10807}\x{10808}\x{10809}\x{1080A}-\x{10835}\x{10836}\x{10837}-\x{10838}\x{10839}-\x{1083B}\x{1083C}\x{1083D}-\x{1083E}\x{1083F}-\x{10855}\x{10856}\x{10857}\x{10858}-\x{1085F}\x{10860}-\x{10876}\x{10877}-\x{10878}\x{10879}-\x{1087F}\x{10880}-\x{1089E}\x{1089F}-\x{108A6}\x{108A7}-\x{108AF}\x{108B0}-\x{108DF}\x{108E0}-\x{108F2}\x{108F3}\x{108F4}-\x{108F5}\x{108F6}-\x{108FA}\x{108FB}-\x{108FF}\x{10900}-\x{10915}\x{10916}-\x{1091B}\x{1091C}-\x{1091E}\x{1091F}\x{10920}-\x{10939}\x{1093A}-\x{1093E}\x{1093F}\x{10940}-\x{1097F}\x{10980}-\x{109B7}\x{109B8}-\x{109BB}\x{109BC}-\x{109BD}\x{109BE}-\x{109BF}\x{109C0}-\x{109CF}\x{109D0}-\x{109D1}\x{109D2}-\x{109FF}\x{10A00}\x{10A01}-\x{10A03}\x{10A04}\x{10A05}-\x{10A06}\x{10A07}-\x{10A0B}\x{10A0C}-\x{10A0F}\x{10A10}-\x{10A13}\x{10A14}\x{10A15}-\x{10A17}\x{10A18}\x{10A19}-\x{10A35}\x{10A36}-\x{10A37}\x{10A38}-\x{10A3A}\x{10A3B}-\x{10A3E}\x{10A3F}\x{10A40}-\x{10A48}\x{10A49}-\x{10A4F}\x{10A50}-\x{10A58}\x{10A59}-\x{10A5F}\x{10A60}-\x{10A7C}\x{10A7D}-\x{10A7E}\x{10A7F}\x{10A80}-\x{10A9C}\x{10A9D}-\x{10A9F}\x{10AA0}-\x{10ABF}\x{10AC0}-\x{10AC7}\x{10AC8}\x{10AC9}-\x{10AE4}\x{10AE5}-\x{10AE6}\x{10AE7}-\x{10AEA}\x{10AEB}-\x{10AEF}\x{10AF0}-\x{10AF6}\x{10AF7}-\x{10AFF}\x{10B00}-\x{10B35}\x{10B36}-\x{10B38}\x{10B39}-\x{10B3F}\x{10B40}-\x{10B55}\x{10B56}-\x{10B57}\x{10B58}-\x{10B5F}\x{10B60}-\x{10B72}\x{10B73}-\x{10B77}\x{10B78}-\x{10B7F}\x{10B80}-\x{10B91}\x{10B92}-\x{10B98}\x{10B99}-\x{10B9C}\x{10B9D}-\x{10BA8}\x{10BA9}-\x{10BAF}\x{10BB0}-\x{10BFF}\x{10C00}-\x{10C48}\x{10C49}-\x{10C7F}\x{10C80}-\x{10CB2}\x{10CB3}-\x{10CBF}\x{10CC0}-\x{10CF2}\x{10CF3}-\x{10CF9}\x{10CFA}-\x{10CFF}\x{10D00}-\x{10D23}\x{10D24}-\x{10D27}\x{10D28}-\x{10D2F}\x{10D30}-\x{10D39}\x{10D3A}-\x{10D3F}\x{10D40}-\x{10E5F}\x{10E60}-\x{10E7E}\x{10E7F}\x{10E80}-\x{10EA9}\x{10EAA}\x{10EAB}-\x{10EAC}\x{10EAD}\x{10EAE}-\x{10EAF}\x{10EB0}-\x{10EB1}\x{10EB2}-\x{10EFF}\x{10F00}-\x{10F1C}\x{10F1D}-\x{10F26}\x{10F27}\x{10F28}-\x{10F2F}\x{10F30}-\x{10F45}\x{10F46}-\x{10F50}\x{10F51}-\x{10F54}\x{10F55}-\x{10F59}\x{10F5A}-\x{10F6F}\x{10F70}-\x{10FAF}\x{10FB0}-\x{10FC4}\x{10FC5}-\x{10FCB}\x{10FCC}-\x{10FDF}\x{10FE0}-\x{10FF6}\x{10FF7}-\x{10FFF}\x{11001}\x{11038}-\x{11046}\x{11052}-\x{11065}\x{1107F}-\x{11081}\x{110B3}-\x{110B6}\x{110B9}-\x{110BA}\x{11100}-\x{11102}\x{11127}-\x{1112B}\x{1112D}-\x{11134}\x{11173}\x{11180}-\x{11181}\x{111B6}-\x{111BE}\x{111C9}-\x{111CC}\x{111CF}\x{1122F}-\x{11231}\x{11234}\x{11236}-\x{11237}\x{1123E}\x{112DF}\x{112E3}-\x{112EA}\x{11300}-\x{11301}\x{1133B}-\x{1133C}\x{11340}\x{11366}-\x{1136C}\x{11370}-\x{11374}\x{11438}-\x{1143F}\x{11442}-\x{11444}\x{11446}\x{1145E}\x{114B3}-\x{114B8}\x{114BA}\x{114BF}-\x{114C0}\x{114C2}-\x{114C3}\x{115B2}-\x{115B5}\x{115BC}-\x{115BD}\x{115BF}-\x{115C0}\x{115DC}-\x{115DD}\x{11633}-\x{1163A}\x{1163D}\x{1163F}-\x{11640}\x{11660}-\x{1166C}\x{116AB}\x{116AD}\x{116B0}-\x{116B5}\x{116B7}\x{1171D}-\x{1171F}\x{11722}-\x{11725}\x{11727}-\x{1172B}\x{1182F}-\x{11837}\x{11839}-\x{1183A}\x{1193B}-\x{1193C}\x{1193E}\x{11943}\x{119D4}-\x{119D7}\x{119DA}-\x{119DB}\x{119E0}\x{11A01}-\x{11A06}\x{11A09}-\x{11A0A}\x{11A33}-\x{11A38}\x{11A3B}-\x{11A3E}\x{11A47}\x{11A51}-\x{11A56}\x{11A59}-\x{11A5B}\x{11A8A}-\x{11A96}\x{11A98}-\x{11A99}\x{11C30}-\x{11C36}\x{11C38}-\x{11C3D}\x{11C92}-\x{11CA7}\x{11CAA}-\x{11CB0}\x{11CB2}-\x{11CB3}\x{11CB5}-\x{11CB6}\x{11D31}-\x{11D36}\x{11D3A}\x{11D3C}-\x{11D3D}\x{11D3F}-\x{11D45}\x{11D47}\x{11D90}-\x{11D91}\x{11D95}\x{11D97}\x{11EF3}-\x{11EF4}\x{11FD5}-\x{11FDC}\x{11FDD}-\x{11FE0}\x{11FE1}-\x{11FF1}\x{16AF0}-\x{16AF4}\x{16B30}-\x{16B36}\x{16F4F}\x{16F8F}-\x{16F92}\x{16FE2}\x{16FE4}\x{1BC9D}-\x{1BC9E}\x{1BCA0}-\x{1BCA3}\x{1D167}-\x{1D169}\x{1D173}-\x{1D17A}\x{1D17B}-\x{1D182}\x{1D185}-\x{1D18B}\x{1D1AA}-\x{1D1AD}\x{1D200}-\x{1D241}\x{1D242}-\x{1D244}\x{1D245}\x{1D300}-\x{1D356}\x{1D6DB}\x{1D715}\x{1D74F}\x{1D789}\x{1D7C3}\x{1D7CE}-\x{1D7FF}\x{1DA00}-\x{1DA36}\x{1DA3B}-\x{1DA6C}\x{1DA75}\x{1DA84}\x{1DA9B}-\x{1DA9F}\x{1DAA1}-\x{1DAAF}\x{1E000}-\x{1E006}\x{1E008}-\x{1E018}\x{1E01B}-\x{1E021}\x{1E023}-\x{1E024}\x{1E026}-\x{1E02A}\x{1E130}-\x{1E136}\x{1E2EC}-\x{1E2EF}\x{1E2FF}\x{1E800}-\x{1E8C4}\x{1E8C5}-\x{1E8C6}\x{1E8C7}-\x{1E8CF}\x{1E8D0}-\x{1E8D6}\x{1E8D7}-\x{1E8FF}\x{1E900}-\x{1E943}\x{1E944}-\x{1E94A}\x{1E94B}\x{1E94C}-\x{1E94F}\x{1E950}-\x{1E959}\x{1E95A}-\x{1E95D}\x{1E95E}-\x{1E95F}\x{1E960}-\x{1EC6F}\x{1EC70}\x{1EC71}-\x{1ECAB}\x{1ECAC}\x{1ECAD}-\x{1ECAF}\x{1ECB0}\x{1ECB1}-\x{1ECB4}\x{1ECB5}-\x{1ECBF}\x{1ECC0}-\x{1ECFF}\x{1ED00}\x{1ED01}-\x{1ED2D}\x{1ED2E}\x{1ED2F}-\x{1ED3D}\x{1ED3E}-\x{1ED4F}\x{1ED50}-\x{1EDFF}\x{1EE00}-\x{1EE03}\x{1EE04}\x{1EE05}-\x{1EE1F}\x{1EE20}\x{1EE21}-\x{1EE22}\x{1EE23}\x{1EE24}\x{1EE25}-\x{1EE26}\x{1EE27}\x{1EE28}\x{1EE29}-\x{1EE32}\x{1EE33}\x{1EE34}-\x{1EE37}\x{1EE38}\x{1EE39}\x{1EE3A}\x{1EE3B}\x{1EE3C}-\x{1EE41}\x{1EE42}\x{1EE43}-\x{1EE46}\x{1EE47}\x{1EE48}\x{1EE49}\x{1EE4A}\x{1EE4B}\x{1EE4C}\x{1EE4D}-\x{1EE4F}\x{1EE50}\x{1EE51}-\x{1EE52}\x{1EE53}\x{1EE54}\x{1EE55}-\x{1EE56}\x{1EE57}\x{1EE58}\x{1EE59}\x{1EE5A}\x{1EE5B}\x{1EE5C}\x{1EE5D}\x{1EE5E}\x{1EE5F}\x{1EE60}\x{1EE61}-\x{1EE62}\x{1EE63}\x{1EE64}\x{1EE65}-\x{1EE66}\x{1EE67}-\x{1EE6A}\x{1EE6B}\x{1EE6C}-\x{1EE72}\x{1EE73}\x{1EE74}-\x{1EE77}\x{1EE78}\x{1EE79}-\x{1EE7C}\x{1EE7D}\x{1EE7E}\x{1EE7F}\x{1EE80}-\x{1EE89}\x{1EE8A}\x{1EE8B}-\x{1EE9B}\x{1EE9C}-\x{1EEA0}\x{1EEA1}-\x{1EEA3}\x{1EEA4}\x{1EEA5}-\x{1EEA9}\x{1EEAA}\x{1EEAB}-\x{1EEBB}\x{1EEBC}-\x{1EEEF}\x{1EEF0}-\x{1EEF1}\x{1EEF2}-\x{1EEFF}\x{1EF00}-\x{1EFFF}\x{1F000}-\x{1F02B}\x{1F030}-\x{1F093}\x{1F0A0}-\x{1F0AE}\x{1F0B1}-\x{1F0BF}\x{1F0C1}-\x{1F0CF}\x{1F0D1}-\x{1F0F5}\x{1F100}-\x{1F10A}\x{1F10B}-\x{1F10C}\x{1F10D}-\x{1F10F}\x{1F12F}\x{1F16A}-\x{1F16F}\x{1F1AD}\x{1F260}-\x{1F265}\x{1F300}-\x{1F3FA}\x{1F3FB}-\x{1F3FF}\x{1F400}-\x{1F6D7}\x{1F6E0}-\x{1F6EC}\x{1F6F0}-\x{1F6FC}\x{1F700}-\x{1F773}\x{1F780}-\x{1F7D8}\x{1F7E0}-\x{1F7EB}\x{1F800}-\x{1F80B}\x{1F810}-\x{1F847}\x{1F850}-\x{1F859}\x{1F860}-\x{1F887}\x{1F890}-\x{1F8AD}\x{1F8B0}-\x{1F8B1}\x{1F900}-\x{1F978}\x{1F97A}-\x{1F9CB}\x{1F9CD}-\x{1FA53}\x{1FA60}-\x{1FA6D}\x{1FA70}-\x{1FA74}\x{1FA78}-\x{1FA7A}\x{1FA80}-\x{1FA86}\x{1FA90}-\x{1FAA8}\x{1FAB0}-\x{1FAB6}\x{1FAC0}-\x{1FAC2}\x{1FAD0}-\x{1FAD6}\x{1FB00}-\x{1FB92}\x{1FB94}-\x{1FBCA}\x{1FBF0}-\x{1FBF9}\x{1FFFE}-\x{1FFFF}\x{2FFFE}-\x{2FFFF}\x{3FFFE}-\x{3FFFF}\x{4FFFE}-\x{4FFFF}\x{5FFFE}-\x{5FFFF}\x{6FFFE}-\x{6FFFF}\x{7FFFE}-\x{7FFFF}\x{8FFFE}-\x{8FFFF}\x{9FFFE}-\x{9FFFF}\x{AFFFE}-\x{AFFFF}\x{BFFFE}-\x{BFFFF}\x{CFFFE}-\x{CFFFF}\x{DFFFE}-\x{E0000}\x{E0001}\x{E0002}-\x{E001F}\x{E0020}-\x{E007F}\x{E0080}-\x{E00FF}\x{E0100}-\x{E01EF}\x{E01F0}-\x{E0FFF}\x{EFFFE}-\x{EFFFF}\x{FFFFE}-\x{FFFFF}\x{10FFFE}-\x{10FFFF}]/u'; + const BIDI_STEP_1_RTL = '/^[\x{0590}\x{05BE}\x{05C0}\x{05C3}\x{05C6}\x{05C8}-\x{05CF}\x{05D0}-\x{05EA}\x{05EB}-\x{05EE}\x{05EF}-\x{05F2}\x{05F3}-\x{05F4}\x{05F5}-\x{05FF}\x{0608}\x{060B}\x{060D}\x{061B}\x{061C}\x{061D}\x{061E}-\x{061F}\x{0620}-\x{063F}\x{0640}\x{0641}-\x{064A}\x{066D}\x{066E}-\x{066F}\x{0671}-\x{06D3}\x{06D4}\x{06D5}\x{06E5}-\x{06E6}\x{06EE}-\x{06EF}\x{06FA}-\x{06FC}\x{06FD}-\x{06FE}\x{06FF}\x{0700}-\x{070D}\x{070E}\x{070F}\x{0710}\x{0712}-\x{072F}\x{074B}-\x{074C}\x{074D}-\x{07A5}\x{07B1}\x{07B2}-\x{07BF}\x{07C0}-\x{07C9}\x{07CA}-\x{07EA}\x{07F4}-\x{07F5}\x{07FA}\x{07FB}-\x{07FC}\x{07FE}-\x{07FF}\x{0800}-\x{0815}\x{081A}\x{0824}\x{0828}\x{082E}-\x{082F}\x{0830}-\x{083E}\x{083F}\x{0840}-\x{0858}\x{085C}-\x{085D}\x{085E}\x{085F}\x{0860}-\x{086A}\x{086B}-\x{086F}\x{0870}-\x{089F}\x{08A0}-\x{08B4}\x{08B5}\x{08B6}-\x{08C7}\x{08C8}-\x{08D2}\x{200F}\x{FB1D}\x{FB1F}-\x{FB28}\x{FB2A}-\x{FB36}\x{FB37}\x{FB38}-\x{FB3C}\x{FB3D}\x{FB3E}\x{FB3F}\x{FB40}-\x{FB41}\x{FB42}\x{FB43}-\x{FB44}\x{FB45}\x{FB46}-\x{FB4F}\x{FB50}-\x{FBB1}\x{FBB2}-\x{FBC1}\x{FBC2}-\x{FBD2}\x{FBD3}-\x{FD3D}\x{FD40}-\x{FD4F}\x{FD50}-\x{FD8F}\x{FD90}-\x{FD91}\x{FD92}-\x{FDC7}\x{FDC8}-\x{FDCF}\x{FDF0}-\x{FDFB}\x{FDFC}\x{FDFE}-\x{FDFF}\x{FE70}-\x{FE74}\x{FE75}\x{FE76}-\x{FEFC}\x{FEFD}-\x{FEFE}\x{10800}-\x{10805}\x{10806}-\x{10807}\x{10808}\x{10809}\x{1080A}-\x{10835}\x{10836}\x{10837}-\x{10838}\x{10839}-\x{1083B}\x{1083C}\x{1083D}-\x{1083E}\x{1083F}-\x{10855}\x{10856}\x{10857}\x{10858}-\x{1085F}\x{10860}-\x{10876}\x{10877}-\x{10878}\x{10879}-\x{1087F}\x{10880}-\x{1089E}\x{1089F}-\x{108A6}\x{108A7}-\x{108AF}\x{108B0}-\x{108DF}\x{108E0}-\x{108F2}\x{108F3}\x{108F4}-\x{108F5}\x{108F6}-\x{108FA}\x{108FB}-\x{108FF}\x{10900}-\x{10915}\x{10916}-\x{1091B}\x{1091C}-\x{1091E}\x{10920}-\x{10939}\x{1093A}-\x{1093E}\x{1093F}\x{10940}-\x{1097F}\x{10980}-\x{109B7}\x{109B8}-\x{109BB}\x{109BC}-\x{109BD}\x{109BE}-\x{109BF}\x{109C0}-\x{109CF}\x{109D0}-\x{109D1}\x{109D2}-\x{109FF}\x{10A00}\x{10A04}\x{10A07}-\x{10A0B}\x{10A10}-\x{10A13}\x{10A14}\x{10A15}-\x{10A17}\x{10A18}\x{10A19}-\x{10A35}\x{10A36}-\x{10A37}\x{10A3B}-\x{10A3E}\x{10A40}-\x{10A48}\x{10A49}-\x{10A4F}\x{10A50}-\x{10A58}\x{10A59}-\x{10A5F}\x{10A60}-\x{10A7C}\x{10A7D}-\x{10A7E}\x{10A7F}\x{10A80}-\x{10A9C}\x{10A9D}-\x{10A9F}\x{10AA0}-\x{10ABF}\x{10AC0}-\x{10AC7}\x{10AC8}\x{10AC9}-\x{10AE4}\x{10AE7}-\x{10AEA}\x{10AEB}-\x{10AEF}\x{10AF0}-\x{10AF6}\x{10AF7}-\x{10AFF}\x{10B00}-\x{10B35}\x{10B36}-\x{10B38}\x{10B40}-\x{10B55}\x{10B56}-\x{10B57}\x{10B58}-\x{10B5F}\x{10B60}-\x{10B72}\x{10B73}-\x{10B77}\x{10B78}-\x{10B7F}\x{10B80}-\x{10B91}\x{10B92}-\x{10B98}\x{10B99}-\x{10B9C}\x{10B9D}-\x{10BA8}\x{10BA9}-\x{10BAF}\x{10BB0}-\x{10BFF}\x{10C00}-\x{10C48}\x{10C49}-\x{10C7F}\x{10C80}-\x{10CB2}\x{10CB3}-\x{10CBF}\x{10CC0}-\x{10CF2}\x{10CF3}-\x{10CF9}\x{10CFA}-\x{10CFF}\x{10D00}-\x{10D23}\x{10D28}-\x{10D2F}\x{10D3A}-\x{10D3F}\x{10D40}-\x{10E5F}\x{10E7F}\x{10E80}-\x{10EA9}\x{10EAA}\x{10EAD}\x{10EAE}-\x{10EAF}\x{10EB0}-\x{10EB1}\x{10EB2}-\x{10EFF}\x{10F00}-\x{10F1C}\x{10F1D}-\x{10F26}\x{10F27}\x{10F28}-\x{10F2F}\x{10F30}-\x{10F45}\x{10F51}-\x{10F54}\x{10F55}-\x{10F59}\x{10F5A}-\x{10F6F}\x{10F70}-\x{10FAF}\x{10FB0}-\x{10FC4}\x{10FC5}-\x{10FCB}\x{10FCC}-\x{10FDF}\x{10FE0}-\x{10FF6}\x{10FF7}-\x{10FFF}\x{1E800}-\x{1E8C4}\x{1E8C5}-\x{1E8C6}\x{1E8C7}-\x{1E8CF}\x{1E8D7}-\x{1E8FF}\x{1E900}-\x{1E943}\x{1E94B}\x{1E94C}-\x{1E94F}\x{1E950}-\x{1E959}\x{1E95A}-\x{1E95D}\x{1E95E}-\x{1E95F}\x{1E960}-\x{1EC6F}\x{1EC70}\x{1EC71}-\x{1ECAB}\x{1ECAC}\x{1ECAD}-\x{1ECAF}\x{1ECB0}\x{1ECB1}-\x{1ECB4}\x{1ECB5}-\x{1ECBF}\x{1ECC0}-\x{1ECFF}\x{1ED00}\x{1ED01}-\x{1ED2D}\x{1ED2E}\x{1ED2F}-\x{1ED3D}\x{1ED3E}-\x{1ED4F}\x{1ED50}-\x{1EDFF}\x{1EE00}-\x{1EE03}\x{1EE04}\x{1EE05}-\x{1EE1F}\x{1EE20}\x{1EE21}-\x{1EE22}\x{1EE23}\x{1EE24}\x{1EE25}-\x{1EE26}\x{1EE27}\x{1EE28}\x{1EE29}-\x{1EE32}\x{1EE33}\x{1EE34}-\x{1EE37}\x{1EE38}\x{1EE39}\x{1EE3A}\x{1EE3B}\x{1EE3C}-\x{1EE41}\x{1EE42}\x{1EE43}-\x{1EE46}\x{1EE47}\x{1EE48}\x{1EE49}\x{1EE4A}\x{1EE4B}\x{1EE4C}\x{1EE4D}-\x{1EE4F}\x{1EE50}\x{1EE51}-\x{1EE52}\x{1EE53}\x{1EE54}\x{1EE55}-\x{1EE56}\x{1EE57}\x{1EE58}\x{1EE59}\x{1EE5A}\x{1EE5B}\x{1EE5C}\x{1EE5D}\x{1EE5E}\x{1EE5F}\x{1EE60}\x{1EE61}-\x{1EE62}\x{1EE63}\x{1EE64}\x{1EE65}-\x{1EE66}\x{1EE67}-\x{1EE6A}\x{1EE6B}\x{1EE6C}-\x{1EE72}\x{1EE73}\x{1EE74}-\x{1EE77}\x{1EE78}\x{1EE79}-\x{1EE7C}\x{1EE7D}\x{1EE7E}\x{1EE7F}\x{1EE80}-\x{1EE89}\x{1EE8A}\x{1EE8B}-\x{1EE9B}\x{1EE9C}-\x{1EEA0}\x{1EEA1}-\x{1EEA3}\x{1EEA4}\x{1EEA5}-\x{1EEA9}\x{1EEAA}\x{1EEAB}-\x{1EEBB}\x{1EEBC}-\x{1EEEF}\x{1EEF2}-\x{1EEFF}\x{1EF00}-\x{1EFFF}]/u'; + const BIDI_STEP_2 = '/[^\x{0000}-\x{0008}\x{000E}-\x{001B}\x{0021}-\x{0022}\x{0023}\x{0024}\x{0025}\x{0026}-\x{0027}\x{0028}\x{0029}\x{002A}\x{002B}\x{002C}\x{002D}\x{002E}-\x{002F}\x{0030}-\x{0039}\x{003A}\x{003B}\x{003C}-\x{003E}\x{003F}-\x{0040}\x{005B}\x{005C}\x{005D}\x{005E}\x{005F}\x{0060}\x{007B}\x{007C}\x{007D}\x{007E}\x{007F}-\x{0084}\x{0086}-\x{009F}\x{00A0}\x{00A1}\x{00A2}-\x{00A5}\x{00A6}\x{00A7}\x{00A8}\x{00A9}\x{00AB}\x{00AC}\x{00AD}\x{00AE}\x{00AF}\x{00B0}\x{00B1}\x{00B2}-\x{00B3}\x{00B4}\x{00B6}-\x{00B7}\x{00B8}\x{00B9}\x{00BB}\x{00BC}-\x{00BE}\x{00BF}\x{00D7}\x{00F7}\x{02B9}-\x{02BA}\x{02C2}-\x{02C5}\x{02C6}-\x{02CF}\x{02D2}-\x{02DF}\x{02E5}-\x{02EB}\x{02EC}\x{02ED}\x{02EF}-\x{02FF}\x{0300}-\x{036F}\x{0374}\x{0375}\x{037E}\x{0384}-\x{0385}\x{0387}\x{03F6}\x{0483}-\x{0487}\x{0488}-\x{0489}\x{058A}\x{058D}-\x{058E}\x{058F}\x{0590}\x{0591}-\x{05BD}\x{05BE}\x{05BF}\x{05C0}\x{05C1}-\x{05C2}\x{05C3}\x{05C4}-\x{05C5}\x{05C6}\x{05C7}\x{05C8}-\x{05CF}\x{05D0}-\x{05EA}\x{05EB}-\x{05EE}\x{05EF}-\x{05F2}\x{05F3}-\x{05F4}\x{05F5}-\x{05FF}\x{0600}-\x{0605}\x{0606}-\x{0607}\x{0608}\x{0609}-\x{060A}\x{060B}\x{060C}\x{060D}\x{060E}-\x{060F}\x{0610}-\x{061A}\x{061B}\x{061C}\x{061D}\x{061E}-\x{061F}\x{0620}-\x{063F}\x{0640}\x{0641}-\x{064A}\x{064B}-\x{065F}\x{0660}-\x{0669}\x{066A}\x{066B}-\x{066C}\x{066D}\x{066E}-\x{066F}\x{0670}\x{0671}-\x{06D3}\x{06D4}\x{06D5}\x{06D6}-\x{06DC}\x{06DD}\x{06DE}\x{06DF}-\x{06E4}\x{06E5}-\x{06E6}\x{06E7}-\x{06E8}\x{06E9}\x{06EA}-\x{06ED}\x{06EE}-\x{06EF}\x{06F0}-\x{06F9}\x{06FA}-\x{06FC}\x{06FD}-\x{06FE}\x{06FF}\x{0700}-\x{070D}\x{070E}\x{070F}\x{0710}\x{0711}\x{0712}-\x{072F}\x{0730}-\x{074A}\x{074B}-\x{074C}\x{074D}-\x{07A5}\x{07A6}-\x{07B0}\x{07B1}\x{07B2}-\x{07BF}\x{07C0}-\x{07C9}\x{07CA}-\x{07EA}\x{07EB}-\x{07F3}\x{07F4}-\x{07F5}\x{07F6}\x{07F7}-\x{07F9}\x{07FA}\x{07FB}-\x{07FC}\x{07FD}\x{07FE}-\x{07FF}\x{0800}-\x{0815}\x{0816}-\x{0819}\x{081A}\x{081B}-\x{0823}\x{0824}\x{0825}-\x{0827}\x{0828}\x{0829}-\x{082D}\x{082E}-\x{082F}\x{0830}-\x{083E}\x{083F}\x{0840}-\x{0858}\x{0859}-\x{085B}\x{085C}-\x{085D}\x{085E}\x{085F}\x{0860}-\x{086A}\x{086B}-\x{086F}\x{0870}-\x{089F}\x{08A0}-\x{08B4}\x{08B5}\x{08B6}-\x{08C7}\x{08C8}-\x{08D2}\x{08D3}-\x{08E1}\x{08E2}\x{08E3}-\x{0902}\x{093A}\x{093C}\x{0941}-\x{0948}\x{094D}\x{0951}-\x{0957}\x{0962}-\x{0963}\x{0981}\x{09BC}\x{09C1}-\x{09C4}\x{09CD}\x{09E2}-\x{09E3}\x{09F2}-\x{09F3}\x{09FB}\x{09FE}\x{0A01}-\x{0A02}\x{0A3C}\x{0A41}-\x{0A42}\x{0A47}-\x{0A48}\x{0A4B}-\x{0A4D}\x{0A51}\x{0A70}-\x{0A71}\x{0A75}\x{0A81}-\x{0A82}\x{0ABC}\x{0AC1}-\x{0AC5}\x{0AC7}-\x{0AC8}\x{0ACD}\x{0AE2}-\x{0AE3}\x{0AF1}\x{0AFA}-\x{0AFF}\x{0B01}\x{0B3C}\x{0B3F}\x{0B41}-\x{0B44}\x{0B4D}\x{0B55}-\x{0B56}\x{0B62}-\x{0B63}\x{0B82}\x{0BC0}\x{0BCD}\x{0BF3}-\x{0BF8}\x{0BF9}\x{0BFA}\x{0C00}\x{0C04}\x{0C3E}-\x{0C40}\x{0C46}-\x{0C48}\x{0C4A}-\x{0C4D}\x{0C55}-\x{0C56}\x{0C62}-\x{0C63}\x{0C78}-\x{0C7E}\x{0C81}\x{0CBC}\x{0CCC}-\x{0CCD}\x{0CE2}-\x{0CE3}\x{0D00}-\x{0D01}\x{0D3B}-\x{0D3C}\x{0D41}-\x{0D44}\x{0D4D}\x{0D62}-\x{0D63}\x{0D81}\x{0DCA}\x{0DD2}-\x{0DD4}\x{0DD6}\x{0E31}\x{0E34}-\x{0E3A}\x{0E3F}\x{0E47}-\x{0E4E}\x{0EB1}\x{0EB4}-\x{0EBC}\x{0EC8}-\x{0ECD}\x{0F18}-\x{0F19}\x{0F35}\x{0F37}\x{0F39}\x{0F3A}\x{0F3B}\x{0F3C}\x{0F3D}\x{0F71}-\x{0F7E}\x{0F80}-\x{0F84}\x{0F86}-\x{0F87}\x{0F8D}-\x{0F97}\x{0F99}-\x{0FBC}\x{0FC6}\x{102D}-\x{1030}\x{1032}-\x{1037}\x{1039}-\x{103A}\x{103D}-\x{103E}\x{1058}-\x{1059}\x{105E}-\x{1060}\x{1071}-\x{1074}\x{1082}\x{1085}-\x{1086}\x{108D}\x{109D}\x{135D}-\x{135F}\x{1390}-\x{1399}\x{1400}\x{169B}\x{169C}\x{1712}-\x{1714}\x{1732}-\x{1734}\x{1752}-\x{1753}\x{1772}-\x{1773}\x{17B4}-\x{17B5}\x{17B7}-\x{17BD}\x{17C6}\x{17C9}-\x{17D3}\x{17DB}\x{17DD}\x{17F0}-\x{17F9}\x{1800}-\x{1805}\x{1806}\x{1807}-\x{180A}\x{180B}-\x{180D}\x{180E}\x{1885}-\x{1886}\x{18A9}\x{1920}-\x{1922}\x{1927}-\x{1928}\x{1932}\x{1939}-\x{193B}\x{1940}\x{1944}-\x{1945}\x{19DE}-\x{19FF}\x{1A17}-\x{1A18}\x{1A1B}\x{1A56}\x{1A58}-\x{1A5E}\x{1A60}\x{1A62}\x{1A65}-\x{1A6C}\x{1A73}-\x{1A7C}\x{1A7F}\x{1AB0}-\x{1ABD}\x{1ABE}\x{1ABF}-\x{1AC0}\x{1B00}-\x{1B03}\x{1B34}\x{1B36}-\x{1B3A}\x{1B3C}\x{1B42}\x{1B6B}-\x{1B73}\x{1B80}-\x{1B81}\x{1BA2}-\x{1BA5}\x{1BA8}-\x{1BA9}\x{1BAB}-\x{1BAD}\x{1BE6}\x{1BE8}-\x{1BE9}\x{1BED}\x{1BEF}-\x{1BF1}\x{1C2C}-\x{1C33}\x{1C36}-\x{1C37}\x{1CD0}-\x{1CD2}\x{1CD4}-\x{1CE0}\x{1CE2}-\x{1CE8}\x{1CED}\x{1CF4}\x{1CF8}-\x{1CF9}\x{1DC0}-\x{1DF9}\x{1DFB}-\x{1DFF}\x{1FBD}\x{1FBF}-\x{1FC1}\x{1FCD}-\x{1FCF}\x{1FDD}-\x{1FDF}\x{1FED}-\x{1FEF}\x{1FFD}-\x{1FFE}\x{200B}-\x{200D}\x{200F}\x{2010}-\x{2015}\x{2016}-\x{2017}\x{2018}\x{2019}\x{201A}\x{201B}-\x{201C}\x{201D}\x{201E}\x{201F}\x{2020}-\x{2027}\x{202F}\x{2030}-\x{2034}\x{2035}-\x{2038}\x{2039}\x{203A}\x{203B}-\x{203E}\x{203F}-\x{2040}\x{2041}-\x{2043}\x{2044}\x{2045}\x{2046}\x{2047}-\x{2051}\x{2052}\x{2053}\x{2054}\x{2055}-\x{205E}\x{2060}-\x{2064}\x{2065}\x{206A}-\x{206F}\x{2070}\x{2074}-\x{2079}\x{207A}-\x{207B}\x{207C}\x{207D}\x{207E}\x{2080}-\x{2089}\x{208A}-\x{208B}\x{208C}\x{208D}\x{208E}\x{20A0}-\x{20BF}\x{20C0}-\x{20CF}\x{20D0}-\x{20DC}\x{20DD}-\x{20E0}\x{20E1}\x{20E2}-\x{20E4}\x{20E5}-\x{20F0}\x{2100}-\x{2101}\x{2103}-\x{2106}\x{2108}-\x{2109}\x{2114}\x{2116}-\x{2117}\x{2118}\x{211E}-\x{2123}\x{2125}\x{2127}\x{2129}\x{212E}\x{213A}-\x{213B}\x{2140}-\x{2144}\x{214A}\x{214B}\x{214C}-\x{214D}\x{2150}-\x{215F}\x{2189}\x{218A}-\x{218B}\x{2190}-\x{2194}\x{2195}-\x{2199}\x{219A}-\x{219B}\x{219C}-\x{219F}\x{21A0}\x{21A1}-\x{21A2}\x{21A3}\x{21A4}-\x{21A5}\x{21A6}\x{21A7}-\x{21AD}\x{21AE}\x{21AF}-\x{21CD}\x{21CE}-\x{21CF}\x{21D0}-\x{21D1}\x{21D2}\x{21D3}\x{21D4}\x{21D5}-\x{21F3}\x{21F4}-\x{2211}\x{2212}\x{2213}\x{2214}-\x{22FF}\x{2300}-\x{2307}\x{2308}\x{2309}\x{230A}\x{230B}\x{230C}-\x{231F}\x{2320}-\x{2321}\x{2322}-\x{2328}\x{2329}\x{232A}\x{232B}-\x{2335}\x{237B}\x{237C}\x{237D}-\x{2394}\x{2396}-\x{239A}\x{239B}-\x{23B3}\x{23B4}-\x{23DB}\x{23DC}-\x{23E1}\x{23E2}-\x{2426}\x{2440}-\x{244A}\x{2460}-\x{2487}\x{2488}-\x{249B}\x{24EA}-\x{24FF}\x{2500}-\x{25B6}\x{25B7}\x{25B8}-\x{25C0}\x{25C1}\x{25C2}-\x{25F7}\x{25F8}-\x{25FF}\x{2600}-\x{266E}\x{266F}\x{2670}-\x{26AB}\x{26AD}-\x{2767}\x{2768}\x{2769}\x{276A}\x{276B}\x{276C}\x{276D}\x{276E}\x{276F}\x{2770}\x{2771}\x{2772}\x{2773}\x{2774}\x{2775}\x{2776}-\x{2793}\x{2794}-\x{27BF}\x{27C0}-\x{27C4}\x{27C5}\x{27C6}\x{27C7}-\x{27E5}\x{27E6}\x{27E7}\x{27E8}\x{27E9}\x{27EA}\x{27EB}\x{27EC}\x{27ED}\x{27EE}\x{27EF}\x{27F0}-\x{27FF}\x{2900}-\x{2982}\x{2983}\x{2984}\x{2985}\x{2986}\x{2987}\x{2988}\x{2989}\x{298A}\x{298B}\x{298C}\x{298D}\x{298E}\x{298F}\x{2990}\x{2991}\x{2992}\x{2993}\x{2994}\x{2995}\x{2996}\x{2997}\x{2998}\x{2999}-\x{29D7}\x{29D8}\x{29D9}\x{29DA}\x{29DB}\x{29DC}-\x{29FB}\x{29FC}\x{29FD}\x{29FE}-\x{2AFF}\x{2B00}-\x{2B2F}\x{2B30}-\x{2B44}\x{2B45}-\x{2B46}\x{2B47}-\x{2B4C}\x{2B4D}-\x{2B73}\x{2B76}-\x{2B95}\x{2B97}-\x{2BFF}\x{2CE5}-\x{2CEA}\x{2CEF}-\x{2CF1}\x{2CF9}-\x{2CFC}\x{2CFD}\x{2CFE}-\x{2CFF}\x{2D7F}\x{2DE0}-\x{2DFF}\x{2E00}-\x{2E01}\x{2E02}\x{2E03}\x{2E04}\x{2E05}\x{2E06}-\x{2E08}\x{2E09}\x{2E0A}\x{2E0B}\x{2E0C}\x{2E0D}\x{2E0E}-\x{2E16}\x{2E17}\x{2E18}-\x{2E19}\x{2E1A}\x{2E1B}\x{2E1C}\x{2E1D}\x{2E1E}-\x{2E1F}\x{2E20}\x{2E21}\x{2E22}\x{2E23}\x{2E24}\x{2E25}\x{2E26}\x{2E27}\x{2E28}\x{2E29}\x{2E2A}-\x{2E2E}\x{2E2F}\x{2E30}-\x{2E39}\x{2E3A}-\x{2E3B}\x{2E3C}-\x{2E3F}\x{2E40}\x{2E41}\x{2E42}\x{2E43}-\x{2E4F}\x{2E50}-\x{2E51}\x{2E52}\x{2E80}-\x{2E99}\x{2E9B}-\x{2EF3}\x{2F00}-\x{2FD5}\x{2FF0}-\x{2FFB}\x{3001}-\x{3003}\x{3004}\x{3008}\x{3009}\x{300A}\x{300B}\x{300C}\x{300D}\x{300E}\x{300F}\x{3010}\x{3011}\x{3012}-\x{3013}\x{3014}\x{3015}\x{3016}\x{3017}\x{3018}\x{3019}\x{301A}\x{301B}\x{301C}\x{301D}\x{301E}-\x{301F}\x{3020}\x{302A}-\x{302D}\x{3030}\x{3036}-\x{3037}\x{303D}\x{303E}-\x{303F}\x{3099}-\x{309A}\x{309B}-\x{309C}\x{30A0}\x{30FB}\x{31C0}-\x{31E3}\x{321D}-\x{321E}\x{3250}\x{3251}-\x{325F}\x{327C}-\x{327E}\x{32B1}-\x{32BF}\x{32CC}-\x{32CF}\x{3377}-\x{337A}\x{33DE}-\x{33DF}\x{33FF}\x{4DC0}-\x{4DFF}\x{A490}-\x{A4C6}\x{A60D}-\x{A60F}\x{A66F}\x{A670}-\x{A672}\x{A673}\x{A674}-\x{A67D}\x{A67E}\x{A67F}\x{A69E}-\x{A69F}\x{A6F0}-\x{A6F1}\x{A700}-\x{A716}\x{A717}-\x{A71F}\x{A720}-\x{A721}\x{A788}\x{A802}\x{A806}\x{A80B}\x{A825}-\x{A826}\x{A828}-\x{A82B}\x{A82C}\x{A838}\x{A839}\x{A874}-\x{A877}\x{A8C4}-\x{A8C5}\x{A8E0}-\x{A8F1}\x{A8FF}\x{A926}-\x{A92D}\x{A947}-\x{A951}\x{A980}-\x{A982}\x{A9B3}\x{A9B6}-\x{A9B9}\x{A9BC}-\x{A9BD}\x{A9E5}\x{AA29}-\x{AA2E}\x{AA31}-\x{AA32}\x{AA35}-\x{AA36}\x{AA43}\x{AA4C}\x{AA7C}\x{AAB0}\x{AAB2}-\x{AAB4}\x{AAB7}-\x{AAB8}\x{AABE}-\x{AABF}\x{AAC1}\x{AAEC}-\x{AAED}\x{AAF6}\x{AB6A}-\x{AB6B}\x{ABE5}\x{ABE8}\x{ABED}\x{FB1D}\x{FB1E}\x{FB1F}-\x{FB28}\x{FB29}\x{FB2A}-\x{FB36}\x{FB37}\x{FB38}-\x{FB3C}\x{FB3D}\x{FB3E}\x{FB3F}\x{FB40}-\x{FB41}\x{FB42}\x{FB43}-\x{FB44}\x{FB45}\x{FB46}-\x{FB4F}\x{FB50}-\x{FBB1}\x{FBB2}-\x{FBC1}\x{FBC2}-\x{FBD2}\x{FBD3}-\x{FD3D}\x{FD3E}\x{FD3F}\x{FD40}-\x{FD4F}\x{FD50}-\x{FD8F}\x{FD90}-\x{FD91}\x{FD92}-\x{FDC7}\x{FDC8}-\x{FDCF}\x{FDD0}-\x{FDEF}\x{FDF0}-\x{FDFB}\x{FDFC}\x{FDFD}\x{FDFE}-\x{FDFF}\x{FE00}-\x{FE0F}\x{FE10}-\x{FE16}\x{FE17}\x{FE18}\x{FE19}\x{FE20}-\x{FE2F}\x{FE30}\x{FE31}-\x{FE32}\x{FE33}-\x{FE34}\x{FE35}\x{FE36}\x{FE37}\x{FE38}\x{FE39}\x{FE3A}\x{FE3B}\x{FE3C}\x{FE3D}\x{FE3E}\x{FE3F}\x{FE40}\x{FE41}\x{FE42}\x{FE43}\x{FE44}\x{FE45}-\x{FE46}\x{FE47}\x{FE48}\x{FE49}-\x{FE4C}\x{FE4D}-\x{FE4F}\x{FE50}\x{FE51}\x{FE52}\x{FE54}\x{FE55}\x{FE56}-\x{FE57}\x{FE58}\x{FE59}\x{FE5A}\x{FE5B}\x{FE5C}\x{FE5D}\x{FE5E}\x{FE5F}\x{FE60}-\x{FE61}\x{FE62}\x{FE63}\x{FE64}-\x{FE66}\x{FE68}\x{FE69}\x{FE6A}\x{FE6B}\x{FE70}-\x{FE74}\x{FE75}\x{FE76}-\x{FEFC}\x{FEFD}-\x{FEFE}\x{FEFF}\x{FF01}-\x{FF02}\x{FF03}\x{FF04}\x{FF05}\x{FF06}-\x{FF07}\x{FF08}\x{FF09}\x{FF0A}\x{FF0B}\x{FF0C}\x{FF0D}\x{FF0E}-\x{FF0F}\x{FF10}-\x{FF19}\x{FF1A}\x{FF1B}\x{FF1C}-\x{FF1E}\x{FF1F}-\x{FF20}\x{FF3B}\x{FF3C}\x{FF3D}\x{FF3E}\x{FF3F}\x{FF40}\x{FF5B}\x{FF5C}\x{FF5D}\x{FF5E}\x{FF5F}\x{FF60}\x{FF61}\x{FF62}\x{FF63}\x{FF64}-\x{FF65}\x{FFE0}-\x{FFE1}\x{FFE2}\x{FFE3}\x{FFE4}\x{FFE5}-\x{FFE6}\x{FFE8}\x{FFE9}-\x{FFEC}\x{FFED}-\x{FFEE}\x{FFF0}-\x{FFF8}\x{FFF9}-\x{FFFB}\x{FFFC}-\x{FFFD}\x{FFFE}-\x{FFFF}\x{10101}\x{10140}-\x{10174}\x{10175}-\x{10178}\x{10179}-\x{10189}\x{1018A}-\x{1018B}\x{1018C}\x{10190}-\x{1019C}\x{101A0}\x{101FD}\x{102E0}\x{102E1}-\x{102FB}\x{10376}-\x{1037A}\x{10800}-\x{10805}\x{10806}-\x{10807}\x{10808}\x{10809}\x{1080A}-\x{10835}\x{10836}\x{10837}-\x{10838}\x{10839}-\x{1083B}\x{1083C}\x{1083D}-\x{1083E}\x{1083F}-\x{10855}\x{10856}\x{10857}\x{10858}-\x{1085F}\x{10860}-\x{10876}\x{10877}-\x{10878}\x{10879}-\x{1087F}\x{10880}-\x{1089E}\x{1089F}-\x{108A6}\x{108A7}-\x{108AF}\x{108B0}-\x{108DF}\x{108E0}-\x{108F2}\x{108F3}\x{108F4}-\x{108F5}\x{108F6}-\x{108FA}\x{108FB}-\x{108FF}\x{10900}-\x{10915}\x{10916}-\x{1091B}\x{1091C}-\x{1091E}\x{1091F}\x{10920}-\x{10939}\x{1093A}-\x{1093E}\x{1093F}\x{10940}-\x{1097F}\x{10980}-\x{109B7}\x{109B8}-\x{109BB}\x{109BC}-\x{109BD}\x{109BE}-\x{109BF}\x{109C0}-\x{109CF}\x{109D0}-\x{109D1}\x{109D2}-\x{109FF}\x{10A00}\x{10A01}-\x{10A03}\x{10A04}\x{10A05}-\x{10A06}\x{10A07}-\x{10A0B}\x{10A0C}-\x{10A0F}\x{10A10}-\x{10A13}\x{10A14}\x{10A15}-\x{10A17}\x{10A18}\x{10A19}-\x{10A35}\x{10A36}-\x{10A37}\x{10A38}-\x{10A3A}\x{10A3B}-\x{10A3E}\x{10A3F}\x{10A40}-\x{10A48}\x{10A49}-\x{10A4F}\x{10A50}-\x{10A58}\x{10A59}-\x{10A5F}\x{10A60}-\x{10A7C}\x{10A7D}-\x{10A7E}\x{10A7F}\x{10A80}-\x{10A9C}\x{10A9D}-\x{10A9F}\x{10AA0}-\x{10ABF}\x{10AC0}-\x{10AC7}\x{10AC8}\x{10AC9}-\x{10AE4}\x{10AE5}-\x{10AE6}\x{10AE7}-\x{10AEA}\x{10AEB}-\x{10AEF}\x{10AF0}-\x{10AF6}\x{10AF7}-\x{10AFF}\x{10B00}-\x{10B35}\x{10B36}-\x{10B38}\x{10B39}-\x{10B3F}\x{10B40}-\x{10B55}\x{10B56}-\x{10B57}\x{10B58}-\x{10B5F}\x{10B60}-\x{10B72}\x{10B73}-\x{10B77}\x{10B78}-\x{10B7F}\x{10B80}-\x{10B91}\x{10B92}-\x{10B98}\x{10B99}-\x{10B9C}\x{10B9D}-\x{10BA8}\x{10BA9}-\x{10BAF}\x{10BB0}-\x{10BFF}\x{10C00}-\x{10C48}\x{10C49}-\x{10C7F}\x{10C80}-\x{10CB2}\x{10CB3}-\x{10CBF}\x{10CC0}-\x{10CF2}\x{10CF3}-\x{10CF9}\x{10CFA}-\x{10CFF}\x{10D00}-\x{10D23}\x{10D24}-\x{10D27}\x{10D28}-\x{10D2F}\x{10D30}-\x{10D39}\x{10D3A}-\x{10D3F}\x{10D40}-\x{10E5F}\x{10E60}-\x{10E7E}\x{10E7F}\x{10E80}-\x{10EA9}\x{10EAA}\x{10EAB}-\x{10EAC}\x{10EAD}\x{10EAE}-\x{10EAF}\x{10EB0}-\x{10EB1}\x{10EB2}-\x{10EFF}\x{10F00}-\x{10F1C}\x{10F1D}-\x{10F26}\x{10F27}\x{10F28}-\x{10F2F}\x{10F30}-\x{10F45}\x{10F46}-\x{10F50}\x{10F51}-\x{10F54}\x{10F55}-\x{10F59}\x{10F5A}-\x{10F6F}\x{10F70}-\x{10FAF}\x{10FB0}-\x{10FC4}\x{10FC5}-\x{10FCB}\x{10FCC}-\x{10FDF}\x{10FE0}-\x{10FF6}\x{10FF7}-\x{10FFF}\x{11001}\x{11038}-\x{11046}\x{11052}-\x{11065}\x{1107F}-\x{11081}\x{110B3}-\x{110B6}\x{110B9}-\x{110BA}\x{11100}-\x{11102}\x{11127}-\x{1112B}\x{1112D}-\x{11134}\x{11173}\x{11180}-\x{11181}\x{111B6}-\x{111BE}\x{111C9}-\x{111CC}\x{111CF}\x{1122F}-\x{11231}\x{11234}\x{11236}-\x{11237}\x{1123E}\x{112DF}\x{112E3}-\x{112EA}\x{11300}-\x{11301}\x{1133B}-\x{1133C}\x{11340}\x{11366}-\x{1136C}\x{11370}-\x{11374}\x{11438}-\x{1143F}\x{11442}-\x{11444}\x{11446}\x{1145E}\x{114B3}-\x{114B8}\x{114BA}\x{114BF}-\x{114C0}\x{114C2}-\x{114C3}\x{115B2}-\x{115B5}\x{115BC}-\x{115BD}\x{115BF}-\x{115C0}\x{115DC}-\x{115DD}\x{11633}-\x{1163A}\x{1163D}\x{1163F}-\x{11640}\x{11660}-\x{1166C}\x{116AB}\x{116AD}\x{116B0}-\x{116B5}\x{116B7}\x{1171D}-\x{1171F}\x{11722}-\x{11725}\x{11727}-\x{1172B}\x{1182F}-\x{11837}\x{11839}-\x{1183A}\x{1193B}-\x{1193C}\x{1193E}\x{11943}\x{119D4}-\x{119D7}\x{119DA}-\x{119DB}\x{119E0}\x{11A01}-\x{11A06}\x{11A09}-\x{11A0A}\x{11A33}-\x{11A38}\x{11A3B}-\x{11A3E}\x{11A47}\x{11A51}-\x{11A56}\x{11A59}-\x{11A5B}\x{11A8A}-\x{11A96}\x{11A98}-\x{11A99}\x{11C30}-\x{11C36}\x{11C38}-\x{11C3D}\x{11C92}-\x{11CA7}\x{11CAA}-\x{11CB0}\x{11CB2}-\x{11CB3}\x{11CB5}-\x{11CB6}\x{11D31}-\x{11D36}\x{11D3A}\x{11D3C}-\x{11D3D}\x{11D3F}-\x{11D45}\x{11D47}\x{11D90}-\x{11D91}\x{11D95}\x{11D97}\x{11EF3}-\x{11EF4}\x{11FD5}-\x{11FDC}\x{11FDD}-\x{11FE0}\x{11FE1}-\x{11FF1}\x{16AF0}-\x{16AF4}\x{16B30}-\x{16B36}\x{16F4F}\x{16F8F}-\x{16F92}\x{16FE2}\x{16FE4}\x{1BC9D}-\x{1BC9E}\x{1BCA0}-\x{1BCA3}\x{1D167}-\x{1D169}\x{1D173}-\x{1D17A}\x{1D17B}-\x{1D182}\x{1D185}-\x{1D18B}\x{1D1AA}-\x{1D1AD}\x{1D200}-\x{1D241}\x{1D242}-\x{1D244}\x{1D245}\x{1D300}-\x{1D356}\x{1D6DB}\x{1D715}\x{1D74F}\x{1D789}\x{1D7C3}\x{1D7CE}-\x{1D7FF}\x{1DA00}-\x{1DA36}\x{1DA3B}-\x{1DA6C}\x{1DA75}\x{1DA84}\x{1DA9B}-\x{1DA9F}\x{1DAA1}-\x{1DAAF}\x{1E000}-\x{1E006}\x{1E008}-\x{1E018}\x{1E01B}-\x{1E021}\x{1E023}-\x{1E024}\x{1E026}-\x{1E02A}\x{1E130}-\x{1E136}\x{1E2EC}-\x{1E2EF}\x{1E2FF}\x{1E800}-\x{1E8C4}\x{1E8C5}-\x{1E8C6}\x{1E8C7}-\x{1E8CF}\x{1E8D0}-\x{1E8D6}\x{1E8D7}-\x{1E8FF}\x{1E900}-\x{1E943}\x{1E944}-\x{1E94A}\x{1E94B}\x{1E94C}-\x{1E94F}\x{1E950}-\x{1E959}\x{1E95A}-\x{1E95D}\x{1E95E}-\x{1E95F}\x{1E960}-\x{1EC6F}\x{1EC70}\x{1EC71}-\x{1ECAB}\x{1ECAC}\x{1ECAD}-\x{1ECAF}\x{1ECB0}\x{1ECB1}-\x{1ECB4}\x{1ECB5}-\x{1ECBF}\x{1ECC0}-\x{1ECFF}\x{1ED00}\x{1ED01}-\x{1ED2D}\x{1ED2E}\x{1ED2F}-\x{1ED3D}\x{1ED3E}-\x{1ED4F}\x{1ED50}-\x{1EDFF}\x{1EE00}-\x{1EE03}\x{1EE04}\x{1EE05}-\x{1EE1F}\x{1EE20}\x{1EE21}-\x{1EE22}\x{1EE23}\x{1EE24}\x{1EE25}-\x{1EE26}\x{1EE27}\x{1EE28}\x{1EE29}-\x{1EE32}\x{1EE33}\x{1EE34}-\x{1EE37}\x{1EE38}\x{1EE39}\x{1EE3A}\x{1EE3B}\x{1EE3C}-\x{1EE41}\x{1EE42}\x{1EE43}-\x{1EE46}\x{1EE47}\x{1EE48}\x{1EE49}\x{1EE4A}\x{1EE4B}\x{1EE4C}\x{1EE4D}-\x{1EE4F}\x{1EE50}\x{1EE51}-\x{1EE52}\x{1EE53}\x{1EE54}\x{1EE55}-\x{1EE56}\x{1EE57}\x{1EE58}\x{1EE59}\x{1EE5A}\x{1EE5B}\x{1EE5C}\x{1EE5D}\x{1EE5E}\x{1EE5F}\x{1EE60}\x{1EE61}-\x{1EE62}\x{1EE63}\x{1EE64}\x{1EE65}-\x{1EE66}\x{1EE67}-\x{1EE6A}\x{1EE6B}\x{1EE6C}-\x{1EE72}\x{1EE73}\x{1EE74}-\x{1EE77}\x{1EE78}\x{1EE79}-\x{1EE7C}\x{1EE7D}\x{1EE7E}\x{1EE7F}\x{1EE80}-\x{1EE89}\x{1EE8A}\x{1EE8B}-\x{1EE9B}\x{1EE9C}-\x{1EEA0}\x{1EEA1}-\x{1EEA3}\x{1EEA4}\x{1EEA5}-\x{1EEA9}\x{1EEAA}\x{1EEAB}-\x{1EEBB}\x{1EEBC}-\x{1EEEF}\x{1EEF0}-\x{1EEF1}\x{1EEF2}-\x{1EEFF}\x{1EF00}-\x{1EFFF}\x{1F000}-\x{1F02B}\x{1F030}-\x{1F093}\x{1F0A0}-\x{1F0AE}\x{1F0B1}-\x{1F0BF}\x{1F0C1}-\x{1F0CF}\x{1F0D1}-\x{1F0F5}\x{1F100}-\x{1F10A}\x{1F10B}-\x{1F10C}\x{1F10D}-\x{1F10F}\x{1F12F}\x{1F16A}-\x{1F16F}\x{1F1AD}\x{1F260}-\x{1F265}\x{1F300}-\x{1F3FA}\x{1F3FB}-\x{1F3FF}\x{1F400}-\x{1F6D7}\x{1F6E0}-\x{1F6EC}\x{1F6F0}-\x{1F6FC}\x{1F700}-\x{1F773}\x{1F780}-\x{1F7D8}\x{1F7E0}-\x{1F7EB}\x{1F800}-\x{1F80B}\x{1F810}-\x{1F847}\x{1F850}-\x{1F859}\x{1F860}-\x{1F887}\x{1F890}-\x{1F8AD}\x{1F8B0}-\x{1F8B1}\x{1F900}-\x{1F978}\x{1F97A}-\x{1F9CB}\x{1F9CD}-\x{1FA53}\x{1FA60}-\x{1FA6D}\x{1FA70}-\x{1FA74}\x{1FA78}-\x{1FA7A}\x{1FA80}-\x{1FA86}\x{1FA90}-\x{1FAA8}\x{1FAB0}-\x{1FAB6}\x{1FAC0}-\x{1FAC2}\x{1FAD0}-\x{1FAD6}\x{1FB00}-\x{1FB92}\x{1FB94}-\x{1FBCA}\x{1FBF0}-\x{1FBF9}\x{1FFFE}-\x{1FFFF}\x{2FFFE}-\x{2FFFF}\x{3FFFE}-\x{3FFFF}\x{4FFFE}-\x{4FFFF}\x{5FFFE}-\x{5FFFF}\x{6FFFE}-\x{6FFFF}\x{7FFFE}-\x{7FFFF}\x{8FFFE}-\x{8FFFF}\x{9FFFE}-\x{9FFFF}\x{AFFFE}-\x{AFFFF}\x{BFFFE}-\x{BFFFF}\x{CFFFE}-\x{CFFFF}\x{DFFFE}-\x{E0000}\x{E0001}\x{E0002}-\x{E001F}\x{E0020}-\x{E007F}\x{E0080}-\x{E00FF}\x{E0100}-\x{E01EF}\x{E01F0}-\x{E0FFF}\x{EFFFE}-\x{EFFFF}\x{FFFFE}-\x{FFFFF}\x{10FFFE}-\x{10FFFF}]/u'; + const BIDI_STEP_3 = '/[\x{0030}-\x{0039}\x{00B2}-\x{00B3}\x{00B9}\x{0590}\x{05BE}\x{05C0}\x{05C3}\x{05C6}\x{05C8}-\x{05CF}\x{05D0}-\x{05EA}\x{05EB}-\x{05EE}\x{05EF}-\x{05F2}\x{05F3}-\x{05F4}\x{05F5}-\x{05FF}\x{0600}-\x{0605}\x{0608}\x{060B}\x{060D}\x{061B}\x{061C}\x{061D}\x{061E}-\x{061F}\x{0620}-\x{063F}\x{0640}\x{0641}-\x{064A}\x{0660}-\x{0669}\x{066B}-\x{066C}\x{066D}\x{066E}-\x{066F}\x{0671}-\x{06D3}\x{06D4}\x{06D5}\x{06DD}\x{06E5}-\x{06E6}\x{06EE}-\x{06EF}\x{06F0}-\x{06F9}\x{06FA}-\x{06FC}\x{06FD}-\x{06FE}\x{06FF}\x{0700}-\x{070D}\x{070E}\x{070F}\x{0710}\x{0712}-\x{072F}\x{074B}-\x{074C}\x{074D}-\x{07A5}\x{07B1}\x{07B2}-\x{07BF}\x{07C0}-\x{07C9}\x{07CA}-\x{07EA}\x{07F4}-\x{07F5}\x{07FA}\x{07FB}-\x{07FC}\x{07FE}-\x{07FF}\x{0800}-\x{0815}\x{081A}\x{0824}\x{0828}\x{082E}-\x{082F}\x{0830}-\x{083E}\x{083F}\x{0840}-\x{0858}\x{085C}-\x{085D}\x{085E}\x{085F}\x{0860}-\x{086A}\x{086B}-\x{086F}\x{0870}-\x{089F}\x{08A0}-\x{08B4}\x{08B5}\x{08B6}-\x{08C7}\x{08C8}-\x{08D2}\x{08E2}\x{200F}\x{2070}\x{2074}-\x{2079}\x{2080}-\x{2089}\x{2488}-\x{249B}\x{FB1D}\x{FB1F}-\x{FB28}\x{FB2A}-\x{FB36}\x{FB37}\x{FB38}-\x{FB3C}\x{FB3D}\x{FB3E}\x{FB3F}\x{FB40}-\x{FB41}\x{FB42}\x{FB43}-\x{FB44}\x{FB45}\x{FB46}-\x{FB4F}\x{FB50}-\x{FBB1}\x{FBB2}-\x{FBC1}\x{FBC2}-\x{FBD2}\x{FBD3}-\x{FD3D}\x{FD40}-\x{FD4F}\x{FD50}-\x{FD8F}\x{FD90}-\x{FD91}\x{FD92}-\x{FDC7}\x{FDC8}-\x{FDCF}\x{FDF0}-\x{FDFB}\x{FDFC}\x{FDFE}-\x{FDFF}\x{FE70}-\x{FE74}\x{FE75}\x{FE76}-\x{FEFC}\x{FEFD}-\x{FEFE}\x{FF10}-\x{FF19}\x{102E1}-\x{102FB}\x{10800}-\x{10805}\x{10806}-\x{10807}\x{10808}\x{10809}\x{1080A}-\x{10835}\x{10836}\x{10837}-\x{10838}\x{10839}-\x{1083B}\x{1083C}\x{1083D}-\x{1083E}\x{1083F}-\x{10855}\x{10856}\x{10857}\x{10858}-\x{1085F}\x{10860}-\x{10876}\x{10877}-\x{10878}\x{10879}-\x{1087F}\x{10880}-\x{1089E}\x{1089F}-\x{108A6}\x{108A7}-\x{108AF}\x{108B0}-\x{108DF}\x{108E0}-\x{108F2}\x{108F3}\x{108F4}-\x{108F5}\x{108F6}-\x{108FA}\x{108FB}-\x{108FF}\x{10900}-\x{10915}\x{10916}-\x{1091B}\x{1091C}-\x{1091E}\x{10920}-\x{10939}\x{1093A}-\x{1093E}\x{1093F}\x{10940}-\x{1097F}\x{10980}-\x{109B7}\x{109B8}-\x{109BB}\x{109BC}-\x{109BD}\x{109BE}-\x{109BF}\x{109C0}-\x{109CF}\x{109D0}-\x{109D1}\x{109D2}-\x{109FF}\x{10A00}\x{10A04}\x{10A07}-\x{10A0B}\x{10A10}-\x{10A13}\x{10A14}\x{10A15}-\x{10A17}\x{10A18}\x{10A19}-\x{10A35}\x{10A36}-\x{10A37}\x{10A3B}-\x{10A3E}\x{10A40}-\x{10A48}\x{10A49}-\x{10A4F}\x{10A50}-\x{10A58}\x{10A59}-\x{10A5F}\x{10A60}-\x{10A7C}\x{10A7D}-\x{10A7E}\x{10A7F}\x{10A80}-\x{10A9C}\x{10A9D}-\x{10A9F}\x{10AA0}-\x{10ABF}\x{10AC0}-\x{10AC7}\x{10AC8}\x{10AC9}-\x{10AE4}\x{10AE7}-\x{10AEA}\x{10AEB}-\x{10AEF}\x{10AF0}-\x{10AF6}\x{10AF7}-\x{10AFF}\x{10B00}-\x{10B35}\x{10B36}-\x{10B38}\x{10B40}-\x{10B55}\x{10B56}-\x{10B57}\x{10B58}-\x{10B5F}\x{10B60}-\x{10B72}\x{10B73}-\x{10B77}\x{10B78}-\x{10B7F}\x{10B80}-\x{10B91}\x{10B92}-\x{10B98}\x{10B99}-\x{10B9C}\x{10B9D}-\x{10BA8}\x{10BA9}-\x{10BAF}\x{10BB0}-\x{10BFF}\x{10C00}-\x{10C48}\x{10C49}-\x{10C7F}\x{10C80}-\x{10CB2}\x{10CB3}-\x{10CBF}\x{10CC0}-\x{10CF2}\x{10CF3}-\x{10CF9}\x{10CFA}-\x{10CFF}\x{10D00}-\x{10D23}\x{10D28}-\x{10D2F}\x{10D30}-\x{10D39}\x{10D3A}-\x{10D3F}\x{10D40}-\x{10E5F}\x{10E60}-\x{10E7E}\x{10E7F}\x{10E80}-\x{10EA9}\x{10EAA}\x{10EAD}\x{10EAE}-\x{10EAF}\x{10EB0}-\x{10EB1}\x{10EB2}-\x{10EFF}\x{10F00}-\x{10F1C}\x{10F1D}-\x{10F26}\x{10F27}\x{10F28}-\x{10F2F}\x{10F30}-\x{10F45}\x{10F51}-\x{10F54}\x{10F55}-\x{10F59}\x{10F5A}-\x{10F6F}\x{10F70}-\x{10FAF}\x{10FB0}-\x{10FC4}\x{10FC5}-\x{10FCB}\x{10FCC}-\x{10FDF}\x{10FE0}-\x{10FF6}\x{10FF7}-\x{10FFF}\x{1D7CE}-\x{1D7FF}\x{1E800}-\x{1E8C4}\x{1E8C5}-\x{1E8C6}\x{1E8C7}-\x{1E8CF}\x{1E8D7}-\x{1E8FF}\x{1E900}-\x{1E943}\x{1E94B}\x{1E94C}-\x{1E94F}\x{1E950}-\x{1E959}\x{1E95A}-\x{1E95D}\x{1E95E}-\x{1E95F}\x{1E960}-\x{1EC6F}\x{1EC70}\x{1EC71}-\x{1ECAB}\x{1ECAC}\x{1ECAD}-\x{1ECAF}\x{1ECB0}\x{1ECB1}-\x{1ECB4}\x{1ECB5}-\x{1ECBF}\x{1ECC0}-\x{1ECFF}\x{1ED00}\x{1ED01}-\x{1ED2D}\x{1ED2E}\x{1ED2F}-\x{1ED3D}\x{1ED3E}-\x{1ED4F}\x{1ED50}-\x{1EDFF}\x{1EE00}-\x{1EE03}\x{1EE04}\x{1EE05}-\x{1EE1F}\x{1EE20}\x{1EE21}-\x{1EE22}\x{1EE23}\x{1EE24}\x{1EE25}-\x{1EE26}\x{1EE27}\x{1EE28}\x{1EE29}-\x{1EE32}\x{1EE33}\x{1EE34}-\x{1EE37}\x{1EE38}\x{1EE39}\x{1EE3A}\x{1EE3B}\x{1EE3C}-\x{1EE41}\x{1EE42}\x{1EE43}-\x{1EE46}\x{1EE47}\x{1EE48}\x{1EE49}\x{1EE4A}\x{1EE4B}\x{1EE4C}\x{1EE4D}-\x{1EE4F}\x{1EE50}\x{1EE51}-\x{1EE52}\x{1EE53}\x{1EE54}\x{1EE55}-\x{1EE56}\x{1EE57}\x{1EE58}\x{1EE59}\x{1EE5A}\x{1EE5B}\x{1EE5C}\x{1EE5D}\x{1EE5E}\x{1EE5F}\x{1EE60}\x{1EE61}-\x{1EE62}\x{1EE63}\x{1EE64}\x{1EE65}-\x{1EE66}\x{1EE67}-\x{1EE6A}\x{1EE6B}\x{1EE6C}-\x{1EE72}\x{1EE73}\x{1EE74}-\x{1EE77}\x{1EE78}\x{1EE79}-\x{1EE7C}\x{1EE7D}\x{1EE7E}\x{1EE7F}\x{1EE80}-\x{1EE89}\x{1EE8A}\x{1EE8B}-\x{1EE9B}\x{1EE9C}-\x{1EEA0}\x{1EEA1}-\x{1EEA3}\x{1EEA4}\x{1EEA5}-\x{1EEA9}\x{1EEAA}\x{1EEAB}-\x{1EEBB}\x{1EEBC}-\x{1EEEF}\x{1EEF2}-\x{1EEFF}\x{1EF00}-\x{1EFFF}\x{1F100}-\x{1F10A}\x{1FBF0}-\x{1FBF9}][\x{0300}-\x{036F}\x{0483}-\x{0487}\x{0488}-\x{0489}\x{0591}-\x{05BD}\x{05BF}\x{05C1}-\x{05C2}\x{05C4}-\x{05C5}\x{05C7}\x{0610}-\x{061A}\x{064B}-\x{065F}\x{0670}\x{06D6}-\x{06DC}\x{06DF}-\x{06E4}\x{06E7}-\x{06E8}\x{06EA}-\x{06ED}\x{0711}\x{0730}-\x{074A}\x{07A6}-\x{07B0}\x{07EB}-\x{07F3}\x{07FD}\x{0816}-\x{0819}\x{081B}-\x{0823}\x{0825}-\x{0827}\x{0829}-\x{082D}\x{0859}-\x{085B}\x{08D3}-\x{08E1}\x{08E3}-\x{0902}\x{093A}\x{093C}\x{0941}-\x{0948}\x{094D}\x{0951}-\x{0957}\x{0962}-\x{0963}\x{0981}\x{09BC}\x{09C1}-\x{09C4}\x{09CD}\x{09E2}-\x{09E3}\x{09FE}\x{0A01}-\x{0A02}\x{0A3C}\x{0A41}-\x{0A42}\x{0A47}-\x{0A48}\x{0A4B}-\x{0A4D}\x{0A51}\x{0A70}-\x{0A71}\x{0A75}\x{0A81}-\x{0A82}\x{0ABC}\x{0AC1}-\x{0AC5}\x{0AC7}-\x{0AC8}\x{0ACD}\x{0AE2}-\x{0AE3}\x{0AFA}-\x{0AFF}\x{0B01}\x{0B3C}\x{0B3F}\x{0B41}-\x{0B44}\x{0B4D}\x{0B55}-\x{0B56}\x{0B62}-\x{0B63}\x{0B82}\x{0BC0}\x{0BCD}\x{0C00}\x{0C04}\x{0C3E}-\x{0C40}\x{0C46}-\x{0C48}\x{0C4A}-\x{0C4D}\x{0C55}-\x{0C56}\x{0C62}-\x{0C63}\x{0C81}\x{0CBC}\x{0CCC}-\x{0CCD}\x{0CE2}-\x{0CE3}\x{0D00}-\x{0D01}\x{0D3B}-\x{0D3C}\x{0D41}-\x{0D44}\x{0D4D}\x{0D62}-\x{0D63}\x{0D81}\x{0DCA}\x{0DD2}-\x{0DD4}\x{0DD6}\x{0E31}\x{0E34}-\x{0E3A}\x{0E47}-\x{0E4E}\x{0EB1}\x{0EB4}-\x{0EBC}\x{0EC8}-\x{0ECD}\x{0F18}-\x{0F19}\x{0F35}\x{0F37}\x{0F39}\x{0F71}-\x{0F7E}\x{0F80}-\x{0F84}\x{0F86}-\x{0F87}\x{0F8D}-\x{0F97}\x{0F99}-\x{0FBC}\x{0FC6}\x{102D}-\x{1030}\x{1032}-\x{1037}\x{1039}-\x{103A}\x{103D}-\x{103E}\x{1058}-\x{1059}\x{105E}-\x{1060}\x{1071}-\x{1074}\x{1082}\x{1085}-\x{1086}\x{108D}\x{109D}\x{135D}-\x{135F}\x{1712}-\x{1714}\x{1732}-\x{1734}\x{1752}-\x{1753}\x{1772}-\x{1773}\x{17B4}-\x{17B5}\x{17B7}-\x{17BD}\x{17C6}\x{17C9}-\x{17D3}\x{17DD}\x{180B}-\x{180D}\x{1885}-\x{1886}\x{18A9}\x{1920}-\x{1922}\x{1927}-\x{1928}\x{1932}\x{1939}-\x{193B}\x{1A17}-\x{1A18}\x{1A1B}\x{1A56}\x{1A58}-\x{1A5E}\x{1A60}\x{1A62}\x{1A65}-\x{1A6C}\x{1A73}-\x{1A7C}\x{1A7F}\x{1AB0}-\x{1ABD}\x{1ABE}\x{1ABF}-\x{1AC0}\x{1B00}-\x{1B03}\x{1B34}\x{1B36}-\x{1B3A}\x{1B3C}\x{1B42}\x{1B6B}-\x{1B73}\x{1B80}-\x{1B81}\x{1BA2}-\x{1BA5}\x{1BA8}-\x{1BA9}\x{1BAB}-\x{1BAD}\x{1BE6}\x{1BE8}-\x{1BE9}\x{1BED}\x{1BEF}-\x{1BF1}\x{1C2C}-\x{1C33}\x{1C36}-\x{1C37}\x{1CD0}-\x{1CD2}\x{1CD4}-\x{1CE0}\x{1CE2}-\x{1CE8}\x{1CED}\x{1CF4}\x{1CF8}-\x{1CF9}\x{1DC0}-\x{1DF9}\x{1DFB}-\x{1DFF}\x{20D0}-\x{20DC}\x{20DD}-\x{20E0}\x{20E1}\x{20E2}-\x{20E4}\x{20E5}-\x{20F0}\x{2CEF}-\x{2CF1}\x{2D7F}\x{2DE0}-\x{2DFF}\x{302A}-\x{302D}\x{3099}-\x{309A}\x{A66F}\x{A670}-\x{A672}\x{A674}-\x{A67D}\x{A69E}-\x{A69F}\x{A6F0}-\x{A6F1}\x{A802}\x{A806}\x{A80B}\x{A825}-\x{A826}\x{A82C}\x{A8C4}-\x{A8C5}\x{A8E0}-\x{A8F1}\x{A8FF}\x{A926}-\x{A92D}\x{A947}-\x{A951}\x{A980}-\x{A982}\x{A9B3}\x{A9B6}-\x{A9B9}\x{A9BC}-\x{A9BD}\x{A9E5}\x{AA29}-\x{AA2E}\x{AA31}-\x{AA32}\x{AA35}-\x{AA36}\x{AA43}\x{AA4C}\x{AA7C}\x{AAB0}\x{AAB2}-\x{AAB4}\x{AAB7}-\x{AAB8}\x{AABE}-\x{AABF}\x{AAC1}\x{AAEC}-\x{AAED}\x{AAF6}\x{ABE5}\x{ABE8}\x{ABED}\x{FB1E}\x{FE00}-\x{FE0F}\x{FE20}-\x{FE2F}\x{101FD}\x{102E0}\x{10376}-\x{1037A}\x{10A01}-\x{10A03}\x{10A05}-\x{10A06}\x{10A0C}-\x{10A0F}\x{10A38}-\x{10A3A}\x{10A3F}\x{10AE5}-\x{10AE6}\x{10D24}-\x{10D27}\x{10EAB}-\x{10EAC}\x{10F46}-\x{10F50}\x{11001}\x{11038}-\x{11046}\x{1107F}-\x{11081}\x{110B3}-\x{110B6}\x{110B9}-\x{110BA}\x{11100}-\x{11102}\x{11127}-\x{1112B}\x{1112D}-\x{11134}\x{11173}\x{11180}-\x{11181}\x{111B6}-\x{111BE}\x{111C9}-\x{111CC}\x{111CF}\x{1122F}-\x{11231}\x{11234}\x{11236}-\x{11237}\x{1123E}\x{112DF}\x{112E3}-\x{112EA}\x{11300}-\x{11301}\x{1133B}-\x{1133C}\x{11340}\x{11366}-\x{1136C}\x{11370}-\x{11374}\x{11438}-\x{1143F}\x{11442}-\x{11444}\x{11446}\x{1145E}\x{114B3}-\x{114B8}\x{114BA}\x{114BF}-\x{114C0}\x{114C2}-\x{114C3}\x{115B2}-\x{115B5}\x{115BC}-\x{115BD}\x{115BF}-\x{115C0}\x{115DC}-\x{115DD}\x{11633}-\x{1163A}\x{1163D}\x{1163F}-\x{11640}\x{116AB}\x{116AD}\x{116B0}-\x{116B5}\x{116B7}\x{1171D}-\x{1171F}\x{11722}-\x{11725}\x{11727}-\x{1172B}\x{1182F}-\x{11837}\x{11839}-\x{1183A}\x{1193B}-\x{1193C}\x{1193E}\x{11943}\x{119D4}-\x{119D7}\x{119DA}-\x{119DB}\x{119E0}\x{11A01}-\x{11A06}\x{11A09}-\x{11A0A}\x{11A33}-\x{11A38}\x{11A3B}-\x{11A3E}\x{11A47}\x{11A51}-\x{11A56}\x{11A59}-\x{11A5B}\x{11A8A}-\x{11A96}\x{11A98}-\x{11A99}\x{11C30}-\x{11C36}\x{11C38}-\x{11C3D}\x{11C92}-\x{11CA7}\x{11CAA}-\x{11CB0}\x{11CB2}-\x{11CB3}\x{11CB5}-\x{11CB6}\x{11D31}-\x{11D36}\x{11D3A}\x{11D3C}-\x{11D3D}\x{11D3F}-\x{11D45}\x{11D47}\x{11D90}-\x{11D91}\x{11D95}\x{11D97}\x{11EF3}-\x{11EF4}\x{16AF0}-\x{16AF4}\x{16B30}-\x{16B36}\x{16F4F}\x{16F8F}-\x{16F92}\x{16FE4}\x{1BC9D}-\x{1BC9E}\x{1D167}-\x{1D169}\x{1D17B}-\x{1D182}\x{1D185}-\x{1D18B}\x{1D1AA}-\x{1D1AD}\x{1D242}-\x{1D244}\x{1DA00}-\x{1DA36}\x{1DA3B}-\x{1DA6C}\x{1DA75}\x{1DA84}\x{1DA9B}-\x{1DA9F}\x{1DAA1}-\x{1DAAF}\x{1E000}-\x{1E006}\x{1E008}-\x{1E018}\x{1E01B}-\x{1E021}\x{1E023}-\x{1E024}\x{1E026}-\x{1E02A}\x{1E130}-\x{1E136}\x{1E2EC}-\x{1E2EF}\x{1E8D0}-\x{1E8D6}\x{1E944}-\x{1E94A}\x{E0100}-\x{E01EF}]*$/u'; + const BIDI_STEP_4_AN = '/[\x{0600}-\x{0605}\x{0660}-\x{0669}\x{066B}-\x{066C}\x{06DD}\x{08E2}\x{10D30}-\x{10D39}\x{10E60}-\x{10E7E}]/u'; + const BIDI_STEP_4_EN = '/[\x{0030}-\x{0039}\x{00B2}-\x{00B3}\x{00B9}\x{06F0}-\x{06F9}\x{2070}\x{2074}-\x{2079}\x{2080}-\x{2089}\x{2488}-\x{249B}\x{FF10}-\x{FF19}\x{102E1}-\x{102FB}\x{1D7CE}-\x{1D7FF}\x{1F100}-\x{1F10A}\x{1FBF0}-\x{1FBF9}]/u'; + const BIDI_STEP_5 = '/[\x{0009}\x{000A}\x{000B}\x{000C}\x{000D}\x{001C}-\x{001E}\x{001F}\x{0020}\x{0085}\x{0590}\x{05BE}\x{05C0}\x{05C3}\x{05C6}\x{05C8}-\x{05CF}\x{05D0}-\x{05EA}\x{05EB}-\x{05EE}\x{05EF}-\x{05F2}\x{05F3}-\x{05F4}\x{05F5}-\x{05FF}\x{0600}-\x{0605}\x{0608}\x{060B}\x{060D}\x{061B}\x{061C}\x{061D}\x{061E}-\x{061F}\x{0620}-\x{063F}\x{0640}\x{0641}-\x{064A}\x{0660}-\x{0669}\x{066B}-\x{066C}\x{066D}\x{066E}-\x{066F}\x{0671}-\x{06D3}\x{06D4}\x{06D5}\x{06DD}\x{06E5}-\x{06E6}\x{06EE}-\x{06EF}\x{06FA}-\x{06FC}\x{06FD}-\x{06FE}\x{06FF}\x{0700}-\x{070D}\x{070E}\x{070F}\x{0710}\x{0712}-\x{072F}\x{074B}-\x{074C}\x{074D}-\x{07A5}\x{07B1}\x{07B2}-\x{07BF}\x{07C0}-\x{07C9}\x{07CA}-\x{07EA}\x{07F4}-\x{07F5}\x{07FA}\x{07FB}-\x{07FC}\x{07FE}-\x{07FF}\x{0800}-\x{0815}\x{081A}\x{0824}\x{0828}\x{082E}-\x{082F}\x{0830}-\x{083E}\x{083F}\x{0840}-\x{0858}\x{085C}-\x{085D}\x{085E}\x{085F}\x{0860}-\x{086A}\x{086B}-\x{086F}\x{0870}-\x{089F}\x{08A0}-\x{08B4}\x{08B5}\x{08B6}-\x{08C7}\x{08C8}-\x{08D2}\x{08E2}\x{1680}\x{2000}-\x{200A}\x{200F}\x{2028}\x{2029}\x{202A}\x{202B}\x{202C}\x{202D}\x{202E}\x{205F}\x{2066}\x{2067}\x{2068}\x{2069}\x{3000}\x{FB1D}\x{FB1F}-\x{FB28}\x{FB2A}-\x{FB36}\x{FB37}\x{FB38}-\x{FB3C}\x{FB3D}\x{FB3E}\x{FB3F}\x{FB40}-\x{FB41}\x{FB42}\x{FB43}-\x{FB44}\x{FB45}\x{FB46}-\x{FB4F}\x{FB50}-\x{FBB1}\x{FBB2}-\x{FBC1}\x{FBC2}-\x{FBD2}\x{FBD3}-\x{FD3D}\x{FD40}-\x{FD4F}\x{FD50}-\x{FD8F}\x{FD90}-\x{FD91}\x{FD92}-\x{FDC7}\x{FDC8}-\x{FDCF}\x{FDF0}-\x{FDFB}\x{FDFC}\x{FDFE}-\x{FDFF}\x{FE70}-\x{FE74}\x{FE75}\x{FE76}-\x{FEFC}\x{FEFD}-\x{FEFE}\x{10800}-\x{10805}\x{10806}-\x{10807}\x{10808}\x{10809}\x{1080A}-\x{10835}\x{10836}\x{10837}-\x{10838}\x{10839}-\x{1083B}\x{1083C}\x{1083D}-\x{1083E}\x{1083F}-\x{10855}\x{10856}\x{10857}\x{10858}-\x{1085F}\x{10860}-\x{10876}\x{10877}-\x{10878}\x{10879}-\x{1087F}\x{10880}-\x{1089E}\x{1089F}-\x{108A6}\x{108A7}-\x{108AF}\x{108B0}-\x{108DF}\x{108E0}-\x{108F2}\x{108F3}\x{108F4}-\x{108F5}\x{108F6}-\x{108FA}\x{108FB}-\x{108FF}\x{10900}-\x{10915}\x{10916}-\x{1091B}\x{1091C}-\x{1091E}\x{10920}-\x{10939}\x{1093A}-\x{1093E}\x{1093F}\x{10940}-\x{1097F}\x{10980}-\x{109B7}\x{109B8}-\x{109BB}\x{109BC}-\x{109BD}\x{109BE}-\x{109BF}\x{109C0}-\x{109CF}\x{109D0}-\x{109D1}\x{109D2}-\x{109FF}\x{10A00}\x{10A04}\x{10A07}-\x{10A0B}\x{10A10}-\x{10A13}\x{10A14}\x{10A15}-\x{10A17}\x{10A18}\x{10A19}-\x{10A35}\x{10A36}-\x{10A37}\x{10A3B}-\x{10A3E}\x{10A40}-\x{10A48}\x{10A49}-\x{10A4F}\x{10A50}-\x{10A58}\x{10A59}-\x{10A5F}\x{10A60}-\x{10A7C}\x{10A7D}-\x{10A7E}\x{10A7F}\x{10A80}-\x{10A9C}\x{10A9D}-\x{10A9F}\x{10AA0}-\x{10ABF}\x{10AC0}-\x{10AC7}\x{10AC8}\x{10AC9}-\x{10AE4}\x{10AE7}-\x{10AEA}\x{10AEB}-\x{10AEF}\x{10AF0}-\x{10AF6}\x{10AF7}-\x{10AFF}\x{10B00}-\x{10B35}\x{10B36}-\x{10B38}\x{10B40}-\x{10B55}\x{10B56}-\x{10B57}\x{10B58}-\x{10B5F}\x{10B60}-\x{10B72}\x{10B73}-\x{10B77}\x{10B78}-\x{10B7F}\x{10B80}-\x{10B91}\x{10B92}-\x{10B98}\x{10B99}-\x{10B9C}\x{10B9D}-\x{10BA8}\x{10BA9}-\x{10BAF}\x{10BB0}-\x{10BFF}\x{10C00}-\x{10C48}\x{10C49}-\x{10C7F}\x{10C80}-\x{10CB2}\x{10CB3}-\x{10CBF}\x{10CC0}-\x{10CF2}\x{10CF3}-\x{10CF9}\x{10CFA}-\x{10CFF}\x{10D00}-\x{10D23}\x{10D28}-\x{10D2F}\x{10D30}-\x{10D39}\x{10D3A}-\x{10D3F}\x{10D40}-\x{10E5F}\x{10E60}-\x{10E7E}\x{10E7F}\x{10E80}-\x{10EA9}\x{10EAA}\x{10EAD}\x{10EAE}-\x{10EAF}\x{10EB0}-\x{10EB1}\x{10EB2}-\x{10EFF}\x{10F00}-\x{10F1C}\x{10F1D}-\x{10F26}\x{10F27}\x{10F28}-\x{10F2F}\x{10F30}-\x{10F45}\x{10F51}-\x{10F54}\x{10F55}-\x{10F59}\x{10F5A}-\x{10F6F}\x{10F70}-\x{10FAF}\x{10FB0}-\x{10FC4}\x{10FC5}-\x{10FCB}\x{10FCC}-\x{10FDF}\x{10FE0}-\x{10FF6}\x{10FF7}-\x{10FFF}\x{1E800}-\x{1E8C4}\x{1E8C5}-\x{1E8C6}\x{1E8C7}-\x{1E8CF}\x{1E8D7}-\x{1E8FF}\x{1E900}-\x{1E943}\x{1E94B}\x{1E94C}-\x{1E94F}\x{1E950}-\x{1E959}\x{1E95A}-\x{1E95D}\x{1E95E}-\x{1E95F}\x{1E960}-\x{1EC6F}\x{1EC70}\x{1EC71}-\x{1ECAB}\x{1ECAC}\x{1ECAD}-\x{1ECAF}\x{1ECB0}\x{1ECB1}-\x{1ECB4}\x{1ECB5}-\x{1ECBF}\x{1ECC0}-\x{1ECFF}\x{1ED00}\x{1ED01}-\x{1ED2D}\x{1ED2E}\x{1ED2F}-\x{1ED3D}\x{1ED3E}-\x{1ED4F}\x{1ED50}-\x{1EDFF}\x{1EE00}-\x{1EE03}\x{1EE04}\x{1EE05}-\x{1EE1F}\x{1EE20}\x{1EE21}-\x{1EE22}\x{1EE23}\x{1EE24}\x{1EE25}-\x{1EE26}\x{1EE27}\x{1EE28}\x{1EE29}-\x{1EE32}\x{1EE33}\x{1EE34}-\x{1EE37}\x{1EE38}\x{1EE39}\x{1EE3A}\x{1EE3B}\x{1EE3C}-\x{1EE41}\x{1EE42}\x{1EE43}-\x{1EE46}\x{1EE47}\x{1EE48}\x{1EE49}\x{1EE4A}\x{1EE4B}\x{1EE4C}\x{1EE4D}-\x{1EE4F}\x{1EE50}\x{1EE51}-\x{1EE52}\x{1EE53}\x{1EE54}\x{1EE55}-\x{1EE56}\x{1EE57}\x{1EE58}\x{1EE59}\x{1EE5A}\x{1EE5B}\x{1EE5C}\x{1EE5D}\x{1EE5E}\x{1EE5F}\x{1EE60}\x{1EE61}-\x{1EE62}\x{1EE63}\x{1EE64}\x{1EE65}-\x{1EE66}\x{1EE67}-\x{1EE6A}\x{1EE6B}\x{1EE6C}-\x{1EE72}\x{1EE73}\x{1EE74}-\x{1EE77}\x{1EE78}\x{1EE79}-\x{1EE7C}\x{1EE7D}\x{1EE7E}\x{1EE7F}\x{1EE80}-\x{1EE89}\x{1EE8A}\x{1EE8B}-\x{1EE9B}\x{1EE9C}-\x{1EEA0}\x{1EEA1}-\x{1EEA3}\x{1EEA4}\x{1EEA5}-\x{1EEA9}\x{1EEAA}\x{1EEAB}-\x{1EEBB}\x{1EEBC}-\x{1EEEF}\x{1EEF2}-\x{1EEFF}\x{1EF00}-\x{1EFFF}]/u'; + const BIDI_STEP_6 = '/[^\x{0000}-\x{0008}\x{0009}\x{000A}\x{000B}\x{000C}\x{000D}\x{000E}-\x{001B}\x{001C}-\x{001E}\x{001F}\x{0020}\x{0021}-\x{0022}\x{0023}\x{0024}\x{0025}\x{0026}-\x{0027}\x{0028}\x{0029}\x{002A}\x{002B}\x{002C}\x{002D}\x{002E}-\x{002F}\x{003A}\x{003B}\x{003C}-\x{003E}\x{003F}-\x{0040}\x{005B}\x{005C}\x{005D}\x{005E}\x{005F}\x{0060}\x{007B}\x{007C}\x{007D}\x{007E}\x{007F}-\x{0084}\x{0085}\x{0086}-\x{009F}\x{00A0}\x{00A1}\x{00A2}-\x{00A5}\x{00A6}\x{00A7}\x{00A8}\x{00A9}\x{00AB}\x{00AC}\x{00AD}\x{00AE}\x{00AF}\x{00B0}\x{00B1}\x{00B4}\x{00B6}-\x{00B7}\x{00B8}\x{00BB}\x{00BC}-\x{00BE}\x{00BF}\x{00D7}\x{00F7}\x{02B9}-\x{02BA}\x{02C2}-\x{02C5}\x{02C6}-\x{02CF}\x{02D2}-\x{02DF}\x{02E5}-\x{02EB}\x{02EC}\x{02ED}\x{02EF}-\x{02FF}\x{0300}-\x{036F}\x{0374}\x{0375}\x{037E}\x{0384}-\x{0385}\x{0387}\x{03F6}\x{0483}-\x{0487}\x{0488}-\x{0489}\x{058A}\x{058D}-\x{058E}\x{058F}\x{0590}\x{0591}-\x{05BD}\x{05BE}\x{05BF}\x{05C0}\x{05C1}-\x{05C2}\x{05C3}\x{05C4}-\x{05C5}\x{05C6}\x{05C7}\x{05C8}-\x{05CF}\x{05D0}-\x{05EA}\x{05EB}-\x{05EE}\x{05EF}-\x{05F2}\x{05F3}-\x{05F4}\x{05F5}-\x{05FF}\x{0600}-\x{0605}\x{0606}-\x{0607}\x{0608}\x{0609}-\x{060A}\x{060B}\x{060C}\x{060D}\x{060E}-\x{060F}\x{0610}-\x{061A}\x{061B}\x{061C}\x{061D}\x{061E}-\x{061F}\x{0620}-\x{063F}\x{0640}\x{0641}-\x{064A}\x{064B}-\x{065F}\x{0660}-\x{0669}\x{066A}\x{066B}-\x{066C}\x{066D}\x{066E}-\x{066F}\x{0670}\x{0671}-\x{06D3}\x{06D4}\x{06D5}\x{06D6}-\x{06DC}\x{06DD}\x{06DE}\x{06DF}-\x{06E4}\x{06E5}-\x{06E6}\x{06E7}-\x{06E8}\x{06E9}\x{06EA}-\x{06ED}\x{06EE}-\x{06EF}\x{06FA}-\x{06FC}\x{06FD}-\x{06FE}\x{06FF}\x{0700}-\x{070D}\x{070E}\x{070F}\x{0710}\x{0711}\x{0712}-\x{072F}\x{0730}-\x{074A}\x{074B}-\x{074C}\x{074D}-\x{07A5}\x{07A6}-\x{07B0}\x{07B1}\x{07B2}-\x{07BF}\x{07C0}-\x{07C9}\x{07CA}-\x{07EA}\x{07EB}-\x{07F3}\x{07F4}-\x{07F5}\x{07F6}\x{07F7}-\x{07F9}\x{07FA}\x{07FB}-\x{07FC}\x{07FD}\x{07FE}-\x{07FF}\x{0800}-\x{0815}\x{0816}-\x{0819}\x{081A}\x{081B}-\x{0823}\x{0824}\x{0825}-\x{0827}\x{0828}\x{0829}-\x{082D}\x{082E}-\x{082F}\x{0830}-\x{083E}\x{083F}\x{0840}-\x{0858}\x{0859}-\x{085B}\x{085C}-\x{085D}\x{085E}\x{085F}\x{0860}-\x{086A}\x{086B}-\x{086F}\x{0870}-\x{089F}\x{08A0}-\x{08B4}\x{08B5}\x{08B6}-\x{08C7}\x{08C8}-\x{08D2}\x{08D3}-\x{08E1}\x{08E2}\x{08E3}-\x{0902}\x{093A}\x{093C}\x{0941}-\x{0948}\x{094D}\x{0951}-\x{0957}\x{0962}-\x{0963}\x{0981}\x{09BC}\x{09C1}-\x{09C4}\x{09CD}\x{09E2}-\x{09E3}\x{09F2}-\x{09F3}\x{09FB}\x{09FE}\x{0A01}-\x{0A02}\x{0A3C}\x{0A41}-\x{0A42}\x{0A47}-\x{0A48}\x{0A4B}-\x{0A4D}\x{0A51}\x{0A70}-\x{0A71}\x{0A75}\x{0A81}-\x{0A82}\x{0ABC}\x{0AC1}-\x{0AC5}\x{0AC7}-\x{0AC8}\x{0ACD}\x{0AE2}-\x{0AE3}\x{0AF1}\x{0AFA}-\x{0AFF}\x{0B01}\x{0B3C}\x{0B3F}\x{0B41}-\x{0B44}\x{0B4D}\x{0B55}-\x{0B56}\x{0B62}-\x{0B63}\x{0B82}\x{0BC0}\x{0BCD}\x{0BF3}-\x{0BF8}\x{0BF9}\x{0BFA}\x{0C00}\x{0C04}\x{0C3E}-\x{0C40}\x{0C46}-\x{0C48}\x{0C4A}-\x{0C4D}\x{0C55}-\x{0C56}\x{0C62}-\x{0C63}\x{0C78}-\x{0C7E}\x{0C81}\x{0CBC}\x{0CCC}-\x{0CCD}\x{0CE2}-\x{0CE3}\x{0D00}-\x{0D01}\x{0D3B}-\x{0D3C}\x{0D41}-\x{0D44}\x{0D4D}\x{0D62}-\x{0D63}\x{0D81}\x{0DCA}\x{0DD2}-\x{0DD4}\x{0DD6}\x{0E31}\x{0E34}-\x{0E3A}\x{0E3F}\x{0E47}-\x{0E4E}\x{0EB1}\x{0EB4}-\x{0EBC}\x{0EC8}-\x{0ECD}\x{0F18}-\x{0F19}\x{0F35}\x{0F37}\x{0F39}\x{0F3A}\x{0F3B}\x{0F3C}\x{0F3D}\x{0F71}-\x{0F7E}\x{0F80}-\x{0F84}\x{0F86}-\x{0F87}\x{0F8D}-\x{0F97}\x{0F99}-\x{0FBC}\x{0FC6}\x{102D}-\x{1030}\x{1032}-\x{1037}\x{1039}-\x{103A}\x{103D}-\x{103E}\x{1058}-\x{1059}\x{105E}-\x{1060}\x{1071}-\x{1074}\x{1082}\x{1085}-\x{1086}\x{108D}\x{109D}\x{135D}-\x{135F}\x{1390}-\x{1399}\x{1400}\x{1680}\x{169B}\x{169C}\x{1712}-\x{1714}\x{1732}-\x{1734}\x{1752}-\x{1753}\x{1772}-\x{1773}\x{17B4}-\x{17B5}\x{17B7}-\x{17BD}\x{17C6}\x{17C9}-\x{17D3}\x{17DB}\x{17DD}\x{17F0}-\x{17F9}\x{1800}-\x{1805}\x{1806}\x{1807}-\x{180A}\x{180B}-\x{180D}\x{180E}\x{1885}-\x{1886}\x{18A9}\x{1920}-\x{1922}\x{1927}-\x{1928}\x{1932}\x{1939}-\x{193B}\x{1940}\x{1944}-\x{1945}\x{19DE}-\x{19FF}\x{1A17}-\x{1A18}\x{1A1B}\x{1A56}\x{1A58}-\x{1A5E}\x{1A60}\x{1A62}\x{1A65}-\x{1A6C}\x{1A73}-\x{1A7C}\x{1A7F}\x{1AB0}-\x{1ABD}\x{1ABE}\x{1ABF}-\x{1AC0}\x{1B00}-\x{1B03}\x{1B34}\x{1B36}-\x{1B3A}\x{1B3C}\x{1B42}\x{1B6B}-\x{1B73}\x{1B80}-\x{1B81}\x{1BA2}-\x{1BA5}\x{1BA8}-\x{1BA9}\x{1BAB}-\x{1BAD}\x{1BE6}\x{1BE8}-\x{1BE9}\x{1BED}\x{1BEF}-\x{1BF1}\x{1C2C}-\x{1C33}\x{1C36}-\x{1C37}\x{1CD0}-\x{1CD2}\x{1CD4}-\x{1CE0}\x{1CE2}-\x{1CE8}\x{1CED}\x{1CF4}\x{1CF8}-\x{1CF9}\x{1DC0}-\x{1DF9}\x{1DFB}-\x{1DFF}\x{1FBD}\x{1FBF}-\x{1FC1}\x{1FCD}-\x{1FCF}\x{1FDD}-\x{1FDF}\x{1FED}-\x{1FEF}\x{1FFD}-\x{1FFE}\x{2000}-\x{200A}\x{200B}-\x{200D}\x{200F}\x{2010}-\x{2015}\x{2016}-\x{2017}\x{2018}\x{2019}\x{201A}\x{201B}-\x{201C}\x{201D}\x{201E}\x{201F}\x{2020}-\x{2027}\x{2028}\x{2029}\x{202A}\x{202B}\x{202C}\x{202D}\x{202E}\x{202F}\x{2030}-\x{2034}\x{2035}-\x{2038}\x{2039}\x{203A}\x{203B}-\x{203E}\x{203F}-\x{2040}\x{2041}-\x{2043}\x{2044}\x{2045}\x{2046}\x{2047}-\x{2051}\x{2052}\x{2053}\x{2054}\x{2055}-\x{205E}\x{205F}\x{2060}-\x{2064}\x{2065}\x{2066}\x{2067}\x{2068}\x{2069}\x{206A}-\x{206F}\x{207A}-\x{207B}\x{207C}\x{207D}\x{207E}\x{208A}-\x{208B}\x{208C}\x{208D}\x{208E}\x{20A0}-\x{20BF}\x{20C0}-\x{20CF}\x{20D0}-\x{20DC}\x{20DD}-\x{20E0}\x{20E1}\x{20E2}-\x{20E4}\x{20E5}-\x{20F0}\x{2100}-\x{2101}\x{2103}-\x{2106}\x{2108}-\x{2109}\x{2114}\x{2116}-\x{2117}\x{2118}\x{211E}-\x{2123}\x{2125}\x{2127}\x{2129}\x{212E}\x{213A}-\x{213B}\x{2140}-\x{2144}\x{214A}\x{214B}\x{214C}-\x{214D}\x{2150}-\x{215F}\x{2189}\x{218A}-\x{218B}\x{2190}-\x{2194}\x{2195}-\x{2199}\x{219A}-\x{219B}\x{219C}-\x{219F}\x{21A0}\x{21A1}-\x{21A2}\x{21A3}\x{21A4}-\x{21A5}\x{21A6}\x{21A7}-\x{21AD}\x{21AE}\x{21AF}-\x{21CD}\x{21CE}-\x{21CF}\x{21D0}-\x{21D1}\x{21D2}\x{21D3}\x{21D4}\x{21D5}-\x{21F3}\x{21F4}-\x{2211}\x{2212}\x{2213}\x{2214}-\x{22FF}\x{2300}-\x{2307}\x{2308}\x{2309}\x{230A}\x{230B}\x{230C}-\x{231F}\x{2320}-\x{2321}\x{2322}-\x{2328}\x{2329}\x{232A}\x{232B}-\x{2335}\x{237B}\x{237C}\x{237D}-\x{2394}\x{2396}-\x{239A}\x{239B}-\x{23B3}\x{23B4}-\x{23DB}\x{23DC}-\x{23E1}\x{23E2}-\x{2426}\x{2440}-\x{244A}\x{2460}-\x{2487}\x{24EA}-\x{24FF}\x{2500}-\x{25B6}\x{25B7}\x{25B8}-\x{25C0}\x{25C1}\x{25C2}-\x{25F7}\x{25F8}-\x{25FF}\x{2600}-\x{266E}\x{266F}\x{2670}-\x{26AB}\x{26AD}-\x{2767}\x{2768}\x{2769}\x{276A}\x{276B}\x{276C}\x{276D}\x{276E}\x{276F}\x{2770}\x{2771}\x{2772}\x{2773}\x{2774}\x{2775}\x{2776}-\x{2793}\x{2794}-\x{27BF}\x{27C0}-\x{27C4}\x{27C5}\x{27C6}\x{27C7}-\x{27E5}\x{27E6}\x{27E7}\x{27E8}\x{27E9}\x{27EA}\x{27EB}\x{27EC}\x{27ED}\x{27EE}\x{27EF}\x{27F0}-\x{27FF}\x{2900}-\x{2982}\x{2983}\x{2984}\x{2985}\x{2986}\x{2987}\x{2988}\x{2989}\x{298A}\x{298B}\x{298C}\x{298D}\x{298E}\x{298F}\x{2990}\x{2991}\x{2992}\x{2993}\x{2994}\x{2995}\x{2996}\x{2997}\x{2998}\x{2999}-\x{29D7}\x{29D8}\x{29D9}\x{29DA}\x{29DB}\x{29DC}-\x{29FB}\x{29FC}\x{29FD}\x{29FE}-\x{2AFF}\x{2B00}-\x{2B2F}\x{2B30}-\x{2B44}\x{2B45}-\x{2B46}\x{2B47}-\x{2B4C}\x{2B4D}-\x{2B73}\x{2B76}-\x{2B95}\x{2B97}-\x{2BFF}\x{2CE5}-\x{2CEA}\x{2CEF}-\x{2CF1}\x{2CF9}-\x{2CFC}\x{2CFD}\x{2CFE}-\x{2CFF}\x{2D7F}\x{2DE0}-\x{2DFF}\x{2E00}-\x{2E01}\x{2E02}\x{2E03}\x{2E04}\x{2E05}\x{2E06}-\x{2E08}\x{2E09}\x{2E0A}\x{2E0B}\x{2E0C}\x{2E0D}\x{2E0E}-\x{2E16}\x{2E17}\x{2E18}-\x{2E19}\x{2E1A}\x{2E1B}\x{2E1C}\x{2E1D}\x{2E1E}-\x{2E1F}\x{2E20}\x{2E21}\x{2E22}\x{2E23}\x{2E24}\x{2E25}\x{2E26}\x{2E27}\x{2E28}\x{2E29}\x{2E2A}-\x{2E2E}\x{2E2F}\x{2E30}-\x{2E39}\x{2E3A}-\x{2E3B}\x{2E3C}-\x{2E3F}\x{2E40}\x{2E41}\x{2E42}\x{2E43}-\x{2E4F}\x{2E50}-\x{2E51}\x{2E52}\x{2E80}-\x{2E99}\x{2E9B}-\x{2EF3}\x{2F00}-\x{2FD5}\x{2FF0}-\x{2FFB}\x{3000}\x{3001}-\x{3003}\x{3004}\x{3008}\x{3009}\x{300A}\x{300B}\x{300C}\x{300D}\x{300E}\x{300F}\x{3010}\x{3011}\x{3012}-\x{3013}\x{3014}\x{3015}\x{3016}\x{3017}\x{3018}\x{3019}\x{301A}\x{301B}\x{301C}\x{301D}\x{301E}-\x{301F}\x{3020}\x{302A}-\x{302D}\x{3030}\x{3036}-\x{3037}\x{303D}\x{303E}-\x{303F}\x{3099}-\x{309A}\x{309B}-\x{309C}\x{30A0}\x{30FB}\x{31C0}-\x{31E3}\x{321D}-\x{321E}\x{3250}\x{3251}-\x{325F}\x{327C}-\x{327E}\x{32B1}-\x{32BF}\x{32CC}-\x{32CF}\x{3377}-\x{337A}\x{33DE}-\x{33DF}\x{33FF}\x{4DC0}-\x{4DFF}\x{A490}-\x{A4C6}\x{A60D}-\x{A60F}\x{A66F}\x{A670}-\x{A672}\x{A673}\x{A674}-\x{A67D}\x{A67E}\x{A67F}\x{A69E}-\x{A69F}\x{A6F0}-\x{A6F1}\x{A700}-\x{A716}\x{A717}-\x{A71F}\x{A720}-\x{A721}\x{A788}\x{A802}\x{A806}\x{A80B}\x{A825}-\x{A826}\x{A828}-\x{A82B}\x{A82C}\x{A838}\x{A839}\x{A874}-\x{A877}\x{A8C4}-\x{A8C5}\x{A8E0}-\x{A8F1}\x{A8FF}\x{A926}-\x{A92D}\x{A947}-\x{A951}\x{A980}-\x{A982}\x{A9B3}\x{A9B6}-\x{A9B9}\x{A9BC}-\x{A9BD}\x{A9E5}\x{AA29}-\x{AA2E}\x{AA31}-\x{AA32}\x{AA35}-\x{AA36}\x{AA43}\x{AA4C}\x{AA7C}\x{AAB0}\x{AAB2}-\x{AAB4}\x{AAB7}-\x{AAB8}\x{AABE}-\x{AABF}\x{AAC1}\x{AAEC}-\x{AAED}\x{AAF6}\x{AB6A}-\x{AB6B}\x{ABE5}\x{ABE8}\x{ABED}\x{FB1D}\x{FB1E}\x{FB1F}-\x{FB28}\x{FB29}\x{FB2A}-\x{FB36}\x{FB37}\x{FB38}-\x{FB3C}\x{FB3D}\x{FB3E}\x{FB3F}\x{FB40}-\x{FB41}\x{FB42}\x{FB43}-\x{FB44}\x{FB45}\x{FB46}-\x{FB4F}\x{FB50}-\x{FBB1}\x{FBB2}-\x{FBC1}\x{FBC2}-\x{FBD2}\x{FBD3}-\x{FD3D}\x{FD3E}\x{FD3F}\x{FD40}-\x{FD4F}\x{FD50}-\x{FD8F}\x{FD90}-\x{FD91}\x{FD92}-\x{FDC7}\x{FDC8}-\x{FDCF}\x{FDD0}-\x{FDEF}\x{FDF0}-\x{FDFB}\x{FDFC}\x{FDFD}\x{FDFE}-\x{FDFF}\x{FE00}-\x{FE0F}\x{FE10}-\x{FE16}\x{FE17}\x{FE18}\x{FE19}\x{FE20}-\x{FE2F}\x{FE30}\x{FE31}-\x{FE32}\x{FE33}-\x{FE34}\x{FE35}\x{FE36}\x{FE37}\x{FE38}\x{FE39}\x{FE3A}\x{FE3B}\x{FE3C}\x{FE3D}\x{FE3E}\x{FE3F}\x{FE40}\x{FE41}\x{FE42}\x{FE43}\x{FE44}\x{FE45}-\x{FE46}\x{FE47}\x{FE48}\x{FE49}-\x{FE4C}\x{FE4D}-\x{FE4F}\x{FE50}\x{FE51}\x{FE52}\x{FE54}\x{FE55}\x{FE56}-\x{FE57}\x{FE58}\x{FE59}\x{FE5A}\x{FE5B}\x{FE5C}\x{FE5D}\x{FE5E}\x{FE5F}\x{FE60}-\x{FE61}\x{FE62}\x{FE63}\x{FE64}-\x{FE66}\x{FE68}\x{FE69}\x{FE6A}\x{FE6B}\x{FE70}-\x{FE74}\x{FE75}\x{FE76}-\x{FEFC}\x{FEFD}-\x{FEFE}\x{FEFF}\x{FF01}-\x{FF02}\x{FF03}\x{FF04}\x{FF05}\x{FF06}-\x{FF07}\x{FF08}\x{FF09}\x{FF0A}\x{FF0B}\x{FF0C}\x{FF0D}\x{FF0E}-\x{FF0F}\x{FF1A}\x{FF1B}\x{FF1C}-\x{FF1E}\x{FF1F}-\x{FF20}\x{FF3B}\x{FF3C}\x{FF3D}\x{FF3E}\x{FF3F}\x{FF40}\x{FF5B}\x{FF5C}\x{FF5D}\x{FF5E}\x{FF5F}\x{FF60}\x{FF61}\x{FF62}\x{FF63}\x{FF64}-\x{FF65}\x{FFE0}-\x{FFE1}\x{FFE2}\x{FFE3}\x{FFE4}\x{FFE5}-\x{FFE6}\x{FFE8}\x{FFE9}-\x{FFEC}\x{FFED}-\x{FFEE}\x{FFF0}-\x{FFF8}\x{FFF9}-\x{FFFB}\x{FFFC}-\x{FFFD}\x{FFFE}-\x{FFFF}\x{10101}\x{10140}-\x{10174}\x{10175}-\x{10178}\x{10179}-\x{10189}\x{1018A}-\x{1018B}\x{1018C}\x{10190}-\x{1019C}\x{101A0}\x{101FD}\x{102E0}\x{10376}-\x{1037A}\x{10800}-\x{10805}\x{10806}-\x{10807}\x{10808}\x{10809}\x{1080A}-\x{10835}\x{10836}\x{10837}-\x{10838}\x{10839}-\x{1083B}\x{1083C}\x{1083D}-\x{1083E}\x{1083F}-\x{10855}\x{10856}\x{10857}\x{10858}-\x{1085F}\x{10860}-\x{10876}\x{10877}-\x{10878}\x{10879}-\x{1087F}\x{10880}-\x{1089E}\x{1089F}-\x{108A6}\x{108A7}-\x{108AF}\x{108B0}-\x{108DF}\x{108E0}-\x{108F2}\x{108F3}\x{108F4}-\x{108F5}\x{108F6}-\x{108FA}\x{108FB}-\x{108FF}\x{10900}-\x{10915}\x{10916}-\x{1091B}\x{1091C}-\x{1091E}\x{1091F}\x{10920}-\x{10939}\x{1093A}-\x{1093E}\x{1093F}\x{10940}-\x{1097F}\x{10980}-\x{109B7}\x{109B8}-\x{109BB}\x{109BC}-\x{109BD}\x{109BE}-\x{109BF}\x{109C0}-\x{109CF}\x{109D0}-\x{109D1}\x{109D2}-\x{109FF}\x{10A00}\x{10A01}-\x{10A03}\x{10A04}\x{10A05}-\x{10A06}\x{10A07}-\x{10A0B}\x{10A0C}-\x{10A0F}\x{10A10}-\x{10A13}\x{10A14}\x{10A15}-\x{10A17}\x{10A18}\x{10A19}-\x{10A35}\x{10A36}-\x{10A37}\x{10A38}-\x{10A3A}\x{10A3B}-\x{10A3E}\x{10A3F}\x{10A40}-\x{10A48}\x{10A49}-\x{10A4F}\x{10A50}-\x{10A58}\x{10A59}-\x{10A5F}\x{10A60}-\x{10A7C}\x{10A7D}-\x{10A7E}\x{10A7F}\x{10A80}-\x{10A9C}\x{10A9D}-\x{10A9F}\x{10AA0}-\x{10ABF}\x{10AC0}-\x{10AC7}\x{10AC8}\x{10AC9}-\x{10AE4}\x{10AE5}-\x{10AE6}\x{10AE7}-\x{10AEA}\x{10AEB}-\x{10AEF}\x{10AF0}-\x{10AF6}\x{10AF7}-\x{10AFF}\x{10B00}-\x{10B35}\x{10B36}-\x{10B38}\x{10B39}-\x{10B3F}\x{10B40}-\x{10B55}\x{10B56}-\x{10B57}\x{10B58}-\x{10B5F}\x{10B60}-\x{10B72}\x{10B73}-\x{10B77}\x{10B78}-\x{10B7F}\x{10B80}-\x{10B91}\x{10B92}-\x{10B98}\x{10B99}-\x{10B9C}\x{10B9D}-\x{10BA8}\x{10BA9}-\x{10BAF}\x{10BB0}-\x{10BFF}\x{10C00}-\x{10C48}\x{10C49}-\x{10C7F}\x{10C80}-\x{10CB2}\x{10CB3}-\x{10CBF}\x{10CC0}-\x{10CF2}\x{10CF3}-\x{10CF9}\x{10CFA}-\x{10CFF}\x{10D00}-\x{10D23}\x{10D24}-\x{10D27}\x{10D28}-\x{10D2F}\x{10D30}-\x{10D39}\x{10D3A}-\x{10D3F}\x{10D40}-\x{10E5F}\x{10E60}-\x{10E7E}\x{10E7F}\x{10E80}-\x{10EA9}\x{10EAA}\x{10EAB}-\x{10EAC}\x{10EAD}\x{10EAE}-\x{10EAF}\x{10EB0}-\x{10EB1}\x{10EB2}-\x{10EFF}\x{10F00}-\x{10F1C}\x{10F1D}-\x{10F26}\x{10F27}\x{10F28}-\x{10F2F}\x{10F30}-\x{10F45}\x{10F46}-\x{10F50}\x{10F51}-\x{10F54}\x{10F55}-\x{10F59}\x{10F5A}-\x{10F6F}\x{10F70}-\x{10FAF}\x{10FB0}-\x{10FC4}\x{10FC5}-\x{10FCB}\x{10FCC}-\x{10FDF}\x{10FE0}-\x{10FF6}\x{10FF7}-\x{10FFF}\x{11001}\x{11038}-\x{11046}\x{11052}-\x{11065}\x{1107F}-\x{11081}\x{110B3}-\x{110B6}\x{110B9}-\x{110BA}\x{11100}-\x{11102}\x{11127}-\x{1112B}\x{1112D}-\x{11134}\x{11173}\x{11180}-\x{11181}\x{111B6}-\x{111BE}\x{111C9}-\x{111CC}\x{111CF}\x{1122F}-\x{11231}\x{11234}\x{11236}-\x{11237}\x{1123E}\x{112DF}\x{112E3}-\x{112EA}\x{11300}-\x{11301}\x{1133B}-\x{1133C}\x{11340}\x{11366}-\x{1136C}\x{11370}-\x{11374}\x{11438}-\x{1143F}\x{11442}-\x{11444}\x{11446}\x{1145E}\x{114B3}-\x{114B8}\x{114BA}\x{114BF}-\x{114C0}\x{114C2}-\x{114C3}\x{115B2}-\x{115B5}\x{115BC}-\x{115BD}\x{115BF}-\x{115C0}\x{115DC}-\x{115DD}\x{11633}-\x{1163A}\x{1163D}\x{1163F}-\x{11640}\x{11660}-\x{1166C}\x{116AB}\x{116AD}\x{116B0}-\x{116B5}\x{116B7}\x{1171D}-\x{1171F}\x{11722}-\x{11725}\x{11727}-\x{1172B}\x{1182F}-\x{11837}\x{11839}-\x{1183A}\x{1193B}-\x{1193C}\x{1193E}\x{11943}\x{119D4}-\x{119D7}\x{119DA}-\x{119DB}\x{119E0}\x{11A01}-\x{11A06}\x{11A09}-\x{11A0A}\x{11A33}-\x{11A38}\x{11A3B}-\x{11A3E}\x{11A47}\x{11A51}-\x{11A56}\x{11A59}-\x{11A5B}\x{11A8A}-\x{11A96}\x{11A98}-\x{11A99}\x{11C30}-\x{11C36}\x{11C38}-\x{11C3D}\x{11C92}-\x{11CA7}\x{11CAA}-\x{11CB0}\x{11CB2}-\x{11CB3}\x{11CB5}-\x{11CB6}\x{11D31}-\x{11D36}\x{11D3A}\x{11D3C}-\x{11D3D}\x{11D3F}-\x{11D45}\x{11D47}\x{11D90}-\x{11D91}\x{11D95}\x{11D97}\x{11EF3}-\x{11EF4}\x{11FD5}-\x{11FDC}\x{11FDD}-\x{11FE0}\x{11FE1}-\x{11FF1}\x{16AF0}-\x{16AF4}\x{16B30}-\x{16B36}\x{16F4F}\x{16F8F}-\x{16F92}\x{16FE2}\x{16FE4}\x{1BC9D}-\x{1BC9E}\x{1BCA0}-\x{1BCA3}\x{1D167}-\x{1D169}\x{1D173}-\x{1D17A}\x{1D17B}-\x{1D182}\x{1D185}-\x{1D18B}\x{1D1AA}-\x{1D1AD}\x{1D200}-\x{1D241}\x{1D242}-\x{1D244}\x{1D245}\x{1D300}-\x{1D356}\x{1D6DB}\x{1D715}\x{1D74F}\x{1D789}\x{1D7C3}\x{1DA00}-\x{1DA36}\x{1DA3B}-\x{1DA6C}\x{1DA75}\x{1DA84}\x{1DA9B}-\x{1DA9F}\x{1DAA1}-\x{1DAAF}\x{1E000}-\x{1E006}\x{1E008}-\x{1E018}\x{1E01B}-\x{1E021}\x{1E023}-\x{1E024}\x{1E026}-\x{1E02A}\x{1E130}-\x{1E136}\x{1E2EC}-\x{1E2EF}\x{1E2FF}\x{1E800}-\x{1E8C4}\x{1E8C5}-\x{1E8C6}\x{1E8C7}-\x{1E8CF}\x{1E8D0}-\x{1E8D6}\x{1E8D7}-\x{1E8FF}\x{1E900}-\x{1E943}\x{1E944}-\x{1E94A}\x{1E94B}\x{1E94C}-\x{1E94F}\x{1E950}-\x{1E959}\x{1E95A}-\x{1E95D}\x{1E95E}-\x{1E95F}\x{1E960}-\x{1EC6F}\x{1EC70}\x{1EC71}-\x{1ECAB}\x{1ECAC}\x{1ECAD}-\x{1ECAF}\x{1ECB0}\x{1ECB1}-\x{1ECB4}\x{1ECB5}-\x{1ECBF}\x{1ECC0}-\x{1ECFF}\x{1ED00}\x{1ED01}-\x{1ED2D}\x{1ED2E}\x{1ED2F}-\x{1ED3D}\x{1ED3E}-\x{1ED4F}\x{1ED50}-\x{1EDFF}\x{1EE00}-\x{1EE03}\x{1EE04}\x{1EE05}-\x{1EE1F}\x{1EE20}\x{1EE21}-\x{1EE22}\x{1EE23}\x{1EE24}\x{1EE25}-\x{1EE26}\x{1EE27}\x{1EE28}\x{1EE29}-\x{1EE32}\x{1EE33}\x{1EE34}-\x{1EE37}\x{1EE38}\x{1EE39}\x{1EE3A}\x{1EE3B}\x{1EE3C}-\x{1EE41}\x{1EE42}\x{1EE43}-\x{1EE46}\x{1EE47}\x{1EE48}\x{1EE49}\x{1EE4A}\x{1EE4B}\x{1EE4C}\x{1EE4D}-\x{1EE4F}\x{1EE50}\x{1EE51}-\x{1EE52}\x{1EE53}\x{1EE54}\x{1EE55}-\x{1EE56}\x{1EE57}\x{1EE58}\x{1EE59}\x{1EE5A}\x{1EE5B}\x{1EE5C}\x{1EE5D}\x{1EE5E}\x{1EE5F}\x{1EE60}\x{1EE61}-\x{1EE62}\x{1EE63}\x{1EE64}\x{1EE65}-\x{1EE66}\x{1EE67}-\x{1EE6A}\x{1EE6B}\x{1EE6C}-\x{1EE72}\x{1EE73}\x{1EE74}-\x{1EE77}\x{1EE78}\x{1EE79}-\x{1EE7C}\x{1EE7D}\x{1EE7E}\x{1EE7F}\x{1EE80}-\x{1EE89}\x{1EE8A}\x{1EE8B}-\x{1EE9B}\x{1EE9C}-\x{1EEA0}\x{1EEA1}-\x{1EEA3}\x{1EEA4}\x{1EEA5}-\x{1EEA9}\x{1EEAA}\x{1EEAB}-\x{1EEBB}\x{1EEBC}-\x{1EEEF}\x{1EEF0}-\x{1EEF1}\x{1EEF2}-\x{1EEFF}\x{1EF00}-\x{1EFFF}\x{1F000}-\x{1F02B}\x{1F030}-\x{1F093}\x{1F0A0}-\x{1F0AE}\x{1F0B1}-\x{1F0BF}\x{1F0C1}-\x{1F0CF}\x{1F0D1}-\x{1F0F5}\x{1F10B}-\x{1F10C}\x{1F10D}-\x{1F10F}\x{1F12F}\x{1F16A}-\x{1F16F}\x{1F1AD}\x{1F260}-\x{1F265}\x{1F300}-\x{1F3FA}\x{1F3FB}-\x{1F3FF}\x{1F400}-\x{1F6D7}\x{1F6E0}-\x{1F6EC}\x{1F6F0}-\x{1F6FC}\x{1F700}-\x{1F773}\x{1F780}-\x{1F7D8}\x{1F7E0}-\x{1F7EB}\x{1F800}-\x{1F80B}\x{1F810}-\x{1F847}\x{1F850}-\x{1F859}\x{1F860}-\x{1F887}\x{1F890}-\x{1F8AD}\x{1F8B0}-\x{1F8B1}\x{1F900}-\x{1F978}\x{1F97A}-\x{1F9CB}\x{1F9CD}-\x{1FA53}\x{1FA60}-\x{1FA6D}\x{1FA70}-\x{1FA74}\x{1FA78}-\x{1FA7A}\x{1FA80}-\x{1FA86}\x{1FA90}-\x{1FAA8}\x{1FAB0}-\x{1FAB6}\x{1FAC0}-\x{1FAC2}\x{1FAD0}-\x{1FAD6}\x{1FB00}-\x{1FB92}\x{1FB94}-\x{1FBCA}\x{1FFFE}-\x{1FFFF}\x{2FFFE}-\x{2FFFF}\x{3FFFE}-\x{3FFFF}\x{4FFFE}-\x{4FFFF}\x{5FFFE}-\x{5FFFF}\x{6FFFE}-\x{6FFFF}\x{7FFFE}-\x{7FFFF}\x{8FFFE}-\x{8FFFF}\x{9FFFE}-\x{9FFFF}\x{AFFFE}-\x{AFFFF}\x{BFFFE}-\x{BFFFF}\x{CFFFE}-\x{CFFFF}\x{DFFFE}-\x{E0000}\x{E0001}\x{E0002}-\x{E001F}\x{E0020}-\x{E007F}\x{E0080}-\x{E00FF}\x{E0100}-\x{E01EF}\x{E01F0}-\x{E0FFF}\x{EFFFE}-\x{EFFFF}\x{FFFFE}-\x{FFFFF}\x{10FFFE}-\x{10FFFF}][\x{0300}-\x{036F}\x{0483}-\x{0487}\x{0488}-\x{0489}\x{0591}-\x{05BD}\x{05BF}\x{05C1}-\x{05C2}\x{05C4}-\x{05C5}\x{05C7}\x{0610}-\x{061A}\x{064B}-\x{065F}\x{0670}\x{06D6}-\x{06DC}\x{06DF}-\x{06E4}\x{06E7}-\x{06E8}\x{06EA}-\x{06ED}\x{0711}\x{0730}-\x{074A}\x{07A6}-\x{07B0}\x{07EB}-\x{07F3}\x{07FD}\x{0816}-\x{0819}\x{081B}-\x{0823}\x{0825}-\x{0827}\x{0829}-\x{082D}\x{0859}-\x{085B}\x{08D3}-\x{08E1}\x{08E3}-\x{0902}\x{093A}\x{093C}\x{0941}-\x{0948}\x{094D}\x{0951}-\x{0957}\x{0962}-\x{0963}\x{0981}\x{09BC}\x{09C1}-\x{09C4}\x{09CD}\x{09E2}-\x{09E3}\x{09FE}\x{0A01}-\x{0A02}\x{0A3C}\x{0A41}-\x{0A42}\x{0A47}-\x{0A48}\x{0A4B}-\x{0A4D}\x{0A51}\x{0A70}-\x{0A71}\x{0A75}\x{0A81}-\x{0A82}\x{0ABC}\x{0AC1}-\x{0AC5}\x{0AC7}-\x{0AC8}\x{0ACD}\x{0AE2}-\x{0AE3}\x{0AFA}-\x{0AFF}\x{0B01}\x{0B3C}\x{0B3F}\x{0B41}-\x{0B44}\x{0B4D}\x{0B55}-\x{0B56}\x{0B62}-\x{0B63}\x{0B82}\x{0BC0}\x{0BCD}\x{0C00}\x{0C04}\x{0C3E}-\x{0C40}\x{0C46}-\x{0C48}\x{0C4A}-\x{0C4D}\x{0C55}-\x{0C56}\x{0C62}-\x{0C63}\x{0C81}\x{0CBC}\x{0CCC}-\x{0CCD}\x{0CE2}-\x{0CE3}\x{0D00}-\x{0D01}\x{0D3B}-\x{0D3C}\x{0D41}-\x{0D44}\x{0D4D}\x{0D62}-\x{0D63}\x{0D81}\x{0DCA}\x{0DD2}-\x{0DD4}\x{0DD6}\x{0E31}\x{0E34}-\x{0E3A}\x{0E47}-\x{0E4E}\x{0EB1}\x{0EB4}-\x{0EBC}\x{0EC8}-\x{0ECD}\x{0F18}-\x{0F19}\x{0F35}\x{0F37}\x{0F39}\x{0F71}-\x{0F7E}\x{0F80}-\x{0F84}\x{0F86}-\x{0F87}\x{0F8D}-\x{0F97}\x{0F99}-\x{0FBC}\x{0FC6}\x{102D}-\x{1030}\x{1032}-\x{1037}\x{1039}-\x{103A}\x{103D}-\x{103E}\x{1058}-\x{1059}\x{105E}-\x{1060}\x{1071}-\x{1074}\x{1082}\x{1085}-\x{1086}\x{108D}\x{109D}\x{135D}-\x{135F}\x{1712}-\x{1714}\x{1732}-\x{1734}\x{1752}-\x{1753}\x{1772}-\x{1773}\x{17B4}-\x{17B5}\x{17B7}-\x{17BD}\x{17C6}\x{17C9}-\x{17D3}\x{17DD}\x{180B}-\x{180D}\x{1885}-\x{1886}\x{18A9}\x{1920}-\x{1922}\x{1927}-\x{1928}\x{1932}\x{1939}-\x{193B}\x{1A17}-\x{1A18}\x{1A1B}\x{1A56}\x{1A58}-\x{1A5E}\x{1A60}\x{1A62}\x{1A65}-\x{1A6C}\x{1A73}-\x{1A7C}\x{1A7F}\x{1AB0}-\x{1ABD}\x{1ABE}\x{1ABF}-\x{1AC0}\x{1B00}-\x{1B03}\x{1B34}\x{1B36}-\x{1B3A}\x{1B3C}\x{1B42}\x{1B6B}-\x{1B73}\x{1B80}-\x{1B81}\x{1BA2}-\x{1BA5}\x{1BA8}-\x{1BA9}\x{1BAB}-\x{1BAD}\x{1BE6}\x{1BE8}-\x{1BE9}\x{1BED}\x{1BEF}-\x{1BF1}\x{1C2C}-\x{1C33}\x{1C36}-\x{1C37}\x{1CD0}-\x{1CD2}\x{1CD4}-\x{1CE0}\x{1CE2}-\x{1CE8}\x{1CED}\x{1CF4}\x{1CF8}-\x{1CF9}\x{1DC0}-\x{1DF9}\x{1DFB}-\x{1DFF}\x{20D0}-\x{20DC}\x{20DD}-\x{20E0}\x{20E1}\x{20E2}-\x{20E4}\x{20E5}-\x{20F0}\x{2CEF}-\x{2CF1}\x{2D7F}\x{2DE0}-\x{2DFF}\x{302A}-\x{302D}\x{3099}-\x{309A}\x{A66F}\x{A670}-\x{A672}\x{A674}-\x{A67D}\x{A69E}-\x{A69F}\x{A6F0}-\x{A6F1}\x{A802}\x{A806}\x{A80B}\x{A825}-\x{A826}\x{A82C}\x{A8C4}-\x{A8C5}\x{A8E0}-\x{A8F1}\x{A8FF}\x{A926}-\x{A92D}\x{A947}-\x{A951}\x{A980}-\x{A982}\x{A9B3}\x{A9B6}-\x{A9B9}\x{A9BC}-\x{A9BD}\x{A9E5}\x{AA29}-\x{AA2E}\x{AA31}-\x{AA32}\x{AA35}-\x{AA36}\x{AA43}\x{AA4C}\x{AA7C}\x{AAB0}\x{AAB2}-\x{AAB4}\x{AAB7}-\x{AAB8}\x{AABE}-\x{AABF}\x{AAC1}\x{AAEC}-\x{AAED}\x{AAF6}\x{ABE5}\x{ABE8}\x{ABED}\x{FB1E}\x{FE00}-\x{FE0F}\x{FE20}-\x{FE2F}\x{101FD}\x{102E0}\x{10376}-\x{1037A}\x{10A01}-\x{10A03}\x{10A05}-\x{10A06}\x{10A0C}-\x{10A0F}\x{10A38}-\x{10A3A}\x{10A3F}\x{10AE5}-\x{10AE6}\x{10D24}-\x{10D27}\x{10EAB}-\x{10EAC}\x{10F46}-\x{10F50}\x{11001}\x{11038}-\x{11046}\x{1107F}-\x{11081}\x{110B3}-\x{110B6}\x{110B9}-\x{110BA}\x{11100}-\x{11102}\x{11127}-\x{1112B}\x{1112D}-\x{11134}\x{11173}\x{11180}-\x{11181}\x{111B6}-\x{111BE}\x{111C9}-\x{111CC}\x{111CF}\x{1122F}-\x{11231}\x{11234}\x{11236}-\x{11237}\x{1123E}\x{112DF}\x{112E3}-\x{112EA}\x{11300}-\x{11301}\x{1133B}-\x{1133C}\x{11340}\x{11366}-\x{1136C}\x{11370}-\x{11374}\x{11438}-\x{1143F}\x{11442}-\x{11444}\x{11446}\x{1145E}\x{114B3}-\x{114B8}\x{114BA}\x{114BF}-\x{114C0}\x{114C2}-\x{114C3}\x{115B2}-\x{115B5}\x{115BC}-\x{115BD}\x{115BF}-\x{115C0}\x{115DC}-\x{115DD}\x{11633}-\x{1163A}\x{1163D}\x{1163F}-\x{11640}\x{116AB}\x{116AD}\x{116B0}-\x{116B5}\x{116B7}\x{1171D}-\x{1171F}\x{11722}-\x{11725}\x{11727}-\x{1172B}\x{1182F}-\x{11837}\x{11839}-\x{1183A}\x{1193B}-\x{1193C}\x{1193E}\x{11943}\x{119D4}-\x{119D7}\x{119DA}-\x{119DB}\x{119E0}\x{11A01}-\x{11A06}\x{11A09}-\x{11A0A}\x{11A33}-\x{11A38}\x{11A3B}-\x{11A3E}\x{11A47}\x{11A51}-\x{11A56}\x{11A59}-\x{11A5B}\x{11A8A}-\x{11A96}\x{11A98}-\x{11A99}\x{11C30}-\x{11C36}\x{11C38}-\x{11C3D}\x{11C92}-\x{11CA7}\x{11CAA}-\x{11CB0}\x{11CB2}-\x{11CB3}\x{11CB5}-\x{11CB6}\x{11D31}-\x{11D36}\x{11D3A}\x{11D3C}-\x{11D3D}\x{11D3F}-\x{11D45}\x{11D47}\x{11D90}-\x{11D91}\x{11D95}\x{11D97}\x{11EF3}-\x{11EF4}\x{16AF0}-\x{16AF4}\x{16B30}-\x{16B36}\x{16F4F}\x{16F8F}-\x{16F92}\x{16FE4}\x{1BC9D}-\x{1BC9E}\x{1D167}-\x{1D169}\x{1D17B}-\x{1D182}\x{1D185}-\x{1D18B}\x{1D1AA}-\x{1D1AD}\x{1D242}-\x{1D244}\x{1DA00}-\x{1DA36}\x{1DA3B}-\x{1DA6C}\x{1DA75}\x{1DA84}\x{1DA9B}-\x{1DA9F}\x{1DAA1}-\x{1DAAF}\x{1E000}-\x{1E006}\x{1E008}-\x{1E018}\x{1E01B}-\x{1E021}\x{1E023}-\x{1E024}\x{1E026}-\x{1E02A}\x{1E130}-\x{1E136}\x{1E2EC}-\x{1E2EF}\x{1E8D0}-\x{1E8D6}\x{1E944}-\x{1E94A}\x{E0100}-\x{E01EF}]*$/u'; - public const ZWNJ = '/([\x{A872}\x{10ACD}\x{10AD7}\x{10D00}\x{10FCB}\x{0620}\x{0626}\x{0628}\x{062A}-\x{062E}\x{0633}-\x{063F}\x{0641}-\x{0647}\x{0649}-\x{064A}\x{066E}-\x{066F}\x{0678}-\x{0687}\x{069A}-\x{06BF}\x{06C1}-\x{06C2}\x{06CC}\x{06CE}\x{06D0}-\x{06D1}\x{06FA}-\x{06FC}\x{06FF}\x{0712}-\x{0714}\x{071A}-\x{071D}\x{071F}-\x{0727}\x{0729}\x{072B}\x{072D}-\x{072E}\x{074E}-\x{0758}\x{075C}-\x{076A}\x{076D}-\x{0770}\x{0772}\x{0775}-\x{0777}\x{077A}-\x{077F}\x{07CA}-\x{07EA}\x{0841}-\x{0845}\x{0848}\x{084A}-\x{0853}\x{0855}\x{0860}\x{0862}-\x{0865}\x{0868}\x{08A0}-\x{08A9}\x{08AF}-\x{08B0}\x{08B3}-\x{08B4}\x{08B6}-\x{08B8}\x{08BA}-\x{08C7}\x{1807}\x{1820}-\x{1842}\x{1843}\x{1844}-\x{1878}\x{1887}-\x{18A8}\x{18AA}\x{A840}-\x{A871}\x{10AC0}-\x{10AC4}\x{10AD3}-\x{10AD6}\x{10AD8}-\x{10ADC}\x{10ADE}-\x{10AE0}\x{10AEB}-\x{10AEE}\x{10B80}\x{10B82}\x{10B86}-\x{10B88}\x{10B8A}-\x{10B8B}\x{10B8D}\x{10B90}\x{10BAD}-\x{10BAE}\x{10D01}-\x{10D21}\x{10D23}\x{10F30}-\x{10F32}\x{10F34}-\x{10F44}\x{10F51}-\x{10F53}\x{10FB0}\x{10FB2}-\x{10FB3}\x{10FB8}\x{10FBB}-\x{10FBC}\x{10FBE}-\x{10FBF}\x{10FC1}\x{10FC4}\x{10FCA}\x{1E900}-\x{1E943}][\x{00AD}\x{0300}-\x{036F}\x{0483}-\x{0487}\x{0488}-\x{0489}\x{0591}-\x{05BD}\x{05BF}\x{05C1}-\x{05C2}\x{05C4}-\x{05C5}\x{05C7}\x{0610}-\x{061A}\x{061C}\x{064B}-\x{065F}\x{0670}\x{06D6}-\x{06DC}\x{06DF}-\x{06E4}\x{06E7}-\x{06E8}\x{06EA}-\x{06ED}\x{070F}\x{0711}\x{0730}-\x{074A}\x{07A6}-\x{07B0}\x{07EB}-\x{07F3}\x{07FD}\x{0816}-\x{0819}\x{081B}-\x{0823}\x{0825}-\x{0827}\x{0829}-\x{082D}\x{0859}-\x{085B}\x{08D3}-\x{08E1}\x{08E3}-\x{0902}\x{093A}\x{093C}\x{0941}-\x{0948}\x{094D}\x{0951}-\x{0957}\x{0962}-\x{0963}\x{0981}\x{09BC}\x{09C1}-\x{09C4}\x{09CD}\x{09E2}-\x{09E3}\x{09FE}\x{0A01}-\x{0A02}\x{0A3C}\x{0A41}-\x{0A42}\x{0A47}-\x{0A48}\x{0A4B}-\x{0A4D}\x{0A51}\x{0A70}-\x{0A71}\x{0A75}\x{0A81}-\x{0A82}\x{0ABC}\x{0AC1}-\x{0AC5}\x{0AC7}-\x{0AC8}\x{0ACD}\x{0AE2}-\x{0AE3}\x{0AFA}-\x{0AFF}\x{0B01}\x{0B3C}\x{0B3F}\x{0B41}-\x{0B44}\x{0B4D}\x{0B55}-\x{0B56}\x{0B62}-\x{0B63}\x{0B82}\x{0BC0}\x{0BCD}\x{0C00}\x{0C04}\x{0C3E}-\x{0C40}\x{0C46}-\x{0C48}\x{0C4A}-\x{0C4D}\x{0C55}-\x{0C56}\x{0C62}-\x{0C63}\x{0C81}\x{0CBC}\x{0CBF}\x{0CC6}\x{0CCC}-\x{0CCD}\x{0CE2}-\x{0CE3}\x{0D00}-\x{0D01}\x{0D3B}-\x{0D3C}\x{0D41}-\x{0D44}\x{0D4D}\x{0D62}-\x{0D63}\x{0D81}\x{0DCA}\x{0DD2}-\x{0DD4}\x{0DD6}\x{0E31}\x{0E34}-\x{0E3A}\x{0E47}-\x{0E4E}\x{0EB1}\x{0EB4}-\x{0EBC}\x{0EC8}-\x{0ECD}\x{0F18}-\x{0F19}\x{0F35}\x{0F37}\x{0F39}\x{0F71}-\x{0F7E}\x{0F80}-\x{0F84}\x{0F86}-\x{0F87}\x{0F8D}-\x{0F97}\x{0F99}-\x{0FBC}\x{0FC6}\x{102D}-\x{1030}\x{1032}-\x{1037}\x{1039}-\x{103A}\x{103D}-\x{103E}\x{1058}-\x{1059}\x{105E}-\x{1060}\x{1071}-\x{1074}\x{1082}\x{1085}-\x{1086}\x{108D}\x{109D}\x{135D}-\x{135F}\x{1712}-\x{1714}\x{1732}-\x{1734}\x{1752}-\x{1753}\x{1772}-\x{1773}\x{17B4}-\x{17B5}\x{17B7}-\x{17BD}\x{17C6}\x{17C9}-\x{17D3}\x{17DD}\x{180B}-\x{180D}\x{1885}-\x{1886}\x{18A9}\x{1920}-\x{1922}\x{1927}-\x{1928}\x{1932}\x{1939}-\x{193B}\x{1A17}-\x{1A18}\x{1A1B}\x{1A56}\x{1A58}-\x{1A5E}\x{1A60}\x{1A62}\x{1A65}-\x{1A6C}\x{1A73}-\x{1A7C}\x{1A7F}\x{1AB0}-\x{1ABD}\x{1ABE}\x{1ABF}-\x{1AC0}\x{1B00}-\x{1B03}\x{1B34}\x{1B36}-\x{1B3A}\x{1B3C}\x{1B42}\x{1B6B}-\x{1B73}\x{1B80}-\x{1B81}\x{1BA2}-\x{1BA5}\x{1BA8}-\x{1BA9}\x{1BAB}-\x{1BAD}\x{1BE6}\x{1BE8}-\x{1BE9}\x{1BED}\x{1BEF}-\x{1BF1}\x{1C2C}-\x{1C33}\x{1C36}-\x{1C37}\x{1CD0}-\x{1CD2}\x{1CD4}-\x{1CE0}\x{1CE2}-\x{1CE8}\x{1CED}\x{1CF4}\x{1CF8}-\x{1CF9}\x{1DC0}-\x{1DF9}\x{1DFB}-\x{1DFF}\x{200B}\x{200E}-\x{200F}\x{202A}-\x{202E}\x{2060}-\x{2064}\x{206A}-\x{206F}\x{20D0}-\x{20DC}\x{20DD}-\x{20E0}\x{20E1}\x{20E2}-\x{20E4}\x{20E5}-\x{20F0}\x{2CEF}-\x{2CF1}\x{2D7F}\x{2DE0}-\x{2DFF}\x{302A}-\x{302D}\x{3099}-\x{309A}\x{A66F}\x{A670}-\x{A672}\x{A674}-\x{A67D}\x{A69E}-\x{A69F}\x{A6F0}-\x{A6F1}\x{A802}\x{A806}\x{A80B}\x{A825}-\x{A826}\x{A82C}\x{A8C4}-\x{A8C5}\x{A8E0}-\x{A8F1}\x{A8FF}\x{A926}-\x{A92D}\x{A947}-\x{A951}\x{A980}-\x{A982}\x{A9B3}\x{A9B6}-\x{A9B9}\x{A9BC}-\x{A9BD}\x{A9E5}\x{AA29}-\x{AA2E}\x{AA31}-\x{AA32}\x{AA35}-\x{AA36}\x{AA43}\x{AA4C}\x{AA7C}\x{AAB0}\x{AAB2}-\x{AAB4}\x{AAB7}-\x{AAB8}\x{AABE}-\x{AABF}\x{AAC1}\x{AAEC}-\x{AAED}\x{AAF6}\x{ABE5}\x{ABE8}\x{ABED}\x{FB1E}\x{FE00}-\x{FE0F}\x{FE20}-\x{FE2F}\x{FEFF}\x{FFF9}-\x{FFFB}\x{101FD}\x{102E0}\x{10376}-\x{1037A}\x{10A01}-\x{10A03}\x{10A05}-\x{10A06}\x{10A0C}-\x{10A0F}\x{10A38}-\x{10A3A}\x{10A3F}\x{10AE5}-\x{10AE6}\x{10D24}-\x{10D27}\x{10EAB}-\x{10EAC}\x{10F46}-\x{10F50}\x{11001}\x{11038}-\x{11046}\x{1107F}-\x{11081}\x{110B3}-\x{110B6}\x{110B9}-\x{110BA}\x{11100}-\x{11102}\x{11127}-\x{1112B}\x{1112D}-\x{11134}\x{11173}\x{11180}-\x{11181}\x{111B6}-\x{111BE}\x{111C9}-\x{111CC}\x{111CF}\x{1122F}-\x{11231}\x{11234}\x{11236}-\x{11237}\x{1123E}\x{112DF}\x{112E3}-\x{112EA}\x{11300}-\x{11301}\x{1133B}-\x{1133C}\x{11340}\x{11366}-\x{1136C}\x{11370}-\x{11374}\x{11438}-\x{1143F}\x{11442}-\x{11444}\x{11446}\x{1145E}\x{114B3}-\x{114B8}\x{114BA}\x{114BF}-\x{114C0}\x{114C2}-\x{114C3}\x{115B2}-\x{115B5}\x{115BC}-\x{115BD}\x{115BF}-\x{115C0}\x{115DC}-\x{115DD}\x{11633}-\x{1163A}\x{1163D}\x{1163F}-\x{11640}\x{116AB}\x{116AD}\x{116B0}-\x{116B5}\x{116B7}\x{1171D}-\x{1171F}\x{11722}-\x{11725}\x{11727}-\x{1172B}\x{1182F}-\x{11837}\x{11839}-\x{1183A}\x{1193B}-\x{1193C}\x{1193E}\x{11943}\x{119D4}-\x{119D7}\x{119DA}-\x{119DB}\x{119E0}\x{11A01}-\x{11A0A}\x{11A33}-\x{11A38}\x{11A3B}-\x{11A3E}\x{11A47}\x{11A51}-\x{11A56}\x{11A59}-\x{11A5B}\x{11A8A}-\x{11A96}\x{11A98}-\x{11A99}\x{11C30}-\x{11C36}\x{11C38}-\x{11C3D}\x{11C3F}\x{11C92}-\x{11CA7}\x{11CAA}-\x{11CB0}\x{11CB2}-\x{11CB3}\x{11CB5}-\x{11CB6}\x{11D31}-\x{11D36}\x{11D3A}\x{11D3C}-\x{11D3D}\x{11D3F}-\x{11D45}\x{11D47}\x{11D90}-\x{11D91}\x{11D95}\x{11D97}\x{11EF3}-\x{11EF4}\x{13430}-\x{13438}\x{16AF0}-\x{16AF4}\x{16B30}-\x{16B36}\x{16F4F}\x{16F8F}-\x{16F92}\x{16FE4}\x{1BC9D}-\x{1BC9E}\x{1BCA0}-\x{1BCA3}\x{1D167}-\x{1D169}\x{1D173}-\x{1D17A}\x{1D17B}-\x{1D182}\x{1D185}-\x{1D18B}\x{1D1AA}-\x{1D1AD}\x{1D242}-\x{1D244}\x{1DA00}-\x{1DA36}\x{1DA3B}-\x{1DA6C}\x{1DA75}\x{1DA84}\x{1DA9B}-\x{1DA9F}\x{1DAA1}-\x{1DAAF}\x{1E000}-\x{1E006}\x{1E008}-\x{1E018}\x{1E01B}-\x{1E021}\x{1E023}-\x{1E024}\x{1E026}-\x{1E02A}\x{1E130}-\x{1E136}\x{1E2EC}-\x{1E2EF}\x{1E8D0}-\x{1E8D6}\x{1E944}-\x{1E94A}\x{1E94B}\x{E0001}\x{E0020}-\x{E007F}\x{E0100}-\x{E01EF}]*\x{200C}[\x{00AD}\x{0300}-\x{036F}\x{0483}-\x{0487}\x{0488}-\x{0489}\x{0591}-\x{05BD}\x{05BF}\x{05C1}-\x{05C2}\x{05C4}-\x{05C5}\x{05C7}\x{0610}-\x{061A}\x{061C}\x{064B}-\x{065F}\x{0670}\x{06D6}-\x{06DC}\x{06DF}-\x{06E4}\x{06E7}-\x{06E8}\x{06EA}-\x{06ED}\x{070F}\x{0711}\x{0730}-\x{074A}\x{07A6}-\x{07B0}\x{07EB}-\x{07F3}\x{07FD}\x{0816}-\x{0819}\x{081B}-\x{0823}\x{0825}-\x{0827}\x{0829}-\x{082D}\x{0859}-\x{085B}\x{08D3}-\x{08E1}\x{08E3}-\x{0902}\x{093A}\x{093C}\x{0941}-\x{0948}\x{094D}\x{0951}-\x{0957}\x{0962}-\x{0963}\x{0981}\x{09BC}\x{09C1}-\x{09C4}\x{09CD}\x{09E2}-\x{09E3}\x{09FE}\x{0A01}-\x{0A02}\x{0A3C}\x{0A41}-\x{0A42}\x{0A47}-\x{0A48}\x{0A4B}-\x{0A4D}\x{0A51}\x{0A70}-\x{0A71}\x{0A75}\x{0A81}-\x{0A82}\x{0ABC}\x{0AC1}-\x{0AC5}\x{0AC7}-\x{0AC8}\x{0ACD}\x{0AE2}-\x{0AE3}\x{0AFA}-\x{0AFF}\x{0B01}\x{0B3C}\x{0B3F}\x{0B41}-\x{0B44}\x{0B4D}\x{0B55}-\x{0B56}\x{0B62}-\x{0B63}\x{0B82}\x{0BC0}\x{0BCD}\x{0C00}\x{0C04}\x{0C3E}-\x{0C40}\x{0C46}-\x{0C48}\x{0C4A}-\x{0C4D}\x{0C55}-\x{0C56}\x{0C62}-\x{0C63}\x{0C81}\x{0CBC}\x{0CBF}\x{0CC6}\x{0CCC}-\x{0CCD}\x{0CE2}-\x{0CE3}\x{0D00}-\x{0D01}\x{0D3B}-\x{0D3C}\x{0D41}-\x{0D44}\x{0D4D}\x{0D62}-\x{0D63}\x{0D81}\x{0DCA}\x{0DD2}-\x{0DD4}\x{0DD6}\x{0E31}\x{0E34}-\x{0E3A}\x{0E47}-\x{0E4E}\x{0EB1}\x{0EB4}-\x{0EBC}\x{0EC8}-\x{0ECD}\x{0F18}-\x{0F19}\x{0F35}\x{0F37}\x{0F39}\x{0F71}-\x{0F7E}\x{0F80}-\x{0F84}\x{0F86}-\x{0F87}\x{0F8D}-\x{0F97}\x{0F99}-\x{0FBC}\x{0FC6}\x{102D}-\x{1030}\x{1032}-\x{1037}\x{1039}-\x{103A}\x{103D}-\x{103E}\x{1058}-\x{1059}\x{105E}-\x{1060}\x{1071}-\x{1074}\x{1082}\x{1085}-\x{1086}\x{108D}\x{109D}\x{135D}-\x{135F}\x{1712}-\x{1714}\x{1732}-\x{1734}\x{1752}-\x{1753}\x{1772}-\x{1773}\x{17B4}-\x{17B5}\x{17B7}-\x{17BD}\x{17C6}\x{17C9}-\x{17D3}\x{17DD}\x{180B}-\x{180D}\x{1885}-\x{1886}\x{18A9}\x{1920}-\x{1922}\x{1927}-\x{1928}\x{1932}\x{1939}-\x{193B}\x{1A17}-\x{1A18}\x{1A1B}\x{1A56}\x{1A58}-\x{1A5E}\x{1A60}\x{1A62}\x{1A65}-\x{1A6C}\x{1A73}-\x{1A7C}\x{1A7F}\x{1AB0}-\x{1ABD}\x{1ABE}\x{1ABF}-\x{1AC0}\x{1B00}-\x{1B03}\x{1B34}\x{1B36}-\x{1B3A}\x{1B3C}\x{1B42}\x{1B6B}-\x{1B73}\x{1B80}-\x{1B81}\x{1BA2}-\x{1BA5}\x{1BA8}-\x{1BA9}\x{1BAB}-\x{1BAD}\x{1BE6}\x{1BE8}-\x{1BE9}\x{1BED}\x{1BEF}-\x{1BF1}\x{1C2C}-\x{1C33}\x{1C36}-\x{1C37}\x{1CD0}-\x{1CD2}\x{1CD4}-\x{1CE0}\x{1CE2}-\x{1CE8}\x{1CED}\x{1CF4}\x{1CF8}-\x{1CF9}\x{1DC0}-\x{1DF9}\x{1DFB}-\x{1DFF}\x{200B}\x{200E}-\x{200F}\x{202A}-\x{202E}\x{2060}-\x{2064}\x{206A}-\x{206F}\x{20D0}-\x{20DC}\x{20DD}-\x{20E0}\x{20E1}\x{20E2}-\x{20E4}\x{20E5}-\x{20F0}\x{2CEF}-\x{2CF1}\x{2D7F}\x{2DE0}-\x{2DFF}\x{302A}-\x{302D}\x{3099}-\x{309A}\x{A66F}\x{A670}-\x{A672}\x{A674}-\x{A67D}\x{A69E}-\x{A69F}\x{A6F0}-\x{A6F1}\x{A802}\x{A806}\x{A80B}\x{A825}-\x{A826}\x{A82C}\x{A8C4}-\x{A8C5}\x{A8E0}-\x{A8F1}\x{A8FF}\x{A926}-\x{A92D}\x{A947}-\x{A951}\x{A980}-\x{A982}\x{A9B3}\x{A9B6}-\x{A9B9}\x{A9BC}-\x{A9BD}\x{A9E5}\x{AA29}-\x{AA2E}\x{AA31}-\x{AA32}\x{AA35}-\x{AA36}\x{AA43}\x{AA4C}\x{AA7C}\x{AAB0}\x{AAB2}-\x{AAB4}\x{AAB7}-\x{AAB8}\x{AABE}-\x{AABF}\x{AAC1}\x{AAEC}-\x{AAED}\x{AAF6}\x{ABE5}\x{ABE8}\x{ABED}\x{FB1E}\x{FE00}-\x{FE0F}\x{FE20}-\x{FE2F}\x{FEFF}\x{FFF9}-\x{FFFB}\x{101FD}\x{102E0}\x{10376}-\x{1037A}\x{10A01}-\x{10A03}\x{10A05}-\x{10A06}\x{10A0C}-\x{10A0F}\x{10A38}-\x{10A3A}\x{10A3F}\x{10AE5}-\x{10AE6}\x{10D24}-\x{10D27}\x{10EAB}-\x{10EAC}\x{10F46}-\x{10F50}\x{11001}\x{11038}-\x{11046}\x{1107F}-\x{11081}\x{110B3}-\x{110B6}\x{110B9}-\x{110BA}\x{11100}-\x{11102}\x{11127}-\x{1112B}\x{1112D}-\x{11134}\x{11173}\x{11180}-\x{11181}\x{111B6}-\x{111BE}\x{111C9}-\x{111CC}\x{111CF}\x{1122F}-\x{11231}\x{11234}\x{11236}-\x{11237}\x{1123E}\x{112DF}\x{112E3}-\x{112EA}\x{11300}-\x{11301}\x{1133B}-\x{1133C}\x{11340}\x{11366}-\x{1136C}\x{11370}-\x{11374}\x{11438}-\x{1143F}\x{11442}-\x{11444}\x{11446}\x{1145E}\x{114B3}-\x{114B8}\x{114BA}\x{114BF}-\x{114C0}\x{114C2}-\x{114C3}\x{115B2}-\x{115B5}\x{115BC}-\x{115BD}\x{115BF}-\x{115C0}\x{115DC}-\x{115DD}\x{11633}-\x{1163A}\x{1163D}\x{1163F}-\x{11640}\x{116AB}\x{116AD}\x{116B0}-\x{116B5}\x{116B7}\x{1171D}-\x{1171F}\x{11722}-\x{11725}\x{11727}-\x{1172B}\x{1182F}-\x{11837}\x{11839}-\x{1183A}\x{1193B}-\x{1193C}\x{1193E}\x{11943}\x{119D4}-\x{119D7}\x{119DA}-\x{119DB}\x{119E0}\x{11A01}-\x{11A0A}\x{11A33}-\x{11A38}\x{11A3B}-\x{11A3E}\x{11A47}\x{11A51}-\x{11A56}\x{11A59}-\x{11A5B}\x{11A8A}-\x{11A96}\x{11A98}-\x{11A99}\x{11C30}-\x{11C36}\x{11C38}-\x{11C3D}\x{11C3F}\x{11C92}-\x{11CA7}\x{11CAA}-\x{11CB0}\x{11CB2}-\x{11CB3}\x{11CB5}-\x{11CB6}\x{11D31}-\x{11D36}\x{11D3A}\x{11D3C}-\x{11D3D}\x{11D3F}-\x{11D45}\x{11D47}\x{11D90}-\x{11D91}\x{11D95}\x{11D97}\x{11EF3}-\x{11EF4}\x{13430}-\x{13438}\x{16AF0}-\x{16AF4}\x{16B30}-\x{16B36}\x{16F4F}\x{16F8F}-\x{16F92}\x{16FE4}\x{1BC9D}-\x{1BC9E}\x{1BCA0}-\x{1BCA3}\x{1D167}-\x{1D169}\x{1D173}-\x{1D17A}\x{1D17B}-\x{1D182}\x{1D185}-\x{1D18B}\x{1D1AA}-\x{1D1AD}\x{1D242}-\x{1D244}\x{1DA00}-\x{1DA36}\x{1DA3B}-\x{1DA6C}\x{1DA75}\x{1DA84}\x{1DA9B}-\x{1DA9F}\x{1DAA1}-\x{1DAAF}\x{1E000}-\x{1E006}\x{1E008}-\x{1E018}\x{1E01B}-\x{1E021}\x{1E023}-\x{1E024}\x{1E026}-\x{1E02A}\x{1E130}-\x{1E136}\x{1E2EC}-\x{1E2EF}\x{1E8D0}-\x{1E8D6}\x{1E944}-\x{1E94A}\x{1E94B}\x{E0001}\x{E0020}-\x{E007F}\x{E0100}-\x{E01EF}]*)[\x{0622}-\x{0625}\x{0627}\x{0629}\x{062F}-\x{0632}\x{0648}\x{0671}-\x{0673}\x{0675}-\x{0677}\x{0688}-\x{0699}\x{06C0}\x{06C3}-\x{06CB}\x{06CD}\x{06CF}\x{06D2}-\x{06D3}\x{06D5}\x{06EE}-\x{06EF}\x{0710}\x{0715}-\x{0719}\x{071E}\x{0728}\x{072A}\x{072C}\x{072F}\x{074D}\x{0759}-\x{075B}\x{076B}-\x{076C}\x{0771}\x{0773}-\x{0774}\x{0778}-\x{0779}\x{0840}\x{0846}-\x{0847}\x{0849}\x{0854}\x{0856}-\x{0858}\x{0867}\x{0869}-\x{086A}\x{08AA}-\x{08AC}\x{08AE}\x{08B1}-\x{08B2}\x{08B9}\x{10AC5}\x{10AC7}\x{10AC9}-\x{10ACA}\x{10ACE}-\x{10AD2}\x{10ADD}\x{10AE1}\x{10AE4}\x{10AEF}\x{10B81}\x{10B83}-\x{10B85}\x{10B89}\x{10B8C}\x{10B8E}-\x{10B8F}\x{10B91}\x{10BA9}-\x{10BAC}\x{10D22}\x{10F33}\x{10F54}\x{10FB4}-\x{10FB6}\x{10FB9}-\x{10FBA}\x{10FBD}\x{10FC2}-\x{10FC3}\x{10FC9}\x{0620}\x{0626}\x{0628}\x{062A}-\x{062E}\x{0633}-\x{063F}\x{0641}-\x{0647}\x{0649}-\x{064A}\x{066E}-\x{066F}\x{0678}-\x{0687}\x{069A}-\x{06BF}\x{06C1}-\x{06C2}\x{06CC}\x{06CE}\x{06D0}-\x{06D1}\x{06FA}-\x{06FC}\x{06FF}\x{0712}-\x{0714}\x{071A}-\x{071D}\x{071F}-\x{0727}\x{0729}\x{072B}\x{072D}-\x{072E}\x{074E}-\x{0758}\x{075C}-\x{076A}\x{076D}-\x{0770}\x{0772}\x{0775}-\x{0777}\x{077A}-\x{077F}\x{07CA}-\x{07EA}\x{0841}-\x{0845}\x{0848}\x{084A}-\x{0853}\x{0855}\x{0860}\x{0862}-\x{0865}\x{0868}\x{08A0}-\x{08A9}\x{08AF}-\x{08B0}\x{08B3}-\x{08B4}\x{08B6}-\x{08B8}\x{08BA}-\x{08C7}\x{1807}\x{1820}-\x{1842}\x{1843}\x{1844}-\x{1878}\x{1887}-\x{18A8}\x{18AA}\x{A840}-\x{A871}\x{10AC0}-\x{10AC4}\x{10AD3}-\x{10AD6}\x{10AD8}-\x{10ADC}\x{10ADE}-\x{10AE0}\x{10AEB}-\x{10AEE}\x{10B80}\x{10B82}\x{10B86}-\x{10B88}\x{10B8A}-\x{10B8B}\x{10B8D}\x{10B90}\x{10BAD}-\x{10BAE}\x{10D01}-\x{10D21}\x{10D23}\x{10F30}-\x{10F32}\x{10F34}-\x{10F44}\x{10F51}-\x{10F53}\x{10FB0}\x{10FB2}-\x{10FB3}\x{10FB8}\x{10FBB}-\x{10FBC}\x{10FBE}-\x{10FBF}\x{10FC1}\x{10FC4}\x{10FCA}\x{1E900}-\x{1E943}]/u'; + const ZWNJ = '/([\x{A872}\x{10ACD}\x{10AD7}\x{10D00}\x{10FCB}\x{0620}\x{0626}\x{0628}\x{062A}-\x{062E}\x{0633}-\x{063F}\x{0641}-\x{0647}\x{0649}-\x{064A}\x{066E}-\x{066F}\x{0678}-\x{0687}\x{069A}-\x{06BF}\x{06C1}-\x{06C2}\x{06CC}\x{06CE}\x{06D0}-\x{06D1}\x{06FA}-\x{06FC}\x{06FF}\x{0712}-\x{0714}\x{071A}-\x{071D}\x{071F}-\x{0727}\x{0729}\x{072B}\x{072D}-\x{072E}\x{074E}-\x{0758}\x{075C}-\x{076A}\x{076D}-\x{0770}\x{0772}\x{0775}-\x{0777}\x{077A}-\x{077F}\x{07CA}-\x{07EA}\x{0841}-\x{0845}\x{0848}\x{084A}-\x{0853}\x{0855}\x{0860}\x{0862}-\x{0865}\x{0868}\x{08A0}-\x{08A9}\x{08AF}-\x{08B0}\x{08B3}-\x{08B4}\x{08B6}-\x{08B8}\x{08BA}-\x{08C7}\x{1807}\x{1820}-\x{1842}\x{1843}\x{1844}-\x{1878}\x{1887}-\x{18A8}\x{18AA}\x{A840}-\x{A871}\x{10AC0}-\x{10AC4}\x{10AD3}-\x{10AD6}\x{10AD8}-\x{10ADC}\x{10ADE}-\x{10AE0}\x{10AEB}-\x{10AEE}\x{10B80}\x{10B82}\x{10B86}-\x{10B88}\x{10B8A}-\x{10B8B}\x{10B8D}\x{10B90}\x{10BAD}-\x{10BAE}\x{10D01}-\x{10D21}\x{10D23}\x{10F30}-\x{10F32}\x{10F34}-\x{10F44}\x{10F51}-\x{10F53}\x{10FB0}\x{10FB2}-\x{10FB3}\x{10FB8}\x{10FBB}-\x{10FBC}\x{10FBE}-\x{10FBF}\x{10FC1}\x{10FC4}\x{10FCA}\x{1E900}-\x{1E943}][\x{00AD}\x{0300}-\x{036F}\x{0483}-\x{0487}\x{0488}-\x{0489}\x{0591}-\x{05BD}\x{05BF}\x{05C1}-\x{05C2}\x{05C4}-\x{05C5}\x{05C7}\x{0610}-\x{061A}\x{061C}\x{064B}-\x{065F}\x{0670}\x{06D6}-\x{06DC}\x{06DF}-\x{06E4}\x{06E7}-\x{06E8}\x{06EA}-\x{06ED}\x{070F}\x{0711}\x{0730}-\x{074A}\x{07A6}-\x{07B0}\x{07EB}-\x{07F3}\x{07FD}\x{0816}-\x{0819}\x{081B}-\x{0823}\x{0825}-\x{0827}\x{0829}-\x{082D}\x{0859}-\x{085B}\x{08D3}-\x{08E1}\x{08E3}-\x{0902}\x{093A}\x{093C}\x{0941}-\x{0948}\x{094D}\x{0951}-\x{0957}\x{0962}-\x{0963}\x{0981}\x{09BC}\x{09C1}-\x{09C4}\x{09CD}\x{09E2}-\x{09E3}\x{09FE}\x{0A01}-\x{0A02}\x{0A3C}\x{0A41}-\x{0A42}\x{0A47}-\x{0A48}\x{0A4B}-\x{0A4D}\x{0A51}\x{0A70}-\x{0A71}\x{0A75}\x{0A81}-\x{0A82}\x{0ABC}\x{0AC1}-\x{0AC5}\x{0AC7}-\x{0AC8}\x{0ACD}\x{0AE2}-\x{0AE3}\x{0AFA}-\x{0AFF}\x{0B01}\x{0B3C}\x{0B3F}\x{0B41}-\x{0B44}\x{0B4D}\x{0B55}-\x{0B56}\x{0B62}-\x{0B63}\x{0B82}\x{0BC0}\x{0BCD}\x{0C00}\x{0C04}\x{0C3E}-\x{0C40}\x{0C46}-\x{0C48}\x{0C4A}-\x{0C4D}\x{0C55}-\x{0C56}\x{0C62}-\x{0C63}\x{0C81}\x{0CBC}\x{0CBF}\x{0CC6}\x{0CCC}-\x{0CCD}\x{0CE2}-\x{0CE3}\x{0D00}-\x{0D01}\x{0D3B}-\x{0D3C}\x{0D41}-\x{0D44}\x{0D4D}\x{0D62}-\x{0D63}\x{0D81}\x{0DCA}\x{0DD2}-\x{0DD4}\x{0DD6}\x{0E31}\x{0E34}-\x{0E3A}\x{0E47}-\x{0E4E}\x{0EB1}\x{0EB4}-\x{0EBC}\x{0EC8}-\x{0ECD}\x{0F18}-\x{0F19}\x{0F35}\x{0F37}\x{0F39}\x{0F71}-\x{0F7E}\x{0F80}-\x{0F84}\x{0F86}-\x{0F87}\x{0F8D}-\x{0F97}\x{0F99}-\x{0FBC}\x{0FC6}\x{102D}-\x{1030}\x{1032}-\x{1037}\x{1039}-\x{103A}\x{103D}-\x{103E}\x{1058}-\x{1059}\x{105E}-\x{1060}\x{1071}-\x{1074}\x{1082}\x{1085}-\x{1086}\x{108D}\x{109D}\x{135D}-\x{135F}\x{1712}-\x{1714}\x{1732}-\x{1734}\x{1752}-\x{1753}\x{1772}-\x{1773}\x{17B4}-\x{17B5}\x{17B7}-\x{17BD}\x{17C6}\x{17C9}-\x{17D3}\x{17DD}\x{180B}-\x{180D}\x{1885}-\x{1886}\x{18A9}\x{1920}-\x{1922}\x{1927}-\x{1928}\x{1932}\x{1939}-\x{193B}\x{1A17}-\x{1A18}\x{1A1B}\x{1A56}\x{1A58}-\x{1A5E}\x{1A60}\x{1A62}\x{1A65}-\x{1A6C}\x{1A73}-\x{1A7C}\x{1A7F}\x{1AB0}-\x{1ABD}\x{1ABE}\x{1ABF}-\x{1AC0}\x{1B00}-\x{1B03}\x{1B34}\x{1B36}-\x{1B3A}\x{1B3C}\x{1B42}\x{1B6B}-\x{1B73}\x{1B80}-\x{1B81}\x{1BA2}-\x{1BA5}\x{1BA8}-\x{1BA9}\x{1BAB}-\x{1BAD}\x{1BE6}\x{1BE8}-\x{1BE9}\x{1BED}\x{1BEF}-\x{1BF1}\x{1C2C}-\x{1C33}\x{1C36}-\x{1C37}\x{1CD0}-\x{1CD2}\x{1CD4}-\x{1CE0}\x{1CE2}-\x{1CE8}\x{1CED}\x{1CF4}\x{1CF8}-\x{1CF9}\x{1DC0}-\x{1DF9}\x{1DFB}-\x{1DFF}\x{200B}\x{200E}-\x{200F}\x{202A}-\x{202E}\x{2060}-\x{2064}\x{206A}-\x{206F}\x{20D0}-\x{20DC}\x{20DD}-\x{20E0}\x{20E1}\x{20E2}-\x{20E4}\x{20E5}-\x{20F0}\x{2CEF}-\x{2CF1}\x{2D7F}\x{2DE0}-\x{2DFF}\x{302A}-\x{302D}\x{3099}-\x{309A}\x{A66F}\x{A670}-\x{A672}\x{A674}-\x{A67D}\x{A69E}-\x{A69F}\x{A6F0}-\x{A6F1}\x{A802}\x{A806}\x{A80B}\x{A825}-\x{A826}\x{A82C}\x{A8C4}-\x{A8C5}\x{A8E0}-\x{A8F1}\x{A8FF}\x{A926}-\x{A92D}\x{A947}-\x{A951}\x{A980}-\x{A982}\x{A9B3}\x{A9B6}-\x{A9B9}\x{A9BC}-\x{A9BD}\x{A9E5}\x{AA29}-\x{AA2E}\x{AA31}-\x{AA32}\x{AA35}-\x{AA36}\x{AA43}\x{AA4C}\x{AA7C}\x{AAB0}\x{AAB2}-\x{AAB4}\x{AAB7}-\x{AAB8}\x{AABE}-\x{AABF}\x{AAC1}\x{AAEC}-\x{AAED}\x{AAF6}\x{ABE5}\x{ABE8}\x{ABED}\x{FB1E}\x{FE00}-\x{FE0F}\x{FE20}-\x{FE2F}\x{FEFF}\x{FFF9}-\x{FFFB}\x{101FD}\x{102E0}\x{10376}-\x{1037A}\x{10A01}-\x{10A03}\x{10A05}-\x{10A06}\x{10A0C}-\x{10A0F}\x{10A38}-\x{10A3A}\x{10A3F}\x{10AE5}-\x{10AE6}\x{10D24}-\x{10D27}\x{10EAB}-\x{10EAC}\x{10F46}-\x{10F50}\x{11001}\x{11038}-\x{11046}\x{1107F}-\x{11081}\x{110B3}-\x{110B6}\x{110B9}-\x{110BA}\x{11100}-\x{11102}\x{11127}-\x{1112B}\x{1112D}-\x{11134}\x{11173}\x{11180}-\x{11181}\x{111B6}-\x{111BE}\x{111C9}-\x{111CC}\x{111CF}\x{1122F}-\x{11231}\x{11234}\x{11236}-\x{11237}\x{1123E}\x{112DF}\x{112E3}-\x{112EA}\x{11300}-\x{11301}\x{1133B}-\x{1133C}\x{11340}\x{11366}-\x{1136C}\x{11370}-\x{11374}\x{11438}-\x{1143F}\x{11442}-\x{11444}\x{11446}\x{1145E}\x{114B3}-\x{114B8}\x{114BA}\x{114BF}-\x{114C0}\x{114C2}-\x{114C3}\x{115B2}-\x{115B5}\x{115BC}-\x{115BD}\x{115BF}-\x{115C0}\x{115DC}-\x{115DD}\x{11633}-\x{1163A}\x{1163D}\x{1163F}-\x{11640}\x{116AB}\x{116AD}\x{116B0}-\x{116B5}\x{116B7}\x{1171D}-\x{1171F}\x{11722}-\x{11725}\x{11727}-\x{1172B}\x{1182F}-\x{11837}\x{11839}-\x{1183A}\x{1193B}-\x{1193C}\x{1193E}\x{11943}\x{119D4}-\x{119D7}\x{119DA}-\x{119DB}\x{119E0}\x{11A01}-\x{11A0A}\x{11A33}-\x{11A38}\x{11A3B}-\x{11A3E}\x{11A47}\x{11A51}-\x{11A56}\x{11A59}-\x{11A5B}\x{11A8A}-\x{11A96}\x{11A98}-\x{11A99}\x{11C30}-\x{11C36}\x{11C38}-\x{11C3D}\x{11C3F}\x{11C92}-\x{11CA7}\x{11CAA}-\x{11CB0}\x{11CB2}-\x{11CB3}\x{11CB5}-\x{11CB6}\x{11D31}-\x{11D36}\x{11D3A}\x{11D3C}-\x{11D3D}\x{11D3F}-\x{11D45}\x{11D47}\x{11D90}-\x{11D91}\x{11D95}\x{11D97}\x{11EF3}-\x{11EF4}\x{13430}-\x{13438}\x{16AF0}-\x{16AF4}\x{16B30}-\x{16B36}\x{16F4F}\x{16F8F}-\x{16F92}\x{16FE4}\x{1BC9D}-\x{1BC9E}\x{1BCA0}-\x{1BCA3}\x{1D167}-\x{1D169}\x{1D173}-\x{1D17A}\x{1D17B}-\x{1D182}\x{1D185}-\x{1D18B}\x{1D1AA}-\x{1D1AD}\x{1D242}-\x{1D244}\x{1DA00}-\x{1DA36}\x{1DA3B}-\x{1DA6C}\x{1DA75}\x{1DA84}\x{1DA9B}-\x{1DA9F}\x{1DAA1}-\x{1DAAF}\x{1E000}-\x{1E006}\x{1E008}-\x{1E018}\x{1E01B}-\x{1E021}\x{1E023}-\x{1E024}\x{1E026}-\x{1E02A}\x{1E130}-\x{1E136}\x{1E2EC}-\x{1E2EF}\x{1E8D0}-\x{1E8D6}\x{1E944}-\x{1E94A}\x{1E94B}\x{E0001}\x{E0020}-\x{E007F}\x{E0100}-\x{E01EF}]*\x{200C}[\x{00AD}\x{0300}-\x{036F}\x{0483}-\x{0487}\x{0488}-\x{0489}\x{0591}-\x{05BD}\x{05BF}\x{05C1}-\x{05C2}\x{05C4}-\x{05C5}\x{05C7}\x{0610}-\x{061A}\x{061C}\x{064B}-\x{065F}\x{0670}\x{06D6}-\x{06DC}\x{06DF}-\x{06E4}\x{06E7}-\x{06E8}\x{06EA}-\x{06ED}\x{070F}\x{0711}\x{0730}-\x{074A}\x{07A6}-\x{07B0}\x{07EB}-\x{07F3}\x{07FD}\x{0816}-\x{0819}\x{081B}-\x{0823}\x{0825}-\x{0827}\x{0829}-\x{082D}\x{0859}-\x{085B}\x{08D3}-\x{08E1}\x{08E3}-\x{0902}\x{093A}\x{093C}\x{0941}-\x{0948}\x{094D}\x{0951}-\x{0957}\x{0962}-\x{0963}\x{0981}\x{09BC}\x{09C1}-\x{09C4}\x{09CD}\x{09E2}-\x{09E3}\x{09FE}\x{0A01}-\x{0A02}\x{0A3C}\x{0A41}-\x{0A42}\x{0A47}-\x{0A48}\x{0A4B}-\x{0A4D}\x{0A51}\x{0A70}-\x{0A71}\x{0A75}\x{0A81}-\x{0A82}\x{0ABC}\x{0AC1}-\x{0AC5}\x{0AC7}-\x{0AC8}\x{0ACD}\x{0AE2}-\x{0AE3}\x{0AFA}-\x{0AFF}\x{0B01}\x{0B3C}\x{0B3F}\x{0B41}-\x{0B44}\x{0B4D}\x{0B55}-\x{0B56}\x{0B62}-\x{0B63}\x{0B82}\x{0BC0}\x{0BCD}\x{0C00}\x{0C04}\x{0C3E}-\x{0C40}\x{0C46}-\x{0C48}\x{0C4A}-\x{0C4D}\x{0C55}-\x{0C56}\x{0C62}-\x{0C63}\x{0C81}\x{0CBC}\x{0CBF}\x{0CC6}\x{0CCC}-\x{0CCD}\x{0CE2}-\x{0CE3}\x{0D00}-\x{0D01}\x{0D3B}-\x{0D3C}\x{0D41}-\x{0D44}\x{0D4D}\x{0D62}-\x{0D63}\x{0D81}\x{0DCA}\x{0DD2}-\x{0DD4}\x{0DD6}\x{0E31}\x{0E34}-\x{0E3A}\x{0E47}-\x{0E4E}\x{0EB1}\x{0EB4}-\x{0EBC}\x{0EC8}-\x{0ECD}\x{0F18}-\x{0F19}\x{0F35}\x{0F37}\x{0F39}\x{0F71}-\x{0F7E}\x{0F80}-\x{0F84}\x{0F86}-\x{0F87}\x{0F8D}-\x{0F97}\x{0F99}-\x{0FBC}\x{0FC6}\x{102D}-\x{1030}\x{1032}-\x{1037}\x{1039}-\x{103A}\x{103D}-\x{103E}\x{1058}-\x{1059}\x{105E}-\x{1060}\x{1071}-\x{1074}\x{1082}\x{1085}-\x{1086}\x{108D}\x{109D}\x{135D}-\x{135F}\x{1712}-\x{1714}\x{1732}-\x{1734}\x{1752}-\x{1753}\x{1772}-\x{1773}\x{17B4}-\x{17B5}\x{17B7}-\x{17BD}\x{17C6}\x{17C9}-\x{17D3}\x{17DD}\x{180B}-\x{180D}\x{1885}-\x{1886}\x{18A9}\x{1920}-\x{1922}\x{1927}-\x{1928}\x{1932}\x{1939}-\x{193B}\x{1A17}-\x{1A18}\x{1A1B}\x{1A56}\x{1A58}-\x{1A5E}\x{1A60}\x{1A62}\x{1A65}-\x{1A6C}\x{1A73}-\x{1A7C}\x{1A7F}\x{1AB0}-\x{1ABD}\x{1ABE}\x{1ABF}-\x{1AC0}\x{1B00}-\x{1B03}\x{1B34}\x{1B36}-\x{1B3A}\x{1B3C}\x{1B42}\x{1B6B}-\x{1B73}\x{1B80}-\x{1B81}\x{1BA2}-\x{1BA5}\x{1BA8}-\x{1BA9}\x{1BAB}-\x{1BAD}\x{1BE6}\x{1BE8}-\x{1BE9}\x{1BED}\x{1BEF}-\x{1BF1}\x{1C2C}-\x{1C33}\x{1C36}-\x{1C37}\x{1CD0}-\x{1CD2}\x{1CD4}-\x{1CE0}\x{1CE2}-\x{1CE8}\x{1CED}\x{1CF4}\x{1CF8}-\x{1CF9}\x{1DC0}-\x{1DF9}\x{1DFB}-\x{1DFF}\x{200B}\x{200E}-\x{200F}\x{202A}-\x{202E}\x{2060}-\x{2064}\x{206A}-\x{206F}\x{20D0}-\x{20DC}\x{20DD}-\x{20E0}\x{20E1}\x{20E2}-\x{20E4}\x{20E5}-\x{20F0}\x{2CEF}-\x{2CF1}\x{2D7F}\x{2DE0}-\x{2DFF}\x{302A}-\x{302D}\x{3099}-\x{309A}\x{A66F}\x{A670}-\x{A672}\x{A674}-\x{A67D}\x{A69E}-\x{A69F}\x{A6F0}-\x{A6F1}\x{A802}\x{A806}\x{A80B}\x{A825}-\x{A826}\x{A82C}\x{A8C4}-\x{A8C5}\x{A8E0}-\x{A8F1}\x{A8FF}\x{A926}-\x{A92D}\x{A947}-\x{A951}\x{A980}-\x{A982}\x{A9B3}\x{A9B6}-\x{A9B9}\x{A9BC}-\x{A9BD}\x{A9E5}\x{AA29}-\x{AA2E}\x{AA31}-\x{AA32}\x{AA35}-\x{AA36}\x{AA43}\x{AA4C}\x{AA7C}\x{AAB0}\x{AAB2}-\x{AAB4}\x{AAB7}-\x{AAB8}\x{AABE}-\x{AABF}\x{AAC1}\x{AAEC}-\x{AAED}\x{AAF6}\x{ABE5}\x{ABE8}\x{ABED}\x{FB1E}\x{FE00}-\x{FE0F}\x{FE20}-\x{FE2F}\x{FEFF}\x{FFF9}-\x{FFFB}\x{101FD}\x{102E0}\x{10376}-\x{1037A}\x{10A01}-\x{10A03}\x{10A05}-\x{10A06}\x{10A0C}-\x{10A0F}\x{10A38}-\x{10A3A}\x{10A3F}\x{10AE5}-\x{10AE6}\x{10D24}-\x{10D27}\x{10EAB}-\x{10EAC}\x{10F46}-\x{10F50}\x{11001}\x{11038}-\x{11046}\x{1107F}-\x{11081}\x{110B3}-\x{110B6}\x{110B9}-\x{110BA}\x{11100}-\x{11102}\x{11127}-\x{1112B}\x{1112D}-\x{11134}\x{11173}\x{11180}-\x{11181}\x{111B6}-\x{111BE}\x{111C9}-\x{111CC}\x{111CF}\x{1122F}-\x{11231}\x{11234}\x{11236}-\x{11237}\x{1123E}\x{112DF}\x{112E3}-\x{112EA}\x{11300}-\x{11301}\x{1133B}-\x{1133C}\x{11340}\x{11366}-\x{1136C}\x{11370}-\x{11374}\x{11438}-\x{1143F}\x{11442}-\x{11444}\x{11446}\x{1145E}\x{114B3}-\x{114B8}\x{114BA}\x{114BF}-\x{114C0}\x{114C2}-\x{114C3}\x{115B2}-\x{115B5}\x{115BC}-\x{115BD}\x{115BF}-\x{115C0}\x{115DC}-\x{115DD}\x{11633}-\x{1163A}\x{1163D}\x{1163F}-\x{11640}\x{116AB}\x{116AD}\x{116B0}-\x{116B5}\x{116B7}\x{1171D}-\x{1171F}\x{11722}-\x{11725}\x{11727}-\x{1172B}\x{1182F}-\x{11837}\x{11839}-\x{1183A}\x{1193B}-\x{1193C}\x{1193E}\x{11943}\x{119D4}-\x{119D7}\x{119DA}-\x{119DB}\x{119E0}\x{11A01}-\x{11A0A}\x{11A33}-\x{11A38}\x{11A3B}-\x{11A3E}\x{11A47}\x{11A51}-\x{11A56}\x{11A59}-\x{11A5B}\x{11A8A}-\x{11A96}\x{11A98}-\x{11A99}\x{11C30}-\x{11C36}\x{11C38}-\x{11C3D}\x{11C3F}\x{11C92}-\x{11CA7}\x{11CAA}-\x{11CB0}\x{11CB2}-\x{11CB3}\x{11CB5}-\x{11CB6}\x{11D31}-\x{11D36}\x{11D3A}\x{11D3C}-\x{11D3D}\x{11D3F}-\x{11D45}\x{11D47}\x{11D90}-\x{11D91}\x{11D95}\x{11D97}\x{11EF3}-\x{11EF4}\x{13430}-\x{13438}\x{16AF0}-\x{16AF4}\x{16B30}-\x{16B36}\x{16F4F}\x{16F8F}-\x{16F92}\x{16FE4}\x{1BC9D}-\x{1BC9E}\x{1BCA0}-\x{1BCA3}\x{1D167}-\x{1D169}\x{1D173}-\x{1D17A}\x{1D17B}-\x{1D182}\x{1D185}-\x{1D18B}\x{1D1AA}-\x{1D1AD}\x{1D242}-\x{1D244}\x{1DA00}-\x{1DA36}\x{1DA3B}-\x{1DA6C}\x{1DA75}\x{1DA84}\x{1DA9B}-\x{1DA9F}\x{1DAA1}-\x{1DAAF}\x{1E000}-\x{1E006}\x{1E008}-\x{1E018}\x{1E01B}-\x{1E021}\x{1E023}-\x{1E024}\x{1E026}-\x{1E02A}\x{1E130}-\x{1E136}\x{1E2EC}-\x{1E2EF}\x{1E8D0}-\x{1E8D6}\x{1E944}-\x{1E94A}\x{1E94B}\x{E0001}\x{E0020}-\x{E007F}\x{E0100}-\x{E01EF}]*)[\x{0622}-\x{0625}\x{0627}\x{0629}\x{062F}-\x{0632}\x{0648}\x{0671}-\x{0673}\x{0675}-\x{0677}\x{0688}-\x{0699}\x{06C0}\x{06C3}-\x{06CB}\x{06CD}\x{06CF}\x{06D2}-\x{06D3}\x{06D5}\x{06EE}-\x{06EF}\x{0710}\x{0715}-\x{0719}\x{071E}\x{0728}\x{072A}\x{072C}\x{072F}\x{074D}\x{0759}-\x{075B}\x{076B}-\x{076C}\x{0771}\x{0773}-\x{0774}\x{0778}-\x{0779}\x{0840}\x{0846}-\x{0847}\x{0849}\x{0854}\x{0856}-\x{0858}\x{0867}\x{0869}-\x{086A}\x{08AA}-\x{08AC}\x{08AE}\x{08B1}-\x{08B2}\x{08B9}\x{10AC5}\x{10AC7}\x{10AC9}-\x{10ACA}\x{10ACE}-\x{10AD2}\x{10ADD}\x{10AE1}\x{10AE4}\x{10AEF}\x{10B81}\x{10B83}-\x{10B85}\x{10B89}\x{10B8C}\x{10B8E}-\x{10B8F}\x{10B91}\x{10BA9}-\x{10BAC}\x{10D22}\x{10F33}\x{10F54}\x{10FB4}-\x{10FB6}\x{10FB9}-\x{10FBA}\x{10FBD}\x{10FC2}-\x{10FC3}\x{10FC9}\x{0620}\x{0626}\x{0628}\x{062A}-\x{062E}\x{0633}-\x{063F}\x{0641}-\x{0647}\x{0649}-\x{064A}\x{066E}-\x{066F}\x{0678}-\x{0687}\x{069A}-\x{06BF}\x{06C1}-\x{06C2}\x{06CC}\x{06CE}\x{06D0}-\x{06D1}\x{06FA}-\x{06FC}\x{06FF}\x{0712}-\x{0714}\x{071A}-\x{071D}\x{071F}-\x{0727}\x{0729}\x{072B}\x{072D}-\x{072E}\x{074E}-\x{0758}\x{075C}-\x{076A}\x{076D}-\x{0770}\x{0772}\x{0775}-\x{0777}\x{077A}-\x{077F}\x{07CA}-\x{07EA}\x{0841}-\x{0845}\x{0848}\x{084A}-\x{0853}\x{0855}\x{0860}\x{0862}-\x{0865}\x{0868}\x{08A0}-\x{08A9}\x{08AF}-\x{08B0}\x{08B3}-\x{08B4}\x{08B6}-\x{08B8}\x{08BA}-\x{08C7}\x{1807}\x{1820}-\x{1842}\x{1843}\x{1844}-\x{1878}\x{1887}-\x{18A8}\x{18AA}\x{A840}-\x{A871}\x{10AC0}-\x{10AC4}\x{10AD3}-\x{10AD6}\x{10AD8}-\x{10ADC}\x{10ADE}-\x{10AE0}\x{10AEB}-\x{10AEE}\x{10B80}\x{10B82}\x{10B86}-\x{10B88}\x{10B8A}-\x{10B8B}\x{10B8D}\x{10B90}\x{10BAD}-\x{10BAE}\x{10D01}-\x{10D21}\x{10D23}\x{10F30}-\x{10F32}\x{10F34}-\x{10F44}\x{10F51}-\x{10F53}\x{10FB0}\x{10FB2}-\x{10FB3}\x{10FB8}\x{10FBB}-\x{10FBC}\x{10FBE}-\x{10FBF}\x{10FC1}\x{10FC4}\x{10FCA}\x{1E900}-\x{1E943}]/u'; } diff --git a/vendor/symfony/polyfill-intl-idn/bootstrap80.php b/vendor/symfony/polyfill-intl-idn/bootstrap80.php index 896538697..a42ab81ac 100644 --- a/vendor/symfony/polyfill-intl-idn/bootstrap80.php +++ b/vendor/symfony/polyfill-intl-idn/bootstrap80.php @@ -74,9 +74,6 @@ if (!defined('IDNA_NONTRANSITIONAL_TO_ASCII')) { if (!defined('IDNA_NONTRANSITIONAL_TO_UNICODE')) { define('IDNA_NONTRANSITIONAL_TO_UNICODE', 32); } -if (!defined('INTL_IDNA_VARIANT_2003')) { - define('INTL_IDNA_VARIANT_2003', 0); -} if (!defined('INTL_IDNA_VARIANT_UTS46')) { define('INTL_IDNA_VARIANT_UTS46', 1); } diff --git a/vendor/symfony/polyfill-intl-idn/composer.json b/vendor/symfony/polyfill-intl-idn/composer.json index 450d1e7b2..c5a2a462a 100644 --- a/vendor/symfony/polyfill-intl-idn/composer.json +++ b/vendor/symfony/polyfill-intl-idn/composer.json @@ -34,7 +34,7 @@ "minimum-stability": "dev", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", diff --git a/vendor/symfony/polyfill-intl-normalizer/composer.json b/vendor/symfony/polyfill-intl-normalizer/composer.json index 8f4cfb4dc..393edf701 100644 --- a/vendor/symfony/polyfill-intl-normalizer/composer.json +++ b/vendor/symfony/polyfill-intl-normalizer/composer.json @@ -29,7 +29,7 @@ "minimum-stability": "dev", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", diff --git a/vendor/symfony/polyfill-mbstring/Mbstring.php b/vendor/symfony/polyfill-mbstring/Mbstring.php index 8b3b75893..c31611fb8 100644 --- a/vendor/symfony/polyfill-mbstring/Mbstring.php +++ b/vendor/symfony/polyfill-mbstring/Mbstring.php @@ -101,7 +101,7 @@ final class Mbstring $fromEncoding = 'Windows-1252'; } if ('UTF-8' !== $fromEncoding) { - $s = iconv($fromEncoding, 'UTF-8//IGNORE', $s); + $s = \iconv($fromEncoding, 'UTF-8//IGNORE', $s); } return preg_replace_callback('/[\x80-\xFF]+/', [__CLASS__, 'html_encoding_callback'], $s); @@ -112,7 +112,7 @@ final class Mbstring $fromEncoding = 'UTF-8'; } - return iconv($fromEncoding, $toEncoding.'//IGNORE', $s); + return \iconv($fromEncoding, $toEncoding.'//IGNORE', $s); } public static function mb_convert_variables($toEncoding, $fromEncoding, &...$vars) @@ -129,7 +129,7 @@ final class Mbstring public static function mb_decode_mimeheader($s) { - return iconv_mime_decode($s, 2, self::$internalEncoding); + return \iconv_mime_decode($s, 2, self::$internalEncoding); } public static function mb_encode_mimeheader($s, $charset = null, $transferEncoding = null, $linefeed = null, $indent = null) @@ -165,10 +165,10 @@ final class Mbstring if ('UTF-8' === $encoding) { $encoding = null; if (!preg_match('//u', $s)) { - $s = @iconv('UTF-8', 'UTF-8//IGNORE', $s); + $s = @\iconv('UTF-8', 'UTF-8//IGNORE', $s); } } else { - $s = iconv($encoding, 'UTF-8//IGNORE', $s); + $s = \iconv($encoding, 'UTF-8//IGNORE', $s); } $cnt = floor(\count($convmap) / 4) * 4; @@ -194,7 +194,7 @@ final class Mbstring return $s; } - return iconv('UTF-8', $encoding.'//IGNORE', $s); + return \iconv('UTF-8', $encoding.'//IGNORE', $s); } public static function mb_encode_numericentity($s, $convmap, $encoding = null, $is_hex = false) @@ -231,10 +231,10 @@ final class Mbstring if ('UTF-8' === $encoding) { $encoding = null; if (!preg_match('//u', $s)) { - $s = @iconv('UTF-8', 'UTF-8//IGNORE', $s); + $s = @\iconv('UTF-8', 'UTF-8//IGNORE', $s); } } else { - $s = iconv($encoding, 'UTF-8//IGNORE', $s); + $s = \iconv($encoding, 'UTF-8//IGNORE', $s); } static $ulenMask = ["\xC0" => 2, "\xD0" => 2, "\xE0" => 3, "\xF0" => 4]; @@ -264,7 +264,7 @@ final class Mbstring return $result; } - return iconv('UTF-8', $encoding.'//IGNORE', $result); + return \iconv('UTF-8', $encoding.'//IGNORE', $result); } public static function mb_convert_case($s, $mode, $encoding = null) @@ -279,10 +279,10 @@ final class Mbstring if ('UTF-8' === $encoding) { $encoding = null; if (!preg_match('//u', $s)) { - $s = @iconv('UTF-8', 'UTF-8//IGNORE', $s); + $s = @\iconv('UTF-8', 'UTF-8//IGNORE', $s); } } else { - $s = iconv($encoding, 'UTF-8//IGNORE', $s); + $s = \iconv($encoding, 'UTF-8//IGNORE', $s); } if (\MB_CASE_TITLE == $mode) { @@ -342,7 +342,7 @@ final class Mbstring return $s; } - return iconv('UTF-8', $encoding.'//IGNORE', $s); + return \iconv('UTF-8', $encoding.'//IGNORE', $s); } public static function mb_internal_encoding($encoding = null) @@ -353,7 +353,7 @@ final class Mbstring $normalizedEncoding = self::getEncoding($encoding); - if ('UTF-8' === $normalizedEncoding || false !== @iconv($normalizedEncoding, $normalizedEncoding, ' ')) { + if ('UTF-8' === $normalizedEncoding || false !== @\iconv($normalizedEncoding, $normalizedEncoding, ' ')) { self::$internalEncoding = $normalizedEncoding; return true; @@ -412,7 +412,7 @@ final class Mbstring $encoding = self::$internalEncoding; } - return self::mb_detect_encoding($var, [$encoding]) || false !== @iconv($encoding, $encoding, $var); + return self::mb_detect_encoding($var, [$encoding]) || false !== @\iconv($encoding, $encoding, $var); } public static function mb_detect_encoding($str, $encodingList = null, $strict = false) @@ -487,7 +487,7 @@ final class Mbstring return \strlen($s); } - return @iconv_strlen($s, $encoding); + return @\iconv_strlen($s, $encoding); } public static function mb_strpos($haystack, $needle, $offset = 0, $encoding = null) @@ -508,7 +508,7 @@ final class Mbstring return 0; } - return iconv_strpos($haystack, $needle, $offset, $encoding); + return \iconv_strpos($haystack, $needle, $offset, $encoding); } public static function mb_strrpos($haystack, $needle, $offset = 0, $encoding = null) @@ -532,7 +532,7 @@ final class Mbstring } $pos = '' !== $needle || 80000 > \PHP_VERSION_ID - ? iconv_strrpos($haystack, $needle, $encoding) + ? \iconv_strrpos($haystack, $needle, $encoding) : self::mb_strlen($haystack, $encoding); return false !== $pos ? $offset + $pos : false; @@ -613,7 +613,7 @@ final class Mbstring } if ($start < 0) { - $start = iconv_strlen($s, $encoding) + $start; + $start = \iconv_strlen($s, $encoding) + $start; if ($start < 0) { $start = 0; } @@ -622,13 +622,13 @@ final class Mbstring if (null === $length) { $length = 2147483647; } elseif ($length < 0) { - $length = iconv_strlen($s, $encoding) + $length - $start; + $length = \iconv_strlen($s, $encoding) + $length - $start; if ($length < 0) { return ''; } } - return (string) iconv_substr($s, $start, $length, $encoding); + return (string) \iconv_substr($s, $start, $length, $encoding); } public static function mb_stripos($haystack, $needle, $offset = 0, $encoding = null) @@ -653,7 +653,7 @@ final class Mbstring $pos = strrpos($haystack, $needle); } else { $needle = self::mb_substr($needle, 0, 1, $encoding); - $pos = iconv_strrpos($haystack, $needle, $encoding); + $pos = \iconv_strrpos($haystack, $needle, $encoding); } return self::getSubpart($pos, $part, $haystack, $encoding); @@ -732,12 +732,12 @@ final class Mbstring $encoding = self::getEncoding($encoding); if ('UTF-8' !== $encoding) { - $s = iconv($encoding, 'UTF-8//IGNORE', $s); + $s = \iconv($encoding, 'UTF-8//IGNORE', $s); } $s = preg_replace('/[\x{1100}-\x{115F}\x{2329}\x{232A}\x{2E80}-\x{303E}\x{3040}-\x{A4CF}\x{AC00}-\x{D7A3}\x{F900}-\x{FAFF}\x{FE10}-\x{FE19}\x{FE30}-\x{FE6F}\x{FF00}-\x{FF60}\x{FFE0}-\x{FFE6}\x{20000}-\x{2FFFD}\x{30000}-\x{3FFFD}]/u', '', $s, -1, $wide); - return ($wide << 1) + iconv_strlen($s, 'UTF-8'); + return ($wide << 1) + \iconv_strlen($s, 'UTF-8'); } public static function mb_substr_count($haystack, $needle, $encoding = null) diff --git a/vendor/symfony/polyfill-mbstring/Resources/unidata/lowerCase.php b/vendor/symfony/polyfill-mbstring/Resources/unidata/lowerCase.php index a22eca57b..fac60b081 100644 --- a/vendor/symfony/polyfill-mbstring/Resources/unidata/lowerCase.php +++ b/vendor/symfony/polyfill-mbstring/Resources/unidata/lowerCase.php @@ -81,7 +81,7 @@ return array ( 'Ī' => 'ī', 'Ĭ' => 'ĭ', 'Į' => 'į', - 'İ' => 'i', + 'İ' => 'i̇', 'IJ' => 'ij', 'Ĵ' => 'ĵ', 'Ķ' => 'ķ', diff --git a/vendor/symfony/polyfill-mbstring/Resources/unidata/upperCase.php b/vendor/symfony/polyfill-mbstring/Resources/unidata/upperCase.php index ecbc15895..56b9cb852 100644 --- a/vendor/symfony/polyfill-mbstring/Resources/unidata/upperCase.php +++ b/vendor/symfony/polyfill-mbstring/Resources/unidata/upperCase.php @@ -746,41 +746,41 @@ return array ( 'ύ' => 'Ύ', 'ὼ' => 'Ὼ', 'ώ' => 'Ώ', - 'ᾀ' => 'ᾈ', - 'ᾁ' => 'ᾉ', - 'ᾂ' => 'ᾊ', - 'ᾃ' => 'ᾋ', - 'ᾄ' => 'ᾌ', - 'ᾅ' => 'ᾍ', - 'ᾆ' => 'ᾎ', - 'ᾇ' => 'ᾏ', - 'ᾐ' => 'ᾘ', - 'ᾑ' => 'ᾙ', - 'ᾒ' => 'ᾚ', - 'ᾓ' => 'ᾛ', - 'ᾔ' => 'ᾜ', - 'ᾕ' => 'ᾝ', - 'ᾖ' => 'ᾞ', - 'ᾗ' => 'ᾟ', - 'ᾠ' => 'ᾨ', - 'ᾡ' => 'ᾩ', - 'ᾢ' => 'ᾪ', - 'ᾣ' => 'ᾫ', - 'ᾤ' => 'ᾬ', - 'ᾥ' => 'ᾭ', - 'ᾦ' => 'ᾮ', - 'ᾧ' => 'ᾯ', + 'ᾀ' => 'ἈΙ', + 'ᾁ' => 'ἉΙ', + 'ᾂ' => 'ἊΙ', + 'ᾃ' => 'ἋΙ', + 'ᾄ' => 'ἌΙ', + 'ᾅ' => 'ἍΙ', + 'ᾆ' => 'ἎΙ', + 'ᾇ' => 'ἏΙ', + 'ᾐ' => 'ἨΙ', + 'ᾑ' => 'ἩΙ', + 'ᾒ' => 'ἪΙ', + 'ᾓ' => 'ἫΙ', + 'ᾔ' => 'ἬΙ', + 'ᾕ' => 'ἭΙ', + 'ᾖ' => 'ἮΙ', + 'ᾗ' => 'ἯΙ', + 'ᾠ' => 'ὨΙ', + 'ᾡ' => 'ὩΙ', + 'ᾢ' => 'ὪΙ', + 'ᾣ' => 'ὫΙ', + 'ᾤ' => 'ὬΙ', + 'ᾥ' => 'ὭΙ', + 'ᾦ' => 'ὮΙ', + 'ᾧ' => 'ὯΙ', 'ᾰ' => 'Ᾰ', 'ᾱ' => 'Ᾱ', - 'ᾳ' => 'ᾼ', + 'ᾳ' => 'ΑΙ', 'ι' => 'Ι', - 'ῃ' => 'ῌ', + 'ῃ' => 'ΗΙ', 'ῐ' => 'Ῐ', 'ῑ' => 'Ῑ', 'ῠ' => 'Ῠ', 'ῡ' => 'Ῡ', 'ῥ' => 'Ῥ', - 'ῳ' => 'ῼ', + 'ῳ' => 'ΩΙ', 'ⅎ' => 'Ⅎ', 'ⅰ' => 'Ⅰ', 'ⅱ' => 'Ⅱ', @@ -1411,4 +1411,79 @@ return array ( '𞥁' => '𞤟', '𞥂' => '𞤠', '𞥃' => '𞤡', + 'ß' => 'SS', + 'ff' => 'FF', + 'fi' => 'FI', + 'fl' => 'FL', + 'ffi' => 'FFI', + 'ffl' => 'FFL', + 'ſt' => 'ST', + 'st' => 'ST', + 'և' => 'ԵՒ', + 'ﬓ' => 'ՄՆ', + 'ﬔ' => 'ՄԵ', + 'ﬕ' => 'ՄԻ', + 'ﬖ' => 'ՎՆ', + 'ﬗ' => 'ՄԽ', + 'ʼn' => 'ʼN', + 'ΐ' => 'Ϊ́', + 'ΰ' => 'Ϋ́', + 'ǰ' => 'J̌', + 'ẖ' => 'H̱', + 'ẗ' => 'T̈', + 'ẘ' => 'W̊', + 'ẙ' => 'Y̊', + 'ẚ' => 'Aʾ', + 'ὐ' => 'Υ̓', + 'ὒ' => 'Υ̓̀', + 'ὔ' => 'Υ̓́', + 'ὖ' => 'Υ̓͂', + 'ᾶ' => 'Α͂', + 'ῆ' => 'Η͂', + 'ῒ' => 'Ϊ̀', + 'ΐ' => 'Ϊ́', + 'ῖ' => 'Ι͂', + 'ῗ' => 'Ϊ͂', + 'ῢ' => 'Ϋ̀', + 'ΰ' => 'Ϋ́', + 'ῤ' => 'Ρ̓', + 'ῦ' => 'Υ͂', + 'ῧ' => 'Ϋ͂', + 'ῶ' => 'Ω͂', + 'ᾈ' => 'ἈΙ', + 'ᾉ' => 'ἉΙ', + 'ᾊ' => 'ἊΙ', + 'ᾋ' => 'ἋΙ', + 'ᾌ' => 'ἌΙ', + 'ᾍ' => 'ἍΙ', + 'ᾎ' => 'ἎΙ', + 'ᾏ' => 'ἏΙ', + 'ᾘ' => 'ἨΙ', + 'ᾙ' => 'ἩΙ', + 'ᾚ' => 'ἪΙ', + 'ᾛ' => 'ἫΙ', + 'ᾜ' => 'ἬΙ', + 'ᾝ' => 'ἭΙ', + 'ᾞ' => 'ἮΙ', + 'ᾟ' => 'ἯΙ', + 'ᾨ' => 'ὨΙ', + 'ᾩ' => 'ὩΙ', + 'ᾪ' => 'ὪΙ', + 'ᾫ' => 'ὫΙ', + 'ᾬ' => 'ὬΙ', + 'ᾭ' => 'ὭΙ', + 'ᾮ' => 'ὮΙ', + 'ᾯ' => 'ὯΙ', + 'ᾼ' => 'ΑΙ', + 'ῌ' => 'ΗΙ', + 'ῼ' => 'ΩΙ', + 'ᾲ' => 'ᾺΙ', + 'ᾴ' => 'ΆΙ', + 'ῂ' => 'ῊΙ', + 'ῄ' => 'ΉΙ', + 'ῲ' => 'ῺΙ', + 'ῴ' => 'ΏΙ', + 'ᾷ' => 'Α͂Ι', + 'ῇ' => 'Η͂Ι', + 'ῷ' => 'Ω͂Ι', ); diff --git a/vendor/symfony/polyfill-mbstring/bootstrap.php b/vendor/symfony/polyfill-mbstring/bootstrap.php index c45624c9f..1fedd1f7c 100644 --- a/vendor/symfony/polyfill-mbstring/bootstrap.php +++ b/vendor/symfony/polyfill-mbstring/bootstrap.php @@ -55,7 +55,7 @@ if (!function_exists('mb_detect_order')) { function mb_detect_order($encoding = null) { return p\Mbstring::mb_detect_order($encoding); } } if (!function_exists('mb_parse_str')) { - function mb_parse_str($string, &$result = []) { parse_str($string, $result); } + function mb_parse_str($string, &$result = []) { parse_str($string, $result); return (bool) $result; } } if (!function_exists('mb_strlen')) { function mb_strlen($string, $encoding = null) { return p\Mbstring::mb_strlen($string, $encoding); } diff --git a/vendor/symfony/polyfill-mbstring/bootstrap80.php b/vendor/symfony/polyfill-mbstring/bootstrap80.php index f404f5fea..82f5ac4d0 100644 --- a/vendor/symfony/polyfill-mbstring/bootstrap80.php +++ b/vendor/symfony/polyfill-mbstring/bootstrap80.php @@ -48,10 +48,10 @@ if (!function_exists('mb_detect_encoding')) { function mb_detect_encoding(?string $string, array|string|null $encodings = null, ?bool $strict = false): string|false { return p\Mbstring::mb_detect_encoding((string) $string, $encodings, (bool) $strict); } } if (!function_exists('mb_detect_order')) { - function mb_detect_order(array|string|null $encoding = null): array|bool { return p\Mbstring::mb_detect_order((string) $encoding); } + function mb_detect_order(array|string|null $encoding = null): array|bool { return p\Mbstring::mb_detect_order($encoding); } } if (!function_exists('mb_parse_str')) { - function mb_parse_str(?string $string, &$result = []): bool { parse_str((string) $string, $result); } + function mb_parse_str(?string $string, &$result = []): bool { parse_str((string) $string, $result); return (bool) $result; } } if (!function_exists('mb_strlen')) { function mb_strlen(?string $string, ?string $encoding = null): int { return p\Mbstring::mb_strlen((string) $string, $encoding); } @@ -78,7 +78,7 @@ if (!function_exists('mb_stristr')) { function mb_stristr(?string $haystack, ?string $needle, ?bool $before_needle = false, ?string $encoding = null): string|false { return p\Mbstring::mb_stristr((string) $haystack, (string) $needle, (bool) $before_needle, $encoding); } } if (!function_exists('mb_strrchr')) { - function mb_strrchr(?string $haystack, ?string $needle, ?bool $before_needle = false, ?string $encoding = null): string|false { return p\Mbstring::mb_strrchr((string) $haystack, (string) $needle, $before_needle, (bool) $encoding); } + function mb_strrchr(?string $haystack, ?string $needle, ?bool $before_needle = false, ?string $encoding = null): string|false { return p\Mbstring::mb_strrchr((string) $haystack, (string) $needle, (bool) $before_needle, $encoding); } } if (!function_exists('mb_strrichr')) { function mb_strrichr(?string $haystack, ?string $needle, ?bool $before_needle = false, ?string $encoding = null): string|false { return p\Mbstring::mb_strrichr((string) $haystack, (string) $needle, (bool) $before_needle, $encoding); } diff --git a/vendor/symfony/polyfill-mbstring/composer.json b/vendor/symfony/polyfill-mbstring/composer.json index ca8263859..2ed7a7435 100644 --- a/vendor/symfony/polyfill-mbstring/composer.json +++ b/vendor/symfony/polyfill-mbstring/composer.json @@ -28,7 +28,7 @@ "minimum-stability": "dev", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", diff --git a/vendor/symfony/polyfill-php72/Php72.php b/vendor/symfony/polyfill-php72/Php72.php index 2b706d42b..5e20d5bf8 100644 --- a/vendor/symfony/polyfill-php72/Php72.php +++ b/vendor/symfony/polyfill-php72/Php72.php @@ -182,7 +182,7 @@ final class Php72 $s = \chr(0xF0 | $code >> 18).\chr(0x80 | $code >> 12 & 0x3F).\chr(0x80 | $code >> 6 & 0x3F).\chr(0x80 | $code & 0x3F); } - if ('UTF-8' !== $encoding) { + if ('UTF-8' !== $encoding = $encoding ?? mb_internal_encoding()) { $s = mb_convert_encoding($s, $encoding, 'UTF-8'); } diff --git a/vendor/symfony/polyfill-php72/composer.json b/vendor/symfony/polyfill-php72/composer.json index 7946892c3..c96c84477 100644 --- a/vendor/symfony/polyfill-php72/composer.json +++ b/vendor/symfony/polyfill-php72/composer.json @@ -25,7 +25,7 @@ "minimum-stability": "dev", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", diff --git a/vendor/symfony/polyfill-php73/composer.json b/vendor/symfony/polyfill-php73/composer.json index 8b99ab890..a7fe47875 100644 --- a/vendor/symfony/polyfill-php73/composer.json +++ b/vendor/symfony/polyfill-php73/composer.json @@ -26,7 +26,7 @@ "minimum-stability": "dev", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", diff --git a/vendor/symfony/polyfill-php80/composer.json b/vendor/symfony/polyfill-php80/composer.json index a9e6813c9..5fe679db3 100644 --- a/vendor/symfony/polyfill-php80/composer.json +++ b/vendor/symfony/polyfill-php80/composer.json @@ -30,7 +30,7 @@ "minimum-stability": "dev", "extra": { "branch-alias": { - "dev-main": "1.22-dev" + "dev-main": "1.23-dev" }, "thanks": { "name": "symfony/polyfill", diff --git a/vendor/symfony/routing/Generator/UrlGenerator.php b/vendor/symfony/routing/Generator/UrlGenerator.php index b2768f7f5..2bef04ed8 100644 --- a/vendor/symfony/routing/Generator/UrlGenerator.php +++ b/vendor/symfony/routing/Generator/UrlGenerator.php @@ -188,7 +188,7 @@ class UrlGenerator implements UrlGeneratorInterface, ConfigurableRequirementsInt if (!$optional || $important || !\array_key_exists($varName, $defaults) || (null !== $mergedParams[$varName] && (string) $mergedParams[$varName] !== (string) $defaults[$varName])) { // check requirement (while ignoring look-around patterns) - if (null !== $this->strictRequirements && !preg_match('#^'.preg_replace('/\(\?(?:=|<=|!|strictRequirements && !preg_match('#^'.preg_replace('/\(\?(?:=|<=|!|strictRequirements) { throw new InvalidParameterException(strtr($message, ['{parameter}' => $varName, '{route}' => $name, '{expected}' => $token[2], '{given}' => $mergedParams[$varName]])); } diff --git a/vendor/symfony/translation/Loader/XliffFileLoader.php b/vendor/symfony/translation/Loader/XliffFileLoader.php index f573dfe4c..73e35cd50 100644 --- a/vendor/symfony/translation/Loader/XliffFileLoader.php +++ b/vendor/symfony/translation/Loader/XliffFileLoader.php @@ -134,7 +134,7 @@ class XliffFileLoader implements LoaderInterface private function extractXliff2(\DOMDocument $dom, MessageCatalogue $catalogue, string $domain) { $xml = simplexml_import_dom($dom); - $encoding = strtoupper($dom->encoding); + $encoding = $dom->encoding ? strtoupper($dom->encoding) : null; $xml->registerXPathNamespace('xliff', 'urn:oasis:names:tc:xliff:document:2.0'); diff --git a/vendor/symfony/translation/Translator.php b/vendor/symfony/translation/Translator.php index e332e1375..6b11cca68 100644 --- a/vendor/symfony/translation/Translator.php +++ b/vendor/symfony/translation/Translator.php @@ -446,7 +446,7 @@ EOF */ protected function assertValidLocale(string $locale) { - if (1 !== preg_match('/^[a-z0-9@_\\.\\-]*$/i', $locale)) { + if (null !== $locale && 1 !== preg_match('/^[a-z0-9@_\\.\\-]*$/i', $locale)) { throw new InvalidArgumentException(sprintf('Invalid "%s" locale.', $locale)); } } diff --git a/vendor/vlucas/phpdotenv/composer.json b/vendor/vlucas/phpdotenv/composer.json index 3d0ffecc9..d7a1e8c4f 100644 --- a/vendor/vlucas/phpdotenv/composer.json +++ b/vendor/vlucas/phpdotenv/composer.json @@ -16,15 +16,18 @@ } ], "require": { - "php": "^5.5.9 || ^7.0 || ^8.0", - "phpoption/phpoption": "^1.7.3", - "symfony/polyfill-ctype": "^1.17" + "php": "^7.1.3 || ^8.0", + "ext-pcre": "*", + "graham-campbell/result-type": "^1.0.1", + "phpoption/phpoption": "^1.7.4", + "symfony/polyfill-ctype": "^1.17", + "symfony/polyfill-mbstring": "^1.17", + "symfony/polyfill-php80": "^1.17" }, "require-dev": { "ext-filter": "*", - "ext-pcre": "*", "bamarni/composer-bin-plugin": "^1.4.1", - "phpunit/phpunit": "^4.8.36 || ^5.7.27 || ^6.5.14 || ^7.5.20" + "phpunit/phpunit": "^7.5.20 || ^8.5.14 || ^9.5.1" }, "autoload": { "psr-4": { @@ -37,15 +40,14 @@ } }, "suggest": { - "ext-filter": "Required to use the boolean validator.", - "ext-pcre": "Required to use most of the library." + "ext-filter": "Required to use the boolean validator." }, "config": { "preferred-install": "dist" }, "extra": { "branch-alias": { - "dev-master": "4.1-dev" + "dev-master": "5.3-dev" } } } diff --git a/vendor/vlucas/phpdotenv/src/Dotenv.php b/vendor/vlucas/phpdotenv/src/Dotenv.php index 0d207b3ba..0460ced20 100644 --- a/vendor/vlucas/phpdotenv/src/Dotenv.php +++ b/vendor/vlucas/phpdotenv/src/Dotenv.php @@ -1,54 +1,72 @@ store = $store; + $this->parser = $parser; $this->loader = $loader; $this->repository = $repository; - $this->store = is_array($store) ? new FileStore($store, true) : $store; } /** @@ -58,18 +76,27 @@ class Dotenv * @param string|string[] $paths * @param string|string[]|null $names * @param bool $shortCircuit + * @param string|null $fileEncoding * * @return \Dotenv\Dotenv */ - public static function create(RepositoryInterface $repository, $paths, $names = null, $shortCircuit = true) + public static function create(RepositoryInterface $repository, $paths, $names = null, bool $shortCircuit = true, string $fileEncoding = null) { - $builder = StoreBuilder::create()->withPaths($paths)->withNames($names); + $builder = $names === null ? StoreBuilder::createWithDefaultName() : StoreBuilder::createWithNoNames(); + + foreach ((array) $paths as $path) { + $builder = $builder->addPath($path); + } + + foreach ((array) $names as $name) { + $builder = $builder->addName($name); + } if ($shortCircuit) { $builder = $builder->shortCircuit(); } - return new self(new Loader(), $repository, $builder->make()); + return new self($builder->fileEncoding($fileEncoding)->make(), new Parser(), new Loader(), $repository); } /** @@ -78,14 +105,34 @@ class Dotenv * @param string|string[] $paths * @param string|string[]|null $names * @param bool $shortCircuit + * @param string|null $fileEncoding * * @return \Dotenv\Dotenv */ - public static function createMutable($paths, $names = null, $shortCircuit = true) + public static function createMutable($paths, $names = null, bool $shortCircuit = true, string $fileEncoding = null) { - $repository = RepositoryBuilder::create()->make(); + $repository = RepositoryBuilder::createWithDefaultAdapters()->make(); - return self::create($repository, $paths, $names, $shortCircuit); + return self::create($repository, $paths, $names, $shortCircuit, $fileEncoding); + } + + /** + * Create a new mutable dotenv instance with default repository with the putenv adapter. + * + * @param string|string[] $paths + * @param string|string[]|null $names + * @param bool $shortCircuit + * @param string|null $fileEncoding + * + * @return \Dotenv\Dotenv + */ + public static function createUnsafeMutable($paths, $names = null, bool $shortCircuit = true, string $fileEncoding = null) + { + $repository = RepositoryBuilder::createWithDefaultAdapters() + ->addAdapter(PutenvAdapter::class) + ->make(); + + return self::create($repository, $paths, $names, $shortCircuit, $fileEncoding); } /** @@ -94,14 +141,35 @@ class Dotenv * @param string|string[] $paths * @param string|string[]|null $names * @param bool $shortCircuit + * @param string|null $fileEncoding * * @return \Dotenv\Dotenv */ - public static function createImmutable($paths, $names = null, $shortCircuit = true) + public static function createImmutable($paths, $names = null, bool $shortCircuit = true, string $fileEncoding = null) { - $repository = RepositoryBuilder::create()->immutable()->make(); + $repository = RepositoryBuilder::createWithDefaultAdapters()->immutable()->make(); - return self::create($repository, $paths, $names, $shortCircuit); + return self::create($repository, $paths, $names, $shortCircuit, $fileEncoding); + } + + /** + * Create a new immutable dotenv instance with default repository with the putenv adapter. + * + * @param string|string[] $paths + * @param string|string[]|null $names + * @param bool $shortCircuit + * @param string|null $fileEncoding + * + * @return \Dotenv\Dotenv + */ + public static function createUnsafeImmutable($paths, $names = null, bool $shortCircuit = true, string $fileEncoding = null) + { + $repository = RepositoryBuilder::createWithDefaultAdapters() + ->addAdapter(PutenvAdapter::class) + ->immutable() + ->make(); + + return self::create($repository, $paths, $names, $shortCircuit, $fileEncoding); } /** @@ -110,16 +178,15 @@ class Dotenv * @param string|string[] $paths * @param string|string[]|null $names * @param bool $shortCircuit + * @param string|null $fileEncoding * * @return \Dotenv\Dotenv */ - public static function createArrayBacked($paths, $names = null, $shortCircuit = true) + public static function createArrayBacked($paths, $names = null, bool $shortCircuit = true, string $fileEncoding = null) { - $adapter = new ArrayAdapter(); + $repository = RepositoryBuilder::createWithNoAdapters()->addAdapter(ArrayAdapter::class)->make(); - $repository = RepositoryBuilder::create()->withReaders([$adapter])->withWriters([$adapter])->make(); - - return self::create($repository, $paths, $names, $shortCircuit); + return self::create($repository, $paths, $names, $shortCircuit, $fileEncoding); } /** @@ -134,13 +201,11 @@ class Dotenv * * @return array */ - public static function parse($content) + public static function parse(string $content) { - $adapter = new ArrayAdapter(); + $repository = RepositoryBuilder::createWithNoAdapters()->addAdapter(ArrayAdapter::class)->make(); - $repository = RepositoryBuilder::create()->withReaders([$adapter])->withWriters([$adapter])->make(); - - $phpdotenv = new self(new Loader(), $repository, new StringStore($content)); + $phpdotenv = new self(new StringStore($content), new Parser(), new Loader(), $repository); return $phpdotenv->load(); } @@ -148,19 +213,21 @@ class Dotenv /** * Read and load environment file(s). * - * @throws \Dotenv\Exception\InvalidPathException|\Dotenv\Exception\InvalidFileException + * @throws \Dotenv\Exception\InvalidPathException|\Dotenv\Exception\InvalidEncodingException|\Dotenv\Exception\InvalidFileException * * @return array */ public function load() { - return $this->loader->load($this->repository, $this->store->read()); + $entries = $this->parser->parse($this->store->read()); + + return $this->loader->load($this->repository, $entries); } /** * Read and load environment file(s), silently failing if no files can be read. * - * @throws \Dotenv\Exception\InvalidFileException + * @throws \Dotenv\Exception\InvalidEncodingException|\Dotenv\Exception\InvalidFileException * * @return array */ @@ -183,7 +250,7 @@ class Dotenv */ public function required($variables) { - return new Validator($this->repository, (array) $variables); + return (new Validator($this->repository, (array) $variables))->required(); } /** @@ -195,6 +262,6 @@ class Dotenv */ public function ifPresent($variables) { - return new Validator($this->repository, (array) $variables, false); + return new Validator($this->repository, (array) $variables); } } diff --git a/vendor/vlucas/phpdotenv/src/Exception/ExceptionInterface.php b/vendor/vlucas/phpdotenv/src/Exception/ExceptionInterface.php index 3ff0ceffd..1e80f5317 100644 --- a/vendor/vlucas/phpdotenv/src/Exception/ExceptionInterface.php +++ b/vendor/vlucas/phpdotenv/src/Exception/ExceptionInterface.php @@ -1,8 +1,12 @@ whitelist = $whitelist; - } - - /** - * Load the given environment file content into the repository. + * We'll substitute any nested variables, and send each variable to the + * repository, with the effect of actually mutating the environment. * * @param \Dotenv\Repository\RepositoryInterface $repository - * @param string $content - * - * @throws \Dotenv\Exception\InvalidFileException + * @param \Dotenv\Parser\Entry[] $entries * * @return array */ - public function load(RepositoryInterface $repository, $content) + public function load(RepositoryInterface $repository, array $entries) { - return $this->processEntries( - $repository, - Lines::process(Regex::split("/(\r\n|\n|\r)/", $content)->getSuccess()) - ); - } + return \array_reduce($entries, static function (array $vars, Entry $entry) use ($repository) { + $name = $entry->getName(); - /** - * Process the environment variable entries. - * - * We'll fill out any nested variables, and acually set the variable using - * the underlying environment variables instance. - * - * @param \Dotenv\Repository\RepositoryInterface $repository - * @param string[] $entries - * - * @throws \Dotenv\Exception\InvalidFileException - * - * @return array - */ - private function processEntries(RepositoryInterface $repository, array $entries) - { - $vars = []; + $value = $entry->getValue()->map(static function (Value $value) use ($repository) { + return Resolver::resolve($repository, $value); + }); - foreach ($entries as $entry) { - list($name, $value) = Parser::parse($entry); - if ($this->whitelist === null || in_array($name, $this->whitelist, true)) { - $vars[$name] = self::resolveNestedVariables($repository, $value); - $repository->set($name, $vars[$name]); + if ($value->isDefined()) { + $inner = $value->get(); + if ($repository->set($name, $inner)) { + return \array_merge($vars, [$name => $inner]); + } + } else { + if ($repository->clear($name)) { + return \array_merge($vars, [$name => null]); + } } - } - return $vars; - } - - /** - * Resolve the nested variables. - * - * Look for ${varname} patterns in the variable value and replace with an - * existing environment variable. - * - * @param \Dotenv\Repository\RepositoryInterface $repository - * @param \Dotenv\Loader\Value|null $value - * - * @return string|null - */ - private static function resolveNestedVariables(RepositoryInterface $repository, Value $value = null) - { - /** @var Option */ - $option = Option::fromValue($value); - - return $option - ->map(function (Value $v) use ($repository) { - /** @var string */ - return array_reduce($v->getVars(), function ($s, $i) use ($repository) { - return substr($s, 0, $i).self::resolveNestedVariable($repository, substr($s, $i)); - }, $v->getChars()); - }) - ->getOrElse(null); - } - - /** - * Resolve a single nested variable. - * - * @param \Dotenv\Repository\RepositoryInterface $repository - * @param string $str - * - * @return string - */ - private static function resolveNestedVariable(RepositoryInterface $repository, $str) - { - return Regex::replaceCallback( - '/\A\${([a-zA-Z0-9_.]+)}/', - function (array $matches) use ($repository) { - return Option::fromValue($repository->get($matches[1])) - ->getOrElse($matches[0]); - }, - $str, - 1 - )->success()->getOrElse($str); + return $vars; + }, []); } } diff --git a/vendor/vlucas/phpdotenv/src/Loader/LoaderInterface.php b/vendor/vlucas/phpdotenv/src/Loader/LoaderInterface.php index 740e1c5d4..275d98e8d 100644 --- a/vendor/vlucas/phpdotenv/src/Loader/LoaderInterface.php +++ b/vendor/vlucas/phpdotenv/src/Loader/LoaderInterface.php @@ -1,5 +1,7 @@ */ - public function load(RepositoryInterface $repository, $content); + public function load(RepositoryInterface $repository, array $entries); } diff --git a/vendor/vlucas/phpdotenv/src/Loader/Parser.php b/vendor/vlucas/phpdotenv/src/Loader/Parser.php deleted file mode 100644 index 8f66ef898..000000000 --- a/vendor/vlucas/phpdotenv/src/Loader/Parser.php +++ /dev/null @@ -1,249 +0,0 @@ -success()->getOrElse(0) === 1; - } - - /** - * Strips quotes and comments from the environment variable value. - * - * @param string|null $value - * - * @throws \Dotenv\Exception\InvalidFileException - * - * @return \Dotenv\Loader\Value|null - */ - private static function parseValue($value) - { - if ($value === null) { - return null; - } - - if (trim($value) === '') { - return Value::blank(); - } - - $result = array_reduce(str_split($value), function ($data, $char) use ($value) { - return self::processChar($data[1], $char)->mapError(function ($err) use ($value) { - throw new InvalidFileException( - self::getErrorMessage($err, $value) - ); - })->mapSuccess(function ($val) use ($data) { - return [$data[0]->append($val[0], $val[1]), $val[2]]; - })->getSuccess(); - }, [Value::blank(), self::INITIAL_STATE]); - - if (in_array($result[1], [self::SINGLE_QUOTED_STATE, self::DOUBLE_QUOTED_STATE, self::ESCAPE_SEQUENCE_STATE], true)) { - throw new InvalidFileException( - self::getErrorMessage('a missing closing quote', $value) - ); - } - - return $result[0]; - } - - /** - * Process the given character. - * - * @param int $state - * @param string $char - * - * @return \Dotenv\Result\Result - */ - private static function processChar($state, $char) - { - switch ($state) { - case self::INITIAL_STATE: - if ($char === '\'') { - /** @var \Dotenv\Result\Result */ - return Success::create(['', false, self::SINGLE_QUOTED_STATE]); - } elseif ($char === '"') { - /** @var \Dotenv\Result\Result */ - return Success::create(['', false, self::DOUBLE_QUOTED_STATE]); - } elseif ($char === '#') { - /** @var \Dotenv\Result\Result */ - return Success::create(['', false, self::COMMENT_STATE]); - } elseif ($char === '$') { - /** @var \Dotenv\Result\Result */ - return Success::create([$char, true, self::UNQUOTED_STATE]); - } else { - /** @var \Dotenv\Result\Result */ - return Success::create([$char, false, self::UNQUOTED_STATE]); - } - case self::UNQUOTED_STATE: - if ($char === '#') { - /** @var \Dotenv\Result\Result */ - return Success::create(['', false, self::COMMENT_STATE]); - } elseif (ctype_space($char)) { - /** @var \Dotenv\Result\Result */ - return Success::create(['', false, self::WHITESPACE_STATE]); - } elseif ($char === '$') { - /** @var \Dotenv\Result\Result */ - return Success::create([$char, true, self::UNQUOTED_STATE]); - } else { - /** @var \Dotenv\Result\Result */ - return Success::create([$char, false, self::UNQUOTED_STATE]); - } - case self::SINGLE_QUOTED_STATE: - if ($char === '\'') { - /** @var \Dotenv\Result\Result */ - return Success::create(['', false, self::WHITESPACE_STATE]); - } else { - /** @var \Dotenv\Result\Result */ - return Success::create([$char, false, self::SINGLE_QUOTED_STATE]); - } - case self::DOUBLE_QUOTED_STATE: - if ($char === '"') { - /** @var \Dotenv\Result\Result */ - return Success::create(['', false, self::WHITESPACE_STATE]); - } elseif ($char === '\\') { - /** @var \Dotenv\Result\Result */ - return Success::create(['', false, self::ESCAPE_SEQUENCE_STATE]); - } elseif ($char === '$') { - /** @var \Dotenv\Result\Result */ - return Success::create([$char, true, self::DOUBLE_QUOTED_STATE]); - } else { - /** @var \Dotenv\Result\Result */ - return Success::create([$char, false, self::DOUBLE_QUOTED_STATE]); - } - case self::ESCAPE_SEQUENCE_STATE: - if ($char === '"' || $char === '\\') { - /** @var \Dotenv\Result\Result */ - return Success::create([$char, false, self::DOUBLE_QUOTED_STATE]); - } elseif ($char === '$') { - /** @var \Dotenv\Result\Result */ - return Success::create([$char, false, self::DOUBLE_QUOTED_STATE]); - } elseif (in_array($char, ['f', 'n', 'r', 't', 'v'], true)) { - /** @var \Dotenv\Result\Result */ - return Success::create([stripcslashes('\\'.$char), false, self::DOUBLE_QUOTED_STATE]); - } else { - /** @var \Dotenv\Result\Result */ - return Error::create('an unexpected escape sequence'); - } - case self::WHITESPACE_STATE: - if ($char === '#') { - /** @var \Dotenv\Result\Result */ - return Success::create(['', false, self::COMMENT_STATE]); - } elseif (!ctype_space($char)) { - /** @var \Dotenv\Result\Result */ - return Error::create('unexpected whitespace'); - } else { - /** @var \Dotenv\Result\Result */ - return Success::create(['', false, self::WHITESPACE_STATE]); - } - case self::COMMENT_STATE: - /** @var \Dotenv\Result\Result */ - return Success::create(['', false, self::COMMENT_STATE]); - default: - throw new RuntimeException('Parser entered invalid state.'); - } - } - - /** - * Generate a friendly error message. - * - * @param string $cause - * @param string $subject - * - * @return string - */ - private static function getErrorMessage($cause, $subject) - { - return sprintf( - 'Failed to parse dotenv file due to %s. Failed at [%s].', - $cause, - strtok($subject, "\n") - ); - } -} diff --git a/vendor/vlucas/phpdotenv/src/Loader/Resolver.php b/vendor/vlucas/phpdotenv/src/Loader/Resolver.php new file mode 100644 index 000000000..36d7a4b9c --- /dev/null +++ b/vendor/vlucas/phpdotenv/src/Loader/Resolver.php @@ -0,0 +1,65 @@ +getVars(), static function (string $s, int $i) use ($repository) { + return Str::substr($s, 0, $i).self::resolveVariable($repository, Str::substr($s, $i)); + }, $value->getChars()); + } + + /** + * Resolve a single nested variable. + * + * @param \Dotenv\Repository\RepositoryInterface $repository + * @param string $str + * + * @return string + */ + private static function resolveVariable(RepositoryInterface $repository, string $str) + { + return Regex::replaceCallback( + '/\A\${([a-zA-Z0-9_.]+)}/', + static function (array $matches) use ($repository) { + return Option::fromValue($repository->get($matches[1])) + ->getOrElse($matches[0]); + }, + $str, + 1 + )->success()->getOrElse($str); + } +} diff --git a/vendor/vlucas/phpdotenv/src/Parser/Entry.php b/vendor/vlucas/phpdotenv/src/Parser/Entry.php new file mode 100644 index 000000000..7570f5874 --- /dev/null +++ b/vendor/vlucas/phpdotenv/src/Parser/Entry.php @@ -0,0 +1,59 @@ +name = $name; + $this->value = $value; + } + + /** + * Get the entry name. + * + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Get the entry value. + * + * @return \PhpOption\Option<\Dotenv\Parser\Value> + */ + public function getValue() + { + /** @var \PhpOption\Option<\Dotenv\Parser\Value> */ + return Option::fromValue($this->value); + } +} diff --git a/vendor/vlucas/phpdotenv/src/Parser/EntryParser.php b/vendor/vlucas/phpdotenv/src/Parser/EntryParser.php new file mode 100644 index 000000000..5cfa3eef6 --- /dev/null +++ b/vendor/vlucas/phpdotenv/src/Parser/EntryParser.php @@ -0,0 +1,293 @@ + + */ + public static function parse(string $entry) + { + return self::splitStringIntoParts($entry)->flatMap(static function (array $parts) { + [$name, $value] = $parts; + + return self::parseName($name)->flatMap(static function (string $name) use ($value) { + /** @var Result */ + $parsedValue = $value === null ? Success::create(null) : self::parseValue($value); + + return $parsedValue->map(static function (?Value $value) use ($name) { + return new Entry($name, $value); + }); + }); + }); + } + + /** + * Split the compound string into parts. + * + * @param string $line + * + * @return \GrahamCampbell\ResultType\Result + */ + private static function splitStringIntoParts(string $line) + { + /** @var array{string,string|null} */ + $result = Str::pos($line, '=')->map(static function () use ($line) { + return \array_map('trim', \explode('=', $line, 2)); + })->getOrElse([$line, null]); + + if ($result[0] === '') { + return Error::create(self::getErrorMessage('an unexpected equals', $line)); + } + + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create($result); + } + + /** + * Parse the given variable name. + * + * That is, strip the optional quotes and leading "export" from the + * variable name. We wrap the answer in a result type. + * + * @param string $name + * + * @return \GrahamCampbell\ResultType\Result + */ + private static function parseName(string $name) + { + if (Str::len($name) > 8 && Str::substr($name, 0, 6) === 'export' && \ctype_space(Str::substr($name, 6, 1))) { + $name = \ltrim(Str::substr($name, 6)); + } + + if (self::isQuotedName($name)) { + $name = Str::substr($name, 1, -1); + } + + if (!self::isValidName($name)) { + return Error::create(self::getErrorMessage('an invalid name', $name)); + } + + return Success::create($name); + } + + /** + * Is the given variable name quoted? + * + * @param string $name + * + * @return bool + */ + private static function isQuotedName(string $name) + { + if (Str::len($name) < 3) { + return false; + } + + $first = Str::substr($name, 0, 1); + $last = Str::substr($name, -1, 1); + + return ($first === '"' && $last === '"') || ($first === '\'' && $last === '\''); + } + + /** + * Is the given variable name valid? + * + * @param string $name + * + * @return bool + */ + private static function isValidName(string $name) + { + return Regex::matches('~\A[a-zA-Z0-9_.]+\z~', $name)->success()->getOrElse(false); + } + + /** + * Parse the given variable value. + * + * This has the effect of stripping quotes and comments, dealing with + * special characters, and locating nested variables, but not resolving + * them. Formally, we run a finite state automaton with an output tape: a + * transducer. We wrap the answer in a result type. + * + * @param string $value + * + * @return \GrahamCampbell\ResultType\Result<\Dotenv\Parser\Value,string> + */ + private static function parseValue(string $value) + { + if (\trim($value) === '') { + return Success::create(Value::blank()); + } + + return \array_reduce(\iterator_to_array(Lexer::lex($value)), static function (Result $data, string $token) { + return $data->flatMap(static function (array $data) use ($token) { + return self::processToken($data[1], $token)->map(static function (array $val) use ($data) { + return [$data[0]->append($val[0], $val[1]), $val[2]]; + }); + }); + }, Success::create([Value::blank(), self::INITIAL_STATE]))->flatMap(static function (array $result) { + if (in_array($result[1], self::REJECT_STATES, true)) { + return Error::create('a missing closing quote'); + } + + return Success::create($result[0]); + })->mapError(static function (string $err) use ($value) { + return self::getErrorMessage($err, $value); + }); + } + + /** + * Process the given token. + * + * @param int $state + * @param string $token + * + * @return \GrahamCampbell\ResultType\Result + */ + private static function processToken(int $state, string $token) + { + switch ($state) { + case self::INITIAL_STATE: + if ($token === '\'') { + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create(['', false, self::SINGLE_QUOTED_STATE]); + } elseif ($token === '"') { + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create(['', false, self::DOUBLE_QUOTED_STATE]); + } elseif ($token === '#') { + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create(['', false, self::COMMENT_STATE]); + } elseif ($token === '$') { + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create([$token, true, self::UNQUOTED_STATE]); + } else { + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create([$token, false, self::UNQUOTED_STATE]); + } + case self::UNQUOTED_STATE: + if ($token === '#') { + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create(['', false, self::COMMENT_STATE]); + } elseif (\ctype_space($token)) { + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create(['', false, self::WHITESPACE_STATE]); + } elseif ($token === '$') { + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create([$token, true, self::UNQUOTED_STATE]); + } else { + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create([$token, false, self::UNQUOTED_STATE]); + } + case self::SINGLE_QUOTED_STATE: + if ($token === '\'') { + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create(['', false, self::WHITESPACE_STATE]); + } else { + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create([$token, false, self::SINGLE_QUOTED_STATE]); + } + case self::DOUBLE_QUOTED_STATE: + if ($token === '"') { + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create(['', false, self::WHITESPACE_STATE]); + } elseif ($token === '\\') { + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create(['', false, self::ESCAPE_SEQUENCE_STATE]); + } elseif ($token === '$') { + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create([$token, true, self::DOUBLE_QUOTED_STATE]); + } else { + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create([$token, false, self::DOUBLE_QUOTED_STATE]); + } + case self::ESCAPE_SEQUENCE_STATE: + if ($token === '"' || $token === '\\') { + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create([$token, false, self::DOUBLE_QUOTED_STATE]); + } elseif ($token === '$') { + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create([$token, false, self::DOUBLE_QUOTED_STATE]); + } else { + $first = Str::substr($token, 0, 1); + if (\in_array($first, ['f', 'n', 'r', 't', 'v'], true)) { + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create([\stripcslashes('\\'.$first).Str::substr($token, 1), false, self::DOUBLE_QUOTED_STATE]); + } else { + /** @var \GrahamCampbell\ResultType\Result */ + return Error::create('an unexpected escape sequence'); + } + } + case self::WHITESPACE_STATE: + if ($token === '#') { + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create(['', false, self::COMMENT_STATE]); + } elseif (!\ctype_space($token)) { + /** @var \GrahamCampbell\ResultType\Result */ + return Error::create('unexpected whitespace'); + } else { + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create(['', false, self::WHITESPACE_STATE]); + } + case self::COMMENT_STATE: + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create(['', false, self::COMMENT_STATE]); + default: + throw new \Error('Parser entered invalid state.'); + } + } + + /** + * Generate a friendly error message. + * + * @param string $cause + * @param string $subject + * + * @return string + */ + private static function getErrorMessage(string $cause, string $subject) + { + return \sprintf( + 'Encountered %s at [%s].', + $cause, + \strtok($subject, "\n") + ); + } +} diff --git a/vendor/vlucas/phpdotenv/src/Parser/Lexer.php b/vendor/vlucas/phpdotenv/src/Parser/Lexer.php new file mode 100644 index 000000000..c5eb64d3a --- /dev/null +++ b/vendor/vlucas/phpdotenv/src/Parser/Lexer.php @@ -0,0 +1,62 @@ + + */ + public static function lex(string $content) + { + static $regex; + + if ($regex === null) { + $regex = '(('.\implode(')|(', self::PATTERNS).'))A'; + } + + $tokens = []; + + $offset = 0; + + while (isset($content[$offset])) { + if (!\preg_match($regex, $content, $matches, 0, $offset)) { + throw new \Error(\sprintf('Lexer encountered unexpected character [%s].', $content[$offset])); + } + + $offset += \strlen($matches[0]); + + yield $matches[0]; + } + } +} diff --git a/vendor/vlucas/phpdotenv/src/Loader/Lines.php b/vendor/vlucas/phpdotenv/src/Parser/Lines.php similarity index 54% rename from vendor/vlucas/phpdotenv/src/Loader/Lines.php rename to vendor/vlucas/phpdotenv/src/Parser/Lines.php index 89d9c34be..383979471 100644 --- a/vendor/vlucas/phpdotenv/src/Loader/Lines.php +++ b/vendor/vlucas/phpdotenv/src/Parser/Lines.php @@ -1,13 +1,30 @@ map(static function () use ($line) { + return self::looksLikeMultilineStop($line, true) === false; + })->getOrElse(false); } /** @@ -83,36 +98,15 @@ class Lines * * @return bool */ - private static function looksLikeMultilineStop($line, $started) + private static function looksLikeMultilineStop(string $line, bool $started) { if ($line === '"') { return true; } - $seen = $started ? 0 : 1; - - foreach (self::getCharPairs(str_replace('\\\\', '', $line)) as $pair) { - if ($pair[0] !== '\\' && $pair[1] === '"') { - $seen++; - } - } - - return $seen > 1; - } - - /** - * Get all pairs of adjacent characters within the line. - * - * @param string $line - * - * @return array{array{string,string|null}} - */ - private static function getCharPairs($line) - { - $chars = str_split($line); - - /** @var array{array{string,string|null}} */ - return array_map(null, $chars, array_slice($chars, 1)); + return Regex::occurences('/(?=([^\\\\]"))/', \str_replace('\\\\', '', $line))->map(static function (int $count) use ($started) { + return $started ? $count > 1 : $count >= 1; + })->success()->getOrElse(false); } /** @@ -122,14 +116,10 @@ class Lines * * @return bool */ - private static function isCommentOrWhitespace($line) + private static function isCommentOrWhitespace(string $line) { - if (trim($line) === '') { - return true; - } + $line = \trim($line); - $line = ltrim($line); - - return isset($line[0]) && $line[0] === '#'; + return $line === '' || (isset($line[0]) && $line[0] === '#'); } } diff --git a/vendor/vlucas/phpdotenv/src/Parser/Parser.php b/vendor/vlucas/phpdotenv/src/Parser/Parser.php new file mode 100644 index 000000000..3c115e55b --- /dev/null +++ b/vendor/vlucas/phpdotenv/src/Parser/Parser.php @@ -0,0 +1,52 @@ +mapError(static function () { + return 'Could not split into separate lines.'; + })->flatMap(static function (array $lines) { + return self::process(Lines::process($lines)); + })->mapError(static function (string $error) { + throw new InvalidFileException(\sprintf('Failed to parse dotenv file. %s', $error)); + })->success()->get(); + } + + /** + * Convert the raw entries into proper entries. + * + * @param string[] $entries + * + * @return \GrahamCampbell\ResultType\Result<\Dotenv\Parser\Entry[],string> + */ + private static function process(array $entries) + { + /** @var \GrahamCampbell\ResultType\Result<\Dotenv\Parser\Entry[],string> */ + return \array_reduce($entries, static function (Result $result, string $raw) { + return $result->flatMap(static function (array $entries) use ($raw) { + return EntryParser::parse($raw)->map(static function (Entry $entry) use ($entries) { + return \array_merge($entries, [$entry]); + }); + }); + }, Success::create([])); + } +} diff --git a/vendor/vlucas/phpdotenv/src/Parser/ParserInterface.php b/vendor/vlucas/phpdotenv/src/Parser/ParserInterface.php new file mode 100644 index 000000000..17cc42adf --- /dev/null +++ b/vendor/vlucas/phpdotenv/src/Parser/ParserInterface.php @@ -0,0 +1,19 @@ +chars = $chars; $this->vars = $vars; @@ -35,7 +39,7 @@ class Value /** * Create an empty value instance. * - * @return \Dotenv\Loader\Value + * @return \Dotenv\Parser\Value */ public static function blank() { @@ -43,18 +47,18 @@ class Value } /** - * Create a new value instance, appending the character. + * Create a new value instance, appending the characters. * - * @param string $char + * @param string $chars * @param bool $var * - * @return \Dotenv\Loader\Value + * @return \Dotenv\Parser\Value */ - public function append($char, $var) + public function append(string $chars, bool $var) { return new self( - $this->chars.$char, - $var ? array_merge($this->vars, [strlen($this->chars)]) : $this->vars + $this->chars.$chars, + $var ? \array_merge($this->vars, [Str::len($this->chars)]) : $this->vars ); } @@ -76,7 +80,8 @@ class Value public function getVars() { $vars = $this->vars; - rsort($vars); + + \rsort($vars); return $vars; } diff --git a/vendor/vlucas/phpdotenv/src/Regex/Regex.php b/vendor/vlucas/phpdotenv/src/Regex/Regex.php deleted file mode 100644 index 2b322ab02..000000000 --- a/vendor/vlucas/phpdotenv/src/Regex/Regex.php +++ /dev/null @@ -1,125 +0,0 @@ - - */ - public static function match($pattern, $subject) - { - return self::pregAndWrap(function ($subject) use ($pattern) { - return (int) @preg_match($pattern, $subject); - }, $subject); - } - - /** - * Perform a preg replace, wrapping up the result. - * - * @param string $pattern - * @param string $replacement - * @param string $subject - * @param int|null $limit - * - * @return \Dotenv\Result\Result - */ - public static function replace($pattern, $replacement, $subject, $limit = null) - { - return self::pregAndWrap(function ($subject) use ($pattern, $replacement, $limit) { - return (string) @preg_replace($pattern, $replacement, $subject, $limit === null ? -1 : $limit); - }, $subject); - } - - /** - * Perform a preg replace callback, wrapping up the result. - * - * @param string $pattern - * @param callable $callback - * @param string $subject - * @param int|null $limit - * - * @return \Dotenv\Result\Result - */ - public static function replaceCallback($pattern, callable $callback, $subject, $limit = null) - { - return self::pregAndWrap(function ($subject) use ($pattern, $callback, $limit) { - return (string) @preg_replace_callback($pattern, $callback, $subject, $limit === null ? -1 : $limit); - }, $subject); - } - - /** - * Perform a preg split, wrapping up the result. - * - * @param string $pattern - * @param string $subject - * - * @return \Dotenv\Result\Result - */ - public static function split($pattern, $subject) - { - return self::pregAndWrap(function ($subject) use ($pattern) { - /** @var string[] */ - return (array) @preg_split($pattern, $subject); - }, $subject); - } - - /** - * Perform a preg operation, wrapping up the result. - * - * @template V - * - * @param callable(string):V $operation - * @param string $subject - * - * @return \Dotenv\Result\Result - */ - private static function pregAndWrap(callable $operation, $subject) - { - $result = $operation($subject); - - if (($e = preg_last_error()) !== PREG_NO_ERROR) { - return Error::create(self::lookupError($e)); - } - - return Success::create($result); - } - - /** - * Lookup the preg error code. - * - * @param int $code - * - * @return string - */ - private static function lookupError($code) - { - if (defined('PREG_JIT_STACKLIMIT_ERROR') && $code === PREG_JIT_STACKLIMIT_ERROR) { - return 'JIT stack limit exhausted'; - } - - switch ($code) { - case PREG_INTERNAL_ERROR: - return 'Internal error'; - case PREG_BAD_UTF8_ERROR: - return 'Malformed UTF-8 characters, possibly incorrectly encoded'; - case PREG_BAD_UTF8_OFFSET_ERROR: - return 'The offset did not correspond to the beginning of a valid UTF-8 code point'; - case PREG_BACKTRACK_LIMIT_ERROR: - return 'Backtrack limit exhausted'; - case PREG_RECURSION_LIMIT_ERROR: - return 'Recursion limit exhausted'; - default: - return 'Unknown error'; - } - } -} diff --git a/vendor/vlucas/phpdotenv/src/Repository/AbstractRepository.php b/vendor/vlucas/phpdotenv/src/Repository/AbstractRepository.php deleted file mode 100644 index 247f9507e..000000000 --- a/vendor/vlucas/phpdotenv/src/Repository/AbstractRepository.php +++ /dev/null @@ -1,175 +0,0 @@ -immutable = $immutable; - $this->loaded = new ArrayAdapter(); - } - - /** - * Get an environment variable. - * - * @param string $name - * - * @throws \InvalidArgumentException - * - * @return string|null - */ - public function get($name) - { - if (!is_string($name)) { - throw new InvalidArgumentException('Expected name to be a string.'); - } - - return $this->getInternal($name); - } - - /** - * Get an environment variable. - * - * @param string $name - * - * @return string|null - */ - abstract protected function getInternal($name); - - /** - * Set an environment variable. - * - * @param string $name - * @param string|null $value - * - * @throws \InvalidArgumentException - * - * @return void - */ - public function set($name, $value = null) - { - if (!is_string($name)) { - throw new InvalidArgumentException('Expected name to be a string.'); - } - - // Don't overwrite existing environment variables if we're immutable - // Ruby's dotenv does this with `ENV[key] ||= value`. - if ($this->immutable && $this->get($name) !== null && $this->loaded->get($name)->isEmpty()) { - return; - } - - $this->setInternal($name, $value); - $this->loaded->set($name, ''); - } - - /** - * Set an environment variable. - * - * @param string $name - * @param string|null $value - * - * @return void - */ - abstract protected function setInternal($name, $value = null); - - /** - * Clear an environment variable. - * - * @param string $name - * - * @throws \InvalidArgumentException - * - * @return void - */ - public function clear($name) - { - if (!is_string($name)) { - throw new InvalidArgumentException('Expected name to be a string.'); - } - - // Don't clear anything if we're immutable. - if ($this->immutable) { - return; - } - - $this->clearInternal($name); - } - - /** - * Clear an environment variable. - * - * @param string $name - * - * @return void - */ - abstract protected function clearInternal($name); - - /** - * Tells whether environment variable has been defined. - * - * @param string $name - * - * @return bool - */ - public function has($name) - { - return is_string($name) && $this->get($name) !== null; - } - - /** - * {@inheritdoc} - */ - public function offsetExists($offset) - { - return $this->has($offset); - } - - /** - * {@inheritdoc} - */ - public function offsetGet($offset) - { - return $this->get($offset); - } - - /** - * {@inheritdoc} - */ - public function offsetSet($offset, $value) - { - $this->set($offset, $value); - } - - /** - * {@inheritdoc} - */ - public function offsetUnset($offset) - { - $this->clear($offset); - } -} diff --git a/vendor/vlucas/phpdotenv/src/Repository/Adapter/AdapterInterface.php b/vendor/vlucas/phpdotenv/src/Repository/Adapter/AdapterInterface.php new file mode 100644 index 000000000..5604398a5 --- /dev/null +++ b/vendor/vlucas/phpdotenv/src/Repository/Adapter/AdapterInterface.php @@ -0,0 +1,15 @@ + + */ + public static function create(); +} diff --git a/vendor/vlucas/phpdotenv/src/Repository/Adapter/ApacheAdapter.php b/vendor/vlucas/phpdotenv/src/Repository/Adapter/ApacheAdapter.php index 73ce87d12..868033af7 100644 --- a/vendor/vlucas/phpdotenv/src/Repository/Adapter/ApacheAdapter.php +++ b/vendor/vlucas/phpdotenv/src/Repository/Adapter/ApacheAdapter.php @@ -1,11 +1,40 @@ + */ + public static function create() + { + if (self::isSupported()) { + /** @var \PhpOption\Option */ + return Some::create(new self()); + } + + return None::create(); + } + /** * Determines if the adapter is supported. * @@ -13,52 +42,48 @@ class ApacheAdapter implements AvailabilityInterface, ReaderInterface, WriterInt * * @return bool */ - public function isSupported() + private static function isSupported() { - return function_exists('apache_getenv') && function_exists('apache_setenv'); + return \function_exists('apache_getenv') && \function_exists('apache_setenv'); } /** - * Get an environment variable, if it exists. - * - * This is intentionally not implemented, since this adapter exists only as - * a means to overwrite existing apache environment variables. + * Read an environment variable, if it exists. * * @param string $name * - * @return \PhpOption\Option + * @return \PhpOption\Option */ - public function get($name) + public function read(string $name) { - return None::create(); + /** @var \PhpOption\Option */ + return Option::fromValue(apache_getenv($name))->filter(static function ($value) { + return \is_string($value) && $value !== ''; + }); } /** - * Set an environment variable. + * Write to an environment variable, if possible. * - * Only if an existing apache variable exists do we overwrite it. + * @param string $name + * @param string $value * - * @param string $name - * @param string|null $value - * - * @return void + * @return bool */ - public function set($name, $value = null) + public function write(string $name, string $value) { - if (apache_getenv($name) !== false) { - apache_setenv($name, (string) $value); - } + return apache_setenv($name, $value); } /** - * Clear an environment variable. + * Delete an environment variable, if possible. * * @param string $name * - * @return void + * @return bool */ - public function clear($name) + public function delete(string $name) { - // Nothing to do here. + return apache_setenv($name, ''); } } diff --git a/vendor/vlucas/phpdotenv/src/Repository/Adapter/ArrayAdapter.php b/vendor/vlucas/phpdotenv/src/Repository/Adapter/ArrayAdapter.php index dc234aa63..2881a7e19 100644 --- a/vendor/vlucas/phpdotenv/src/Repository/Adapter/ArrayAdapter.php +++ b/vendor/vlucas/phpdotenv/src/Repository/Adapter/ArrayAdapter.php @@ -1,67 +1,80 @@ + * @var array */ - private $variables = []; + private $variables; /** - * Determines if the adapter is supported. + * Create a new array adapter instance. + * + * @return void + */ + private function __construct() + { + $this->variables = []; + } + + /** + * Create a new instance of the adapter, if it is available. + * + * @return \PhpOption\Option<\Dotenv\Repository\Adapter\AdapterInterface> + */ + public static function create() + { + /** @var \PhpOption\Option */ + return Some::create(new self()); + } + + /** + * Read an environment variable, if it exists. + * + * @param string $name + * + * @return \PhpOption\Option + */ + public function read(string $name) + { + return Option::fromArraysValue($this->variables, $name); + } + + /** + * Write to an environment variable, if possible. + * + * @param string $name + * @param string $value * * @return bool */ - public function isSupported() + public function write(string $name, string $value) { + $this->variables[$name] = $value; + return true; } /** - * Get an environment variable, if it exists. + * Delete an environment variable, if possible. * * @param string $name * - * @return \PhpOption\Option + * @return bool */ - public function get($name) - { - if (array_key_exists($name, $this->variables)) { - return Some::create($this->variables[$name]); - } - - return None::create(); - } - - /** - * Set an environment variable. - * - * @param string $name - * @param string|null $value - * - * @return void - */ - public function set($name, $value = null) - { - $this->variables[$name] = $value; - } - - /** - * Clear an environment variable. - * - * @param string $name - * - * @return void - */ - public function clear($name) + public function delete(string $name) { unset($this->variables[$name]); + + return true; } } diff --git a/vendor/vlucas/phpdotenv/src/Repository/Adapter/AvailabilityInterface.php b/vendor/vlucas/phpdotenv/src/Repository/Adapter/AvailabilityInterface.php deleted file mode 100644 index b03537217..000000000 --- a/vendor/vlucas/phpdotenv/src/Repository/Adapter/AvailabilityInterface.php +++ /dev/null @@ -1,13 +0,0 @@ - + */ + public static function create() + { + /** @var \PhpOption\Option */ + return Some::create(new self()); + } + + /** + * Read an environment variable, if it exists. + * + * @param string $name + * + * @return \PhpOption\Option + */ + public function read(string $name) + { + /** @var \PhpOption\Option */ + return Option::fromArraysValue($_ENV, $name) + ->map(static function ($value) { + if ($value === false) { + return 'false'; + } + + if ($value === true) { + return 'true'; + } + + return $value; + })->filter(static function ($value) { + return \is_string($value); + }); + } + + /** + * Write to an environment variable, if possible. + * + * @param string $name + * @param string $value * * @return bool */ - public function isSupported() + public function write(string $name, string $value) { + $_ENV[$name] = $value; + return true; } /** - * Get an environment variable, if it exists. + * Delete an environment variable, if possible. * * @param string $name * - * @return \PhpOption\Option + * @return bool */ - public function get($name) - { - if (array_key_exists($name, $_ENV)) { - return Some::create($_ENV[$name]); - } - - return None::create(); - } - - /** - * Set an environment variable. - * - * @param string $name - * @param string|null $value - * - * @return void - */ - public function set($name, $value = null) - { - $_ENV[$name] = $value; - } - - /** - * Clear an environment variable. - * - * @param string $name - * - * @return void - */ - public function clear($name) + public function delete(string $name) { unset($_ENV[$name]); + + return true; } } diff --git a/vendor/vlucas/phpdotenv/src/Repository/Adapter/GuardedWriter.php b/vendor/vlucas/phpdotenv/src/Repository/Adapter/GuardedWriter.php new file mode 100644 index 000000000..7bb69e825 --- /dev/null +++ b/vendor/vlucas/phpdotenv/src/Repository/Adapter/GuardedWriter.php @@ -0,0 +1,85 @@ +writer = $writer; + $this->allowList = $allowList; + } + + /** + * Write to an environment variable, if possible. + * + * @param string $name + * @param string $value + * + * @return bool + */ + public function write(string $name, string $value) + { + // Don't set non-allowed variables + if (!$this->isAllowed($name)) { + return false; + } + + // Set the value on the inner writer + return $this->writer->write($name, $value); + } + + /** + * Delete an environment variable, if possible. + * + * @param string $name + * + * @return bool + */ + public function delete(string $name) + { + // Don't clear non-allowed variables + if (!$this->isAllowed($name)) { + return false; + } + + // Set the value on the inner writer + return $this->writer->delete($name); + } + + /** + * Determine if the given variable is allowed. + * + * @param string $name + * + * @return bool + */ + private function isAllowed(string $name) + { + return \in_array($name, $this->allowList, true); + } +} diff --git a/vendor/vlucas/phpdotenv/src/Repository/Adapter/ImmutableWriter.php b/vendor/vlucas/phpdotenv/src/Repository/Adapter/ImmutableWriter.php new file mode 100644 index 000000000..574fcd690 --- /dev/null +++ b/vendor/vlucas/phpdotenv/src/Repository/Adapter/ImmutableWriter.php @@ -0,0 +1,110 @@ + + */ + private $loaded; + + /** + * Create a new immutable writer instance. + * + * @param \Dotenv\Repository\Adapter\WriterInterface $writer + * @param \Dotenv\Repository\Adapter\ReaderInterface $reader + * + * @return void + */ + public function __construct(WriterInterface $writer, ReaderInterface $reader) + { + $this->writer = $writer; + $this->reader = $reader; + $this->loaded = []; + } + + /** + * Write to an environment variable, if possible. + * + * @param string $name + * @param string $value + * + * @return bool + */ + public function write(string $name, string $value) + { + // Don't overwrite existing environment variables + // Ruby's dotenv does this with `ENV[key] ||= value` + if ($this->isExternallyDefined($name)) { + return false; + } + + // Set the value on the inner writer + if (!$this->writer->write($name, $value)) { + return false; + } + + // Record that we have loaded the variable + $this->loaded[$name] = ''; + + return true; + } + + /** + * Delete an environment variable, if possible. + * + * @param string $name + * + * @return bool + */ + public function delete(string $name) + { + // Don't clear existing environment variables + if ($this->isExternallyDefined($name)) { + return false; + } + + // Clear the value on the inner writer + if (!$this->writer->delete($name)) { + return false; + } + + // Leave the variable as fair game + unset($this->loaded[$name]); + + return true; + } + + /** + * Determine if the given variable is externally defined. + * + * That is, is it an "existing" variable. + * + * @param string $name + * + * @return bool + */ + private function isExternallyDefined(string $name) + { + return $this->reader->read($name)->isDefined() && !isset($this->loaded[$name]); + } +} diff --git a/vendor/vlucas/phpdotenv/src/Repository/Adapter/MultiReader.php b/vendor/vlucas/phpdotenv/src/Repository/Adapter/MultiReader.php new file mode 100644 index 000000000..12b3bda4b --- /dev/null +++ b/vendor/vlucas/phpdotenv/src/Repository/Adapter/MultiReader.php @@ -0,0 +1,48 @@ +readers = $readers; + } + + /** + * Read an environment variable, if it exists. + * + * @param string $name + * + * @return \PhpOption\Option + */ + public function read(string $name) + { + foreach ($this->readers as $reader) { + $result = $reader->read($name); + if ($result->isDefined()) { + return $result; + } + } + + return None::create(); + } +} diff --git a/vendor/vlucas/phpdotenv/src/Repository/Adapter/MultiWriter.php b/vendor/vlucas/phpdotenv/src/Repository/Adapter/MultiWriter.php new file mode 100644 index 000000000..e1dcf56b3 --- /dev/null +++ b/vendor/vlucas/phpdotenv/src/Repository/Adapter/MultiWriter.php @@ -0,0 +1,64 @@ +writers = $writers; + } + + /** + * Write to an environment variable, if possible. + * + * @param string $name + * @param string $value + * + * @return bool + */ + public function write(string $name, string $value) + { + foreach ($this->writers as $writers) { + if (!$writers->write($name, $value)) { + return false; + } + } + + return true; + } + + /** + * Delete an environment variable, if possible. + * + * @param string $name + * + * @return bool + */ + public function delete(string $name) + { + foreach ($this->writers as $writers) { + if (!$writers->delete($name)) { + return false; + } + } + + return true; + } +} diff --git a/vendor/vlucas/phpdotenv/src/Repository/Adapter/PutenvAdapter.php b/vendor/vlucas/phpdotenv/src/Repository/Adapter/PutenvAdapter.php index 766afd3b3..126c46564 100644 --- a/vendor/vlucas/phpdotenv/src/Repository/Adapter/PutenvAdapter.php +++ b/vendor/vlucas/phpdotenv/src/Repository/Adapter/PutenvAdapter.php @@ -1,56 +1,91 @@ + */ + public static function create() + { + if (self::isSupported()) { + /** @var \PhpOption\Option */ + return Some::create(new self()); + } + + return None::create(); + } + /** * Determines if the adapter is supported. * * @return bool */ - public function isSupported() + private static function isSupported() { - return function_exists('getenv') && function_exists('putenv'); + return \function_exists('getenv') && \function_exists('putenv'); } /** - * Get an environment variable, if it exists. + * Read an environment variable, if it exists. * * @param string $name * - * @return \PhpOption\Option + * @return \PhpOption\Option */ - public function get($name) + public function read(string $name) { - /** @var \PhpOption\Option */ - return Option::fromValue(getenv($name), false); + /** @var \PhpOption\Option */ + return Option::fromValue(\getenv($name), false)->filter(static function ($value) { + return \is_string($value); + }); } /** - * Set an environment variable. + * Write to an environment variable, if possible. * - * @param string $name - * @param string|null $value + * @param string $name + * @param string $value * - * @return void + * @return bool */ - public function set($name, $value = null) + public function write(string $name, string $value) { - putenv("$name=$value"); + \putenv("$name=$value"); + + return true; } /** - * Clear an environment variable. + * Delete an environment variable, if possible. * * @param string $name * - * @return void + * @return bool */ - public function clear($name) + public function delete(string $name) { - putenv($name); + \putenv($name); + + return true; } } diff --git a/vendor/vlucas/phpdotenv/src/Repository/Adapter/ReaderInterface.php b/vendor/vlucas/phpdotenv/src/Repository/Adapter/ReaderInterface.php index 90a1fabef..5ece5ee7b 100644 --- a/vendor/vlucas/phpdotenv/src/Repository/Adapter/ReaderInterface.php +++ b/vendor/vlucas/phpdotenv/src/Repository/Adapter/ReaderInterface.php @@ -1,15 +1,17 @@ + * @return \PhpOption\Option */ - public function get($name); + public function read(string $name); } diff --git a/vendor/vlucas/phpdotenv/src/Repository/Adapter/ReplacingWriter.php b/vendor/vlucas/phpdotenv/src/Repository/Adapter/ReplacingWriter.php new file mode 100644 index 000000000..326cd187d --- /dev/null +++ b/vendor/vlucas/phpdotenv/src/Repository/Adapter/ReplacingWriter.php @@ -0,0 +1,104 @@ + + */ + private $seen; + + /** + * Create a new replacement writer instance. + * + * @param \Dotenv\Repository\Adapter\WriterInterface $writer + * @param \Dotenv\Repository\Adapter\ReaderInterface $reader + * + * @return void + */ + public function __construct(WriterInterface $writer, ReaderInterface $reader) + { + $this->writer = $writer; + $this->reader = $reader; + $this->seen = []; + } + + /** + * Write to an environment variable, if possible. + * + * @param string $name + * @param string $value + * + * @return bool + */ + public function write(string $name, string $value) + { + if ($this->exists($name)) { + return $this->writer->write($name, $value); + } + + // succeed if nothing to do + return true; + } + + /** + * Delete an environment variable, if possible. + * + * @param string $name + * + * @return bool + */ + public function delete(string $name) + { + if ($this->exists($name)) { + return $this->writer->delete($name); + } + + // succeed if nothing to do + return true; + } + + /** + * Does the given environment variable exist. + * + * Returns true if it currently exists, or existed at any point in the past + * that we are aware of. + * + * @param string $name + * + * @return bool + */ + private function exists(string $name) + { + if (isset($this->seen[$name])) { + return true; + } + + if ($this->reader->read($name)->isDefined()) { + $this->seen[$name] = ''; + + return true; + } + + return false; + } +} diff --git a/vendor/vlucas/phpdotenv/src/Repository/Adapter/ServerConstAdapter.php b/vendor/vlucas/phpdotenv/src/Repository/Adapter/ServerConstAdapter.php index 529df96f1..8e3dc98e8 100644 --- a/vendor/vlucas/phpdotenv/src/Repository/Adapter/ServerConstAdapter.php +++ b/vendor/vlucas/phpdotenv/src/Repository/Adapter/ServerConstAdapter.php @@ -1,60 +1,87 @@ + */ + public static function create() + { + /** @var \PhpOption\Option */ + return Some::create(new self()); + } + + /** + * Read an environment variable, if it exists. + * + * @param string $name + * + * @return \PhpOption\Option + */ + public function read(string $name) + { + /** @var \PhpOption\Option */ + return Option::fromArraysValue($_SERVER, $name) + ->map(static function ($value) { + if ($value === false) { + return 'false'; + } + + if ($value === true) { + return 'true'; + } + + return $value; + })->filter(static function ($value) { + return \is_string($value); + }); + } + + /** + * Write to an environment variable, if possible. + * + * @param string $name + * @param string $value * * @return bool */ - public function isSupported() + public function write(string $name, string $value) { + $_SERVER[$name] = $value; + return true; } /** - * Get an environment variable, if it exists. + * Delete an environment variable, if possible. * * @param string $name * - * @return \PhpOption\Option + * @return bool */ - public function get($name) - { - if (array_key_exists($name, $_SERVER)) { - return Some::create($_SERVER[$name]); - } - - return None::create(); - } - - /** - * Set an environment variable. - * - * @param string $name - * @param string|null $value - * - * @return void - */ - public function set($name, $value = null) - { - $_SERVER[$name] = $value; - } - - /** - * Clear an environment variable. - * - * @param string $name - * - * @return void - */ - public function clear($name) + public function delete(string $name) { unset($_SERVER[$name]); + + return true; } } diff --git a/vendor/vlucas/phpdotenv/src/Repository/Adapter/WriterInterface.php b/vendor/vlucas/phpdotenv/src/Repository/Adapter/WriterInterface.php index 6670b728f..8b3fa5777 100644 --- a/vendor/vlucas/phpdotenv/src/Repository/Adapter/WriterInterface.php +++ b/vendor/vlucas/phpdotenv/src/Repository/Adapter/WriterInterface.php @@ -1,25 +1,27 @@ readers = $readers; - $this->writers = $writers; - parent::__construct($immutable); + $this->reader = $reader; + $this->writer = $writer; + } + + /** + * Determine if the given environment variable is defined. + * + * @param string $name + * + * @return bool + */ + public function has(string $name) + { + return $this->reader->read($name)->isDefined(); } /** * Get an environment variable. * - * We do this by querying our readers sequentially. - * * @param string $name * * @return string|null */ - protected function getInternal($name) + public function get(string $name) { - foreach ($this->readers as $reader) { - $result = $reader->get($name); - if ($result->isDefined()) { - return $result->get(); - } - } - - return null; + return $this->reader->read($name)->getOrElse(null); } /** * Set an environment variable. * - * @param string $name - * @param string|null $value + * @param string $name + * @param string $value * - * @return void + * @return bool */ - protected function setInternal($name, $value = null) + public function set(string $name, string $value) { - foreach ($this->writers as $writers) { - $writers->set($name, $value); - } + return $this->writer->write($name, $value); } /** @@ -75,12 +79,10 @@ class AdapterRepository extends AbstractRepository * * @param string $name * - * @return void + * @return bool */ - protected function clearInternal($name) + public function clear(string $name) { - foreach ($this->writers as $writers) { - $writers->clear($name); - } + return $this->writer->delete($name); } } diff --git a/vendor/vlucas/phpdotenv/src/Repository/RepositoryBuilder.php b/vendor/vlucas/phpdotenv/src/Repository/RepositoryBuilder.php index 66c1105cb..f8a926448 100644 --- a/vendor/vlucas/phpdotenv/src/Repository/RepositoryBuilder.php +++ b/vendor/vlucas/phpdotenv/src/Repository/RepositoryBuilder.php @@ -1,26 +1,45 @@ readers = $readers; - $this->writers = $writers; - $this->immutable = $immutable; - } + private $allowList; /** * Create a new repository builder instance. * + * @param \Dotenv\Repository\Adapter\ReaderInterface[] $readers + * @param \Dotenv\Repository\Adapter\WriterInterface[] $writers + * @param bool $immutable + * @param string[]|null $allowList + * + * @return void + */ + private function __construct(array $readers = [], array $writers = [], bool $immutable = false, array $allowList = null) + { + $this->readers = $readers; + $this->writers = $writers; + $this->immutable = $immutable; + $this->allowList = $allowList; + } + + /** + * Create a new repository builder instance with no adapters added. + * * @return \Dotenv\Repository\RepositoryBuilder */ - public static function create() + public static function createWithNoAdapters() { return new self(); } /** - * Creates a repository builder with the given readers. - * - * @param \Dotenv\Repository\Adapter\ReaderInterface[]|null $readers + * Create a new repository builder instance with the default adapters added. * * @return \Dotenv\Repository\RepositoryBuilder */ - public function withReaders(array $readers = null) + public static function createWithDefaultAdapters() { - $readers = $readers === null ? null : self::filterByAvailability($readers); + $adapters = \iterator_to_array(self::defaultAdapters()); - return new self($readers, $this->writers, $this->immutable); + return new self($adapters, $adapters); } /** - * Creates a repository builder with the given writers. + * Return the array of default adapters. * - * @param \Dotenv\Repository\Adapter\WriterInterface[]|null $writers + * @return \Generator<\Dotenv\Repository\Adapter\AdapterInterface> + */ + private static function defaultAdapters() + { + foreach (self::DEFAULT_ADAPTERS as $adapter) { + $instance = $adapter::create(); + if ($instance->isDefined()) { + yield $instance->get(); + } + } + } + + /** + * Determine if the given name if of an adapaterclass. + * + * @param string $name + * + * @return bool + */ + private static function isAnAdapterClass(string $name) + { + if (!\class_exists($name)) { + return false; + } + + return (new ReflectionClass($name))->implementsInterface(AdapterInterface::class); + } + + /** + * Creates a repository builder with the given reader added. + * + * Accepts either a reader instance, or a class-string for an adapter. If + * the adapter is not supported, then we silently skip adding it. + * + * @param \Dotenv\Repository\Adapter\ReaderInterface|string $reader + * + * @throws \InvalidArgumentException * * @return \Dotenv\Repository\RepositoryBuilder */ - public function withWriters(array $writers = null) + public function addReader($reader) { - $writers = $writers === null ? null : self::filterByAvailability($writers); + if (!(\is_string($reader) && self::isAnAdapterClass($reader)) && !($reader instanceof ReaderInterface)) { + throw new InvalidArgumentException( + \sprintf( + 'Expected either an instance of %s or a class-string implementing %s', + ReaderInterface::class, + AdapterInterface::class + ) + ); + } - return new self($this->readers, $writers, $this->immutable); + $optional = Some::create($reader)->flatMap(static function ($reader) { + return \is_string($reader) ? $reader::create() : Some::create($reader); + }); + + $readers = \array_merge($this->readers, \iterator_to_array($optional)); + + return new self($readers, $this->writers, $this->immutable, $this->allowList); + } + + /** + * Creates a repository builder with the given writer added. + * + * Accepts either a writer instance, or a class-string for an adapter. If + * the adapter is not supported, then we silently skip adding it. + * + * @param \Dotenv\Repository\Adapter\WriterInterface|string $writer + * + * @throws \InvalidArgumentException + * + * @return \Dotenv\Repository\RepositoryBuilder + */ + public function addWriter($writer) + { + if (!(\is_string($writer) && self::isAnAdapterClass($writer)) && !($writer instanceof WriterInterface)) { + throw new InvalidArgumentException( + \sprintf( + 'Expected either an instance of %s or a class-string implementing %s', + WriterInterface::class, + AdapterInterface::class + ) + ); + } + + $optional = Some::create($writer)->flatMap(static function ($writer) { + return \is_string($writer) ? $writer::create() : Some::create($writer); + }); + + $writers = \array_merge($this->writers, \iterator_to_array($optional)); + + return new self($this->readers, $writers, $this->immutable, $this->allowList); + } + + /** + * Creates a repository builder with the given adapter added. + * + * Accepts either an adapter instance, or a class-string for an adapter. If + * the adapter is not supported, then we silently skip adding it. We will + * add the adapter as both a reader and a writer. + * + * @param \Dotenv\Repository\Adapter\WriterInterface|string $adapter + * + * @throws \InvalidArgumentException + * + * @return \Dotenv\Repository\RepositoryBuilder + */ + public function addAdapter($adapter) + { + if (!(\is_string($adapter) && self::isAnAdapterClass($adapter)) && !($adapter instanceof AdapterInterface)) { + throw new InvalidArgumentException( + \sprintf( + 'Expected either an instance of %s or a class-string implementing %s', + WriterInterface::class, + AdapterInterface::class + ) + ); + } + + $optional = Some::create($adapter)->flatMap(static function ($adapter) { + return \is_string($adapter) ? $adapter::create() : Some::create($adapter); + }); + + $readers = \array_merge($this->readers, \iterator_to_array($optional)); + $writers = \array_merge($this->writers, \iterator_to_array($optional)); + + return new self($readers, $writers, $this->immutable, $this->allowList); } /** @@ -92,7 +236,19 @@ class RepositoryBuilder */ public function immutable() { - return new self($this->readers, $this->writers, true); + return new self($this->readers, $this->writers, true, $this->allowList); + } + + /** + * Creates a repository builder with the given allow list. + * + * @param string[]|null $allowList + * + * @return \Dotenv\Repository\RepositoryBuilder + */ + public function allowList(array $allowList = null) + { + return new self($this->readers, $this->writers, $this->immutable, $allowList); } /** @@ -102,43 +258,17 @@ class RepositoryBuilder */ public function make() { - if ($this->readers === null || $this->writers === null) { - $defaults = self::defaultAdapters(); + $reader = new MultiReader($this->readers); + $writer = new MultiWriter($this->writers); + + if ($this->immutable) { + $writer = new ImmutableWriter($writer, $reader); } - return new AdapterRepository( - $this->readers === null ? $defaults : $this->readers, - $this->writers === null ? $defaults : $this->writers, - $this->immutable - ); - } + if ($this->allowList !== null) { + $writer = new GuardedWriter($writer, $this->allowList); + } - /** - * Return the array of default adapters. - * - * @return \Dotenv\Repository\Adapter\AvailabilityInterface[] - */ - private static function defaultAdapters() - { - return self::filterByAvailability([ - new ApacheAdapter(), - new EnvConstAdapter(), - new ServerConstAdapter(), - new PutenvAdapter(), - ]); - } - - /** - * Filter an array of adapters to only those that are supported. - * - * @param \Dotenv\Repository\Adapter\AvailabilityInterface[] $adapters - * - * @return \Dotenv\Repository\Adapter\AvailabilityInterface[] - */ - private static function filterByAvailability(array $adapters) - { - return array_filter($adapters, function (AvailabilityInterface $adapter) { - return $adapter->isSupported(); - }); + return new AdapterRepository($reader, $writer); } } diff --git a/vendor/vlucas/phpdotenv/src/Repository/RepositoryInterface.php b/vendor/vlucas/phpdotenv/src/Repository/RepositoryInterface.php index db6641656..a2a7d32f0 100644 --- a/vendor/vlucas/phpdotenv/src/Repository/RepositoryInterface.php +++ b/vendor/vlucas/phpdotenv/src/Repository/RepositoryInterface.php @@ -1,54 +1,45 @@ - */ -interface RepositoryInterface extends ArrayAccess +interface RepositoryInterface { /** - * Tells whether environment variable has been defined. + * Determine if the given environment variable is defined. * * @param string $name * * @return bool */ - public function has($name); + public function has(string $name); /** * Get an environment variable. * * @param string $name * - * @throws \InvalidArgumentException - * * @return string|null */ - public function get($name); + public function get(string $name); /** * Set an environment variable. * - * @param string $name - * @param string|null $value + * @param string $name + * @param string $value * - * @throws \InvalidArgumentException - * - * @return void + * @return bool */ - public function set($name, $value = null); + public function set(string $name, string $value); /** * Clear an environment variable. * * @param string $name * - * @throws \InvalidArgumentException - * - * @return void + * @return bool */ - public function clear($name); + public function clear(string $name); } diff --git a/vendor/vlucas/phpdotenv/src/Result/Result.php b/vendor/vlucas/phpdotenv/src/Result/Result.php deleted file mode 100644 index 0a3656a76..000000000 --- a/vendor/vlucas/phpdotenv/src/Result/Result.php +++ /dev/null @@ -1,70 +0,0 @@ - - */ - abstract public function success(); - - /** - * Get the success value, if possible. - * - * @throws \RuntimeException - * - * @return T - */ - public function getSuccess() - { - return $this->success()->get(); - } - - /** - * Map over the success value. - * - * @template S - * - * @param callable(T):S $f - * - * @return \Dotenv\Result\Result - */ - abstract public function mapSuccess(callable $f); - - /** - * Get the error option value. - * - * @return \PhpOption\Option - */ - abstract public function error(); - - /** - * Get the error value, if possible. - * - * @throws \RuntimeException - * - * @return E - */ - public function getError() - { - return $this->error()->get(); - } - - /** - * Map over the error value. - * - * @template F - * - * @param callable(E):F $f - * - * @return \Dotenv\Result\Result - */ - abstract public function mapError(callable $f); -} diff --git a/vendor/vlucas/phpdotenv/src/Store/File/Paths.php b/vendor/vlucas/phpdotenv/src/Store/File/Paths.php index 989606361..4f678a552 100644 --- a/vendor/vlucas/phpdotenv/src/Store/File/Paths.php +++ b/vendor/vlucas/phpdotenv/src/Store/File/Paths.php @@ -1,9 +1,26 @@ */ - public static function read(array $filePaths, $shortCircuit = true) + public static function read(array $filePaths, bool $shortCircuit = true, string $fileEncoding = null) { $output = []; foreach ($filePaths as $filePath) { - $content = self::readFromFile($filePath); + $content = self::readFromFile($filePath, $fileEncoding); if ($content->isDefined()) { $output[$filePath] = $content->get(); if ($shortCircuit) { @@ -38,15 +60,22 @@ class Reader /** * Read the given file. * - * @param string $filePath + * @param string $path + * @param string|null $encoding + * + * @throws \Dotenv\Exception\InvalidEncodingException * * @return \PhpOption\Option */ - private static function readFromFile($filePath) + private static function readFromFile(string $path, string $encoding = null) { - $content = @file_get_contents($filePath); + /** @var Option */ + $content = Option::fromValue(@\file_get_contents($path), false); - /** @var \PhpOption\Option */ - return Option::fromValue($content, false); + return $content->flatMap(static function (string $content) use ($encoding) { + return Str::utf8($content, $encoding)->mapError(static function (string $error) { + throw new InvalidEncodingException($error); + })->success(); + }); } } diff --git a/vendor/vlucas/phpdotenv/src/Store/FileStore.php b/vendor/vlucas/phpdotenv/src/Store/FileStore.php index 8fed2a11d..43f6135c0 100644 --- a/vendor/vlucas/phpdotenv/src/Store/FileStore.php +++ b/vendor/vlucas/phpdotenv/src/Store/FileStore.php @@ -1,44 +1,55 @@ filePaths = $filePaths; $this->shortCircuit = $shortCircuit; + $this->fileEncoding = $fileEncoding; } /** * Read the content of the environment file(s). * - * @throws \Dotenv\Exception\InvalidPathException + * @throws \Dotenv\Exception\InvalidEncodingException|\Dotenv\Exception\InvalidPathException * * @return string */ @@ -48,14 +59,14 @@ class FileStore implements StoreInterface throw new InvalidPathException('At least one environment file path must be provided.'); } - $contents = Reader::read($this->filePaths, $this->shortCircuit); + $contents = Reader::read($this->filePaths, $this->shortCircuit, $this->fileEncoding); - if (count($contents) > 0) { - return implode("\n", $contents); + if (\count($contents) > 0) { + return \implode("\n", $contents); } throw new InvalidPathException( - sprintf('Unable to read any of the environment file(s) at [%s].', implode(', ', $this->filePaths)) + \sprintf('Unable to read any of the environment file(s) at [%s].', \implode(', ', $this->filePaths)) ); } } diff --git a/vendor/vlucas/phpdotenv/src/Store/StoreBuilder.php b/vendor/vlucas/phpdotenv/src/Store/StoreBuilder.php index 833f8b097..d1fb26fb3 100644 --- a/vendor/vlucas/phpdotenv/src/Store/StoreBuilder.php +++ b/vendor/vlucas/phpdotenv/src/Store/StoreBuilder.php @@ -1,11 +1,20 @@ paths = $paths; $this->names = $names; $this->shortCircuit = $shortCircuit; + $this->fileEncoding = $fileEncoding; } /** - * Create a new store builder instance. + * Create a new store builder instance with no names. * * @return \Dotenv\Store\StoreBuilder */ - public static function create() + public static function createWithNoNames() { return new self(); } /** - * Creates a store builder with the given paths. - * - * @param string|string[] $paths + * Create a new store builder instance with the default name. * * @return \Dotenv\Store\StoreBuilder */ - public function withPaths($paths) + public static function createWithDefaultName() { - return new self((array) $paths, $this->names, $this->shortCircuit); + return new self([], [self::DEFAULT_NAME]); } /** - * Creates a store builder with the given names. + * Creates a store builder with the given path added. * - * @param string|string[]|null $names + * @param string $path * * @return \Dotenv\Store\StoreBuilder */ - public function withNames($names = null) + public function addPath(string $path) { - return new self($this->paths, $names === null ? null : (array) $names, $this->shortCircuit); + return new self(\array_merge($this->paths, [$path]), $this->names, $this->shortCircuit, $this->fileEncoding); + } + + /** + * Creates a store builder with the given name added. + * + * @param string $name + * + * @return \Dotenv\Store\StoreBuilder + */ + public function addName(string $name) + { + return new self($this->paths, \array_merge($this->names, [$name]), $this->shortCircuit, $this->fileEncoding); } /** @@ -84,7 +112,19 @@ class StoreBuilder */ public function shortCircuit() { - return new self($this->paths, $this->names, true); + return new self($this->paths, $this->names, true, $this->fileEncoding); + } + + /** + * Creates a store builder with the specified file encoding. + * + * @param string|null $fileEncoding + * + * @return \Dotenv\Store\StoreBuilder + */ + public function fileEncoding(string $fileEncoding = null) + { + return new self($this->paths, $this->names, $this->shortCircuit, $fileEncoding); } /** @@ -95,8 +135,9 @@ class StoreBuilder public function make() { return new FileStore( - Paths::filePaths($this->paths, $this->names === null ? ['.env'] : $this->names), - $this->shortCircuit + Paths::filePaths($this->paths, $this->names), + $this->shortCircuit, + $this->fileEncoding ); } } diff --git a/vendor/vlucas/phpdotenv/src/Store/StoreInterface.php b/vendor/vlucas/phpdotenv/src/Store/StoreInterface.php index 91134514c..6f5b98629 100644 --- a/vendor/vlucas/phpdotenv/src/Store/StoreInterface.php +++ b/vendor/vlucas/phpdotenv/src/Store/StoreInterface.php @@ -1,5 +1,7 @@ content = $content; } diff --git a/vendor/vlucas/phpdotenv/src/Util/Regex.php b/vendor/vlucas/phpdotenv/src/Util/Regex.php new file mode 100644 index 000000000..e558f407a --- /dev/null +++ b/vendor/vlucas/phpdotenv/src/Util/Regex.php @@ -0,0 +1,110 @@ + + */ + public static function matches(string $pattern, string $subject) + { + return self::pregAndWrap(static function (string $subject) use ($pattern) { + return @\preg_match($pattern, $subject) === 1; + }, $subject); + } + + /** + * Perform a preg match all, wrapping up the result. + * + * @param string $pattern + * @param string $subject + * + * @return \GrahamCampbell\ResultType\Result + */ + public static function occurences(string $pattern, string $subject) + { + return self::pregAndWrap(static function (string $subject) use ($pattern) { + return (int) @\preg_match_all($pattern, $subject); + }, $subject); + } + + /** + * Perform a preg replace callback, wrapping up the result. + * + * @param string $pattern + * @param callable $callback + * @param string $subject + * @param int|null $limit + * + * @return \GrahamCampbell\ResultType\Result + */ + public static function replaceCallback(string $pattern, callable $callback, string $subject, int $limit = null) + { + return self::pregAndWrap(static function (string $subject) use ($pattern, $callback, $limit) { + return (string) @\preg_replace_callback($pattern, $callback, $subject, $limit ?? -1); + }, $subject); + } + + /** + * Perform a preg split, wrapping up the result. + * + * @param string $pattern + * @param string $subject + * + * @return \GrahamCampbell\ResultType\Result + */ + public static function split(string $pattern, string $subject) + { + return self::pregAndWrap(static function (string $subject) use ($pattern) { + /** @var string[] */ + return (array) @\preg_split($pattern, $subject); + }, $subject); + } + + /** + * Perform a preg operation, wrapping up the result. + * + * @template V + * + * @param callable(string):V $operation + * @param string $subject + * + * @return \GrahamCampbell\ResultType\Result + */ + private static function pregAndWrap(callable $operation, string $subject) + { + $result = $operation($subject); + + if (\preg_last_error() !== \PREG_NO_ERROR) { + return Error::create(\preg_last_error_msg()); + } + + return Success::create($result); + } +} diff --git a/vendor/vlucas/phpdotenv/src/Util/Str.php b/vendor/vlucas/phpdotenv/src/Util/Str.php new file mode 100644 index 000000000..582c21440 --- /dev/null +++ b/vendor/vlucas/phpdotenv/src/Util/Str.php @@ -0,0 +1,90 @@ + + */ + public static function utf8(string $input, string $encoding = null) + { + if ($encoding !== null && !\in_array($encoding, \mb_list_encodings(), true)) { + /** @var \GrahamCampbell\ResultType\Result */ + return Error::create( + \sprintf('Illegal character encoding [%s] specified.', $encoding) + ); + } + + /** @var \GrahamCampbell\ResultType\Result */ + return Success::create( + $encoding === null ? @\mb_convert_encoding($input, 'UTF-8') : @\mb_convert_encoding($input, 'UTF-8', $encoding) + ); + } + + /** + * Search for a given substring of the input. + * + * @param string $haystack + * @param string $needle + * + * @return \PhpOption\Option + */ + public static function pos(string $haystack, string $needle) + { + /** @var \PhpOption\Option */ + return Option::fromValue(\mb_strpos($haystack, $needle, 0, 'UTF-8'), false); + } + + /** + * Grab the specified substring of the input. + * + * @param string $input + * @param int $start + * @param int|null $length + * + * @return string + */ + public static function substr(string $input, int $start, int $length = null) + { + return \mb_substr($input, $start, $length, 'UTF-8'); + } + + /** + * Compute the length of the given string. + * + * @param string $input + * + * @return int + */ + public static function len(string $input) + { + return \mb_strlen($input, 'UTF-8'); + } +} diff --git a/vendor/vlucas/phpdotenv/src/Validator.php b/vendor/vlucas/phpdotenv/src/Validator.php index 8d002ee06..0c04ab62e 100644 --- a/vendor/vlucas/phpdotenv/src/Validator.php +++ b/vendor/vlucas/phpdotenv/src/Validator.php @@ -1,10 +1,13 @@ repository = $repository; $this->variables = $variables; + } - if ($required) { - $this->assertCallback( - function ($value) { - return $value !== null; - }, - 'is missing' - ); - } + /** + * Assert that each variable is present. + * + * @throws \Dotenv\Exception\ValidationException + * + * @return \Dotenv\Validator + */ + public function required() + { + return $this->assert( + static function (?string $value) { + return $value !== null; + }, + 'is missing' + ); } /** @@ -57,13 +67,9 @@ class Validator */ public function notEmpty() { - return $this->assertCallback( - function ($value) { - if ($value === null) { - return true; - } - - return strlen(trim($value)) > 0; + return $this->assertNullable( + static function (string $value) { + return Str::len(\trim($value)) > 0; }, 'is empty' ); @@ -78,13 +84,9 @@ class Validator */ public function isInteger() { - return $this->assertCallback( - function ($value) { - if ($value === null) { - return true; - } - - return ctype_digit($value); + return $this->assertNullable( + static function (string $value) { + return \ctype_digit($value); }, 'is not an integer' ); @@ -99,17 +101,13 @@ class Validator */ public function isBoolean() { - return $this->assertCallback( - function ($value) { - if ($value === null) { - return true; - } - + return $this->assertNullable( + static function (string $value) { if ($value === '') { return false; } - return filter_var($value, FILTER_VALIDATE_BOOLEAN, FILTER_NULL_ON_FAILURE) !== null; + return \filter_var($value, \FILTER_VALIDATE_BOOLEAN, \FILTER_NULL_ON_FAILURE) !== null; }, 'is not a boolean' ); @@ -126,15 +124,11 @@ class Validator */ public function allowedValues(array $choices) { - return $this->assertCallback( - function ($value) use ($choices) { - if ($value === null) { - return true; - } - - return in_array($value, $choices, true); + return $this->assertNullable( + static function (string $value) use ($choices) { + return \in_array($value, $choices, true); }, - sprintf('is not one of [%s]', implode(', ', $choices)) + \sprintf('is not one of [%s]', \implode(', ', $choices)) ); } @@ -147,47 +141,69 @@ class Validator * * @return \Dotenv\Validator */ - public function allowedRegexValues($regex) + public function allowedRegexValues(string $regex) { - return $this->assertCallback( - function ($value) use ($regex) { - if ($value === null) { - return true; - } - - return Regex::match($regex, $value)->success()->getOrElse(0) === 1; + return $this->assertNullable( + static function (string $value) use ($regex) { + return Regex::matches($regex, $value)->success()->getOrElse(false); }, - sprintf('does not match "%s"', $regex) + \sprintf('does not match "%s"', $regex) ); } /** * Assert that the callback returns true for each variable. * - * @param callable $callback - * @param string $message + * @param callable(?string):bool $callback + * @param string $message * * @throws \Dotenv\Exception\ValidationException * * @return \Dotenv\Validator */ - protected function assertCallback(callable $callback, $message = 'failed callback assertion') + public function assert(callable $callback, string $message) { $failing = []; foreach ($this->variables as $variable) { if ($callback($this->repository->get($variable)) === false) { - $failing[] = sprintf('%s %s', $variable, $message); + $failing[] = \sprintf('%s %s', $variable, $message); } } - if (count($failing) > 0) { - throw new ValidationException(sprintf( + if (\count($failing) > 0) { + throw new ValidationException(\sprintf( 'One or more environment variables failed assertions: %s.', - implode(', ', $failing) + \implode(', ', $failing) )); } return $this; } + + /** + * Assert that the callback returns true for each variable. + * + * Skip checking null variable values. + * + * @param callable(string):bool $callback + * @param string $message + * + * @throws \Dotenv\Exception\ValidationException + * + * @return \Dotenv\Validator + */ + public function assertNullable(callable $callback, string $message) + { + return $this->assert( + static function (?string $value) use ($callback) { + if ($value === null) { + return true; + } + + return $callback($value); + }, + $message + ); + } }