From d4489ec7afd3df0cb5c1ce8ea28d5d18d814faef Mon Sep 17 00:00:00 2001 From: grandeljay Date: Tue, 19 Dec 2023 15:31:43 +0100 Subject: [PATCH] chore(dependencies): update composer --- composer.json | 2 +- composer.lock | 270 +-- vendor/composer/autoload_classmap.php | 266 +-- vendor/composer/autoload_static.php | 266 +-- vendor/composer/ca-bundle/composer.json | 2 +- vendor/composer/ca-bundle/res/cacert.pem | 195 ++- vendor/composer/installed.json | 298 ++-- vendor/composer/installed.php | 90 +- vendor/embed/embed/CHANGELOG.md | 15 +- .../embed/embed/src/Http/CurlDispatcher.php | 31 +- .../embed/embed/src/Http/FactoryDiscovery.php | 20 + vendor/embed/embed/src/LinkedData.php | 62 +- vendor/embed/embed/src/functions.php | 26 +- vendor/gettext/translator/CHANGELOG.md | 7 +- vendor/gettext/translator/README.md | 2 +- .../src/Generator/ArrayGenerator.php | 72 +- vendor/nikic/php-parser/grammar/README.md | 30 - .../nikic/php-parser/grammar/parser.template | 106 -- vendor/nikic/php-parser/grammar/php5.y | 1046 ----------- vendor/nikic/php-parser/grammar/php7.y | 1245 ------------- vendor/nikic/php-parser/grammar/phpyLang.php | 184 -- .../php-parser/grammar/rebuildParsers.php | 81 - .../nikic/php-parser/grammar/tokens.template | 17 - vendor/nikic/php-parser/grammar/tokens.y | 115 -- .../PhpParser/NodeVisitor/NameResolver.php | 3 + .../php-parser/lib/PhpParser/Parser/Php5.php | 2 +- .../php-parser/lib/PhpParser/Parser/Php7.php | 2 +- .../lib/PhpParser/ParserFactory.php | 32 + vendor/oscarotero/html-parser/CHANGELOG.md | 9 +- vendor/oscarotero/html-parser/src/Parser.php | 4 + vendor/phpcsstandards/phpcsextra/CHANGELOG.md | 69 +- .../phpcsextra/Modernize/ruleset.xml | 2 +- .../Sniffs/Arrays/CommaAfterLastSniff.php | 7 + .../phpcsextra/NormalizedArrays/ruleset.xml | 2 +- vendor/phpcsstandards/phpcsextra/README.md | 36 +- .../CodeAnalysis/NoDoubleNegativeStandard.xml | 27 + .../Docs/Operators/ConcatPositionStandard.xml | 31 + .../Docs/PHP/LowercasePHPTagStandard.xml | 25 + .../ConstructorDestructorReturnSniff.php | 12 + .../CodeAnalysis/NoDoubleNegativeSniff.php | 269 +++ .../Sniffs/Operators/ConcatPositionSniff.php | 204 +++ .../Sniffs/PHP/LowercasePHPTagSniff.php | 87 + .../UseStatements/NoUselessAliasesSniff.php | 9 - .../phpcsextra/Universal/ruleset.xml | 2 +- .../phpcsstandards/phpcsextra/composer.json | 9 +- vendor/phpcsstandards/phpcsutils/CHANGELOG.md | 31 + .../AbstractArrayDeclarationSniff.php | 8 +- .../PHPCSUtils/BackCompat/BCFile.php | 55 +- .../PHPCSUtils/BackCompat/BCTokens.php | 12 +- .../PHPCSUtils/BackCompat/Helper.php | 2 +- .../Exceptions/TestTargetNotFound.php | 4 +- .../phpcsutils/PHPCSUtils/Internal/Cache.php | 5 +- .../Internal/IsShortArrayOrList.php | 4 +- .../Internal/IsShortArrayOrListWithCache.php | 2 +- .../PHPCSUtils/Internal/NoFileCache.php | 2 +- .../PHPCSUtils/Internal/StableCollections.php | 4 +- .../TestUtils/UtilityMethodTestCase.php | 47 +- .../PHPCSUtils/Tokens/Collections.php | 152 +- .../phpcsutils/PHPCSUtils/Utils/Arrays.php | 20 +- .../PHPCSUtils/Utils/Conditions.php | 30 +- .../PHPCSUtils/Utils/ControlStructures.php | 3 +- .../PHPCSUtils/Utils/FunctionDeclarations.php | 24 +- .../phpcsutils/PHPCSUtils/Utils/Lists.php | 23 +- .../PHPCSUtils/Utils/MessageHelper.php | 4 +- .../phpcsutils/PHPCSUtils/Utils/Numbers.php | 2 +- .../PHPCSUtils/Utils/ObjectDeclarations.php | 28 +- .../phpcsutils/PHPCSUtils/Utils/Operators.php | 2 +- .../PHPCSUtils/Utils/Parentheses.php | 100 +- .../PHPCSUtils/Utils/PassedParameters.php | 44 +- .../phpcsutils/PHPCSUtils/Utils/Scopes.php | 10 +- .../PHPCSUtils/Utils/UseStatements.php | 48 +- .../phpcsutils/PHPCSUtils/Utils/Variables.php | 11 +- .../phpcsutils/PHPCSUtils/ruleset.xml | 2 +- vendor/phpcsstandards/phpcsutils/README.md | 25 +- .../phpcsstandards/phpcsutils/composer.json | 7 +- .../php-code-coverage/ChangeLog-10.1.md | 28 + .../src/Data/RawCodeCoverageData.php | 12 + .../Html/Renderer/Template/css/style.css | 2 +- .../ExecutableLinesFindingVisitor.php | 16 +- .../phpunit/php-code-coverage/src/Version.php | 2 +- vendor/phpunit/phpunit/.phpstorm.meta.php | 9 +- vendor/phpunit/phpunit/ChangeLog-10.0.md | 126 -- vendor/phpunit/phpunit/ChangeLog-10.5.md | 51 + vendor/phpunit/phpunit/ChangeLog-8.5.md | 297 ---- vendor/phpunit/phpunit/ChangeLog-9.6.md | 14 - vendor/phpunit/phpunit/DEPRECATIONS.md | 91 + vendor/phpunit/phpunit/README.md | 2 - vendor/phpunit/phpunit/SECURITY.md | 28 +- vendor/phpunit/phpunit/composer.json | 17 +- vendor/phpunit/phpunit/composer.lock | 1542 +++++++++++++++++ vendor/phpunit/phpunit/phpunit | 21 +- vendor/phpunit/phpunit/phpunit.xsd | 120 +- vendor/phpunit/phpunit/schema/10.0.xsd | 284 +++ .../src/Event/Dispatcher/DirectDispatcher.php | 52 +- .../src/Event/Emitter/DispatchingEmitter.php | 415 +++-- .../phpunit/src/Event/Emitter/Emitter.php | 52 +- .../src/Event/Events/Application/Finished.php | 2 +- .../src/Event/Events/Application/Started.php | 2 +- .../Events/Test/Assertion/AssertionFailed.php | 12 +- .../Assertion/AssertionFailedSubscriber.php | 2 + .../Test/Assertion/AssertionSucceeded.php | 12 +- .../AssertionSucceededSubscriber.php | 2 + .../Events/Test/ComparatorRegistered.php | 2 +- .../HookMethod/AfterLastTestMethodCalled.php | 2 +- .../AfterLastTestMethodFinished.php | 2 +- .../Test/HookMethod/AfterTestMethodCalled.php | 2 +- .../HookMethod/AfterTestMethodFinished.php | 2 +- .../BeforeFirstTestMethodCalled.php | 2 +- .../BeforeFirstTestMethodErrored.php | 2 +- .../BeforeFirstTestMethodFinished.php | 2 +- .../HookMethod/BeforeTestMethodCalled.php | 2 +- .../HookMethod/BeforeTestMethodFinished.php | 2 +- .../Test/HookMethod/PostConditionCalled.php | 2 +- .../Test/HookMethod/PostConditionFinished.php | 2 +- .../Test/HookMethod/PreConditionCalled.php | 2 +- .../Test/HookMethod/PreConditionFinished.php | 2 +- .../Events/Test/Issue/ConsideredRisky.php | 10 + .../Test/Issue/DeprecationTriggered.php | 80 +- .../Events/Test/Issue/ErrorTriggered.php | 46 +- .../Events/Test/Issue/NoticeTriggered.php | 71 +- .../Test/Issue/PhpDeprecationTriggered.php | 80 +- .../Events/Test/Issue/PhpNoticeTriggered.php | 71 +- .../Events/Test/Issue/PhpWarningTriggered.php | 71 +- .../Issue/PhpunitDeprecationTriggered.php | 2 +- .../Test/Issue/PhpunitErrorTriggered.php | 5 +- .../Test/Issue/PhpunitWarningTriggered.php | 2 +- .../Events/Test/Issue/WarningTriggered.php | 71 +- .../Lifecycle/DataProviderMethodCalled.php | 60 + .../DataProviderMethodCalledSubscriber.php | 20 + .../Lifecycle/DataProviderMethodFinished.php | 77 + .../DataProviderMethodFinishedSubscriber.php | 20 + .../Test/Lifecycle/PreparationFailed.php | 50 + .../Lifecycle/PreparationFailedSubscriber.php | 20 + .../src/Event/Events/Test/Outcome/Errored.php | 5 +- .../src/Event/Events/Test/Outcome/Failed.php | 5 +- .../Events/Test/Outcome/MarkedIncomplete.php | 5 +- .../src/Event/Events/Test/Outcome/Skipped.php | 2 +- .../Events/Test/PrintedUnexpectedOutput.php | 60 + .../PrintedUnexpectedOutputSubscriber.php | 20 + .../Test/TestDouble/MockObjectCreated.php | 2 +- .../MockObjectForAbstractClassCreated.php | 2 +- ...jectForIntersectionOfInterfacesCreated.php | 2 +- .../TestDouble/MockObjectForTraitCreated.php | 2 +- .../TestDouble/MockObjectFromWsdlCreated.php | 2 +- .../TestDouble/PartialMockObjectCreated.php | 2 +- .../Test/TestDouble/TestProxyCreated.php | 2 +- .../Test/TestDouble/TestStubCreated.php | 2 +- ...StubForIntersectionOfInterfacesCreated.php | 2 +- .../Events/TestRunner/BootstrapFinished.php | 2 +- .../TestRunner/DeprecationTriggered.php | 2 +- .../Events/TestRunner/ExecutionAborted.php | 38 + .../TestRunner/ExecutionAbortedSubscriber.php | 20 + .../Events/TestRunner/ExecutionStarted.php | 2 +- .../TestRunner/ExtensionLoadedFromPhar.php | 2 +- .../TestRunner/GarbageCollectionDisabled.php | 38 + .../GarbageCollectionDisabledSubscriber.php | 20 + .../TestRunner/GarbageCollectionEnabled.php | 38 + .../GarbageCollectionEnabledSubscriber.php | 20 + .../TestRunner/GarbageCollectionTriggered.php | 38 + .../GarbageCollectionTriggeredSubscriber.php | 20 + .../Events/TestRunner/WarningTriggered.php | 2 +- .../src/Event/Events/TestSuite/Filtered.php | 2 +- .../src/Event/Events/TestSuite/Finished.php | 12 +- .../src/Event/Events/TestSuite/Loaded.php | 2 +- .../src/Event/Events/TestSuite/Skipped.php | 57 + .../Events/TestSuite/SkippedSubscriber.php | 20 + .../src/Event/Events/TestSuite/Started.php | 12 +- .../NoTestCaseObjectOnCallStackException.php | 3 +- vendor/phpunit/phpunit/src/Event/Facade.php | 174 +- vendor/phpunit/phpunit/src/Event/TypeMap.php | 167 +- .../src/Event/Value/ComparisonFailure.php | 54 +- .../Event/Value/ComparisonFailureBuilder.php | 68 + .../phpunit/src/Event/Value/Runtime/PHP.php | 2 +- .../src/Event/Value/Runtime/Runtime.php | 2 +- .../src/Event/Value/Telemetry/Duration.php | 14 +- .../Telemetry/GarbageCollectorStatus.php | 180 ++ .../GarbageCollectorStatusProvider.php | 18 + .../src/Event/Value/Telemetry/HRTime.php | 10 +- .../src/Event/Value/Telemetry/Info.php | 7 +- .../src/Event/Value/Telemetry/MemoryMeter.php | 2 +- .../src/Event/Value/Telemetry/MemoryUsage.php | 4 +- .../Php81GarbageCollectorStatusProvider.php | 38 + .../Php83GarbageCollectorStatusProvider.php | 38 + .../src/Event/Value/Telemetry/Snapshot.php | 15 +- .../src/Event/Value/Telemetry/StopWatch.php | 2 +- .../src/Event/Value/Telemetry/System.php | 13 +- .../phpunit/src/Event/Value/Test/Phpt.php | 11 +- .../phpunit/src/Event/Value/Test/Test.php | 15 + .../phpunit/src/Event/Value/Test/TestDox.php | 35 +- .../src/Event/Value/Test/TestDoxBuilder.php | 49 + .../src/Event/Value/Test/TestMethod.php | 77 +- .../Event/Value/Test/TestMethodBuilder.php | 94 + .../src/Event/Value/TestSuite/TestSuite.php | 95 +- .../Value/TestSuite/TestSuiteBuilder.php | 122 ++ ...TestSuiteForTestMethodWithDataProvider.php | 11 +- .../phpunit/src/Event/Value/Throwable.php | 26 +- .../src/Event/Value/ThrowableBuilder.php | 42 + .../phpunit/phpunit/src/Framework/Assert.php | 279 ++- .../src/Framework/Assert/Functions.php | 102 +- .../Attributes/CodeCoverageIgnore.php | 2 + .../Attributes/IgnoreClassForCodeCoverage.php | 44 + .../Attributes/IgnoreDeprecations.php | 22 + .../IgnoreFunctionForCodeCoverage.php | 44 + .../IgnoreMethodForCodeCoverage.php | 59 + .../Attributes/WithoutErrorHandler.php | 22 + .../Constraint/Cardinality/Count.php | 6 +- .../Constraint/Cardinality/GreaterThan.php | 10 +- .../Constraint/Cardinality/IsEmpty.php | 2 +- .../Constraint/Cardinality/LessThan.php | 10 +- .../src/Framework/Constraint/Constraint.php | 50 +- .../Framework/Constraint/Equality/IsEqual.php | 17 +- .../Equality/IsEqualCanonicalizing.php | 13 +- .../Equality/IsEqualIgnoringCase.php | 13 +- .../Constraint/Equality/IsEqualWithDelta.php | 15 +- .../Constraint/Exception/Exception.php | 30 +- .../Constraint/Exception/ExceptionCode.php | 11 +- .../ExceptionMessageIsOrContains.php} | 23 +- ...eptionMessageMatchesRegularExpression.php} | 23 +- .../Constraint/Filesystem/DirectoryExists.php | 2 +- .../Constraint/Filesystem/FileExists.php | 2 +- .../Constraint/Filesystem/IsReadable.php | 2 +- .../Constraint/Filesystem/IsWritable.php | 2 +- .../src/Framework/Constraint/IsIdentical.php | 16 +- .../src/Framework/Constraint/JsonMatches.php | 4 +- .../JsonMatchesErrorMessageProvider.php | 52 - .../Constraint/{ => Object}/ObjectEquals.php | 20 +- .../Constraint/Object/ObjectHasProperty.php | 80 + .../Constraint/Operator/BinaryOperator.php | 2 +- .../Constraint/Operator/LogicalNot.php | 8 +- .../Constraint/Operator/LogicalXor.php | 2 +- .../Framework/Constraint/String/IsJson.php | 33 +- .../Constraint/String/RegularExpression.php | 2 +- .../Constraint/String/StringContains.php | 99 +- .../StringEqualsStringIgnoringLineEndings.php | 4 +- .../String/StringMatchesFormatDescription.php | 42 +- .../Constraint/Traversable/ArrayHasKey.php | 5 +- .../Constraint/Traversable/IsList.php | 4 +- .../Traversable/TraversableContains.php | 7 +- .../Traversable/TraversableContainsOnly.php | 10 +- .../Constraint/Type/IsInstanceOf.php | 59 +- .../src/Framework/Constraint/Type/IsType.php | 21 +- .../src/Framework/DataProviderTestSuite.php | 9 +- .../src/Framework/Exception/Exception.php | 19 +- .../GeneratorNotSupportedException.php | 11 +- .../ActualValueIsNotAnObjectException.php | 9 +- ...hodDoesNotAcceptParameterTypeException.php | 10 +- ...dDoesNotDeclareBoolReturnTypeException.php | 10 +- ...NotDeclareExactlyOneParameterException.php | 13 +- ...odDoesNotDeclareParameterTypeException.php | 13 +- .../ComparisonMethodDoesNotExistException.php | 13 +- .../UnknownClassOrInterfaceException.php | 4 +- ...Exception.php => UnknownTypeException.php} | 8 +- .../Framework/ExecutionOrderDependency.php | 14 +- .../MockObject/ConfigurableMethod.php | 49 +- .../CannotUseAddMethodsException.php | 4 +- .../CannotUseOnlyMethodsException.php | 6 +- .../IncompatibleReturnValueException.php | 4 +- .../MatchBuilderNotFoundException.php | 4 +- .../MatcherAlreadyRegisteredException.php | 4 +- .../MethodCannotBeConfiguredException.php | 4 +- .../NeverReturningMethodException.php | 34 + .../ReturnValueNotConfiguredException.php | 6 +- .../Exception/ClassAlreadyExistsException.php | 6 +- .../Exception/ClassIsEnumerationException.php | 6 +- .../Exception/ClassIsFinalException.php | 6 +- .../Exception/ClassIsReadonlyException.php | 6 +- .../Exception/DuplicateMethodException.php | 6 +- .../Generator/Exception/Exception.php | 19 + .../Exception/InvalidMethodNameException.php | 6 +- ...ConstructorInvocationRequiredException.php | 2 +- .../Exception/ReflectionException.php} | 4 +- .../Generator/Exception/RuntimeException.php} | 10 +- .../SoapExtensionNotAvailableException.php | 4 +- .../Exception/UnknownClassException.php | 6 +- .../Exception/UnknownTraitException.php | 8 +- .../Exception/UnknownTypeException.php | 6 +- .../MockObject/{ => Generator}/Generator.php | 455 ++--- .../MockObject/{ => Generator}/MockClass.php | 5 +- .../MockObject/{ => Generator}/MockMethod.php | 117 +- .../{ => Generator}/MockMethodSet.php | 2 +- .../MockObject/{ => Generator}/MockTrait.php | 9 +- .../MockObject/{ => Generator}/MockType.php | 2 +- .../{ => Generator}/TemplateLoader.php | 17 +- .../MockObject/Generator/mocked_class.tpl | 6 - .../Generator/mocked_method_never_or_void.tpl | 20 - .../proxied_method_never_or_void.tpl | 22 - .../Generator/{ => templates}/deprecation.tpl | 0 .../doubled_method.tpl} | 4 +- .../doubled_static_method.tpl} | 0 .../{ => templates}/intersection.tpl | 0 .../{ => templates}/proxied_method.tpl | 2 +- .../Generator/templates/test_double_class.tpl | 5 + .../Generator/{ => templates}/trait_class.tpl | 0 .../Generator/{ => templates}/wsdl_class.tpl | 0 .../Generator/{ => templates}/wsdl_method.tpl | 0 .../src/Framework/MockObject/Invocation.php | 274 --- .../src/Framework/MockObject/MockBuilder.php | 112 +- .../Api/DoubledCloneMethod.php} | 2 +- .../MockObject/{ => Runtime}/Api/Method.php | 2 +- .../MockObject/Runtime/Api/MockObjectApi.php | 52 + .../Api/ProxiedCloneMethod.php} | 2 +- .../{Api/Api.php => Runtime/Api/StubApi.php} | 39 +- .../{ => Runtime}/Builder/Identity.php | 0 .../Builder/InvocationMocker.php | 70 +- .../Builder/InvocationStubber.php | 0 .../{ => Runtime}/Builder/MethodNameMatch.php | 0 .../{ => Runtime}/Builder/ParametersMatch.php | 0 .../MockObject/{ => Runtime}/Builder/Stub.php | 0 .../{ => Runtime/Interface}/MockObject.php | 10 +- .../Runtime/Interface/MockObjectInternal.php | 22 + .../{ => Runtime/Interface}/Stub.php | 5 - .../Runtime/Interface/StubInternal.php | 24 + .../MockObject/Runtime/Invocation.php | 150 ++ .../{ => Runtime}/InvocationHandler.php | 24 +- .../MockObject/{ => Runtime}/Matcher.php | 47 +- .../{ => Runtime}/MethodNameConstraint.php | 9 +- .../Runtime/ReturnValueGenerator.php | 242 +++ .../{ => Runtime}/Rule/AnyInvokedCount.php | 0 .../{ => Runtime}/Rule/AnyParameters.php | 5 - .../{ => Runtime}/Rule/InvocationOrder.php | 5 +- .../Rule/InvokedAtLeastCount.php | 20 +- .../{ => Runtime}/Rule/InvokedAtLeastOnce.php | 2 +- .../{ => Runtime}/Rule/InvokedAtMostCount.php | 20 +- .../{ => Runtime}/Rule/InvokedCount.php | 21 +- .../{ => Runtime}/Rule/MethodName.php | 0 .../{ => Runtime}/Rule/Parameters.php | 23 +- .../{ => Runtime}/Rule/ParametersRule.php | 4 +- .../{ => Runtime}/Stub/ConsecutiveCalls.php | 21 +- .../{ => Runtime}/Stub/Exception.php | 12 - .../{ => Runtime}/Stub/ReturnArgument.php | 6 - .../{ => Runtime}/Stub/ReturnCallback.php | 27 - .../{ => Runtime}/Stub/ReturnReference.php | 12 - .../{ => Runtime}/Stub/ReturnSelf.php | 5 - .../{ => Runtime}/Stub/ReturnStub.php | 12 - .../{ => Runtime}/Stub/ReturnValueMap.php | 5 - .../MockObject/{ => Runtime}/Stub/Stub.php | 3 +- .../src/Framework/MockObject/Verifiable.php | 26 - .../phpunit/src/Framework/TestBuilder.php | 38 +- .../phpunit/src/Framework/TestCase.php | 600 ++++--- .../phpunit/src/Framework/TestRunner.php | 110 +- .../phpunit/src/Framework/TestSuite.php | 363 ++-- .../src/Framework/TestSuiteIterator.php | 2 +- .../phpunit/src/Logging/EventLogger.php | 2 +- .../src/Logging/JUnit/JunitXmlLogger.php | 167 +- .../TestPreparationFailedSubscriber.php | 30 + .../TestPreparationStartedSubscriber.php | 30 + .../Subscriber/TestPreparedSubscriber.php | 2 +- .../src/Logging/TeamCity/TeamCityLogger.php | 44 +- .../src/Logging/TestDox/HtmlRenderer.php | 45 +- .../src/Logging/TestDox/NamePrettifier.php | 22 +- .../src/Logging/TestDox/PlainTextRenderer.php | 32 +- ...edMockObjectForAbstractClassSubscriber.php | 24 - ...estCreatedMockObjectForTraitSubscriber.php | 24 - ...estCreatedMockObjectFromWsdlSubscriber.php | 24 - ...TestCreatedPartialMockObjectSubscriber.php | 24 - .../TestCreatedTestProxySubscriber.php | 24 - .../Subscriber/Subscriber.php | 0 .../TestConsideredRiskySubscriber.php | 0 .../Subscriber/TestErroredSubscriber.php | 0 .../Subscriber/TestFailedSubscriber.php | 0 .../Subscriber/TestFinishedSubscriber.php | 0 .../TestMarkedIncompleteSubscriber.php | 0 .../Subscriber/TestPassedSubscriber.php | 0 .../Subscriber/TestPreparedSubscriber.php | 0 .../Subscriber/TestSkippedSubscriber.php | 0 .../{TestMethod => TestResult}/TestResult.php | 33 +- .../TestResultCollection.php | 0 .../TestResultCollectionIterator.php | 0 .../TestResultCollector.php | 118 +- vendor/phpunit/phpunit/src/Metadata/After.php | 7 +- .../phpunit/src/Metadata/AfterClass.php | 7 +- .../phpunit/src/Metadata/Api/CodeCoverage.php | 122 +- .../phpunit/src/Metadata/Api/DataProvider.php | 74 +- .../phpunit/src/Metadata/Api/Dependencies.php | 17 +- .../phpunit/src/Metadata/Api/Groups.php | 12 +- .../phpunit/src/Metadata/Api/HookMethods.php | 72 +- .../phpunit/src/Metadata/Api/Requirements.php | 19 +- .../phpunit/src/Metadata/BackupGlobals.php | 10 +- .../src/Metadata/BackupStaticProperties.php | 10 +- .../phpunit/phpunit/src/Metadata/Before.php | 7 +- .../phpunit/src/Metadata/BeforeClass.php | 7 +- .../phpunit/phpunit/src/Metadata/Covers.php | 17 +- .../phpunit/src/Metadata/CoversClass.php | 10 +- .../src/Metadata/CoversDefaultClass.php | 8 +- .../phpunit/src/Metadata/CoversFunction.php | 20 +- .../phpunit/src/Metadata/CoversNothing.php | 7 +- .../phpunit/src/Metadata/DataProvider.php | 16 +- .../phpunit/src/Metadata/DependsOnClass.php | 8 +- .../phpunit/src/Metadata/DependsOnMethod.php | 16 +- .../src/Metadata/DoesNotPerformAssertions.php | 7 +- ...tSupportedForInternalClassesException.php} | 15 +- .../ExcludeGlobalVariableFromBackup.php | 17 +- .../ExcludeStaticPropertyFromBackup.php | 16 +- vendor/phpunit/phpunit/src/Metadata/Group.php | 17 +- .../Metadata/IgnoreClassForCodeCoverage.php | 52 + .../src/Metadata/IgnoreDeprecations.php | 26 + .../IgnoreFunctionForCodeCoverage.php | 52 + .../Metadata/IgnoreMethodForCodeCoverage.php | 67 + .../phpunit/phpunit/src/Metadata/Metadata.php | 198 ++- .../src/Metadata/MetadataCollection.php | 265 +-- .../Metadata/MetadataCollectionIterator.php | 2 +- .../Metadata/Parser/Annotation/DocBlock.php | 39 +- .../Metadata/Parser/Annotation/Registry.php | 15 +- .../src/Metadata/Parser/AnnotationParser.php | 57 +- .../src/Metadata/Parser/AttributeParser.php | 94 +- .../src/Metadata/Parser/CachingParser.php | 4 +- .../phpunit/src/Metadata/Parser/Parser.php | 2 + .../src/Metadata/Parser/ParserChain.php | 4 +- .../phpunit/src/Metadata/Parser/Registry.php | 4 +- .../phpunit/src/Metadata/PostCondition.php | 7 +- .../phpunit/src/Metadata/PreCondition.php | 7 +- .../src/Metadata/PreserveGlobalState.php | 10 +- .../phpunit/src/Metadata/RequiresFunction.php | 17 +- .../phpunit/src/Metadata/RequiresMethod.php | 18 +- .../src/Metadata/RequiresOperatingSystem.php | 17 +- .../RequiresOperatingSystemFamily.php | 17 +- .../phpunit/src/Metadata/RequiresPhp.php | 10 +- .../src/Metadata/RequiresPhpExtension.php | 17 +- .../phpunit/src/Metadata/RequiresPhpunit.php | 10 +- .../phpunit/src/Metadata/RequiresSetting.php | 25 +- .../Metadata/RunClassInSeparateProcess.php | 7 +- .../src/Metadata/RunInSeparateProcess.php | 7 +- .../Metadata/RunTestsInSeparateProcesses.php | 7 +- vendor/phpunit/phpunit/src/Metadata/Test.php | 7 +- .../phpunit/phpunit/src/Metadata/TestDox.php | 17 +- .../phpunit/phpunit/src/Metadata/TestWith.php | 10 +- vendor/phpunit/phpunit/src/Metadata/Uses.php | 17 +- .../phpunit/src/Metadata/UsesClass.php | 10 +- .../phpunit/src/Metadata/UsesDefaultClass.php | 8 +- .../phpunit/src/Metadata/UsesFunction.php | 20 +- .../Version/ComparisonRequirement.php | 2 +- .../Version/ConstraintRequirement.php | 6 +- .../src/Metadata/Version/Requirement.php | 10 +- .../src/Metadata/WithoutErrorHandler.php | 26 + .../phpunit/src/Runner/Baseline/Baseline.php | 59 + .../Exception/CannotLoadBaselineException.php | 20 + .../FileDoesNotHaveLineException.php} | 14 +- .../phpunit/src/Runner/Baseline/Generator.php | 80 + .../phpunit/src/Runner/Baseline/Issue.php | 143 ++ .../phpunit/src/Runner/Baseline/Reader.php | 100 ++ .../Baseline/RelativePathCalculator.php | 103 ++ .../Runner/Baseline/Subscriber/Subscriber.php | 28 + .../TestTriggeredDeprecationSubscriber.php | 29 + .../TestTriggeredNoticeSubscriber.php | 29 + .../TestTriggeredPhpDeprecationSubscriber.php | 29 + .../TestTriggeredPhpNoticeSubscriber.php | 29 + .../TestTriggeredPhpWarningSubscriber.php | 29 + .../TestTriggeredWarningSubscriber.php | 29 + .../phpunit/src/Runner/Baseline/Writer.php | 65 + .../phpunit/src/Runner/CodeCoverage.php | 259 +-- .../src/{Util => Runner}/ErrorHandler.php | 98 +- .../Exception/ClassCannotBeFoundException.php | 4 +- ...> ClassDoesNotExtendTestCaseException.php} | 11 +- .../Exception/ClassIsAbstractException.php | 4 +- .../DirectoryCannotBeCreatedException.php | 4 +- .../Exception/FileDoesNotExistException.php | 4 +- .../ParameterDoesNotExistException.php | 2 +- ...hptExternalFileCannotBeLoadedException.php | 4 +- .../UnsupportedPhptSectionException.php | 4 +- .../Extension/ExtensionBootstrapper.php | 59 +- .../phpunit/src/Runner/Extension/Facade.php | 68 +- .../src/Runner/Extension/PharLoader.php | 99 +- .../phpunit/src/Runner/Filter/Factory.php | 19 + .../src/Runner/Filter/GroupFilterIterator.php | 9 +- .../src/Runner/Filter/NameFilterIterator.php | 13 +- .../Runner/Filter/TestIdFilterIterator.php | 61 + .../GarbageCollectionHandler.php | 87 + .../ExecutionFinishedSubscriber.php | 29 + .../Subscriber/ExecutionStartedSubscriber.php | 29 + .../Subscriber/Subscriber.php} | 18 +- .../Subscriber/TestFinishedSubscriber.php | 29 + .../phpunit/src/Runner/PhptTestCase.php | 55 +- .../Runner/ResultCache/DefaultResultCache.php | 4 +- .../Runner/ResultCache/ResultCacheHandler.php | 18 +- .../src/Runner/TestResult/Collector.php | 447 +++-- .../phpunit/src/Runner/TestResult/Facade.php | 83 +- .../phpunit/src/Runner/TestResult/Issue.php | 113 ++ .../src/Runner/TestResult/PassedTests.php | 8 +- .../TestSuiteFinishedSubscriber.php | 4 + .../Subscriber/TestSuiteSkippedSubscriber.php | 24 + .../src/Runner/TestResult/TestResult.php | 468 +++-- .../phpunit/src/Runner/TestSuiteLoader.php | 131 +- .../phpunit/src/Runner/TestSuiteSorter.php | 10 +- vendor/phpunit/phpunit/src/Runner/Version.php | 2 +- .../phpunit/src/TextUI/Application.php | 380 ++-- .../Commands/GenerateConfigurationCommand.php | 4 +- .../Command/Commands/ListGroupsCommand.php | 4 +- .../Commands/ListTestSuitesCommand.php | 2 +- .../Commands/ListTestsAsTextCommand.php | 4 +- .../Commands/ListTestsAsXmlCommand.php | 16 +- .../Commands/MigrateConfigurationCommand.php | 2 +- .../Command/Commands/ShowHelpCommand.php | 2 +- .../Command/Commands/VersionCheckCommand.php | 8 +- .../Commands/WarmCodeCoverageCacheCommand.php | 18 +- .../phpunit/src/TextUI/Command/Result.php | 9 +- .../src/TextUI/Configuration/Builder.php | 6 +- .../src/TextUI/Configuration/Cli/Builder.php | 193 ++- .../Configuration/Cli/Configuration.php | 489 ++++-- .../Cli/XmlConfigurationFileFinder.php | 4 +- .../CodeCoverageFilterRegistry.php | 61 +- .../TextUI/Configuration/Configuration.php | 306 +++- .../Exception/CannotFindSchemaException.php | 20 + .../Exception/NoBaselineException.php} | 4 +- .../src/TextUI/Configuration/Merger.php | 223 ++- .../src/TextUI/Configuration/PhpHandler.php | 2 +- .../src/TextUI/Configuration/Registry.php | 5 +- .../Configuration/SourceFilter.php} | 13 +- .../src/TextUI/Configuration/SourceMapper.php | 97 ++ .../TextUI/Configuration/TestSuiteBuilder.php | 75 +- .../TextUI/Configuration/Value/Constant.php | 2 +- .../src/TextUI/Configuration/Value/File.php | 9 + .../Configuration/Value/FilterDirectory.php | 9 + .../src/TextUI/Configuration/Value/Source.php | 166 ++ .../Configuration/Value/TestDirectory.php | 9 + .../TextUI/Configuration/Value/TestSuite.php | 9 + .../Xml/CodeCoverage/CodeCoverage.php | 16 +- .../Configuration/Xml/Configuration.php | 10 +- .../Xml/DefaultConfiguration.php | 37 +- .../TextUI/Configuration/Xml/Generator.php | 8 +- .../Xml/LoadedFromFileConfiguration.php | 7 +- .../src/TextUI/Configuration/Xml/Loader.php | 219 ++- .../Xml/Migration/MigrationBuilder.php | 10 +- .../Migrations/IntroduceCoverageElement.php | 2 +- .../Migrations/LogToReportMigration.php | 2 +- .../MoveCoverageDirectoriesToSource.php | 54 + .../MoveWhitelistExcludesToCoverage.php | 3 +- ...hp => MoveWhitelistIncludesToCoverage.php} | 9 +- .../Migration/Migrations/RemoveLogTypes.php | 1 - .../Migrations/UpdateSchemaLocation.php | 2 +- .../Configuration/Xml/Migration/Migrator.php | 10 +- .../Xml/Migration}/SnapshotNodeList.php | 2 +- .../src/TextUI/Configuration/Xml/PHPUnit.php | 70 +- .../FailedSchemaDetectionResult.php | 2 +- .../SchemaDetector}/SchemaDetectionResult.php | 4 +- .../Xml/SchemaDetector}/SchemaDetector.php | 14 +- .../SuccessfulSchemaDetectionResult.php | 2 +- .../Configuration}/Xml/SchemaFinder.php | 12 +- .../Configuration/Xml/TestSuiteMapper.php | 50 +- .../Xml/Validator}/ValidationResult.php | 2 +- .../Xml/Validator}/Validator.php | 2 +- .../DirectoryDoesNotExistException.php | 6 +- .../Exception/InvalidSocketException.php | 6 +- .../TestDirectoryNotFoundException.php | 4 +- .../Exception/TestFileNotFoundException.php | 4 +- vendor/phpunit/phpunit/src/TextUI/Help.php | 89 +- .../ProgressPrinter/ProgressPrinter.php | 143 +- .../TestTriggeredDeprecationSubscriber.php | 2 +- .../TestTriggeredErrorSubscriber.php} | 12 +- .../TestTriggeredNoticeSubscriber.php | 2 +- .../TestTriggeredPhpDeprecationSubscriber.php | 2 +- .../TestTriggeredPhpNoticeSubscriber.php | 2 +- .../TestTriggeredPhpWarningSubscriber.php | 2 +- ...tTriggeredPhpunitDeprecationSubscriber.php | 2 +- .../TestTriggeredPhpunitWarningSubscriber.php | 2 +- .../TestTriggeredWarningSubscriber.php | 2 +- .../TextUI/Output/Default/ResultPrinter.php | 549 +++--- .../Default/UnexpectedOutputPrinter.php | 38 + .../phpunit/src/TextUI/Output/Facade.php | 229 ++- .../TextUI/Output/Printer/DefaultPrinter.php | 8 +- .../src/TextUI/Output/SummaryPrinter.php | 63 +- .../TextUI/Output/TestDox/ResultPrinter.php | 50 +- .../src/TextUI/ShellExitCodeCalculator.php | 28 +- .../phpunit/phpunit/src/TextUI/TestRunner.php | 8 +- .../src/TextUI/TestSuiteFilterProcessor.php | 16 +- vendor/phpunit/phpunit/src/Util/Color.php | 6 +- .../Exception/InvalidDirectoryException.php | 4 +- .../InvalidVersionOperatorException.php | 4 +- .../phpunit/phpunit/src/Util/ExcludeList.php | 15 +- vendor/phpunit/phpunit/src/Util/Exporter.php | 61 + .../phpunit/phpunit/src/Util/Filesystem.php | 2 +- vendor/phpunit/phpunit/src/Util/Filter.php | 6 +- .../phpunit/phpunit/src/Util/GlobalState.php | 92 +- .../src/Util/PHP/AbstractPhpProcess.php | 104 +- .../src/Util/PHP/DefaultPhpProcess.php | 91 +- .../src/Util/PHP/Template/TestCaseClass.tpl | 41 +- .../src/Util/PHP/Template/TestCaseMethod.tpl | 41 +- .../src/Util/PHP/WindowsPhpProcess.php | 2 +- .../phpunit/phpunit/src/Util/Reflection.php | 41 +- vendor/phpunit/phpunit/src/Util/Test.php | 2 +- .../phpunit/phpunit/src/Util/Xml/Loader.php | 55 +- .../phpunit/src/Util/{ => Xml}/Xml.php | 4 +- vendor/psr/http-client/CHANGELOG.md | 8 + vendor/psr/http-client/composer.json | 3 + vendor/sebastian/complexity/ChangeLog.md | 13 + vendor/sebastian/complexity/composer.json | 2 +- .../complexity/src/Complexity/Complexity.php | 12 + .../src/Complexity/ComplexityCollection.php | 37 + .../Visitor/ComplexityCalculatingVisitor.php | 6 + vendor/sebastian/exporter/ChangeLog.md | 7 + vendor/sebastian/exporter/composer.json | 2 +- vendor/sebastian/exporter/src/Exporter.php | 40 +- vendor/symfony/console/README.md | 13 +- vendor/theseer/tokenizer/.php_cs.dist | 213 --- vendor/theseer/tokenizer/CHANGELOG.md | 6 + vendor/theseer/tokenizer/README.md | 3 - vendor/theseer/tokenizer/src/Tokenizer.php | 21 +- 596 files changed, 16907 insertions(+), 10021 deletions(-) delete mode 100644 vendor/nikic/php-parser/grammar/README.md delete mode 100644 vendor/nikic/php-parser/grammar/parser.template delete mode 100644 vendor/nikic/php-parser/grammar/php5.y delete mode 100644 vendor/nikic/php-parser/grammar/php7.y delete mode 100644 vendor/nikic/php-parser/grammar/phpyLang.php delete mode 100644 vendor/nikic/php-parser/grammar/rebuildParsers.php delete mode 100644 vendor/nikic/php-parser/grammar/tokens.template delete mode 100644 vendor/nikic/php-parser/grammar/tokens.y create mode 100644 vendor/phpcsstandards/phpcsextra/Universal/Docs/CodeAnalysis/NoDoubleNegativeStandard.xml create mode 100644 vendor/phpcsstandards/phpcsextra/Universal/Docs/Operators/ConcatPositionStandard.xml create mode 100644 vendor/phpcsstandards/phpcsextra/Universal/Docs/PHP/LowercasePHPTagStandard.xml create mode 100644 vendor/phpcsstandards/phpcsextra/Universal/Sniffs/CodeAnalysis/NoDoubleNegativeSniff.php create mode 100644 vendor/phpcsstandards/phpcsextra/Universal/Sniffs/Operators/ConcatPositionSniff.php create mode 100644 vendor/phpcsstandards/phpcsextra/Universal/Sniffs/PHP/LowercasePHPTagSniff.php delete mode 100644 vendor/phpunit/phpunit/ChangeLog-10.0.md create mode 100644 vendor/phpunit/phpunit/ChangeLog-10.5.md delete mode 100644 vendor/phpunit/phpunit/ChangeLog-8.5.md delete mode 100644 vendor/phpunit/phpunit/ChangeLog-9.6.md create mode 100644 vendor/phpunit/phpunit/DEPRECATIONS.md create mode 100644 vendor/phpunit/phpunit/composer.lock create mode 100644 vendor/phpunit/phpunit/schema/10.0.xsd create mode 100644 vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodCalled.php create mode 100644 vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodCalledSubscriber.php create mode 100644 vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodFinished.php create mode 100644 vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodFinishedSubscriber.php create mode 100644 vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/PreparationFailed.php create mode 100644 vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/PreparationFailedSubscriber.php create mode 100644 vendor/phpunit/phpunit/src/Event/Events/Test/PrintedUnexpectedOutput.php create mode 100644 vendor/phpunit/phpunit/src/Event/Events/Test/PrintedUnexpectedOutputSubscriber.php create mode 100644 vendor/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionAborted.php create mode 100644 vendor/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionAbortedSubscriber.php create mode 100644 vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionDisabled.php create mode 100644 vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionDisabledSubscriber.php create mode 100644 vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionEnabled.php create mode 100644 vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionEnabledSubscriber.php create mode 100644 vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionTriggered.php create mode 100644 vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionTriggeredSubscriber.php create mode 100644 vendor/phpunit/phpunit/src/Event/Events/TestSuite/Skipped.php create mode 100644 vendor/phpunit/phpunit/src/Event/Events/TestSuite/SkippedSubscriber.php rename vendor/phpunit/phpunit/src/{Util => Event}/Exception/NoTestCaseObjectOnCallStackException.php (90%) create mode 100644 vendor/phpunit/phpunit/src/Event/Value/ComparisonFailureBuilder.php create mode 100644 vendor/phpunit/phpunit/src/Event/Value/Telemetry/GarbageCollectorStatus.php create mode 100644 vendor/phpunit/phpunit/src/Event/Value/Telemetry/GarbageCollectorStatusProvider.php create mode 100644 vendor/phpunit/phpunit/src/Event/Value/Telemetry/Php81GarbageCollectorStatusProvider.php create mode 100644 vendor/phpunit/phpunit/src/Event/Value/Telemetry/Php83GarbageCollectorStatusProvider.php create mode 100644 vendor/phpunit/phpunit/src/Event/Value/Test/TestDoxBuilder.php create mode 100644 vendor/phpunit/phpunit/src/Event/Value/Test/TestMethodBuilder.php create mode 100644 vendor/phpunit/phpunit/src/Event/Value/TestSuite/TestSuiteBuilder.php create mode 100644 vendor/phpunit/phpunit/src/Event/Value/ThrowableBuilder.php create mode 100644 vendor/phpunit/phpunit/src/Framework/Attributes/IgnoreClassForCodeCoverage.php create mode 100644 vendor/phpunit/phpunit/src/Framework/Attributes/IgnoreDeprecations.php create mode 100644 vendor/phpunit/phpunit/src/Framework/Attributes/IgnoreFunctionForCodeCoverage.php create mode 100644 vendor/phpunit/phpunit/src/Framework/Attributes/IgnoreMethodForCodeCoverage.php create mode 100644 vendor/phpunit/phpunit/src/Framework/Attributes/WithoutErrorHandler.php rename vendor/phpunit/phpunit/src/Framework/Constraint/{Message/MessageIsOrContains.php => Exception/ExceptionMessageIsOrContains.php} (65%) rename vendor/phpunit/phpunit/src/Framework/Constraint/{Message/MessageMatchesRegularExpression.php => Exception/ExceptionMessageMatchesRegularExpression.php} (66%) delete mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/JsonMatchesErrorMessageProvider.php rename vendor/phpunit/phpunit/src/Framework/Constraint/{ => Object}/ObjectEquals.php (92%) create mode 100644 vendor/phpunit/phpunit/src/Framework/Constraint/Object/ObjectHasProperty.php rename vendor/phpunit/phpunit/src/Framework/Exception/{UnknownClassException.php => UnknownTypeException.php} (78%) create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Exception/NeverReturningMethodException.php rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Generator}/Exception/ClassAlreadyExistsException.php (87%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Generator}/Exception/ClassIsEnumerationException.php (87%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Generator}/Exception/ClassIsFinalException.php (87%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Generator}/Exception/ClassIsReadonlyException.php (87%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Generator}/Exception/DuplicateMethodException.php (90%) create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/Exception.php rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Generator}/Exception/InvalidMethodNameException.php (87%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Generator}/Exception/OriginalConstructorInvocationRequiredException.php (92%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{Exception/ConfigurableMethodsAlreadyInitializedException.php => Generator/Exception/ReflectionException.php} (69%) rename vendor/phpunit/phpunit/src/{Metadata/CodeCoverageIgnore.php => Framework/MockObject/Generator/Exception/RuntimeException.php} (66%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Generator}/Exception/SoapExtensionNotAvailableException.php (89%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Generator}/Exception/UnknownClassException.php (87%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Generator}/Exception/UnknownTraitException.php (79%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Generator}/Exception/UnknownTypeException.php (88%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Generator}/Generator.php (75%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Generator}/MockClass.php (91%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Generator}/MockMethod.php (75%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Generator}/MockMethodSet.php (95%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Generator}/MockTrait.php (88%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Generator}/MockType.php (90%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Generator}/TemplateLoader.php (56%) delete mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Generator/mocked_class.tpl delete mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Generator/mocked_method_never_or_void.tpl delete mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Generator/proxied_method_never_or_void.tpl rename vendor/phpunit/phpunit/src/Framework/MockObject/Generator/{ => templates}/deprecation.tpl (100%) rename vendor/phpunit/phpunit/src/Framework/MockObject/Generator/{mocked_method.tpl => templates/doubled_method.tpl} (94%) rename vendor/phpunit/phpunit/src/Framework/MockObject/Generator/{mocked_static_method.tpl => templates/doubled_static_method.tpl} (100%) rename vendor/phpunit/phpunit/src/Framework/MockObject/Generator/{ => templates}/intersection.tpl (100%) rename vendor/phpunit/phpunit/src/Framework/MockObject/Generator/{ => templates}/proxied_method.tpl (84%) create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/test_double_class.tpl rename vendor/phpunit/phpunit/src/Framework/MockObject/Generator/{ => templates}/trait_class.tpl (100%) rename vendor/phpunit/phpunit/src/Framework/MockObject/Generator/{ => templates}/wsdl_class.tpl (100%) rename vendor/phpunit/phpunit/src/Framework/MockObject/Generator/{ => templates}/wsdl_method.tpl (100%) delete mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Invocation.php rename vendor/phpunit/phpunit/src/Framework/MockObject/{Api/MockedCloneMethod.php => Runtime/Api/DoubledCloneMethod.php} (95%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Api/Method.php (96%) create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/MockObjectApi.php rename vendor/phpunit/phpunit/src/Framework/MockObject/{Api/UnmockedCloneMethod.php => Runtime/Api/ProxiedCloneMethod.php} (95%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{Api/Api.php => Runtime/Api/StubApi.php} (55%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Builder/Identity.php (100%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Builder/InvocationMocker.php (80%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Builder/InvocationStubber.php (100%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Builder/MethodNameMatch.php (100%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Builder/ParametersMatch.php (100%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Builder/Stub.php (100%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime/Interface}/MockObject.php (56%) create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/MockObjectInternal.php rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime/Interface}/Stub.php (71%) create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/StubInternal.php create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Invocation.php rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/InvocationHandler.php (86%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Matcher.php (82%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/MethodNameConstraint.php (81%) create mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/ReturnValueGenerator.php rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Rule/AnyInvokedCount.php (100%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Rule/AnyParameters.php (87%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Rule/InvocationOrder.php (90%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Rule/InvokedAtLeastCount.php (65%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Rule/InvokedAtLeastOnce.php (99%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Rule/InvokedAtMostCount.php (65%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Rule/InvokedCount.php (78%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Rule/MethodName.php (100%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Rule/Parameters.php (90%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Rule/ParametersRule.php (83%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Stub/ConsecutiveCalls.php (59%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Stub/Exception.php (73%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Stub/ReturnArgument.php (84%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Stub/ReturnCallback.php (51%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Stub/ReturnReference.php (72%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Stub/ReturnSelf.php (87%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Stub/ReturnStub.php (72%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Stub/ReturnValueMap.php (92%) rename vendor/phpunit/phpunit/src/Framework/MockObject/{ => Runtime}/Stub/Stub.php (89%) delete mode 100644 vendor/phpunit/phpunit/src/Framework/MockObject/Verifiable.php create mode 100644 vendor/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestPreparationFailedSubscriber.php create mode 100644 vendor/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestPreparationStartedSubscriber.php delete mode 100644 vendor/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestCreatedMockObjectForAbstractClassSubscriber.php delete mode 100644 vendor/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestCreatedMockObjectForTraitSubscriber.php delete mode 100644 vendor/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestCreatedMockObjectFromWsdlSubscriber.php delete mode 100644 vendor/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestCreatedPartialMockObjectSubscriber.php delete mode 100644 vendor/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestCreatedTestProxySubscriber.php rename vendor/phpunit/phpunit/src/Logging/TestDox/{ => TestResult}/Subscriber/Subscriber.php (100%) rename vendor/phpunit/phpunit/src/Logging/TestDox/{ => TestResult}/Subscriber/TestConsideredRiskySubscriber.php (100%) rename vendor/phpunit/phpunit/src/Logging/TestDox/{ => TestResult}/Subscriber/TestErroredSubscriber.php (100%) rename vendor/phpunit/phpunit/src/Logging/TestDox/{ => TestResult}/Subscriber/TestFailedSubscriber.php (100%) rename vendor/phpunit/phpunit/src/Logging/TestDox/{ => TestResult}/Subscriber/TestFinishedSubscriber.php (100%) rename vendor/phpunit/phpunit/src/Logging/TestDox/{ => TestResult}/Subscriber/TestMarkedIncompleteSubscriber.php (100%) rename vendor/phpunit/phpunit/src/Logging/TestDox/{ => TestResult}/Subscriber/TestPassedSubscriber.php (100%) rename vendor/phpunit/phpunit/src/Logging/TestDox/{ => TestResult}/Subscriber/TestPreparedSubscriber.php (100%) rename vendor/phpunit/phpunit/src/Logging/TestDox/{ => TestResult}/Subscriber/TestSkippedSubscriber.php (100%) rename vendor/phpunit/phpunit/src/Logging/TestDox/{TestMethod => TestResult}/TestResult.php (56%) rename vendor/phpunit/phpunit/src/Logging/TestDox/{TestMethod => TestResult}/TestResultCollection.php (100%) rename vendor/phpunit/phpunit/src/Logging/TestDox/{TestMethod => TestResult}/TestResultCollectionIterator.php (100%) rename vendor/phpunit/phpunit/src/Logging/TestDox/{TestMethod => TestResult}/TestResultCollector.php (66%) rename vendor/phpunit/phpunit/src/{Runner/Exception/ClassCannotBeInstantiatedException.php => Metadata/Exception/AnnotationsAreNotSupportedForInternalClassesException.php} (57%) create mode 100644 vendor/phpunit/phpunit/src/Metadata/IgnoreClassForCodeCoverage.php create mode 100644 vendor/phpunit/phpunit/src/Metadata/IgnoreDeprecations.php create mode 100644 vendor/phpunit/phpunit/src/Metadata/IgnoreFunctionForCodeCoverage.php create mode 100644 vendor/phpunit/phpunit/src/Metadata/IgnoreMethodForCodeCoverage.php create mode 100644 vendor/phpunit/phpunit/src/Metadata/WithoutErrorHandler.php create mode 100644 vendor/phpunit/phpunit/src/Runner/Baseline/Baseline.php create mode 100644 vendor/phpunit/phpunit/src/Runner/Baseline/Exception/CannotLoadBaselineException.php rename vendor/phpunit/phpunit/src/Runner/{Exception/ClassDoesNotExistException.php => Baseline/Exception/FileDoesNotHaveLineException.php} (59%) create mode 100644 vendor/phpunit/phpunit/src/Runner/Baseline/Generator.php create mode 100644 vendor/phpunit/phpunit/src/Runner/Baseline/Issue.php create mode 100644 vendor/phpunit/phpunit/src/Runner/Baseline/Reader.php create mode 100644 vendor/phpunit/phpunit/src/Runner/Baseline/RelativePathCalculator.php create mode 100644 vendor/phpunit/phpunit/src/Runner/Baseline/Subscriber/Subscriber.php create mode 100644 vendor/phpunit/phpunit/src/Runner/Baseline/Subscriber/TestTriggeredDeprecationSubscriber.php create mode 100644 vendor/phpunit/phpunit/src/Runner/Baseline/Subscriber/TestTriggeredNoticeSubscriber.php create mode 100644 vendor/phpunit/phpunit/src/Runner/Baseline/Subscriber/TestTriggeredPhpDeprecationSubscriber.php create mode 100644 vendor/phpunit/phpunit/src/Runner/Baseline/Subscriber/TestTriggeredPhpNoticeSubscriber.php create mode 100644 vendor/phpunit/phpunit/src/Runner/Baseline/Subscriber/TestTriggeredPhpWarningSubscriber.php create mode 100644 vendor/phpunit/phpunit/src/Runner/Baseline/Subscriber/TestTriggeredWarningSubscriber.php create mode 100644 vendor/phpunit/phpunit/src/Runner/Baseline/Writer.php rename vendor/phpunit/phpunit/src/{Util => Runner}/ErrorHandler.php (61%) rename vendor/phpunit/phpunit/src/Runner/Exception/{ClassDoesNotImplementExtensionInterfaceException.php => ClassDoesNotExtendTestCaseException.php} (63%) create mode 100644 vendor/phpunit/phpunit/src/Runner/Filter/TestIdFilterIterator.php create mode 100644 vendor/phpunit/phpunit/src/Runner/GarbageCollection/GarbageCollectionHandler.php create mode 100644 vendor/phpunit/phpunit/src/Runner/GarbageCollection/Subscriber/ExecutionFinishedSubscriber.php create mode 100644 vendor/phpunit/phpunit/src/Runner/GarbageCollection/Subscriber/ExecutionStartedSubscriber.php rename vendor/phpunit/phpunit/src/{Logging/TestDox/Subscriber/TestCreatedTestStubSubscriber.php => Runner/GarbageCollection/Subscriber/Subscriber.php} (52%) create mode 100644 vendor/phpunit/phpunit/src/Runner/GarbageCollection/Subscriber/TestFinishedSubscriber.php create mode 100644 vendor/phpunit/phpunit/src/Runner/TestResult/Issue.php create mode 100644 vendor/phpunit/phpunit/src/Runner/TestResult/Subscriber/TestSuiteSkippedSubscriber.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/Configuration/Exception/CannotFindSchemaException.php rename vendor/phpunit/phpunit/src/{Util/Xml/Exception.php => TextUI/Configuration/Exception/NoBaselineException.php} (76%) rename vendor/phpunit/phpunit/src/{Framework/Exception/Error.php => TextUI/Configuration/SourceFilter.php} (60%) create mode 100644 vendor/phpunit/phpunit/src/TextUI/Configuration/SourceMapper.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/Configuration/Value/Source.php create mode 100644 vendor/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/MoveCoverageDirectoriesToSource.php rename vendor/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/{MoveWhitelistDirectoriesToCoverage.php => MoveWhitelistIncludesToCoverage.php} (83%) rename vendor/phpunit/phpunit/src/{Util/Xml => TextUI/Configuration/Xml/Migration}/SnapshotNodeList.php (96%) rename vendor/phpunit/phpunit/src/{Util/Xml => TextUI/Configuration/Xml/SchemaDetector}/FailedSchemaDetectionResult.php (91%) rename vendor/phpunit/phpunit/src/{Util/Xml => TextUI/Configuration/Xml/SchemaDetector}/SchemaDetectionResult.php (89%) rename vendor/phpunit/phpunit/src/{Util/Xml => TextUI/Configuration/Xml/SchemaDetector}/SchemaDetector.php (77%) rename vendor/phpunit/phpunit/src/{Util/Xml => TextUI/Configuration/Xml/SchemaDetector}/SuccessfulSchemaDetectionResult.php (94%) rename vendor/phpunit/phpunit/src/{Util => TextUI/Configuration}/Xml/SchemaFinder.php (82%) rename vendor/phpunit/phpunit/src/{Util/Xml => TextUI/Configuration/Xml/Validator}/ValidationResult.php (97%) rename vendor/phpunit/phpunit/src/{Util/Xml => TextUI/Configuration/Xml/Validator}/Validator.php (95%) rename vendor/phpunit/phpunit/src/{Util => TextUI}/Exception/DirectoryDoesNotExistException.php (90%) rename vendor/phpunit/phpunit/src/{Util => TextUI}/Exception/InvalidSocketException.php (91%) rename vendor/phpunit/phpunit/src/{Logging/TestDox/Subscriber/TestCreatedMockObjectSubscriber.php => TextUI/Output/Default/ProgressPrinter/Subscriber/TestTriggeredErrorSubscriber.php} (51%) create mode 100644 vendor/phpunit/phpunit/src/TextUI/Output/Default/UnexpectedOutputPrinter.php create mode 100644 vendor/phpunit/phpunit/src/Util/Exporter.php rename vendor/phpunit/phpunit/src/Util/{ => Xml}/Xml.php (97%) delete mode 100644 vendor/theseer/tokenizer/.php_cs.dist diff --git a/composer.json b/composer.json index 2016f8de..727c02d4 100644 --- a/composer.json +++ b/composer.json @@ -12,7 +12,7 @@ "require-dev": { "dealerdirect/phpcodesniffer-composer-installer": "^1.0", "wp-coding-standards/wpcs": "^3.0", - "phpunit/phpunit": "10", + "phpunit/phpunit": "^10.5", "marcocesarato/php-conventional-changelog": "^1.17" }, "config": { diff --git a/composer.lock b/composer.lock index 82d05f1d..b530943b 100644 --- a/composer.lock +++ b/composer.lock @@ -4,20 +4,20 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "1962984bdea78a0680e7a349f6809b8a", + "content-hash": "4384b20b3f11062da469aea341c2b804", "packages": [ { "name": "composer/ca-bundle", - "version": "1.3.7", + "version": "1.4.0", "source": { "type": "git", "url": "https://github.com/composer/ca-bundle.git", - "reference": "76e46335014860eec1aa5a724799a00a2e47cc85" + "reference": "b66d11b7479109ab547f9405b97205640b17d385" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/ca-bundle/zipball/76e46335014860eec1aa5a724799a00a2e47cc85", - "reference": "76e46335014860eec1aa5a724799a00a2e47cc85", + "url": "https://api.github.com/repos/composer/ca-bundle/zipball/b66d11b7479109ab547f9405b97205640b17d385", + "reference": "b66d11b7479109ab547f9405b97205640b17d385", "shasum": "" }, "require": { @@ -29,7 +29,7 @@ "phpstan/phpstan": "^0.12.55", "psr/log": "^1.0", "symfony/phpunit-bridge": "^4.2 || ^5", - "symfony/process": "^2.5 || ^3.0 || ^4.0 || ^5.0 || ^6.0" + "symfony/process": "^2.5 || ^3.0 || ^4.0 || ^5.0 || ^6.0 || ^7.0" }, "type": "library", "extra": { @@ -64,7 +64,7 @@ "support": { "irc": "irc://irc.freenode.org/composer", "issues": "https://github.com/composer/ca-bundle/issues", - "source": "https://github.com/composer/ca-bundle/tree/1.3.7" + "source": "https://github.com/composer/ca-bundle/tree/1.4.0" }, "funding": [ { @@ -80,20 +80,20 @@ "type": "tidelift" } ], - "time": "2023-08-30T09:31:38+00:00" + "time": "2023-12-18T12:05:55+00:00" }, { "name": "embed/embed", - "version": "v4.4.8", + "version": "v4.4.10", "source": { "type": "git", "url": "https://github.com/oscarotero/Embed.git", - "reference": "49134080764018bc6b8a2488dd1c8cc2c47d15fc" + "reference": "8ac21505d048e8796c6cb9172ec5e81e5d0e0408" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/oscarotero/Embed/zipball/49134080764018bc6b8a2488dd1c8cc2c47d15fc", - "reference": "49134080764018bc6b8a2488dd1c8cc2c47d15fc", + "url": "https://api.github.com/repos/oscarotero/Embed/zipball/8ac21505d048e8796c6cb9172ec5e81e5d0e0408", + "reference": "8ac21505d048e8796c6cb9172ec5e81e5d0e0408", "shasum": "" }, "require": { @@ -153,7 +153,7 @@ "support": { "email": "oom@oscarotero.com", "issues": "https://github.com/oscarotero/Embed/issues", - "source": "https://github.com/oscarotero/Embed/tree/v4.4.8" + "source": "https://github.com/oscarotero/Embed/tree/v4.4.10" }, "funding": [ { @@ -169,7 +169,7 @@ "type": "patreon" } ], - "time": "2023-05-22T18:48:30+00:00" + "time": "2023-12-10T12:30:47+00:00" }, { "name": "erusev/parsedown", @@ -427,16 +427,16 @@ }, { "name": "gettext/translator", - "version": "v1.1.1", + "version": "v1.2.0", "source": { "type": "git", "url": "https://github.com/php-gettext/Translator.git", - "reference": "b18ff33e8203de623854561f5e47e992fc5c50bb" + "reference": "a4fa5ed740f304a0ed7b3e169b2b554a195c7570" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-gettext/Translator/zipball/b18ff33e8203de623854561f5e47e992fc5c50bb", - "reference": "b18ff33e8203de623854561f5e47e992fc5c50bb", + "url": "https://api.github.com/repos/php-gettext/Translator/zipball/a4fa5ed740f304a0ed7b3e169b2b554a195c7570", + "reference": "a4fa5ed740f304a0ed7b3e169b2b554a195c7570", "shasum": "" }, "require": { @@ -481,7 +481,7 @@ "support": { "email": "oom@oscarotero.com", "issues": "https://github.com/php-gettext/Translator/issues", - "source": "https://github.com/php-gettext/Translator/tree/v1.1.1" + "source": "https://github.com/php-gettext/Translator/tree/v1.2.0" }, "funding": [ { @@ -497,7 +497,7 @@ "type": "patreon" } ], - "time": "2022-02-23T20:29:40+00:00" + "time": "2023-11-06T15:42:03+00:00" }, { "name": "grandel/include-directory", @@ -697,16 +697,16 @@ }, { "name": "oscarotero/html-parser", - "version": "v0.1.7", + "version": "v0.1.8", "source": { "type": "git", "url": "https://github.com/oscarotero/html-parser.git", - "reference": "0c5b619bdc7ac061f06a667d913e2af708ee3231" + "reference": "10f3219267a365d9433f2f7d1694209c9d436c8d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/oscarotero/html-parser/zipball/0c5b619bdc7ac061f06a667d913e2af708ee3231", - "reference": "0c5b619bdc7ac061f06a667d913e2af708ee3231", + "url": "https://api.github.com/repos/oscarotero/html-parser/zipball/10f3219267a365d9433f2f7d1694209c9d436c8d", + "reference": "10f3219267a365d9433f2f7d1694209c9d436c8d", "shasum": "" }, "require": { @@ -744,22 +744,22 @@ "support": { "email": "oom@oscarotero.com", "issues": "https://github.com/oscarotero/html-parser/issues", - "source": "https://github.com/oscarotero/html-parser/tree/v0.1.7" + "source": "https://github.com/oscarotero/html-parser/tree/v0.1.8" }, - "time": "2022-12-17T09:48:58+00:00" + "time": "2023-11-29T20:28:41+00:00" }, { "name": "psr/http-client", - "version": "1.0.2", + "version": "1.0.3", "source": { "type": "git", "url": "https://github.com/php-fig/http-client.git", - "reference": "0955afe48220520692d2d09f7ab7e0f93ffd6a31" + "reference": "bb5906edc1c324c9a05aa0873d40117941e5fa90" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/http-client/zipball/0955afe48220520692d2d09f7ab7e0f93ffd6a31", - "reference": "0955afe48220520692d2d09f7ab7e0f93ffd6a31", + "url": "https://api.github.com/repos/php-fig/http-client/zipball/bb5906edc1c324c9a05aa0873d40117941e5fa90", + "reference": "bb5906edc1c324c9a05aa0873d40117941e5fa90", "shasum": "" }, "require": { @@ -796,9 +796,9 @@ "psr-18" ], "support": { - "source": "https://github.com/php-fig/http-client/tree/1.0.2" + "source": "https://github.com/php-fig/http-client" }, - "time": "2023-04-10T20:12:12+00:00" + "time": "2023-09-23T14:17:50+00:00" }, { "name": "psr/http-factory", @@ -1380,16 +1380,16 @@ }, { "name": "nikic/php-parser", - "version": "v4.17.1", + "version": "v4.18.0", "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d" + "reference": "1bcbb2179f97633e98bbbc87044ee2611c7d7999" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d", - "reference": "a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/1bcbb2179f97633e98bbbc87044ee2611c7d7999", + "reference": "1bcbb2179f97633e98bbbc87044ee2611c7d7999", "shasum": "" }, "require": { @@ -1430,9 +1430,9 @@ ], "support": { "issues": "https://github.com/nikic/PHP-Parser/issues", - "source": "https://github.com/nikic/PHP-Parser/tree/v4.17.1" + "source": "https://github.com/nikic/PHP-Parser/tree/v4.18.0" }, - "time": "2023-08-13T19:53:39+00:00" + "time": "2023-12-10T21:03:43+00:00" }, { "name": "phar-io/manifest", @@ -1547,29 +1547,29 @@ }, { "name": "phpcsstandards/phpcsextra", - "version": "1.1.1", + "version": "1.2.1", "source": { "type": "git", "url": "https://github.com/PHPCSStandards/PHPCSExtra.git", - "reference": "98bcdbacbda14b1db85f710b1853125726795bbc" + "reference": "11d387c6642b6e4acaf0bd9bf5203b8cca1ec489" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/PHPCSStandards/PHPCSExtra/zipball/98bcdbacbda14b1db85f710b1853125726795bbc", - "reference": "98bcdbacbda14b1db85f710b1853125726795bbc", + "url": "https://api.github.com/repos/PHPCSStandards/PHPCSExtra/zipball/11d387c6642b6e4acaf0bd9bf5203b8cca1ec489", + "reference": "11d387c6642b6e4acaf0bd9bf5203b8cca1ec489", "shasum": "" }, "require": { "php": ">=5.4", - "phpcsstandards/phpcsutils": "^1.0.8", - "squizlabs/php_codesniffer": "^3.7.1" + "phpcsstandards/phpcsutils": "^1.0.9", + "squizlabs/php_codesniffer": "^3.8.0" }, "require-dev": { "php-parallel-lint/php-console-highlighter": "^1.0", "php-parallel-lint/php-parallel-lint": "^1.3.2", "phpcsstandards/phpcsdevcs": "^1.1.6", "phpcsstandards/phpcsdevtools": "^1.2.1", - "phpunit/phpunit": "^4.5 || ^5.0 || ^6.0 || ^7.0" + "phpunit/phpunit": "^4.5 || ^5.0 || ^6.0 || ^7.0 || ^8.0 || ^9.0" }, "type": "phpcodesniffer-standard", "extra": { @@ -1604,35 +1604,50 @@ ], "support": { "issues": "https://github.com/PHPCSStandards/PHPCSExtra/issues", + "security": "https://github.com/PHPCSStandards/PHPCSExtra/security/policy", "source": "https://github.com/PHPCSStandards/PHPCSExtra" }, - "time": "2023-08-26T04:46:45+00:00" + "funding": [ + { + "url": "https://github.com/PHPCSStandards", + "type": "github" + }, + { + "url": "https://github.com/jrfnl", + "type": "github" + }, + { + "url": "https://opencollective.com/php_codesniffer", + "type": "open_collective" + } + ], + "time": "2023-12-08T16:49:07+00:00" }, { "name": "phpcsstandards/phpcsutils", - "version": "1.0.8", + "version": "1.0.9", "source": { "type": "git", "url": "https://github.com/PHPCSStandards/PHPCSUtils.git", - "reference": "69465cab9d12454e5e7767b9041af0cd8cd13be7" + "reference": "908247bc65010c7b7541a9551e002db12e9dae70" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/PHPCSStandards/PHPCSUtils/zipball/69465cab9d12454e5e7767b9041af0cd8cd13be7", - "reference": "69465cab9d12454e5e7767b9041af0cd8cd13be7", + "url": "https://api.github.com/repos/PHPCSStandards/PHPCSUtils/zipball/908247bc65010c7b7541a9551e002db12e9dae70", + "reference": "908247bc65010c7b7541a9551e002db12e9dae70", "shasum": "" }, "require": { "dealerdirect/phpcodesniffer-composer-installer": "^0.4.1 || ^0.5 || ^0.6.2 || ^0.7 || ^1.0", "php": ">=5.4", - "squizlabs/php_codesniffer": "^3.7.1 || 4.0.x-dev@dev" + "squizlabs/php_codesniffer": "^3.8.0 || 4.0.x-dev@dev" }, "require-dev": { "ext-filter": "*", "php-parallel-lint/php-console-highlighter": "^1.0", "php-parallel-lint/php-parallel-lint": "^1.3.2", "phpcsstandards/phpcsdevcs": "^1.1.6", - "yoast/phpunit-polyfills": "^1.0.5 || ^2.0.0" + "yoast/phpunit-polyfills": "^1.1.0 || ^2.0.0" }, "type": "phpcodesniffer-standard", "extra": { @@ -1677,22 +1692,37 @@ "support": { "docs": "https://phpcsutils.com/", "issues": "https://github.com/PHPCSStandards/PHPCSUtils/issues", + "security": "https://github.com/PHPCSStandards/PHPCSUtils/security/policy", "source": "https://github.com/PHPCSStandards/PHPCSUtils" }, - "time": "2023-07-16T21:39:41+00:00" + "funding": [ + { + "url": "https://github.com/PHPCSStandards", + "type": "github" + }, + { + "url": "https://github.com/jrfnl", + "type": "github" + }, + { + "url": "https://opencollective.com/php_codesniffer", + "type": "open_collective" + } + ], + "time": "2023-12-08T14:50:00+00:00" }, { "name": "phpunit/php-code-coverage", - "version": "10.1.6", + "version": "10.1.10", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "56f33548fe522c8d82da7ff3824b42829d324364" + "reference": "599109c8ca6bae97b23482d557d2874c25a65e59" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/56f33548fe522c8d82da7ff3824b42829d324364", - "reference": "56f33548fe522c8d82da7ff3824b42829d324364", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/599109c8ca6bae97b23482d557d2874c25a65e59", + "reference": "599109c8ca6bae97b23482d557d2874c25a65e59", "shasum": "" }, "require": { @@ -1749,7 +1779,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", "security": "https://github.com/sebastianbergmann/php-code-coverage/security/policy", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/10.1.6" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/10.1.10" }, "funding": [ { @@ -1757,7 +1787,7 @@ "type": "github" } ], - "time": "2023-09-19T04:59:03+00:00" + "time": "2023-12-11T06:28:43+00:00" }, { "name": "phpunit/php-file-iterator", @@ -2004,16 +2034,16 @@ }, { "name": "phpunit/phpunit", - "version": "10.0.0", + "version": "10.5.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "c4c60c34c0e92045afce938510f8878d7cd84f8a" + "reference": "6fce887c71076a73f32fd3e0774a6833fc5c7f19" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/c4c60c34c0e92045afce938510f8878d7cd84f8a", - "reference": "c4c60c34c0e92045afce938510f8878d7cd84f8a", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/6fce887c71076a73f32fd3e0774a6833fc5c7f19", + "reference": "6fce887c71076a73f32fd3e0774a6833fc5c7f19", "shasum": "" }, "require": { @@ -2027,7 +2057,7 @@ "phar-io/manifest": "^2.0.3", "phar-io/version": "^3.0.2", "php": ">=8.1", - "phpunit/php-code-coverage": "^10.0", + "phpunit/php-code-coverage": "^10.1.5", "phpunit/php-file-iterator": "^4.0", "phpunit/php-invoker": "^4.0", "phpunit/php-text-template": "^3.0", @@ -2037,15 +2067,15 @@ "sebastian/comparator": "^5.0", "sebastian/diff": "^5.0", "sebastian/environment": "^6.0", - "sebastian/exporter": "^5.0", - "sebastian/global-state": "^6.0", + "sebastian/exporter": "^5.1", + "sebastian/global-state": "^6.0.1", "sebastian/object-enumerator": "^5.0", "sebastian/recursion-context": "^5.0", "sebastian/type": "^4.0", "sebastian/version": "^4.0" }, "suggest": { - "ext-soap": "*" + "ext-soap": "To be able to generate mocks based on WSDL files" }, "bin": [ "phpunit" @@ -2053,7 +2083,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "10.0-dev" + "dev-main": "10.5-dev" } }, "autoload": { @@ -2084,7 +2114,8 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", - "source": "https://github.com/sebastianbergmann/phpunit/tree/10.0.0" + "security": "https://github.com/sebastianbergmann/phpunit/security/policy", + "source": "https://github.com/sebastianbergmann/phpunit/tree/10.5.3" }, "funding": [ { @@ -2100,7 +2131,7 @@ "type": "tidelift" } ], - "time": "2023-02-03T07:16:15+00:00" + "time": "2023-12-13T07:25:23+00:00" }, { "name": "psr/container", @@ -2401,16 +2432,16 @@ }, { "name": "sebastian/complexity", - "version": "3.0.1", + "version": "3.1.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/complexity.git", - "reference": "c70b73893e10757af9c6a48929fa6a333b56a97a" + "reference": "68cfb347a44871f01e33ab0ef8215966432f6957" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/c70b73893e10757af9c6a48929fa6a333b56a97a", - "reference": "c70b73893e10757af9c6a48929fa6a333b56a97a", + "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/68cfb347a44871f01e33ab0ef8215966432f6957", + "reference": "68cfb347a44871f01e33ab0ef8215966432f6957", "shasum": "" }, "require": { @@ -2423,7 +2454,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "3.0-dev" + "dev-main": "3.1-dev" } }, "autoload": { @@ -2447,7 +2478,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/complexity/issues", "security": "https://github.com/sebastianbergmann/complexity/security/policy", - "source": "https://github.com/sebastianbergmann/complexity/tree/3.0.1" + "source": "https://github.com/sebastianbergmann/complexity/tree/3.1.0" }, "funding": [ { @@ -2455,7 +2486,7 @@ "type": "github" } ], - "time": "2023-08-31T09:55:53+00:00" + "time": "2023-09-28T11:50:59+00:00" }, { "name": "sebastian/diff", @@ -2590,16 +2621,16 @@ }, { "name": "sebastian/exporter", - "version": "5.1.0", + "version": "5.1.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "c3fa8483f9539b190f7cd4bfc4a07631dd1df344" + "reference": "64f51654862e0f5e318db7e9dcc2292c63cdbddc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/c3fa8483f9539b190f7cd4bfc4a07631dd1df344", - "reference": "c3fa8483f9539b190f7cd4bfc4a07631dd1df344", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/64f51654862e0f5e318db7e9dcc2292c63cdbddc", + "reference": "64f51654862e0f5e318db7e9dcc2292c63cdbddc", "shasum": "" }, "require": { @@ -2613,7 +2644,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "5.0-dev" + "dev-main": "5.1-dev" } }, "autoload": { @@ -2656,7 +2687,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/exporter/issues", "security": "https://github.com/sebastianbergmann/exporter/security/policy", - "source": "https://github.com/sebastianbergmann/exporter/tree/5.1.0" + "source": "https://github.com/sebastianbergmann/exporter/tree/5.1.1" }, "funding": [ { @@ -2664,7 +2695,7 @@ "type": "github" } ], - "time": "2023-09-18T07:15:37+00:00" + "time": "2023-09-24T13:22:09+00:00" }, { "name": "sebastian/global-state", @@ -3072,16 +3103,16 @@ }, { "name": "squizlabs/php_codesniffer", - "version": "3.7.2", + "version": "3.8.0", "source": { "type": "git", - "url": "https://github.com/squizlabs/PHP_CodeSniffer.git", - "reference": "ed8e00df0a83aa96acf703f8c2979ff33341f879" + "url": "https://github.com/PHPCSStandards/PHP_CodeSniffer.git", + "reference": "5805f7a4e4958dbb5e944ef1e6edae0a303765e7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/ed8e00df0a83aa96acf703f8c2979ff33341f879", - "reference": "ed8e00df0a83aa96acf703f8c2979ff33341f879", + "url": "https://api.github.com/repos/PHPCSStandards/PHP_CodeSniffer/zipball/5805f7a4e4958dbb5e944ef1e6edae0a303765e7", + "reference": "5805f7a4e4958dbb5e944ef1e6edae0a303765e7", "shasum": "" }, "require": { @@ -3091,7 +3122,7 @@ "php": ">=5.4.0" }, "require-dev": { - "phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0" + "phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0 || ^8.0 || ^9.0" }, "bin": [ "bin/phpcs", @@ -3110,35 +3141,58 @@ "authors": [ { "name": "Greg Sherwood", - "role": "lead" + "role": "Former lead" + }, + { + "name": "Juliette Reinders Folmer", + "role": "Current lead" + }, + { + "name": "Contributors", + "homepage": "https://github.com/PHPCSStandards/PHP_CodeSniffer/graphs/contributors" } ], "description": "PHP_CodeSniffer tokenizes PHP, JavaScript and CSS files and detects violations of a defined set of coding standards.", - "homepage": "https://github.com/squizlabs/PHP_CodeSniffer", + "homepage": "https://github.com/PHPCSStandards/PHP_CodeSniffer", "keywords": [ "phpcs", "standards", "static analysis" ], "support": { - "issues": "https://github.com/squizlabs/PHP_CodeSniffer/issues", - "source": "https://github.com/squizlabs/PHP_CodeSniffer", - "wiki": "https://github.com/squizlabs/PHP_CodeSniffer/wiki" + "issues": "https://github.com/PHPCSStandards/PHP_CodeSniffer/issues", + "security": "https://github.com/PHPCSStandards/PHP_CodeSniffer/security/policy", + "source": "https://github.com/PHPCSStandards/PHP_CodeSniffer", + "wiki": "https://github.com/PHPCSStandards/PHP_CodeSniffer/wiki" }, - "time": "2023-02-22T23:07:41+00:00" + "funding": [ + { + "url": "https://github.com/PHPCSStandards", + "type": "github" + }, + { + "url": "https://github.com/jrfnl", + "type": "github" + }, + { + "url": "https://opencollective.com/php_codesniffer", + "type": "open_collective" + } + ], + "time": "2023-12-08T12:32:31+00:00" }, { "name": "symfony/console", - "version": "v6.4.0", + "version": "v6.4.1", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "cd9864b47c367450e14ab32f78fdbf98c44c26b6" + "reference": "a550a7c99daeedef3f9d23fb82e3531525ff11fd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/cd9864b47c367450e14ab32f78fdbf98c44c26b6", - "reference": "cd9864b47c367450e14ab32f78fdbf98c44c26b6", + "url": "https://api.github.com/repos/symfony/console/zipball/a550a7c99daeedef3f9d23fb82e3531525ff11fd", + "reference": "a550a7c99daeedef3f9d23fb82e3531525ff11fd", "shasum": "" }, "require": { @@ -3203,7 +3257,7 @@ "terminal" ], "support": { - "source": "https://github.com/symfony/console/tree/v6.4.0" + "source": "https://github.com/symfony/console/tree/v6.4.1" }, "funding": [ { @@ -3219,7 +3273,7 @@ "type": "tidelift" } ], - "time": "2023-11-20T16:41:16+00:00" + "time": "2023-11-30T10:54:28+00:00" }, { "name": "symfony/deprecation-contracts", @@ -3788,16 +3842,16 @@ }, { "name": "theseer/tokenizer", - "version": "1.2.1", + "version": "1.2.2", "source": { "type": "git", "url": "https://github.com/theseer/tokenizer.git", - "reference": "34a41e998c2183e22995f158c581e7b5e755ab9e" + "reference": "b2ad5003ca10d4ee50a12da31de12a5774ba6b96" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/theseer/tokenizer/zipball/34a41e998c2183e22995f158c581e7b5e755ab9e", - "reference": "34a41e998c2183e22995f158c581e7b5e755ab9e", + "url": "https://api.github.com/repos/theseer/tokenizer/zipball/b2ad5003ca10d4ee50a12da31de12a5774ba6b96", + "reference": "b2ad5003ca10d4ee50a12da31de12a5774ba6b96", "shasum": "" }, "require": { @@ -3826,7 +3880,7 @@ "description": "A small library for converting tokenized PHP source code into XML and potentially other formats", "support": { "issues": "https://github.com/theseer/tokenizer/issues", - "source": "https://github.com/theseer/tokenizer/tree/1.2.1" + "source": "https://github.com/theseer/tokenizer/tree/1.2.2" }, "funding": [ { @@ -3834,7 +3888,7 @@ "type": "github" } ], - "time": "2021-07-28T10:34:58+00:00" + "time": "2023-11-20T00:12:19+00:00" }, { "name": "wp-coding-standards/wpcs", diff --git a/vendor/composer/autoload_classmap.php b/vendor/composer/autoload_classmap.php index 97c8db8a..06a724ab 100644 --- a/vendor/composer/autoload_classmap.php +++ b/vendor/composer/autoload_classmap.php @@ -52,13 +52,18 @@ return array( 'PHPUnit\\Event\\Application\\StartedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Application/StartedSubscriber.php', 'PHPUnit\\Event\\Code\\ClassMethod' => $vendorDir . '/phpunit/phpunit/src/Event/Value/ClassMethod.php', 'PHPUnit\\Event\\Code\\ComparisonFailure' => $vendorDir . '/phpunit/phpunit/src/Event/Value/ComparisonFailure.php', + 'PHPUnit\\Event\\Code\\ComparisonFailureBuilder' => $vendorDir . '/phpunit/phpunit/src/Event/Value/ComparisonFailureBuilder.php', + 'PHPUnit\\Event\\Code\\NoTestCaseObjectOnCallStackException' => $vendorDir . '/phpunit/phpunit/src/Event/Exception/NoTestCaseObjectOnCallStackException.php', 'PHPUnit\\Event\\Code\\Phpt' => $vendorDir . '/phpunit/phpunit/src/Event/Value/Test/Phpt.php', 'PHPUnit\\Event\\Code\\Test' => $vendorDir . '/phpunit/phpunit/src/Event/Value/Test/Test.php', 'PHPUnit\\Event\\Code\\TestCollection' => $vendorDir . '/phpunit/phpunit/src/Event/Value/Test/TestCollection.php', 'PHPUnit\\Event\\Code\\TestCollectionIterator' => $vendorDir . '/phpunit/phpunit/src/Event/Value/Test/TestCollectionIterator.php', 'PHPUnit\\Event\\Code\\TestDox' => $vendorDir . '/phpunit/phpunit/src/Event/Value/Test/TestDox.php', + 'PHPUnit\\Event\\Code\\TestDoxBuilder' => $vendorDir . '/phpunit/phpunit/src/Event/Value/Test/TestDoxBuilder.php', 'PHPUnit\\Event\\Code\\TestMethod' => $vendorDir . '/phpunit/phpunit/src/Event/Value/Test/TestMethod.php', + 'PHPUnit\\Event\\Code\\TestMethodBuilder' => $vendorDir . '/phpunit/phpunit/src/Event/Value/Test/TestMethodBuilder.php', 'PHPUnit\\Event\\Code\\Throwable' => $vendorDir . '/phpunit/phpunit/src/Event/Value/Throwable.php', + 'PHPUnit\\Event\\Code\\ThrowableBuilder' => $vendorDir . '/phpunit/phpunit/src/Event/Value/ThrowableBuilder.php', 'PHPUnit\\Event\\CollectingDispatcher' => $vendorDir . '/phpunit/phpunit/src/Event/Dispatcher/CollectingDispatcher.php', 'PHPUnit\\Event\\DeferringDispatcher' => $vendorDir . '/phpunit/phpunit/src/Event/Dispatcher/DeferringDispatcher.php', 'PHPUnit\\Event\\DirectDispatcher' => $vendorDir . '/phpunit/phpunit/src/Event/Dispatcher/DirectDispatcher.php', @@ -86,10 +91,14 @@ return array( 'PHPUnit\\Event\\Subscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Subscriber.php', 'PHPUnit\\Event\\SubscriberTypeAlreadyRegisteredException' => $vendorDir . '/phpunit/phpunit/src/Event/Exception/SubscriberTypeAlreadyRegisteredException.php', 'PHPUnit\\Event\\Telemetry\\Duration' => $vendorDir . '/phpunit/phpunit/src/Event/Value/Telemetry/Duration.php', + 'PHPUnit\\Event\\Telemetry\\GarbageCollectorStatus' => $vendorDir . '/phpunit/phpunit/src/Event/Value/Telemetry/GarbageCollectorStatus.php', + 'PHPUnit\\Event\\Telemetry\\GarbageCollectorStatusProvider' => $vendorDir . '/phpunit/phpunit/src/Event/Value/Telemetry/GarbageCollectorStatusProvider.php', 'PHPUnit\\Event\\Telemetry\\HRTime' => $vendorDir . '/phpunit/phpunit/src/Event/Value/Telemetry/HRTime.php', 'PHPUnit\\Event\\Telemetry\\Info' => $vendorDir . '/phpunit/phpunit/src/Event/Value/Telemetry/Info.php', 'PHPUnit\\Event\\Telemetry\\MemoryMeter' => $vendorDir . '/phpunit/phpunit/src/Event/Value/Telemetry/MemoryMeter.php', 'PHPUnit\\Event\\Telemetry\\MemoryUsage' => $vendorDir . '/phpunit/phpunit/src/Event/Value/Telemetry/MemoryUsage.php', + 'PHPUnit\\Event\\Telemetry\\Php81GarbageCollectorStatusProvider' => $vendorDir . '/phpunit/phpunit/src/Event/Value/Telemetry/Php81GarbageCollectorStatusProvider.php', + 'PHPUnit\\Event\\Telemetry\\Php83GarbageCollectorStatusProvider' => $vendorDir . '/phpunit/phpunit/src/Event/Value/Telemetry/Php83GarbageCollectorStatusProvider.php', 'PHPUnit\\Event\\Telemetry\\Snapshot' => $vendorDir . '/phpunit/phpunit/src/Event/Value/Telemetry/Snapshot.php', 'PHPUnit\\Event\\Telemetry\\StopWatch' => $vendorDir . '/phpunit/phpunit/src/Event/Value/Telemetry/StopWatch.php', 'PHPUnit\\Event\\Telemetry\\System' => $vendorDir . '/phpunit/phpunit/src/Event/Value/Telemetry/System.php', @@ -111,6 +120,8 @@ return array( 'PHPUnit\\Event\\TestRunner\\DeprecationTriggeredSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestRunner/DeprecationTriggeredSubscriber.php', 'PHPUnit\\Event\\TestRunner\\EventFacadeSealed' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestRunner/EventFacadeSealed.php', 'PHPUnit\\Event\\TestRunner\\EventFacadeSealedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestRunner/EventFacadeSealedSubscriber.php', + 'PHPUnit\\Event\\TestRunner\\ExecutionAborted' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionAborted.php', + 'PHPUnit\\Event\\TestRunner\\ExecutionAbortedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionAbortedSubscriber.php', 'PHPUnit\\Event\\TestRunner\\ExecutionFinished' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionFinished.php', 'PHPUnit\\Event\\TestRunner\\ExecutionFinishedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionFinishedSubscriber.php', 'PHPUnit\\Event\\TestRunner\\ExecutionStarted' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionStarted.php', @@ -121,6 +132,12 @@ return array( 'PHPUnit\\Event\\TestRunner\\ExtensionLoadedFromPharSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestRunner/ExtensionLoadedFromPharSubscriber.php', 'PHPUnit\\Event\\TestRunner\\Finished' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestRunner/Finished.php', 'PHPUnit\\Event\\TestRunner\\FinishedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestRunner/FinishedSubscriber.php', + 'PHPUnit\\Event\\TestRunner\\GarbageCollectionDisabled' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionDisabled.php', + 'PHPUnit\\Event\\TestRunner\\GarbageCollectionDisabledSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionDisabledSubscriber.php', + 'PHPUnit\\Event\\TestRunner\\GarbageCollectionEnabled' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionEnabled.php', + 'PHPUnit\\Event\\TestRunner\\GarbageCollectionEnabledSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionEnabledSubscriber.php', + 'PHPUnit\\Event\\TestRunner\\GarbageCollectionTriggered' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionTriggered.php', + 'PHPUnit\\Event\\TestRunner\\GarbageCollectionTriggeredSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionTriggeredSubscriber.php', 'PHPUnit\\Event\\TestRunner\\Started' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestRunner/Started.php', 'PHPUnit\\Event\\TestRunner\\StartedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestRunner/StartedSubscriber.php', 'PHPUnit\\Event\\TestRunner\\WarningTriggered' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestRunner/WarningTriggered.php', @@ -131,11 +148,14 @@ return array( 'PHPUnit\\Event\\TestSuite\\FinishedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestSuite/FinishedSubscriber.php', 'PHPUnit\\Event\\TestSuite\\Loaded' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestSuite/Loaded.php', 'PHPUnit\\Event\\TestSuite\\LoadedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestSuite/LoadedSubscriber.php', + 'PHPUnit\\Event\\TestSuite\\Skipped' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestSuite/Skipped.php', + 'PHPUnit\\Event\\TestSuite\\SkippedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestSuite/SkippedSubscriber.php', 'PHPUnit\\Event\\TestSuite\\Sorted' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestSuite/Sorted.php', 'PHPUnit\\Event\\TestSuite\\SortedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestSuite/SortedSubscriber.php', 'PHPUnit\\Event\\TestSuite\\Started' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestSuite/Started.php', 'PHPUnit\\Event\\TestSuite\\StartedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/TestSuite/StartedSubscriber.php', 'PHPUnit\\Event\\TestSuite\\TestSuite' => $vendorDir . '/phpunit/phpunit/src/Event/Value/TestSuite/TestSuite.php', + 'PHPUnit\\Event\\TestSuite\\TestSuiteBuilder' => $vendorDir . '/phpunit/phpunit/src/Event/Value/TestSuite/TestSuiteBuilder.php', 'PHPUnit\\Event\\TestSuite\\TestSuiteForTestClass' => $vendorDir . '/phpunit/phpunit/src/Event/Value/TestSuite/TestSuiteForTestClass.php', 'PHPUnit\\Event\\TestSuite\\TestSuiteForTestMethodWithDataProvider' => $vendorDir . '/phpunit/phpunit/src/Event/Value/TestSuite/TestSuiteForTestMethodWithDataProvider.php', 'PHPUnit\\Event\\TestSuite\\TestSuiteWithName' => $vendorDir . '/phpunit/phpunit/src/Event/Value/TestSuite/TestSuiteWithName.php', @@ -165,6 +185,10 @@ return array( 'PHPUnit\\Event\\Test\\ComparatorRegisteredSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/ComparatorRegisteredSubscriber.php', 'PHPUnit\\Event\\Test\\ConsideredRisky' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/Issue/ConsideredRisky.php', 'PHPUnit\\Event\\Test\\ConsideredRiskySubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/Issue/ConsideredRiskySubscriber.php', + 'PHPUnit\\Event\\Test\\DataProviderMethodCalled' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodCalled.php', + 'PHPUnit\\Event\\Test\\DataProviderMethodCalledSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodCalledSubscriber.php', + 'PHPUnit\\Event\\Test\\DataProviderMethodFinished' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodFinished.php', + 'PHPUnit\\Event\\Test\\DataProviderMethodFinishedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodFinishedSubscriber.php', 'PHPUnit\\Event\\Test\\DeprecationTriggered' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/Issue/DeprecationTriggered.php', 'PHPUnit\\Event\\Test\\DeprecationTriggeredSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/Issue/DeprecationTriggeredSubscriber.php', 'PHPUnit\\Event\\Test\\ErrorTriggered' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/Issue/ErrorTriggered.php', @@ -214,10 +238,14 @@ return array( 'PHPUnit\\Event\\Test\\PreConditionCalledSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/HookMethod/PreConditionCalledSubscriber.php', 'PHPUnit\\Event\\Test\\PreConditionFinished' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/HookMethod/PreConditionFinished.php', 'PHPUnit\\Event\\Test\\PreConditionFinishedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/HookMethod/PreConditionFinishedSubscriber.php', + 'PHPUnit\\Event\\Test\\PreparationFailed' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/Lifecycle/PreparationFailed.php', + 'PHPUnit\\Event\\Test\\PreparationFailedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/Lifecycle/PreparationFailedSubscriber.php', 'PHPUnit\\Event\\Test\\PreparationStarted' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/Lifecycle/PreparationStarted.php', 'PHPUnit\\Event\\Test\\PreparationStartedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/Lifecycle/PreparationStartedSubscriber.php', 'PHPUnit\\Event\\Test\\Prepared' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/Lifecycle/Prepared.php', 'PHPUnit\\Event\\Test\\PreparedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/Lifecycle/PreparedSubscriber.php', + 'PHPUnit\\Event\\Test\\PrintedUnexpectedOutput' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/PrintedUnexpectedOutput.php', + 'PHPUnit\\Event\\Test\\PrintedUnexpectedOutputSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/PrintedUnexpectedOutputSubscriber.php', 'PHPUnit\\Event\\Test\\Skipped' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/Outcome/Skipped.php', 'PHPUnit\\Event\\Test\\SkippedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/Outcome/SkippedSubscriber.php', 'PHPUnit\\Event\\Test\\TestProxyCreated' => $vendorDir . '/phpunit/phpunit/src/Event/Events/Test/TestDouble/TestProxyCreated.php', @@ -263,6 +291,10 @@ return array( 'PHPUnit\\Framework\\Attributes\\ExcludeGlobalVariableFromBackup' => $vendorDir . '/phpunit/phpunit/src/Framework/Attributes/ExcludeGlobalVariableFromBackup.php', 'PHPUnit\\Framework\\Attributes\\ExcludeStaticPropertyFromBackup' => $vendorDir . '/phpunit/phpunit/src/Framework/Attributes/ExcludeStaticPropertyFromBackup.php', 'PHPUnit\\Framework\\Attributes\\Group' => $vendorDir . '/phpunit/phpunit/src/Framework/Attributes/Group.php', + 'PHPUnit\\Framework\\Attributes\\IgnoreClassForCodeCoverage' => $vendorDir . '/phpunit/phpunit/src/Framework/Attributes/IgnoreClassForCodeCoverage.php', + 'PHPUnit\\Framework\\Attributes\\IgnoreDeprecations' => $vendorDir . '/phpunit/phpunit/src/Framework/Attributes/IgnoreDeprecations.php', + 'PHPUnit\\Framework\\Attributes\\IgnoreFunctionForCodeCoverage' => $vendorDir . '/phpunit/phpunit/src/Framework/Attributes/IgnoreFunctionForCodeCoverage.php', + 'PHPUnit\\Framework\\Attributes\\IgnoreMethodForCodeCoverage' => $vendorDir . '/phpunit/phpunit/src/Framework/Attributes/IgnoreMethodForCodeCoverage.php', 'PHPUnit\\Framework\\Attributes\\Large' => $vendorDir . '/phpunit/phpunit/src/Framework/Attributes/Large.php', 'PHPUnit\\Framework\\Attributes\\Medium' => $vendorDir . '/phpunit/phpunit/src/Framework/Attributes/Medium.php', 'PHPUnit\\Framework\\Attributes\\PostCondition' => $vendorDir . '/phpunit/phpunit/src/Framework/Attributes/PostCondition.php', @@ -287,6 +319,7 @@ return array( 'PHPUnit\\Framework\\Attributes\\Ticket' => $vendorDir . '/phpunit/phpunit/src/Framework/Attributes/Ticket.php', 'PHPUnit\\Framework\\Attributes\\UsesClass' => $vendorDir . '/phpunit/phpunit/src/Framework/Attributes/UsesClass.php', 'PHPUnit\\Framework\\Attributes\\UsesFunction' => $vendorDir . '/phpunit/phpunit/src/Framework/Attributes/UsesFunction.php', + 'PHPUnit\\Framework\\Attributes\\WithoutErrorHandler' => $vendorDir . '/phpunit/phpunit/src/Framework/Attributes/WithoutErrorHandler.php', 'PHPUnit\\Framework\\CodeCoverageException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/CodeCoverageException.php', 'PHPUnit\\Framework\\ComparisonMethodDoesNotAcceptParameterTypeException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotAcceptParameterTypeException.php', 'PHPUnit\\Framework\\ComparisonMethodDoesNotDeclareBoolReturnTypeException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotDeclareBoolReturnTypeException.php', @@ -301,6 +334,8 @@ return array( '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\\ExceptionMessageIsOrContains' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionMessageIsOrContains.php', + 'PHPUnit\\Framework\\Constraint\\ExceptionMessageMatchesRegularExpression' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionMessageMatchesRegularExpression.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', @@ -323,15 +358,13 @@ return array( '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/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\\MessageIsOrContains' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Message/MessageIsOrContains.php', - 'PHPUnit\\Framework\\Constraint\\MessageMatchesRegularExpression' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Message/MessageMatchesRegularExpression.php', - 'PHPUnit\\Framework\\Constraint\\ObjectEquals' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/ObjectEquals.php', + 'PHPUnit\\Framework\\Constraint\\ObjectEquals' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Object/ObjectEquals.php', + 'PHPUnit\\Framework\\Constraint\\ObjectHasProperty' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Object/ObjectHasProperty.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', @@ -347,7 +380,6 @@ return array( 'PHPUnit\\Framework\\Constraint\\UnaryOperator' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Operator/UnaryOperator.php', 'PHPUnit\\Framework\\DataProviderTestSuite' => $vendorDir . '/phpunit/phpunit/src/Framework/DataProviderTestSuite.php', 'PHPUnit\\Framework\\EmptyStringException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/EmptyStringException.php', - 'PHPUnit\\Framework\\Error' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/Error.php', 'PHPUnit\\Framework\\Exception' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/Exception.php', 'PHPUnit\\Framework\\ExecutionOrderDependency' => $vendorDir . '/phpunit/phpunit/src/Framework/ExecutionOrderDependency.php', 'PHPUnit\\Framework\\ExpectationFailedException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/ExpectationFailedException.php', @@ -358,77 +390,83 @@ return array( 'PHPUnit\\Framework\\InvalidCoversTargetException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/InvalidCoversTargetException.php', 'PHPUnit\\Framework\\InvalidDataProviderException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/InvalidDataProviderException.php', 'PHPUnit\\Framework\\InvalidDependencyException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/InvalidDependencyException.php', - 'PHPUnit\\Framework\\MockObject\\Api' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Api/Api.php', 'PHPUnit\\Framework\\MockObject\\BadMethodCallException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/BadMethodCallException.php', - '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\\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\\Builder\\Identity' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/Identity.php', + 'PHPUnit\\Framework\\MockObject\\Builder\\InvocationMocker' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/InvocationMocker.php', + 'PHPUnit\\Framework\\MockObject\\Builder\\InvocationStubber' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/InvocationStubber.php', + 'PHPUnit\\Framework\\MockObject\\Builder\\MethodNameMatch' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/MethodNameMatch.php', + 'PHPUnit\\Framework\\MockObject\\Builder\\ParametersMatch' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/ParametersMatch.php', + 'PHPUnit\\Framework\\MockObject\\Builder\\Stub' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/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\\ClassIsEnumerationException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsEnumerationException.php', - 'PHPUnit\\Framework\\MockObject\\ClassIsFinalException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsFinalException.php', - 'PHPUnit\\Framework\\MockObject\\ClassIsReadonlyException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsReadonlyException.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\\DoubledCloneMethod' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/DoubledCloneMethod.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\\Generator\\ClassAlreadyExistsException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ClassAlreadyExistsException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\ClassIsEnumerationException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ClassIsEnumerationException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\ClassIsFinalException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ClassIsFinalException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\ClassIsReadonlyException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ClassIsReadonlyException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\DuplicateMethodException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/DuplicateMethodException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\Exception' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/Exception.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\Generator' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator/Generator.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\InvalidMethodNameException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/InvalidMethodNameException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\MockClass' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator/MockClass.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\MockMethod' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator/MockMethod.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\MockMethodSet' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator/MockMethodSet.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\MockTrait' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator/MockTrait.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\MockType' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator/MockType.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\OriginalConstructorInvocationRequiredException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/OriginalConstructorInvocationRequiredException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\ReflectionException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ReflectionException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\RuntimeException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/RuntimeException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\SoapExtensionNotAvailableException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/SoapExtensionNotAvailableException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\TemplateLoader' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator/TemplateLoader.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\UnknownClassException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/UnknownClassException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\UnknownTraitException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/UnknownTraitException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\UnknownTypeException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/UnknownTypeException.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\\Invocation' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Invocation.php', + 'PHPUnit\\Framework\\MockObject\\InvocationHandler' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/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\\Matcher' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/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\\Method' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/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\\MethodNameConstraint' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/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', - 'PHPUnit\\Framework\\MockObject\\MockMethodSet' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/MockMethodSet.php', - 'PHPUnit\\Framework\\MockObject\\MockObject' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/MockObject.php', - '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\\MockObject' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/MockObject.php', + 'PHPUnit\\Framework\\MockObject\\MockObjectApi' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/MockObjectApi.php', + 'PHPUnit\\Framework\\MockObject\\MockObjectInternal' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/MockObjectInternal.php', + 'PHPUnit\\Framework\\MockObject\\NeverReturningMethodException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/NeverReturningMethodException.php', + 'PHPUnit\\Framework\\MockObject\\ProxiedCloneMethod' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/ProxiedCloneMethod.php', 'PHPUnit\\Framework\\MockObject\\ReflectionException' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Exception/ReflectionException.php', + 'PHPUnit\\Framework\\MockObject\\ReturnValueGenerator' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/ReturnValueGenerator.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\\InvocationOrder' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Rule/InvocationOrder.php', - 'PHPUnit\\Framework\\MockObject\\Rule\\InvokedAtLeastCount' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedAtLeastCount.php', - 'PHPUnit\\Framework\\MockObject\\Rule\\InvokedAtLeastOnce' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedAtLeastOnce.php', - 'PHPUnit\\Framework\\MockObject\\Rule\\InvokedAtMostCount' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedAtMostCount.php', - 'PHPUnit\\Framework\\MockObject\\Rule\\InvokedCount' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedCount.php', - 'PHPUnit\\Framework\\MockObject\\Rule\\MethodName' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Rule/MethodName.php', - '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\\Rule\\AnyInvokedCount' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/AnyInvokedCount.php', + 'PHPUnit\\Framework\\MockObject\\Rule\\AnyParameters' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/AnyParameters.php', + 'PHPUnit\\Framework\\MockObject\\Rule\\InvocationOrder' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvocationOrder.php', + 'PHPUnit\\Framework\\MockObject\\Rule\\InvokedAtLeastCount' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvokedAtLeastCount.php', + 'PHPUnit\\Framework\\MockObject\\Rule\\InvokedAtLeastOnce' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvokedAtLeastOnce.php', + 'PHPUnit\\Framework\\MockObject\\Rule\\InvokedAtMostCount' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvokedAtMostCount.php', + 'PHPUnit\\Framework\\MockObject\\Rule\\InvokedCount' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvokedCount.php', + 'PHPUnit\\Framework\\MockObject\\Rule\\MethodName' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/MethodName.php', + 'PHPUnit\\Framework\\MockObject\\Rule\\Parameters' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/Parameters.php', + 'PHPUnit\\Framework\\MockObject\\Rule\\ParametersRule' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/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', - 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnArgument' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnArgument.php', - 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnCallback' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnCallback.php', - 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnReference' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnReference.php', - 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnSelf' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnSelf.php', - '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\\TemplateLoader' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/TemplateLoader.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\\MockObject\\Stub' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/Stub.php', + 'PHPUnit\\Framework\\MockObject\\StubApi' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/StubApi.php', + 'PHPUnit\\Framework\\MockObject\\StubInternal' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/StubInternal.php', + 'PHPUnit\\Framework\\MockObject\\Stub\\ConsecutiveCalls' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ConsecutiveCalls.php', + 'PHPUnit\\Framework\\MockObject\\Stub\\Exception' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/Exception.php', + 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnArgument' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnArgument.php', + 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnCallback' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnCallback.php', + 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnReference' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnReference.php', + 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnSelf' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnSelf.php', + 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnStub' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnStub.php', + 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnValueMap' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnValueMap.php', + 'PHPUnit\\Framework\\MockObject\\Stub\\Stub' => $vendorDir . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/Stub.php', 'PHPUnit\\Framework\\NoChildTestSuiteException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/NoChildTestSuiteException.php', 'PHPUnit\\Framework\\PhptAssertionFailedError' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/PhptAssertionFailedError.php', 'PHPUnit\\Framework\\ProcessIsolationException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/ProcessIsolationException.php', @@ -461,8 +499,8 @@ return array( 'PHPUnit\\Framework\\TestStatus\\Warning' => $vendorDir . '/phpunit/phpunit/src/Framework/TestStatus/Warning.php', 'PHPUnit\\Framework\\TestSuite' => $vendorDir . '/phpunit/phpunit/src/Framework/TestSuite.php', 'PHPUnit\\Framework\\TestSuiteIterator' => $vendorDir . '/phpunit/phpunit/src/Framework/TestSuiteIterator.php', - 'PHPUnit\\Framework\\UnknownClassException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/UnknownClassException.php', 'PHPUnit\\Framework\\UnknownClassOrInterfaceException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/UnknownClassOrInterfaceException.php', + 'PHPUnit\\Framework\\UnknownTypeException' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception/UnknownTypeException.php', 'PHPUnit\\Logging\\EventLogger' => $vendorDir . '/phpunit/phpunit/src/Logging/EventLogger.php', 'PHPUnit\\Logging\\Exception' => $vendorDir . '/phpunit/phpunit/src/Logging/Exception.php', 'PHPUnit\\Logging\\JUnit\\JunitXmlLogger' => $vendorDir . '/phpunit/phpunit/src/Logging/JUnit/JunitXmlLogger.php', @@ -471,6 +509,8 @@ return array( 'PHPUnit\\Logging\\JUnit\\TestFailedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestFailedSubscriber.php', 'PHPUnit\\Logging\\JUnit\\TestFinishedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestFinishedSubscriber.php', 'PHPUnit\\Logging\\JUnit\\TestMarkedIncompleteSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestMarkedIncompleteSubscriber.php', + 'PHPUnit\\Logging\\JUnit\\TestPreparationFailedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestPreparationFailedSubscriber.php', + 'PHPUnit\\Logging\\JUnit\\TestPreparationStartedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestPreparationStartedSubscriber.php', 'PHPUnit\\Logging\\JUnit\\TestPreparedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestPreparedSubscriber.php', 'PHPUnit\\Logging\\JUnit\\TestRunnerExecutionFinishedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestRunnerExecutionFinishedSubscriber.php', 'PHPUnit\\Logging\\JUnit\\TestSkippedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestSkippedSubscriber.php', @@ -491,30 +531,24 @@ return array( 'PHPUnit\\Logging\\TestDox\\HtmlRenderer' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/HtmlRenderer.php', 'PHPUnit\\Logging\\TestDox\\NamePrettifier' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/NamePrettifier.php', 'PHPUnit\\Logging\\TestDox\\PlainTextRenderer' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/PlainTextRenderer.php', - 'PHPUnit\\Logging\\TestDox\\Subscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/Subscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestConsideredRiskySubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestConsideredRiskySubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestCreatedMockObjectForAbstractClassSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestCreatedMockObjectForAbstractClassSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestCreatedMockObjectForTraitSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestCreatedMockObjectForTraitSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestCreatedMockObjectFromWsdlSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestCreatedMockObjectFromWsdlSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestCreatedMockObjectSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestCreatedMockObjectSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestCreatedPartialMockObjectSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestCreatedPartialMockObjectSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestCreatedTestProxySubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestCreatedTestProxySubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestCreatedTestStubSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestCreatedTestStubSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestErroredSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestErroredSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestFailedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestFailedSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestFinishedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestFinishedSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestMarkedIncompleteSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestMarkedIncompleteSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestPassedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestPassedSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestPreparedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestPreparedSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestResult' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/TestMethod/TestResult.php', - 'PHPUnit\\Logging\\TestDox\\TestResultCollection' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/TestMethod/TestResultCollection.php', - 'PHPUnit\\Logging\\TestDox\\TestResultCollectionIterator' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/TestMethod/TestResultCollectionIterator.php', - 'PHPUnit\\Logging\\TestDox\\TestResultCollector' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/TestMethod/TestResultCollector.php', - 'PHPUnit\\Logging\\TestDox\\TestSkippedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestSkippedSubscriber.php', + 'PHPUnit\\Logging\\TestDox\\Subscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/TestResult/Subscriber/Subscriber.php', + 'PHPUnit\\Logging\\TestDox\\TestConsideredRiskySubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/TestResult/Subscriber/TestConsideredRiskySubscriber.php', + 'PHPUnit\\Logging\\TestDox\\TestErroredSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/TestResult/Subscriber/TestErroredSubscriber.php', + 'PHPUnit\\Logging\\TestDox\\TestFailedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/TestResult/Subscriber/TestFailedSubscriber.php', + 'PHPUnit\\Logging\\TestDox\\TestFinishedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/TestResult/Subscriber/TestFinishedSubscriber.php', + 'PHPUnit\\Logging\\TestDox\\TestMarkedIncompleteSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/TestResult/Subscriber/TestMarkedIncompleteSubscriber.php', + 'PHPUnit\\Logging\\TestDox\\TestPassedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/TestResult/Subscriber/TestPassedSubscriber.php', + 'PHPUnit\\Logging\\TestDox\\TestPreparedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/TestResult/Subscriber/TestPreparedSubscriber.php', + 'PHPUnit\\Logging\\TestDox\\TestResult' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/TestResult/TestResult.php', + 'PHPUnit\\Logging\\TestDox\\TestResultCollection' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/TestResult/TestResultCollection.php', + 'PHPUnit\\Logging\\TestDox\\TestResultCollectionIterator' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/TestResult/TestResultCollectionIterator.php', + 'PHPUnit\\Logging\\TestDox\\TestResultCollector' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/TestResult/TestResultCollector.php', + 'PHPUnit\\Logging\\TestDox\\TestSkippedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Logging/TestDox/TestResult/Subscriber/TestSkippedSubscriber.php', 'PHPUnit\\Metadata\\After' => $vendorDir . '/phpunit/phpunit/src/Metadata/After.php', 'PHPUnit\\Metadata\\AfterClass' => $vendorDir . '/phpunit/phpunit/src/Metadata/AfterClass.php', 'PHPUnit\\Metadata\\Annotation\\Parser\\DocBlock' => $vendorDir . '/phpunit/phpunit/src/Metadata/Parser/Annotation/DocBlock.php', 'PHPUnit\\Metadata\\Annotation\\Parser\\Registry' => $vendorDir . '/phpunit/phpunit/src/Metadata/Parser/Annotation/Registry.php', + 'PHPUnit\\Metadata\\AnnotationsAreNotSupportedForInternalClassesException' => $vendorDir . '/phpunit/phpunit/src/Metadata/Exception/AnnotationsAreNotSupportedForInternalClassesException.php', 'PHPUnit\\Metadata\\Api\\CodeCoverage' => $vendorDir . '/phpunit/phpunit/src/Metadata/Api/CodeCoverage.php', 'PHPUnit\\Metadata\\Api\\DataProvider' => $vendorDir . '/phpunit/phpunit/src/Metadata/Api/DataProvider.php', 'PHPUnit\\Metadata\\Api\\Dependencies' => $vendorDir . '/phpunit/phpunit/src/Metadata/Api/Dependencies.php', @@ -525,7 +559,6 @@ return array( 'PHPUnit\\Metadata\\BackupStaticProperties' => $vendorDir . '/phpunit/phpunit/src/Metadata/BackupStaticProperties.php', 'PHPUnit\\Metadata\\Before' => $vendorDir . '/phpunit/phpunit/src/Metadata/Before.php', 'PHPUnit\\Metadata\\BeforeClass' => $vendorDir . '/phpunit/phpunit/src/Metadata/BeforeClass.php', - 'PHPUnit\\Metadata\\CodeCoverageIgnore' => $vendorDir . '/phpunit/phpunit/src/Metadata/CodeCoverageIgnore.php', 'PHPUnit\\Metadata\\Covers' => $vendorDir . '/phpunit/phpunit/src/Metadata/Covers.php', 'PHPUnit\\Metadata\\CoversClass' => $vendorDir . '/phpunit/phpunit/src/Metadata/CoversClass.php', 'PHPUnit\\Metadata\\CoversDefaultClass' => $vendorDir . '/phpunit/phpunit/src/Metadata/CoversDefaultClass.php', @@ -539,6 +572,10 @@ return array( 'PHPUnit\\Metadata\\ExcludeGlobalVariableFromBackup' => $vendorDir . '/phpunit/phpunit/src/Metadata/ExcludeGlobalVariableFromBackup.php', 'PHPUnit\\Metadata\\ExcludeStaticPropertyFromBackup' => $vendorDir . '/phpunit/phpunit/src/Metadata/ExcludeStaticPropertyFromBackup.php', 'PHPUnit\\Metadata\\Group' => $vendorDir . '/phpunit/phpunit/src/Metadata/Group.php', + 'PHPUnit\\Metadata\\IgnoreClassForCodeCoverage' => $vendorDir . '/phpunit/phpunit/src/Metadata/IgnoreClassForCodeCoverage.php', + 'PHPUnit\\Metadata\\IgnoreDeprecations' => $vendorDir . '/phpunit/phpunit/src/Metadata/IgnoreDeprecations.php', + 'PHPUnit\\Metadata\\IgnoreFunctionForCodeCoverage' => $vendorDir . '/phpunit/phpunit/src/Metadata/IgnoreFunctionForCodeCoverage.php', + 'PHPUnit\\Metadata\\IgnoreMethodForCodeCoverage' => $vendorDir . '/phpunit/phpunit/src/Metadata/IgnoreMethodForCodeCoverage.php', 'PHPUnit\\Metadata\\InvalidVersionRequirementException' => $vendorDir . '/phpunit/phpunit/src/Metadata/Exception/InvalidVersionRequirementException.php', 'PHPUnit\\Metadata\\Metadata' => $vendorDir . '/phpunit/phpunit/src/Metadata/Metadata.php', 'PHPUnit\\Metadata\\MetadataCollection' => $vendorDir . '/phpunit/phpunit/src/Metadata/MetadataCollection.php', @@ -575,13 +612,28 @@ return array( 'PHPUnit\\Metadata\\Version\\ComparisonRequirement' => $vendorDir . '/phpunit/phpunit/src/Metadata/Version/ComparisonRequirement.php', 'PHPUnit\\Metadata\\Version\\ConstraintRequirement' => $vendorDir . '/phpunit/phpunit/src/Metadata/Version/ConstraintRequirement.php', 'PHPUnit\\Metadata\\Version\\Requirement' => $vendorDir . '/phpunit/phpunit/src/Metadata/Version/Requirement.php', + 'PHPUnit\\Metadata\\WithoutErrorHandler' => $vendorDir . '/phpunit/phpunit/src/Metadata/WithoutErrorHandler.php', + 'PHPUnit\\Runner\\Baseline\\Baseline' => $vendorDir . '/phpunit/phpunit/src/Runner/Baseline/Baseline.php', + 'PHPUnit\\Runner\\Baseline\\CannotLoadBaselineException' => $vendorDir . '/phpunit/phpunit/src/Runner/Baseline/Exception/CannotLoadBaselineException.php', + 'PHPUnit\\Runner\\Baseline\\FileDoesNotHaveLineException' => $vendorDir . '/phpunit/phpunit/src/Runner/Baseline/Exception/FileDoesNotHaveLineException.php', + 'PHPUnit\\Runner\\Baseline\\Generator' => $vendorDir . '/phpunit/phpunit/src/Runner/Baseline/Generator.php', + 'PHPUnit\\Runner\\Baseline\\Issue' => $vendorDir . '/phpunit/phpunit/src/Runner/Baseline/Issue.php', + 'PHPUnit\\Runner\\Baseline\\Reader' => $vendorDir . '/phpunit/phpunit/src/Runner/Baseline/Reader.php', + 'PHPUnit\\Runner\\Baseline\\RelativePathCalculator' => $vendorDir . '/phpunit/phpunit/src/Runner/Baseline/RelativePathCalculator.php', + 'PHPUnit\\Runner\\Baseline\\Subscriber' => $vendorDir . '/phpunit/phpunit/src/Runner/Baseline/Subscriber/Subscriber.php', + 'PHPUnit\\Runner\\Baseline\\TestTriggeredDeprecationSubscriber' => $vendorDir . '/phpunit/phpunit/src/Runner/Baseline/Subscriber/TestTriggeredDeprecationSubscriber.php', + 'PHPUnit\\Runner\\Baseline\\TestTriggeredNoticeSubscriber' => $vendorDir . '/phpunit/phpunit/src/Runner/Baseline/Subscriber/TestTriggeredNoticeSubscriber.php', + 'PHPUnit\\Runner\\Baseline\\TestTriggeredPhpDeprecationSubscriber' => $vendorDir . '/phpunit/phpunit/src/Runner/Baseline/Subscriber/TestTriggeredPhpDeprecationSubscriber.php', + 'PHPUnit\\Runner\\Baseline\\TestTriggeredPhpNoticeSubscriber' => $vendorDir . '/phpunit/phpunit/src/Runner/Baseline/Subscriber/TestTriggeredPhpNoticeSubscriber.php', + 'PHPUnit\\Runner\\Baseline\\TestTriggeredPhpWarningSubscriber' => $vendorDir . '/phpunit/phpunit/src/Runner/Baseline/Subscriber/TestTriggeredPhpWarningSubscriber.php', + 'PHPUnit\\Runner\\Baseline\\TestTriggeredWarningSubscriber' => $vendorDir . '/phpunit/phpunit/src/Runner/Baseline/Subscriber/TestTriggeredWarningSubscriber.php', + 'PHPUnit\\Runner\\Baseline\\Writer' => $vendorDir . '/phpunit/phpunit/src/Runner/Baseline/Writer.php', 'PHPUnit\\Runner\\ClassCannotBeFoundException' => $vendorDir . '/phpunit/phpunit/src/Runner/Exception/ClassCannotBeFoundException.php', - 'PHPUnit\\Runner\\ClassCannotBeInstantiatedException' => $vendorDir . '/phpunit/phpunit/src/Runner/Exception/ClassCannotBeInstantiatedException.php', - 'PHPUnit\\Runner\\ClassDoesNotExistException' => $vendorDir . '/phpunit/phpunit/src/Runner/Exception/ClassDoesNotExistException.php', - 'PHPUnit\\Runner\\ClassDoesNotImplementExtensionInterfaceException' => $vendorDir . '/phpunit/phpunit/src/Runner/Exception/ClassDoesNotImplementExtensionInterfaceException.php', + 'PHPUnit\\Runner\\ClassDoesNotExtendTestCaseException' => $vendorDir . '/phpunit/phpunit/src/Runner/Exception/ClassDoesNotExtendTestCaseException.php', 'PHPUnit\\Runner\\ClassIsAbstractException' => $vendorDir . '/phpunit/phpunit/src/Runner/Exception/ClassIsAbstractException.php', 'PHPUnit\\Runner\\CodeCoverage' => $vendorDir . '/phpunit/phpunit/src/Runner/CodeCoverage.php', 'PHPUnit\\Runner\\DirectoryCannotBeCreatedException' => $vendorDir . '/phpunit/phpunit/src/Runner/Exception/DirectoryCannotBeCreatedException.php', + 'PHPUnit\\Runner\\ErrorHandler' => $vendorDir . '/phpunit/phpunit/src/Runner/ErrorHandler.php', 'PHPUnit\\Runner\\Exception' => $vendorDir . '/phpunit/phpunit/src/Runner/Exception/Exception.php', 'PHPUnit\\Runner\\Extension\\Extension' => $vendorDir . '/phpunit/phpunit/src/Runner/Extension/Extension.php', 'PHPUnit\\Runner\\Extension\\ExtensionBootstrapper' => $vendorDir . '/phpunit/phpunit/src/Runner/Extension/ExtensionBootstrapper.php', @@ -594,6 +646,12 @@ return array( 'PHPUnit\\Runner\\Filter\\GroupFilterIterator' => $vendorDir . '/phpunit/phpunit/src/Runner/Filter/GroupFilterIterator.php', 'PHPUnit\\Runner\\Filter\\IncludeGroupFilterIterator' => $vendorDir . '/phpunit/phpunit/src/Runner/Filter/IncludeGroupFilterIterator.php', 'PHPUnit\\Runner\\Filter\\NameFilterIterator' => $vendorDir . '/phpunit/phpunit/src/Runner/Filter/NameFilterIterator.php', + 'PHPUnit\\Runner\\Filter\\TestIdFilterIterator' => $vendorDir . '/phpunit/phpunit/src/Runner/Filter/TestIdFilterIterator.php', + 'PHPUnit\\Runner\\GarbageCollection\\ExecutionFinishedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Runner/GarbageCollection/Subscriber/ExecutionFinishedSubscriber.php', + 'PHPUnit\\Runner\\GarbageCollection\\ExecutionStartedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Runner/GarbageCollection/Subscriber/ExecutionStartedSubscriber.php', + 'PHPUnit\\Runner\\GarbageCollection\\GarbageCollectionHandler' => $vendorDir . '/phpunit/phpunit/src/Runner/GarbageCollection/GarbageCollectionHandler.php', + 'PHPUnit\\Runner\\GarbageCollection\\Subscriber' => $vendorDir . '/phpunit/phpunit/src/Runner/GarbageCollection/Subscriber/Subscriber.php', + 'PHPUnit\\Runner\\GarbageCollection\\TestFinishedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Runner/GarbageCollection/Subscriber/TestFinishedSubscriber.php', 'PHPUnit\\Runner\\InvalidOrderException' => $vendorDir . '/phpunit/phpunit/src/Runner/Exception/InvalidOrderException.php', 'PHPUnit\\Runner\\InvalidPhptFileException' => $vendorDir . '/phpunit/phpunit/src/Runner/Exception/InvalidPhptFileException.php', 'PHPUnit\\Runner\\NoIgnoredEventException' => $vendorDir . '/phpunit/phpunit/src/Runner/Exception/NoIgnoredEventException.php', @@ -623,6 +681,7 @@ return array( 'PHPUnit\\TestRunner\\TestResult\\Collector' => $vendorDir . '/phpunit/phpunit/src/Runner/TestResult/Collector.php', 'PHPUnit\\TestRunner\\TestResult\\ExecutionStartedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Runner/TestResult/Subscriber/ExecutionStartedSubscriber.php', 'PHPUnit\\TestRunner\\TestResult\\Facade' => $vendorDir . '/phpunit/phpunit/src/Runner/TestResult/Facade.php', + 'PHPUnit\\TestRunner\\TestResult\\Issues\\Issue' => $vendorDir . '/phpunit/phpunit/src/Runner/TestResult/Issue.php', 'PHPUnit\\TestRunner\\TestResult\\PassedTests' => $vendorDir . '/phpunit/phpunit/src/Runner/TestResult/PassedTests.php', 'PHPUnit\\TestRunner\\TestResult\\Subscriber' => $vendorDir . '/phpunit/phpunit/src/Runner/TestResult/Subscriber/Subscriber.php', 'PHPUnit\\TestRunner\\TestResult\\TestConsideredRiskySubscriber' => $vendorDir . '/phpunit/phpunit/src/Runner/TestResult/Subscriber/TestConsideredRiskySubscriber.php', @@ -636,6 +695,7 @@ return array( 'PHPUnit\\TestRunner\\TestResult\\TestRunnerTriggeredWarningSubscriber' => $vendorDir . '/phpunit/phpunit/src/Runner/TestResult/Subscriber/TestRunnerTriggeredWarningSubscriber.php', 'PHPUnit\\TestRunner\\TestResult\\TestSkippedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Runner/TestResult/Subscriber/TestSkippedSubscriber.php', 'PHPUnit\\TestRunner\\TestResult\\TestSuiteFinishedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Runner/TestResult/Subscriber/TestSuiteFinishedSubscriber.php', + 'PHPUnit\\TestRunner\\TestResult\\TestSuiteSkippedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Runner/TestResult/Subscriber/TestSuiteSkippedSubscriber.php', 'PHPUnit\\TestRunner\\TestResult\\TestSuiteStartedSubscriber' => $vendorDir . '/phpunit/phpunit/src/Runner/TestResult/Subscriber/TestSuiteStartedSubscriber.php', 'PHPUnit\\TestRunner\\TestResult\\TestTriggeredDeprecationSubscriber' => $vendorDir . '/phpunit/phpunit/src/Runner/TestResult/Subscriber/TestTriggeredDeprecationSubscriber.php', 'PHPUnit\\TestRunner\\TestResult\\TestTriggeredErrorSubscriber' => $vendorDir . '/phpunit/phpunit/src/Runner/TestResult/Subscriber/TestTriggeredErrorSubscriber.php', @@ -696,6 +756,7 @@ return array( 'PHPUnit\\TextUI\\Configuration\\IniSettingCollectionIterator' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Value/IniSettingCollectionIterator.php', 'PHPUnit\\TextUI\\Configuration\\LoggingNotConfiguredException' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Exception/LoggingNotConfiguredException.php', 'PHPUnit\\TextUI\\Configuration\\Merger' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Merger.php', + 'PHPUnit\\TextUI\\Configuration\\NoBaselineException' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Exception/NoBaselineException.php', 'PHPUnit\\TextUI\\Configuration\\NoBootstrapException' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Exception/NoBootstrapException.php', 'PHPUnit\\TextUI\\Configuration\\NoCacheDirectoryException' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Exception/NoCacheDirectoryException.php', 'PHPUnit\\TextUI\\Configuration\\NoCliArgumentException' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Exception/NoCliArgumentException.php', @@ -707,6 +768,9 @@ return array( 'PHPUnit\\TextUI\\Configuration\\Php' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Value/Php.php', 'PHPUnit\\TextUI\\Configuration\\PhpHandler' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/PhpHandler.php', 'PHPUnit\\TextUI\\Configuration\\Registry' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Registry.php', + 'PHPUnit\\TextUI\\Configuration\\Source' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Value/Source.php', + 'PHPUnit\\TextUI\\Configuration\\SourceFilter' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/SourceFilter.php', + 'PHPUnit\\TextUI\\Configuration\\SourceMapper' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/SourceMapper.php', 'PHPUnit\\TextUI\\Configuration\\TestDirectory' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Value/TestDirectory.php', 'PHPUnit\\TextUI\\Configuration\\TestDirectoryCollection' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Value/TestDirectoryCollection.php', 'PHPUnit\\TextUI\\Configuration\\TestDirectoryCollectionIterator' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Value/TestDirectoryCollectionIterator.php', @@ -720,9 +784,11 @@ return array( 'PHPUnit\\TextUI\\Configuration\\Variable' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Value/Variable.php', 'PHPUnit\\TextUI\\Configuration\\VariableCollection' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Value/VariableCollection.php', 'PHPUnit\\TextUI\\Configuration\\VariableCollectionIterator' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Value/VariableCollectionIterator.php', + 'PHPUnit\\TextUI\\DirectoryDoesNotExistException' => $vendorDir . '/phpunit/phpunit/src/TextUI/Exception/DirectoryDoesNotExistException.php', 'PHPUnit\\TextUI\\Exception' => $vendorDir . '/phpunit/phpunit/src/TextUI/Exception/Exception.php', 'PHPUnit\\TextUI\\ExtensionsNotConfiguredException' => $vendorDir . '/phpunit/phpunit/src/TextUI/Exception/ExtensionsNotConfiguredException.php', 'PHPUnit\\TextUI\\Help' => $vendorDir . '/phpunit/phpunit/src/TextUI/Help.php', + 'PHPUnit\\TextUI\\InvalidSocketException' => $vendorDir . '/phpunit/phpunit/src/TextUI/Exception/InvalidSocketException.php', 'PHPUnit\\TextUI\\Output\\DefaultPrinter' => $vendorDir . '/phpunit/phpunit/src/TextUI/Output/Printer/DefaultPrinter.php', 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\BeforeTestClassMethodErroredSubscriber' => $vendorDir . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/Subscriber/BeforeTestClassMethodErroredSubscriber.php', 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\ProgressPrinter' => $vendorDir . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/ProgressPrinter.php', @@ -736,6 +802,7 @@ return array( 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\TestRunnerExecutionStartedSubscriber' => $vendorDir . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/Subscriber/TestRunnerExecutionStartedSubscriber.php', 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\TestSkippedSubscriber' => $vendorDir . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/Subscriber/TestSkippedSubscriber.php', 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\TestTriggeredDeprecationSubscriber' => $vendorDir . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/Subscriber/TestTriggeredDeprecationSubscriber.php', + 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\TestTriggeredErrorSubscriber' => $vendorDir . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/Subscriber/TestTriggeredErrorSubscriber.php', 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\TestTriggeredNoticeSubscriber' => $vendorDir . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/Subscriber/TestTriggeredNoticeSubscriber.php', 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\TestTriggeredPhpDeprecationSubscriber' => $vendorDir . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/Subscriber/TestTriggeredPhpDeprecationSubscriber.php', 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\TestTriggeredPhpNoticeSubscriber' => $vendorDir . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/Subscriber/TestTriggeredPhpNoticeSubscriber.php', @@ -744,6 +811,7 @@ return array( 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\TestTriggeredPhpunitWarningSubscriber' => $vendorDir . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/Subscriber/TestTriggeredPhpunitWarningSubscriber.php', 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\TestTriggeredWarningSubscriber' => $vendorDir . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/Subscriber/TestTriggeredWarningSubscriber.php', 'PHPUnit\\TextUI\\Output\\Default\\ResultPrinter' => $vendorDir . '/phpunit/phpunit/src/TextUI/Output/Default/ResultPrinter.php', + 'PHPUnit\\TextUI\\Output\\Default\\UnexpectedOutputPrinter' => $vendorDir . '/phpunit/phpunit/src/TextUI/Output/Default/UnexpectedOutputPrinter.php', 'PHPUnit\\TextUI\\Output\\Facade' => $vendorDir . '/phpunit/phpunit/src/TextUI/Output/Facade.php', 'PHPUnit\\TextUI\\Output\\NullPrinter' => $vendorDir . '/phpunit/phpunit/src/TextUI/Output/Printer/NullPrinter.php', 'PHPUnit\\TextUI\\Output\\Printer' => $vendorDir . '/phpunit/phpunit/src/TextUI/Output/Printer/Printer.php', @@ -756,6 +824,7 @@ return array( 'PHPUnit\\TextUI\\TestFileNotFoundException' => $vendorDir . '/phpunit/phpunit/src/TextUI/Exception/TestFileNotFoundException.php', 'PHPUnit\\TextUI\\TestRunner' => $vendorDir . '/phpunit/phpunit/src/TextUI/TestRunner.php', 'PHPUnit\\TextUI\\TestSuiteFilterProcessor' => $vendorDir . '/phpunit/phpunit/src/TextUI/TestSuiteFilterProcessor.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CannotFindSchemaException' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Exception/CannotFindSchemaException.php', 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\CodeCoverage' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/CodeCoverage/CodeCoverage.php', 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Report\\Clover' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/CodeCoverage/Report/Clover.php', 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Report\\Cobertura' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/CodeCoverage/Report/Cobertura.php', @@ -774,6 +843,7 @@ return array( 'PHPUnit\\TextUI\\XmlConfiguration\\CoverageXmlToReport' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/CoverageXmlToReport.php', 'PHPUnit\\TextUI\\XmlConfiguration\\DefaultConfiguration' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/DefaultConfiguration.php', 'PHPUnit\\TextUI\\XmlConfiguration\\Exception' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Exception.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\FailedSchemaDetectionResult' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/SchemaDetector/FailedSchemaDetectionResult.php', 'PHPUnit\\TextUI\\XmlConfiguration\\Generator' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Generator.php', 'PHPUnit\\TextUI\\XmlConfiguration\\Groups' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Groups.php', 'PHPUnit\\TextUI\\XmlConfiguration\\IntroduceCacheDirectoryAttribute' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/IntroduceCacheDirectoryAttribute.php', @@ -793,8 +863,9 @@ return array( 'PHPUnit\\TextUI\\XmlConfiguration\\Migrator' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrator.php', 'PHPUnit\\TextUI\\XmlConfiguration\\MoveAttributesFromFilterWhitelistToCoverage' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/MoveAttributesFromFilterWhitelistToCoverage.php', 'PHPUnit\\TextUI\\XmlConfiguration\\MoveAttributesFromRootToCoverage' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/MoveAttributesFromRootToCoverage.php', - 'PHPUnit\\TextUI\\XmlConfiguration\\MoveWhitelistDirectoriesToCoverage' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/MoveWhitelistDirectoriesToCoverage.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\MoveCoverageDirectoriesToSource' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/MoveCoverageDirectoriesToSource.php', 'PHPUnit\\TextUI\\XmlConfiguration\\MoveWhitelistExcludesToCoverage' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/MoveWhitelistExcludesToCoverage.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\MoveWhitelistIncludesToCoverage' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/MoveWhitelistIncludesToCoverage.php', 'PHPUnit\\TextUI\\XmlConfiguration\\PHPUnit' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/PHPUnit.php', 'PHPUnit\\TextUI\\XmlConfiguration\\RemoveBeStrictAboutResourceUsageDuringSmallTestsAttribute' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/RemoveBeStrictAboutResourceUsageDuringSmallTestsAttribute.php', 'PHPUnit\\TextUI\\XmlConfiguration\\RemoveBeStrictAboutTodoAnnotatedTestsAttribute' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/RemoveBeStrictAboutTodoAnnotatedTestsAttribute.php', @@ -815,23 +886,27 @@ return array( 'PHPUnit\\TextUI\\XmlConfiguration\\RenameBackupStaticAttributesAttribute' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/RenameBackupStaticAttributesAttribute.php', 'PHPUnit\\TextUI\\XmlConfiguration\\RenameBeStrictAboutCoversAnnotationAttribute' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/RenameBeStrictAboutCoversAnnotationAttribute.php', 'PHPUnit\\TextUI\\XmlConfiguration\\RenameForceCoversAnnotationAttribute' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/RenameForceCoversAnnotationAttribute.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\SchemaDetectionResult' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/SchemaDetector/SchemaDetectionResult.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\SchemaDetector' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/SchemaDetector/SchemaDetector.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\SchemaFinder' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/SchemaFinder.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\SnapshotNodeList' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/SnapshotNodeList.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\SuccessfulSchemaDetectionResult' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/SchemaDetector/SuccessfulSchemaDetectionResult.php', 'PHPUnit\\TextUI\\XmlConfiguration\\TestSuiteMapper' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/TestSuiteMapper.php', 'PHPUnit\\TextUI\\XmlConfiguration\\UpdateSchemaLocation' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/UpdateSchemaLocation.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\ValidationResult' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Validator/ValidationResult.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Validator' => $vendorDir . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Validator/Validator.php', 'PHPUnit\\Util\\Cloner' => $vendorDir . '/phpunit/phpunit/src/Util/Cloner.php', 'PHPUnit\\Util\\Color' => $vendorDir . '/phpunit/phpunit/src/Util/Color.php', - 'PHPUnit\\Util\\DirectoryDoesNotExistException' => $vendorDir . '/phpunit/phpunit/src/Util/Exception/DirectoryDoesNotExistException.php', - 'PHPUnit\\Util\\ErrorHandler' => $vendorDir . '/phpunit/phpunit/src/Util/ErrorHandler.php', 'PHPUnit\\Util\\Exception' => $vendorDir . '/phpunit/phpunit/src/Util/Exception/Exception.php', 'PHPUnit\\Util\\ExcludeList' => $vendorDir . '/phpunit/phpunit/src/Util/ExcludeList.php', + 'PHPUnit\\Util\\Exporter' => $vendorDir . '/phpunit/phpunit/src/Util/Exporter.php', 'PHPUnit\\Util\\Filesystem' => $vendorDir . '/phpunit/phpunit/src/Util/Filesystem.php', 'PHPUnit\\Util\\Filter' => $vendorDir . '/phpunit/phpunit/src/Util/Filter.php', 'PHPUnit\\Util\\GlobalState' => $vendorDir . '/phpunit/phpunit/src/Util/GlobalState.php', 'PHPUnit\\Util\\InvalidDirectoryException' => $vendorDir . '/phpunit/phpunit/src/Util/Exception/InvalidDirectoryException.php', 'PHPUnit\\Util\\InvalidJsonException' => $vendorDir . '/phpunit/phpunit/src/Util/Exception/InvalidJsonException.php', - 'PHPUnit\\Util\\InvalidSocketException' => $vendorDir . '/phpunit/phpunit/src/Util/Exception/InvalidSocketException.php', 'PHPUnit\\Util\\InvalidVersionOperatorException' => $vendorDir . '/phpunit/phpunit/src/Util/Exception/InvalidVersionOperatorException.php', 'PHPUnit\\Util\\Json' => $vendorDir . '/phpunit/phpunit/src/Util/Json.php', - 'PHPUnit\\Util\\NoTestCaseObjectOnCallStackException' => $vendorDir . '/phpunit/phpunit/src/Util/Exception/NoTestCaseObjectOnCallStackException.php', 'PHPUnit\\Util\\PHP\\AbstractPhpProcess' => $vendorDir . '/phpunit/phpunit/src/Util/PHP/AbstractPhpProcess.php', 'PHPUnit\\Util\\PHP\\DefaultPhpProcess' => $vendorDir . '/phpunit/phpunit/src/Util/PHP/DefaultPhpProcess.php', 'PHPUnit\\Util\\PHP\\PhpProcessException' => $vendorDir . '/phpunit/phpunit/src/Util/Exception/PhpProcessException.php', @@ -840,17 +915,8 @@ return array( 'PHPUnit\\Util\\Test' => $vendorDir . '/phpunit/phpunit/src/Util/Test.php', 'PHPUnit\\Util\\ThrowableToStringMapper' => $vendorDir . '/phpunit/phpunit/src/Util/ThrowableToStringMapper.php', 'PHPUnit\\Util\\VersionComparisonOperator' => $vendorDir . '/phpunit/phpunit/src/Util/VersionComparisonOperator.php', - 'PHPUnit\\Util\\Xml' => $vendorDir . '/phpunit/phpunit/src/Util/Xml.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' => $vendorDir . '/phpunit/phpunit/src/Util/Xml/Xml.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', 'PHPUnit\\Util\\Xml\\XmlException' => $vendorDir . '/phpunit/phpunit/src/Util/Exception/XmlException.php', 'PharIo\\Manifest\\Application' => $vendorDir . '/phar-io/manifest/src/values/Application.php', 'PharIo\\Manifest\\ApplicationName' => $vendorDir . '/phar-io/manifest/src/values/ApplicationName.php', diff --git a/vendor/composer/autoload_static.php b/vendor/composer/autoload_static.php index 12d83cbb..a4f6197f 100644 --- a/vendor/composer/autoload_static.php +++ b/vendor/composer/autoload_static.php @@ -255,13 +255,18 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\Event\\Application\\StartedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Application/StartedSubscriber.php', 'PHPUnit\\Event\\Code\\ClassMethod' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/ClassMethod.php', 'PHPUnit\\Event\\Code\\ComparisonFailure' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/ComparisonFailure.php', + 'PHPUnit\\Event\\Code\\ComparisonFailureBuilder' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/ComparisonFailureBuilder.php', + 'PHPUnit\\Event\\Code\\NoTestCaseObjectOnCallStackException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Exception/NoTestCaseObjectOnCallStackException.php', 'PHPUnit\\Event\\Code\\Phpt' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/Test/Phpt.php', 'PHPUnit\\Event\\Code\\Test' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/Test/Test.php', 'PHPUnit\\Event\\Code\\TestCollection' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/Test/TestCollection.php', 'PHPUnit\\Event\\Code\\TestCollectionIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/Test/TestCollectionIterator.php', 'PHPUnit\\Event\\Code\\TestDox' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/Test/TestDox.php', + 'PHPUnit\\Event\\Code\\TestDoxBuilder' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/Test/TestDoxBuilder.php', 'PHPUnit\\Event\\Code\\TestMethod' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/Test/TestMethod.php', + 'PHPUnit\\Event\\Code\\TestMethodBuilder' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/Test/TestMethodBuilder.php', 'PHPUnit\\Event\\Code\\Throwable' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/Throwable.php', + 'PHPUnit\\Event\\Code\\ThrowableBuilder' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/ThrowableBuilder.php', 'PHPUnit\\Event\\CollectingDispatcher' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Dispatcher/CollectingDispatcher.php', 'PHPUnit\\Event\\DeferringDispatcher' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Dispatcher/DeferringDispatcher.php', 'PHPUnit\\Event\\DirectDispatcher' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Dispatcher/DirectDispatcher.php', @@ -289,10 +294,14 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\Event\\Subscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Subscriber.php', 'PHPUnit\\Event\\SubscriberTypeAlreadyRegisteredException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Exception/SubscriberTypeAlreadyRegisteredException.php', 'PHPUnit\\Event\\Telemetry\\Duration' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/Telemetry/Duration.php', + 'PHPUnit\\Event\\Telemetry\\GarbageCollectorStatus' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/Telemetry/GarbageCollectorStatus.php', + 'PHPUnit\\Event\\Telemetry\\GarbageCollectorStatusProvider' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/Telemetry/GarbageCollectorStatusProvider.php', 'PHPUnit\\Event\\Telemetry\\HRTime' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/Telemetry/HRTime.php', 'PHPUnit\\Event\\Telemetry\\Info' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/Telemetry/Info.php', 'PHPUnit\\Event\\Telemetry\\MemoryMeter' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/Telemetry/MemoryMeter.php', 'PHPUnit\\Event\\Telemetry\\MemoryUsage' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/Telemetry/MemoryUsage.php', + 'PHPUnit\\Event\\Telemetry\\Php81GarbageCollectorStatusProvider' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/Telemetry/Php81GarbageCollectorStatusProvider.php', + 'PHPUnit\\Event\\Telemetry\\Php83GarbageCollectorStatusProvider' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/Telemetry/Php83GarbageCollectorStatusProvider.php', 'PHPUnit\\Event\\Telemetry\\Snapshot' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/Telemetry/Snapshot.php', 'PHPUnit\\Event\\Telemetry\\StopWatch' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/Telemetry/StopWatch.php', 'PHPUnit\\Event\\Telemetry\\System' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/Telemetry/System.php', @@ -314,6 +323,8 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\Event\\TestRunner\\DeprecationTriggeredSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestRunner/DeprecationTriggeredSubscriber.php', 'PHPUnit\\Event\\TestRunner\\EventFacadeSealed' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestRunner/EventFacadeSealed.php', 'PHPUnit\\Event\\TestRunner\\EventFacadeSealedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestRunner/EventFacadeSealedSubscriber.php', + 'PHPUnit\\Event\\TestRunner\\ExecutionAborted' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionAborted.php', + 'PHPUnit\\Event\\TestRunner\\ExecutionAbortedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionAbortedSubscriber.php', 'PHPUnit\\Event\\TestRunner\\ExecutionFinished' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionFinished.php', 'PHPUnit\\Event\\TestRunner\\ExecutionFinishedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionFinishedSubscriber.php', 'PHPUnit\\Event\\TestRunner\\ExecutionStarted' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionStarted.php', @@ -324,6 +335,12 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\Event\\TestRunner\\ExtensionLoadedFromPharSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestRunner/ExtensionLoadedFromPharSubscriber.php', 'PHPUnit\\Event\\TestRunner\\Finished' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestRunner/Finished.php', 'PHPUnit\\Event\\TestRunner\\FinishedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestRunner/FinishedSubscriber.php', + 'PHPUnit\\Event\\TestRunner\\GarbageCollectionDisabled' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionDisabled.php', + 'PHPUnit\\Event\\TestRunner\\GarbageCollectionDisabledSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionDisabledSubscriber.php', + 'PHPUnit\\Event\\TestRunner\\GarbageCollectionEnabled' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionEnabled.php', + 'PHPUnit\\Event\\TestRunner\\GarbageCollectionEnabledSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionEnabledSubscriber.php', + 'PHPUnit\\Event\\TestRunner\\GarbageCollectionTriggered' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionTriggered.php', + 'PHPUnit\\Event\\TestRunner\\GarbageCollectionTriggeredSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionTriggeredSubscriber.php', 'PHPUnit\\Event\\TestRunner\\Started' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestRunner/Started.php', 'PHPUnit\\Event\\TestRunner\\StartedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestRunner/StartedSubscriber.php', 'PHPUnit\\Event\\TestRunner\\WarningTriggered' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestRunner/WarningTriggered.php', @@ -334,11 +351,14 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\Event\\TestSuite\\FinishedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestSuite/FinishedSubscriber.php', 'PHPUnit\\Event\\TestSuite\\Loaded' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestSuite/Loaded.php', 'PHPUnit\\Event\\TestSuite\\LoadedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestSuite/LoadedSubscriber.php', + 'PHPUnit\\Event\\TestSuite\\Skipped' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestSuite/Skipped.php', + 'PHPUnit\\Event\\TestSuite\\SkippedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestSuite/SkippedSubscriber.php', 'PHPUnit\\Event\\TestSuite\\Sorted' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestSuite/Sorted.php', 'PHPUnit\\Event\\TestSuite\\SortedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestSuite/SortedSubscriber.php', 'PHPUnit\\Event\\TestSuite\\Started' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestSuite/Started.php', 'PHPUnit\\Event\\TestSuite\\StartedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/TestSuite/StartedSubscriber.php', 'PHPUnit\\Event\\TestSuite\\TestSuite' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/TestSuite/TestSuite.php', + 'PHPUnit\\Event\\TestSuite\\TestSuiteBuilder' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/TestSuite/TestSuiteBuilder.php', 'PHPUnit\\Event\\TestSuite\\TestSuiteForTestClass' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/TestSuite/TestSuiteForTestClass.php', 'PHPUnit\\Event\\TestSuite\\TestSuiteForTestMethodWithDataProvider' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/TestSuite/TestSuiteForTestMethodWithDataProvider.php', 'PHPUnit\\Event\\TestSuite\\TestSuiteWithName' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Value/TestSuite/TestSuiteWithName.php', @@ -368,6 +388,10 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\Event\\Test\\ComparatorRegisteredSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/ComparatorRegisteredSubscriber.php', 'PHPUnit\\Event\\Test\\ConsideredRisky' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/Issue/ConsideredRisky.php', 'PHPUnit\\Event\\Test\\ConsideredRiskySubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/Issue/ConsideredRiskySubscriber.php', + 'PHPUnit\\Event\\Test\\DataProviderMethodCalled' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodCalled.php', + 'PHPUnit\\Event\\Test\\DataProviderMethodCalledSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodCalledSubscriber.php', + 'PHPUnit\\Event\\Test\\DataProviderMethodFinished' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodFinished.php', + 'PHPUnit\\Event\\Test\\DataProviderMethodFinishedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodFinishedSubscriber.php', 'PHPUnit\\Event\\Test\\DeprecationTriggered' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/Issue/DeprecationTriggered.php', 'PHPUnit\\Event\\Test\\DeprecationTriggeredSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/Issue/DeprecationTriggeredSubscriber.php', 'PHPUnit\\Event\\Test\\ErrorTriggered' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/Issue/ErrorTriggered.php', @@ -417,10 +441,14 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\Event\\Test\\PreConditionCalledSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/HookMethod/PreConditionCalledSubscriber.php', 'PHPUnit\\Event\\Test\\PreConditionFinished' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/HookMethod/PreConditionFinished.php', 'PHPUnit\\Event\\Test\\PreConditionFinishedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/HookMethod/PreConditionFinishedSubscriber.php', + 'PHPUnit\\Event\\Test\\PreparationFailed' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/Lifecycle/PreparationFailed.php', + 'PHPUnit\\Event\\Test\\PreparationFailedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/Lifecycle/PreparationFailedSubscriber.php', 'PHPUnit\\Event\\Test\\PreparationStarted' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/Lifecycle/PreparationStarted.php', 'PHPUnit\\Event\\Test\\PreparationStartedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/Lifecycle/PreparationStartedSubscriber.php', 'PHPUnit\\Event\\Test\\Prepared' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/Lifecycle/Prepared.php', 'PHPUnit\\Event\\Test\\PreparedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/Lifecycle/PreparedSubscriber.php', + 'PHPUnit\\Event\\Test\\PrintedUnexpectedOutput' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/PrintedUnexpectedOutput.php', + 'PHPUnit\\Event\\Test\\PrintedUnexpectedOutputSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/PrintedUnexpectedOutputSubscriber.php', 'PHPUnit\\Event\\Test\\Skipped' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/Outcome/Skipped.php', 'PHPUnit\\Event\\Test\\SkippedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/Outcome/SkippedSubscriber.php', 'PHPUnit\\Event\\Test\\TestProxyCreated' => __DIR__ . '/..' . '/phpunit/phpunit/src/Event/Events/Test/TestDouble/TestProxyCreated.php', @@ -466,6 +494,10 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\Framework\\Attributes\\ExcludeGlobalVariableFromBackup' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Attributes/ExcludeGlobalVariableFromBackup.php', 'PHPUnit\\Framework\\Attributes\\ExcludeStaticPropertyFromBackup' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Attributes/ExcludeStaticPropertyFromBackup.php', 'PHPUnit\\Framework\\Attributes\\Group' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Attributes/Group.php', + 'PHPUnit\\Framework\\Attributes\\IgnoreClassForCodeCoverage' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Attributes/IgnoreClassForCodeCoverage.php', + 'PHPUnit\\Framework\\Attributes\\IgnoreDeprecations' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Attributes/IgnoreDeprecations.php', + 'PHPUnit\\Framework\\Attributes\\IgnoreFunctionForCodeCoverage' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Attributes/IgnoreFunctionForCodeCoverage.php', + 'PHPUnit\\Framework\\Attributes\\IgnoreMethodForCodeCoverage' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Attributes/IgnoreMethodForCodeCoverage.php', 'PHPUnit\\Framework\\Attributes\\Large' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Attributes/Large.php', 'PHPUnit\\Framework\\Attributes\\Medium' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Attributes/Medium.php', 'PHPUnit\\Framework\\Attributes\\PostCondition' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Attributes/PostCondition.php', @@ -490,6 +522,7 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\Framework\\Attributes\\Ticket' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Attributes/Ticket.php', 'PHPUnit\\Framework\\Attributes\\UsesClass' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Attributes/UsesClass.php', 'PHPUnit\\Framework\\Attributes\\UsesFunction' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Attributes/UsesFunction.php', + 'PHPUnit\\Framework\\Attributes\\WithoutErrorHandler' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Attributes/WithoutErrorHandler.php', 'PHPUnit\\Framework\\CodeCoverageException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/CodeCoverageException.php', 'PHPUnit\\Framework\\ComparisonMethodDoesNotAcceptParameterTypeException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotAcceptParameterTypeException.php', 'PHPUnit\\Framework\\ComparisonMethodDoesNotDeclareBoolReturnTypeException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotDeclareBoolReturnTypeException.php', @@ -504,6 +537,8 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 '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\\ExceptionMessageIsOrContains' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionMessageIsOrContains.php', + 'PHPUnit\\Framework\\Constraint\\ExceptionMessageMatchesRegularExpression' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionMessageMatchesRegularExpression.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', @@ -526,15 +561,13 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 '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/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\\MessageIsOrContains' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Message/MessageIsOrContains.php', - 'PHPUnit\\Framework\\Constraint\\MessageMatchesRegularExpression' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Message/MessageMatchesRegularExpression.php', - 'PHPUnit\\Framework\\Constraint\\ObjectEquals' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/ObjectEquals.php', + 'PHPUnit\\Framework\\Constraint\\ObjectEquals' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Object/ObjectEquals.php', + 'PHPUnit\\Framework\\Constraint\\ObjectHasProperty' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Object/ObjectHasProperty.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', @@ -550,7 +583,6 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\Framework\\Constraint\\UnaryOperator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Operator/UnaryOperator.php', 'PHPUnit\\Framework\\DataProviderTestSuite' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/DataProviderTestSuite.php', 'PHPUnit\\Framework\\EmptyStringException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/EmptyStringException.php', - 'PHPUnit\\Framework\\Error' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/Error.php', 'PHPUnit\\Framework\\Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/Exception.php', 'PHPUnit\\Framework\\ExecutionOrderDependency' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/ExecutionOrderDependency.php', 'PHPUnit\\Framework\\ExpectationFailedException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/ExpectationFailedException.php', @@ -561,77 +593,83 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\Framework\\InvalidCoversTargetException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/InvalidCoversTargetException.php', 'PHPUnit\\Framework\\InvalidDataProviderException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/InvalidDataProviderException.php', 'PHPUnit\\Framework\\InvalidDependencyException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/InvalidDependencyException.php', - 'PHPUnit\\Framework\\MockObject\\Api' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Api/Api.php', 'PHPUnit\\Framework\\MockObject\\BadMethodCallException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/BadMethodCallException.php', - '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\\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\\Builder\\Identity' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/Identity.php', + 'PHPUnit\\Framework\\MockObject\\Builder\\InvocationMocker' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/InvocationMocker.php', + 'PHPUnit\\Framework\\MockObject\\Builder\\InvocationStubber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/InvocationStubber.php', + 'PHPUnit\\Framework\\MockObject\\Builder\\MethodNameMatch' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/MethodNameMatch.php', + 'PHPUnit\\Framework\\MockObject\\Builder\\ParametersMatch' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/ParametersMatch.php', + 'PHPUnit\\Framework\\MockObject\\Builder\\Stub' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/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\\ClassIsEnumerationException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsEnumerationException.php', - 'PHPUnit\\Framework\\MockObject\\ClassIsFinalException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsFinalException.php', - 'PHPUnit\\Framework\\MockObject\\ClassIsReadonlyException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsReadonlyException.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\\DoubledCloneMethod' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/DoubledCloneMethod.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\\Generator\\ClassAlreadyExistsException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ClassAlreadyExistsException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\ClassIsEnumerationException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ClassIsEnumerationException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\ClassIsFinalException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ClassIsFinalException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\ClassIsReadonlyException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ClassIsReadonlyException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\DuplicateMethodException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/DuplicateMethodException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/Exception.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\Generator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator/Generator.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\InvalidMethodNameException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/InvalidMethodNameException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\MockClass' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator/MockClass.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\MockMethod' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator/MockMethod.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\MockMethodSet' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator/MockMethodSet.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\MockTrait' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator/MockTrait.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\MockType' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator/MockType.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\OriginalConstructorInvocationRequiredException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/OriginalConstructorInvocationRequiredException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\ReflectionException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ReflectionException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\RuntimeException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/RuntimeException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\SoapExtensionNotAvailableException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/SoapExtensionNotAvailableException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\TemplateLoader' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator/TemplateLoader.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\UnknownClassException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/UnknownClassException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\UnknownTraitException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/UnknownTraitException.php', + 'PHPUnit\\Framework\\MockObject\\Generator\\UnknownTypeException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/UnknownTypeException.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\\Invocation' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Invocation.php', + 'PHPUnit\\Framework\\MockObject\\InvocationHandler' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/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\\Matcher' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/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\\Method' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/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\\MethodNameConstraint' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/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', - 'PHPUnit\\Framework\\MockObject\\MockMethodSet' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/MockMethodSet.php', - 'PHPUnit\\Framework\\MockObject\\MockObject' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/MockObject.php', - '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\\MockObject' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/MockObject.php', + 'PHPUnit\\Framework\\MockObject\\MockObjectApi' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/MockObjectApi.php', + 'PHPUnit\\Framework\\MockObject\\MockObjectInternal' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/MockObjectInternal.php', + 'PHPUnit\\Framework\\MockObject\\NeverReturningMethodException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/NeverReturningMethodException.php', + 'PHPUnit\\Framework\\MockObject\\ProxiedCloneMethod' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/ProxiedCloneMethod.php', 'PHPUnit\\Framework\\MockObject\\ReflectionException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Exception/ReflectionException.php', + 'PHPUnit\\Framework\\MockObject\\ReturnValueGenerator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/ReturnValueGenerator.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\\InvocationOrder' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Rule/InvocationOrder.php', - 'PHPUnit\\Framework\\MockObject\\Rule\\InvokedAtLeastCount' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedAtLeastCount.php', - 'PHPUnit\\Framework\\MockObject\\Rule\\InvokedAtLeastOnce' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedAtLeastOnce.php', - 'PHPUnit\\Framework\\MockObject\\Rule\\InvokedAtMostCount' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedAtMostCount.php', - 'PHPUnit\\Framework\\MockObject\\Rule\\InvokedCount' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedCount.php', - 'PHPUnit\\Framework\\MockObject\\Rule\\MethodName' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Rule/MethodName.php', - '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\\Rule\\AnyInvokedCount' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/AnyInvokedCount.php', + 'PHPUnit\\Framework\\MockObject\\Rule\\AnyParameters' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/AnyParameters.php', + 'PHPUnit\\Framework\\MockObject\\Rule\\InvocationOrder' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvocationOrder.php', + 'PHPUnit\\Framework\\MockObject\\Rule\\InvokedAtLeastCount' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvokedAtLeastCount.php', + 'PHPUnit\\Framework\\MockObject\\Rule\\InvokedAtLeastOnce' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvokedAtLeastOnce.php', + 'PHPUnit\\Framework\\MockObject\\Rule\\InvokedAtMostCount' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvokedAtMostCount.php', + 'PHPUnit\\Framework\\MockObject\\Rule\\InvokedCount' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvokedCount.php', + 'PHPUnit\\Framework\\MockObject\\Rule\\MethodName' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/MethodName.php', + 'PHPUnit\\Framework\\MockObject\\Rule\\Parameters' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/Parameters.php', + 'PHPUnit\\Framework\\MockObject\\Rule\\ParametersRule' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/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', - 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnArgument' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnArgument.php', - 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnCallback' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnCallback.php', - 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnReference' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnReference.php', - 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnSelf' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnSelf.php', - '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\\TemplateLoader' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/TemplateLoader.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\\MockObject\\Stub' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/Stub.php', + 'PHPUnit\\Framework\\MockObject\\StubApi' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/StubApi.php', + 'PHPUnit\\Framework\\MockObject\\StubInternal' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/StubInternal.php', + 'PHPUnit\\Framework\\MockObject\\Stub\\ConsecutiveCalls' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ConsecutiveCalls.php', + 'PHPUnit\\Framework\\MockObject\\Stub\\Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/Exception.php', + 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnArgument' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnArgument.php', + 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnCallback' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnCallback.php', + 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnReference' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnReference.php', + 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnSelf' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnSelf.php', + 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnStub' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnStub.php', + 'PHPUnit\\Framework\\MockObject\\Stub\\ReturnValueMap' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnValueMap.php', + 'PHPUnit\\Framework\\MockObject\\Stub\\Stub' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/Stub.php', 'PHPUnit\\Framework\\NoChildTestSuiteException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/NoChildTestSuiteException.php', 'PHPUnit\\Framework\\PhptAssertionFailedError' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/PhptAssertionFailedError.php', 'PHPUnit\\Framework\\ProcessIsolationException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/ProcessIsolationException.php', @@ -664,8 +702,8 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\Framework\\TestStatus\\Warning' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/TestStatus/Warning.php', 'PHPUnit\\Framework\\TestSuite' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/TestSuite.php', 'PHPUnit\\Framework\\TestSuiteIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/TestSuiteIterator.php', - 'PHPUnit\\Framework\\UnknownClassException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/UnknownClassException.php', 'PHPUnit\\Framework\\UnknownClassOrInterfaceException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/UnknownClassOrInterfaceException.php', + 'PHPUnit\\Framework\\UnknownTypeException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception/UnknownTypeException.php', 'PHPUnit\\Logging\\EventLogger' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/EventLogger.php', 'PHPUnit\\Logging\\Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/Exception.php', 'PHPUnit\\Logging\\JUnit\\JunitXmlLogger' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/JUnit/JunitXmlLogger.php', @@ -674,6 +712,8 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\Logging\\JUnit\\TestFailedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestFailedSubscriber.php', 'PHPUnit\\Logging\\JUnit\\TestFinishedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestFinishedSubscriber.php', 'PHPUnit\\Logging\\JUnit\\TestMarkedIncompleteSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestMarkedIncompleteSubscriber.php', + 'PHPUnit\\Logging\\JUnit\\TestPreparationFailedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestPreparationFailedSubscriber.php', + 'PHPUnit\\Logging\\JUnit\\TestPreparationStartedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestPreparationStartedSubscriber.php', 'PHPUnit\\Logging\\JUnit\\TestPreparedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestPreparedSubscriber.php', 'PHPUnit\\Logging\\JUnit\\TestRunnerExecutionFinishedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestRunnerExecutionFinishedSubscriber.php', 'PHPUnit\\Logging\\JUnit\\TestSkippedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestSkippedSubscriber.php', @@ -694,30 +734,24 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\Logging\\TestDox\\HtmlRenderer' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/HtmlRenderer.php', 'PHPUnit\\Logging\\TestDox\\NamePrettifier' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/NamePrettifier.php', 'PHPUnit\\Logging\\TestDox\\PlainTextRenderer' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/PlainTextRenderer.php', - 'PHPUnit\\Logging\\TestDox\\Subscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/Subscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestConsideredRiskySubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestConsideredRiskySubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestCreatedMockObjectForAbstractClassSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestCreatedMockObjectForAbstractClassSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestCreatedMockObjectForTraitSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestCreatedMockObjectForTraitSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestCreatedMockObjectFromWsdlSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestCreatedMockObjectFromWsdlSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestCreatedMockObjectSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestCreatedMockObjectSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestCreatedPartialMockObjectSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestCreatedPartialMockObjectSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestCreatedTestProxySubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestCreatedTestProxySubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestCreatedTestStubSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestCreatedTestStubSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestErroredSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestErroredSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestFailedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestFailedSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestFinishedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestFinishedSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestMarkedIncompleteSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestMarkedIncompleteSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestPassedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestPassedSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestPreparedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestPreparedSubscriber.php', - 'PHPUnit\\Logging\\TestDox\\TestResult' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/TestMethod/TestResult.php', - 'PHPUnit\\Logging\\TestDox\\TestResultCollection' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/TestMethod/TestResultCollection.php', - 'PHPUnit\\Logging\\TestDox\\TestResultCollectionIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/TestMethod/TestResultCollectionIterator.php', - 'PHPUnit\\Logging\\TestDox\\TestResultCollector' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/TestMethod/TestResultCollector.php', - 'PHPUnit\\Logging\\TestDox\\TestSkippedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/Subscriber/TestSkippedSubscriber.php', + 'PHPUnit\\Logging\\TestDox\\Subscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/TestResult/Subscriber/Subscriber.php', + 'PHPUnit\\Logging\\TestDox\\TestConsideredRiskySubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/TestResult/Subscriber/TestConsideredRiskySubscriber.php', + 'PHPUnit\\Logging\\TestDox\\TestErroredSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/TestResult/Subscriber/TestErroredSubscriber.php', + 'PHPUnit\\Logging\\TestDox\\TestFailedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/TestResult/Subscriber/TestFailedSubscriber.php', + 'PHPUnit\\Logging\\TestDox\\TestFinishedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/TestResult/Subscriber/TestFinishedSubscriber.php', + 'PHPUnit\\Logging\\TestDox\\TestMarkedIncompleteSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/TestResult/Subscriber/TestMarkedIncompleteSubscriber.php', + 'PHPUnit\\Logging\\TestDox\\TestPassedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/TestResult/Subscriber/TestPassedSubscriber.php', + 'PHPUnit\\Logging\\TestDox\\TestPreparedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/TestResult/Subscriber/TestPreparedSubscriber.php', + 'PHPUnit\\Logging\\TestDox\\TestResult' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/TestResult/TestResult.php', + 'PHPUnit\\Logging\\TestDox\\TestResultCollection' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/TestResult/TestResultCollection.php', + 'PHPUnit\\Logging\\TestDox\\TestResultCollectionIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/TestResult/TestResultCollectionIterator.php', + 'PHPUnit\\Logging\\TestDox\\TestResultCollector' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/TestResult/TestResultCollector.php', + 'PHPUnit\\Logging\\TestDox\\TestSkippedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Logging/TestDox/TestResult/Subscriber/TestSkippedSubscriber.php', 'PHPUnit\\Metadata\\After' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/After.php', 'PHPUnit\\Metadata\\AfterClass' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/AfterClass.php', 'PHPUnit\\Metadata\\Annotation\\Parser\\DocBlock' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/Parser/Annotation/DocBlock.php', 'PHPUnit\\Metadata\\Annotation\\Parser\\Registry' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/Parser/Annotation/Registry.php', + 'PHPUnit\\Metadata\\AnnotationsAreNotSupportedForInternalClassesException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/Exception/AnnotationsAreNotSupportedForInternalClassesException.php', 'PHPUnit\\Metadata\\Api\\CodeCoverage' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/Api/CodeCoverage.php', 'PHPUnit\\Metadata\\Api\\DataProvider' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/Api/DataProvider.php', 'PHPUnit\\Metadata\\Api\\Dependencies' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/Api/Dependencies.php', @@ -728,7 +762,6 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\Metadata\\BackupStaticProperties' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/BackupStaticProperties.php', 'PHPUnit\\Metadata\\Before' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/Before.php', 'PHPUnit\\Metadata\\BeforeClass' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/BeforeClass.php', - 'PHPUnit\\Metadata\\CodeCoverageIgnore' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/CodeCoverageIgnore.php', 'PHPUnit\\Metadata\\Covers' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/Covers.php', 'PHPUnit\\Metadata\\CoversClass' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/CoversClass.php', 'PHPUnit\\Metadata\\CoversDefaultClass' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/CoversDefaultClass.php', @@ -742,6 +775,10 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\Metadata\\ExcludeGlobalVariableFromBackup' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/ExcludeGlobalVariableFromBackup.php', 'PHPUnit\\Metadata\\ExcludeStaticPropertyFromBackup' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/ExcludeStaticPropertyFromBackup.php', 'PHPUnit\\Metadata\\Group' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/Group.php', + 'PHPUnit\\Metadata\\IgnoreClassForCodeCoverage' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/IgnoreClassForCodeCoverage.php', + 'PHPUnit\\Metadata\\IgnoreDeprecations' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/IgnoreDeprecations.php', + 'PHPUnit\\Metadata\\IgnoreFunctionForCodeCoverage' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/IgnoreFunctionForCodeCoverage.php', + 'PHPUnit\\Metadata\\IgnoreMethodForCodeCoverage' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/IgnoreMethodForCodeCoverage.php', 'PHPUnit\\Metadata\\InvalidVersionRequirementException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/Exception/InvalidVersionRequirementException.php', 'PHPUnit\\Metadata\\Metadata' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/Metadata.php', 'PHPUnit\\Metadata\\MetadataCollection' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/MetadataCollection.php', @@ -778,13 +815,28 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\Metadata\\Version\\ComparisonRequirement' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/Version/ComparisonRequirement.php', 'PHPUnit\\Metadata\\Version\\ConstraintRequirement' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/Version/ConstraintRequirement.php', 'PHPUnit\\Metadata\\Version\\Requirement' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/Version/Requirement.php', + 'PHPUnit\\Metadata\\WithoutErrorHandler' => __DIR__ . '/..' . '/phpunit/phpunit/src/Metadata/WithoutErrorHandler.php', + 'PHPUnit\\Runner\\Baseline\\Baseline' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Baseline/Baseline.php', + 'PHPUnit\\Runner\\Baseline\\CannotLoadBaselineException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Baseline/Exception/CannotLoadBaselineException.php', + 'PHPUnit\\Runner\\Baseline\\FileDoesNotHaveLineException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Baseline/Exception/FileDoesNotHaveLineException.php', + 'PHPUnit\\Runner\\Baseline\\Generator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Baseline/Generator.php', + 'PHPUnit\\Runner\\Baseline\\Issue' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Baseline/Issue.php', + 'PHPUnit\\Runner\\Baseline\\Reader' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Baseline/Reader.php', + 'PHPUnit\\Runner\\Baseline\\RelativePathCalculator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Baseline/RelativePathCalculator.php', + 'PHPUnit\\Runner\\Baseline\\Subscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Baseline/Subscriber/Subscriber.php', + 'PHPUnit\\Runner\\Baseline\\TestTriggeredDeprecationSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Baseline/Subscriber/TestTriggeredDeprecationSubscriber.php', + 'PHPUnit\\Runner\\Baseline\\TestTriggeredNoticeSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Baseline/Subscriber/TestTriggeredNoticeSubscriber.php', + 'PHPUnit\\Runner\\Baseline\\TestTriggeredPhpDeprecationSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Baseline/Subscriber/TestTriggeredPhpDeprecationSubscriber.php', + 'PHPUnit\\Runner\\Baseline\\TestTriggeredPhpNoticeSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Baseline/Subscriber/TestTriggeredPhpNoticeSubscriber.php', + 'PHPUnit\\Runner\\Baseline\\TestTriggeredPhpWarningSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Baseline/Subscriber/TestTriggeredPhpWarningSubscriber.php', + 'PHPUnit\\Runner\\Baseline\\TestTriggeredWarningSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Baseline/Subscriber/TestTriggeredWarningSubscriber.php', + 'PHPUnit\\Runner\\Baseline\\Writer' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Baseline/Writer.php', 'PHPUnit\\Runner\\ClassCannotBeFoundException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Exception/ClassCannotBeFoundException.php', - 'PHPUnit\\Runner\\ClassCannotBeInstantiatedException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Exception/ClassCannotBeInstantiatedException.php', - 'PHPUnit\\Runner\\ClassDoesNotExistException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Exception/ClassDoesNotExistException.php', - 'PHPUnit\\Runner\\ClassDoesNotImplementExtensionInterfaceException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Exception/ClassDoesNotImplementExtensionInterfaceException.php', + 'PHPUnit\\Runner\\ClassDoesNotExtendTestCaseException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Exception/ClassDoesNotExtendTestCaseException.php', 'PHPUnit\\Runner\\ClassIsAbstractException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Exception/ClassIsAbstractException.php', 'PHPUnit\\Runner\\CodeCoverage' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/CodeCoverage.php', 'PHPUnit\\Runner\\DirectoryCannotBeCreatedException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Exception/DirectoryCannotBeCreatedException.php', + 'PHPUnit\\Runner\\ErrorHandler' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/ErrorHandler.php', 'PHPUnit\\Runner\\Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Exception/Exception.php', 'PHPUnit\\Runner\\Extension\\Extension' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Extension/Extension.php', 'PHPUnit\\Runner\\Extension\\ExtensionBootstrapper' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Extension/ExtensionBootstrapper.php', @@ -797,6 +849,12 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\Runner\\Filter\\GroupFilterIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Filter/GroupFilterIterator.php', 'PHPUnit\\Runner\\Filter\\IncludeGroupFilterIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Filter/IncludeGroupFilterIterator.php', 'PHPUnit\\Runner\\Filter\\NameFilterIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Filter/NameFilterIterator.php', + 'PHPUnit\\Runner\\Filter\\TestIdFilterIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Filter/TestIdFilterIterator.php', + 'PHPUnit\\Runner\\GarbageCollection\\ExecutionFinishedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/GarbageCollection/Subscriber/ExecutionFinishedSubscriber.php', + 'PHPUnit\\Runner\\GarbageCollection\\ExecutionStartedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/GarbageCollection/Subscriber/ExecutionStartedSubscriber.php', + 'PHPUnit\\Runner\\GarbageCollection\\GarbageCollectionHandler' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/GarbageCollection/GarbageCollectionHandler.php', + 'PHPUnit\\Runner\\GarbageCollection\\Subscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/GarbageCollection/Subscriber/Subscriber.php', + 'PHPUnit\\Runner\\GarbageCollection\\TestFinishedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/GarbageCollection/Subscriber/TestFinishedSubscriber.php', 'PHPUnit\\Runner\\InvalidOrderException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Exception/InvalidOrderException.php', 'PHPUnit\\Runner\\InvalidPhptFileException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Exception/InvalidPhptFileException.php', 'PHPUnit\\Runner\\NoIgnoredEventException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Exception/NoIgnoredEventException.php', @@ -826,6 +884,7 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\TestRunner\\TestResult\\Collector' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/TestResult/Collector.php', 'PHPUnit\\TestRunner\\TestResult\\ExecutionStartedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/TestResult/Subscriber/ExecutionStartedSubscriber.php', 'PHPUnit\\TestRunner\\TestResult\\Facade' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/TestResult/Facade.php', + 'PHPUnit\\TestRunner\\TestResult\\Issues\\Issue' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/TestResult/Issue.php', 'PHPUnit\\TestRunner\\TestResult\\PassedTests' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/TestResult/PassedTests.php', 'PHPUnit\\TestRunner\\TestResult\\Subscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/TestResult/Subscriber/Subscriber.php', 'PHPUnit\\TestRunner\\TestResult\\TestConsideredRiskySubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/TestResult/Subscriber/TestConsideredRiskySubscriber.php', @@ -839,6 +898,7 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\TestRunner\\TestResult\\TestRunnerTriggeredWarningSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/TestResult/Subscriber/TestRunnerTriggeredWarningSubscriber.php', 'PHPUnit\\TestRunner\\TestResult\\TestSkippedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/TestResult/Subscriber/TestSkippedSubscriber.php', 'PHPUnit\\TestRunner\\TestResult\\TestSuiteFinishedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/TestResult/Subscriber/TestSuiteFinishedSubscriber.php', + 'PHPUnit\\TestRunner\\TestResult\\TestSuiteSkippedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/TestResult/Subscriber/TestSuiteSkippedSubscriber.php', 'PHPUnit\\TestRunner\\TestResult\\TestSuiteStartedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/TestResult/Subscriber/TestSuiteStartedSubscriber.php', 'PHPUnit\\TestRunner\\TestResult\\TestTriggeredDeprecationSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/TestResult/Subscriber/TestTriggeredDeprecationSubscriber.php', 'PHPUnit\\TestRunner\\TestResult\\TestTriggeredErrorSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/TestResult/Subscriber/TestTriggeredErrorSubscriber.php', @@ -899,6 +959,7 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\TextUI\\Configuration\\IniSettingCollectionIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Value/IniSettingCollectionIterator.php', 'PHPUnit\\TextUI\\Configuration\\LoggingNotConfiguredException' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Exception/LoggingNotConfiguredException.php', 'PHPUnit\\TextUI\\Configuration\\Merger' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Merger.php', + 'PHPUnit\\TextUI\\Configuration\\NoBaselineException' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Exception/NoBaselineException.php', 'PHPUnit\\TextUI\\Configuration\\NoBootstrapException' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Exception/NoBootstrapException.php', 'PHPUnit\\TextUI\\Configuration\\NoCacheDirectoryException' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Exception/NoCacheDirectoryException.php', 'PHPUnit\\TextUI\\Configuration\\NoCliArgumentException' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Exception/NoCliArgumentException.php', @@ -910,6 +971,9 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\TextUI\\Configuration\\Php' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Value/Php.php', 'PHPUnit\\TextUI\\Configuration\\PhpHandler' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/PhpHandler.php', 'PHPUnit\\TextUI\\Configuration\\Registry' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Registry.php', + 'PHPUnit\\TextUI\\Configuration\\Source' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Value/Source.php', + 'PHPUnit\\TextUI\\Configuration\\SourceFilter' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/SourceFilter.php', + 'PHPUnit\\TextUI\\Configuration\\SourceMapper' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/SourceMapper.php', 'PHPUnit\\TextUI\\Configuration\\TestDirectory' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Value/TestDirectory.php', 'PHPUnit\\TextUI\\Configuration\\TestDirectoryCollection' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Value/TestDirectoryCollection.php', 'PHPUnit\\TextUI\\Configuration\\TestDirectoryCollectionIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Value/TestDirectoryCollectionIterator.php', @@ -923,9 +987,11 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\TextUI\\Configuration\\Variable' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Value/Variable.php', 'PHPUnit\\TextUI\\Configuration\\VariableCollection' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Value/VariableCollection.php', 'PHPUnit\\TextUI\\Configuration\\VariableCollectionIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Value/VariableCollectionIterator.php', + 'PHPUnit\\TextUI\\DirectoryDoesNotExistException' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Exception/DirectoryDoesNotExistException.php', 'PHPUnit\\TextUI\\Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Exception/Exception.php', 'PHPUnit\\TextUI\\ExtensionsNotConfiguredException' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Exception/ExtensionsNotConfiguredException.php', 'PHPUnit\\TextUI\\Help' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Help.php', + 'PHPUnit\\TextUI\\InvalidSocketException' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Exception/InvalidSocketException.php', 'PHPUnit\\TextUI\\Output\\DefaultPrinter' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Output/Printer/DefaultPrinter.php', 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\BeforeTestClassMethodErroredSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/Subscriber/BeforeTestClassMethodErroredSubscriber.php', 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\ProgressPrinter' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/ProgressPrinter.php', @@ -939,6 +1005,7 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\TestRunnerExecutionStartedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/Subscriber/TestRunnerExecutionStartedSubscriber.php', 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\TestSkippedSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/Subscriber/TestSkippedSubscriber.php', 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\TestTriggeredDeprecationSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/Subscriber/TestTriggeredDeprecationSubscriber.php', + 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\TestTriggeredErrorSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/Subscriber/TestTriggeredErrorSubscriber.php', 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\TestTriggeredNoticeSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/Subscriber/TestTriggeredNoticeSubscriber.php', 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\TestTriggeredPhpDeprecationSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/Subscriber/TestTriggeredPhpDeprecationSubscriber.php', 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\TestTriggeredPhpNoticeSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/Subscriber/TestTriggeredPhpNoticeSubscriber.php', @@ -947,6 +1014,7 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\TestTriggeredPhpunitWarningSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/Subscriber/TestTriggeredPhpunitWarningSubscriber.php', 'PHPUnit\\TextUI\\Output\\Default\\ProgressPrinter\\TestTriggeredWarningSubscriber' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Output/Default/ProgressPrinter/Subscriber/TestTriggeredWarningSubscriber.php', 'PHPUnit\\TextUI\\Output\\Default\\ResultPrinter' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Output/Default/ResultPrinter.php', + 'PHPUnit\\TextUI\\Output\\Default\\UnexpectedOutputPrinter' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Output/Default/UnexpectedOutputPrinter.php', 'PHPUnit\\TextUI\\Output\\Facade' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Output/Facade.php', 'PHPUnit\\TextUI\\Output\\NullPrinter' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Output/Printer/NullPrinter.php', 'PHPUnit\\TextUI\\Output\\Printer' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Output/Printer/Printer.php', @@ -959,6 +1027,7 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\TextUI\\TestFileNotFoundException' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Exception/TestFileNotFoundException.php', 'PHPUnit\\TextUI\\TestRunner' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/TestRunner.php', 'PHPUnit\\TextUI\\TestSuiteFilterProcessor' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/TestSuiteFilterProcessor.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\CannotFindSchemaException' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Exception/CannotFindSchemaException.php', 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\CodeCoverage' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/CodeCoverage/CodeCoverage.php', 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Report\\Clover' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/CodeCoverage/Report/Clover.php', 'PHPUnit\\TextUI\\XmlConfiguration\\CodeCoverage\\Report\\Cobertura' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/CodeCoverage/Report/Cobertura.php', @@ -977,6 +1046,7 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\TextUI\\XmlConfiguration\\CoverageXmlToReport' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/CoverageXmlToReport.php', 'PHPUnit\\TextUI\\XmlConfiguration\\DefaultConfiguration' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/DefaultConfiguration.php', 'PHPUnit\\TextUI\\XmlConfiguration\\Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Exception.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\FailedSchemaDetectionResult' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/SchemaDetector/FailedSchemaDetectionResult.php', 'PHPUnit\\TextUI\\XmlConfiguration\\Generator' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Generator.php', 'PHPUnit\\TextUI\\XmlConfiguration\\Groups' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Groups.php', 'PHPUnit\\TextUI\\XmlConfiguration\\IntroduceCacheDirectoryAttribute' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/IntroduceCacheDirectoryAttribute.php', @@ -996,8 +1066,9 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\TextUI\\XmlConfiguration\\Migrator' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrator.php', 'PHPUnit\\TextUI\\XmlConfiguration\\MoveAttributesFromFilterWhitelistToCoverage' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/MoveAttributesFromFilterWhitelistToCoverage.php', 'PHPUnit\\TextUI\\XmlConfiguration\\MoveAttributesFromRootToCoverage' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/MoveAttributesFromRootToCoverage.php', - 'PHPUnit\\TextUI\\XmlConfiguration\\MoveWhitelistDirectoriesToCoverage' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/MoveWhitelistDirectoriesToCoverage.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\MoveCoverageDirectoriesToSource' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/MoveCoverageDirectoriesToSource.php', 'PHPUnit\\TextUI\\XmlConfiguration\\MoveWhitelistExcludesToCoverage' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/MoveWhitelistExcludesToCoverage.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\MoveWhitelistIncludesToCoverage' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/MoveWhitelistIncludesToCoverage.php', 'PHPUnit\\TextUI\\XmlConfiguration\\PHPUnit' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/PHPUnit.php', 'PHPUnit\\TextUI\\XmlConfiguration\\RemoveBeStrictAboutResourceUsageDuringSmallTestsAttribute' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/RemoveBeStrictAboutResourceUsageDuringSmallTestsAttribute.php', 'PHPUnit\\TextUI\\XmlConfiguration\\RemoveBeStrictAboutTodoAnnotatedTestsAttribute' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/RemoveBeStrictAboutTodoAnnotatedTestsAttribute.php', @@ -1018,23 +1089,27 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\TextUI\\XmlConfiguration\\RenameBackupStaticAttributesAttribute' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/RenameBackupStaticAttributesAttribute.php', 'PHPUnit\\TextUI\\XmlConfiguration\\RenameBeStrictAboutCoversAnnotationAttribute' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/RenameBeStrictAboutCoversAnnotationAttribute.php', 'PHPUnit\\TextUI\\XmlConfiguration\\RenameForceCoversAnnotationAttribute' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/RenameForceCoversAnnotationAttribute.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\SchemaDetectionResult' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/SchemaDetector/SchemaDetectionResult.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\SchemaDetector' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/SchemaDetector/SchemaDetector.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\SchemaFinder' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/SchemaFinder.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\SnapshotNodeList' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/SnapshotNodeList.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\SuccessfulSchemaDetectionResult' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/SchemaDetector/SuccessfulSchemaDetectionResult.php', 'PHPUnit\\TextUI\\XmlConfiguration\\TestSuiteMapper' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/TestSuiteMapper.php', 'PHPUnit\\TextUI\\XmlConfiguration\\UpdateSchemaLocation' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Migration/Migrations/UpdateSchemaLocation.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\ValidationResult' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Validator/ValidationResult.php', + 'PHPUnit\\TextUI\\XmlConfiguration\\Validator' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Configuration/Xml/Validator/Validator.php', 'PHPUnit\\Util\\Cloner' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Cloner.php', 'PHPUnit\\Util\\Color' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Color.php', - 'PHPUnit\\Util\\DirectoryDoesNotExistException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Exception/DirectoryDoesNotExistException.php', - 'PHPUnit\\Util\\ErrorHandler' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/ErrorHandler.php', 'PHPUnit\\Util\\Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Exception/Exception.php', 'PHPUnit\\Util\\ExcludeList' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/ExcludeList.php', + 'PHPUnit\\Util\\Exporter' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Exporter.php', 'PHPUnit\\Util\\Filesystem' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Filesystem.php', 'PHPUnit\\Util\\Filter' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Filter.php', 'PHPUnit\\Util\\GlobalState' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/GlobalState.php', 'PHPUnit\\Util\\InvalidDirectoryException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Exception/InvalidDirectoryException.php', 'PHPUnit\\Util\\InvalidJsonException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Exception/InvalidJsonException.php', - 'PHPUnit\\Util\\InvalidSocketException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Exception/InvalidSocketException.php', 'PHPUnit\\Util\\InvalidVersionOperatorException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Exception/InvalidVersionOperatorException.php', 'PHPUnit\\Util\\Json' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Json.php', - 'PHPUnit\\Util\\NoTestCaseObjectOnCallStackException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Exception/NoTestCaseObjectOnCallStackException.php', 'PHPUnit\\Util\\PHP\\AbstractPhpProcess' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/PHP/AbstractPhpProcess.php', 'PHPUnit\\Util\\PHP\\DefaultPhpProcess' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/PHP/DefaultPhpProcess.php', 'PHPUnit\\Util\\PHP\\PhpProcessException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Exception/PhpProcessException.php', @@ -1043,17 +1118,8 @@ class ComposerStaticInit5f3db9fc1d0cf1dd6a77a1d84501b4b1 'PHPUnit\\Util\\Test' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Test.php', 'PHPUnit\\Util\\ThrowableToStringMapper' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/ThrowableToStringMapper.php', 'PHPUnit\\Util\\VersionComparisonOperator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/VersionComparisonOperator.php', - 'PHPUnit\\Util\\Xml' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Xml.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' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Xml/Xml.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', 'PHPUnit\\Util\\Xml\\XmlException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Exception/XmlException.php', 'PharIo\\Manifest\\Application' => __DIR__ . '/..' . '/phar-io/manifest/src/values/Application.php', 'PharIo\\Manifest\\ApplicationName' => __DIR__ . '/..' . '/phar-io/manifest/src/values/ApplicationName.php', diff --git a/vendor/composer/ca-bundle/composer.json b/vendor/composer/ca-bundle/composer.json index ed6a1b36..c85480ad 100644 --- a/vendor/composer/ca-bundle/composer.json +++ b/vendor/composer/ca-bundle/composer.json @@ -30,7 +30,7 @@ "symfony/phpunit-bridge": "^4.2 || ^5", "phpstan/phpstan": "^0.12.55", "psr/log": "^1.0", - "symfony/process": "^2.5 || ^3.0 || ^4.0 || ^5.0 || ^6.0" + "symfony/process": "^2.5 || ^3.0 || ^4.0 || ^5.0 || ^6.0 || ^7.0" }, "autoload": { "psr-4": { diff --git a/vendor/composer/ca-bundle/res/cacert.pem b/vendor/composer/ca-bundle/res/cacert.pem index 9551dfd8..d8fda7d1 100644 --- a/vendor/composer/ca-bundle/res/cacert.pem +++ b/vendor/composer/ca-bundle/res/cacert.pem @@ -1,7 +1,7 @@ ## ## Bundle of CA Root Certificates ## -## Certificate data from Mozilla as of: Tue Aug 22 03:12:04 2023 GMT +## Certificate data from Mozilla as of: Tue Dec 12 04:12:04 2023 GMT ## ## This is a bundle of X.509 certificates of public Certificate Authorities ## (CA). These were automatically extracted from Mozilla's root certificates @@ -14,7 +14,7 @@ ## Just configure this file as the SSLCACertificateFile. ## ## Conversion done with mk-ca-bundle.pl version 1.29. -## SHA256: 0ff137babc6a5561a9cfbe9f29558972e5b528202681b7d3803d03a3e82922bd +## SHA256: 1970dd65858925d68498d2356aea6d03f764422523c5887deca8ce3ba9e1f845 ## @@ -200,27 +200,6 @@ vGJHvOB0K7Lrfb5BG7XARsWhIstfTsEokt4YutUqKLsRixeTmJlglFwjz1onl14LBQaTNx47aTbr qZ5hHY8y2o4M1nQ+ewkk2gF3R8Q7zTSMmfXK4SVhM7JZG+Ju1zdXtg2pEto= -----END CERTIFICATE----- -Security Communication Root CA -============================== ------BEGIN CERTIFICATE----- -MIIDWjCCAkKgAwIBAgIBADANBgkqhkiG9w0BAQUFADBQMQswCQYDVQQGEwJKUDEYMBYGA1UEChMP -U0VDT00gVHJ1c3QubmV0MScwJQYDVQQLEx5TZWN1cml0eSBDb21tdW5pY2F0aW9uIFJvb3RDQTEw -HhcNMDMwOTMwMDQyMDQ5WhcNMjMwOTMwMDQyMDQ5WjBQMQswCQYDVQQGEwJKUDEYMBYGA1UEChMP -U0VDT00gVHJ1c3QubmV0MScwJQYDVQQLEx5TZWN1cml0eSBDb21tdW5pY2F0aW9uIFJvb3RDQTEw -ggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCzs/5/022x7xZ8V6UMbXaKL0u/ZPtM7orw -8yl89f/uKuDp6bpbZCKamm8sOiZpUQWZJtzVHGpxxpp9Hp3dfGzGjGdnSj74cbAZJ6kJDKaVv0uM -DPpVmDvY6CKhS3E4eayXkmmziX7qIWgGmBSWh9JhNrxtJ1aeV+7AwFb9Ms+k2Y7CI9eNqPPYJayX -5HA49LY6tJ07lyZDo6G8SVlyTCMwhwFY9k6+HGhWZq/NQV3Is00qVUarH9oe4kA92819uZKAnDfd -DJZkndwi92SL32HeFZRSFaB9UslLqCHJxrHty8OVYNEP8Ktw+N/LTX7s1vqr2b1/VPKl6Xn62dZ2 -JChzAgMBAAGjPzA9MB0GA1UdDgQWBBSgc0mZaNyFW2XjmygvV5+9M7wHSDALBgNVHQ8EBAMCAQYw -DwYDVR0TAQH/BAUwAwEB/zANBgkqhkiG9w0BAQUFAAOCAQEAaECpqLvkT115swW1F7NgE+vGkl3g -0dNq/vu+m22/xwVtWSDEHPC32oRYAmP6SBbvT6UL90qY8j+eG61Ha2POCEfrUj94nK9NrvjVT8+a -mCoQQTlSxN3Zmw7vkwGusi7KaEIkQmywszo+zenaSMQVy+n5Bw+SUEmK3TGXX8npN6o7WWWXlDLJ -s58+OmJYxUmtYg5xpTKqL8aJdkNAExNnPaJUJRDL8Try2frbSVa7pv6nQTXD4IhhyYjH3zYQIphZ -6rBK+1YWc26sTfcioU+tHXotRSflMMFe8toTyyVCUZVHA4xsIcx0Qu1T/zOLjw9XARYvz6buyXAi -FL39vmwLAw== ------END CERTIFICATE----- - XRamp Global CA Root ==================== -----BEGIN CERTIFICATE----- @@ -669,39 +648,6 @@ YIvDQVETI53O9zJrlAGomecsMx86OyXShkDOOyyGeMlhLxS67ttVb9+E7gUJTb0o2HLO02JQZR7r kpeDMdmztcpHWD9f -----END CERTIFICATE----- -Autoridad de Certificacion Firmaprofesional CIF A62634068 -========================================================= ------BEGIN CERTIFICATE----- -MIIGFDCCA/ygAwIBAgIIU+w77vuySF8wDQYJKoZIhvcNAQEFBQAwUTELMAkGA1UEBhMCRVMxQjBA -BgNVBAMMOUF1dG9yaWRhZCBkZSBDZXJ0aWZpY2FjaW9uIEZpcm1hcHJvZmVzaW9uYWwgQ0lGIEE2 -MjYzNDA2ODAeFw0wOTA1MjAwODM4MTVaFw0zMDEyMzEwODM4MTVaMFExCzAJBgNVBAYTAkVTMUIw -QAYDVQQDDDlBdXRvcmlkYWQgZGUgQ2VydGlmaWNhY2lvbiBGaXJtYXByb2Zlc2lvbmFsIENJRiBB -NjI2MzQwNjgwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQDKlmuO6vj78aI14H9M2uDD -Utd9thDIAl6zQyrET2qyyhxdKJp4ERppWVevtSBC5IsP5t9bpgOSL/UR5GLXMnE42QQMcas9UX4P -B99jBVzpv5RvwSmCwLTaUbDBPLutN0pcyvFLNg4kq7/DhHf9qFD0sefGL9ItWY16Ck6WaVICqjaY -7Pz6FIMMNx/Jkjd/14Et5cS54D40/mf0PmbR0/RAz15iNA9wBj4gGFrO93IbJWyTdBSTo3OxDqqH -ECNZXyAFGUftaI6SEspd/NYrspI8IM/hX68gvqB2f3bl7BqGYTM+53u0P6APjqK5am+5hyZvQWyI -plD9amML9ZMWGxmPsu2bm8mQ9QEM3xk9Dz44I8kvjwzRAv4bVdZO0I08r0+k8/6vKtMFnXkIoctX -MbScyJCyZ/QYFpM6/EfY0XiWMR+6KwxfXZmtY4laJCB22N/9q06mIqqdXuYnin1oKaPnirjaEbsX -LZmdEyRG98Xi2J+Of8ePdG1asuhy9azuJBCtLxTa/y2aRnFHvkLfuwHb9H/TKI8xWVvTyQKmtFLK -bpf7Q8UIJm+K9Lv9nyiqDdVF8xM6HdjAeI9BZzwelGSuewvF6NkBiDkal4ZkQdU7hwxu+g/GvUgU -vzlN1J5Bto+WHWOWk9mVBngxaJ43BjuAiUVhOSPHG0SjFeUc+JIwuwIDAQABo4HvMIHsMBIGA1Ud -EwEB/wQIMAYBAf8CAQEwDgYDVR0PAQH/BAQDAgEGMB0GA1UdDgQWBBRlzeurNR4APn7VdMActHNH -DhpkLzCBpgYDVR0gBIGeMIGbMIGYBgRVHSAAMIGPMC8GCCsGAQUFBwIBFiNodHRwOi8vd3d3LmZp -cm1hcHJvZmVzaW9uYWwuY29tL2NwczBcBggrBgEFBQcCAjBQHk4AUABhAHMAZQBvACAAZABlACAA -bABhACAAQgBvAG4AYQBuAG8AdgBhACAANAA3ACAAQgBhAHIAYwBlAGwAbwBuAGEAIAAwADgAMAAx -ADcwDQYJKoZIhvcNAQEFBQADggIBABd9oPm03cXF661LJLWhAqvdpYhKsg9VSytXjDvlMd3+xDLx -51tkljYyGOylMnfX40S2wBEqgLk9am58m9Ot/MPWo+ZkKXzR4Tgegiv/J2Wv+xYVxC5xhOW1//qk -R71kMrv2JYSiJ0L1ILDCExARzRAVukKQKtJE4ZYm6zFIEv0q2skGz3QeqUvVhyj5eTSSPi5E6PaP -T481PyWzOdxjKpBrIF/EUhJOlywqrJ2X3kjyo2bbwtKDlaZmp54lD+kLM5FlClrD2VQS3a/DTg4f -Jl4N3LON7NWBcN7STyQF82xO9UxJZo3R/9ILJUFI/lGExkKvgATP0H5kSeTy36LssUzAKh3ntLFl -osS88Zj0qnAHY7S42jtM+kAiMFsRpvAFDsYCA0irhpuF3dvd6qJ2gHN99ZwExEWN57kci57q13XR -crHedUTnQn3iV2t93Jm8PYMo6oCTjcVMZcFwgbg4/EMxsvYDNEeyrPsiBsse3RdHHF9mudMaotoR -saS8I8nkvof/uZS2+F0gStRf571oe2XyFR7SOqkt6dhrJKyXWERHrVkY8SFlcN7ONGCoQPHzPKTD -KCOM/iczQ0CgFzzr6juwcqajuUpLXhZI9LK8yIySxZ2frHI2vDSANGupi5LAuBft7HZT9SQBjLMi -6Et8Vcad+qMUu2WFbm5PEn4KPJ2V ------END CERTIFICATE----- - Izenpe.com ========== -----BEGIN CERTIFICATE----- @@ -3449,3 +3395,140 @@ TFsR0PXNor6uzFFcw9VUewyu1rkGd4Di7wcaaMxZUa1+XGdrudviB0JbuAEFWDlN5LuYo7Ey7Nmj PqYO5Wue/9vsL3SD3460s6neFE3/MaNFcyT6lSnMEpcEoji2jbDwN/zIIX8/syQbPYtuzE2wFg2W HYMfRsCbvUOZ58SWLs5fyQ== -----END CERTIFICATE----- + +TrustAsia Global Root CA G3 +=========================== +-----BEGIN CERTIFICATE----- +MIIFpTCCA42gAwIBAgIUZPYOZXdhaqs7tOqFhLuxibhxkw8wDQYJKoZIhvcNAQEMBQAwWjELMAkG +A1UEBhMCQ04xJTAjBgNVBAoMHFRydXN0QXNpYSBUZWNobm9sb2dpZXMsIEluYy4xJDAiBgNVBAMM +G1RydXN0QXNpYSBHbG9iYWwgUm9vdCBDQSBHMzAeFw0yMTA1MjAwMjEwMTlaFw00NjA1MTkwMjEw +MTlaMFoxCzAJBgNVBAYTAkNOMSUwIwYDVQQKDBxUcnVzdEFzaWEgVGVjaG5vbG9naWVzLCBJbmMu +MSQwIgYDVQQDDBtUcnVzdEFzaWEgR2xvYmFsIFJvb3QgQ0EgRzMwggIiMA0GCSqGSIb3DQEBAQUA +A4ICDwAwggIKAoICAQDAMYJhkuSUGwoqZdC+BqmHO1ES6nBBruL7dOoKjbmzTNyPtxNST1QY4Sxz +lZHFZjtqz6xjbYdT8PfxObegQ2OwxANdV6nnRM7EoYNl9lA+sX4WuDqKAtCWHwDNBSHvBm3dIZwZ +Q0WhxeiAysKtQGIXBsaqvPPW5vxQfmZCHzyLpnl5hkA1nyDvP+uLRx+PjsXUjrYsyUQE49RDdT/V +P68czH5GX6zfZBCK70bwkPAPLfSIC7Epqq+FqklYqL9joDiR5rPmd2jE+SoZhLsO4fWvieylL1Ag +dB4SQXMeJNnKziyhWTXAyB1GJ2Faj/lN03J5Zh6fFZAhLf3ti1ZwA0pJPn9pMRJpxx5cynoTi+jm +9WAPzJMshH/x/Gr8m0ed262IPfN2dTPXS6TIi/n1Q1hPy8gDVI+lhXgEGvNz8teHHUGf59gXzhqc +D0r83ERoVGjiQTz+LISGNzzNPy+i2+f3VANfWdP3kXjHi3dqFuVJhZBFcnAvkV34PmVACxmZySYg +WmjBNb9Pp1Hx2BErW+Canig7CjoKH8GB5S7wprlppYiU5msTf9FkPz2ccEblooV7WIQn3MSAPmea +mseaMQ4w7OYXQJXZRe0Blqq/DPNL0WP3E1jAuPP6Z92bfW1K/zJMtSU7/xxnD4UiWQWRkUF3gdCF +TIcQcf+eQxuulXUtgQIDAQABo2MwYTAPBgNVHRMBAf8EBTADAQH/MB8GA1UdIwQYMBaAFEDk5PIj +7zjKsK5Xf/IhMBY027ySMB0GA1UdDgQWBBRA5OTyI+84yrCuV3/yITAWNNu8kjAOBgNVHQ8BAf8E +BAMCAQYwDQYJKoZIhvcNAQEMBQADggIBACY7UeFNOPMyGLS0XuFlXsSUT9SnYaP4wM8zAQLpw6o1 +D/GUE3d3NZ4tVlFEbuHGLige/9rsR82XRBf34EzC4Xx8MnpmyFq2XFNFV1pF1AWZLy4jVe5jaN/T +G3inEpQGAHUNcoTpLrxaatXeL1nHo+zSh2bbt1S1JKv0Q3jbSwTEb93mPmY+KfJLaHEih6D4sTNj +duMNhXJEIlU/HHzp/LgV6FL6qj6jITk1dImmasI5+njPtqzn59ZW/yOSLlALqbUHM/Q4X6RJpstl +cHboCoWASzY9M/eVVHUl2qzEc4Jl6VL1XP04lQJqaTDFHApXB64ipCz5xUG3uOyfT0gA+QEEVcys ++TIxxHWVBqB/0Y0n3bOppHKH/lmLmnp0Ft0WpWIp6zqW3IunaFnT63eROfjXy9mPX1onAX1daBli +2MjN9LdyR75bl87yraKZk62Uy5P2EgmVtqvXO9A/EcswFi55gORngS1d7XB4tmBZrOFdRWOPyN9y +aFvqHbgB8X7754qz41SgOAngPN5C8sLtLpvzHzW2NtjjgKGLzZlkD8Kqq7HK9W+eQ42EVJmzbsAS +ZthwEPEGNTNDqJwuuhQxzhB/HIbjj9LV+Hfsm6vxL2PZQl/gZ4FkkfGXL/xuJvYz+NO1+MRiqzFR +JQJ6+N1rZdVtTTDIZbpoFGWsJwt0ivKH +-----END CERTIFICATE----- + +TrustAsia Global Root CA G4 +=========================== +-----BEGIN CERTIFICATE----- +MIICVTCCAdygAwIBAgIUTyNkuI6XY57GU4HBdk7LKnQV1tcwCgYIKoZIzj0EAwMwWjELMAkGA1UE +BhMCQ04xJTAjBgNVBAoMHFRydXN0QXNpYSBUZWNobm9sb2dpZXMsIEluYy4xJDAiBgNVBAMMG1Ry +dXN0QXNpYSBHbG9iYWwgUm9vdCBDQSBHNDAeFw0yMTA1MjAwMjEwMjJaFw00NjA1MTkwMjEwMjJa +MFoxCzAJBgNVBAYTAkNOMSUwIwYDVQQKDBxUcnVzdEFzaWEgVGVjaG5vbG9naWVzLCBJbmMuMSQw +IgYDVQQDDBtUcnVzdEFzaWEgR2xvYmFsIFJvb3QgQ0EgRzQwdjAQBgcqhkjOPQIBBgUrgQQAIgNi +AATxs8045CVD5d4ZCbuBeaIVXxVjAd7Cq92zphtnS4CDr5nLrBfbK5bKfFJV4hrhPVbwLxYI+hW8 +m7tH5j/uqOFMjPXTNvk4XatwmkcN4oFBButJ+bAp3TPsUKV/eSm4IJijYzBhMA8GA1UdEwEB/wQF +MAMBAf8wHwYDVR0jBBgwFoAUpbtKl86zK3+kMd6Xg1mDpm9xy94wHQYDVR0OBBYEFKW7SpfOsyt/ +pDHel4NZg6ZvccveMA4GA1UdDwEB/wQEAwIBBjAKBggqhkjOPQQDAwNnADBkAjBe8usGzEkxn0AA +bbd+NvBNEU/zy4k6LHiRUKNbwMp1JvK/kF0LgoxgKJ/GcJpo5PECMFxYDlZ2z1jD1xCMuo6u47xk +dUfFVZDj/bpV6wfEU6s3qe4hsiFbYI89MvHVI5TWWA== +-----END CERTIFICATE----- + +CommScope Public Trust ECC Root-01 +================================== +-----BEGIN CERTIFICATE----- +MIICHTCCAaOgAwIBAgIUQ3CCd89NXTTxyq4yLzf39H91oJ4wCgYIKoZIzj0EAwMwTjELMAkGA1UE +BhMCVVMxEjAQBgNVBAoMCUNvbW1TY29wZTErMCkGA1UEAwwiQ29tbVNjb3BlIFB1YmxpYyBUcnVz +dCBFQ0MgUm9vdC0wMTAeFw0yMTA0MjgxNzM1NDNaFw00NjA0MjgxNzM1NDJaME4xCzAJBgNVBAYT +AlVTMRIwEAYDVQQKDAlDb21tU2NvcGUxKzApBgNVBAMMIkNvbW1TY29wZSBQdWJsaWMgVHJ1c3Qg +RUNDIFJvb3QtMDEwdjAQBgcqhkjOPQIBBgUrgQQAIgNiAARLNumuV16ocNfQj3Rid8NeeqrltqLx +eP0CflfdkXmcbLlSiFS8LwS+uM32ENEp7LXQoMPwiXAZu1FlxUOcw5tjnSCDPgYLpkJEhRGnSjot +6dZoL0hOUysHP029uax3OVejQjBAMA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgEGMB0G +A1UdDgQWBBSOB2LAUN3GGQYARnQE9/OufXVNMDAKBggqhkjOPQQDAwNoADBlAjEAnDPfQeMjqEI2 +Jpc1XHvr20v4qotzVRVcrHgpD7oh2MSg2NED3W3ROT3Ek2DS43KyAjB8xX6I01D1HiXo+k515liW +pDVfG2XqYZpwI7UNo5uSUm9poIyNStDuiw7LR47QjRE= +-----END CERTIFICATE----- + +CommScope Public Trust ECC Root-02 +================================== +-----BEGIN CERTIFICATE----- +MIICHDCCAaOgAwIBAgIUKP2ZYEFHpgE6yhR7H+/5aAiDXX0wCgYIKoZIzj0EAwMwTjELMAkGA1UE +BhMCVVMxEjAQBgNVBAoMCUNvbW1TY29wZTErMCkGA1UEAwwiQ29tbVNjb3BlIFB1YmxpYyBUcnVz +dCBFQ0MgUm9vdC0wMjAeFw0yMTA0MjgxNzQ0NTRaFw00NjA0MjgxNzQ0NTNaME4xCzAJBgNVBAYT +AlVTMRIwEAYDVQQKDAlDb21tU2NvcGUxKzApBgNVBAMMIkNvbW1TY29wZSBQdWJsaWMgVHJ1c3Qg +RUNDIFJvb3QtMDIwdjAQBgcqhkjOPQIBBgUrgQQAIgNiAAR4MIHoYx7l63FRD/cHB8o5mXxO1Q/M +MDALj2aTPs+9xYa9+bG3tD60B8jzljHz7aRP+KNOjSkVWLjVb3/ubCK1sK9IRQq9qEmUv4RDsNuE +SgMjGWdqb8FuvAY5N9GIIvejQjBAMA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgEGMB0G +A1UdDgQWBBTmGHX/72DehKT1RsfeSlXjMjZ59TAKBggqhkjOPQQDAwNnADBkAjAmc0l6tqvmSfR9 +Uj/UQQSugEODZXW5hYA4O9Zv5JOGq4/nich/m35rChJVYaoR4HkCMHfoMXGsPHED1oQmHhS48zs7 +3u1Z/GtMMH9ZzkXpc2AVmkzw5l4lIhVtwodZ0LKOag== +-----END CERTIFICATE----- + +CommScope Public Trust RSA Root-01 +================================== +-----BEGIN CERTIFICATE----- +MIIFbDCCA1SgAwIBAgIUPgNJgXUWdDGOTKvVxZAplsU5EN0wDQYJKoZIhvcNAQELBQAwTjELMAkG +A1UEBhMCVVMxEjAQBgNVBAoMCUNvbW1TY29wZTErMCkGA1UEAwwiQ29tbVNjb3BlIFB1YmxpYyBU +cnVzdCBSU0EgUm9vdC0wMTAeFw0yMTA0MjgxNjQ1NTRaFw00NjA0MjgxNjQ1NTNaME4xCzAJBgNV +BAYTAlVTMRIwEAYDVQQKDAlDb21tU2NvcGUxKzApBgNVBAMMIkNvbW1TY29wZSBQdWJsaWMgVHJ1 +c3QgUlNBIFJvb3QtMDEwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCwSGWjDR1C45Ft +nYSkYZYSwu3D2iM0GXb26v1VWvZVAVMP8syMl0+5UMuzAURWlv2bKOx7dAvnQmtVzslhsuitQDy6 +uUEKBU8bJoWPQ7VAtYXR1HHcg0Hz9kXHgKKEUJdGzqAMxGBWBB0HW0alDrJLpA6lfO741GIDuZNq +ihS4cPgugkY4Iw50x2tBt9Apo52AsH53k2NC+zSDO3OjWiE260f6GBfZumbCk6SP/F2krfxQapWs +vCQz0b2If4b19bJzKo98rwjyGpg/qYFlP8GMicWWMJoKz/TUyDTtnS+8jTiGU+6Xn6myY5QXjQ/c +Zip8UlF1y5mO6D1cv547KI2DAg+pn3LiLCuz3GaXAEDQpFSOm117RTYm1nJD68/A6g3czhLmfTif +BSeolz7pUcZsBSjBAg/pGG3svZwG1KdJ9FQFa2ww8esD1eo9anbCyxooSU1/ZOD6K9pzg4H/kQO9 +lLvkuI6cMmPNn7togbGEW682v3fuHX/3SZtS7NJ3Wn2RnU3COS3kuoL4b/JOHg9O5j9ZpSPcPYeo +KFgo0fEbNttPxP/hjFtyjMcmAyejOQoBqsCyMWCDIqFPEgkBEa801M/XrmLTBQe0MXXgDW1XT2mH ++VepuhX2yFJtocucH+X8eKg1mp9BFM6ltM6UCBwJrVbl2rZJmkrqYxhTnCwuwwIDAQABo0IwQDAP +BgNVHRMBAf8EBTADAQH/MA4GA1UdDwEB/wQEAwIBBjAdBgNVHQ4EFgQUN12mmnQywsL5x6YVEFm4 +5P3luG0wDQYJKoZIhvcNAQELBQADggIBAK+nz97/4L1CjU3lIpbfaOp9TSp90K09FlxD533Ahuh6 +NWPxzIHIxgvoLlI1pKZJkGNRrDSsBTtXAOnTYtPZKdVUvhwQkZyybf5Z/Xn36lbQnmhUQo8mUuJM +3y+Xpi/SB5io82BdS5pYV4jvguX6r2yBS5KPQJqTRlnLX3gWsWc+QgvfKNmwrZggvkN80V4aCRck +jXtdlemrwWCrWxhkgPut4AZ9HcpZuPN4KWfGVh2vtrV0KnahP/t1MJ+UXjulYPPLXAziDslg+Mkf +Foom3ecnf+slpoq9uC02EJqxWE2aaE9gVOX2RhOOiKy8IUISrcZKiX2bwdgt6ZYD9KJ0DLwAHb/W +NyVntHKLr4W96ioDj8z7PEQkguIBpQtZtjSNMgsSDesnwv1B10A8ckYpwIzqug/xBpMu95yo9GA+ +o/E4Xo4TwbM6l4c/ksp4qRyv0LAbJh6+cOx69TOY6lz/KwsETkPdY34Op054A5U+1C0wlREQKC6/ +oAI+/15Z0wUOlV9TRe9rh9VIzRamloPh37MG88EU26fsHItdkJANclHnYfkUyq+Dj7+vsQpZXdxc +1+SWrVtgHdqul7I52Qb1dgAT+GhMIbA1xNxVssnBQVocicCMb3SgazNNtQEo/a2tiRc7ppqEvOuM +6sRxJKi6KfkIsidWNTJf6jn7MZrVGczw +-----END CERTIFICATE----- + +CommScope Public Trust RSA Root-02 +================================== +-----BEGIN CERTIFICATE----- +MIIFbDCCA1SgAwIBAgIUVBa/O345lXGN0aoApYYNK496BU4wDQYJKoZIhvcNAQELBQAwTjELMAkG +A1UEBhMCVVMxEjAQBgNVBAoMCUNvbW1TY29wZTErMCkGA1UEAwwiQ29tbVNjb3BlIFB1YmxpYyBU +cnVzdCBSU0EgUm9vdC0wMjAeFw0yMTA0MjgxNzE2NDNaFw00NjA0MjgxNzE2NDJaME4xCzAJBgNV +BAYTAlVTMRIwEAYDVQQKDAlDb21tU2NvcGUxKzApBgNVBAMMIkNvbW1TY29wZSBQdWJsaWMgVHJ1 +c3QgUlNBIFJvb3QtMDIwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQDh+g77aAASyE3V +rCLENQE7xVTlWXZjpX/rwcRqmL0yjReA61260WI9JSMZNRTpf4mnG2I81lDnNJUDMrG0kyI9p+Kx +7eZ7Ti6Hmw0zdQreqjXnfuU2mKKuJZ6VszKWpCtYHu8//mI0SFHRtI1CrWDaSWqVcN3SAOLMV2MC +e5bdSZdbkk6V0/nLKR8YSvgBKtJjCW4k6YnS5cciTNxzhkcAqg2Ijq6FfUrpuzNPDlJwnZXjfG2W +Wy09X6GDRl224yW4fKcZgBzqZUPckXk2LHR88mcGyYnJ27/aaL8j7dxrrSiDeS/sOKUNNwFnJ5rp +M9kzXzehxfCrPfp4sOcsn/Y+n2Dg70jpkEUeBVF4GiwSLFworA2iI540jwXmojPOEXcT1A6kHkIf +hs1w/tkuFT0du7jyU1fbzMZ0KZwYszZ1OC4PVKH4kh+Jlk+71O6d6Ts2QrUKOyrUZHk2EOH5kQMr +eyBUzQ0ZGshBMjTRsJnhkB4BQDa1t/qp5Xd1pCKBXbCL5CcSD1SIxtuFdOa3wNemKfrb3vOTlycE +VS8KbzfFPROvCgCpLIscgSjX74Yxqa7ybrjKaixUR9gqiC6vwQcQeKwRoi9C8DfF8rhW3Q5iLc4t +Vn5V8qdE9isy9COoR+jUKgF4z2rDN6ieZdIs5fq6M8EGRPbmz6UNp2YINIos8wIDAQABo0IwQDAP +BgNVHRMBAf8EBTADAQH/MA4GA1UdDwEB/wQEAwIBBjAdBgNVHQ4EFgQUR9DnsSL/nSz12Vdgs7Gx +cJXvYXowDQYJKoZIhvcNAQELBQADggIBAIZpsU0v6Z9PIpNojuQhmaPORVMbc0RTAIFhzTHjCLqB +KCh6krm2qMhDnscTJk3C2OVVnJJdUNjCK9v+5qiXz1I6JMNlZFxHMaNlNRPDk7n3+VGXu6TwYofF +1gbTl4MgqX67tiHCpQ2EAOHyJxCDut0DgdXdaMNmEMjRdrSzbymeAPnCKfWxkxlSaRosTKCL4BWa +MS/TiJVZbuXEs1DIFAhKm4sTg7GkcrI7djNB3NyqpgdvHSQSn8h2vS/ZjvQs7rfSOBAkNlEv41xd +gSGn2rtO/+YHqP65DSdsu3BaVXoT6fEqSWnHX4dXTEN5bTpl6TBcQe7rd6VzEojov32u5cSoHw2O +HG1QAk8mGEPej1WFsQs3BWDJVTkSBKEqz3EWnzZRSb9wO55nnPt7eck5HHisd5FUmrh1CoFSl+Nm +YWvtPjgelmFV4ZFUjO2MJB+ByRCac5krFk5yAD9UG/iNuovnFNa2RU9g7Jauwy8CTl2dlklyALKr +dVwPaFsdZcJfMw8eD/A7hvWwTruc9+olBdytoptLFwG+Qt81IR2tq670v64fG9PiO/yzcnMcmyiQ +iRM9HcEARwmWmjgb3bHPDcK0RPOWlc4yOo80nOAXx17Org3bhzjlP1v9mxnhMUF6cKojawHhRUzN +lM47ni3niAIi9G7oyOzWPPO5std3eqx7 +-----END CERTIFICATE----- diff --git a/vendor/composer/installed.json b/vendor/composer/installed.json index b60d5d7a..9ab1644c 100644 --- a/vendor/composer/installed.json +++ b/vendor/composer/installed.json @@ -2,17 +2,17 @@ "packages": [ { "name": "composer/ca-bundle", - "version": "1.3.7", - "version_normalized": "1.3.7.0", + "version": "1.4.0", + "version_normalized": "1.4.0.0", "source": { "type": "git", "url": "https://github.com/composer/ca-bundle.git", - "reference": "76e46335014860eec1aa5a724799a00a2e47cc85" + "reference": "b66d11b7479109ab547f9405b97205640b17d385" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/ca-bundle/zipball/76e46335014860eec1aa5a724799a00a2e47cc85", - "reference": "76e46335014860eec1aa5a724799a00a2e47cc85", + "url": "https://api.github.com/repos/composer/ca-bundle/zipball/b66d11b7479109ab547f9405b97205640b17d385", + "reference": "b66d11b7479109ab547f9405b97205640b17d385", "shasum": "" }, "require": { @@ -24,9 +24,9 @@ "phpstan/phpstan": "^0.12.55", "psr/log": "^1.0", "symfony/phpunit-bridge": "^4.2 || ^5", - "symfony/process": "^2.5 || ^3.0 || ^4.0 || ^5.0 || ^6.0" + "symfony/process": "^2.5 || ^3.0 || ^4.0 || ^5.0 || ^6.0 || ^7.0" }, - "time": "2023-08-30T09:31:38+00:00", + "time": "2023-12-18T12:05:55+00:00", "type": "library", "extra": { "branch-alias": { @@ -61,7 +61,7 @@ "support": { "irc": "irc://irc.freenode.org/composer", "issues": "https://github.com/composer/ca-bundle/issues", - "source": "https://github.com/composer/ca-bundle/tree/1.3.7" + "source": "https://github.com/composer/ca-bundle/tree/1.4.0" }, "funding": [ { @@ -162,17 +162,17 @@ }, { "name": "embed/embed", - "version": "v4.4.8", - "version_normalized": "4.4.8.0", + "version": "v4.4.10", + "version_normalized": "4.4.10.0", "source": { "type": "git", "url": "https://github.com/oscarotero/Embed.git", - "reference": "49134080764018bc6b8a2488dd1c8cc2c47d15fc" + "reference": "8ac21505d048e8796c6cb9172ec5e81e5d0e0408" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/oscarotero/Embed/zipball/49134080764018bc6b8a2488dd1c8cc2c47d15fc", - "reference": "49134080764018bc6b8a2488dd1c8cc2c47d15fc", + "url": "https://api.github.com/repos/oscarotero/Embed/zipball/8ac21505d048e8796c6cb9172ec5e81e5d0e0408", + "reference": "8ac21505d048e8796c6cb9172ec5e81e5d0e0408", "shasum": "" }, "require": { @@ -199,7 +199,7 @@ "suggest": { "symfony/css-selector": "If you want to get elements using css selectors" }, - "time": "2023-05-22T18:48:30+00:00", + "time": "2023-12-10T12:30:47+00:00", "type": "library", "installation-source": "dist", "autoload": { @@ -234,7 +234,7 @@ "support": { "email": "oom@oscarotero.com", "issues": "https://github.com/oscarotero/Embed/issues", - "source": "https://github.com/oscarotero/Embed/tree/v4.4.8" + "source": "https://github.com/oscarotero/Embed/tree/v4.4.10" }, "funding": [ { @@ -520,17 +520,17 @@ }, { "name": "gettext/translator", - "version": "v1.1.1", - "version_normalized": "1.1.1.0", + "version": "v1.2.0", + "version_normalized": "1.2.0.0", "source": { "type": "git", "url": "https://github.com/php-gettext/Translator.git", - "reference": "b18ff33e8203de623854561f5e47e992fc5c50bb" + "reference": "a4fa5ed740f304a0ed7b3e169b2b554a195c7570" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-gettext/Translator/zipball/b18ff33e8203de623854561f5e47e992fc5c50bb", - "reference": "b18ff33e8203de623854561f5e47e992fc5c50bb", + "url": "https://api.github.com/repos/php-gettext/Translator/zipball/a4fa5ed740f304a0ed7b3e169b2b554a195c7570", + "reference": "a4fa5ed740f304a0ed7b3e169b2b554a195c7570", "shasum": "" }, "require": { @@ -546,7 +546,7 @@ "suggest": { "gettext/gettext": "Is necessary to load and generate array files used by the translator" }, - "time": "2022-02-23T20:29:40+00:00", + "time": "2023-11-06T15:42:03+00:00", "type": "library", "installation-source": "dist", "autoload": { @@ -577,7 +577,7 @@ "support": { "email": "oom@oscarotero.com", "issues": "https://github.com/php-gettext/Translator/issues", - "source": "https://github.com/php-gettext/Translator/tree/v1.1.1" + "source": "https://github.com/php-gettext/Translator/tree/v1.2.0" }, "funding": [ { @@ -947,17 +947,17 @@ }, { "name": "nikic/php-parser", - "version": "v4.17.1", - "version_normalized": "4.17.1.0", + "version": "v4.18.0", + "version_normalized": "4.18.0.0", "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d" + "reference": "1bcbb2179f97633e98bbbc87044ee2611c7d7999" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d", - "reference": "a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/1bcbb2179f97633e98bbbc87044ee2611c7d7999", + "reference": "1bcbb2179f97633e98bbbc87044ee2611c7d7999", "shasum": "" }, "require": { @@ -968,7 +968,7 @@ "ircmaxell/php-yacc": "^0.0.7", "phpunit/phpunit": "^6.5 || ^7.0 || ^8.0 || ^9.0" }, - "time": "2023-08-13T19:53:39+00:00", + "time": "2023-12-10T21:03:43+00:00", "bin": [ "bin/php-parse" ], @@ -1000,23 +1000,23 @@ ], "support": { "issues": "https://github.com/nikic/PHP-Parser/issues", - "source": "https://github.com/nikic/PHP-Parser/tree/v4.17.1" + "source": "https://github.com/nikic/PHP-Parser/tree/v4.18.0" }, "install-path": "../nikic/php-parser" }, { "name": "oscarotero/html-parser", - "version": "v0.1.7", - "version_normalized": "0.1.7.0", + "version": "v0.1.8", + "version_normalized": "0.1.8.0", "source": { "type": "git", "url": "https://github.com/oscarotero/html-parser.git", - "reference": "0c5b619bdc7ac061f06a667d913e2af708ee3231" + "reference": "10f3219267a365d9433f2f7d1694209c9d436c8d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/oscarotero/html-parser/zipball/0c5b619bdc7ac061f06a667d913e2af708ee3231", - "reference": "0c5b619bdc7ac061f06a667d913e2af708ee3231", + "url": "https://api.github.com/repos/oscarotero/html-parser/zipball/10f3219267a365d9433f2f7d1694209c9d436c8d", + "reference": "10f3219267a365d9433f2f7d1694209c9d436c8d", "shasum": "" }, "require": { @@ -1026,7 +1026,7 @@ "friendsofphp/php-cs-fixer": "^2.11", "phpunit/phpunit": "^8.0" }, - "time": "2022-12-17T09:48:58+00:00", + "time": "2023-11-29T20:28:41+00:00", "type": "library", "installation-source": "dist", "autoload": { @@ -1056,7 +1056,7 @@ "support": { "email": "oom@oscarotero.com", "issues": "https://github.com/oscarotero/html-parser/issues", - "source": "https://github.com/oscarotero/html-parser/tree/v0.1.7" + "source": "https://github.com/oscarotero/html-parser/tree/v0.1.8" }, "install-path": "../oscarotero/html-parser" }, @@ -1179,32 +1179,32 @@ }, { "name": "phpcsstandards/phpcsextra", - "version": "1.1.1", - "version_normalized": "1.1.1.0", + "version": "1.2.1", + "version_normalized": "1.2.1.0", "source": { "type": "git", "url": "https://github.com/PHPCSStandards/PHPCSExtra.git", - "reference": "98bcdbacbda14b1db85f710b1853125726795bbc" + "reference": "11d387c6642b6e4acaf0bd9bf5203b8cca1ec489" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/PHPCSStandards/PHPCSExtra/zipball/98bcdbacbda14b1db85f710b1853125726795bbc", - "reference": "98bcdbacbda14b1db85f710b1853125726795bbc", + "url": "https://api.github.com/repos/PHPCSStandards/PHPCSExtra/zipball/11d387c6642b6e4acaf0bd9bf5203b8cca1ec489", + "reference": "11d387c6642b6e4acaf0bd9bf5203b8cca1ec489", "shasum": "" }, "require": { "php": ">=5.4", - "phpcsstandards/phpcsutils": "^1.0.8", - "squizlabs/php_codesniffer": "^3.7.1" + "phpcsstandards/phpcsutils": "^1.0.9", + "squizlabs/php_codesniffer": "^3.8.0" }, "require-dev": { "php-parallel-lint/php-console-highlighter": "^1.0", "php-parallel-lint/php-parallel-lint": "^1.3.2", "phpcsstandards/phpcsdevcs": "^1.1.6", "phpcsstandards/phpcsdevtools": "^1.2.1", - "phpunit/phpunit": "^4.5 || ^5.0 || ^6.0 || ^7.0" + "phpunit/phpunit": "^4.5 || ^5.0 || ^6.0 || ^7.0 || ^8.0 || ^9.0" }, - "time": "2023-08-26T04:46:45+00:00", + "time": "2023-12-08T16:49:07+00:00", "type": "phpcodesniffer-standard", "extra": { "branch-alias": { @@ -1239,38 +1239,53 @@ ], "support": { "issues": "https://github.com/PHPCSStandards/PHPCSExtra/issues", + "security": "https://github.com/PHPCSStandards/PHPCSExtra/security/policy", "source": "https://github.com/PHPCSStandards/PHPCSExtra" }, + "funding": [ + { + "url": "https://github.com/PHPCSStandards", + "type": "github" + }, + { + "url": "https://github.com/jrfnl", + "type": "github" + }, + { + "url": "https://opencollective.com/php_codesniffer", + "type": "open_collective" + } + ], "install-path": "../phpcsstandards/phpcsextra" }, { "name": "phpcsstandards/phpcsutils", - "version": "1.0.8", - "version_normalized": "1.0.8.0", + "version": "1.0.9", + "version_normalized": "1.0.9.0", "source": { "type": "git", "url": "https://github.com/PHPCSStandards/PHPCSUtils.git", - "reference": "69465cab9d12454e5e7767b9041af0cd8cd13be7" + "reference": "908247bc65010c7b7541a9551e002db12e9dae70" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/PHPCSStandards/PHPCSUtils/zipball/69465cab9d12454e5e7767b9041af0cd8cd13be7", - "reference": "69465cab9d12454e5e7767b9041af0cd8cd13be7", + "url": "https://api.github.com/repos/PHPCSStandards/PHPCSUtils/zipball/908247bc65010c7b7541a9551e002db12e9dae70", + "reference": "908247bc65010c7b7541a9551e002db12e9dae70", "shasum": "" }, "require": { "dealerdirect/phpcodesniffer-composer-installer": "^0.4.1 || ^0.5 || ^0.6.2 || ^0.7 || ^1.0", "php": ">=5.4", - "squizlabs/php_codesniffer": "^3.7.1 || 4.0.x-dev@dev" + "squizlabs/php_codesniffer": "^3.8.0 || 4.0.x-dev@dev" }, "require-dev": { "ext-filter": "*", "php-parallel-lint/php-console-highlighter": "^1.0", "php-parallel-lint/php-parallel-lint": "^1.3.2", "phpcsstandards/phpcsdevcs": "^1.1.6", - "yoast/phpunit-polyfills": "^1.0.5 || ^2.0.0" + "yoast/phpunit-polyfills": "^1.1.0 || ^2.0.0" }, - "time": "2023-07-16T21:39:41+00:00", + "time": "2023-12-08T14:50:00+00:00", "type": "phpcodesniffer-standard", "extra": { "branch-alias": { @@ -1315,23 +1330,38 @@ "support": { "docs": "https://phpcsutils.com/", "issues": "https://github.com/PHPCSStandards/PHPCSUtils/issues", + "security": "https://github.com/PHPCSStandards/PHPCSUtils/security/policy", "source": "https://github.com/PHPCSStandards/PHPCSUtils" }, + "funding": [ + { + "url": "https://github.com/PHPCSStandards", + "type": "github" + }, + { + "url": "https://github.com/jrfnl", + "type": "github" + }, + { + "url": "https://opencollective.com/php_codesniffer", + "type": "open_collective" + } + ], "install-path": "../phpcsstandards/phpcsutils" }, { "name": "phpunit/php-code-coverage", - "version": "10.1.6", - "version_normalized": "10.1.6.0", + "version": "10.1.10", + "version_normalized": "10.1.10.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "56f33548fe522c8d82da7ff3824b42829d324364" + "reference": "599109c8ca6bae97b23482d557d2874c25a65e59" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/56f33548fe522c8d82da7ff3824b42829d324364", - "reference": "56f33548fe522c8d82da7ff3824b42829d324364", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/599109c8ca6bae97b23482d557d2874c25a65e59", + "reference": "599109c8ca6bae97b23482d557d2874c25a65e59", "shasum": "" }, "require": { @@ -1356,7 +1386,7 @@ "ext-pcov": "PHP extension that provides line coverage", "ext-xdebug": "PHP extension that provides line coverage as well as branch and path coverage" }, - "time": "2023-09-19T04:59:03+00:00", + "time": "2023-12-11T06:28:43+00:00", "type": "library", "extra": { "branch-alias": { @@ -1390,7 +1420,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", "security": "https://github.com/sebastianbergmann/php-code-coverage/security/policy", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/10.1.6" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/10.1.10" }, "funding": [ { @@ -1657,17 +1687,17 @@ }, { "name": "phpunit/phpunit", - "version": "10.0.0", - "version_normalized": "10.0.0.0", + "version": "10.5.3", + "version_normalized": "10.5.3.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "c4c60c34c0e92045afce938510f8878d7cd84f8a" + "reference": "6fce887c71076a73f32fd3e0774a6833fc5c7f19" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/c4c60c34c0e92045afce938510f8878d7cd84f8a", - "reference": "c4c60c34c0e92045afce938510f8878d7cd84f8a", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/6fce887c71076a73f32fd3e0774a6833fc5c7f19", + "reference": "6fce887c71076a73f32fd3e0774a6833fc5c7f19", "shasum": "" }, "require": { @@ -1681,7 +1711,7 @@ "phar-io/manifest": "^2.0.3", "phar-io/version": "^3.0.2", "php": ">=8.1", - "phpunit/php-code-coverage": "^10.0", + "phpunit/php-code-coverage": "^10.1.5", "phpunit/php-file-iterator": "^4.0", "phpunit/php-invoker": "^4.0", "phpunit/php-text-template": "^3.0", @@ -1691,24 +1721,24 @@ "sebastian/comparator": "^5.0", "sebastian/diff": "^5.0", "sebastian/environment": "^6.0", - "sebastian/exporter": "^5.0", - "sebastian/global-state": "^6.0", + "sebastian/exporter": "^5.1", + "sebastian/global-state": "^6.0.1", "sebastian/object-enumerator": "^5.0", "sebastian/recursion-context": "^5.0", "sebastian/type": "^4.0", "sebastian/version": "^4.0" }, "suggest": { - "ext-soap": "*" + "ext-soap": "To be able to generate mocks based on WSDL files" }, - "time": "2023-02-03T07:16:15+00:00", + "time": "2023-12-13T07:25:23+00:00", "bin": [ "phpunit" ], "type": "library", "extra": { "branch-alias": { - "dev-main": "10.0-dev" + "dev-main": "10.5-dev" } }, "installation-source": "dist", @@ -1740,7 +1770,8 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", - "source": "https://github.com/sebastianbergmann/phpunit/tree/10.0.0" + "security": "https://github.com/sebastianbergmann/phpunit/security/policy", + "source": "https://github.com/sebastianbergmann/phpunit/tree/10.5.3" }, "funding": [ { @@ -1816,24 +1847,24 @@ }, { "name": "psr/http-client", - "version": "1.0.2", - "version_normalized": "1.0.2.0", + "version": "1.0.3", + "version_normalized": "1.0.3.0", "source": { "type": "git", "url": "https://github.com/php-fig/http-client.git", - "reference": "0955afe48220520692d2d09f7ab7e0f93ffd6a31" + "reference": "bb5906edc1c324c9a05aa0873d40117941e5fa90" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/http-client/zipball/0955afe48220520692d2d09f7ab7e0f93ffd6a31", - "reference": "0955afe48220520692d2d09f7ab7e0f93ffd6a31", + "url": "https://api.github.com/repos/php-fig/http-client/zipball/bb5906edc1c324c9a05aa0873d40117941e5fa90", + "reference": "bb5906edc1c324c9a05aa0873d40117941e5fa90", "shasum": "" }, "require": { "php": "^7.0 || ^8.0", "psr/http-message": "^1.0 || ^2.0" }, - "time": "2023-04-10T20:12:12+00:00", + "time": "2023-09-23T14:17:50+00:00", "type": "library", "extra": { "branch-alias": { @@ -1865,7 +1896,7 @@ "psr-18" ], "support": { - "source": "https://github.com/php-fig/http-client/tree/1.0.2" + "source": "https://github.com/php-fig/http-client" }, "install-path": "../psr/http-client" }, @@ -2336,17 +2367,17 @@ }, { "name": "sebastian/complexity", - "version": "3.0.1", - "version_normalized": "3.0.1.0", + "version": "3.1.0", + "version_normalized": "3.1.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/complexity.git", - "reference": "c70b73893e10757af9c6a48929fa6a333b56a97a" + "reference": "68cfb347a44871f01e33ab0ef8215966432f6957" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/c70b73893e10757af9c6a48929fa6a333b56a97a", - "reference": "c70b73893e10757af9c6a48929fa6a333b56a97a", + "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/68cfb347a44871f01e33ab0ef8215966432f6957", + "reference": "68cfb347a44871f01e33ab0ef8215966432f6957", "shasum": "" }, "require": { @@ -2356,11 +2387,11 @@ "require-dev": { "phpunit/phpunit": "^10.0" }, - "time": "2023-08-31T09:55:53+00:00", + "time": "2023-09-28T11:50:59+00:00", "type": "library", "extra": { "branch-alias": { - "dev-main": "3.0-dev" + "dev-main": "3.1-dev" } }, "installation-source": "dist", @@ -2385,7 +2416,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/complexity/issues", "security": "https://github.com/sebastianbergmann/complexity/security/policy", - "source": "https://github.com/sebastianbergmann/complexity/tree/3.0.1" + "source": "https://github.com/sebastianbergmann/complexity/tree/3.1.0" }, "funding": [ { @@ -2534,17 +2565,17 @@ }, { "name": "sebastian/exporter", - "version": "5.1.0", - "version_normalized": "5.1.0.0", + "version": "5.1.1", + "version_normalized": "5.1.1.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "c3fa8483f9539b190f7cd4bfc4a07631dd1df344" + "reference": "64f51654862e0f5e318db7e9dcc2292c63cdbddc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/c3fa8483f9539b190f7cd4bfc4a07631dd1df344", - "reference": "c3fa8483f9539b190f7cd4bfc4a07631dd1df344", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/64f51654862e0f5e318db7e9dcc2292c63cdbddc", + "reference": "64f51654862e0f5e318db7e9dcc2292c63cdbddc", "shasum": "" }, "require": { @@ -2555,11 +2586,11 @@ "require-dev": { "phpunit/phpunit": "^10.0" }, - "time": "2023-09-18T07:15:37+00:00", + "time": "2023-09-24T13:22:09+00:00", "type": "library", "extra": { "branch-alias": { - "dev-main": "5.0-dev" + "dev-main": "5.1-dev" } }, "installation-source": "dist", @@ -2603,7 +2634,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/exporter/issues", "security": "https://github.com/sebastianbergmann/exporter/security/policy", - "source": "https://github.com/sebastianbergmann/exporter/tree/5.1.0" + "source": "https://github.com/sebastianbergmann/exporter/tree/5.1.1" }, "funding": [ { @@ -3125,17 +3156,17 @@ }, { "name": "squizlabs/php_codesniffer", - "version": "3.7.2", - "version_normalized": "3.7.2.0", + "version": "3.8.0", + "version_normalized": "3.8.0.0", "source": { "type": "git", - "url": "https://github.com/squizlabs/PHP_CodeSniffer.git", - "reference": "ed8e00df0a83aa96acf703f8c2979ff33341f879" + "url": "https://github.com/PHPCSStandards/PHP_CodeSniffer.git", + "reference": "5805f7a4e4958dbb5e944ef1e6edae0a303765e7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/ed8e00df0a83aa96acf703f8c2979ff33341f879", - "reference": "ed8e00df0a83aa96acf703f8c2979ff33341f879", + "url": "https://api.github.com/repos/PHPCSStandards/PHP_CodeSniffer/zipball/5805f7a4e4958dbb5e944ef1e6edae0a303765e7", + "reference": "5805f7a4e4958dbb5e944ef1e6edae0a303765e7", "shasum": "" }, "require": { @@ -3145,9 +3176,9 @@ "php": ">=5.4.0" }, "require-dev": { - "phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0" + "phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0 || ^8.0 || ^9.0" }, - "time": "2023-02-22T23:07:41+00:00", + "time": "2023-12-08T12:32:31+00:00", "bin": [ "bin/phpcs", "bin/phpcbf" @@ -3166,36 +3197,59 @@ "authors": [ { "name": "Greg Sherwood", - "role": "lead" + "role": "Former lead" + }, + { + "name": "Juliette Reinders Folmer", + "role": "Current lead" + }, + { + "name": "Contributors", + "homepage": "https://github.com/PHPCSStandards/PHP_CodeSniffer/graphs/contributors" } ], "description": "PHP_CodeSniffer tokenizes PHP, JavaScript and CSS files and detects violations of a defined set of coding standards.", - "homepage": "https://github.com/squizlabs/PHP_CodeSniffer", + "homepage": "https://github.com/PHPCSStandards/PHP_CodeSniffer", "keywords": [ "phpcs", "standards", "static analysis" ], "support": { - "issues": "https://github.com/squizlabs/PHP_CodeSniffer/issues", - "source": "https://github.com/squizlabs/PHP_CodeSniffer", - "wiki": "https://github.com/squizlabs/PHP_CodeSniffer/wiki" + "issues": "https://github.com/PHPCSStandards/PHP_CodeSniffer/issues", + "security": "https://github.com/PHPCSStandards/PHP_CodeSniffer/security/policy", + "source": "https://github.com/PHPCSStandards/PHP_CodeSniffer", + "wiki": "https://github.com/PHPCSStandards/PHP_CodeSniffer/wiki" }, + "funding": [ + { + "url": "https://github.com/PHPCSStandards", + "type": "github" + }, + { + "url": "https://github.com/jrfnl", + "type": "github" + }, + { + "url": "https://opencollective.com/php_codesniffer", + "type": "open_collective" + } + ], "install-path": "../squizlabs/php_codesniffer" }, { "name": "symfony/console", - "version": "v6.4.0", - "version_normalized": "6.4.0.0", + "version": "v6.4.1", + "version_normalized": "6.4.1.0", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "cd9864b47c367450e14ab32f78fdbf98c44c26b6" + "reference": "a550a7c99daeedef3f9d23fb82e3531525ff11fd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/cd9864b47c367450e14ab32f78fdbf98c44c26b6", - "reference": "cd9864b47c367450e14ab32f78fdbf98c44c26b6", + "url": "https://api.github.com/repos/symfony/console/zipball/a550a7c99daeedef3f9d23fb82e3531525ff11fd", + "reference": "a550a7c99daeedef3f9d23fb82e3531525ff11fd", "shasum": "" }, "require": { @@ -3228,7 +3282,7 @@ "symfony/stopwatch": "^5.4|^6.0|^7.0", "symfony/var-dumper": "^5.4|^6.0|^7.0" }, - "time": "2023-11-20T16:41:16+00:00", + "time": "2023-11-30T10:54:28+00:00", "type": "library", "installation-source": "dist", "autoload": { @@ -3262,7 +3316,7 @@ "terminal" ], "support": { - "source": "https://github.com/symfony/console/tree/v6.4.0" + "source": "https://github.com/symfony/console/tree/v6.4.1" }, "funding": [ { @@ -3954,17 +4008,17 @@ }, { "name": "theseer/tokenizer", - "version": "1.2.1", - "version_normalized": "1.2.1.0", + "version": "1.2.2", + "version_normalized": "1.2.2.0", "source": { "type": "git", "url": "https://github.com/theseer/tokenizer.git", - "reference": "34a41e998c2183e22995f158c581e7b5e755ab9e" + "reference": "b2ad5003ca10d4ee50a12da31de12a5774ba6b96" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/theseer/tokenizer/zipball/34a41e998c2183e22995f158c581e7b5e755ab9e", - "reference": "34a41e998c2183e22995f158c581e7b5e755ab9e", + "url": "https://api.github.com/repos/theseer/tokenizer/zipball/b2ad5003ca10d4ee50a12da31de12a5774ba6b96", + "reference": "b2ad5003ca10d4ee50a12da31de12a5774ba6b96", "shasum": "" }, "require": { @@ -3973,7 +4027,7 @@ "ext-xmlwriter": "*", "php": "^7.2 || ^8.0" }, - "time": "2021-07-28T10:34:58+00:00", + "time": "2023-11-20T00:12:19+00:00", "type": "library", "installation-source": "dist", "autoload": { @@ -3995,7 +4049,7 @@ "description": "A small library for converting tokenized PHP source code into XML and potentially other formats", "support": { "issues": "https://github.com/theseer/tokenizer/issues", - "source": "https://github.com/theseer/tokenizer/tree/1.2.1" + "source": "https://github.com/theseer/tokenizer/tree/1.2.2" }, "funding": [ { diff --git a/vendor/composer/installed.php b/vendor/composer/installed.php index c2e2900c..8b7c3c74 100644 --- a/vendor/composer/installed.php +++ b/vendor/composer/installed.php @@ -20,9 +20,9 @@ 'dev_requirement' => false, ), 'composer/ca-bundle' => array( - 'pretty_version' => '1.3.7', - 'version' => '1.3.7.0', - 'reference' => '76e46335014860eec1aa5a724799a00a2e47cc85', + 'pretty_version' => '1.4.0', + 'version' => '1.4.0.0', + 'reference' => 'b66d11b7479109ab547f9405b97205640b17d385', 'type' => 'library', 'install_path' => __DIR__ . '/./ca-bundle', 'aliases' => array(), @@ -38,9 +38,9 @@ 'dev_requirement' => true, ), 'embed/embed' => array( - 'pretty_version' => 'v4.4.8', - 'version' => '4.4.8.0', - 'reference' => '49134080764018bc6b8a2488dd1c8cc2c47d15fc', + 'pretty_version' => 'v4.4.10', + 'version' => '4.4.10.0', + 'reference' => '8ac21505d048e8796c6cb9172ec5e81e5d0e0408', 'type' => 'library', 'install_path' => __DIR__ . '/../embed/embed', 'aliases' => array(), @@ -83,9 +83,9 @@ 'dev_requirement' => false, ), 'gettext/translator' => array( - 'pretty_version' => 'v1.1.1', - 'version' => '1.1.1.0', - 'reference' => 'b18ff33e8203de623854561f5e47e992fc5c50bb', + 'pretty_version' => 'v1.2.0', + 'version' => '1.2.0.0', + 'reference' => 'a4fa5ed740f304a0ed7b3e169b2b554a195c7570', 'type' => 'library', 'install_path' => __DIR__ . '/../gettext/translator', 'aliases' => array(), @@ -146,18 +146,18 @@ 'dev_requirement' => true, ), 'nikic/php-parser' => array( - 'pretty_version' => 'v4.17.1', - 'version' => '4.17.1.0', - 'reference' => 'a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d', + 'pretty_version' => 'v4.18.0', + 'version' => '4.18.0.0', + 'reference' => '1bcbb2179f97633e98bbbc87044ee2611c7d7999', 'type' => 'library', 'install_path' => __DIR__ . '/../nikic/php-parser', 'aliases' => array(), 'dev_requirement' => true, ), 'oscarotero/html-parser' => array( - 'pretty_version' => 'v0.1.7', - 'version' => '0.1.7.0', - 'reference' => '0c5b619bdc7ac061f06a667d913e2af708ee3231', + 'pretty_version' => 'v0.1.8', + 'version' => '0.1.8.0', + 'reference' => '10f3219267a365d9433f2f7d1694209c9d436c8d', 'type' => 'library', 'install_path' => __DIR__ . '/../oscarotero/html-parser', 'aliases' => array(), @@ -182,27 +182,27 @@ 'dev_requirement' => true, ), 'phpcsstandards/phpcsextra' => array( - 'pretty_version' => '1.1.1', - 'version' => '1.1.1.0', - 'reference' => '98bcdbacbda14b1db85f710b1853125726795bbc', + 'pretty_version' => '1.2.1', + 'version' => '1.2.1.0', + 'reference' => '11d387c6642b6e4acaf0bd9bf5203b8cca1ec489', 'type' => 'phpcodesniffer-standard', 'install_path' => __DIR__ . '/../phpcsstandards/phpcsextra', 'aliases' => array(), 'dev_requirement' => true, ), 'phpcsstandards/phpcsutils' => array( - 'pretty_version' => '1.0.8', - 'version' => '1.0.8.0', - 'reference' => '69465cab9d12454e5e7767b9041af0cd8cd13be7', + 'pretty_version' => '1.0.9', + 'version' => '1.0.9.0', + 'reference' => '908247bc65010c7b7541a9551e002db12e9dae70', 'type' => 'phpcodesniffer-standard', 'install_path' => __DIR__ . '/../phpcsstandards/phpcsutils', 'aliases' => array(), 'dev_requirement' => true, ), 'phpunit/php-code-coverage' => array( - 'pretty_version' => '10.1.6', - 'version' => '10.1.6.0', - 'reference' => '56f33548fe522c8d82da7ff3824b42829d324364', + 'pretty_version' => '10.1.10', + 'version' => '10.1.10.0', + 'reference' => '599109c8ca6bae97b23482d557d2874c25a65e59', 'type' => 'library', 'install_path' => __DIR__ . '/../phpunit/php-code-coverage', 'aliases' => array(), @@ -245,9 +245,9 @@ 'dev_requirement' => true, ), 'phpunit/phpunit' => array( - 'pretty_version' => '10.0.0', - 'version' => '10.0.0.0', - 'reference' => 'c4c60c34c0e92045afce938510f8878d7cd84f8a', + 'pretty_version' => '10.5.3', + 'version' => '10.5.3.0', + 'reference' => '6fce887c71076a73f32fd3e0774a6833fc5c7f19', 'type' => 'library', 'install_path' => __DIR__ . '/../phpunit/phpunit', 'aliases' => array(), @@ -263,9 +263,9 @@ 'dev_requirement' => true, ), 'psr/http-client' => array( - 'pretty_version' => '1.0.2', - 'version' => '1.0.2.0', - 'reference' => '0955afe48220520692d2d09f7ab7e0f93ffd6a31', + 'pretty_version' => '1.0.3', + 'version' => '1.0.3.0', + 'reference' => 'bb5906edc1c324c9a05aa0873d40117941e5fa90', 'type' => 'library', 'install_path' => __DIR__ . '/../psr/http-client', 'aliases' => array(), @@ -362,9 +362,9 @@ 'dev_requirement' => true, ), 'sebastian/complexity' => array( - 'pretty_version' => '3.0.1', - 'version' => '3.0.1.0', - 'reference' => 'c70b73893e10757af9c6a48929fa6a333b56a97a', + 'pretty_version' => '3.1.0', + 'version' => '3.1.0.0', + 'reference' => '68cfb347a44871f01e33ab0ef8215966432f6957', 'type' => 'library', 'install_path' => __DIR__ . '/../sebastian/complexity', 'aliases' => array(), @@ -389,9 +389,9 @@ 'dev_requirement' => true, ), 'sebastian/exporter' => array( - 'pretty_version' => '5.1.0', - 'version' => '5.1.0.0', - 'reference' => 'c3fa8483f9539b190f7cd4bfc4a07631dd1df344', + 'pretty_version' => '5.1.1', + 'version' => '5.1.1.0', + 'reference' => '64f51654862e0f5e318db7e9dcc2292c63cdbddc', 'type' => 'library', 'install_path' => __DIR__ . '/../sebastian/exporter', 'aliases' => array(), @@ -470,18 +470,18 @@ 'dev_requirement' => false, ), 'squizlabs/php_codesniffer' => array( - 'pretty_version' => '3.7.2', - 'version' => '3.7.2.0', - 'reference' => 'ed8e00df0a83aa96acf703f8c2979ff33341f879', + 'pretty_version' => '3.8.0', + 'version' => '3.8.0.0', + 'reference' => '5805f7a4e4958dbb5e944ef1e6edae0a303765e7', 'type' => 'library', 'install_path' => __DIR__ . '/../squizlabs/php_codesniffer', 'aliases' => array(), 'dev_requirement' => true, ), 'symfony/console' => array( - 'pretty_version' => 'v6.4.0', - 'version' => '6.4.0.0', - 'reference' => 'cd9864b47c367450e14ab32f78fdbf98c44c26b6', + 'pretty_version' => 'v6.4.1', + 'version' => '6.4.1.0', + 'reference' => 'a550a7c99daeedef3f9d23fb82e3531525ff11fd', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/console', 'aliases' => array(), @@ -560,9 +560,9 @@ 'dev_requirement' => true, ), 'theseer/tokenizer' => array( - 'pretty_version' => '1.2.1', - 'version' => '1.2.1.0', - 'reference' => '34a41e998c2183e22995f158c581e7b5e755ab9e', + 'pretty_version' => '1.2.2', + 'version' => '1.2.2.0', + 'reference' => 'b2ad5003ca10d4ee50a12da31de12a5774ba6b96', 'type' => 'library', 'install_path' => __DIR__ . '/../theseer/tokenizer', 'aliases' => array(), diff --git a/vendor/embed/embed/CHANGELOG.md b/vendor/embed/embed/CHANGELOG.md index ec1c9a76..05931046 100644 --- a/vendor/embed/embed/CHANGELOG.md +++ b/vendor/embed/embed/CHANGELOG.md @@ -1,10 +1,18 @@ # Changelog - All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/) and this project adheres to [Semantic Versioning](http://semver.org/). +## [4.4.10] - 2023-12-10 +### Fixed +- PHP 7.4 support +- Use correct method for string length [#529] + +## [4.4.9] - 2023-12-01 +### Fixed +- Performance and memory leak issues [#525], [#527]. + ## [4.4.8] - 2023-05-22 ### Fixed - Support for `psr/http-message@2` [#514], [#515] @@ -217,7 +225,12 @@ Full library refactoring. [#507]: https://github.com/oscarotero/Embed/issues/507 [#514]: https://github.com/oscarotero/Embed/issues/514 [#515]: https://github.com/oscarotero/Embed/issues/515 +[#525]: https://github.com/oscarotero/Embed/issues/525 +[#527]: https://github.com/oscarotero/Embed/issues/527 +[#529]: https://github.com/oscarotero/Embed/issues/529 +[4.4.10]: https://github.com/oscarotero/Embed/compare/v4.4.9...v4.4.10 +[4.4.9]: https://github.com/oscarotero/Embed/compare/v4.4.8...v4.4.9 [4.4.8]: https://github.com/oscarotero/Embed/compare/v4.4.7...v4.4.8 [4.4.7]: https://github.com/oscarotero/Embed/compare/v4.4.6...v4.4.7 [4.4.6]: https://github.com/oscarotero/Embed/compare/v4.4.5...v4.4.6 diff --git a/vendor/embed/embed/src/Http/CurlDispatcher.php b/vendor/embed/embed/src/Http/CurlDispatcher.php index 8f61e39f..259a9df4 100644 --- a/vendor/embed/embed/src/Http/CurlDispatcher.php +++ b/vendor/embed/embed/src/Http/CurlDispatcher.php @@ -7,18 +7,23 @@ use Composer\CaBundle\CaBundle; use Psr\Http\Message\RequestInterface; use Psr\Http\Message\ResponseFactoryInterface; use Psr\Http\Message\ResponseInterface; +use Psr\Http\Message\StreamFactoryInterface; +use Psr\Http\Message\StreamInterface; /** * Class to fetch html pages */ final class CurlDispatcher { + private static int $contentLengthThreshold = 5000000; + private RequestInterface $request; + private StreamFactoryInterface $streamFactory; private $curl; private $result; private array $headers = []; private $isBinary = false; - private $body; + private ?StreamInterface $body = null; private ?int $error = null; private array $settings; @@ -29,7 +34,8 @@ final class CurlDispatcher { if (count($requests) === 1) { $connection = new static($settings, $requests[0]); - return [$connection->exec($responseFactory)]; + curl_exec($connection->curl); + return [$connection->getResponse($responseFactory)]; } //Init connections @@ -72,16 +78,17 @@ final class CurlDispatcher curl_multi_close($multi); return array_map( - fn ($connection) => $connection->exec($responseFactory), + fn ($connection) => $connection->getResponse($responseFactory), $connections ); } - private function __construct(array $settings, RequestInterface $request) + private function __construct(array $settings, RequestInterface $request, StreamFactoryInterface $streamFactory = null) { $this->request = $request; $this->curl = curl_init((string) $request->getUri()); $this->settings = $settings; + $this->streamFactory = $streamFactory ?? FactoryDiscovery::getStreamFactory(); $cookies = $settings['cookies_path'] ?? str_replace('//', '/', sys_get_temp_dir().'/embed-cookies.txt'); @@ -107,10 +114,8 @@ final class CurlDispatcher ]); } - private function exec(ResponseFactoryInterface $responseFactory): ResponseInterface + private function getResponse(ResponseFactoryInterface $responseFactory): ResponseInterface { - curl_exec($this->curl); - $info = curl_getinfo($this->curl); if ($this->error) { @@ -136,7 +141,9 @@ final class CurlDispatcher if ($this->body) { //5Mb max - $response->getBody()->write(stream_get_contents($this->body, 5000000, 0)); + $this->body->rewind(); + $response = $response->withBody($this->body); + $this->body = null; } return $response; @@ -199,9 +206,13 @@ final class CurlDispatcher } if (!$this->body) { - $this->body = fopen('php://temp', 'w+'); + $this->body = $this->streamFactory->createStreamFromFile('php://temp', 'w+'); } - return fwrite($this->body, $string); + if ($this->body->getSize() > self::$contentLengthThreshold) { + return strlen($string); + } + + return $this->body->write($string); } } diff --git a/vendor/embed/embed/src/Http/FactoryDiscovery.php b/vendor/embed/embed/src/Http/FactoryDiscovery.php index 75ccf379..8072d6fb 100644 --- a/vendor/embed/embed/src/Http/FactoryDiscovery.php +++ b/vendor/embed/embed/src/Http/FactoryDiscovery.php @@ -5,6 +5,7 @@ namespace Embed\Http; use Psr\Http\Message\RequestFactoryInterface; use Psr\Http\Message\ResponseFactoryInterface; +use Psr\Http\Message\StreamFactoryInterface; use Psr\Http\Message\UriFactoryInterface; use RuntimeException; @@ -34,6 +35,14 @@ abstract class FactoryDiscovery 'Sunrise\Http\Message\UriFactory', ]; + private const STREAM = [ + 'Laminas\Diactoros\StreamFactory', + 'GuzzleHttp\Psr7\HttpFactory', + 'Slim\Psr7\Factory\StreamFactory', + 'Nyholm\Psr7\Factory\Psr17Factory', + 'Sunrise\Http\Message\StreamFactory', + ]; + public static function getRequestFactory(): RequestFactoryInterface { if ($class = self::searchClass(self::REQUEST)) { @@ -57,6 +66,17 @@ abstract class FactoryDiscovery if ($class = self::searchClass(self::URI)) { return new $class(); } + + throw new RuntimeException('No UriFactoryInterface detected'); + } + + public static function getStreamFactory(): StreamFactoryInterface + { + if ($class = self::searchClass(self::STREAM)) { + return new $class(); + } + + throw new RuntimeException('No StreamFactoryInterface detected'); } private static function searchClass($classes): ?string diff --git a/vendor/embed/embed/src/LinkedData.php b/vendor/embed/embed/src/LinkedData.php index 1e3962d6..41f6c533 100644 --- a/vendor/embed/embed/src/LinkedData.php +++ b/vendor/embed/embed/src/LinkedData.php @@ -4,6 +4,7 @@ declare(strict_types = 1); namespace Embed; use Exception; +use ML\JsonLD\JsonLD; use ML\JsonLD\Document as LdDocument; use ML\JsonLD\DocumentInterface; use ML\JsonLD\GraphInterface; @@ -16,7 +17,9 @@ class LinkedData private ?DocumentInterface $document; - private function get(string ...$keys) + private array $allData; + + public function get(string ...$keys) { $graph = $this->getGraph(); @@ -39,6 +42,15 @@ class LinkedData return null; } + public function getAll() + { + if (!isset($this->allData)) { + $this->fetchData(); + } + + return $this->allData; + } + private function getGraph(string $name = null): ?GraphInterface { if (!isset($this->document)) { @@ -50,20 +62,58 @@ class LinkedData } } - return $this->document->getGraph(); + return $this->document->getGraph($name); } protected function fetchData(): array { - $document = $this->extractor->getDocument(); - $content = $document->select('.//script', ['type' => 'application/ld+json'])->str(); + $this->allData = []; - if (empty($content)) { + $document = $this->extractor->getDocument(); + $nodes = $document->select('.//script', ['type' => 'application/ld+json'])->strAll(); + + if (empty($nodes)) { return []; } try { - return json_decode($content, true) ?: []; + $data = []; + $request_uri = (string)$this->extractor->getUri(); + foreach ($nodes as $node) { + $ldjson = json_decode($node, true); + if (!empty($ldjson)) { + + // some pages with multiple ld+json blocks will put + // each block into an array (Flickr does this). Most + // appear to put an object in each ld+json block. To + // prevent them from stepping on one another, the ones + // that are not arrays will be put into an array. + if (!array_is_list($ldjson)) { + $ldjson = [$ldjson]; + } + + foreach ($ldjson as $node) { + if (empty($data)) { + $data = $node; + } elseif (isset($node['mainEntityOfPage'])) { + $url = ''; + if (is_string($node['mainEntityOfPage'])) { + $url = $node['mainEntityOfPage']; + } elseif (isset($node['mainEntityOfPage']['@id'])) { + $url = $node['mainEntityOfPage']['@id']; + } + if (!empty($url) && $url == $request_uri) { + $data = $node; + } + } + } + + + $this->allData = array_merge($this->allData, $ldjson); + } + } + + return $data; } catch (Exception $exception) { return []; } diff --git a/vendor/embed/embed/src/functions.php b/vendor/embed/embed/src/functions.php index 93c18edf..bd35a016 100644 --- a/vendor/embed/embed/src/functions.php +++ b/vendor/embed/embed/src/functions.php @@ -10,7 +10,7 @@ function clean(string $value, bool $allowHTML = false): ?string $value = trim($value); if (!$allowHTML) { - $value = html_entity_decode($value); + $value = html_entity_decode($value, ENT_QUOTES | ENT_SUBSTITUTE | ENT_HTML401); $value = strip_tags($value); } @@ -140,7 +140,7 @@ function getDirectory(string $path, int $position): ?string * * @return boolean */ -function isEmpty(mixed ...$values): bool +function isEmpty(...$values): bool { $skipValues = array( 'undefined', @@ -154,3 +154,25 @@ function isEmpty(mixed ...$values): bool return false; } + +if (!function_exists("array_is_list")) { + /** + * Polyfil for https://www.php.net/manual/en/function.array-is-list.php + * which is only available in PHP 8.1+ + * + * @param array $array The array + * + * @return bool + */ + function array_is_list(array $array): bool + { + $i = -1; + foreach ($array as $k => $v) { + ++$i; + if ($k !== $i) { + return false; + } + } + return true; + } +} diff --git a/vendor/gettext/translator/CHANGELOG.md b/vendor/gettext/translator/CHANGELOG.md index e7ccae65..3231f1cb 100644 --- a/vendor/gettext/translator/CHANGELOG.md +++ b/vendor/gettext/translator/CHANGELOG.md @@ -1,10 +1,13 @@ # Change Log - All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/) and this project adheres to [Semantic Versioning](http://semver.org/). +## [1.2.0] - 2023-11-06 +### Added +- Option to generate prettier PHP code [#8]. + ## [1.1.1] - 2022-02-23 ### Security - Updated the plural form conversion to accept a limited character set [#5] @@ -24,7 +27,9 @@ First version [#1]: https://github.com/php-gettext/Translator/issues/1 [#3]: https://github.com/php-gettext/Translator/issues/3 [#5]: https://github.com/php-gettext/Translator/issues/5 +[#8]: https://github.com/php-gettext/Translator/issues/8 +[1.2.0]: https://github.com/php-gettext/Translator/compare/v1.1.1...v1.2.0 [1.1.1]: https://github.com/php-gettext/Translator/compare/v1.1.0...v1.1.1 [1.1.0]: https://github.com/php-gettext/Translator/compare/v1.0.1...v1.1.0 [1.0.1]: https://github.com/php-gettext/Translator/compare/v1.0.0...v1.0.1 diff --git a/vendor/gettext/translator/README.md b/vendor/gettext/translator/README.md index e43e291c..f36ed05c 100644 --- a/vendor/gettext/translator/README.md +++ b/vendor/gettext/translator/README.md @@ -48,7 +48,7 @@ $t->setLanguage('gl'); //Load the domains: $t->loadDomain('messages', 'project/Locale'); -//this means you have the file "project/Locale/gl/LC_MESSAGES/messages.po" +//this means you have the file "project/Locale/gl/LC_MESSAGES/messages.mo" //Now you can use it in your templates echo $t->gettext('apple'); diff --git a/vendor/gettext/translator/src/Generator/ArrayGenerator.php b/vendor/gettext/translator/src/Generator/ArrayGenerator.php index 28c7a8fb..60dfe9fb 100644 --- a/vendor/gettext/translator/src/Generator/ArrayGenerator.php +++ b/vendor/gettext/translator/src/Generator/ArrayGenerator.php @@ -9,8 +9,26 @@ use Gettext\Translations; final class ArrayGenerator extends Generator { + /** + * @private + */ + const PRETTY_INDENT = ' '; + + /** + * @var bool + */ private $includeEmpty; + /** + * @var bool + */ + private $strictTypes; + + /** + * @var bool + */ + private $pretty; + /** * Constructs a new ArrayGenerator * @param array|null $options @@ -20,13 +38,21 @@ final class ArrayGenerator extends Generator public function __construct(?array $options = null) { $this->includeEmpty = (bool) ($options['includeEmpty'] ?? false); + $this->strictTypes = (bool) ($options['strictTypes'] ?? false); + $this->pretty = (bool) ($options['pretty'] ?? false); } public function generateString(Translations $translations): string { $array = $this->generateArray($translations); + $result = 'pretty) { + $result .= $this->strictTypes ? "\n\ndeclare(strict_types=1);\n\n" : "\n\n"; + } else { + $result .= $this->strictTypes ? ' declare(strict_types=1); ' : ' '; + } - return sprintf('pretty ? self::prettyExport($array) : (var_export($array, true) . ';')); } public function generateArray(Translations $translations): array @@ -66,4 +92,48 @@ final class ArrayGenerator extends Generator { return implode('', $translation->getPluralTranslations()) !== ''; } + + private static function prettyExport(array &$array): string + { + return self::prettyExportArray($array, 0) . ";\n"; + } + + private static function prettyExportArray(array &$array, int $depth): string + { + if ($array === []) { + return '[]'; + } + $result = '['; + $isList = self::isList($array); + foreach ($array as $key => $value) { + $result .= "\n" . str_repeat(self::PRETTY_INDENT, $depth + 1); + if (!$isList) { + $result .= var_export($key, true) . ' => '; + } + if (is_array($value)) { + $result .= self::prettyExportArray($value, $depth + 1); + } else { + $result .= self::prettyExportScalar($value); + } + $result .= ','; + } + return $result . "\n" . str_repeat(self::PRETTY_INDENT, $depth) . ']'; + } + + private static function prettyExportScalar($value): string + { + return $value === null ? 'null' : var_export($value, true); + } + + private static function isList(array &$value): bool + { + if ($value === []) { + return true; + } + if (function_exists('array_is_list')) { + return \array_is_list($value); + } + + return array_keys($value) === range(0, count($value) - 1); + } } diff --git a/vendor/nikic/php-parser/grammar/README.md b/vendor/nikic/php-parser/grammar/README.md deleted file mode 100644 index 4bae11d8..00000000 --- a/vendor/nikic/php-parser/grammar/README.md +++ /dev/null @@ -1,30 +0,0 @@ -What do all those files mean? -============================= - - * `php5.y`: PHP 5 grammar written in a pseudo language - * `php7.y`: PHP 7 grammar written in a pseudo language - * `tokens.y`: Tokens definition shared between PHP 5 and PHP 7 grammars - * `parser.template`: A `kmyacc` parser prototype file for PHP - * `tokens.template`: A `kmyacc` prototype file for the `Tokens` class - * `rebuildParsers.php`: Preprocesses the grammar and builds the parser using `kmyacc` - -.phpy pseudo language -===================== - -The `.y` file is a normal grammar in `kmyacc` (`yacc`) style, with some transformations -applied to it: - - * Nodes are created using the syntax `Name[..., ...]`. This is transformed into - `new Name(..., ..., attributes())` - * Some function-like constructs are resolved (see `rebuildParsers.php` for a list) - -Building the parser -=================== - -Run `php grammar/rebuildParsers.php` to rebuild the parsers. Additional options: - - * The `KMYACC` environment variable can be used to specify an alternative `kmyacc` binary. - By default the `phpyacc` dev dependency will be used. To use the original `kmyacc`, you - need to compile [moriyoshi's fork](https://github.com/moriyoshi/kmyacc-forked). - * The `--debug` option enables emission of debug symbols and creates the `y.output` file. - * The `--keep-tmp-grammar` option preserves the preprocessed grammar file. diff --git a/vendor/nikic/php-parser/grammar/parser.template b/vendor/nikic/php-parser/grammar/parser.template deleted file mode 100644 index 6166607c..00000000 --- a/vendor/nikic/php-parser/grammar/parser.template +++ /dev/null @@ -1,106 +0,0 @@ -semValue -#semval($,%t) $this->semValue -#semval(%n) $stackPos-(%l-%n) -#semval(%n,%t) $stackPos-(%l-%n) - -namespace PhpParser\Parser; - -use PhpParser\Error; -use PhpParser\Node; -use PhpParser\Node\Expr; -use PhpParser\Node\Name; -use PhpParser\Node\Scalar; -use PhpParser\Node\Stmt; -#include; - -/* This is an automatically GENERATED file, which should not be manually edited. - * Instead edit one of the following: - * * the grammar files grammar/php5.y or grammar/php7.y - * * the skeleton file grammar/parser.template - * * the preprocessing script grammar/rebuildParsers.php - */ -class #(-p) extends \PhpParser\ParserAbstract -{ - protected $tokenToSymbolMapSize = #(YYMAXLEX); - protected $actionTableSize = #(YYLAST); - protected $gotoTableSize = #(YYGLAST); - - protected $invalidSymbol = #(YYBADCH); - protected $errorSymbol = #(YYINTERRTOK); - protected $defaultAction = #(YYDEFAULT); - protected $unexpectedTokenRule = #(YYUNEXPECTED); - - protected $YY2TBLSTATE = #(YY2TBLSTATE); - protected $numNonLeafStates = #(YYNLSTATES); - - protected $symbolToName = array( - #listvar terminals - ); - - protected $tokenToSymbol = array( - #listvar yytranslate - ); - - protected $action = array( - #listvar yyaction - ); - - protected $actionCheck = array( - #listvar yycheck - ); - - protected $actionBase = array( - #listvar yybase - ); - - protected $actionDefault = array( - #listvar yydefault - ); - - protected $goto = array( - #listvar yygoto - ); - - protected $gotoCheck = array( - #listvar yygcheck - ); - - protected $gotoBase = array( - #listvar yygbase - ); - - protected $gotoDefault = array( - #listvar yygdefault - ); - - protected $ruleToNonTerminal = array( - #listvar yylhs - ); - - protected $ruleToLength = array( - #listvar yylen - ); -#if -t - - protected $productions = array( - #production-strings; - ); -#endif - - protected function initReduceCallbacks() { - $this->reduceCallbacks = [ -#reduce - %n => function ($stackPos) { - %b - }, -#noact - %n => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos]; - }, -#endreduce - ]; - } -} -#tailcode; diff --git a/vendor/nikic/php-parser/grammar/php5.y b/vendor/nikic/php-parser/grammar/php5.y deleted file mode 100644 index 77e4fb7e..00000000 --- a/vendor/nikic/php-parser/grammar/php5.y +++ /dev/null @@ -1,1046 +0,0 @@ -%pure_parser -%expect 6 - -%tokens - -%% - -start: - top_statement_list { $$ = $this->handleNamespaces($1); } -; - -top_statement_list_ex: - top_statement_list_ex top_statement { pushNormalizing($1, $2); } - | /* empty */ { init(); } -; - -top_statement_list: - top_statement_list_ex - { makeZeroLengthNop($nop, $this->lookaheadStartAttributes); - if ($nop !== null) { $1[] = $nop; } $$ = $1; } -; - -ampersand: - T_AMPERSAND_FOLLOWED_BY_VAR_OR_VARARG - | T_AMPERSAND_NOT_FOLLOWED_BY_VAR_OR_VARARG -; - -reserved_non_modifiers: - T_INCLUDE | T_INCLUDE_ONCE | T_EVAL | T_REQUIRE | T_REQUIRE_ONCE | T_LOGICAL_OR | T_LOGICAL_XOR | T_LOGICAL_AND - | T_INSTANCEOF | T_NEW | T_CLONE | T_EXIT | T_IF | T_ELSEIF | T_ELSE | T_ENDIF | T_ECHO | T_DO | T_WHILE - | T_ENDWHILE | T_FOR | T_ENDFOR | T_FOREACH | T_ENDFOREACH | T_DECLARE | T_ENDDECLARE | T_AS | T_TRY | T_CATCH - | T_FINALLY | T_THROW | T_USE | T_INSTEADOF | T_GLOBAL | T_VAR | T_UNSET | T_ISSET | T_EMPTY | T_CONTINUE | T_GOTO - | T_FUNCTION | T_CONST | T_RETURN | T_PRINT | T_YIELD | T_LIST | T_SWITCH | T_ENDSWITCH | T_CASE | T_DEFAULT - | T_BREAK | T_ARRAY | T_CALLABLE | T_EXTENDS | T_IMPLEMENTS | T_NAMESPACE | T_TRAIT | T_INTERFACE | T_CLASS - | T_CLASS_C | T_TRAIT_C | T_FUNC_C | T_METHOD_C | T_LINE | T_FILE | T_DIR | T_NS_C | T_HALT_COMPILER | T_FN - | T_MATCH -; - -semi_reserved: - reserved_non_modifiers - | T_STATIC | T_ABSTRACT | T_FINAL | T_PRIVATE | T_PROTECTED | T_PUBLIC -; - -identifier_ex: - T_STRING { $$ = Node\Identifier[$1]; } - | semi_reserved { $$ = Node\Identifier[$1]; } -; - -identifier: - T_STRING { $$ = Node\Identifier[$1]; } -; - -reserved_non_modifiers_identifier: - reserved_non_modifiers { $$ = Node\Identifier[$1]; } -; - -namespace_name: - T_STRING { $$ = Name[$1]; } - | T_NAME_QUALIFIED { $$ = Name[$1]; } -; - -legacy_namespace_name: - namespace_name { $$ = $1; } - | T_NAME_FULLY_QUALIFIED { $$ = Name[substr($1, 1)]; } -; - -plain_variable: - T_VARIABLE { $$ = Expr\Variable[parseVar($1)]; } -; - -top_statement: - statement { $$ = $1; } - | function_declaration_statement { $$ = $1; } - | class_declaration_statement { $$ = $1; } - | T_HALT_COMPILER - { $$ = Stmt\HaltCompiler[$this->lexer->handleHaltCompiler()]; } - | T_NAMESPACE namespace_name ';' - { $$ = Stmt\Namespace_[$2, null]; - $$->setAttribute('kind', Stmt\Namespace_::KIND_SEMICOLON); - $this->checkNamespace($$); } - | T_NAMESPACE namespace_name '{' top_statement_list '}' - { $$ = Stmt\Namespace_[$2, $4]; - $$->setAttribute('kind', Stmt\Namespace_::KIND_BRACED); - $this->checkNamespace($$); } - | T_NAMESPACE '{' top_statement_list '}' - { $$ = Stmt\Namespace_[null, $3]; - $$->setAttribute('kind', Stmt\Namespace_::KIND_BRACED); - $this->checkNamespace($$); } - | T_USE use_declarations ';' { $$ = Stmt\Use_[$2, Stmt\Use_::TYPE_NORMAL]; } - | T_USE use_type use_declarations ';' { $$ = Stmt\Use_[$3, $2]; } - | group_use_declaration ';' { $$ = $1; } - | T_CONST constant_declaration_list ';' { $$ = Stmt\Const_[$2]; } -; - -use_type: - T_FUNCTION { $$ = Stmt\Use_::TYPE_FUNCTION; } - | T_CONST { $$ = Stmt\Use_::TYPE_CONSTANT; } -; - -group_use_declaration: - T_USE use_type legacy_namespace_name T_NS_SEPARATOR '{' unprefixed_use_declarations '}' - { $$ = Stmt\GroupUse[$3, $6, $2]; } - | T_USE legacy_namespace_name T_NS_SEPARATOR '{' inline_use_declarations '}' - { $$ = Stmt\GroupUse[$2, $5, Stmt\Use_::TYPE_UNKNOWN]; } -; - -unprefixed_use_declarations: - unprefixed_use_declarations ',' unprefixed_use_declaration - { push($1, $3); } - | unprefixed_use_declaration { init($1); } -; - -use_declarations: - use_declarations ',' use_declaration { push($1, $3); } - | use_declaration { init($1); } -; - -inline_use_declarations: - inline_use_declarations ',' inline_use_declaration { push($1, $3); } - | inline_use_declaration { init($1); } -; - -unprefixed_use_declaration: - namespace_name - { $$ = Stmt\UseUse[$1, null, Stmt\Use_::TYPE_UNKNOWN]; $this->checkUseUse($$, #1); } - | namespace_name T_AS identifier - { $$ = Stmt\UseUse[$1, $3, Stmt\Use_::TYPE_UNKNOWN]; $this->checkUseUse($$, #3); } -; - -use_declaration: - legacy_namespace_name - { $$ = Stmt\UseUse[$1, null, Stmt\Use_::TYPE_UNKNOWN]; $this->checkUseUse($$, #1); } - | legacy_namespace_name T_AS identifier - { $$ = Stmt\UseUse[$1, $3, Stmt\Use_::TYPE_UNKNOWN]; $this->checkUseUse($$, #3); } -; - -inline_use_declaration: - unprefixed_use_declaration { $$ = $1; $$->type = Stmt\Use_::TYPE_NORMAL; } - | use_type unprefixed_use_declaration { $$ = $2; $$->type = $1; } -; - -constant_declaration_list: - constant_declaration_list ',' constant_declaration { push($1, $3); } - | constant_declaration { init($1); } -; - -constant_declaration: - identifier '=' static_scalar { $$ = Node\Const_[$1, $3]; } -; - -class_const_list: - class_const_list ',' class_const { push($1, $3); } - | class_const { init($1); } -; - -class_const: - identifier_ex '=' static_scalar { $$ = Node\Const_[$1, $3]; } -; - -inner_statement_list_ex: - inner_statement_list_ex inner_statement { pushNormalizing($1, $2); } - | /* empty */ { init(); } -; - -inner_statement_list: - inner_statement_list_ex - { makeZeroLengthNop($nop, $this->lookaheadStartAttributes); - if ($nop !== null) { $1[] = $nop; } $$ = $1; } -; - -inner_statement: - statement { $$ = $1; } - | function_declaration_statement { $$ = $1; } - | class_declaration_statement { $$ = $1; } - | T_HALT_COMPILER - { throw new Error('__HALT_COMPILER() can only be used from the outermost scope', attributes()); } -; - -non_empty_statement: - '{' inner_statement_list '}' - { - if ($2) { - $$ = $2; prependLeadingComments($$); - } else { - makeNop($$, $this->startAttributeStack[#1], $this->endAttributes); - if (null === $$) { $$ = array(); } - } - } - | T_IF parentheses_expr statement elseif_list else_single - { $$ = Stmt\If_[$2, ['stmts' => toArray($3), 'elseifs' => $4, 'else' => $5]]; } - | T_IF parentheses_expr ':' inner_statement_list new_elseif_list new_else_single T_ENDIF ';' - { $$ = Stmt\If_[$2, ['stmts' => $4, 'elseifs' => $5, 'else' => $6]]; } - | T_WHILE parentheses_expr while_statement { $$ = Stmt\While_[$2, $3]; } - | T_DO statement T_WHILE parentheses_expr ';' { $$ = Stmt\Do_ [$4, toArray($2)]; } - | T_FOR '(' for_expr ';' for_expr ';' for_expr ')' for_statement - { $$ = Stmt\For_[['init' => $3, 'cond' => $5, 'loop' => $7, 'stmts' => $9]]; } - | T_SWITCH parentheses_expr switch_case_list { $$ = Stmt\Switch_[$2, $3]; } - | T_BREAK ';' { $$ = Stmt\Break_[null]; } - | T_BREAK expr ';' { $$ = Stmt\Break_[$2]; } - | T_CONTINUE ';' { $$ = Stmt\Continue_[null]; } - | T_CONTINUE expr ';' { $$ = Stmt\Continue_[$2]; } - | T_RETURN ';' { $$ = Stmt\Return_[null]; } - | T_RETURN expr ';' { $$ = Stmt\Return_[$2]; } - | T_GLOBAL global_var_list ';' { $$ = Stmt\Global_[$2]; } - | T_STATIC static_var_list ';' { $$ = Stmt\Static_[$2]; } - | T_ECHO expr_list ';' { $$ = Stmt\Echo_[$2]; } - | T_INLINE_HTML { $$ = Stmt\InlineHTML[$1]; } - | yield_expr ';' { $$ = Stmt\Expression[$1]; } - | expr ';' { $$ = Stmt\Expression[$1]; } - | T_UNSET '(' variables_list ')' ';' { $$ = Stmt\Unset_[$3]; } - | T_FOREACH '(' expr T_AS foreach_variable ')' foreach_statement - { $$ = Stmt\Foreach_[$3, $5[0], ['keyVar' => null, 'byRef' => $5[1], 'stmts' => $7]]; } - | T_FOREACH '(' expr T_AS variable T_DOUBLE_ARROW foreach_variable ')' foreach_statement - { $$ = Stmt\Foreach_[$3, $7[0], ['keyVar' => $5, 'byRef' => $7[1], 'stmts' => $9]]; } - | T_DECLARE '(' declare_list ')' declare_statement { $$ = Stmt\Declare_[$3, $5]; } - | T_TRY '{' inner_statement_list '}' catches optional_finally - { $$ = Stmt\TryCatch[$3, $5, $6]; $this->checkTryCatch($$); } - | T_THROW expr ';' { $$ = Stmt\Throw_[$2]; } - | T_GOTO identifier ';' { $$ = Stmt\Goto_[$2]; } - | identifier ':' { $$ = Stmt\Label[$1]; } - | expr error { $$ = Stmt\Expression[$1]; } - | error { $$ = array(); /* means: no statement */ } -; - -statement: - non_empty_statement { $$ = $1; } - | ';' - { makeNop($$, $this->startAttributeStack[#1], $this->endAttributes); - if ($$ === null) $$ = array(); /* means: no statement */ } -; - -catches: - /* empty */ { init(); } - | catches catch { push($1, $2); } -; - -catch: - T_CATCH '(' name plain_variable ')' '{' inner_statement_list '}' - { $$ = Stmt\Catch_[array($3), $4, $7]; } -; - -optional_finally: - /* empty */ { $$ = null; } - | T_FINALLY '{' inner_statement_list '}' { $$ = Stmt\Finally_[$3]; } -; - -variables_list: - variable { init($1); } - | variables_list ',' variable { push($1, $3); } -; - -optional_ref: - /* empty */ { $$ = false; } - | ampersand { $$ = true; } -; - -optional_arg_ref: - /* empty */ { $$ = false; } - | T_AMPERSAND_FOLLOWED_BY_VAR_OR_VARARG { $$ = true; } -; - -optional_ellipsis: - /* empty */ { $$ = false; } - | T_ELLIPSIS { $$ = true; } -; - -identifier_maybe_readonly: - identifier { $$ = $1; } - | T_READONLY { $$ = Node\Identifier[$1]; } -; - -function_declaration_statement: - T_FUNCTION optional_ref identifier_maybe_readonly '(' parameter_list ')' optional_return_type '{' inner_statement_list '}' - { $$ = Stmt\Function_[$3, ['byRef' => $2, 'params' => $5, 'returnType' => $7, 'stmts' => $9]]; } -; - -class_declaration_statement: - class_entry_type identifier extends_from implements_list '{' class_statement_list '}' - { $$ = Stmt\Class_[$2, ['type' => $1, 'extends' => $3, 'implements' => $4, 'stmts' => $6]]; - $this->checkClass($$, #2); } - | T_INTERFACE identifier interface_extends_list '{' class_statement_list '}' - { $$ = Stmt\Interface_[$2, ['extends' => $3, 'stmts' => $5]]; - $this->checkInterface($$, #2); } - | T_TRAIT identifier '{' class_statement_list '}' - { $$ = Stmt\Trait_[$2, ['stmts' => $4]]; } -; - -class_entry_type: - T_CLASS { $$ = 0; } - | T_ABSTRACT T_CLASS { $$ = Stmt\Class_::MODIFIER_ABSTRACT; } - | T_FINAL T_CLASS { $$ = Stmt\Class_::MODIFIER_FINAL; } -; - -extends_from: - /* empty */ { $$ = null; } - | T_EXTENDS class_name { $$ = $2; } -; - -interface_extends_list: - /* empty */ { $$ = array(); } - | T_EXTENDS class_name_list { $$ = $2; } -; - -implements_list: - /* empty */ { $$ = array(); } - | T_IMPLEMENTS class_name_list { $$ = $2; } -; - -class_name_list: - class_name { init($1); } - | class_name_list ',' class_name { push($1, $3); } -; - -for_statement: - statement { $$ = toArray($1); } - | ':' inner_statement_list T_ENDFOR ';' { $$ = $2; } -; - -foreach_statement: - statement { $$ = toArray($1); } - | ':' inner_statement_list T_ENDFOREACH ';' { $$ = $2; } -; - -declare_statement: - non_empty_statement { $$ = toArray($1); } - | ';' { $$ = null; } - | ':' inner_statement_list T_ENDDECLARE ';' { $$ = $2; } -; - -declare_list: - declare_list_element { init($1); } - | declare_list ',' declare_list_element { push($1, $3); } -; - -declare_list_element: - identifier '=' static_scalar { $$ = Stmt\DeclareDeclare[$1, $3]; } -; - -switch_case_list: - '{' case_list '}' { $$ = $2; } - | '{' ';' case_list '}' { $$ = $3; } - | ':' case_list T_ENDSWITCH ';' { $$ = $2; } - | ':' ';' case_list T_ENDSWITCH ';' { $$ = $3; } -; - -case_list: - /* empty */ { init(); } - | case_list case { push($1, $2); } -; - -case: - T_CASE expr case_separator inner_statement_list_ex { $$ = Stmt\Case_[$2, $4]; } - | T_DEFAULT case_separator inner_statement_list_ex { $$ = Stmt\Case_[null, $3]; } -; - -case_separator: - ':' - | ';' -; - -while_statement: - statement { $$ = toArray($1); } - | ':' inner_statement_list T_ENDWHILE ';' { $$ = $2; } -; - -elseif_list: - /* empty */ { init(); } - | elseif_list elseif { push($1, $2); } -; - -elseif: - T_ELSEIF parentheses_expr statement { $$ = Stmt\ElseIf_[$2, toArray($3)]; } -; - -new_elseif_list: - /* empty */ { init(); } - | new_elseif_list new_elseif { push($1, $2); } -; - -new_elseif: - T_ELSEIF parentheses_expr ':' inner_statement_list { $$ = Stmt\ElseIf_[$2, $4]; } -; - -else_single: - /* empty */ { $$ = null; } - | T_ELSE statement { $$ = Stmt\Else_[toArray($2)]; } -; - -new_else_single: - /* empty */ { $$ = null; } - | T_ELSE ':' inner_statement_list { $$ = Stmt\Else_[$3]; } -; - -foreach_variable: - variable { $$ = array($1, false); } - | ampersand variable { $$ = array($2, true); } - | list_expr { $$ = array($1, false); } -; - -parameter_list: - non_empty_parameter_list { $$ = $1; } - | /* empty */ { $$ = array(); } -; - -non_empty_parameter_list: - parameter { init($1); } - | non_empty_parameter_list ',' parameter { push($1, $3); } -; - -parameter: - optional_param_type optional_arg_ref optional_ellipsis plain_variable - { $$ = Node\Param[$4, null, $1, $2, $3]; $this->checkParam($$); } - | optional_param_type optional_arg_ref optional_ellipsis plain_variable '=' static_scalar - { $$ = Node\Param[$4, $6, $1, $2, $3]; $this->checkParam($$); } -; - -type: - name { $$ = $1; } - | T_ARRAY { $$ = Node\Identifier['array']; } - | T_CALLABLE { $$ = Node\Identifier['callable']; } -; - -optional_param_type: - /* empty */ { $$ = null; } - | type { $$ = $1; } -; - -optional_return_type: - /* empty */ { $$ = null; } - | ':' type { $$ = $2; } -; - -argument_list: - '(' ')' { $$ = array(); } - | '(' non_empty_argument_list ')' { $$ = $2; } - | '(' yield_expr ')' { $$ = array(Node\Arg[$2, false, false]); } -; - -non_empty_argument_list: - argument { init($1); } - | non_empty_argument_list ',' argument { push($1, $3); } -; - -argument: - expr { $$ = Node\Arg[$1, false, false]; } - | ampersand variable { $$ = Node\Arg[$2, true, false]; } - | T_ELLIPSIS expr { $$ = Node\Arg[$2, false, true]; } -; - -global_var_list: - global_var_list ',' global_var { push($1, $3); } - | global_var { init($1); } -; - -global_var: - plain_variable { $$ = $1; } - | '$' variable { $$ = Expr\Variable[$2]; } - | '$' '{' expr '}' { $$ = Expr\Variable[$3]; } -; - -static_var_list: - static_var_list ',' static_var { push($1, $3); } - | static_var { init($1); } -; - -static_var: - plain_variable { $$ = Stmt\StaticVar[$1, null]; } - | plain_variable '=' static_scalar { $$ = Stmt\StaticVar[$1, $3]; } -; - -class_statement_list_ex: - class_statement_list_ex class_statement { if ($2 !== null) { push($1, $2); } } - | /* empty */ { init(); } -; - -class_statement_list: - class_statement_list_ex - { makeZeroLengthNop($nop, $this->lookaheadStartAttributes); - if ($nop !== null) { $1[] = $nop; } $$ = $1; } -; - -class_statement: - variable_modifiers property_declaration_list ';' - { $$ = Stmt\Property[$1, $2]; $this->checkProperty($$, #1); } - | T_CONST class_const_list ';' { $$ = Stmt\ClassConst[$2, 0]; } - | method_modifiers T_FUNCTION optional_ref identifier_ex '(' parameter_list ')' optional_return_type method_body - { $$ = Stmt\ClassMethod[$4, ['type' => $1, 'byRef' => $3, 'params' => $6, 'returnType' => $8, 'stmts' => $9]]; - $this->checkClassMethod($$, #1); } - | T_USE class_name_list trait_adaptations { $$ = Stmt\TraitUse[$2, $3]; } -; - -trait_adaptations: - ';' { $$ = array(); } - | '{' trait_adaptation_list '}' { $$ = $2; } -; - -trait_adaptation_list: - /* empty */ { init(); } - | trait_adaptation_list trait_adaptation { push($1, $2); } -; - -trait_adaptation: - trait_method_reference_fully_qualified T_INSTEADOF class_name_list ';' - { $$ = Stmt\TraitUseAdaptation\Precedence[$1[0], $1[1], $3]; } - | trait_method_reference T_AS member_modifier identifier_ex ';' - { $$ = Stmt\TraitUseAdaptation\Alias[$1[0], $1[1], $3, $4]; } - | trait_method_reference T_AS member_modifier ';' - { $$ = Stmt\TraitUseAdaptation\Alias[$1[0], $1[1], $3, null]; } - | trait_method_reference T_AS identifier ';' - { $$ = Stmt\TraitUseAdaptation\Alias[$1[0], $1[1], null, $3]; } - | trait_method_reference T_AS reserved_non_modifiers_identifier ';' - { $$ = Stmt\TraitUseAdaptation\Alias[$1[0], $1[1], null, $3]; } -; - -trait_method_reference_fully_qualified: - name T_PAAMAYIM_NEKUDOTAYIM identifier_ex { $$ = array($1, $3); } -; -trait_method_reference: - trait_method_reference_fully_qualified { $$ = $1; } - | identifier_ex { $$ = array(null, $1); } -; - -method_body: - ';' /* abstract method */ { $$ = null; } - | '{' inner_statement_list '}' { $$ = $2; } -; - -variable_modifiers: - non_empty_member_modifiers { $$ = $1; } - | T_VAR { $$ = 0; } -; - -method_modifiers: - /* empty */ { $$ = 0; } - | non_empty_member_modifiers { $$ = $1; } -; - -non_empty_member_modifiers: - member_modifier { $$ = $1; } - | non_empty_member_modifiers member_modifier { $this->checkModifier($1, $2, #2); $$ = $1 | $2; } -; - -member_modifier: - T_PUBLIC { $$ = Stmt\Class_::MODIFIER_PUBLIC; } - | T_PROTECTED { $$ = Stmt\Class_::MODIFIER_PROTECTED; } - | T_PRIVATE { $$ = Stmt\Class_::MODIFIER_PRIVATE; } - | T_STATIC { $$ = Stmt\Class_::MODIFIER_STATIC; } - | T_ABSTRACT { $$ = Stmt\Class_::MODIFIER_ABSTRACT; } - | T_FINAL { $$ = Stmt\Class_::MODIFIER_FINAL; } -; - -property_declaration_list: - property_declaration { init($1); } - | property_declaration_list ',' property_declaration { push($1, $3); } -; - -property_decl_name: - T_VARIABLE { $$ = Node\VarLikeIdentifier[parseVar($1)]; } -; - -property_declaration: - property_decl_name { $$ = Stmt\PropertyProperty[$1, null]; } - | property_decl_name '=' static_scalar { $$ = Stmt\PropertyProperty[$1, $3]; } -; - -expr_list: - expr_list ',' expr { push($1, $3); } - | expr { init($1); } -; - -for_expr: - /* empty */ { $$ = array(); } - | expr_list { $$ = $1; } -; - -expr: - variable { $$ = $1; } - | list_expr '=' expr { $$ = Expr\Assign[$1, $3]; } - | variable '=' expr { $$ = Expr\Assign[$1, $3]; } - | variable '=' ampersand variable { $$ = Expr\AssignRef[$1, $4]; } - | variable '=' ampersand new_expr { $$ = Expr\AssignRef[$1, $4]; } - | new_expr { $$ = $1; } - | T_CLONE expr { $$ = Expr\Clone_[$2]; } - | variable T_PLUS_EQUAL expr { $$ = Expr\AssignOp\Plus [$1, $3]; } - | variable T_MINUS_EQUAL expr { $$ = Expr\AssignOp\Minus [$1, $3]; } - | variable T_MUL_EQUAL expr { $$ = Expr\AssignOp\Mul [$1, $3]; } - | variable T_DIV_EQUAL expr { $$ = Expr\AssignOp\Div [$1, $3]; } - | variable T_CONCAT_EQUAL expr { $$ = Expr\AssignOp\Concat [$1, $3]; } - | variable T_MOD_EQUAL expr { $$ = Expr\AssignOp\Mod [$1, $3]; } - | variable T_AND_EQUAL expr { $$ = Expr\AssignOp\BitwiseAnd[$1, $3]; } - | variable T_OR_EQUAL expr { $$ = Expr\AssignOp\BitwiseOr [$1, $3]; } - | variable T_XOR_EQUAL expr { $$ = Expr\AssignOp\BitwiseXor[$1, $3]; } - | variable T_SL_EQUAL expr { $$ = Expr\AssignOp\ShiftLeft [$1, $3]; } - | variable T_SR_EQUAL expr { $$ = Expr\AssignOp\ShiftRight[$1, $3]; } - | variable T_POW_EQUAL expr { $$ = Expr\AssignOp\Pow [$1, $3]; } - | variable T_COALESCE_EQUAL expr { $$ = Expr\AssignOp\Coalesce [$1, $3]; } - | variable T_INC { $$ = Expr\PostInc[$1]; } - | T_INC variable { $$ = Expr\PreInc [$2]; } - | variable T_DEC { $$ = Expr\PostDec[$1]; } - | T_DEC variable { $$ = Expr\PreDec [$2]; } - | expr T_BOOLEAN_OR expr { $$ = Expr\BinaryOp\BooleanOr [$1, $3]; } - | expr T_BOOLEAN_AND expr { $$ = Expr\BinaryOp\BooleanAnd[$1, $3]; } - | expr T_LOGICAL_OR expr { $$ = Expr\BinaryOp\LogicalOr [$1, $3]; } - | expr T_LOGICAL_AND expr { $$ = Expr\BinaryOp\LogicalAnd[$1, $3]; } - | expr T_LOGICAL_XOR expr { $$ = Expr\BinaryOp\LogicalXor[$1, $3]; } - | expr '|' expr { $$ = Expr\BinaryOp\BitwiseOr [$1, $3]; } - | expr T_AMPERSAND_NOT_FOLLOWED_BY_VAR_OR_VARARG expr { $$ = Expr\BinaryOp\BitwiseAnd[$1, $3]; } - | expr T_AMPERSAND_FOLLOWED_BY_VAR_OR_VARARG expr { $$ = Expr\BinaryOp\BitwiseAnd[$1, $3]; } - | expr '^' expr { $$ = Expr\BinaryOp\BitwiseXor[$1, $3]; } - | expr '.' expr { $$ = Expr\BinaryOp\Concat [$1, $3]; } - | expr '+' expr { $$ = Expr\BinaryOp\Plus [$1, $3]; } - | expr '-' expr { $$ = Expr\BinaryOp\Minus [$1, $3]; } - | expr '*' expr { $$ = Expr\BinaryOp\Mul [$1, $3]; } - | expr '/' expr { $$ = Expr\BinaryOp\Div [$1, $3]; } - | expr '%' expr { $$ = Expr\BinaryOp\Mod [$1, $3]; } - | expr T_SL expr { $$ = Expr\BinaryOp\ShiftLeft [$1, $3]; } - | expr T_SR expr { $$ = Expr\BinaryOp\ShiftRight[$1, $3]; } - | expr T_POW expr { $$ = Expr\BinaryOp\Pow [$1, $3]; } - | '+' expr %prec T_INC { $$ = Expr\UnaryPlus [$2]; } - | '-' expr %prec T_INC { $$ = Expr\UnaryMinus[$2]; } - | '!' expr { $$ = Expr\BooleanNot[$2]; } - | '~' expr { $$ = Expr\BitwiseNot[$2]; } - | expr T_IS_IDENTICAL expr { $$ = Expr\BinaryOp\Identical [$1, $3]; } - | expr T_IS_NOT_IDENTICAL expr { $$ = Expr\BinaryOp\NotIdentical [$1, $3]; } - | expr T_IS_EQUAL expr { $$ = Expr\BinaryOp\Equal [$1, $3]; } - | expr T_IS_NOT_EQUAL expr { $$ = Expr\BinaryOp\NotEqual [$1, $3]; } - | expr T_SPACESHIP expr { $$ = Expr\BinaryOp\Spaceship [$1, $3]; } - | expr '<' expr { $$ = Expr\BinaryOp\Smaller [$1, $3]; } - | expr T_IS_SMALLER_OR_EQUAL expr { $$ = Expr\BinaryOp\SmallerOrEqual[$1, $3]; } - | expr '>' expr { $$ = Expr\BinaryOp\Greater [$1, $3]; } - | expr T_IS_GREATER_OR_EQUAL expr { $$ = Expr\BinaryOp\GreaterOrEqual[$1, $3]; } - | expr T_INSTANCEOF class_name_reference { $$ = Expr\Instanceof_[$1, $3]; } - | parentheses_expr { $$ = $1; } - /* we need a separate '(' new_expr ')' rule to avoid problems caused by a s/r conflict */ - | '(' new_expr ')' { $$ = $2; } - | expr '?' expr ':' expr { $$ = Expr\Ternary[$1, $3, $5]; } - | expr '?' ':' expr { $$ = Expr\Ternary[$1, null, $4]; } - | expr T_COALESCE expr { $$ = Expr\BinaryOp\Coalesce[$1, $3]; } - | T_ISSET '(' variables_list ')' { $$ = Expr\Isset_[$3]; } - | T_EMPTY '(' expr ')' { $$ = Expr\Empty_[$3]; } - | T_INCLUDE expr { $$ = Expr\Include_[$2, Expr\Include_::TYPE_INCLUDE]; } - | T_INCLUDE_ONCE expr { $$ = Expr\Include_[$2, Expr\Include_::TYPE_INCLUDE_ONCE]; } - | T_EVAL parentheses_expr { $$ = Expr\Eval_[$2]; } - | T_REQUIRE expr { $$ = Expr\Include_[$2, Expr\Include_::TYPE_REQUIRE]; } - | T_REQUIRE_ONCE expr { $$ = Expr\Include_[$2, Expr\Include_::TYPE_REQUIRE_ONCE]; } - | T_INT_CAST expr { $$ = Expr\Cast\Int_ [$2]; } - | T_DOUBLE_CAST expr - { $attrs = attributes(); - $attrs['kind'] = $this->getFloatCastKind($1); - $$ = new Expr\Cast\Double($2, $attrs); } - | T_STRING_CAST expr { $$ = Expr\Cast\String_ [$2]; } - | T_ARRAY_CAST expr { $$ = Expr\Cast\Array_ [$2]; } - | T_OBJECT_CAST expr { $$ = Expr\Cast\Object_ [$2]; } - | T_BOOL_CAST expr { $$ = Expr\Cast\Bool_ [$2]; } - | T_UNSET_CAST expr { $$ = Expr\Cast\Unset_ [$2]; } - | T_EXIT exit_expr - { $attrs = attributes(); - $attrs['kind'] = strtolower($1) === 'exit' ? Expr\Exit_::KIND_EXIT : Expr\Exit_::KIND_DIE; - $$ = new Expr\Exit_($2, $attrs); } - | '@' expr { $$ = Expr\ErrorSuppress[$2]; } - | scalar { $$ = $1; } - | array_expr { $$ = $1; } - | scalar_dereference { $$ = $1; } - | '`' backticks_expr '`' { $$ = Expr\ShellExec[$2]; } - | T_PRINT expr { $$ = Expr\Print_[$2]; } - | T_YIELD { $$ = Expr\Yield_[null, null]; } - | T_YIELD_FROM expr { $$ = Expr\YieldFrom[$2]; } - | T_FUNCTION optional_ref '(' parameter_list ')' lexical_vars optional_return_type - '{' inner_statement_list '}' - { $$ = Expr\Closure[['static' => false, 'byRef' => $2, 'params' => $4, 'uses' => $6, 'returnType' => $7, 'stmts' => $9]]; } - | T_STATIC T_FUNCTION optional_ref '(' parameter_list ')' lexical_vars optional_return_type - '{' inner_statement_list '}' - { $$ = Expr\Closure[['static' => true, 'byRef' => $3, 'params' => $5, 'uses' => $7, 'returnType' => $8, 'stmts' => $10]]; } -; - -parentheses_expr: - '(' expr ')' { $$ = $2; } - | '(' yield_expr ')' { $$ = $2; } -; - -yield_expr: - T_YIELD expr { $$ = Expr\Yield_[$2, null]; } - | T_YIELD expr T_DOUBLE_ARROW expr { $$ = Expr\Yield_[$4, $2]; } -; - -array_expr: - T_ARRAY '(' array_pair_list ')' - { $attrs = attributes(); $attrs['kind'] = Expr\Array_::KIND_LONG; - $$ = new Expr\Array_($3, $attrs); } - | '[' array_pair_list ']' - { $attrs = attributes(); $attrs['kind'] = Expr\Array_::KIND_SHORT; - $$ = new Expr\Array_($2, $attrs); } -; - -scalar_dereference: - array_expr '[' dim_offset ']' { $$ = Expr\ArrayDimFetch[$1, $3]; } - | T_CONSTANT_ENCAPSED_STRING '[' dim_offset ']' { $$ = Expr\ArrayDimFetch[Scalar\String_::fromString($1, attributes()), $3]; } - | constant '[' dim_offset ']' { $$ = Expr\ArrayDimFetch[$1, $3]; } - | scalar_dereference '[' dim_offset ']' { $$ = Expr\ArrayDimFetch[$1, $3]; } - /* alternative array syntax missing intentionally */ -; - -anonymous_class: - T_CLASS ctor_arguments extends_from implements_list '{' class_statement_list '}' - { $$ = array(Stmt\Class_[null, ['type' => 0, 'extends' => $3, 'implements' => $4, 'stmts' => $6]], $2); - $this->checkClass($$[0], -1); } -; - -new_expr: - T_NEW class_name_reference ctor_arguments { $$ = Expr\New_[$2, $3]; } - | T_NEW anonymous_class - { list($class, $ctorArgs) = $2; $$ = Expr\New_[$class, $ctorArgs]; } -; - -lexical_vars: - /* empty */ { $$ = array(); } - | T_USE '(' lexical_var_list ')' { $$ = $3; } -; - -lexical_var_list: - lexical_var { init($1); } - | lexical_var_list ',' lexical_var { push($1, $3); } -; - -lexical_var: - optional_ref plain_variable { $$ = Expr\ClosureUse[$2, $1]; } -; - -name_readonly: - T_READONLY { $$ = Name[$1]; } -; - -function_call: - name argument_list { $$ = Expr\FuncCall[$1, $2]; } - | name_readonly argument_list { $$ = Expr\FuncCall[$1, $2]; } - | class_name_or_var T_PAAMAYIM_NEKUDOTAYIM identifier_ex argument_list - { $$ = Expr\StaticCall[$1, $3, $4]; } - | class_name_or_var T_PAAMAYIM_NEKUDOTAYIM '{' expr '}' argument_list - { $$ = Expr\StaticCall[$1, $4, $6]; } - | static_property argument_list - { $$ = $this->fixupPhp5StaticPropCall($1, $2, attributes()); } - | variable_without_objects argument_list - { $$ = Expr\FuncCall[$1, $2]; } - | function_call '[' dim_offset ']' { $$ = Expr\ArrayDimFetch[$1, $3]; } - /* alternative array syntax missing intentionally */ -; - -class_name: - T_STATIC { $$ = Name[$1]; } - | name { $$ = $1; } -; - -name: - T_STRING { $$ = Name[$1]; } - | T_NAME_QUALIFIED { $$ = Name[$1]; } - | T_NAME_FULLY_QUALIFIED { $$ = Name\FullyQualified[substr($1, 1)]; } - | T_NAME_RELATIVE { $$ = Name\Relative[substr($1, 10)]; } -; - -class_name_reference: - class_name { $$ = $1; } - | dynamic_class_name_reference { $$ = $1; } -; - -dynamic_class_name_reference: - object_access_for_dcnr { $$ = $1; } - | base_variable { $$ = $1; } -; - -class_name_or_var: - class_name { $$ = $1; } - | reference_variable { $$ = $1; } -; - -object_access_for_dcnr: - base_variable T_OBJECT_OPERATOR object_property - { $$ = Expr\PropertyFetch[$1, $3]; } - | object_access_for_dcnr T_OBJECT_OPERATOR object_property - { $$ = Expr\PropertyFetch[$1, $3]; } - | object_access_for_dcnr '[' dim_offset ']' { $$ = Expr\ArrayDimFetch[$1, $3]; } - | object_access_for_dcnr '{' expr '}' { $$ = Expr\ArrayDimFetch[$1, $3]; } -; - -exit_expr: - /* empty */ { $$ = null; } - | '(' ')' { $$ = null; } - | parentheses_expr { $$ = $1; } -; - -backticks_expr: - /* empty */ { $$ = array(); } - | T_ENCAPSED_AND_WHITESPACE - { $$ = array(Scalar\EncapsedStringPart[Scalar\String_::parseEscapeSequences($1, '`', false)]); } - | encaps_list { parseEncapsed($1, '`', false); $$ = $1; } -; - -ctor_arguments: - /* empty */ { $$ = array(); } - | argument_list { $$ = $1; } -; - -common_scalar: - T_LNUMBER { $$ = $this->parseLNumber($1, attributes(), true); } - | T_DNUMBER { $$ = Scalar\DNumber::fromString($1, attributes()); } - | T_CONSTANT_ENCAPSED_STRING { $$ = Scalar\String_::fromString($1, attributes(), false); } - | T_LINE { $$ = Scalar\MagicConst\Line[]; } - | T_FILE { $$ = Scalar\MagicConst\File[]; } - | T_DIR { $$ = Scalar\MagicConst\Dir[]; } - | T_CLASS_C { $$ = Scalar\MagicConst\Class_[]; } - | T_TRAIT_C { $$ = Scalar\MagicConst\Trait_[]; } - | T_METHOD_C { $$ = Scalar\MagicConst\Method[]; } - | T_FUNC_C { $$ = Scalar\MagicConst\Function_[]; } - | T_NS_C { $$ = Scalar\MagicConst\Namespace_[]; } - | T_START_HEREDOC T_ENCAPSED_AND_WHITESPACE T_END_HEREDOC - { $$ = $this->parseDocString($1, $2, $3, attributes(), stackAttributes(#3), false); } - | T_START_HEREDOC T_END_HEREDOC - { $$ = $this->parseDocString($1, '', $2, attributes(), stackAttributes(#2), false); } -; - -static_scalar: - common_scalar { $$ = $1; } - | class_name T_PAAMAYIM_NEKUDOTAYIM identifier_ex { $$ = Expr\ClassConstFetch[$1, $3]; } - | name { $$ = Expr\ConstFetch[$1]; } - | T_ARRAY '(' static_array_pair_list ')' { $$ = Expr\Array_[$3]; } - | '[' static_array_pair_list ']' { $$ = Expr\Array_[$2]; } - | static_operation { $$ = $1; } -; - -static_operation: - static_scalar T_BOOLEAN_OR static_scalar { $$ = Expr\BinaryOp\BooleanOr [$1, $3]; } - | static_scalar T_BOOLEAN_AND static_scalar { $$ = Expr\BinaryOp\BooleanAnd[$1, $3]; } - | static_scalar T_LOGICAL_OR static_scalar { $$ = Expr\BinaryOp\LogicalOr [$1, $3]; } - | static_scalar T_LOGICAL_AND static_scalar { $$ = Expr\BinaryOp\LogicalAnd[$1, $3]; } - | static_scalar T_LOGICAL_XOR static_scalar { $$ = Expr\BinaryOp\LogicalXor[$1, $3]; } - | static_scalar '|' static_scalar { $$ = Expr\BinaryOp\BitwiseOr [$1, $3]; } - | static_scalar T_AMPERSAND_NOT_FOLLOWED_BY_VAR_OR_VARARG static_scalar - { $$ = Expr\BinaryOp\BitwiseAnd[$1, $3]; } - | static_scalar T_AMPERSAND_FOLLOWED_BY_VAR_OR_VARARG static_scalar - { $$ = Expr\BinaryOp\BitwiseAnd[$1, $3]; } - | static_scalar '^' static_scalar { $$ = Expr\BinaryOp\BitwiseXor[$1, $3]; } - | static_scalar '.' static_scalar { $$ = Expr\BinaryOp\Concat [$1, $3]; } - | static_scalar '+' static_scalar { $$ = Expr\BinaryOp\Plus [$1, $3]; } - | static_scalar '-' static_scalar { $$ = Expr\BinaryOp\Minus [$1, $3]; } - | static_scalar '*' static_scalar { $$ = Expr\BinaryOp\Mul [$1, $3]; } - | static_scalar '/' static_scalar { $$ = Expr\BinaryOp\Div [$1, $3]; } - | static_scalar '%' static_scalar { $$ = Expr\BinaryOp\Mod [$1, $3]; } - | static_scalar T_SL static_scalar { $$ = Expr\BinaryOp\ShiftLeft [$1, $3]; } - | static_scalar T_SR static_scalar { $$ = Expr\BinaryOp\ShiftRight[$1, $3]; } - | static_scalar T_POW static_scalar { $$ = Expr\BinaryOp\Pow [$1, $3]; } - | '+' static_scalar %prec T_INC { $$ = Expr\UnaryPlus [$2]; } - | '-' static_scalar %prec T_INC { $$ = Expr\UnaryMinus[$2]; } - | '!' static_scalar { $$ = Expr\BooleanNot[$2]; } - | '~' static_scalar { $$ = Expr\BitwiseNot[$2]; } - | static_scalar T_IS_IDENTICAL static_scalar { $$ = Expr\BinaryOp\Identical [$1, $3]; } - | static_scalar T_IS_NOT_IDENTICAL static_scalar { $$ = Expr\BinaryOp\NotIdentical [$1, $3]; } - | static_scalar T_IS_EQUAL static_scalar { $$ = Expr\BinaryOp\Equal [$1, $3]; } - | static_scalar T_IS_NOT_EQUAL static_scalar { $$ = Expr\BinaryOp\NotEqual [$1, $3]; } - | static_scalar '<' static_scalar { $$ = Expr\BinaryOp\Smaller [$1, $3]; } - | static_scalar T_IS_SMALLER_OR_EQUAL static_scalar { $$ = Expr\BinaryOp\SmallerOrEqual[$1, $3]; } - | static_scalar '>' static_scalar { $$ = Expr\BinaryOp\Greater [$1, $3]; } - | static_scalar T_IS_GREATER_OR_EQUAL static_scalar { $$ = Expr\BinaryOp\GreaterOrEqual[$1, $3]; } - | static_scalar '?' static_scalar ':' static_scalar { $$ = Expr\Ternary[$1, $3, $5]; } - | static_scalar '?' ':' static_scalar { $$ = Expr\Ternary[$1, null, $4]; } - | static_scalar '[' static_scalar ']' { $$ = Expr\ArrayDimFetch[$1, $3]; } - | '(' static_scalar ')' { $$ = $2; } -; - -constant: - name { $$ = Expr\ConstFetch[$1]; } - | class_name_or_var T_PAAMAYIM_NEKUDOTAYIM identifier_ex - { $$ = Expr\ClassConstFetch[$1, $3]; } -; - -scalar: - common_scalar { $$ = $1; } - | constant { $$ = $1; } - | '"' encaps_list '"' - { $attrs = attributes(); $attrs['kind'] = Scalar\String_::KIND_DOUBLE_QUOTED; - parseEncapsed($2, '"', true); $$ = new Scalar\Encapsed($2, $attrs); } - | T_START_HEREDOC encaps_list T_END_HEREDOC - { $$ = $this->parseDocString($1, $2, $3, attributes(), stackAttributes(#3), true); } -; - -static_array_pair_list: - /* empty */ { $$ = array(); } - | non_empty_static_array_pair_list optional_comma { $$ = $1; } -; - -optional_comma: - /* empty */ - | ',' -; - -non_empty_static_array_pair_list: - non_empty_static_array_pair_list ',' static_array_pair { push($1, $3); } - | static_array_pair { init($1); } -; - -static_array_pair: - static_scalar T_DOUBLE_ARROW static_scalar { $$ = Expr\ArrayItem[$3, $1, false]; } - | static_scalar { $$ = Expr\ArrayItem[$1, null, false]; } -; - -variable: - object_access { $$ = $1; } - | base_variable { $$ = $1; } - | function_call { $$ = $1; } - | new_expr_array_deref { $$ = $1; } -; - -new_expr_array_deref: - '(' new_expr ')' '[' dim_offset ']' { $$ = Expr\ArrayDimFetch[$2, $5]; } - | new_expr_array_deref '[' dim_offset ']' { $$ = Expr\ArrayDimFetch[$1, $3]; } - /* alternative array syntax missing intentionally */ -; - -object_access: - variable_or_new_expr T_OBJECT_OPERATOR object_property - { $$ = Expr\PropertyFetch[$1, $3]; } - | variable_or_new_expr T_OBJECT_OPERATOR object_property argument_list - { $$ = Expr\MethodCall[$1, $3, $4]; } - | object_access argument_list { $$ = Expr\FuncCall[$1, $2]; } - | object_access '[' dim_offset ']' { $$ = Expr\ArrayDimFetch[$1, $3]; } - | object_access '{' expr '}' { $$ = Expr\ArrayDimFetch[$1, $3]; } -; - -variable_or_new_expr: - variable { $$ = $1; } - | '(' new_expr ')' { $$ = $2; } -; - -variable_without_objects: - reference_variable { $$ = $1; } - | '$' variable_without_objects { $$ = Expr\Variable[$2]; } -; - -base_variable: - variable_without_objects { $$ = $1; } - | static_property { $$ = $1; } -; - -static_property: - class_name_or_var T_PAAMAYIM_NEKUDOTAYIM '$' reference_variable - { $$ = Expr\StaticPropertyFetch[$1, $4]; } - | static_property_with_arrays { $$ = $1; } -; - -static_property_simple_name: - T_VARIABLE - { $var = parseVar($1); $$ = \is_string($var) ? Node\VarLikeIdentifier[$var] : $var; } -; - -static_property_with_arrays: - class_name_or_var T_PAAMAYIM_NEKUDOTAYIM static_property_simple_name - { $$ = Expr\StaticPropertyFetch[$1, $3]; } - | class_name_or_var T_PAAMAYIM_NEKUDOTAYIM '$' '{' expr '}' - { $$ = Expr\StaticPropertyFetch[$1, $5]; } - | static_property_with_arrays '[' dim_offset ']' { $$ = Expr\ArrayDimFetch[$1, $3]; } - | static_property_with_arrays '{' expr '}' { $$ = Expr\ArrayDimFetch[$1, $3]; } -; - -reference_variable: - reference_variable '[' dim_offset ']' { $$ = Expr\ArrayDimFetch[$1, $3]; } - | reference_variable '{' expr '}' { $$ = Expr\ArrayDimFetch[$1, $3]; } - | plain_variable { $$ = $1; } - | '$' '{' expr '}' { $$ = Expr\Variable[$3]; } -; - -dim_offset: - /* empty */ { $$ = null; } - | expr { $$ = $1; } -; - -object_property: - identifier { $$ = $1; } - | '{' expr '}' { $$ = $2; } - | variable_without_objects { $$ = $1; } - | error { $$ = Expr\Error[]; $this->errorState = 2; } -; - -list_expr: - T_LIST '(' list_expr_elements ')' { $$ = Expr\List_[$3]; } -; - -list_expr_elements: - list_expr_elements ',' list_expr_element { push($1, $3); } - | list_expr_element { init($1); } -; - -list_expr_element: - variable { $$ = Expr\ArrayItem[$1, null, false]; } - | list_expr { $$ = Expr\ArrayItem[$1, null, false]; } - | /* empty */ { $$ = null; } -; - -array_pair_list: - /* empty */ { $$ = array(); } - | non_empty_array_pair_list optional_comma { $$ = $1; } -; - -non_empty_array_pair_list: - non_empty_array_pair_list ',' array_pair { push($1, $3); } - | array_pair { init($1); } -; - -array_pair: - expr T_DOUBLE_ARROW expr { $$ = Expr\ArrayItem[$3, $1, false]; } - | expr { $$ = Expr\ArrayItem[$1, null, false]; } - | expr T_DOUBLE_ARROW ampersand variable { $$ = Expr\ArrayItem[$4, $1, true]; } - | ampersand variable { $$ = Expr\ArrayItem[$2, null, true]; } - | T_ELLIPSIS expr { $$ = new Expr\ArrayItem($2, null, false, attributes(), true); } -; - -encaps_list: - encaps_list encaps_var { push($1, $2); } - | encaps_list encaps_string_part { push($1, $2); } - | encaps_var { init($1); } - | encaps_string_part encaps_var { init($1, $2); } -; - -encaps_string_part: - T_ENCAPSED_AND_WHITESPACE { $$ = Scalar\EncapsedStringPart[$1]; } -; - -encaps_str_varname: - T_STRING_VARNAME { $$ = Expr\Variable[$1]; } -; - -encaps_var: - plain_variable { $$ = $1; } - | plain_variable '[' encaps_var_offset ']' { $$ = Expr\ArrayDimFetch[$1, $3]; } - | plain_variable T_OBJECT_OPERATOR identifier { $$ = Expr\PropertyFetch[$1, $3]; } - | T_DOLLAR_OPEN_CURLY_BRACES expr '}' { $$ = Expr\Variable[$2]; } - | T_DOLLAR_OPEN_CURLY_BRACES T_STRING_VARNAME '}' { $$ = Expr\Variable[$2]; } - | T_DOLLAR_OPEN_CURLY_BRACES encaps_str_varname '[' expr ']' '}' - { $$ = Expr\ArrayDimFetch[$2, $4]; } - | T_CURLY_OPEN variable '}' { $$ = $2; } -; - -encaps_var_offset: - T_STRING { $$ = Scalar\String_[$1]; } - | T_NUM_STRING { $$ = $this->parseNumString($1, attributes()); } - | plain_variable { $$ = $1; } -; - -%% diff --git a/vendor/nikic/php-parser/grammar/php7.y b/vendor/nikic/php-parser/grammar/php7.y deleted file mode 100644 index 1ef60bfe..00000000 --- a/vendor/nikic/php-parser/grammar/php7.y +++ /dev/null @@ -1,1245 +0,0 @@ -%pure_parser -%expect 2 - -%tokens - -%% - -start: - top_statement_list { $$ = $this->handleNamespaces($1); } -; - -top_statement_list_ex: - top_statement_list_ex top_statement { pushNormalizing($1, $2); } - | /* empty */ { init(); } -; - -top_statement_list: - top_statement_list_ex - { makeZeroLengthNop($nop, $this->lookaheadStartAttributes); - if ($nop !== null) { $1[] = $nop; } $$ = $1; } -; - -ampersand: - T_AMPERSAND_FOLLOWED_BY_VAR_OR_VARARG - | T_AMPERSAND_NOT_FOLLOWED_BY_VAR_OR_VARARG -; - -reserved_non_modifiers: - T_INCLUDE | T_INCLUDE_ONCE | T_EVAL | T_REQUIRE | T_REQUIRE_ONCE | T_LOGICAL_OR | T_LOGICAL_XOR | T_LOGICAL_AND - | T_INSTANCEOF | T_NEW | T_CLONE | T_EXIT | T_IF | T_ELSEIF | T_ELSE | T_ENDIF | T_ECHO | T_DO | T_WHILE - | T_ENDWHILE | T_FOR | T_ENDFOR | T_FOREACH | T_ENDFOREACH | T_DECLARE | T_ENDDECLARE | T_AS | T_TRY | T_CATCH - | T_FINALLY | T_THROW | T_USE | T_INSTEADOF | T_GLOBAL | T_VAR | T_UNSET | T_ISSET | T_EMPTY | T_CONTINUE | T_GOTO - | T_FUNCTION | T_CONST | T_RETURN | T_PRINT | T_YIELD | T_LIST | T_SWITCH | T_ENDSWITCH | T_CASE | T_DEFAULT - | T_BREAK | T_ARRAY | T_CALLABLE | T_EXTENDS | T_IMPLEMENTS | T_NAMESPACE | T_TRAIT | T_INTERFACE | T_CLASS - | T_CLASS_C | T_TRAIT_C | T_FUNC_C | T_METHOD_C | T_LINE | T_FILE | T_DIR | T_NS_C | T_HALT_COMPILER | T_FN - | T_MATCH | T_ENUM -; - -semi_reserved: - reserved_non_modifiers - | T_STATIC | T_ABSTRACT | T_FINAL | T_PRIVATE | T_PROTECTED | T_PUBLIC | T_READONLY -; - -identifier_maybe_reserved: - T_STRING { $$ = Node\Identifier[$1]; } - | semi_reserved { $$ = Node\Identifier[$1]; } -; - -identifier_not_reserved: - T_STRING { $$ = Node\Identifier[$1]; } -; - -reserved_non_modifiers_identifier: - reserved_non_modifiers { $$ = Node\Identifier[$1]; } -; - -namespace_declaration_name: - T_STRING { $$ = Name[$1]; } - | semi_reserved { $$ = Name[$1]; } - | T_NAME_QUALIFIED { $$ = Name[$1]; } -; - -namespace_name: - T_STRING { $$ = Name[$1]; } - | T_NAME_QUALIFIED { $$ = Name[$1]; } -; - -legacy_namespace_name: - namespace_name { $$ = $1; } - | T_NAME_FULLY_QUALIFIED { $$ = Name[substr($1, 1)]; } -; - -plain_variable: - T_VARIABLE { $$ = Expr\Variable[parseVar($1)]; } -; - -semi: - ';' { /* nothing */ } - | error { /* nothing */ } -; - -no_comma: - /* empty */ { /* nothing */ } - | ',' { $this->emitError(new Error('A trailing comma is not allowed here', attributes())); } -; - -optional_comma: - /* empty */ - | ',' -; - -attribute_decl: - class_name { $$ = Node\Attribute[$1, []]; } - | class_name argument_list { $$ = Node\Attribute[$1, $2]; } -; - -attribute_group: - attribute_decl { init($1); } - | attribute_group ',' attribute_decl { push($1, $3); } -; - -attribute: - T_ATTRIBUTE attribute_group optional_comma ']' { $$ = Node\AttributeGroup[$2]; } -; - -attributes: - attribute { init($1); } - | attributes attribute { push($1, $2); } -; - -optional_attributes: - /* empty */ { $$ = []; } - | attributes { $$ = $1; } -; - -top_statement: - statement { $$ = $1; } - | function_declaration_statement { $$ = $1; } - | class_declaration_statement { $$ = $1; } - | T_HALT_COMPILER - { $$ = Stmt\HaltCompiler[$this->lexer->handleHaltCompiler()]; } - | T_NAMESPACE namespace_declaration_name semi - { $$ = Stmt\Namespace_[$2, null]; - $$->setAttribute('kind', Stmt\Namespace_::KIND_SEMICOLON); - $this->checkNamespace($$); } - | T_NAMESPACE namespace_declaration_name '{' top_statement_list '}' - { $$ = Stmt\Namespace_[$2, $4]; - $$->setAttribute('kind', Stmt\Namespace_::KIND_BRACED); - $this->checkNamespace($$); } - | T_NAMESPACE '{' top_statement_list '}' - { $$ = Stmt\Namespace_[null, $3]; - $$->setAttribute('kind', Stmt\Namespace_::KIND_BRACED); - $this->checkNamespace($$); } - | T_USE use_declarations semi { $$ = Stmt\Use_[$2, Stmt\Use_::TYPE_NORMAL]; } - | T_USE use_type use_declarations semi { $$ = Stmt\Use_[$3, $2]; } - | group_use_declaration semi { $$ = $1; } - | T_CONST constant_declaration_list semi { $$ = Stmt\Const_[$2]; } -; - -use_type: - T_FUNCTION { $$ = Stmt\Use_::TYPE_FUNCTION; } - | T_CONST { $$ = Stmt\Use_::TYPE_CONSTANT; } -; - -group_use_declaration: - T_USE use_type legacy_namespace_name T_NS_SEPARATOR '{' unprefixed_use_declarations '}' - { $$ = Stmt\GroupUse[$3, $6, $2]; } - | T_USE legacy_namespace_name T_NS_SEPARATOR '{' inline_use_declarations '}' - { $$ = Stmt\GroupUse[$2, $5, Stmt\Use_::TYPE_UNKNOWN]; } -; - -unprefixed_use_declarations: - non_empty_unprefixed_use_declarations optional_comma { $$ = $1; } -; - -non_empty_unprefixed_use_declarations: - non_empty_unprefixed_use_declarations ',' unprefixed_use_declaration - { push($1, $3); } - | unprefixed_use_declaration { init($1); } -; - -use_declarations: - non_empty_use_declarations no_comma { $$ = $1; } -; - -non_empty_use_declarations: - non_empty_use_declarations ',' use_declaration { push($1, $3); } - | use_declaration { init($1); } -; - -inline_use_declarations: - non_empty_inline_use_declarations optional_comma { $$ = $1; } -; - -non_empty_inline_use_declarations: - non_empty_inline_use_declarations ',' inline_use_declaration - { push($1, $3); } - | inline_use_declaration { init($1); } -; - -unprefixed_use_declaration: - namespace_name - { $$ = Stmt\UseUse[$1, null, Stmt\Use_::TYPE_UNKNOWN]; $this->checkUseUse($$, #1); } - | namespace_name T_AS identifier_not_reserved - { $$ = Stmt\UseUse[$1, $3, Stmt\Use_::TYPE_UNKNOWN]; $this->checkUseUse($$, #3); } -; - -use_declaration: - legacy_namespace_name - { $$ = Stmt\UseUse[$1, null, Stmt\Use_::TYPE_UNKNOWN]; $this->checkUseUse($$, #1); } - | legacy_namespace_name T_AS identifier_not_reserved - { $$ = Stmt\UseUse[$1, $3, Stmt\Use_::TYPE_UNKNOWN]; $this->checkUseUse($$, #3); } -; - -inline_use_declaration: - unprefixed_use_declaration { $$ = $1; $$->type = Stmt\Use_::TYPE_NORMAL; } - | use_type unprefixed_use_declaration { $$ = $2; $$->type = $1; } -; - -constant_declaration_list: - non_empty_constant_declaration_list no_comma { $$ = $1; } -; - -non_empty_constant_declaration_list: - non_empty_constant_declaration_list ',' constant_declaration - { push($1, $3); } - | constant_declaration { init($1); } -; - -constant_declaration: - identifier_not_reserved '=' expr { $$ = Node\Const_[$1, $3]; } -; - -class_const_list: - non_empty_class_const_list no_comma { $$ = $1; } -; - -non_empty_class_const_list: - non_empty_class_const_list ',' class_const { push($1, $3); } - | class_const { init($1); } -; - -class_const: - T_STRING '=' expr - { $$ = Node\Const_[new Node\Identifier($1, stackAttributes(#1)), $3]; } - | semi_reserved '=' expr - { $$ = Node\Const_[new Node\Identifier($1, stackAttributes(#1)), $3]; } -; - -inner_statement_list_ex: - inner_statement_list_ex inner_statement { pushNormalizing($1, $2); } - | /* empty */ { init(); } -; - -inner_statement_list: - inner_statement_list_ex - { makeZeroLengthNop($nop, $this->lookaheadStartAttributes); - if ($nop !== null) { $1[] = $nop; } $$ = $1; } -; - -inner_statement: - statement { $$ = $1; } - | function_declaration_statement { $$ = $1; } - | class_declaration_statement { $$ = $1; } - | T_HALT_COMPILER - { throw new Error('__HALT_COMPILER() can only be used from the outermost scope', attributes()); } -; - -non_empty_statement: - '{' inner_statement_list '}' - { - if ($2) { - $$ = $2; prependLeadingComments($$); - } else { - makeNop($$, $this->startAttributeStack[#1], $this->endAttributes); - if (null === $$) { $$ = array(); } - } - } - | T_IF '(' expr ')' statement elseif_list else_single - { $$ = Stmt\If_[$3, ['stmts' => toArray($5), 'elseifs' => $6, 'else' => $7]]; } - | T_IF '(' expr ')' ':' inner_statement_list new_elseif_list new_else_single T_ENDIF ';' - { $$ = Stmt\If_[$3, ['stmts' => $6, 'elseifs' => $7, 'else' => $8]]; } - | T_WHILE '(' expr ')' while_statement { $$ = Stmt\While_[$3, $5]; } - | T_DO statement T_WHILE '(' expr ')' ';' { $$ = Stmt\Do_ [$5, toArray($2)]; } - | T_FOR '(' for_expr ';' for_expr ';' for_expr ')' for_statement - { $$ = Stmt\For_[['init' => $3, 'cond' => $5, 'loop' => $7, 'stmts' => $9]]; } - | T_SWITCH '(' expr ')' switch_case_list { $$ = Stmt\Switch_[$3, $5]; } - | T_BREAK optional_expr semi { $$ = Stmt\Break_[$2]; } - | T_CONTINUE optional_expr semi { $$ = Stmt\Continue_[$2]; } - | T_RETURN optional_expr semi { $$ = Stmt\Return_[$2]; } - | T_GLOBAL global_var_list semi { $$ = Stmt\Global_[$2]; } - | T_STATIC static_var_list semi { $$ = Stmt\Static_[$2]; } - | T_ECHO expr_list_forbid_comma semi { $$ = Stmt\Echo_[$2]; } - | T_INLINE_HTML { $$ = Stmt\InlineHTML[$1]; } - | expr semi { - $e = $1; - if ($e instanceof Expr\Throw_) { - // For backwards-compatibility reasons, convert throw in statement position into - // Stmt\Throw_ rather than Stmt\Expression(Expr\Throw_). - $$ = Stmt\Throw_[$e->expr]; - } else { - $$ = Stmt\Expression[$e]; - } - } - | T_UNSET '(' variables_list ')' semi { $$ = Stmt\Unset_[$3]; } - | T_FOREACH '(' expr T_AS foreach_variable ')' foreach_statement - { $$ = Stmt\Foreach_[$3, $5[0], ['keyVar' => null, 'byRef' => $5[1], 'stmts' => $7]]; } - | T_FOREACH '(' expr T_AS variable T_DOUBLE_ARROW foreach_variable ')' foreach_statement - { $$ = Stmt\Foreach_[$3, $7[0], ['keyVar' => $5, 'byRef' => $7[1], 'stmts' => $9]]; } - | T_FOREACH '(' expr error ')' foreach_statement - { $$ = Stmt\Foreach_[$3, new Expr\Error(stackAttributes(#4)), ['stmts' => $6]]; } - | T_DECLARE '(' declare_list ')' declare_statement { $$ = Stmt\Declare_[$3, $5]; } - | T_TRY '{' inner_statement_list '}' catches optional_finally - { $$ = Stmt\TryCatch[$3, $5, $6]; $this->checkTryCatch($$); } - | T_GOTO identifier_not_reserved semi { $$ = Stmt\Goto_[$2]; } - | identifier_not_reserved ':' { $$ = Stmt\Label[$1]; } - | error { $$ = array(); /* means: no statement */ } -; - -statement: - non_empty_statement { $$ = $1; } - | ';' - { makeNop($$, $this->startAttributeStack[#1], $this->endAttributes); - if ($$ === null) $$ = array(); /* means: no statement */ } -; - -catches: - /* empty */ { init(); } - | catches catch { push($1, $2); } -; - -name_union: - name { init($1); } - | name_union '|' name { push($1, $3); } -; - -catch: - T_CATCH '(' name_union optional_plain_variable ')' '{' inner_statement_list '}' - { $$ = Stmt\Catch_[$3, $4, $7]; } -; - -optional_finally: - /* empty */ { $$ = null; } - | T_FINALLY '{' inner_statement_list '}' { $$ = Stmt\Finally_[$3]; } -; - -variables_list: - non_empty_variables_list optional_comma { $$ = $1; } -; - -non_empty_variables_list: - variable { init($1); } - | non_empty_variables_list ',' variable { push($1, $3); } -; - -optional_ref: - /* empty */ { $$ = false; } - | ampersand { $$ = true; } -; - -optional_arg_ref: - /* empty */ { $$ = false; } - | T_AMPERSAND_FOLLOWED_BY_VAR_OR_VARARG { $$ = true; } -; - -optional_ellipsis: - /* empty */ { $$ = false; } - | T_ELLIPSIS { $$ = true; } -; - -block_or_error: - '{' inner_statement_list '}' { $$ = $2; } - | error { $$ = []; } -; - -identifier_maybe_readonly: - identifier_not_reserved { $$ = $1; } - | T_READONLY { $$ = Node\Identifier[$1]; } -; - -function_declaration_statement: - T_FUNCTION optional_ref identifier_maybe_readonly '(' parameter_list ')' optional_return_type block_or_error - { $$ = Stmt\Function_[$3, ['byRef' => $2, 'params' => $5, 'returnType' => $7, 'stmts' => $8, 'attrGroups' => []]]; } - | attributes T_FUNCTION optional_ref identifier_maybe_readonly '(' parameter_list ')' optional_return_type block_or_error - { $$ = Stmt\Function_[$4, ['byRef' => $3, 'params' => $6, 'returnType' => $8, 'stmts' => $9, 'attrGroups' => $1]]; } -; - -class_declaration_statement: - class_entry_type identifier_not_reserved extends_from implements_list '{' class_statement_list '}' - { $$ = Stmt\Class_[$2, ['type' => $1, 'extends' => $3, 'implements' => $4, 'stmts' => $6, 'attrGroups' => []]]; - $this->checkClass($$, #2); } - | attributes class_entry_type identifier_not_reserved extends_from implements_list '{' class_statement_list '}' - { $$ = Stmt\Class_[$3, ['type' => $2, 'extends' => $4, 'implements' => $5, 'stmts' => $7, 'attrGroups' => $1]]; - $this->checkClass($$, #3); } - | optional_attributes T_INTERFACE identifier_not_reserved interface_extends_list '{' class_statement_list '}' - { $$ = Stmt\Interface_[$3, ['extends' => $4, 'stmts' => $6, 'attrGroups' => $1]]; - $this->checkInterface($$, #3); } - | optional_attributes T_TRAIT identifier_not_reserved '{' class_statement_list '}' - { $$ = Stmt\Trait_[$3, ['stmts' => $5, 'attrGroups' => $1]]; } - | optional_attributes T_ENUM identifier_not_reserved enum_scalar_type implements_list '{' class_statement_list '}' - { $$ = Stmt\Enum_[$3, ['scalarType' => $4, 'implements' => $5, 'stmts' => $7, 'attrGroups' => $1]]; - $this->checkEnum($$, #3); } -; - -enum_scalar_type: - /* empty */ { $$ = null; } - | ':' type { $$ = $2; } - -enum_case_expr: - /* empty */ { $$ = null; } - | '=' expr { $$ = $2; } -; - -class_entry_type: - T_CLASS { $$ = 0; } - | class_modifiers T_CLASS { $$ = $1; } -; - -class_modifiers: - class_modifier { $$ = $1; } - | class_modifiers class_modifier { $this->checkClassModifier($1, $2, #2); $$ = $1 | $2; } -; - -class_modifier: - T_ABSTRACT { $$ = Stmt\Class_::MODIFIER_ABSTRACT; } - | T_FINAL { $$ = Stmt\Class_::MODIFIER_FINAL; } - | T_READONLY { $$ = Stmt\Class_::MODIFIER_READONLY; } -; - -extends_from: - /* empty */ { $$ = null; } - | T_EXTENDS class_name { $$ = $2; } -; - -interface_extends_list: - /* empty */ { $$ = array(); } - | T_EXTENDS class_name_list { $$ = $2; } -; - -implements_list: - /* empty */ { $$ = array(); } - | T_IMPLEMENTS class_name_list { $$ = $2; } -; - -class_name_list: - non_empty_class_name_list no_comma { $$ = $1; } -; - -non_empty_class_name_list: - class_name { init($1); } - | non_empty_class_name_list ',' class_name { push($1, $3); } -; - -for_statement: - statement { $$ = toArray($1); } - | ':' inner_statement_list T_ENDFOR ';' { $$ = $2; } -; - -foreach_statement: - statement { $$ = toArray($1); } - | ':' inner_statement_list T_ENDFOREACH ';' { $$ = $2; } -; - -declare_statement: - non_empty_statement { $$ = toArray($1); } - | ';' { $$ = null; } - | ':' inner_statement_list T_ENDDECLARE ';' { $$ = $2; } -; - -declare_list: - non_empty_declare_list no_comma { $$ = $1; } -; - -non_empty_declare_list: - declare_list_element { init($1); } - | non_empty_declare_list ',' declare_list_element { push($1, $3); } -; - -declare_list_element: - identifier_not_reserved '=' expr { $$ = Stmt\DeclareDeclare[$1, $3]; } -; - -switch_case_list: - '{' case_list '}' { $$ = $2; } - | '{' ';' case_list '}' { $$ = $3; } - | ':' case_list T_ENDSWITCH ';' { $$ = $2; } - | ':' ';' case_list T_ENDSWITCH ';' { $$ = $3; } -; - -case_list: - /* empty */ { init(); } - | case_list case { push($1, $2); } -; - -case: - T_CASE expr case_separator inner_statement_list_ex { $$ = Stmt\Case_[$2, $4]; } - | T_DEFAULT case_separator inner_statement_list_ex { $$ = Stmt\Case_[null, $3]; } -; - -case_separator: - ':' - | ';' -; - -match: - T_MATCH '(' expr ')' '{' match_arm_list '}' { $$ = Expr\Match_[$3, $6]; } -; - -match_arm_list: - /* empty */ { $$ = []; } - | non_empty_match_arm_list optional_comma { $$ = $1; } -; - -non_empty_match_arm_list: - match_arm { init($1); } - | non_empty_match_arm_list ',' match_arm { push($1, $3); } -; - -match_arm: - expr_list_allow_comma T_DOUBLE_ARROW expr { $$ = Node\MatchArm[$1, $3]; } - | T_DEFAULT optional_comma T_DOUBLE_ARROW expr { $$ = Node\MatchArm[null, $4]; } -; - -while_statement: - statement { $$ = toArray($1); } - | ':' inner_statement_list T_ENDWHILE ';' { $$ = $2; } -; - -elseif_list: - /* empty */ { init(); } - | elseif_list elseif { push($1, $2); } -; - -elseif: - T_ELSEIF '(' expr ')' statement { $$ = Stmt\ElseIf_[$3, toArray($5)]; } -; - -new_elseif_list: - /* empty */ { init(); } - | new_elseif_list new_elseif { push($1, $2); } -; - -new_elseif: - T_ELSEIF '(' expr ')' ':' inner_statement_list - { $$ = Stmt\ElseIf_[$3, $6]; $this->fixupAlternativeElse($$); } -; - -else_single: - /* empty */ { $$ = null; } - | T_ELSE statement { $$ = Stmt\Else_[toArray($2)]; } -; - -new_else_single: - /* empty */ { $$ = null; } - | T_ELSE ':' inner_statement_list - { $$ = Stmt\Else_[$3]; $this->fixupAlternativeElse($$); } -; - -foreach_variable: - variable { $$ = array($1, false); } - | ampersand variable { $$ = array($2, true); } - | list_expr { $$ = array($1, false); } - | array_short_syntax { $$ = array($1, false); } -; - -parameter_list: - non_empty_parameter_list optional_comma { $$ = $1; } - | /* empty */ { $$ = array(); } -; - -non_empty_parameter_list: - parameter { init($1); } - | non_empty_parameter_list ',' parameter { push($1, $3); } -; - -optional_property_modifiers: - /* empty */ { $$ = 0; } - | optional_property_modifiers property_modifier - { $this->checkModifier($1, $2, #2); $$ = $1 | $2; } -; - -property_modifier: - T_PUBLIC { $$ = Stmt\Class_::MODIFIER_PUBLIC; } - | T_PROTECTED { $$ = Stmt\Class_::MODIFIER_PROTECTED; } - | T_PRIVATE { $$ = Stmt\Class_::MODIFIER_PRIVATE; } - | T_READONLY { $$ = Stmt\Class_::MODIFIER_READONLY; } -; - -parameter: - optional_attributes optional_property_modifiers optional_type_without_static - optional_arg_ref optional_ellipsis plain_variable - { $$ = new Node\Param($6, null, $3, $4, $5, attributes(), $2, $1); - $this->checkParam($$); } - | optional_attributes optional_property_modifiers optional_type_without_static - optional_arg_ref optional_ellipsis plain_variable '=' expr - { $$ = new Node\Param($6, $8, $3, $4, $5, attributes(), $2, $1); - $this->checkParam($$); } - | optional_attributes optional_property_modifiers optional_type_without_static - optional_arg_ref optional_ellipsis error - { $$ = new Node\Param(Expr\Error[], null, $3, $4, $5, attributes(), $2, $1); } -; - -type_expr: - type { $$ = $1; } - | '?' type { $$ = Node\NullableType[$2]; } - | union_type { $$ = Node\UnionType[$1]; } - | intersection_type { $$ = $1; } -; - -type: - type_without_static { $$ = $1; } - | T_STATIC { $$ = Node\Name['static']; } -; - -type_without_static: - name { $$ = $this->handleBuiltinTypes($1); } - | T_ARRAY { $$ = Node\Identifier['array']; } - | T_CALLABLE { $$ = Node\Identifier['callable']; } -; - -union_type_element: - type { $$ = $1; } - | '(' intersection_type ')' { $$ = $2; } -; - -union_type: - union_type_element '|' union_type_element { init($1, $3); } - | union_type '|' union_type_element { push($1, $3); } -; - -union_type_without_static_element: - type_without_static { $$ = $1; } - | '(' intersection_type_without_static ')' { $$ = $2; } -; - -union_type_without_static: - union_type_without_static_element '|' union_type_without_static_element { init($1, $3); } - | union_type_without_static '|' union_type_without_static_element { push($1, $3); } -; - -intersection_type_list: - type T_AMPERSAND_NOT_FOLLOWED_BY_VAR_OR_VARARG type { init($1, $3); } - | intersection_type_list T_AMPERSAND_NOT_FOLLOWED_BY_VAR_OR_VARARG type - { push($1, $3); } -; - -intersection_type: - intersection_type_list { $$ = Node\IntersectionType[$1]; } -; - -intersection_type_without_static_list: - type_without_static T_AMPERSAND_NOT_FOLLOWED_BY_VAR_OR_VARARG type_without_static - { init($1, $3); } - | intersection_type_without_static_list T_AMPERSAND_NOT_FOLLOWED_BY_VAR_OR_VARARG type_without_static - { push($1, $3); } -; - -intersection_type_without_static: - intersection_type_without_static_list { $$ = Node\IntersectionType[$1]; } -; - -type_expr_without_static: - type_without_static { $$ = $1; } - | '?' type_without_static { $$ = Node\NullableType[$2]; } - | union_type_without_static { $$ = Node\UnionType[$1]; } - | intersection_type_without_static { $$ = $1; } -; - -optional_type_without_static: - /* empty */ { $$ = null; } - | type_expr_without_static { $$ = $1; } -; - -optional_return_type: - /* empty */ { $$ = null; } - | ':' type_expr { $$ = $2; } - | ':' error { $$ = null; } -; - -argument_list: - '(' ')' { $$ = array(); } - | '(' non_empty_argument_list optional_comma ')' { $$ = $2; } - | '(' variadic_placeholder ')' { init($2); } -; - -variadic_placeholder: - T_ELLIPSIS { $$ = Node\VariadicPlaceholder[]; } -; - -non_empty_argument_list: - argument { init($1); } - | non_empty_argument_list ',' argument { push($1, $3); } -; - -argument: - expr { $$ = Node\Arg[$1, false, false]; } - | ampersand variable { $$ = Node\Arg[$2, true, false]; } - | T_ELLIPSIS expr { $$ = Node\Arg[$2, false, true]; } - | identifier_maybe_reserved ':' expr - { $$ = new Node\Arg($3, false, false, attributes(), $1); } -; - -global_var_list: - non_empty_global_var_list no_comma { $$ = $1; } -; - -non_empty_global_var_list: - non_empty_global_var_list ',' global_var { push($1, $3); } - | global_var { init($1); } -; - -global_var: - simple_variable { $$ = $1; } -; - -static_var_list: - non_empty_static_var_list no_comma { $$ = $1; } -; - -non_empty_static_var_list: - non_empty_static_var_list ',' static_var { push($1, $3); } - | static_var { init($1); } -; - -static_var: - plain_variable { $$ = Stmt\StaticVar[$1, null]; } - | plain_variable '=' expr { $$ = Stmt\StaticVar[$1, $3]; } -; - -class_statement_list_ex: - class_statement_list_ex class_statement { if ($2 !== null) { push($1, $2); } } - | /* empty */ { init(); } -; - -class_statement_list: - class_statement_list_ex - { makeZeroLengthNop($nop, $this->lookaheadStartAttributes); - if ($nop !== null) { $1[] = $nop; } $$ = $1; } -; - -class_statement: - optional_attributes variable_modifiers optional_type_without_static property_declaration_list semi - { $$ = new Stmt\Property($2, $4, attributes(), $3, $1); - $this->checkProperty($$, #2); } - | optional_attributes method_modifiers T_CONST class_const_list semi - { $$ = new Stmt\ClassConst($4, $2, attributes(), $1); - $this->checkClassConst($$, #2); } - | optional_attributes method_modifiers T_CONST type_expr class_const_list semi - { $$ = new Stmt\ClassConst($5, $2, attributes(), $1, $4); - $this->checkClassConst($$, #2); } - | optional_attributes method_modifiers T_FUNCTION optional_ref identifier_maybe_reserved '(' parameter_list ')' - optional_return_type method_body - { $$ = Stmt\ClassMethod[$5, ['type' => $2, 'byRef' => $4, 'params' => $7, 'returnType' => $9, 'stmts' => $10, 'attrGroups' => $1]]; - $this->checkClassMethod($$, #2); } - | T_USE class_name_list trait_adaptations { $$ = Stmt\TraitUse[$2, $3]; } - | optional_attributes T_CASE identifier_maybe_reserved enum_case_expr semi - { $$ = Stmt\EnumCase[$3, $4, $1]; } - | error { $$ = null; /* will be skipped */ } -; - -trait_adaptations: - ';' { $$ = array(); } - | '{' trait_adaptation_list '}' { $$ = $2; } -; - -trait_adaptation_list: - /* empty */ { init(); } - | trait_adaptation_list trait_adaptation { push($1, $2); } -; - -trait_adaptation: - trait_method_reference_fully_qualified T_INSTEADOF class_name_list ';' - { $$ = Stmt\TraitUseAdaptation\Precedence[$1[0], $1[1], $3]; } - | trait_method_reference T_AS member_modifier identifier_maybe_reserved ';' - { $$ = Stmt\TraitUseAdaptation\Alias[$1[0], $1[1], $3, $4]; } - | trait_method_reference T_AS member_modifier ';' - { $$ = Stmt\TraitUseAdaptation\Alias[$1[0], $1[1], $3, null]; } - | trait_method_reference T_AS identifier_not_reserved ';' - { $$ = Stmt\TraitUseAdaptation\Alias[$1[0], $1[1], null, $3]; } - | trait_method_reference T_AS reserved_non_modifiers_identifier ';' - { $$ = Stmt\TraitUseAdaptation\Alias[$1[0], $1[1], null, $3]; } -; - -trait_method_reference_fully_qualified: - name T_PAAMAYIM_NEKUDOTAYIM identifier_maybe_reserved { $$ = array($1, $3); } -; -trait_method_reference: - trait_method_reference_fully_qualified { $$ = $1; } - | identifier_maybe_reserved { $$ = array(null, $1); } -; - -method_body: - ';' /* abstract method */ { $$ = null; } - | block_or_error { $$ = $1; } -; - -variable_modifiers: - non_empty_member_modifiers { $$ = $1; } - | T_VAR { $$ = 0; } -; - -method_modifiers: - /* empty */ { $$ = 0; } - | non_empty_member_modifiers { $$ = $1; } -; - -non_empty_member_modifiers: - member_modifier { $$ = $1; } - | non_empty_member_modifiers member_modifier { $this->checkModifier($1, $2, #2); $$ = $1 | $2; } -; - -member_modifier: - T_PUBLIC { $$ = Stmt\Class_::MODIFIER_PUBLIC; } - | T_PROTECTED { $$ = Stmt\Class_::MODIFIER_PROTECTED; } - | T_PRIVATE { $$ = Stmt\Class_::MODIFIER_PRIVATE; } - | T_STATIC { $$ = Stmt\Class_::MODIFIER_STATIC; } - | T_ABSTRACT { $$ = Stmt\Class_::MODIFIER_ABSTRACT; } - | T_FINAL { $$ = Stmt\Class_::MODIFIER_FINAL; } - | T_READONLY { $$ = Stmt\Class_::MODIFIER_READONLY; } -; - -property_declaration_list: - non_empty_property_declaration_list no_comma { $$ = $1; } -; - -non_empty_property_declaration_list: - property_declaration { init($1); } - | non_empty_property_declaration_list ',' property_declaration - { push($1, $3); } -; - -property_decl_name: - T_VARIABLE { $$ = Node\VarLikeIdentifier[parseVar($1)]; } -; - -property_declaration: - property_decl_name { $$ = Stmt\PropertyProperty[$1, null]; } - | property_decl_name '=' expr { $$ = Stmt\PropertyProperty[$1, $3]; } -; - -expr_list_forbid_comma: - non_empty_expr_list no_comma { $$ = $1; } -; - -expr_list_allow_comma: - non_empty_expr_list optional_comma { $$ = $1; } -; - -non_empty_expr_list: - non_empty_expr_list ',' expr { push($1, $3); } - | expr { init($1); } -; - -for_expr: - /* empty */ { $$ = array(); } - | expr_list_forbid_comma { $$ = $1; } -; - -expr: - variable { $$ = $1; } - | list_expr '=' expr { $$ = Expr\Assign[$1, $3]; } - | array_short_syntax '=' expr { $$ = Expr\Assign[$1, $3]; } - | variable '=' expr { $$ = Expr\Assign[$1, $3]; } - | variable '=' ampersand variable { $$ = Expr\AssignRef[$1, $4]; } - | new_expr { $$ = $1; } - | match { $$ = $1; } - | T_CLONE expr { $$ = Expr\Clone_[$2]; } - | variable T_PLUS_EQUAL expr { $$ = Expr\AssignOp\Plus [$1, $3]; } - | variable T_MINUS_EQUAL expr { $$ = Expr\AssignOp\Minus [$1, $3]; } - | variable T_MUL_EQUAL expr { $$ = Expr\AssignOp\Mul [$1, $3]; } - | variable T_DIV_EQUAL expr { $$ = Expr\AssignOp\Div [$1, $3]; } - | variable T_CONCAT_EQUAL expr { $$ = Expr\AssignOp\Concat [$1, $3]; } - | variable T_MOD_EQUAL expr { $$ = Expr\AssignOp\Mod [$1, $3]; } - | variable T_AND_EQUAL expr { $$ = Expr\AssignOp\BitwiseAnd[$1, $3]; } - | variable T_OR_EQUAL expr { $$ = Expr\AssignOp\BitwiseOr [$1, $3]; } - | variable T_XOR_EQUAL expr { $$ = Expr\AssignOp\BitwiseXor[$1, $3]; } - | variable T_SL_EQUAL expr { $$ = Expr\AssignOp\ShiftLeft [$1, $3]; } - | variable T_SR_EQUAL expr { $$ = Expr\AssignOp\ShiftRight[$1, $3]; } - | variable T_POW_EQUAL expr { $$ = Expr\AssignOp\Pow [$1, $3]; } - | variable T_COALESCE_EQUAL expr { $$ = Expr\AssignOp\Coalesce [$1, $3]; } - | variable T_INC { $$ = Expr\PostInc[$1]; } - | T_INC variable { $$ = Expr\PreInc [$2]; } - | variable T_DEC { $$ = Expr\PostDec[$1]; } - | T_DEC variable { $$ = Expr\PreDec [$2]; } - | expr T_BOOLEAN_OR expr { $$ = Expr\BinaryOp\BooleanOr [$1, $3]; } - | expr T_BOOLEAN_AND expr { $$ = Expr\BinaryOp\BooleanAnd[$1, $3]; } - | expr T_LOGICAL_OR expr { $$ = Expr\BinaryOp\LogicalOr [$1, $3]; } - | expr T_LOGICAL_AND expr { $$ = Expr\BinaryOp\LogicalAnd[$1, $3]; } - | expr T_LOGICAL_XOR expr { $$ = Expr\BinaryOp\LogicalXor[$1, $3]; } - | expr '|' expr { $$ = Expr\BinaryOp\BitwiseOr [$1, $3]; } - | expr T_AMPERSAND_NOT_FOLLOWED_BY_VAR_OR_VARARG expr { $$ = Expr\BinaryOp\BitwiseAnd[$1, $3]; } - | expr T_AMPERSAND_FOLLOWED_BY_VAR_OR_VARARG expr { $$ = Expr\BinaryOp\BitwiseAnd[$1, $3]; } - | expr '^' expr { $$ = Expr\BinaryOp\BitwiseXor[$1, $3]; } - | expr '.' expr { $$ = Expr\BinaryOp\Concat [$1, $3]; } - | expr '+' expr { $$ = Expr\BinaryOp\Plus [$1, $3]; } - | expr '-' expr { $$ = Expr\BinaryOp\Minus [$1, $3]; } - | expr '*' expr { $$ = Expr\BinaryOp\Mul [$1, $3]; } - | expr '/' expr { $$ = Expr\BinaryOp\Div [$1, $3]; } - | expr '%' expr { $$ = Expr\BinaryOp\Mod [$1, $3]; } - | expr T_SL expr { $$ = Expr\BinaryOp\ShiftLeft [$1, $3]; } - | expr T_SR expr { $$ = Expr\BinaryOp\ShiftRight[$1, $3]; } - | expr T_POW expr { $$ = Expr\BinaryOp\Pow [$1, $3]; } - | '+' expr %prec T_INC { $$ = Expr\UnaryPlus [$2]; } - | '-' expr %prec T_INC { $$ = Expr\UnaryMinus[$2]; } - | '!' expr { $$ = Expr\BooleanNot[$2]; } - | '~' expr { $$ = Expr\BitwiseNot[$2]; } - | expr T_IS_IDENTICAL expr { $$ = Expr\BinaryOp\Identical [$1, $3]; } - | expr T_IS_NOT_IDENTICAL expr { $$ = Expr\BinaryOp\NotIdentical [$1, $3]; } - | expr T_IS_EQUAL expr { $$ = Expr\BinaryOp\Equal [$1, $3]; } - | expr T_IS_NOT_EQUAL expr { $$ = Expr\BinaryOp\NotEqual [$1, $3]; } - | expr T_SPACESHIP expr { $$ = Expr\BinaryOp\Spaceship [$1, $3]; } - | expr '<' expr { $$ = Expr\BinaryOp\Smaller [$1, $3]; } - | expr T_IS_SMALLER_OR_EQUAL expr { $$ = Expr\BinaryOp\SmallerOrEqual[$1, $3]; } - | expr '>' expr { $$ = Expr\BinaryOp\Greater [$1, $3]; } - | expr T_IS_GREATER_OR_EQUAL expr { $$ = Expr\BinaryOp\GreaterOrEqual[$1, $3]; } - | expr T_INSTANCEOF class_name_reference { $$ = Expr\Instanceof_[$1, $3]; } - | '(' expr ')' { $$ = $2; } - | expr '?' expr ':' expr { $$ = Expr\Ternary[$1, $3, $5]; } - | expr '?' ':' expr { $$ = Expr\Ternary[$1, null, $4]; } - | expr T_COALESCE expr { $$ = Expr\BinaryOp\Coalesce[$1, $3]; } - | T_ISSET '(' expr_list_allow_comma ')' { $$ = Expr\Isset_[$3]; } - | T_EMPTY '(' expr ')' { $$ = Expr\Empty_[$3]; } - | T_INCLUDE expr { $$ = Expr\Include_[$2, Expr\Include_::TYPE_INCLUDE]; } - | T_INCLUDE_ONCE expr { $$ = Expr\Include_[$2, Expr\Include_::TYPE_INCLUDE_ONCE]; } - | T_EVAL '(' expr ')' { $$ = Expr\Eval_[$3]; } - | T_REQUIRE expr { $$ = Expr\Include_[$2, Expr\Include_::TYPE_REQUIRE]; } - | T_REQUIRE_ONCE expr { $$ = Expr\Include_[$2, Expr\Include_::TYPE_REQUIRE_ONCE]; } - | T_INT_CAST expr { $$ = Expr\Cast\Int_ [$2]; } - | T_DOUBLE_CAST expr - { $attrs = attributes(); - $attrs['kind'] = $this->getFloatCastKind($1); - $$ = new Expr\Cast\Double($2, $attrs); } - | T_STRING_CAST expr { $$ = Expr\Cast\String_ [$2]; } - | T_ARRAY_CAST expr { $$ = Expr\Cast\Array_ [$2]; } - | T_OBJECT_CAST expr { $$ = Expr\Cast\Object_ [$2]; } - | T_BOOL_CAST expr { $$ = Expr\Cast\Bool_ [$2]; } - | T_UNSET_CAST expr { $$ = Expr\Cast\Unset_ [$2]; } - | T_EXIT exit_expr - { $attrs = attributes(); - $attrs['kind'] = strtolower($1) === 'exit' ? Expr\Exit_::KIND_EXIT : Expr\Exit_::KIND_DIE; - $$ = new Expr\Exit_($2, $attrs); } - | '@' expr { $$ = Expr\ErrorSuppress[$2]; } - | scalar { $$ = $1; } - | '`' backticks_expr '`' { $$ = Expr\ShellExec[$2]; } - | T_PRINT expr { $$ = Expr\Print_[$2]; } - | T_YIELD { $$ = Expr\Yield_[null, null]; } - | T_YIELD expr { $$ = Expr\Yield_[$2, null]; } - | T_YIELD expr T_DOUBLE_ARROW expr { $$ = Expr\Yield_[$4, $2]; } - | T_YIELD_FROM expr { $$ = Expr\YieldFrom[$2]; } - | T_THROW expr { $$ = Expr\Throw_[$2]; } - - | T_FN optional_ref '(' parameter_list ')' optional_return_type T_DOUBLE_ARROW expr %prec T_THROW - { $$ = Expr\ArrowFunction[['static' => false, 'byRef' => $2, 'params' => $4, 'returnType' => $6, 'expr' => $8, 'attrGroups' => []]]; } - | T_STATIC T_FN optional_ref '(' parameter_list ')' optional_return_type T_DOUBLE_ARROW expr %prec T_THROW - { $$ = Expr\ArrowFunction[['static' => true, 'byRef' => $3, 'params' => $5, 'returnType' => $7, 'expr' => $9, 'attrGroups' => []]]; } - | T_FUNCTION optional_ref '(' parameter_list ')' lexical_vars optional_return_type block_or_error - { $$ = Expr\Closure[['static' => false, 'byRef' => $2, 'params' => $4, 'uses' => $6, 'returnType' => $7, 'stmts' => $8, 'attrGroups' => []]]; } - | T_STATIC T_FUNCTION optional_ref '(' parameter_list ')' lexical_vars optional_return_type block_or_error - { $$ = Expr\Closure[['static' => true, 'byRef' => $3, 'params' => $5, 'uses' => $7, 'returnType' => $8, 'stmts' => $9, 'attrGroups' => []]]; } - - | attributes T_FN optional_ref '(' parameter_list ')' optional_return_type T_DOUBLE_ARROW expr %prec T_THROW - { $$ = Expr\ArrowFunction[['static' => false, 'byRef' => $3, 'params' => $5, 'returnType' => $7, 'expr' => $9, 'attrGroups' => $1]]; } - | attributes T_STATIC T_FN optional_ref '(' parameter_list ')' optional_return_type T_DOUBLE_ARROW expr %prec T_THROW - { $$ = Expr\ArrowFunction[['static' => true, 'byRef' => $4, 'params' => $6, 'returnType' => $8, 'expr' => $10, 'attrGroups' => $1]]; } - | attributes T_FUNCTION optional_ref '(' parameter_list ')' lexical_vars optional_return_type block_or_error - { $$ = Expr\Closure[['static' => false, 'byRef' => $3, 'params' => $5, 'uses' => $7, 'returnType' => $8, 'stmts' => $9, 'attrGroups' => $1]]; } - | attributes T_STATIC T_FUNCTION optional_ref '(' parameter_list ')' lexical_vars optional_return_type block_or_error - { $$ = Expr\Closure[['static' => true, 'byRef' => $4, 'params' => $6, 'uses' => $8, 'returnType' => $9, 'stmts' => $10, 'attrGroups' => $1]]; } -; - -anonymous_class: - optional_attributes class_entry_type ctor_arguments extends_from implements_list '{' class_statement_list '}' - { $$ = array(Stmt\Class_[null, ['type' => $2, 'extends' => $4, 'implements' => $5, 'stmts' => $7, 'attrGroups' => $1]], $3); - $this->checkClass($$[0], -1); } -; - -new_expr: - T_NEW class_name_reference ctor_arguments { $$ = Expr\New_[$2, $3]; } - | T_NEW anonymous_class - { list($class, $ctorArgs) = $2; $$ = Expr\New_[$class, $ctorArgs]; } -; - -lexical_vars: - /* empty */ { $$ = array(); } - | T_USE '(' lexical_var_list ')' { $$ = $3; } -; - -lexical_var_list: - non_empty_lexical_var_list optional_comma { $$ = $1; } -; - -non_empty_lexical_var_list: - lexical_var { init($1); } - | non_empty_lexical_var_list ',' lexical_var { push($1, $3); } -; - -lexical_var: - optional_ref plain_variable { $$ = Expr\ClosureUse[$2, $1]; } -; - -name_readonly: - T_READONLY { $$ = Name[$1]; } -; - -function_call: - name argument_list { $$ = Expr\FuncCall[$1, $2]; } - | name_readonly argument_list { $$ = Expr\FuncCall[$1, $2]; } - | callable_expr argument_list { $$ = Expr\FuncCall[$1, $2]; } - | class_name_or_var T_PAAMAYIM_NEKUDOTAYIM member_name argument_list - { $$ = Expr\StaticCall[$1, $3, $4]; } -; - -class_name: - T_STATIC { $$ = Name[$1]; } - | name { $$ = $1; } -; - -name: - T_STRING { $$ = Name[$1]; } - | T_NAME_QUALIFIED { $$ = Name[$1]; } - | T_NAME_FULLY_QUALIFIED { $$ = Name\FullyQualified[substr($1, 1)]; } - | T_NAME_RELATIVE { $$ = Name\Relative[substr($1, 10)]; } -; - -class_name_reference: - class_name { $$ = $1; } - | new_variable { $$ = $1; } - | '(' expr ')' { $$ = $2; } - | error { $$ = Expr\Error[]; $this->errorState = 2; } -; - -class_name_or_var: - class_name { $$ = $1; } - | fully_dereferencable { $$ = $1; } -; - -exit_expr: - /* empty */ { $$ = null; } - | '(' optional_expr ')' { $$ = $2; } -; - -backticks_expr: - /* empty */ { $$ = array(); } - | T_ENCAPSED_AND_WHITESPACE - { $$ = array(Scalar\EncapsedStringPart[Scalar\String_::parseEscapeSequences($1, '`')]); } - | encaps_list { parseEncapsed($1, '`', true); $$ = $1; } -; - -ctor_arguments: - /* empty */ { $$ = array(); } - | argument_list { $$ = $1; } -; - -constant: - name { $$ = Expr\ConstFetch[$1]; } - | T_LINE { $$ = Scalar\MagicConst\Line[]; } - | T_FILE { $$ = Scalar\MagicConst\File[]; } - | T_DIR { $$ = Scalar\MagicConst\Dir[]; } - | T_CLASS_C { $$ = Scalar\MagicConst\Class_[]; } - | T_TRAIT_C { $$ = Scalar\MagicConst\Trait_[]; } - | T_METHOD_C { $$ = Scalar\MagicConst\Method[]; } - | T_FUNC_C { $$ = Scalar\MagicConst\Function_[]; } - | T_NS_C { $$ = Scalar\MagicConst\Namespace_[]; } -; - -class_constant: - class_name_or_var T_PAAMAYIM_NEKUDOTAYIM identifier_maybe_reserved - { $$ = Expr\ClassConstFetch[$1, $3]; } - | class_name_or_var T_PAAMAYIM_NEKUDOTAYIM '{' expr '}' - { $$ = Expr\ClassConstFetch[$1, $4]; } - /* We interpret an isolated FOO:: as an unfinished class constant fetch. It could also be - an unfinished static property fetch or unfinished scoped call. */ - | class_name_or_var T_PAAMAYIM_NEKUDOTAYIM error - { $$ = Expr\ClassConstFetch[$1, new Expr\Error(stackAttributes(#3))]; $this->errorState = 2; } -; - -array_short_syntax: - '[' array_pair_list ']' - { $attrs = attributes(); $attrs['kind'] = Expr\Array_::KIND_SHORT; - $$ = new Expr\Array_($2, $attrs); } -; - -dereferencable_scalar: - T_ARRAY '(' array_pair_list ')' - { $attrs = attributes(); $attrs['kind'] = Expr\Array_::KIND_LONG; - $$ = new Expr\Array_($3, $attrs); } - | array_short_syntax { $$ = $1; } - | T_CONSTANT_ENCAPSED_STRING { $$ = Scalar\String_::fromString($1, attributes()); } - | '"' encaps_list '"' - { $attrs = attributes(); $attrs['kind'] = Scalar\String_::KIND_DOUBLE_QUOTED; - parseEncapsed($2, '"', true); $$ = new Scalar\Encapsed($2, $attrs); } -; - -scalar: - T_LNUMBER { $$ = $this->parseLNumber($1, attributes()); } - | T_DNUMBER { $$ = Scalar\DNumber::fromString($1, attributes()); } - | dereferencable_scalar { $$ = $1; } - | constant { $$ = $1; } - | class_constant { $$ = $1; } - | T_START_HEREDOC T_ENCAPSED_AND_WHITESPACE T_END_HEREDOC - { $$ = $this->parseDocString($1, $2, $3, attributes(), stackAttributes(#3), true); } - | T_START_HEREDOC T_END_HEREDOC - { $$ = $this->parseDocString($1, '', $2, attributes(), stackAttributes(#2), true); } - | T_START_HEREDOC encaps_list T_END_HEREDOC - { $$ = $this->parseDocString($1, $2, $3, attributes(), stackAttributes(#3), true); } -; - -optional_expr: - /* empty */ { $$ = null; } - | expr { $$ = $1; } -; - -fully_dereferencable: - variable { $$ = $1; } - | '(' expr ')' { $$ = $2; } - | dereferencable_scalar { $$ = $1; } - | class_constant { $$ = $1; } -; - -array_object_dereferencable: - fully_dereferencable { $$ = $1; } - | constant { $$ = $1; } -; - -callable_expr: - callable_variable { $$ = $1; } - | '(' expr ')' { $$ = $2; } - | dereferencable_scalar { $$ = $1; } -; - -callable_variable: - simple_variable { $$ = $1; } - | array_object_dereferencable '[' optional_expr ']' { $$ = Expr\ArrayDimFetch[$1, $3]; } - | array_object_dereferencable '{' expr '}' { $$ = Expr\ArrayDimFetch[$1, $3]; } - | function_call { $$ = $1; } - | array_object_dereferencable T_OBJECT_OPERATOR property_name argument_list - { $$ = Expr\MethodCall[$1, $3, $4]; } - | array_object_dereferencable T_NULLSAFE_OBJECT_OPERATOR property_name argument_list - { $$ = Expr\NullsafeMethodCall[$1, $3, $4]; } -; - -optional_plain_variable: - /* empty */ { $$ = null; } - | plain_variable { $$ = $1; } -; - -variable: - callable_variable { $$ = $1; } - | static_member { $$ = $1; } - | array_object_dereferencable T_OBJECT_OPERATOR property_name - { $$ = Expr\PropertyFetch[$1, $3]; } - | array_object_dereferencable T_NULLSAFE_OBJECT_OPERATOR property_name - { $$ = Expr\NullsafePropertyFetch[$1, $3]; } -; - -simple_variable: - plain_variable { $$ = $1; } - | '$' '{' expr '}' { $$ = Expr\Variable[$3]; } - | '$' simple_variable { $$ = Expr\Variable[$2]; } - | '$' error { $$ = Expr\Variable[Expr\Error[]]; $this->errorState = 2; } -; - -static_member_prop_name: - simple_variable - { $var = $1->name; $$ = \is_string($var) ? Node\VarLikeIdentifier[$var] : $var; } -; - -static_member: - class_name_or_var T_PAAMAYIM_NEKUDOTAYIM static_member_prop_name - { $$ = Expr\StaticPropertyFetch[$1, $3]; } -; - -new_variable: - simple_variable { $$ = $1; } - | new_variable '[' optional_expr ']' { $$ = Expr\ArrayDimFetch[$1, $3]; } - | new_variable '{' expr '}' { $$ = Expr\ArrayDimFetch[$1, $3]; } - | new_variable T_OBJECT_OPERATOR property_name { $$ = Expr\PropertyFetch[$1, $3]; } - | new_variable T_NULLSAFE_OBJECT_OPERATOR property_name { $$ = Expr\NullsafePropertyFetch[$1, $3]; } - | class_name T_PAAMAYIM_NEKUDOTAYIM static_member_prop_name - { $$ = Expr\StaticPropertyFetch[$1, $3]; } - | new_variable T_PAAMAYIM_NEKUDOTAYIM static_member_prop_name - { $$ = Expr\StaticPropertyFetch[$1, $3]; } -; - -member_name: - identifier_maybe_reserved { $$ = $1; } - | '{' expr '}' { $$ = $2; } - | simple_variable { $$ = $1; } -; - -property_name: - identifier_not_reserved { $$ = $1; } - | '{' expr '}' { $$ = $2; } - | simple_variable { $$ = $1; } - | error { $$ = Expr\Error[]; $this->errorState = 2; } -; - -list_expr: - T_LIST '(' inner_array_pair_list ')' { $$ = Expr\List_[$3]; } -; - -array_pair_list: - inner_array_pair_list - { $$ = $1; $end = count($$)-1; if ($$[$end] === null) array_pop($$); } -; - -comma_or_error: - ',' - | error - { /* do nothing -- prevent default action of $$=$1. See #551. */ } -; - -inner_array_pair_list: - inner_array_pair_list comma_or_error array_pair { push($1, $3); } - | array_pair { init($1); } -; - -array_pair: - expr { $$ = Expr\ArrayItem[$1, null, false]; } - | ampersand variable { $$ = Expr\ArrayItem[$2, null, true]; } - | list_expr { $$ = Expr\ArrayItem[$1, null, false]; } - | expr T_DOUBLE_ARROW expr { $$ = Expr\ArrayItem[$3, $1, false]; } - | expr T_DOUBLE_ARROW ampersand variable { $$ = Expr\ArrayItem[$4, $1, true]; } - | expr T_DOUBLE_ARROW list_expr { $$ = Expr\ArrayItem[$3, $1, false]; } - | T_ELLIPSIS expr { $$ = new Expr\ArrayItem($2, null, false, attributes(), true); } - | /* empty */ { $$ = null; } -; - -encaps_list: - encaps_list encaps_var { push($1, $2); } - | encaps_list encaps_string_part { push($1, $2); } - | encaps_var { init($1); } - | encaps_string_part encaps_var { init($1, $2); } -; - -encaps_string_part: - T_ENCAPSED_AND_WHITESPACE { $$ = Scalar\EncapsedStringPart[$1]; } -; - -encaps_str_varname: - T_STRING_VARNAME { $$ = Expr\Variable[$1]; } -; - -encaps_var: - plain_variable { $$ = $1; } - | plain_variable '[' encaps_var_offset ']' { $$ = Expr\ArrayDimFetch[$1, $3]; } - | plain_variable T_OBJECT_OPERATOR identifier_not_reserved - { $$ = Expr\PropertyFetch[$1, $3]; } - | plain_variable T_NULLSAFE_OBJECT_OPERATOR identifier_not_reserved - { $$ = Expr\NullsafePropertyFetch[$1, $3]; } - | T_DOLLAR_OPEN_CURLY_BRACES expr '}' { $$ = Expr\Variable[$2]; } - | T_DOLLAR_OPEN_CURLY_BRACES T_STRING_VARNAME '}' { $$ = Expr\Variable[$2]; } - | T_DOLLAR_OPEN_CURLY_BRACES encaps_str_varname '[' expr ']' '}' - { $$ = Expr\ArrayDimFetch[$2, $4]; } - | T_CURLY_OPEN variable '}' { $$ = $2; } -; - -encaps_var_offset: - T_STRING { $$ = Scalar\String_[$1]; } - | T_NUM_STRING { $$ = $this->parseNumString($1, attributes()); } - | '-' T_NUM_STRING { $$ = $this->parseNumString('-' . $2, attributes()); } - | plain_variable { $$ = $1; } -; - -%% diff --git a/vendor/nikic/php-parser/grammar/phpyLang.php b/vendor/nikic/php-parser/grammar/phpyLang.php deleted file mode 100644 index 663c2a14..00000000 --- a/vendor/nikic/php-parser/grammar/phpyLang.php +++ /dev/null @@ -1,184 +0,0 @@ -\'[^\\\\\']*+(?:\\\\.[^\\\\\']*+)*+\') - (?"[^\\\\"]*+(?:\\\\.[^\\\\"]*+)*+") - (?(?&singleQuotedString)|(?&doubleQuotedString)) - (?/\*[^*]*+(?:\*(?!/)[^*]*+)*+\*/) - (?\{[^\'"/{}]*+(?:(?:(?&string)|(?&comment)|(?&code)|/)[^\'"/{}]*+)*+}) -)'; - -const PARAMS = '\[(?[^[\]]*+(?:\[(?¶ms)\][^[\]]*+)*+)\]'; -const ARGS = '\((?[^()]*+(?:\((?&args)\)[^()]*+)*+)\)'; - -/////////////////////////////// -/// Preprocessing functions /// -/////////////////////////////// - -function preprocessGrammar($code) { - $code = resolveNodes($code); - $code = resolveMacros($code); - $code = resolveStackAccess($code); - - return $code; -} - -function resolveNodes($code) { - return preg_replace_callback( - '~\b(?[A-Z][a-zA-Z_\\\\]++)\s*' . PARAMS . '~', - function($matches) { - // recurse - $matches['params'] = resolveNodes($matches['params']); - - $params = magicSplit( - '(?:' . PARAMS . '|' . ARGS . ')(*SKIP)(*FAIL)|,', - $matches['params'] - ); - - $paramCode = ''; - foreach ($params as $param) { - $paramCode .= $param . ', '; - } - - return 'new ' . $matches['name'] . '(' . $paramCode . 'attributes())'; - }, - $code - ); -} - -function resolveMacros($code) { - return preg_replace_callback( - '~\b(?)(?!array\()(?[a-z][A-Za-z]++)' . ARGS . '~', - function($matches) { - // recurse - $matches['args'] = resolveMacros($matches['args']); - - $name = $matches['name']; - $args = magicSplit( - '(?:' . PARAMS . '|' . ARGS . ')(*SKIP)(*FAIL)|,', - $matches['args'] - ); - - if ('attributes' === $name) { - assertArgs(0, $args, $name); - return '$this->startAttributeStack[#1] + $this->endAttributes'; - } - - if ('stackAttributes' === $name) { - assertArgs(1, $args, $name); - return '$this->startAttributeStack[' . $args[0] . ']' - . ' + $this->endAttributeStack[' . $args[0] . ']'; - } - - if ('init' === $name) { - return '$$ = array(' . implode(', ', $args) . ')'; - } - - if ('push' === $name) { - assertArgs(2, $args, $name); - - return $args[0] . '[] = ' . $args[1] . '; $$ = ' . $args[0]; - } - - if ('pushNormalizing' === $name) { - assertArgs(2, $args, $name); - - return 'if (is_array(' . $args[1] . ')) { $$ = array_merge(' . $args[0] . ', ' . $args[1] . '); }' - . ' else { ' . $args[0] . '[] = ' . $args[1] . '; $$ = ' . $args[0] . '; }'; - } - - if ('toArray' == $name) { - assertArgs(1, $args, $name); - - return 'is_array(' . $args[0] . ') ? ' . $args[0] . ' : array(' . $args[0] . ')'; - } - - if ('parseVar' === $name) { - assertArgs(1, $args, $name); - - return 'substr(' . $args[0] . ', 1)'; - } - - if ('parseEncapsed' === $name) { - assertArgs(3, $args, $name); - - return 'foreach (' . $args[0] . ' as $s) { if ($s instanceof Node\Scalar\EncapsedStringPart) {' - . ' $s->value = Node\Scalar\String_::parseEscapeSequences($s->value, ' . $args[1] . ', ' . $args[2] . '); } }'; - } - - if ('makeNop' === $name) { - assertArgs(3, $args, $name); - - return '$startAttributes = ' . $args[1] . ';' - . ' if (isset($startAttributes[\'comments\']))' - . ' { ' . $args[0] . ' = new Stmt\Nop($startAttributes + ' . $args[2] . '); }' - . ' else { ' . $args[0] . ' = null; }'; - } - - if ('makeZeroLengthNop' == $name) { - assertArgs(2, $args, $name); - - return '$startAttributes = ' . $args[1] . ';' - . ' if (isset($startAttributes[\'comments\']))' - . ' { ' . $args[0] . ' = new Stmt\Nop($this->createCommentNopAttributes($startAttributes[\'comments\'])); }' - . ' else { ' . $args[0] . ' = null; }'; - } - - if ('prependLeadingComments' === $name) { - assertArgs(1, $args, $name); - - return '$attrs = $this->startAttributeStack[#1]; $stmts = ' . $args[0] . '; ' - . 'if (!empty($attrs[\'comments\'])) {' - . '$stmts[0]->setAttribute(\'comments\', ' - . 'array_merge($attrs[\'comments\'], $stmts[0]->getAttribute(\'comments\', []))); }'; - } - - return $matches[0]; - }, - $code - ); -} - -function assertArgs($num, $args, $name) { - if ($num != count($args)) { - die('Wrong argument count for ' . $name . '().'); - } -} - -function resolveStackAccess($code) { - $code = preg_replace('/\$\d+/', '$this->semStack[$0]', $code); - $code = preg_replace('/#(\d+)/', '$$1', $code); - return $code; -} - -function removeTrailingWhitespace($code) { - $lines = explode("\n", $code); - $lines = array_map('rtrim', $lines); - return implode("\n", $lines); -} - -////////////////////////////// -/// Regex helper functions /// -////////////////////////////// - -function regex($regex) { - return '~' . LIB . '(?:' . str_replace('~', '\~', $regex) . ')~'; -} - -function magicSplit($regex, $string) { - $pieces = preg_split(regex('(?:(?&string)|(?&comment)|(?&code))(*SKIP)(*FAIL)|' . $regex), $string); - - foreach ($pieces as &$piece) { - $piece = trim($piece); - } - - if ($pieces === ['']) { - return []; - } - - return $pieces; -} diff --git a/vendor/nikic/php-parser/grammar/rebuildParsers.php b/vendor/nikic/php-parser/grammar/rebuildParsers.php deleted file mode 100644 index 2d0c6b14..00000000 --- a/vendor/nikic/php-parser/grammar/rebuildParsers.php +++ /dev/null @@ -1,81 +0,0 @@ - 'Php5', - __DIR__ . '/php7.y' => 'Php7', -]; - -$tokensFile = __DIR__ . '/tokens.y'; -$tokensTemplate = __DIR__ . '/tokens.template'; -$skeletonFile = __DIR__ . '/parser.template'; -$tmpGrammarFile = __DIR__ . '/tmp_parser.phpy'; -$tmpResultFile = __DIR__ . '/tmp_parser.php'; -$resultDir = __DIR__ . '/../lib/PhpParser/Parser'; -$tokensResultsFile = $resultDir . '/Tokens.php'; - -$kmyacc = getenv('KMYACC'); -if (!$kmyacc) { - // Use phpyacc from dev dependencies by default. - $kmyacc = __DIR__ . '/../vendor/bin/phpyacc'; -} - -$options = array_flip($argv); -$optionDebug = isset($options['--debug']); -$optionKeepTmpGrammar = isset($options['--keep-tmp-grammar']); - -/////////////////// -/// Main script /// -/////////////////// - -$tokens = file_get_contents($tokensFile); - -foreach ($grammarFileToName as $grammarFile => $name) { - echo "Building temporary $name grammar file.\n"; - - $grammarCode = file_get_contents($grammarFile); - $grammarCode = str_replace('%tokens', $tokens, $grammarCode); - $grammarCode = preprocessGrammar($grammarCode); - - file_put_contents($tmpGrammarFile, $grammarCode); - - $additionalArgs = $optionDebug ? '-t -v' : ''; - - echo "Building $name parser.\n"; - $output = execCmd("$kmyacc $additionalArgs -m $skeletonFile -p $name $tmpGrammarFile"); - - $resultCode = file_get_contents($tmpResultFile); - $resultCode = removeTrailingWhitespace($resultCode); - - ensureDirExists($resultDir); - file_put_contents("$resultDir/$name.php", $resultCode); - unlink($tmpResultFile); - - echo "Building token definition.\n"; - $output = execCmd("$kmyacc -m $tokensTemplate $tmpGrammarFile"); - rename($tmpResultFile, $tokensResultsFile); - - if (!$optionKeepTmpGrammar) { - unlink($tmpGrammarFile); - } -} - -//////////////////////////////// -/// Utility helper functions /// -//////////////////////////////// - -function ensureDirExists($dir) { - if (!is_dir($dir)) { - mkdir($dir, 0777, true); - } -} - -function execCmd($cmd) { - $output = trim(shell_exec("$cmd 2>&1")); - if ($output !== "") { - echo "> " . $cmd . "\n"; - echo $output; - } - return $output; -} diff --git a/vendor/nikic/php-parser/grammar/tokens.template b/vendor/nikic/php-parser/grammar/tokens.template deleted file mode 100644 index ba4e4901..00000000 --- a/vendor/nikic/php-parser/grammar/tokens.template +++ /dev/null @@ -1,17 +0,0 @@ -semValue -#semval($,%t) $this->semValue -#semval(%n) $this->stackPos-(%l-%n) -#semval(%n,%t) $this->stackPos-(%l-%n) - -namespace PhpParser\Parser; -#include; - -/* GENERATED file based on grammar/tokens.y */ -final class Tokens -{ -#tokenval - const %s = %n; -#endtokenval -} diff --git a/vendor/nikic/php-parser/grammar/tokens.y b/vendor/nikic/php-parser/grammar/tokens.y deleted file mode 100644 index 8f0b2172..00000000 --- a/vendor/nikic/php-parser/grammar/tokens.y +++ /dev/null @@ -1,115 +0,0 @@ -/* We currently rely on the token ID mapping to be the same between PHP 5 and PHP 7 - so the same lexer can be used for - * both. This is enforced by sharing this token file. */ - -%right T_THROW -%left T_INCLUDE T_INCLUDE_ONCE T_EVAL T_REQUIRE T_REQUIRE_ONCE -%left ',' -%left T_LOGICAL_OR -%left T_LOGICAL_XOR -%left T_LOGICAL_AND -%right T_PRINT -%right T_YIELD -%right T_DOUBLE_ARROW -%right T_YIELD_FROM -%left '=' T_PLUS_EQUAL T_MINUS_EQUAL T_MUL_EQUAL T_DIV_EQUAL T_CONCAT_EQUAL T_MOD_EQUAL T_AND_EQUAL T_OR_EQUAL T_XOR_EQUAL T_SL_EQUAL T_SR_EQUAL T_POW_EQUAL T_COALESCE_EQUAL -%left '?' ':' -%right T_COALESCE -%left T_BOOLEAN_OR -%left T_BOOLEAN_AND -%left '|' -%left '^' -%left T_AMPERSAND_NOT_FOLLOWED_BY_VAR_OR_VARARG T_AMPERSAND_FOLLOWED_BY_VAR_OR_VARARG -%nonassoc T_IS_EQUAL T_IS_NOT_EQUAL T_IS_IDENTICAL T_IS_NOT_IDENTICAL T_SPACESHIP -%nonassoc '<' T_IS_SMALLER_OR_EQUAL '>' T_IS_GREATER_OR_EQUAL -%left T_SL T_SR -%left '+' '-' '.' -%left '*' '/' '%' -%right '!' -%nonassoc T_INSTANCEOF -%right '~' T_INC T_DEC T_INT_CAST T_DOUBLE_CAST T_STRING_CAST T_ARRAY_CAST T_OBJECT_CAST T_BOOL_CAST T_UNSET_CAST '@' -%right T_POW -%right '[' -%nonassoc T_NEW T_CLONE -%token T_EXIT -%token T_IF -%left T_ELSEIF -%left T_ELSE -%left T_ENDIF -%token T_LNUMBER -%token T_DNUMBER -%token T_STRING -%token T_STRING_VARNAME -%token T_VARIABLE -%token T_NUM_STRING -%token T_INLINE_HTML -%token T_ENCAPSED_AND_WHITESPACE -%token T_CONSTANT_ENCAPSED_STRING -%token T_ECHO -%token T_DO -%token T_WHILE -%token T_ENDWHILE -%token T_FOR -%token T_ENDFOR -%token T_FOREACH -%token T_ENDFOREACH -%token T_DECLARE -%token T_ENDDECLARE -%token T_AS -%token T_SWITCH -%token T_MATCH -%token T_ENDSWITCH -%token T_CASE -%token T_DEFAULT -%token T_BREAK -%token T_CONTINUE -%token T_GOTO -%token T_FUNCTION -%token T_FN -%token T_CONST -%token T_RETURN -%token T_TRY -%token T_CATCH -%token T_FINALLY -%token T_THROW -%token T_USE -%token T_INSTEADOF -%token T_GLOBAL -%right T_STATIC T_ABSTRACT T_FINAL T_PRIVATE T_PROTECTED T_PUBLIC T_READONLY -%token T_VAR -%token T_UNSET -%token T_ISSET -%token T_EMPTY -%token T_HALT_COMPILER -%token T_CLASS -%token T_TRAIT -%token T_INTERFACE -%token T_ENUM -%token T_EXTENDS -%token T_IMPLEMENTS -%token T_OBJECT_OPERATOR -%token T_NULLSAFE_OBJECT_OPERATOR -%token T_DOUBLE_ARROW -%token T_LIST -%token T_ARRAY -%token T_CALLABLE -%token T_CLASS_C -%token T_TRAIT_C -%token T_METHOD_C -%token T_FUNC_C -%token T_LINE -%token T_FILE -%token T_START_HEREDOC -%token T_END_HEREDOC -%token T_DOLLAR_OPEN_CURLY_BRACES -%token T_CURLY_OPEN -%token T_PAAMAYIM_NEKUDOTAYIM -%token T_NAMESPACE -%token T_NS_C -%token T_DIR -%token T_NS_SEPARATOR -%token T_ELLIPSIS -%token T_NAME_FULLY_QUALIFIED -%token T_NAME_QUALIFIED -%token T_NAME_RELATIVE -%token T_ATTRIBUTE -%token T_ENUM diff --git a/vendor/nikic/php-parser/lib/PhpParser/NodeVisitor/NameResolver.php b/vendor/nikic/php-parser/lib/PhpParser/NodeVisitor/NameResolver.php index d0e7de02..83f3ea83 100644 --- a/vendor/nikic/php-parser/lib/PhpParser/NodeVisitor/NameResolver.php +++ b/vendor/nikic/php-parser/lib/PhpParser/NodeVisitor/NameResolver.php @@ -118,6 +118,9 @@ class NameResolver extends NodeVisitorAbstract $this->addNamespacedName($const); } } else if ($node instanceof Stmt\ClassConst) { + if (null !== $node->type) { + $node->type = $this->resolveType($node->type); + } $this->resolveAttrGroups($node); } else if ($node instanceof Stmt\EnumCase) { $this->resolveAttrGroups($node); diff --git a/vendor/nikic/php-parser/lib/PhpParser/Parser/Php5.php b/vendor/nikic/php-parser/lib/PhpParser/Parser/Php5.php index a4306710..59bd1e8c 100644 --- a/vendor/nikic/php-parser/lib/PhpParser/Parser/Php5.php +++ b/vendor/nikic/php-parser/lib/PhpParser/Parser/Php5.php @@ -1738,7 +1738,7 @@ class Php5 extends \PhpParser\ParserAbstract $this->semValue = new Stmt\StaticVar($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 259 => function ($stackPos) { - if ($this->semStack[$stackPos-(2-2)] !== null) { $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; } + if ($this->semStack[$stackPos-(2-2)] !== null) { $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; } else { $this->semValue = $this->semStack[$stackPos-(2-1)]; } }, 260 => function ($stackPos) { $this->semValue = array(); diff --git a/vendor/nikic/php-parser/lib/PhpParser/Parser/Php7.php b/vendor/nikic/php-parser/lib/PhpParser/Parser/Php7.php index fc895cb0..6d2b4b0f 100644 --- a/vendor/nikic/php-parser/lib/PhpParser/Parser/Php7.php +++ b/vendor/nikic/php-parser/lib/PhpParser/Parser/Php7.php @@ -2056,7 +2056,7 @@ class Php7 extends \PhpParser\ParserAbstract $this->semValue = new Stmt\StaticVar($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 340 => function ($stackPos) { - if ($this->semStack[$stackPos-(2-2)] !== null) { $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; } + if ($this->semStack[$stackPos-(2-2)] !== null) { $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; } else { $this->semValue = $this->semStack[$stackPos-(2-1)]; } }, 341 => function ($stackPos) { $this->semValue = array(); diff --git a/vendor/nikic/php-parser/lib/PhpParser/ParserFactory.php b/vendor/nikic/php-parser/lib/PhpParser/ParserFactory.php index f041e7ff..baba23bd 100644 --- a/vendor/nikic/php-parser/lib/PhpParser/ParserFactory.php +++ b/vendor/nikic/php-parser/lib/PhpParser/ParserFactory.php @@ -2,6 +2,9 @@ namespace PhpParser; +use PhpParser\Lexer\Emulative; +use PhpParser\Parser\Php7; + class ParserFactory { const PREFER_PHP7 = 1; @@ -41,4 +44,33 @@ class ParserFactory ); } } + + /** + * Create a parser targeting the newest version supported by this library. Code for older + * versions will be accepted if there have been no relevant backwards-compatibility breaks in + * PHP. + * + * All supported lexer attributes (comments, startLine, endLine, startTokenPos, endTokenPos, + * startFilePos, endFilePos) will be enabled. + */ + public function createForNewestSupportedVersion(): Parser { + return new Php7(new Emulative($this->getLexerOptions())); + } + + /** + * Create a parser targeting the host PHP version, that is the PHP version we're currently + * running on. This parser will not use any token emulation. + * + * All supported lexer attributes (comments, startLine, endLine, startTokenPos, endTokenPos, + * startFilePos, endFilePos) will be enabled. + */ + public function createForHostVersion(): Parser { + return new Php7(new Lexer($this->getLexerOptions())); + } + + private function getLexerOptions(): array { + return ['usedAttributes' => [ + 'comments', 'startLine', 'endLine', 'startTokenPos', 'endTokenPos', 'startFilePos', 'endFilePos', + ]]; + } } diff --git a/vendor/oscarotero/html-parser/CHANGELOG.md b/vendor/oscarotero/html-parser/CHANGELOG.md index 04f30ad9..c547c8f3 100644 --- a/vendor/oscarotero/html-parser/CHANGELOG.md +++ b/vendor/oscarotero/html-parser/CHANGELOG.md @@ -1,10 +1,13 @@ # Changelog - All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/) and this project adheres to [Semantic Versioning](http://semver.org/). +## [0.1.8] - 2023-11-29 +### Fixed +- libxml internal buffer leak [#5] + ## [0.1.7] - 2022-12-17 ### Added - Support for PHP 8.2 [#4]. @@ -26,7 +29,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/). ## [0.1.3] - 2019-07-20 ### Fixed -- UTF-8 econding issues +- UTF-8 enconding issues ## [0.1.2] - 2019-05-25 ### Fixed @@ -43,7 +46,9 @@ First version [#2]: https://github.com/oscarotero/html-parser/issues/2 [#3]: https://github.com/oscarotero/html-parser/issues/3 [#4]: https://github.com/oscarotero/html-parser/issues/4 +[#5]: https://github.com/oscarotero/html-parser/issues/5 +[0.1.8]: https://github.com/oscarotero/html-parser/compare/v0.1.7...v0.1.8 [0.1.7]: https://github.com/oscarotero/html-parser/compare/v0.1.6...v0.1.7 [0.1.6]: https://github.com/oscarotero/html-parser/compare/v0.1.5...v0.1.6 [0.1.5]: https://github.com/oscarotero/html-parser/compare/v0.1.4...v0.1.5 diff --git a/vendor/oscarotero/html-parser/src/Parser.php b/vendor/oscarotero/html-parser/src/Parser.php index e92b3294..3c583012 100644 --- a/vendor/oscarotero/html-parser/src/Parser.php +++ b/vendor/oscarotero/html-parser/src/Parser.php @@ -90,6 +90,10 @@ class Parser libxml_disable_entity_loader($entities); } + if (libxml_get_last_error() !== false) { + libxml_clear_errors(); + } + return $document; } } diff --git a/vendor/phpcsstandards/phpcsextra/CHANGELOG.md b/vendor/phpcsstandards/phpcsextra/CHANGELOG.md index 262b97d6..3ee3258b 100644 --- a/vendor/phpcsstandards/phpcsextra/CHANGELOG.md +++ b/vendor/phpcsstandards/phpcsextra/CHANGELOG.md @@ -14,6 +14,67 @@ This projects adheres to [Keep a CHANGELOG](http://keepachangelog.com/) and uses _Nothing yet._ +## [1.2.1] - 2023-12-08 + +### Changed + +#### Other + +* Composer: The minimum `PHP_CodeSniffer` requirement has been updated to `^3.8.0` (was `^3.7.2`). [#298] +* Composer: The minimum `PHPCSUtils` requirement has been updated to `^1.0.9` (was `^1.0.8`). [#298] + +Please ensure you run `composer update phpcsstandards/phpcsextra --with-dependencies` to benefit from this. + +[#298]: https://github.com/PHPCSStandards/PHPCSExtra/pull/298 + + +## [1.2.0] - 2023-12-02 + +### Added + +#### Universal + +* :wrench: :books: New `Universal.CodeAnalysis.NoDoubleNegative` sniff to detect double negatives (!!) and advise to use a boolean cast instead. Thanks [@diedexx] for reviewing. [#277] +* :wrench: :books: New `Universal.Operators.ConcatPosition` sniff to enforce that the concatenation operator for multi-line concatenations is in a preferred position, either always at the start of the next line or always at the end of the previous line. [#294] +* :wrench: :bar_chart: :books: New `Universal.PHP.LowercasePHPTag` sniff to enforce that the "PHP" in a PHP open tag is lowercase. Thanks [@fredden] for reviewing. [#276] + +### Changed + +#### NormalizedArrays + +* `NormalizedArrays.Arrays.CommaAfterLast`: the sniff now has two extra error codes to distinguish between multi-line arrays with the last array item on the _same line_ as the array closer vs the last array item being on a line _before_ the array closer. Thanks [@stronk7] for suggesting and patching this. [#283], [#284] + These new error codes allow for selectively excluding that specific situation from triggering the sniff. + The new error codes are `FoundMultiLineCloserSameLine` (for `multiLine="forbid"`) and `MissingMultiLineCloserSameLine` (for `multiLine="enforce"`). + The pre-existing `FoundMultiLine` and `FoundSingleLine` error codes continue to be used for multi-line arrays with the last array item on a different line than the array closer. + +#### Other + +* Various housekeeping. + +[#276]: https://github.com/PHPCSStandards/PHPCSExtra/pull/276 +[#277]: https://github.com/PHPCSStandards/PHPCSExtra/pull/277 +[#283]: https://github.com/PHPCSStandards/PHPCSExtra/issues/283 +[#284]: https://github.com/PHPCSStandards/PHPCSExtra/pull/284 +[#294]: https://github.com/PHPCSStandards/PHPCSExtra/pull/294 + + +## [1.1.2] - 2023-09-21 + +### Changed + +#### Other + +* Various housekeeping. + +### Fixed + +#### Universal + +* `Universal.CodeAnalysis.ConstructorDestructorReturn`: the sniff will now correctly ignore methods mirroring the class name (PHP-4 style constructors) in namespaced code. [#207], [#272] + +[#272]: https://github.com/PHPCSStandards/PHPCSExtra/pull/272 + + ## [1.1.1] - 2023-08-26 ### Changed @@ -503,9 +564,12 @@ This initial alpha release contains the following sniffs: Individual sub-types can be allowed by excluding specific error codes. [Composer PHPCS plugin]: https://github.com/PHPCSStandards/composer-installer -[php_version-config]: https://github.com/squizlabs/PHP_CodeSniffer/wiki/Configuration-Options#setting-the-php-version +[php_version-config]: https://github.com/PHPCSStandards/PHP_CodeSniffer/wiki/Configuration-Options#setting-the-php-version [Unreleased]: https://github.com/PHPCSStandards/PHPCSExtra/compare/stable...HEAD +[1.2.1]: https://github.com/PHPCSStandards/PHPCSExtra/compare/1.2.0...1.2.1 +[1.2.0]: https://github.com/PHPCSStandards/PHPCSExtra/compare/1.1.2...1.2.0 +[1.1.2]: https://github.com/PHPCSStandards/PHPCSExtra/compare/1.1.1...1.1.2 [1.1.1]: https://github.com/PHPCSStandards/PHPCSExtra/compare/1.1.0...1.1.1 [1.1.0]: https://github.com/PHPCSStandards/PHPCSExtra/compare/1.0.4...1.1.0 [1.0.4]: https://github.com/PHPCSStandards/PHPCSExtra/compare/1.0.3...1.0.4 @@ -519,5 +583,8 @@ This initial alpha release contains the following sniffs: [@anomiex]: https://github.com/anomiex [@derickr]: https://github.com/derickr +[@diedexx]: https://github.com/diedexx +[@fredden]: https://github.com/fredden [@GaryJones]: https://github.com/GaryJones +[@stronk7]: https://github.com/stronk7 [@szepeviktor]: https://github.com/szepeviktor diff --git a/vendor/phpcsstandards/phpcsextra/Modernize/ruleset.xml b/vendor/phpcsstandards/phpcsextra/Modernize/ruleset.xml index 57e341ba..c30d745d 100644 --- a/vendor/phpcsstandards/phpcsextra/Modernize/ruleset.xml +++ b/vendor/phpcsstandards/phpcsextra/Modernize/ruleset.xml @@ -1,5 +1,5 @@ - + A collection of sniffs to detect code modernization opportunities. diff --git a/vendor/phpcsstandards/phpcsextra/NormalizedArrays/Sniffs/Arrays/CommaAfterLastSniff.php b/vendor/phpcsstandards/phpcsextra/NormalizedArrays/Sniffs/Arrays/CommaAfterLastSniff.php index d03d1ffc..7384421d 100644 --- a/vendor/phpcsstandards/phpcsextra/NormalizedArrays/Sniffs/Arrays/CommaAfterLastSniff.php +++ b/vendor/phpcsstandards/phpcsextra/NormalizedArrays/Sniffs/Arrays/CommaAfterLastSniff.php @@ -145,6 +145,13 @@ final class CommaAfterLastSniff implements Sniff return; } + // If the closer is on the same line as the last element, change the error code for multi-line arrays. + if ($errorCode === 'MultiLine' + && $tokens[$lastNonEmpty]['line'] === $tokens[$closer]['line'] + ) { + $errorCode .= 'CloserSameLine'; + } + $isComma = ($tokens[$lastNonEmpty]['code'] === \T_COMMA); $phpcsFile->recordMetric( diff --git a/vendor/phpcsstandards/phpcsextra/NormalizedArrays/ruleset.xml b/vendor/phpcsstandards/phpcsextra/NormalizedArrays/ruleset.xml index ce35adb5..69c54a8e 100644 --- a/vendor/phpcsstandards/phpcsextra/NormalizedArrays/ruleset.xml +++ b/vendor/phpcsstandards/phpcsextra/NormalizedArrays/ruleset.xml @@ -1,5 +1,5 @@ - + A ruleset for PHP_CodeSniffer to check arrays for normalized format. diff --git a/vendor/phpcsstandards/phpcsextra/README.md b/vendor/phpcsstandards/phpcsextra/README.md index 22ba5382..a82fa893 100644 --- a/vendor/phpcsstandards/phpcsextra/README.md +++ b/vendor/phpcsstandards/phpcsextra/README.md @@ -9,12 +9,13 @@ PHPCSExtra [![Latest Unstable Version](https://img.shields.io/badge/unstable-dev--develop-e68718.svg?maxAge=2419200)](https://packagist.org/packages/phpcsstandards/phpcsextra#dev-develop) [![Last Commit to Unstable](https://img.shields.io/github/last-commit/PHPCSStandards/PHPCSExtra/develop.svg)](https://github.com/PHPCSStandards/PHPCSExtra/commits/develop) -[![Minimum PHP Version](https://img.shields.io/packagist/php-v/phpcsstandards/phpcsextra.svg?maxAge=3600)][phpcsextra-packagist] [![CS Build Status](https://github.com/PHPCSStandards/PHPCSExtra/actions/workflows/basics.yml/badge.svg?branch=develop)][gha-qa-results] [![Test Build Status](https://github.com/PHPCSStandards/PHPCSExtra/actions/workflows/test.yml/badge.svg?branch=develop)][gha-test-results] -[![Tested on PHP 5.4 to 8.2](https://img.shields.io/badge/tested%20on-PHP%205.4%20|%205.5%20|%205.6%20|%207.0%20|%207.1%20|%207.2%20|%207.3%20|%207.4%20|%208.0%20|%208.1%20|%208.2-brightgreen.svg?maxAge=2419200)][gha-test-results] [![Coverage Status](https://coveralls.io/repos/github/PHPCSStandards/PHPCSExtra/badge.svg)](https://coveralls.io/github/PHPCSStandards/PHPCSExtra) +[![Minimum PHP Version](https://img.shields.io/packagist/php-v/phpcsstandards/phpcsextra.svg?maxAge=3600)][phpcsextra-packagist] +[![Tested on PHP 5.4 to 8.3](https://img.shields.io/badge/tested%20on-PHP%205.4%20|%205.5%20|%205.6%20|%207.0%20|%207.1%20|%207.2%20|%207.3%20|%207.4%20|%208.0%20|%208.1%20|%208.2%20|%208.3-brightgreen.svg?maxAge=2419200)][gha-test-results] + [![License: LGPLv3](https://poser.pugx.org/phpcsstandards/phpcsextra/license)](https://github.com/PHPCSStandards/PHPCSExtra/blob/stable/LICENSE) ![Awesome](https://img.shields.io/badge/awesome%3F-yes!-brightgreen.svg) @@ -45,8 +46,8 @@ Minimum Requirements ------------------------------------------- * PHP 5.4 or higher. -* [PHP_CodeSniffer][phpcs-gh] version **3.7.1** or higher. -* [PHPCSUtils][phpcsutils-gh] version **1.0.8** or higher. +* [PHP_CodeSniffer][phpcs-gh] version **3.8.0** or higher. +* [PHPCSUtils][phpcsutils-gh] version **1.0.9** or higher. Installation @@ -61,7 +62,7 @@ Installing via Composer is highly recommended. Run the following from the root of your project: ```bash composer config allow-plugins.dealerdirect/phpcodesniffer-composer-installer true -composer require --dev phpcsstandards/phpcsextra:"^1.1.0" +composer require --dev phpcsstandards/phpcsextra:"^1.2.0" ``` ### Composer Global Installation @@ -69,7 +70,7 @@ composer require --dev phpcsstandards/phpcsextra:"^1.1.0" Alternatively, you may want to install this standard globally: ```bash composer global config allow-plugins.dealerdirect/phpcodesniffer-composer-installer true -composer global require --dev phpcsstandards/phpcsextra:"^1.1.0" +composer global require --dev phpcsstandards/phpcsextra:"^1.2.0" ``` ### Updating to a newer version @@ -229,6 +230,13 @@ Detects `foreach` control structures which use the same variable for both the ke Note: The fixer will maintain the existing behaviour of the code. This may not be the _intended_ behaviour. +#### `Universal.CodeAnalysis.NoDoubleNegative` :wrench: :books: + +Detects double negation `!!` in code, which is effectively the same as a boolean cast, but with a much higher cognitive load. +Also detects triple negation `!!!`, which is effectively the same as a single negation. + +The sniff has modular error codes to allow for disabling individual checks. The error codes are: `FoundDouble`, `FoundDoubleWithInstanceof` (not auto-fixable) and `FoundTriple`. + #### `Universal.CodeAnalysis.NoEchoSprintf` :wrench: :books: Detects use of the inefficient `echo [v]sprintf(...);` combi. Use `[v]printf()` instead. @@ -360,6 +368,14 @@ Enforce that the names used in a class/enum "implements" statement or an interfa The fixer will separate each name with a comma and one space. If alternative formatting is desired, a sniff which will check and fix the formatting should be added to the ruleset. +#### `Universal.Operators.ConcatPosition` :wrench: :bar_chart: :books: + +Enforce that the concatenation operator for multi-line concatenations is in a preferred position, either always at the start of the next line or always at the end of the previous line. + +* This sniff contains an `allowOnly` property to set the preferred position for the operator. + Accepted values: (string) `"start"` or `"end"`. Defaults to `"start"`. +* Note: mid-line concatenation is still allowed and will not be flagged by this sniff. + #### `Universal.Operators.DisallowLogicalAndOr` :bar_chart: :books: Enforce the use of the boolean `&&` and `||` operators instead of the logical `and`/`or` operators. @@ -391,6 +407,10 @@ Enforce no spaces around the union type and intersection type operators. The available error codes are: `UnionTypeSpacesBefore`, `UnionTypeSpacesAfter`, `IntersectionTypeSpacesBefore`, `IntersectionTypeSpacesAfter`. +#### `Universal.PHP.LowercasePHPTag` :wrench: :bar_chart: :books: + +Enforces that the "PHP" in a PHP open tag is lowercase. + #### `Universal.PHP.OneStatementInShortEchoTag` :wrench: :books: Disallow short open echo tags ` + + + + + + + ! $b; + +if((bool) callMe($a)) {} + ]]> + + + ! ! $b; + +if(! ! ! callMe($a)) {} + ]]> + + + diff --git a/vendor/phpcsstandards/phpcsextra/Universal/Docs/Operators/ConcatPositionStandard.xml b/vendor/phpcsstandards/phpcsextra/Universal/Docs/Operators/ConcatPositionStandard.xml new file mode 100644 index 00000000..4d2761af --- /dev/null +++ b/vendor/phpcsstandards/phpcsextra/Universal/Docs/Operators/ConcatPositionStandard.xml @@ -0,0 +1,31 @@ + + + + + + + + . $b . 'text' + . $c; + ]]> + + + . + $b . 'text' + . $c; + ]]> + + + diff --git a/vendor/phpcsstandards/phpcsextra/Universal/Docs/PHP/LowercasePHPTagStandard.xml b/vendor/phpcsstandards/phpcsextra/Universal/Docs/PHP/LowercasePHPTagStandard.xml new file mode 100644 index 00000000..261f93cd --- /dev/null +++ b/vendor/phpcsstandards/phpcsextra/Universal/Docs/PHP/LowercasePHPTagStandard.xml @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + diff --git a/vendor/phpcsstandards/phpcsextra/Universal/Sniffs/CodeAnalysis/ConstructorDestructorReturnSniff.php b/vendor/phpcsstandards/phpcsextra/Universal/Sniffs/CodeAnalysis/ConstructorDestructorReturnSniff.php index 4c577884..6f78cb66 100644 --- a/vendor/phpcsstandards/phpcsextra/Universal/Sniffs/CodeAnalysis/ConstructorDestructorReturnSniff.php +++ b/vendor/phpcsstandards/phpcsextra/Universal/Sniffs/CodeAnalysis/ConstructorDestructorReturnSniff.php @@ -18,6 +18,7 @@ use PHPCSUtils\BackCompat\Helper; use PHPCSUtils\Tokens\Collections; use PHPCSUtils\Utils\FunctionDeclarations; use PHPCSUtils\Utils\GetTokensAsString; +use PHPCSUtils\Utils\Namespaces; use PHPCSUtils\Utils\NamingConventions; use PHPCSUtils\Utils\ObjectDeclarations; use PHPCSUtils\Utils\Scopes; @@ -105,6 +106,17 @@ final class ConstructorDestructorReturnSniff implements Sniff return; } + if (Namespaces::determineNamespace($phpcsFile, $stackPtr) !== '') { + /* + * Namespaced methods with the same name as the class are treated as + * regular methods, so we can bow out if we're in a namespace. + * + * Note: the exception to this is PHP 5.3.0-5.3.2. This is currently + * not dealt with. + */ + return; + } + $functionType = 'A PHP 4-style constructor'; } diff --git a/vendor/phpcsstandards/phpcsextra/Universal/Sniffs/CodeAnalysis/NoDoubleNegativeSniff.php b/vendor/phpcsstandards/phpcsextra/Universal/Sniffs/CodeAnalysis/NoDoubleNegativeSniff.php new file mode 100644 index 00000000..549c8cd3 --- /dev/null +++ b/vendor/phpcsstandards/phpcsextra/Universal/Sniffs/CodeAnalysis/NoDoubleNegativeSniff.php @@ -0,0 +1,269 @@ + + */ + private $operatorsWithLowerPrecedence; + + /** + * Returns an array of tokens this test wants to listen for. + * + * @since 1.2.0 + * + * @return array + */ + public function register() + { + // Collect all the operators only once. + $this->operatorsWithLowerPrecedence = Tokens::$assignmentTokens; + $this->operatorsWithLowerPrecedence += Tokens::$booleanOperators; + $this->operatorsWithLowerPrecedence += Tokens::$comparisonTokens; + $this->operatorsWithLowerPrecedence += Tokens::$operators; + $this->operatorsWithLowerPrecedence[\T_INLINE_THEN] = \T_INLINE_THEN; + $this->operatorsWithLowerPrecedence[\T_INLINE_ELSE] = \T_INLINE_ELSE; + + return [\T_BOOLEAN_NOT]; + } + + /** + * Processes this test, when one of its tokens is encountered. + * + * @since 1.2.0 + * + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file being scanned. + * @param int $stackPtr The position of the current token + * in the stack passed in $tokens. + * + * @return int|void Integer stack pointer to skip forward or void to continue + * normal file processing. + */ + public function process(File $phpcsFile, $stackPtr) + { + $tokens = $phpcsFile->getTokens(); + + $notCount = 1; + $lastNot = $stackPtr; + for ($afterNot = ($stackPtr + 1); $afterNot < $phpcsFile->numTokens; $afterNot++) { + if (isset(Tokens::$emptyTokens[$tokens[$afterNot]['code']])) { + continue; + } + + if ($tokens[$afterNot]['code'] === \T_BOOLEAN_NOT) { + $lastNot = $afterNot; + ++$notCount; + continue; + } + + break; + } + + if ($notCount === 1) { + // Singular unary not-operator. Nothing to do. + return; + } + + $found = \trim(GetTokensAsString::compact($phpcsFile, $stackPtr, $lastNot)); + $data = [$found]; + + if (($notCount % 2) === 1) { + /* + * Oh dear... silly code time, found a triple negative (or other uneven number), + * this should just be a singular not-operator. + */ + $fix = $phpcsFile->addFixableError( + 'Triple negative (or more) detected. Use a singular not (!) operator instead. Found: %s', + $stackPtr, + 'FoundTriple', + $data + ); + + if ($fix === true) { + $phpcsFile->fixer->beginChangeset(); + + $this->removeNotAndTrailingSpaces($phpcsFile, $stackPtr, $lastNot); + + $phpcsFile->fixer->endChangeset(); + } + + // Only throw one error, even if there are more than two not-operators. + return $lastNot; + } + + /* + * Found a double negative, which should be a boolean cast. + */ + + $fixable = true; + + /* + * If whatever is being "cast" is within parentheses, we're good. + * If not, we need to prevent creating a change in behaviour + * when what follows is an `$x instanceof ...` expression, as + * the "instanceof" operator is right between a boolean cast + * and the ! operator precedence-wise. + * + * Note: this only applies to double negative, not triple negative. + * + * @link https://www.php.net/language.operators.precedence + */ + if ($tokens[$afterNot]['code'] !== \T_OPEN_PARENTHESIS) { + $end = Parentheses::getLastCloser($phpcsFile, $stackPtr); + if ($end === false) { + $end = BCFile::findEndOfStatement($phpcsFile, $stackPtr); + } + + for ($nextRelevant = $afterNot; $nextRelevant < $end; $nextRelevant++) { + if (isset(Tokens::$emptyTokens[$tokens[$nextRelevant]['code']])) { + continue; + } + + if ($tokens[$nextRelevant]['code'] === \T_INSTANCEOF) { + $fixable = false; + break; + } + + if (isset($this->operatorsWithLowerPrecedence[$tokens[$nextRelevant]['code']])) { + // The expression the `!` belongs to has ended. + break; + } + + // Skip over anything within some form of brackets. + if (isset($tokens[$nextRelevant]['scope_closer']) + && ($nextRelevant === $tokens[$nextRelevant]['scope_opener'] + || $nextRelevant === $tokens[$nextRelevant]['scope_condition']) + ) { + $nextRelevant = $tokens[$nextRelevant]['scope_closer']; + continue; + } + + if (isset($tokens[$nextRelevant]['bracket_opener'], $tokens[$nextRelevant]['bracket_closer']) + && $nextRelevant === $tokens[$nextRelevant]['bracket_opener'] + ) { + $nextRelevant = $tokens[$nextRelevant]['bracket_closer']; + continue; + } + + if ($tokens[$nextRelevant]['code'] === \T_OPEN_PARENTHESIS + && isset($tokens[$nextRelevant]['parenthesis_closer']) + ) { + $nextRelevant = $tokens[$nextRelevant]['parenthesis_closer']; + continue; + } + + // Skip over attributes (just in case). + if ($tokens[$nextRelevant]['code'] === \T_ATTRIBUTE + && isset($tokens[$nextRelevant]['attribute_closer']) + ) { + $nextRelevant = $tokens[$nextRelevant]['attribute_closer']; + continue; + } + } + } + + $error = 'Double negative detected. Use a (bool) cast %s instead. Found: %s'; + $code = 'FoundDouble'; + $data = [ + '', + $found, + ]; + + if ($fixable === false) { + $code = 'FoundDoubleWithInstanceof'; + $data[0] = 'and parentheses around the instanceof expression'; + + // Don't auto-fix in combination with instanceof. + $phpcsFile->addError($error, $stackPtr, $code, $data); + + // Only throw one error, even if there are more than two not-operators. + return $lastNot; + } + + $fix = $phpcsFile->addFixableError($error, $stackPtr, $code, $data); + + if ($fix === true) { + $phpcsFile->fixer->beginChangeset(); + + $this->removeNotAndTrailingSpaces($phpcsFile, $stackPtr, $lastNot); + + $phpcsFile->fixer->replaceToken($lastNot, '(bool)'); + + $phpcsFile->fixer->endChangeset(); + } + + // Only throw one error, even if there are more than two not-operators. + return $lastNot; + } + + /** + * Remove boolean not-operators and trailing whitespace after those, + * but don't remove comments or trailing whitespace after comments. + * + * @since 1.2.0 + * + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file being scanned. + * @param int $stackPtr The position of the current token + * in the stack passed in $tokens. + * @param int $lastNot The position of the last boolean not token + * in the chain. + * + * @return void + */ + private function removeNotAndTrailingSpaces(File $phpcsFile, $stackPtr, $lastNot) + { + $tokens = $phpcsFile->getTokens(); + $ignore = false; + + for ($i = $stackPtr; $i < $lastNot; $i++) { + if (isset(Tokens::$commentTokens[$tokens[$i]['code']])) { + // Ignore comments and whitespace after comments. + $ignore = true; + continue; + } + + if ($tokens[$i]['code'] === \T_WHITESPACE && $ignore === false) { + $phpcsFile->fixer->replaceToken($i, ''); + continue; + } + + if ($tokens[$i]['code'] === \T_BOOLEAN_NOT) { + $ignore = false; + $phpcsFile->fixer->replaceToken($i, ''); + } + } + } +} diff --git a/vendor/phpcsstandards/phpcsextra/Universal/Sniffs/Operators/ConcatPositionSniff.php b/vendor/phpcsstandards/phpcsextra/Universal/Sniffs/Operators/ConcatPositionSniff.php new file mode 100644 index 00000000..093785ad --- /dev/null +++ b/vendor/phpcsstandards/phpcsextra/Universal/Sniffs/Operators/ConcatPositionSniff.php @@ -0,0 +1,204 @@ + + */ + public function register() + { + return [\T_STRING_CONCAT]; + } + + /** + * Processes this test, when one of its tokens is encountered. + * + * @since 1.2.0 + * + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file being scanned. + * @param int $stackPtr The position of the current token + * in the stack passed in $tokens. + * + * @return int|void Integer stack pointer to skip forward or void to continue + * normal file processing. + */ + public function process(File $phpcsFile, $stackPtr) + { + /* + * Validate the setting. + */ + if ($this->allowOnly !== self::POSITION_END) { + // Use the default. + $this->allowOnly = self::POSITION_START; + } + + $prevNonEmpty = $phpcsFile->findPrevious(Tokens::$emptyTokens, ($stackPtr - 1), null, true); + $nextNonEmpty = $phpcsFile->findNext(Tokens::$emptyTokens, ($stackPtr + 1), null, true); + + if ($nextNonEmpty === false) { + // Parse error/live coding. + return; + } + + $tokens = $phpcsFile->getTokens(); + if ($tokens[$prevNonEmpty]['line'] === $tokens[$nextNonEmpty]['line']) { + // Not multi-line concatenation. Not our target. + return; + } + + $position = self::POSITION_STANDALONE; + if ($tokens[$prevNonEmpty]['line'] === $tokens[$stackPtr]['line']) { + $position = self::POSITION_END; + } elseif ($tokens[$nextNonEmpty]['line'] === $tokens[$stackPtr]['line']) { + $position = self::POSITION_START; + } + + // Record metric. + $phpcsFile->recordMetric($stackPtr, self::METRIC_NAME, $position); + + if ($this->allowOnly === $position) { + // All okay. + return; + } + + $fix = $phpcsFile->addFixableError( + 'The concatenation operator for multi-line concatenations should always be at the %s of a line.', + $stackPtr, + 'Incorrect', + [$this->allowOnly] + ); + + if ($fix === true) { + if ($this->allowOnly === self::POSITION_END) { + $phpcsFile->fixer->beginChangeset(); + + // Move the concat operator. + $phpcsFile->fixer->replaceToken($stackPtr, ''); + $phpcsFile->fixer->addContent($prevNonEmpty, ' .'); + + if ($position === self::POSITION_START + && $tokens[($stackPtr + 1)]['code'] === \T_WHITESPACE + ) { + // Remove trailing space. + $phpcsFile->fixer->replaceToken(($stackPtr + 1), ''); + } elseif ($position === self::POSITION_STANDALONE) { + // Remove potential indentation space. + if ($tokens[($stackPtr - 1)]['code'] === \T_WHITESPACE) { + $phpcsFile->fixer->replaceToken(($stackPtr - 1), ''); + } + + // Remove new line. + if ($tokens[($stackPtr + 1)]['code'] === \T_WHITESPACE) { + $phpcsFile->fixer->replaceToken(($stackPtr + 1), ''); + } + } + + $phpcsFile->fixer->endChangeset(); + return; + } + + // Fixer for allowOnly === self::POSITION_START. + $phpcsFile->fixer->beginChangeset(); + + // Move the concat operator. + $phpcsFile->fixer->replaceToken($stackPtr, ''); + $phpcsFile->fixer->addContentBefore($nextNonEmpty, '. '); + + if ($position === self::POSITION_END + && $tokens[($stackPtr - 1)]['code'] === \T_WHITESPACE + ) { + // Remove trailing space. + $phpcsFile->fixer->replaceToken(($stackPtr - 1), ''); + } elseif ($position === self::POSITION_STANDALONE) { + // Remove potential indentation space. + if ($tokens[($stackPtr - 1)]['code'] === \T_WHITESPACE) { + $phpcsFile->fixer->replaceToken(($stackPtr - 1), ''); + } + + // Remove new line. + if ($tokens[($stackPtr + 1)]['code'] === \T_WHITESPACE) { + $phpcsFile->fixer->replaceToken(($stackPtr + 1), ''); + } + } + + $phpcsFile->fixer->endChangeset(); + } + } +} diff --git a/vendor/phpcsstandards/phpcsextra/Universal/Sniffs/PHP/LowercasePHPTagSniff.php b/vendor/phpcsstandards/phpcsextra/Universal/Sniffs/PHP/LowercasePHPTagSniff.php new file mode 100644 index 00000000..b231b225 --- /dev/null +++ b/vendor/phpcsstandards/phpcsextra/Universal/Sniffs/PHP/LowercasePHPTagSniff.php @@ -0,0 +1,87 @@ + + */ + public function register() + { + return [\T_OPEN_TAG]; + } + + /** + * Processes this test, when one of its tokens is encountered. + * + * @since 1.2.0 + * + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file being scanned. + * @param int $stackPtr The position of the current token + * in the stack passed in $tokens. + * + * @return void + */ + public function process(File $phpcsFile, $stackPtr) + { + $tokens = $phpcsFile->getTokens(); + $content = $tokens[$stackPtr]['content']; + $contentLC = \strtolower($content); + + if ($contentLC === $content) { + $phpcsFile->recordMetric($stackPtr, self::METRIC_NAME, 'lowercase'); + return; + } + + $errorCode = ''; + if (\strtoupper($content) === $content) { + $errorCode = 'Uppercase'; + $phpcsFile->recordMetric($stackPtr, self::METRIC_NAME, 'uppercase'); + } else { + $errorCode = 'Mixedcase'; + $phpcsFile->recordMetric($stackPtr, self::METRIC_NAME, 'mixed case'); + } + + $fix = $phpcsFile->addFixableError( + 'The php open tag should be in lowercase. Found: %s', + $stackPtr, + $errorCode, + [\trim($content)] + ); + + if ($fix === true) { + $phpcsFile->fixer->replaceToken($stackPtr, $contentLC); + } + } +} diff --git a/vendor/phpcsstandards/phpcsextra/Universal/Sniffs/UseStatements/NoUselessAliasesSniff.php b/vendor/phpcsstandards/phpcsextra/Universal/Sniffs/UseStatements/NoUselessAliasesSniff.php index 6d699934..93de596c 100644 --- a/vendor/phpcsstandards/phpcsextra/Universal/Sniffs/UseStatements/NoUselessAliasesSniff.php +++ b/vendor/phpcsstandards/phpcsextra/Universal/Sniffs/UseStatements/NoUselessAliasesSniff.php @@ -28,15 +28,6 @@ use PHPCSUtils\Utils\UseStatements; final class NoUselessAliasesSniff implements Sniff { - /** - * Name of the "Use import source" metric. - * - * @since 1.1.0 - * - * @var string - */ - const METRIC_NAME = 'Import use statement type'; - /** * Returns an array of tokens this test wants to listen for. * diff --git a/vendor/phpcsstandards/phpcsextra/Universal/ruleset.xml b/vendor/phpcsstandards/phpcsextra/Universal/ruleset.xml index 33067f2b..6c591eb7 100644 --- a/vendor/phpcsstandards/phpcsextra/Universal/ruleset.xml +++ b/vendor/phpcsstandards/phpcsextra/Universal/ruleset.xml @@ -1,5 +1,5 @@ - + A collection of universal sniffs. This standard is not designed to be used to check code. Include individual sniffs from this standard in a custom ruleset instead. diff --git a/vendor/phpcsstandards/phpcsextra/composer.json b/vendor/phpcsstandards/phpcsextra/composer.json index f4bbf2b9..92122571 100644 --- a/vendor/phpcsstandards/phpcsextra/composer.json +++ b/vendor/phpcsstandards/phpcsextra/composer.json @@ -17,19 +17,20 @@ ], "support" : { "issues" : "https://github.com/PHPCSStandards/PHPCSExtra/issues", - "source" : "https://github.com/PHPCSStandards/PHPCSExtra" + "source" : "https://github.com/PHPCSStandards/PHPCSExtra", + "security": "https://github.com/PHPCSStandards/PHPCSExtra/security/policy" }, "require" : { "php" : ">=5.4", - "squizlabs/php_codesniffer" : "^3.7.1", - "phpcsstandards/phpcsutils" : "^1.0.8" + "squizlabs/php_codesniffer" : "^3.8.0", + "phpcsstandards/phpcsutils" : "^1.0.9" }, "require-dev" : { "php-parallel-lint/php-parallel-lint": "^1.3.2", "php-parallel-lint/php-console-highlighter": "^1.0", "phpcsstandards/phpcsdevcs": "^1.1.6", "phpcsstandards/phpcsdevtools": "^1.2.1", - "phpunit/phpunit": "^4.5 || ^5.0 || ^6.0 || ^7.0" + "phpunit/phpunit": "^4.5 || ^5.0 || ^6.0 || ^7.0 || ^8.0 || ^9.0" }, "extra": { "branch-alias": { diff --git a/vendor/phpcsstandards/phpcsutils/CHANGELOG.md b/vendor/phpcsstandards/phpcsutils/CHANGELOG.md index 4094d4ab..cc5bb53d 100644 --- a/vendor/phpcsstandards/phpcsutils/CHANGELOG.md +++ b/vendor/phpcsstandards/phpcsutils/CHANGELOG.md @@ -10,6 +10,34 @@ This projects adheres to [Keep a CHANGELOG](https://keepachangelog.com/) and use _Nothing yet._ +## [1.0.9] - 2023-12-08 + +### Added + +#### PHPCS BackCompat + +* `BCFile::getMemberProperties()`: sync with PHPCS 3.8.0 - support for PHP 8.2 `true` type. [#524] +* `BCFile::getMethodProperties()`: sync with PHPCS 3.8.0 - support for PHP 8.2 `true` type. [#524] +* `BCFile::getMethodParameters()`: sync with PHPCS 3.8.0 - support for PHP 8.2 `true` type. [#524] + +### Changed + +#### TestUtils + +* Significant performance improvement for the [`UtilityMethodTestCase`]. [#525] + +#### Other + +* Dropped support for [PHP_CodeSniffer] < 3.8.0. [#523] + Please ensure you run `composer update phpcsstandards/phpcsutils --with-dependencies` to benefit from this. +* Small improvements to the documentation website generation. Includes a contribution from [@fredden]. +* Various housekeeping and documentation improvements. Includes a contribution from [@fredden]. + +[#523]: https://github.com/PHPCSStandards/PHPCSUtils/pull/523 +[#524]: https://github.com/PHPCSStandards/PHPCSUtils/pull/524 +[#525]: https://github.com/PHPCSStandards/PHPCSUtils/pull/525 + + ## [1.0.8] - 2023-07-17 ### Changed @@ -928,6 +956,7 @@ This initial alpha release contains the following utility classes: [Unreleased]: https://github.com/PHPCSStandards/PHPCSUtils/compare/stable...HEAD +[1.0.9]: https://github.com/PHPCSStandards/PHPCSUtils/compare/1.0.8...1.0.9 [1.0.8]: https://github.com/PHPCSStandards/PHPCSUtils/compare/1.0.7...1.0.8 [1.0.7]: https://github.com/PHPCSStandards/PHPCSUtils/compare/1.0.6...1.0.7 [1.0.6]: https://github.com/PHPCSStandards/PHPCSUtils/compare/1.0.5...1.0.6 @@ -943,6 +972,7 @@ This initial alpha release contains the following utility classes: [1.0.0-alpha2]: https://github.com/PHPCSStandards/PHPCSUtils/compare/1.0.0-alpha1...1.0.0-alpha2 [Composer PHPCS plugin]: https://github.com/PHPCSStandards/composer-installer +[PHP_CodeSniffer]: https://github.com/PHPCSStandards/PHP_CodeSniffer [`AbstractArrayDeclarationSniff`]: https://phpcsutils.com/phpdoc/classes/PHPCSUtils-AbstractSniffs-AbstractArrayDeclarationSniff.html [`BCFile`]: https://phpcsutils.com/phpdoc/classes/PHPCSUtils-BackCompat-BCFile.html @@ -973,5 +1003,6 @@ This initial alpha release contains the following utility classes: [`UseStatements`]: https://phpcsutils.com/phpdoc/classes/PHPCSUtils-Utils-UseStatements.html [`Variables`]: https://phpcsutils.com/phpdoc/classes/PHPCSUtils-Utils-Variables.html +[@fredden]: https://github.com/fredden [@GaryJones]: https://github.com/GaryJones [@szepeviktor]: https://github.com/szepeviktor diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/AbstractSniffs/AbstractArrayDeclarationSniff.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/AbstractSniffs/AbstractArrayDeclarationSniff.php index 21420a8e..b79a3fdc 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/AbstractSniffs/AbstractArrayDeclarationSniff.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/AbstractSniffs/AbstractArrayDeclarationSniff.php @@ -42,7 +42,7 @@ abstract class AbstractArrayDeclarationSniff implements Sniff * * @since 1.0.0 * - * @var array + * @var array> */ protected $tokens; @@ -79,7 +79,7 @@ abstract class AbstractArrayDeclarationSniff implements Sniff * * @since 1.0.0 * - * @var array + * @var array> */ protected $arrayItems; @@ -108,7 +108,7 @@ abstract class AbstractArrayDeclarationSniff implements Sniff * * @since 1.0.0 * - * @var array + * @var array */ private $acceptedTokens = [ \T_NULL => \T_NULL, @@ -152,7 +152,7 @@ abstract class AbstractArrayDeclarationSniff implements Sniff * * @codeCoverageIgnore * - * @return array + * @return array */ public function register() { diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/BackCompat/BCFile.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/BackCompat/BCFile.php index 030bde4b..af4ec95e 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/BackCompat/BCFile.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/BackCompat/BCFile.php @@ -29,7 +29,7 @@ * @author Klaus Purer * * @copyright 2006-2019 Squiz Pty Ltd (ABN 77 084 670 600) - * @license https://github.com/squizlabs/PHP_CodeSniffer/blob/master/licence.txt BSD Licence + * @license https://github.com/PHPCSStandards/PHP_CodeSniffer/blob/master/licence.txt BSD Licence */ namespace PHPCSUtils\BackCompat; @@ -201,7 +201,7 @@ final class BCFile * @param int $stackPtr The position in the stack of the function token * to acquire the parameters for. * - * @return array + * @return array> * * @throws \PHP_CodeSniffer\Exceptions\RuntimeException If the specified `$stackPtr` is not of * type `T_FUNCTION`, `T_CLOSURE`, `T_USE`, @@ -362,6 +362,7 @@ final class BCFile case T_TYPE_UNION: case T_TYPE_INTERSECTION: case T_FALSE: + case T_TRUE: case T_NULL: // Part of a type hint or default value. if ($defaultStart === null) { @@ -498,7 +499,7 @@ final class BCFile * * Changelog for the PHPCS native function: * - Introduced in PHPCS 0.0.5. - * - The upstream method has received no significant updates since PHPCS 3.7.1. + * - The upstream method has received no significant updates since PHPCS 3.8.0. * * @see \PHP_CodeSniffer\Files\File::getMethodProperties() Original source. * @see \PHPCSUtils\Utils\FunctionDeclarations::getProperties() PHPCSUtils native improved version. @@ -509,7 +510,7 @@ final class BCFile * @param int $stackPtr The position in the stack of the function token to * acquire the properties for. * - * @return array + * @return array * * @throws \PHP_CodeSniffer\Exceptions\RuntimeException If the specified position is not a * `T_FUNCTION`, `T_CLOSURE`, or `T_FN` token. @@ -543,7 +544,7 @@ final class BCFile * * Changelog for the PHPCS native function: * - Introduced in PHPCS 0.0.5. - * - The upstream method has received no significant updates since PHPCS 3.7.1. + * - The upstream method has received no significant updates since PHPCS 3.8.0. * * @see \PHP_CodeSniffer\Files\File::getMemberProperties() Original source. * @see \PHPCSUtils\Utils\Variables::getMemberProperties() PHPCSUtils native improved version. @@ -554,7 +555,7 @@ final class BCFile * @param int $stackPtr The position in the stack of the `T_VARIABLE` token to * acquire the properties for. * - * @return array + * @return array * * @throws \PHP_CodeSniffer\Exceptions\RuntimeException If the specified position is not a * `T_VARIABLE` token, or if the position is not @@ -573,7 +574,7 @@ final class BCFile * array( * 'is_abstract' => boolean, // TRUE if the abstract keyword was found. * 'is_final' => boolean, // TRUE if the final keyword was found. - * 'is_readonly' => false, // TRUE if the readonly keyword was found. + * 'is_readonly' => boolean, // TRUE if the readonly keyword was found. * ); * ``` * @@ -593,7 +594,7 @@ final class BCFile * @param int $stackPtr The position in the stack of the `T_CLASS` * token to acquire the properties for. * - * @return array + * @return array * * @throws \PHP_CodeSniffer\Exceptions\RuntimeException If the specified position is not a * `T_CLASS` token. @@ -653,7 +654,7 @@ final class BCFile * * Changelog for the PHPCS native function: * - Introduced in PHPCS 0.0.5. - * - The upstream method has received no significant updates since PHPCS 3.7.1. + * - The upstream method has received no significant updates since PHPCS 3.8.0. * * @see \PHP_CodeSniffer\Files\File::isReference() Original source. * @see \PHPCSUtils\Utils\Operators::isReference() PHPCSUtils native improved version. @@ -679,7 +680,7 @@ final class BCFile * * Changelog for the PHPCS native function: * - Introduced in PHPCS 0.0.5. - * - The upstream method has received no significant updates since PHPCS 3.7.1. + * - The upstream method has received no significant updates since PHPCS 3.8.0. * * @see \PHP_CodeSniffer\Files\File::getTokensAsString() Original source. * @see \PHPCSUtils\Utils\GetTokensAsString Related set of functions. @@ -708,15 +709,15 @@ final class BCFile * * Changelog for the PHPCS native function: * - Introduced in PHPCS 2.1.0. - * - The upstream method has received no significant updates since PHPCS 3.7.1. + * - The upstream method has received no significant updates since PHPCS 3.8.0. * * @see \PHP_CodeSniffer\Files\File::findStartOfStatement() Original source. * * @since 1.0.0 * - * @param \PHP_CodeSniffer\Files\File $phpcsFile The file being scanned. - * @param int $start The position to start searching from in the token stack. - * @param int|string|array $ignore Token types that should not be considered stop points. + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file being scanned. + * @param int $start The position to start searching from in the token stack. + * @param int|string|array $ignore Token types that should not be considered stop points. * * @return int */ @@ -732,15 +733,15 @@ final class BCFile * * Changelog for the PHPCS native function: * - Introduced in PHPCS 2.1.0. - * - The upstream method has received no significant updates since PHPCS 3.7.1. + * - The upstream method has received no significant updates since PHPCS 3.8.0. * * @see \PHP_CodeSniffer\Files\File::findEndOfStatement() Original source. * * @since 1.0.0 * - * @param \PHP_CodeSniffer\Files\File $phpcsFile The file being scanned. - * @param int $start The position to start searching from in the token stack. - * @param int|string|array $ignore Token types that should not be considered stop points. + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file being scanned. + * @param int $start The position to start searching from in the token stack. + * @param int|string|array $ignore Token types that should not be considered stop points. * * @return int */ @@ -756,16 +757,16 @@ final class BCFile * * Changelog for the PHPCS native function: * - Introduced in PHPCS 0.0.5. - * - The upstream method has received no significant updates since PHPCS 3.7.1. + * - The upstream method has received no significant updates since PHPCS 3.8.0. * * @see \PHP_CodeSniffer\Files\File::hasCondition() Original source. * @see \PHPCSUtils\Utils\Conditions::hasCondition() PHPCSUtils native alternative. * * @since 1.0.0 * - * @param \PHP_CodeSniffer\Files\File $phpcsFile The file being scanned. - * @param int $stackPtr The position of the token we are checking. - * @param int|string|array $types The type(s) of tokens to search for. + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file being scanned. + * @param int $stackPtr The position of the token we are checking. + * @param int|string|array $types The type(s) of tokens to search for. * * @return bool */ @@ -781,7 +782,7 @@ final class BCFile * * Changelog for the PHPCS native function: * - Introduced in PHPCS 1.3.0. - * - The upstream method has received no significant updates since PHPCS 3.7.1. + * - The upstream method has received no significant updates since PHPCS 3.8.0. * * @see \PHP_CodeSniffer\Files\File::getCondition() Original source. * @see \PHPCSUtils\Utils\Conditions::getCondition() More versatile alternative. @@ -812,7 +813,7 @@ final class BCFile * * Changelog for the PHPCS native function: * - Introduced in PHPCS 1.2.0. - * - The upstream method has received no significant updates since PHPCS 3.7.1. + * - The upstream method has received no significant updates since PHPCS 3.8.0. * * @see \PHP_CodeSniffer\Files\File::findExtendedClassName() Original source. * @see \PHPCSUtils\Utils\ObjectDeclarations::findExtendedClassName() PHPCSUtils native improved version. @@ -837,7 +838,7 @@ final class BCFile * * Changelog for the PHPCS native function: * - Introduced in PHPCS 2.7.0. - * - The upstream method has received no significant updates since PHPCS 3.7.1. + * - The upstream method has received no significant updates since PHPCS 3.8.0. * * @see \PHP_CodeSniffer\Files\File::findImplementedInterfaceNames() Original source. * @see \PHPCSUtils\Utils\ObjectDeclarations::findImplementedInterfaceNames() PHPCSUtils native improved version. @@ -847,8 +848,8 @@ final class BCFile * @param \PHP_CodeSniffer\Files\File $phpcsFile The file being scanned. * @param int $stackPtr The stack position of the class or enum token. * - * @return array|false Array with names of the implemented interfaces or `FALSE` on - * error or if there are no implemented interface names. + * @return string[]|false Array with names of the implemented interfaces or `FALSE` on + * error or if there are no implemented interface names. */ public static function findImplementedInterfaceNames(File $phpcsFile, $stackPtr) { diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/BackCompat/BCTokens.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/BackCompat/BCTokens.php index 78591164..9424f70c 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/BackCompat/BCTokens.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/BackCompat/BCTokens.php @@ -74,15 +74,15 @@ final class BCTokens /** * Handle calls to (undeclared) methods for token arrays which haven't received any - * changes since PHPCS 3.7.1. + * changes since PHPCS 3.8.0. * * @since 1.0.0 * - * @param string $name The name of the method which has been called. - * @param array $args Any arguments passed to the method. - * Unused as none of the methods take arguments. + * @param string $name The name of the method which has been called. + * @param array $args Any arguments passed to the method. + * Unused as none of the methods take arguments. * - * @return array => Token array + * @return array Token array * * @throws \PHPCSUtils\Exceptions\InvalidTokenArray When an invalid token array is requested. */ @@ -110,7 +110,7 @@ final class BCTokens * * @since 1.0.0 * - * @return array => Token array. + * @return array Token array. */ public static function functionNameTokens() { diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/BackCompat/Helper.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/BackCompat/Helper.php index c3a30257..7352a8cb 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/BackCompat/Helper.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/BackCompat/Helper.php @@ -52,7 +52,7 @@ final class Helper * @since 1.0.0 * * @param string $key The name of the config value. - * @param string|null $value The value to set. If `null`, the config entry + * @param mixed $value The value to set. If `null`, the config entry * is deleted, reverting it to the default value. * @param bool $temp Set this config data temporarily for this script run. * This will not write the config data to the config file. diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Exceptions/TestTargetNotFound.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Exceptions/TestTargetNotFound.php index 0e9eed68..4f9e5b4e 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Exceptions/TestTargetNotFound.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Exceptions/TestTargetNotFound.php @@ -29,12 +29,12 @@ final class TestTargetNotFound extends OutOfBoundsException * @param string $content The (optional) target token content. * @param string $file The file in which the target token was not found. * - * @return \PHPCSUtils\Exceptions\TestMarkerNotFound + * @return \PHPCSUtils\Exceptions\TestTargetNotFound */ public static function create($marker, $content, $file) { $contentPhrase = ''; - if ($content !== null) { + if (\is_string($content)) { $contentPhrase = ' with token content: ' . $content; } diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Internal/Cache.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Internal/Cache.php index 3843f03d..2f7873fe 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Internal/Cache.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Internal/Cache.php @@ -68,7 +68,8 @@ final class Cache * * @since 1.0.0 * - * @var array> Format: $cache[$loop][$fileName][$key][$id] = mixed $value; + * @var array>>> + * Format: $cache[$loop][$fileName][$key][$id] = mixed $value; */ private static $cache = []; @@ -144,7 +145,7 @@ final class Cache * @param string $key The key to identify a particular set of results. * It is recommended to pass __METHOD__ to this parameter. * - * @return array + * @return array */ public static function getForFile(File $phpcsFile, $key) { diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Internal/IsShortArrayOrList.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Internal/IsShortArrayOrList.php index f056d623..28a38989 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Internal/IsShortArrayOrList.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Internal/IsShortArrayOrList.php @@ -114,7 +114,7 @@ final class IsShortArrayOrList * * @since 1.0.0 * - * @var array + * @var array> */ private $tokens; @@ -168,7 +168,7 @@ final class IsShortArrayOrList * * @since 1.0.0 * - * @return array => + * @var array */ private $openBrackets; diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Internal/IsShortArrayOrListWithCache.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Internal/IsShortArrayOrListWithCache.php index 72f854f0..b1b8c47e 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Internal/IsShortArrayOrListWithCache.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Internal/IsShortArrayOrListWithCache.php @@ -58,7 +58,7 @@ final class IsShortArrayOrListWithCache * * @since 1.0.0 * - * @var array + * @var array> */ private $tokens; diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Internal/NoFileCache.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Internal/NoFileCache.php index 6e7d08dd..2f7a2478 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Internal/NoFileCache.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Internal/NoFileCache.php @@ -116,7 +116,7 @@ final class NoFileCache * @param string $key The key to identify a particular set of results. * It is recommended to pass `__METHOD__` to this parameter. * - * @return array + * @return array */ public static function getForKey($key) { diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Internal/StableCollections.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Internal/StableCollections.php index 7d8d92f0..593392df 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Internal/StableCollections.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Internal/StableCollections.php @@ -46,7 +46,7 @@ final class StableCollections * * @since 1.0.2 * - * @var array => + * @var array */ public static $shortArrayListOpenTokensBC = [ \T_OPEN_SHORT_ARRAY => \T_OPEN_SHORT_ARRAY, @@ -64,7 +64,7 @@ final class StableCollections * * @since 1.0.2 * - * @var array => + * @var array */ public static $shortArrayListTokensBC = [ \T_OPEN_SHORT_ARRAY => \T_OPEN_SHORT_ARRAY, diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/TestUtils/UtilityMethodTestCase.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/TestUtils/UtilityMethodTestCase.php index fcc1e75a..2de11a2d 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/TestUtils/UtilityMethodTestCase.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/TestUtils/UtilityMethodTestCase.php @@ -18,6 +18,7 @@ use PHPCSUtils\Exceptions\TestMarkerNotFound; use PHPCSUtils\Exceptions\TestTargetNotFound; use PHPUnit\Framework\TestCase; use ReflectionClass; +use ReflectionProperty; /** * Base class for use when testing utility methods for PHP_CodeSniffer. @@ -154,7 +155,7 @@ abstract class UtilityMethodTestCase extends TestCase * * @since 1.0.0 * - * @var \PHP_CodeSniffer\Files\File + * @var \PHP_CodeSniffer\Files\File|null */ protected static $phpcsFile; @@ -168,7 +169,7 @@ abstract class UtilityMethodTestCase extends TestCase * * @since 1.0.0 * - * @var array + * @var string[] */ protected static $selectedSniff = ['Dummy.Dummy.Dummy']; @@ -208,9 +209,22 @@ abstract class UtilityMethodTestCase extends TestCase $contents = \file_get_contents($caseFile); + /* + * Set the static properties in the Config class to specific values for performance + * and to clear out values from other tests. + */ + self::setStaticConfigProperty('executablePaths', []); + + // Set to values which prevent the test-runner user's `CodeSniffer.conf` file + // from being read and influencing the tests. Also prevent an `exec()` call to stty. + self::setStaticConfigProperty('configData', ['report_width' => 80]); + self::setStaticConfigProperty('configDataFile', ''); + $config = new \PHP_CodeSniffer\Config(); /* + * Set to a usable value to circumvent Config trying to find a phpcs.xml config file. + * * We just need to provide a standard so PHPCS will tokenize the file. * The standard itself doesn't actually matter for testing utility methods, * so use the smallest one to get the fastest results. @@ -298,6 +312,27 @@ abstract class UtilityMethodTestCase extends TestCase self::$tabWidth = 4; self::$phpcsFile = null; self::$selectedSniff = ['Dummy.Dummy.Dummy']; + + // Reset the static properties in the Config class to their defaults to prevent tests influencing each other. + self::setStaticConfigProperty('executablePaths', []); + self::setStaticConfigProperty('configData', null); + self::setStaticConfigProperty('configDataFile', null); + } + + /** + * Helper function to set the value of a private static property on the PHPCS Config class. + * + * @param string $name The name of the property to set. + * @param mixed $value The value to set the property to. + * + * @return void + */ + public static function setStaticConfigProperty($name, $value) + { + $property = new ReflectionProperty('PHP_CodeSniffer\Config', $name); + $property->setAccessible(true); + $property->setValue(null, $value); + $property->setAccessible(false); } /** @@ -329,10 +364,10 @@ abstract class UtilityMethodTestCase extends TestCase * * @since 1.0.0 * - * @param string $commentString The complete delimiter comment to look for as a string. - * This string should include the comment opener and closer. - * @param int|string|array $tokenType The type of token(s) to look for. - * @param string $tokenContent Optional. The token content for the target token. + * @param string $commentString The complete delimiter comment to look for as a string. + * This string should include the comment opener and closer. + * @param int|string|array $tokenType The type of token(s) to look for. + * @param string $tokenContent Optional. The token content for the target token. * * @return int * diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Tokens/Collections.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Tokens/Collections.php index 09ed84b4..c8465152 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Tokens/Collections.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Tokens/Collections.php @@ -67,7 +67,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::alternativeControlStructureSyntaxes()} method for access. * - * @var array => + * @var array */ private static $alternativeControlStructureSyntaxes = [ \T_IF => \T_IF, @@ -85,7 +85,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::alternativeControlStructureSyntaxClosers()} method for access. * - * @var array => + * @var array */ private static $alternativeControlStructureSyntaxClosers = [ \T_ENDIF => \T_ENDIF, @@ -109,7 +109,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::arrayOpenTokensBC()} method for access. * - * @var array => + * @var array */ private static $arrayOpenTokensBC = [ \T_ARRAY => \T_ARRAY, @@ -128,7 +128,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::arrayTokens()} method for access. * - * @var array => + * @var array */ private static $arrayTokens = [ \T_ARRAY => \T_ARRAY, @@ -141,7 +141,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::classModifierKeywords()} method for access. * - * @var array => + * @var array */ private static $classModifierKeywords = [ \T_FINAL => \T_FINAL, @@ -160,7 +160,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::closedScopes()} method for access. * - * @var array => + * @var array */ private static $closedScopes = [ \T_CLASS => \T_CLASS, @@ -180,7 +180,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::constantModifierKeywords()} method for access. * - * @var array => + * @var array */ private static $constantModifierKeywords = [ \T_PUBLIC => \T_PUBLIC, @@ -194,7 +194,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::controlStructureTokens()} method for access. * - * @var array => + * @var array */ private static $controlStructureTokens = [ \T_IF => \T_IF, @@ -214,7 +214,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::functionDeclarationTokens()} method for access. * - * @var array => + * @var array */ private static $functionDeclarationTokens = [ \T_FUNCTION => \T_FUNCTION, @@ -227,7 +227,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::incrementDecrementOperators()} method for access. * - * @var array => + * @var array */ private static $incrementDecrementOperators = [ \T_DEC => \T_DEC, @@ -247,7 +247,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::listOpenTokensBC()} method for access. * - * @var array => + * @var array */ private static $listOpenTokensBC = [ \T_LIST => \T_LIST, @@ -264,7 +264,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::listTokens()} method for access. * - * @var array => + * @var array */ private static $listTokens = [ \T_LIST => \T_LIST, @@ -277,7 +277,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::namespaceDeclarationClosers()} method for access. * - * @var array => + * @var array */ private static $namespaceDeclarationClosers = [ \T_SEMICOLON => \T_SEMICOLON, @@ -298,7 +298,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::nameTokens()} method for access. * - * @var array => + * @var array */ private static $nameTokens = [ \T_STRING => \T_STRING, @@ -312,7 +312,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::objectOperators()} method for access. * - * @var array => + * @var array */ private static $objectOperators = [ \T_DOUBLE_COLON => \T_DOUBLE_COLON, @@ -325,7 +325,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::ooCanExtend()} method for access. * - * @var array => + * @var array */ private static $ooCanExtend = [ \T_CLASS => \T_CLASS, @@ -338,7 +338,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::ooCanImplement()} method for access. * - * @var array => + * @var array */ private static $ooCanImplement = [ \T_CLASS => \T_CLASS, @@ -353,7 +353,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::ooConstantScopes()} method for access. * - * @var array => + * @var array */ private static $ooConstantScopes = [ \T_CLASS => \T_CLASS, @@ -370,7 +370,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::ooHierarchyKeywords()} method for access. * - * @var array => + * @var array */ private static $ooHierarchyKeywords = [ \T_PARENT => \T_PARENT, @@ -385,7 +385,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::ooPropertyScopes()} method for access. * - * @var array => + * @var array */ private static $ooPropertyScopes = [ \T_CLASS => \T_CLASS, @@ -398,7 +398,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::parameterTypeTokens()} method for access. * - * @var array => + * @var array */ private static $parameterTypeTokens = [ \T_CALLABLE => \T_CALLABLE, @@ -416,7 +416,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::phpOpenTags()} method for access. * - * @var array => + * @var array */ private static $phpOpenTags = [ \T_OPEN_TAG => \T_OPEN_TAG, @@ -428,7 +428,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::propertyModifierKeywords()} method for access. * - * @var array => + * @var array */ private static $propertyModifierKeywords = [ \T_PUBLIC => \T_PUBLIC, @@ -444,7 +444,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::propertyTypeTokens()} method for access. * - * @var array => + * @var array */ private static $propertyTypeTokens = [ \T_CALLABLE => \T_CALLABLE, @@ -462,7 +462,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::returnTypeTokens()} method for access. * - * @var array => + * @var array */ private static $returnTypeTokens = [ \T_CALLABLE => \T_CALLABLE, @@ -481,7 +481,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::shortArrayListOpenTokensBC()} method for access. * - * @var array => + * @var array */ private static $shortArrayListOpenTokensBC = [ \T_OPEN_SHORT_ARRAY => \T_OPEN_SHORT_ARRAY, @@ -494,7 +494,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::shortArrayTokens()} method for access. * - * @var array => + * @var array */ private static $shortArrayTokens = [ \T_OPEN_SHORT_ARRAY => \T_OPEN_SHORT_ARRAY, @@ -508,7 +508,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::shortListTokens()} method for access. * - * @var array => + * @var array */ private static $shortListTokens = [ \T_OPEN_SHORT_ARRAY => \T_OPEN_SHORT_ARRAY, @@ -520,7 +520,7 @@ final class Collections * * @since 1.0.0 Use the {@see Collections::textStringStartTokens()} method for access. * - * @var array => + * @var array */ private static $textStringStartTokens = [ \T_START_HEREDOC => \T_START_HEREDOC, @@ -534,11 +534,11 @@ final class Collections * * @since 1.0.0 * - * @param string $name The name of the method which has been called. - * @param array $args Any arguments passed to the method. - * Unused as none of the methods take arguments. + * @param string $name The name of the method which has been called. + * @param array $args Any arguments passed to the method. + * Unused as none of the methods take arguments. * - * @return array => Token array + * @return array Token array * * @throws \PHPCSUtils\Exceptions\InvalidTokenArray When an invalid token array is requested. */ @@ -592,17 +592,11 @@ final class Collections * * @since 1.0.0 * - * @return array => + * @return array */ public static function arrayOpenTokensBC() { - $tokens = self::$arrayOpenTokensBC; - - if (\version_compare(Helper::getVersion(), '3.7.1', '<=')) { - $tokens[\T_OPEN_SQUARE_BRACKET] = \T_OPEN_SQUARE_BRACKET; - } - - return $tokens; + return self::$arrayOpenTokensBC; } /** @@ -619,18 +613,11 @@ final class Collections * * @since 1.0.0 * - * @return array => + * @return array */ public static function arrayTokensBC() { - $tokens = self::$arrayTokens; - - if (\version_compare(Helper::getVersion(), '3.7.1', '<=')) { - $tokens[\T_OPEN_SQUARE_BRACKET] = \T_OPEN_SQUARE_BRACKET; - $tokens[\T_CLOSE_SQUARE_BRACKET] = \T_CLOSE_SQUARE_BRACKET; - } - - return $tokens; + return self::$arrayTokens; } /** @@ -640,7 +627,7 @@ final class Collections * * @since 1.0.0 * - * @return array => + * @return array */ public static function functionCallTokens() { @@ -669,17 +656,11 @@ final class Collections * * @since 1.0.0 * - * @return array => + * @return array */ public static function listOpenTokensBC() { - $tokens = self::$listOpenTokensBC; - - if (\version_compare(Helper::getVersion(), '3.7.1', '<=')) { - $tokens[\T_OPEN_SQUARE_BRACKET] = \T_OPEN_SQUARE_BRACKET; - } - - return $tokens; + return self::$listOpenTokensBC; } /** @@ -694,18 +675,11 @@ final class Collections * * @since 1.0.0 * - * @return array => + * @return array */ public static function listTokensBC() { - $tokens = self::$listTokens; - - if (\version_compare(Helper::getVersion(), '3.7.1', '<=')) { - $tokens[\T_OPEN_SQUARE_BRACKET] = \T_OPEN_SQUARE_BRACKET; - $tokens[\T_CLOSE_SQUARE_BRACKET] = \T_CLOSE_SQUARE_BRACKET; - } - - return $tokens; + return self::$listTokens; } /** @@ -718,7 +692,7 @@ final class Collections * * @since 1.0.0 * - * @return array => + * @return array */ public static function namespacedNameTokens() { @@ -739,7 +713,7 @@ final class Collections * * @since 1.0.0 * - * @return array => + * @return array */ public static function parameterPassingTokens() { @@ -761,7 +735,7 @@ final class Collections * * @since 1.0.0 * - * @return array => + * @return array */ public static function parameterTypeTokens() { @@ -776,7 +750,7 @@ final class Collections * * @since 1.0.0 * - * @return array => + * @return array */ public static function propertyTypeTokens() { @@ -791,7 +765,7 @@ final class Collections * * @since 1.0.0 * - * @return array => + * @return array */ public static function returnTypeTokens() { @@ -811,17 +785,11 @@ final class Collections * * @since 1.0.0 * - * @return array => + * @return array */ public static function shortArrayListOpenTokensBC() { - $tokens = self::$shortArrayListOpenTokensBC; - - if (\version_compare(Helper::getVersion(), '3.7.1', '<=')) { - $tokens[\T_OPEN_SQUARE_BRACKET] = \T_OPEN_SQUARE_BRACKET; - } - - return $tokens; + return self::$shortArrayListOpenTokensBC; } /** @@ -836,18 +804,11 @@ final class Collections * * @since 1.0.0 * - * @return array => + * @return array */ public static function shortArrayTokensBC() { - $tokens = self::$shortArrayTokens; - - if (\version_compare(Helper::getVersion(), '3.7.1', '<=')) { - $tokens[\T_OPEN_SQUARE_BRACKET] = \T_OPEN_SQUARE_BRACKET; - $tokens[\T_CLOSE_SQUARE_BRACKET] = \T_CLOSE_SQUARE_BRACKET; - } - - return $tokens; + return self::$shortArrayTokens; } /** @@ -862,17 +823,10 @@ final class Collections * * @since 1.0.0 * - * @return array => + * @return array */ public static function shortListTokensBC() { - $tokens = self::$shortListTokens; - - if (\version_compare(Helper::getVersion(), '3.7.1', '<=')) { - $tokens[\T_OPEN_SQUARE_BRACKET] = \T_OPEN_SQUARE_BRACKET; - $tokens[\T_CLOSE_SQUARE_BRACKET] = \T_CLOSE_SQUARE_BRACKET; - } - - return $tokens; + return self::$shortListTokens; } } diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Arrays.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Arrays.php index 3fe7a100..1e228413 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Arrays.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Arrays.php @@ -29,7 +29,7 @@ final class Arrays * * @since 1.0.0 * - * @var array => + * @var array */ private static $doubleArrowTargets = [ \T_DOUBLE_ARROW => \T_DOUBLE_ARROW, @@ -86,15 +86,15 @@ final class Arrays * tokens in an array. * Use with care. * - * @return array|false An array with the token pointers; or `FALSE` if this is not a - * (short) array token or if the opener/closer could not be determined. - * The format of the array return value is: - * ```php - * array( - * 'opener' => integer, // Stack pointer to the array open bracket. - * 'closer' => integer, // Stack pointer to the array close bracket. - * ) - * ``` + * @return array|false An array with the token pointers; or `FALSE` if this is not a + * (short) array token or if the opener/closer could not be determined. + * The format of the array return value is: + * ```php + * array( + * 'opener' => integer, // Stack pointer to the array open bracket. + * 'closer' => integer, // Stack pointer to the array close bracket. + * ) + * ``` */ public static function getOpenClose(File $phpcsFile, $stackPtr, $isShortArray = null) { diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Conditions.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Conditions.php index aba769e3..76f0e885 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Conditions.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Conditions.php @@ -39,12 +39,12 @@ final class Conditions * * @since 1.0.0 * - * @param \PHP_CodeSniffer\Files\File $phpcsFile The file being scanned. - * @param int $stackPtr The position of the token we are checking. - * @param int|string|array $types Optional. The type(s) of tokens to search for. - * @param bool $first Optional. Whether to search for the first (outermost) - * (`true`) or the last (innermost) condition (`false`) of - * the specified type(s). + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file being scanned. + * @param int $stackPtr The position of the token we are checking. + * @param int|string|array $types Optional. The type(s) of tokens to search for. + * @param bool $first Optional. Whether to search for the first (outermost) + * (`true`) or the last (innermost) condition (`false`) of + * the specified type(s). * * @return int|false Integer stack pointer to the condition; or `FALSE` if the token * does not have the condition or has no conditions at all. @@ -103,9 +103,9 @@ final class Conditions * * @since 1.0.0 * - * @param \PHP_CodeSniffer\Files\File $phpcsFile The file being scanned. - * @param int $stackPtr The position of the token we are checking. - * @param int|string|array $types The type(s) of tokens to search for. + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file being scanned. + * @param int $stackPtr The position of the token we are checking. + * @param int|string|array $types The type(s) of tokens to search for. * * @return bool */ @@ -122,9 +122,9 @@ final class Conditions * * @since 1.0.0 * - * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. - * @param int $stackPtr The position of the token we are checking. - * @param int|string|array $types Optional. The type(s) of tokens to search for. + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. + * @param int $stackPtr The position of the token we are checking. + * @param int|string|array $types Optional. The type(s) of tokens to search for. * * @return int|false Integer stack pointer to the condition; or `FALSE` if the token * does not have the condition or has no conditions at all. @@ -142,9 +142,9 @@ final class Conditions * * @since 1.0.0 * - * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. - * @param int $stackPtr The position of the token we are checking. - * @param int|string|array $types Optional. The type(s) of tokens to search for. + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. + * @param int $stackPtr The position of the token we are checking. + * @param int|string|array $types Optional. The type(s) of tokens to search for. * * @return int|false Integer stack pointer to the condition; or `FALSE` if the token * does not have the condition or has no conditions at all. diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/ControlStructures.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/ControlStructures.php index 44bc053d..b343c736 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/ControlStructures.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/ControlStructures.php @@ -199,7 +199,8 @@ final class ControlStructures * @param \PHP_CodeSniffer\Files\File $phpcsFile The file being scanned. * @param int $stackPtr The position of the token we are checking. * - * @return array Array with information about the caught Exception(s). + * @return array> + * Array with information about the caught Exception(s). * The returned array will contain the following information for * each caught exception: * ```php diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/FunctionDeclarations.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/FunctionDeclarations.php index 153bce45..e24bcf27 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/FunctionDeclarations.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/FunctionDeclarations.php @@ -43,7 +43,7 @@ final class FunctionDeclarations * * @since 1.0.0 * - * @var array => + * @var array */ public static $magicFunctions = [ '__autoload' => 'autoload', @@ -59,7 +59,7 @@ final class FunctionDeclarations * * @since 1.0.0 * - * @var array => + * @var array */ public static $magicMethods = [ '__construct' => 'construct', @@ -94,7 +94,7 @@ final class FunctionDeclarations * * @since 1.0.0 * - * @var array => + * @var array */ public static $methodsDoubleUnderscore = [ '__dorequest' => 'SOAPClient', @@ -148,7 +148,6 @@ final class FunctionDeclarations * - Defensive coding against incorrect calls to this method. * - More efficient checking whether a function has a body. * - Support for PHP 8.0 identifier name tokens in return types, cross-version PHP & PHPCS. - * - Support for the PHP 8.2 `true` type. * - The results of this function call are cached during a PHPCS run for faster response times. * * @see \PHP_CodeSniffer\Files\File::getMethodProperties() Original source. @@ -160,7 +159,7 @@ final class FunctionDeclarations * @param int $stackPtr The position in the stack of the function token to * acquire the properties for. * - * @return array Array with information about a function declaration. + * @return array Array with information about a function declaration. * The format of the return value is: * ```php * array( @@ -248,12 +247,6 @@ final class FunctionDeclarations $hasBody = false; $returnTypeTokens = Collections::returnTypeTokens(); - /* - * BC PHPCS < 3.x.x: The union type separator is not (yet) retokenized correctly - * for union types containing the `true` type. - */ - $returnTypeTokens[\T_BITWISE_OR] = \T_BITWISE_OR; - $parenthesisCloser = null; if (isset($tokens[$stackPtr]['parenthesis_closer']) === true) { $parenthesisCloser = $tokens[$stackPtr]['parenthesis_closer']; @@ -367,7 +360,6 @@ final class FunctionDeclarations * - More efficient and more stable looping of the default value. * - Clearer exception message when a non-closure use token was passed to the function. * - Support for PHP 8.0 identifier name tokens in parameter types, cross-version PHP & PHPCS. - * - Support for the PHP 8.2 `true` type. * - The results of this function call are cached during a PHPCS run for faster response times. * * @see \PHP_CodeSniffer\Files\File::getMethodParameters() Original source. @@ -379,7 +371,7 @@ final class FunctionDeclarations * @param int $stackPtr The position in the stack of the function token * to acquire the parameters for. * - * @return array + * @return array> * * @throws \PHP_CodeSniffer\Exceptions\RuntimeException If the specified $stackPtr is not of * type `T_FUNCTION`, `T_CLOSURE` or `T_USE`, @@ -447,12 +439,6 @@ final class FunctionDeclarations $parameterTypeTokens = Collections::parameterTypeTokens(); - /* - * BC PHPCS < 3.x.x: The union type separator is not (yet) retokenized correctly - * for union types containing the `true` type. - */ - $parameterTypeTokens[\T_BITWISE_OR] = \T_BITWISE_OR; - for ($i = $paramStart; $i <= $closer; $i++) { if (isset($parameterTypeTokens[$tokens[$i]['code']]) === true /* diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Lists.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Lists.php index baf2c02a..167d6508 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Lists.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Lists.php @@ -33,7 +33,7 @@ final class Lists * * @since 1.0.0 * - * @var array + * @var array */ private static $listItemDefaults = [ 'raw' => '', @@ -87,15 +87,15 @@ final class Lists * tokens in a list. * Use with care. * - * @return array|false An array with the token pointers; or `FALSE` if this is not a (short) list - * token or if the opener/closer could not be determined. - * The format of the array return value is: - * ```php - * array( - * 'opener' => integer, // Stack pointer to the list open bracket. - * 'closer' => integer, // Stack pointer to the list close bracket. - * ) - * ``` + * @return array|false An array with the token pointers; or `FALSE` if this is not a (short) list + * token or if the opener/closer could not be determined. + * The format of the array return value is: + * ```php + * array( + * 'opener' => integer, // Stack pointer to the list open bracket. + * 'closer' => integer, // Stack pointer to the list close bracket. + * ) + * ``` */ public static function getOpenClose(File $phpcsFile, $stackPtr, $isShortList = null) { @@ -190,7 +190,8 @@ final class Lists * @param int $stackPtr The position in the stack of the function token * to acquire the parameters for. * - * @return array An array with information on each assignment made, including skipped assignments (empty), + * @return array> + * An array with information on each assignment made, including skipped assignments (empty), * or an empty array if no assignments are made at all (fatal error in PHP >= 7.0). * * @throws \PHP_CodeSniffer\Exceptions\RuntimeException If the specified $stackPtr is not of diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/MessageHelper.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/MessageHelper.php index 388f2a09..eb7c1505 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/MessageHelper.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/MessageHelper.php @@ -34,7 +34,7 @@ final class MessageHelper * Defaults to true (error). * @param string $code The error code for the message. * Defaults to 'Found'. - * @param array $data Optional input for the data replacements. + * @param scalar[] $data Optional input for the data replacements. * @param int $severity Optional. Severity level. Defaults to 0 which will * translate to the PHPCS default severity level. * @@ -70,7 +70,7 @@ final class MessageHelper * Defaults to true (error). * @param string $code The error code for the message. * Defaults to 'Found'. - * @param array $data Optional input for the data replacements. + * @param scalar[] $data Optional input for the data replacements. * @param int $severity Optional. Severity level. Defaults to 0 which will * translate to the PHPCS default severity level. * diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Numbers.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Numbers.php index 053643d7..69ec4ef0 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Numbers.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Numbers.php @@ -106,7 +106,7 @@ final class Numbers * @param \PHP_CodeSniffer\Files\File $phpcsFile The file being scanned. * @param int $stackPtr The position of a T_LNUMBER or T_DNUMBER token. * - * @return array An array with information about the number. + * @return array An array with information about the number. * The format of the array return value is: * ```php * array( diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/ObjectDeclarations.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/ObjectDeclarations.php index e284224c..cb45bd4f 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/ObjectDeclarations.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/ObjectDeclarations.php @@ -147,7 +147,7 @@ final class ObjectDeclarations * @param int $stackPtr The position in the stack of the `T_CLASS` * token to acquire the properties for. * - * @return array Array with implementation properties of a class. + * @return array Array with implementation properties of a class. * The format of the return value is: * ```php * array( @@ -272,8 +272,8 @@ final class ObjectDeclarations * @param \PHP_CodeSniffer\Files\File $phpcsFile The file being scanned. * @param int $stackPtr The stack position of the class or enum token. * - * @return array|false Array with names of the implemented interfaces or `FALSE` on - * error or if there are no implemented interface names. + * @return string[]|false Array with names of the implemented interfaces or `FALSE` on + * error or if there are no implemented interface names. */ public static function findImplementedInterfaceNames(File $phpcsFile, $stackPtr) { @@ -290,8 +290,8 @@ final class ObjectDeclarations * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. * @param int $stackPtr The stack position of the interface keyword. * - * @return array|false Array with names of the extended interfaces or `FALSE` on - * error or if there are no extended interface names. + * @return string[]|false Array with names of the extended interfaces or `FALSE` on + * error or if there are no extended interface names. */ public static function findExtendedInterfaceNames(File $phpcsFile, $stackPtr) { @@ -309,16 +309,16 @@ final class ObjectDeclarations * * @since 1.0.0 * - * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. - * @param int $stackPtr The stack position of the - * class/interface declaration keyword. - * @param int $keyword The token constant for the keyword to examine. - * Either `T_EXTENDS` or `T_IMPLEMENTS`. - * @param array $allowedFor Array of OO types for which use of the keyword - * is allowed. + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. + * @param int $stackPtr The stack position of the + * class/interface declaration keyword. + * @param int $keyword The token constant for the keyword to examine. + * Either `T_EXTENDS` or `T_IMPLEMENTS`. + * @param array $allowedFor Array of OO types for which use of the keyword + * is allowed. * - * @return array|false Returns an array of names or `FALSE` on error or when the object - * being declared does not extend/implement another object. + * @return string[]|false Returns an array of names or `FALSE` on error or when the object + * being declared does not extend/implement another object. */ private static function findNames(File $phpcsFile, $stackPtr, $keyword, array $allowedFor) { diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Operators.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Operators.php index ae155c13..562440fe 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Operators.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Operators.php @@ -35,7 +35,7 @@ final class Operators * * @since 1.0.0 * - * @var array => + * @var array Note: value is irrelevant, only key is used. */ private static $extraUnaryIndicators = [ \T_STRING_CONCAT => true, diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Parentheses.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Parentheses.php index 2e7384e0..998b64f9 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Parentheses.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Parentheses.php @@ -34,7 +34,7 @@ final class Parentheses * * @since 1.0.0 * - * @var array => + * @var array */ private static $extraParenthesesOwners = [ \T_ISSET => \T_ISSET, @@ -95,10 +95,10 @@ final class Parentheses * * @since 1.0.0 * - * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. - * @param int $stackPtr The position of `T_OPEN/CLOSE_PARENTHESIS` token. - * @param int|string|array $validOwners Array of token constants for the owners - * which should be considered valid. + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. + * @param int $stackPtr The position of `T_OPEN/CLOSE_PARENTHESIS` token. + * @param int|string|array $validOwners Array of token constants for the owners + * which should be considered valid. * * @return bool `TRUE` if the owner is within the list of `$validOwners`; `FALSE` if not and * if the parenthesis does not have a (direct) owner. @@ -121,10 +121,10 @@ final class Parentheses * * @since 1.0.0 * - * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. - * @param int $stackPtr The position of the token we are checking. - * @param int|string|array $validOwners Array of token constants for the owners - * which should be considered valid. + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. + * @param int $stackPtr The position of the token we are checking. + * @param int|string|array $validOwners Array of token constants for the owners + * which should be considered valid. * * @return bool */ @@ -143,10 +143,10 @@ final class Parentheses * * @since 1.0.0 * - * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. - * @param int $stackPtr The position of the token we are checking. - * @param int|string|array $validOwners Array of token constants for the owners - * which should be considered valid. + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. + * @param int $stackPtr The position of the token we are checking. + * @param int|string|array $validOwners Array of token constants for the owners + * which should be considered valid. * * @return int|false Integer stack pointer to the parentheses opener; or `FALSE` if the token * does not have parentheses owned by any of the valid owners or if @@ -167,10 +167,10 @@ final class Parentheses * * @since 1.0.0 * - * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. - * @param int $stackPtr The position of the token we are checking. - * @param int|string|array $validOwners Array of token constants for the owners - * which should be considered valid. + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. + * @param int $stackPtr The position of the token we are checking. + * @param int|string|array $validOwners Array of token constants for the owners + * which should be considered valid. * * @return int|false Integer stack pointer to the parentheses closer; or `FALSE` if the token * does not have parentheses owned by any of the valid owners or if @@ -197,10 +197,10 @@ final class Parentheses * * @since 1.0.0 * - * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. - * @param int $stackPtr The position of the token we are checking. - * @param int|string|array $validOwners Array of token constants for the owners - * which should be considered valid. + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. + * @param int $stackPtr The position of the token we are checking. + * @param int|string|array $validOwners Array of token constants for the owners + * which should be considered valid. * * @return int|false Integer stack pointer to the parentheses owner; or `FALSE` if the token * does not have parentheses owned by any of the valid owners or if @@ -226,10 +226,10 @@ final class Parentheses * * @since 1.0.0 * - * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. - * @param int $stackPtr The position of the token we are checking. - * @param int|string|array $validOwners Array of token constants for the owners - * which should be considered valid. + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. + * @param int $stackPtr The position of the token we are checking. + * @param int|string|array $validOwners Array of token constants for the owners + * which should be considered valid. * * @return int|false Integer stack pointer to the parentheses opener; or `FALSE` if the token * does not have parentheses owned by any of the valid owners or if @@ -250,10 +250,10 @@ final class Parentheses * * @since 1.0.0 * - * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. - * @param int $stackPtr The position of the token we are checking. - * @param int|string|array $validOwners Array of token constants for the owners - * which should be considered valid. + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. + * @param int $stackPtr The position of the token we are checking. + * @param int|string|array $validOwners Array of token constants for the owners + * which should be considered valid. * * @return int|false Integer stack pointer to the parentheses closer; or `FALSE` if the token * does not have parentheses owned by any of the valid owners or if @@ -280,10 +280,10 @@ final class Parentheses * * @since 1.0.0 * - * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. - * @param int $stackPtr The position of the token we are checking. - * @param int|string|array $validOwners Array of token constants for the owners - * which should be considered valid. + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. + * @param int $stackPtr The position of the token we are checking. + * @param int|string|array $validOwners Array of token constants for the owners + * which should be considered valid. * * @return int|false Integer stack pointer to the parentheses owner; or `FALSE` if the token * does not have parentheses owned by any of the valid owners or if @@ -305,11 +305,11 @@ final class Parentheses * * @since 1.0.0 * - * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. - * @param int $stackPtr The position in the stack of the - * token to verify. - * @param int|string|array $validOwners Array of token constants for the owners - * which should be considered valid. + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. + * @param int $stackPtr The position in the stack of the + * token to verify. + * @param int|string|array $validOwners Array of token constants for the owners + * which should be considered valid. * * @return int|false Integer stack pointer to the valid parentheses owner; or `FALSE` if * the token was not wrapped in parentheses or if the outermost set @@ -333,11 +333,11 @@ final class Parentheses * * @since 1.0.0 * - * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. - * @param int $stackPtr The position in the stack of the - * token to verify. - * @param int|string|array $validOwners Array of token constants for the owners - * which should be considered valid. + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. + * @param int $stackPtr The position in the stack of the + * token to verify. + * @param int|string|array $validOwners Array of token constants for the owners + * which should be considered valid. * * @return int|false Integer stack pointer to the valid parentheses owner; or `FALSE` if * the token was not wrapped in parentheses or if the innermost set @@ -363,13 +363,13 @@ final class Parentheses * * @since 1.0.0 * - * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. - * @param int $stackPtr The position of the token we are checking. - * @param int|string|array $validOwners Optional. Array of token constants for the owners - * which should be considered valid. - * @param bool $reverse Optional. Whether to search for the first/outermost - * (`false`) or the last/innermost (`true`) set of - * parentheses with the specified owner(s). + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. + * @param int $stackPtr The position of the token we are checking. + * @param int|string|array $validOwners Optional. Array of token constants for the owners + * which should be considered valid. + * @param bool $reverse Optional. Whether to search for the first/outermost + * (`false`) or the last/innermost (`true`) set of + * parentheses with the specified owner(s). * * @return int|false Integer stack pointer to the parentheses opener; or `FALSE` if the token * does not have parentheses owned by any of the valid owners or if diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/PassedParameters.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/PassedParameters.php index f73ee8c4..35f1f391 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/PassedParameters.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/PassedParameters.php @@ -33,7 +33,7 @@ final class PassedParameters * * @since 1.0.0 * - * @var array => + * @var array */ private static $callParsingStopPoints = [ \T_COMMA => \T_COMMA, @@ -170,7 +170,8 @@ final class PassedParameters * Efficiency tweak for when this has already been established, * Use with EXTREME care. * - * @return array A multi-dimentional array with information on each parameter/array item. + * @return array> + * A multi-dimentional array with information on each parameter/array item. * The information gathered about each parameter/array item is in the following format: * ```php * 1 => array( @@ -379,11 +380,11 @@ final class PassedParameters * always pass both the offset as well as the parameter * name when examining function calls. * - * @return array|false Array with information on the parameter/array item at the specified offset, - * or with the specified name. - * Or `FALSE` if the specified parameter/array item is not found. - * See {@see PassedParameters::getParameters()} for the format of the returned - * (single-dimensional) array. + * @return array|false Array with information on the parameter/array item at the specified + * offset, or with the specified name. + * Or `FALSE` if the specified parameter/array item is not found. + * See {@see PassedParameters::getParameters()} for the format of the + * returned (single-dimensional) array. * * @throws \PHP_CodeSniffer\Exceptions\RuntimeException If the token passed is not one of the * accepted types or doesn't exist. @@ -452,20 +453,23 @@ final class PassedParameters * * @since 1.0.0 * - * @param array $parameters The output of a previous call to {@see PassedParameters::getParameters()}. - * @param int $paramOffset The 1-based index position of the parameter to retrieve. - * @param string|string[] $paramNames Either the name of the target parameter to retrieve - * as a string or an array of names for the same target parameter. - * An array of names is supported to allow for functions - * for which the parameter names have undergone name - * changes over time. - * The name will take precedence over the offset. + * @param array> $parameters The output of a previous call to + * {@see PassedParameters::getParameters()}. + * @param int $paramOffset The 1-based index position of the parameter + * to retrieve. + * @param string|string[] $paramNames Either the name of the target parameter to retrieve + * as a string or an array of names for the same target + * parameter. + * An array of names is supported to allow for functions + * for which the parameter names have undergone name + * changes over time. + * The name will take precedence over the offset. * - * @return array|false Array with information on the parameter at the specified offset, - * or with the specified name. - * Or `FALSE` if the specified parameter is not found. - * See {@see PassedParameters::getParameters()} for the format of the returned - * (single-dimensional) array. + * @return array|false Array with information on the parameter at the specified offset, + * or with the specified name. + * Or `FALSE` if the specified parameter is not found. + * See {@see PassedParameters::getParameters()} for the format of the + * returned (single-dimensional) array. * * @throws \PHP_CodeSniffer\Exceptions\RuntimeException If the `$paramNames` parameter is not passed * and the requested parameter was not passed diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Scopes.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Scopes.php index 32947c9e..99011fba 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Scopes.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Scopes.php @@ -30,11 +30,11 @@ final class Scopes * * @since 1.0.0 * - * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. - * @param int $stackPtr The position in the stack of the - * token to verify. - * @param int|string|array $validScopes Array of token constants representing - * the scopes considered valid. + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. + * @param int $stackPtr The position in the stack of the + * token to verify. + * @param int|string|array $validScopes Array of token constants representing + * the scopes considered valid. * * @return int|false Integer stack pointer to the valid direct scope; or `FALSE` if * no valid direct scope was found. diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/UseStatements.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/UseStatements.php index 4e917322..3fdf9d66 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/UseStatements.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/UseStatements.php @@ -156,7 +156,8 @@ final class UseStatements * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. * @param int $stackPtr The position in the stack of the `T_USE` token. * - * @return array A multi-level array containing information about the use statement. + * @return array> + * A multi-level array containing information about the use statement. * The first level is `'name'`, `'function'` and `'const'`. These keys will always exist. * If any statements are found for any of these categories, the second level * will contain the alias/name as the key and the full original use name as the @@ -358,16 +359,18 @@ final class UseStatements * * @since 1.0.0 * - * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. - * @param int $stackPtr The position in the stack of the `T_USE` token. - * @param array $previousUseStatements The import `use` statements collected so far. - * This should be either the output of a - * previous call to this method or the output of - * an earlier call to the - * {@see UseStatements::splitImportUseStatement()} - * method. + * @param \PHP_CodeSniffer\Files\File $phpcsFile The file where this token was found. + * @param int $stackPtr The position in the stack of the + * `T_USE` token. + * @param array> $previousUseStatements The import `use` statements collected so far. + * This should be either the output of a + * previous call to this method or the output of + * an earlier call to the + * {@see UseStatements::splitImportUseStatement()} + * method. * - * @return array A multi-level array containing information about the current `use` statement combined with + * @return array> + * A multi-level array containing information about the current `use` statement combined with * the previously collected `use` statement information. * See {@see UseStatements::splitImportUseStatement()} for more details about the array format. */ @@ -393,19 +396,20 @@ final class UseStatements * * @since 1.0.0 * - * @param array $previousUseStatements The import `use` statements collected so far. - * This should be either the output of a - * previous call to this method or the output of - * an earlier call to the - * {@see UseStatements::splitImportUseStatement()} - * method. - * @param array $currentUseStatement The parsed import `use` statements to merge with - * the previously collected use statements. - * This should be the output of a call to the - * {@see UseStatements::splitImportUseStatement()} - * method. + * @param array> $previousUseStatements The import `use` statements collected so far. + * This should be either the output of a + * previous call to this method or the output of + * an earlier call to the + * {@see UseStatements::splitImportUseStatement()} + * method. + * @param array> $currentUseStatement The parsed import `use` statements to merge with + * the previously collected use statements. + * This should be the output of a call to the + * {@see UseStatements::splitImportUseStatement()} + * method. * - * @return array A multi-level array containing information about the current `use` statement combined with + * @return array> + * A multi-level array containing information about the current `use` statement combined with * the previously collected `use` statement information. * See {@see UseStatements::splitImportUseStatement()} for more details about the array format. */ diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Variables.php b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Variables.php index 4c92e1ed..a97135f4 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Variables.php +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/Variables.php @@ -41,7 +41,7 @@ final class Variables * * @since 1.0.0 * - * @var array => + * @var array */ public static $phpReservedVars = [ '_SERVER' => true, @@ -82,7 +82,6 @@ final class Variables * other non-property variables passed to the method. * - Defensive coding against incorrect calls to this method. * - Support PHP 8.0 identifier name tokens in property types, cross-version PHP & PHPCS. - * - Support for the PHP 8.2 `true` type. * - The results of this function call are cached during a PHPCS run for faster response times. * * @see \PHP_CodeSniffer\Files\File::getMemberProperties() Original source. @@ -94,7 +93,7 @@ final class Variables * @param int $stackPtr The position in the stack of the `T_VARIABLE` token * to acquire the properties for. * - * @return array Array with information about the class member variable. + * @return array Array with information about the class member variable. * The format of the return value is: * ```php * array( @@ -183,12 +182,6 @@ final class Variables $nullableType = false; $propertyTypeTokens = Collections::propertyTypeTokens(); - /* - * BC PHPCS < 3.x.x: The union type separator is not (yet) retokenized correctly - * for union types containing the `true` type. - */ - $propertyTypeTokens[\T_BITWISE_OR] = \T_BITWISE_OR; - if ($i < $stackPtr) { // We've found a type. for ($i; $i < $stackPtr; $i++) { diff --git a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/ruleset.xml b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/ruleset.xml index f4365516..eefc6dbb 100644 --- a/vendor/phpcsstandards/phpcsutils/PHPCSUtils/ruleset.xml +++ b/vendor/phpcsstandards/phpcsutils/PHPCSUtils/ruleset.xml @@ -1,4 +1,4 @@ - + Utility methods for external PHPCS standards. diff --git a/vendor/phpcsstandards/phpcsutils/README.md b/vendor/phpcsstandards/phpcsutils/README.md index 20d2b200..430855ea 100644 --- a/vendor/phpcsstandards/phpcsutils/README.md +++ b/vendor/phpcsstandards/phpcsutils/README.md @@ -8,13 +8,14 @@ [![Latest Unstable Version](https://img.shields.io/badge/unstable-dev--develop-e68718.svg?maxAge=2419200)](https://packagist.org/packages/phpcsstandards/phpcsutils#dev-develop) [![Last Commit to Unstable](https://img.shields.io/github/last-commit/PHPCSStandards/PHPCSUtils/develop.svg)](https://github.com/PHPCSStandards/PHPCSUtils/commits/develop) -[![Minimum PHP Version](https://img.shields.io/packagist/php-v/phpcsstandards/phpcsutils.svg?maxAge=3600)][phpcsutils-packagist] +[![Docs website](https://github.com/PHPCSStandards/PHPCSUtils/actions/workflows/update-docs.yml/badge.svg)][phpcsutils-web] [![CS Build Status](https://github.com/PHPCSStandards/PHPCSUtils/actions/workflows/basics.yml/badge.svg?branch=develop)](https://github.com/PHPCSStandards/PHPCSUtils/actions/workflows/basics.yml) [![Test Build Status](https://github.com/PHPCSStandards/PHPCSUtils/actions/workflows/test.yml/badge.svg?branch=develop)][phpcsutils-tests-gha] -[![Tested on PHP 5.4 to 8.2](https://img.shields.io/badge/tested%20on-PHP%205.4%20|%205.5%20|%205.6%20|%207.0%20|%207.1%20|%207.2%20|%207.3%20|%207.4%20|%208.0%20|%208.1%20|%208.2-brightgreen.svg?maxAge=2419200)][phpcsutils-tests-gha] [![Coverage Status](https://coveralls.io/repos/github/PHPCSStandards/PHPCSUtils/badge.svg?branch=develop)](https://coveralls.io/github/PHPCSStandards/PHPCSUtils?branch=develop) -[![Docs website](https://github.com/PHPCSStandards/PHPCSUtils/actions/workflows/update-docs.yml/badge.svg)][phpcsutils-web] +[![Minimum PHP Version](https://img.shields.io/packagist/php-v/phpcsstandards/phpcsutils.svg?maxAge=3600)][phpcsutils-packagist] +[![Tested on PHP 5.4 to 8.3](https://img.shields.io/badge/tested%20on-PHP%205.4%20|%205.5%20|%205.6%20|%207.0%20|%207.1%20|%207.2%20|%207.3%20|%207.4%20|%208.0%20|%208.1%20|%208.2%20|%208.3-brightgreen.svg?maxAge=2419200)][phpcsutils-tests-gha] + [![License: LGPLv3](https://poser.pugx.org/phpcsstandards/phpcsutils/license)](https://github.com/PHPCSStandards/PHPCSUtils/blob/stable/LICENSE) ![Awesome](https://img.shields.io/badge/awesome%3F-yes!-brightgreen.svg) @@ -45,7 +46,7 @@ Whether you need to split an `array` into the individual items, are trying to de Includes improved versions of the PHPCS native utility functions and plenty of new utility functions. -These functions are compatible with PHPCS 3.7.1 up to PHPCS `master`. +These functions are compatible with PHPCS 3.8.0 up to PHPCS `master`. ### A collection of static properties and methods for often-used token groups @@ -65,7 +66,7 @@ Supports PHPUnit 4.x up to 9.x. Normally to use the latest version of PHP_CodeSniffer native utility functions, you would have to raise the minimum requirements of your external PHPCS standard. -Now you won't have to anymore. This package allows you to use the latest version of those utility functions in all PHP_CodeSniffer versions from PHPCS 3.7.1 and up. +Now you won't have to anymore. This package allows you to use the latest version of those utility functions in all PHP_CodeSniffer versions from PHPCS 3.8.0 and up. ### Fully documented @@ -77,7 +78,7 @@ To see detailed information about all the available abstract sniffs, utility fun ## Minimum Requirements * PHP 5.4 or higher. -* [PHP_CodeSniffer] 3.7.1+. +* [PHP_CodeSniffer] 3.8.0+. * Recommended PHP extensions for optimal functionality: - PCRE with Unicode support (normally enabled by default) @@ -127,7 +128,7 @@ To use a non-Composer based installation for your sniff development environment, Your installation instructions for a non-Composer based installation will probably look similar to this: -> * Install [PHP_CodeSniffer] via [your preferred method](https://github.com/squizlabs/PHP_CodeSniffer#installation). +> * Install [PHP_CodeSniffer] via [your preferred method](https://github.com/PHPCSStandards/PHP_CodeSniffer#installation). > * Register the path to PHPCS in your system `$PATH` environment variable to make the `phpcs` command available from anywhere in your file system. > * Download the \[latest _YourStandardName_ release\] and unzip/untar it into an arbitrary directory. > You can also choose to clone the repository using git. @@ -164,11 +165,11 @@ For things to continue working when you add PHPCSUtils to your standard, you nee To support non-Composer based installs for running your sniff unit tests, you will need to adjust the PHPUnit `bootstrap.php` file to allow for passing an environment variable pointing to your PHPCSUtils installation.
- Example bootstrap code using a PHPCSUTILS_DIR environment variable + Example bootstrap code using a PHPCSUtils_DIR environment variable ```php // Get the PHPCS dir from an environment variable. -$phpcsUtilDir = getenv('PHPCSUTILS_DIR'); +$phpcsUtilDir = getenv('PHPCSUtils_DIR'); // This may be a Composer install. if ($phpcsUtilDir === false && file_exists(__DIR__ . '/vendor/autoload.php')) { @@ -191,7 +192,7 @@ if ($phpcsUtilDir === false && file_exists(__DIR__ . '/vendor/autoload.php')) { echo 'Uh oh... can\'t find PHPCSUtils. If you use Composer, please run `composer install`. -Otherwise, make sure you set a `PHPCSUTILS_DIR` environment variable in your phpunit.xml file +Otherwise, make sure you set a `PHPCSUtils_DIR` environment variable in your phpunit.xml file pointing to the PHPCS directory. '; @@ -208,7 +209,7 @@ Once that's done, you will need to make a small tweak to your own dev environmen ```xml - + ``` @@ -287,7 +288,7 @@ If you are unsure whether the changes you are proposing would be welcome, please This code is released under the [GNU Lesser General Public License (LGPLv3)](LICENSE). -[PHP_CodeSniffer]: https://github.com/squizlabs/PHP_CodeSniffer +[PHP_CodeSniffer]: https://github.com/PHPCSStandards/PHP_CodeSniffer [Composer PHPCS plugin]: https://github.com/PHPCSStandards/composer-installer [phpcsutils-repo]: https://github.com/PHPCSStandards/PHPCSUtils [phpcsutils-web]: https://phpcsutils.com/ diff --git a/vendor/phpcsstandards/phpcsutils/composer.json b/vendor/phpcsstandards/phpcsutils/composer.json index 8c0e8d45..bd5c4ae0 100644 --- a/vendor/phpcsstandards/phpcsutils/composer.json +++ b/vendor/phpcsstandards/phpcsutils/composer.json @@ -19,11 +19,12 @@ "support" : { "issues" : "https://github.com/PHPCSStandards/PHPCSUtils/issues", "source" : "https://github.com/PHPCSStandards/PHPCSUtils", - "docs" : "https://phpcsutils.com/" + "docs" : "https://phpcsutils.com/", + "security": "https://github.com/PHPCSStandards/PHPCSUtils/security/policy" }, "require" : { "php" : ">=5.4", - "squizlabs/php_codesniffer" : "^3.7.1 || 4.0.x-dev@dev", + "squizlabs/php_codesniffer" : "^3.8.0 || 4.0.x-dev@dev", "dealerdirect/phpcodesniffer-composer-installer" : "^0.4.1 || ^0.5 || ^0.6.2 || ^0.7 || ^1.0" }, "require-dev" : { @@ -31,7 +32,7 @@ "phpcsstandards/phpcsdevcs": "^1.1.6", "php-parallel-lint/php-parallel-lint": "^1.3.2", "php-parallel-lint/php-console-highlighter": "^1.0", - "yoast/phpunit-polyfills": "^1.0.5 || ^2.0.0" + "yoast/phpunit-polyfills": "^1.1.0 || ^2.0.0" }, "minimum-stability": "dev", "prefer-stable": true, diff --git a/vendor/phpunit/php-code-coverage/ChangeLog-10.1.md b/vendor/phpunit/php-code-coverage/ChangeLog-10.1.md index 1098364b..62e3eae3 100644 --- a/vendor/phpunit/php-code-coverage/ChangeLog-10.1.md +++ b/vendor/phpunit/php-code-coverage/ChangeLog-10.1.md @@ -2,6 +2,30 @@ All notable changes are documented in this file using the [Keep a CHANGELOG](http://keepachangelog.com/) principles. +## [10.1.10] - 2023-12-11 + +### Fixed + +* [#1023](https://github.com/sebastianbergmann/php-code-coverage/issues/1023): Branch Coverage and Path Coverage are not correctly reported for traits + +## [10.1.9] - 2023-11-23 + +### Fixed + +* [#1020](https://github.com/sebastianbergmann/php-code-coverage/issues/1020): Single line method is ignored + +## [10.1.8] - 2023-11-15 + +### Fixed + +* [#1018](https://github.com/sebastianbergmann/php-code-coverage/issues/1018): Interface methods are not ignored when their signature is split over multiple lines + +## [10.1.7] - 2023-10-04 + +### Fixed + +* [#1014](https://github.com/sebastianbergmann/php-code-coverage/issues/1014): Incorrect statement count in coverage report for constructor property promotion + ## [10.1.6] - 2023-09-19 ### Fixed @@ -53,6 +77,10 @@ All notable changes are documented in this file using the [Keep a CHANGELOG](htt * The `SebastianBergmann\CodeCoverage\Filter::includeDirectory()`, `SebastianBergmann\CodeCoverage\Filter::excludeDirectory()`, and `SebastianBergmann\CodeCoverage\Filter::excludeFile()` methods are now deprecated +[10.1.10]: https://github.com/sebastianbergmann/php-code-coverage/compare/10.1.9...10.1.10 +[10.1.9]: https://github.com/sebastianbergmann/php-code-coverage/compare/10.1.8...10.1.9 +[10.1.8]: https://github.com/sebastianbergmann/php-code-coverage/compare/10.1.7...10.1.8 +[10.1.7]: https://github.com/sebastianbergmann/php-code-coverage/compare/10.1.6...10.1.7 [10.1.6]: https://github.com/sebastianbergmann/php-code-coverage/compare/10.1.5...10.1.6 [10.1.5]: https://github.com/sebastianbergmann/php-code-coverage/compare/10.1.4...10.1.5 [10.1.4]: https://github.com/sebastianbergmann/php-code-coverage/compare/10.1.3...10.1.4 diff --git a/vendor/phpunit/php-code-coverage/src/Data/RawCodeCoverageData.php b/vendor/phpunit/php-code-coverage/src/Data/RawCodeCoverageData.php index 0d91745f..da7522df 100644 --- a/vendor/phpunit/php-code-coverage/src/Data/RawCodeCoverageData.php +++ b/vendor/phpunit/php-code-coverage/src/Data/RawCodeCoverageData.php @@ -19,7 +19,10 @@ use function explode; use function file_get_contents; use function in_array; use function is_file; +use function preg_replace; use function range; +use function str_ends_with; +use function str_starts_with; use function trim; use SebastianBergmann\CodeCoverage\Driver\Driver; use SebastianBergmann\CodeCoverage\StaticAnalysis\FileAnalyser; @@ -65,6 +68,15 @@ final class RawCodeCoverageData $functionCoverage = []; foreach ($rawCoverage as $file => $fileCoverageData) { + // Xdebug annotates the function name of traits, strip that off + foreach ($fileCoverageData['functions'] as $existingKey => $data) { + if (str_ends_with($existingKey, '}') && !str_starts_with($existingKey, '{')) { // don't want to catch {main} + $newKey = preg_replace('/\{.*}$/', '', $existingKey); + $fileCoverageData['functions'][$newKey] = $data; + unset($fileCoverageData['functions'][$existingKey]); + } + } + $lineCoverage[$file] = $fileCoverageData['lines']; $functionCoverage[$file] = $fileCoverageData['functions']; } diff --git a/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/css/style.css b/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/css/style.css index 2e3ece54..04ebcd89 100644 --- a/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/css/style.css +++ b/vendor/phpunit/php-code-coverage/src/Report/Html/Renderer/Template/css/style.css @@ -120,7 +120,7 @@ svg text { .scrollbox { height:245px; - overflow-x:hidden; + overflow-x:scroll; overflow-y:scroll; } diff --git a/vendor/phpunit/php-code-coverage/src/StaticAnalysis/ExecutableLinesFindingVisitor.php b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/ExecutableLinesFindingVisitor.php index 4ce6e436..54824314 100644 --- a/vendor/phpunit/php-code-coverage/src/StaticAnalysis/ExecutableLinesFindingVisitor.php +++ b/vendor/phpunit/php-code-coverage/src/StaticAnalysis/ExecutableLinesFindingVisitor.php @@ -128,6 +128,20 @@ final class ExecutableLinesFindingVisitor extends NodeVisitorAbstract $node instanceof Node\Stmt\ClassMethod || $node instanceof Node\Expr\Closure || $node instanceof Node\Stmt\Trait_) { + if ($node instanceof Node\Stmt\Function_ || $node instanceof Node\Stmt\ClassMethod) { + $unsets = []; + + foreach ($node->getParams() as $param) { + foreach (range($param->getStartLine(), $param->getEndLine()) as $line) { + $unsets[$line] = true; + } + } + + unset($unsets[$node->getEndLine()]); + + $this->unsets += $unsets; + } + $isConcreteClassLike = $node instanceof Node\Stmt\Enum_ || $node instanceof Node\Stmt\Class_ || $node instanceof Node\Stmt\Trait_; if (null !== $node->stmts) { @@ -161,7 +175,7 @@ final class ExecutableLinesFindingVisitor extends NodeVisitorAbstract ); if ($hasEmptyBody) { - if ($node->getEndLine() === $node->getStartLine()) { + if ($node->getEndLine() === $node->getStartLine() && isset($this->executableLinesGroupedByBranch[$node->getStartLine()])) { return; } diff --git a/vendor/phpunit/php-code-coverage/src/Version.php b/vendor/phpunit/php-code-coverage/src/Version.php index 8e4a03d0..8ad93a04 100644 --- a/vendor/phpunit/php-code-coverage/src/Version.php +++ b/vendor/phpunit/php-code-coverage/src/Version.php @@ -19,7 +19,7 @@ final class Version public static function id(): string { if (self::$version === '') { - self::$version = (new VersionId('10.1.5', dirname(__DIR__)))->asString(); + self::$version = (new VersionId('10.1.10', dirname(__DIR__)))->asString(); } return self::$version; diff --git a/vendor/phpunit/phpunit/.phpstorm.meta.php b/vendor/phpunit/phpunit/.phpstorm.meta.php index b69ff789..496a943e 100644 --- a/vendor/phpunit/phpunit/.phpstorm.meta.php +++ b/vendor/phpunit/phpunit/.phpstorm.meta.php @@ -2,12 +2,17 @@ namespace PHPSTORM_META { override( - \PHPUnit\Framework\TestCase::createMock(0), + \PHPUnit\Framework\TestCase::createStub(0), map([""=>"$0"]) ); override( - \PHPUnit\Framework\TestCase::createStub(0), + \PHPUnit\Framework\TestCase::createConfiguredStub(0), + map([""=>"$0"]) + ); + + override( + \PHPUnit\Framework\TestCase::createMock(0), map([""=>"$0"]) ); diff --git a/vendor/phpunit/phpunit/ChangeLog-10.0.md b/vendor/phpunit/phpunit/ChangeLog-10.0.md deleted file mode 100644 index 6e748bdf..00000000 --- a/vendor/phpunit/phpunit/ChangeLog-10.0.md +++ /dev/null @@ -1,126 +0,0 @@ -# Changes in PHPUnit 10.0 - -All notable changes of the PHPUnit 10.0 release series are documented in this file using the [Keep a CHANGELOG](https://keepachangelog.com/) principles. - -## [10.0.0] - 2023-02-03 - -### Added - -* [#4676](https://github.com/sebastianbergmann/phpunit/issues/4676): Event System for extending PHPUnit's test runner -* [#4502](https://github.com/sebastianbergmann/phpunit/issues/4502): Support PHP 8 attributes for adding metadata to test classes and test methods as well as tested code units -* [#4641](https://github.com/sebastianbergmann/phpunit/issues/4641): `assertStringEqualsStringIgnoringLineEndings()` and `assertStringContainsStringIgnoringLineEndings()` -* [#4650](https://github.com/sebastianbergmann/phpunit/issues/4650): Support dist file name `phpunit.dist.xml` -* [#4657](https://github.com/sebastianbergmann/phpunit/pull/4657): `--exclude-testsuite` option -* [#4818](https://github.com/sebastianbergmann/phpunit/pull/4818): `assertIsList()` -* [#4892](https://github.com/sebastianbergmann/phpunit/issues/4892): Make colors used in HTML code coverage report configurable -* [#4893](https://github.com/sebastianbergmann/phpunit/issues/4893): Make path to custom.css for HTML code coverage report configurable -* [#5097](https://github.com/sebastianbergmann/phpunit/issues/5097): Support for `enum` values in TestDox placeholder replacements -* `TestCase::createStubForIntersectionOfInterfaces()` and `TestCase::createMockForIntersectionOfInterfaces()` -* `#[ExcludeGlobalVariableFromBackup('variable')]` attribute for excluding a global variable from the backup/restore of global and super-global variables -* `#[ExcludeStaticPropertyFromBackup('className', 'propertyName')]` attribute for excluding a static property from the backup/restore of static properties in user-defined classes -* `--log-events-text ` option that controls streaming of event information (without event telemetry) in text format to a file -* `--log-events-verbose-text ` option that controls streaming of event information (with event telemetry) in text format to a file -* `--no-progress` option to disable test execution progress output -* `--no-results` option to disable test result output -* `--no-output` option to disable all output -* `--display-incomplete` option and `displayDetailsOnIncompleteTests` XML configuration attribute to control whether details on incomplete tests should be displayed -* `--display-skipped` option and `displayDetailsOnSkippedTests` XML configuration attribute to control whether details on skipped tests should be displayed -* `--display-deprecations` option and `displayDetailsOnTestsThatTriggerDeprecations` XML configuration attribute to control whether details on tests that trigger `E_DEPRECATED` or `E_USER_DEPRECATED` should be displayed -* `--display-errors` option and `displayDetailsOnTestsThatTriggerErrors` XML configuration attribute to control whether details on tests that trigger `E_ERROR` or `E_USER_ERROR` should be displayed -* `--display-notices` option and `displayDetailsOnTestsThatTriggerNotices` XML configuration attribute to control whether details on tests that trigger `E_STRING`, `E_NOTICE`, or `E_USER_NOTICE` should be displayed -* `--display-warnings` option and `displayDetailsOnTestsThatTriggerWarnings` XML configuration attribute to control whether details on tests that trigger `E_WARNING` or `E_USER_WARNING` should be displayed - -### Changed - -* [#3871](https://github.com/sebastianbergmann/phpunit/issues/3871): Declare return types for `InvocationStubber` methods -* [#3954](https://github.com/sebastianbergmann/phpunit/issues/3954): Disable global state preservation for process isolation by default -* [#4599](https://github.com/sebastianbergmann/phpunit/issues/4599): Unify cache configuration -* [#4603](https://github.com/sebastianbergmann/phpunit/issues/4603): Use "property" instead of "attribute" for configuring the backup of static fields -* [#4656](https://github.com/sebastianbergmann/phpunit/issues/4656): Prevent doubling of `__destruct()` -* Using a non-static method as a data provider is now deprecated -* Using a non-public method as a data provider is now deprecated -* Declaring a data provider method to require an argument is now deprecated -* A test method now continues execution after test(ed) code triggered `E_(USER_)DEPRECATED`, `E_(USER_)NOTICE`, `E_STRICT`, or `E_(USER_)WARNING` -* PHPUnit no longer invokes a static method named `suite` on a class that is declared in a file that is passed as an argument to the CLI test runner -* PHPUnit no longer promotes variables that are global in the bootstrap script's scope to global variables in the test runner's scope (use `$GLOBALS['variable'] = 'value'` instead of `$variable = 'value'` in your bootstrap script) -* `PHPUnit\Framework\TestCase::$backupGlobals` can no longer be used to enable or disable the backup/restore of global and super-global variables for a test case class -* `PHPUnit\Framework\TestCase::$backupStaticAttributes` can no longer be used to enable or disable the backup/restore of static properties in user-defined classes for a test case class -* `@author` is no longer an alias for `@group` -* The JUnit XML logfile now has both `name` and `file` attributes on `` elements for PHPT tests -* The JUnit XML logfile no longer has `` elements that contain the output printed to `stdout` by a test -* The JUnit XML logfile now only reports test outcome (errored, failed, incomplete, skipped, or passed) and no longer test issues (considered risky, for instance) -* The `forceCoversAnnotation` attribute of the `` element of PHPUnit's XML configuration file has been renamed to `requireCoverageMetadata` -* The `beStrictAboutCoversAnnotation` attribute of the `` element of PHPUnit's XML configuration file has been renamed to `beStrictAboutCoverageMetadata` -* The public methods of `PHPUnit\Framework\Assert` and `PHPUnit\Framework\TestCase` are now `final` -* The `--testdox` CLI option no longer replaces the default progress output, but only the default result output -* The CLI test runner now only stops after a test errored when `--stop-on-error` or `--stop-on-defect` is used -* The CLI test runner now only stops after a test failed when `--stop-on-failure` or `--stop-on-defect` is used -* The CLI test runner now only stops after a test triggered a warning when `--stop-on-warning` or `--stop-on-defect` is used -* The CLI test runner now only stops after a test was marked as risky when `--stop-on-risky` or `--stop-on-defect` is used -* The CLI test runner now only stops after a test was skipped when `--stop-on-skipped` is used -* The CLI test runner now only stops after a test was marked as incomplete when `--stop-on-incomplete` is used - -### Removed - -* [#3389](https://github.com/sebastianbergmann/phpunit/issues/3389): Remove `PHPUnit\Framework\TestListener` and `PHPUnit\Framework\TestListenerDefaultImplementation` -* [#3631](https://github.com/sebastianbergmann/phpunit/issues/3631): Remove support for `"ClassName<*>"` as values for `@covers` and `@uses` annotations -* [#3769](https://github.com/sebastianbergmann/phpunit/issues/3769): Remove `MockBuilder::setMethods()` and `MockBuilder::setMethodsExcept()` -* [#3777](https://github.com/sebastianbergmann/phpunit/issues/3777): Remove `PHPUnit\Framework\Error\*` classes -* [#4063](https://github.com/sebastianbergmann/phpunit/issues/4063): Remove `assertNotIsReadable()` -* [#4066](https://github.com/sebastianbergmann/phpunit/issues/4066): Remove `assertNotIsWritable()` -* [#4069](https://github.com/sebastianbergmann/phpunit/issues/4069): Remove `assertDirectoryNotExists()` -* [#4072](https://github.com/sebastianbergmann/phpunit/issues/4072): Remove `assertDirectoryNotIsReadable()` -* [#4075](https://github.com/sebastianbergmann/phpunit/issues/4075): Remove `assertDirectoryNotIsWritable()` -* [#4078](https://github.com/sebastianbergmann/phpunit/issues/4078): Remove `assertFileNotExists()` -* [#4081](https://github.com/sebastianbergmann/phpunit/issues/4081): Remove `assertFileNotIsReadable()` -* [#4087](https://github.com/sebastianbergmann/phpunit/issues/4087): Remove `assertRegExp()` -* [#4090](https://github.com/sebastianbergmann/phpunit/issues/4090): Remove `assertNotRegExp()` -* [#4092](https://github.com/sebastianbergmann/phpunit/issues/4092): Remove `assertEqualXMLStructure()` -* [#4142](https://github.com/sebastianbergmann/phpunit/issues/4142): Remove Prophecy integration -* [#4227](https://github.com/sebastianbergmann/phpunit/issues/4227): Remove `--dump-xdebug-filter` and `--prepend` -* [#4272](https://github.com/sebastianbergmann/phpunit/issues/4272): Remove `PHPUnit\Util\Blacklist` -* [#4273](https://github.com/sebastianbergmann/phpunit/issues/4273): Remove `PHPUnit\Framework\TestCase::$backupGlobalsBlacklist` -* [#4274](https://github.com/sebastianbergmann/phpunit/issues/4274): Remove `PHPUnit\Framework\TestCase::$backupStaticAttributesBlacklist` -* [#4278](https://github.com/sebastianbergmann/phpunit/issues/4278): Remove `--whitelist` option -* [#4279](https://github.com/sebastianbergmann/phpunit/issues/4279): Remove support for old code coverage configuration -* [#4286](https://github.com/sebastianbergmann/phpunit/issues/4286): Remove support for old logging configuration -* [#4298](https://github.com/sebastianbergmann/phpunit/issues/4298): Remove `at()` matcher -* [#4397](https://github.com/sebastianbergmann/phpunit/issues/4397): Remove confusing parameter options for XML assertions -* [#4531](https://github.com/sebastianbergmann/phpunit/pull/4531): Remove `--loader` option as well as `testSuiteLoaderClass` and `testSuiteLoaderFile` XML configuration settings -* [#4536](https://github.com/sebastianbergmann/phpunit/issues/4536): Remove `assertFileNotIsWritable()` -* [#4596](https://github.com/sebastianbergmann/phpunit/issues/4595): Remove Test Hooks -* [#4564](https://github.com/sebastianbergmann/phpunit/issues/4564): Remove `withConsecutive()` -* [#4567](https://github.com/sebastianbergmann/phpunit/issues/4567): Remove support for generators in `assertCount()` and `Count` constraint -* [#4601](https://github.com/sebastianbergmann/phpunit/issues/4601): Remove assertions that operate on class/object properties -* Removed the `expectDeprecation()`, `expectDeprecationMessage()`, and `expectDeprecationMessageMatches()` methods -* Removed the `expectError()`, `expectErrorMessage()`, and `expectErrorMessageMatches()` methods -* Removed the `expectNotice()`, `expectNoticeMessage()`, and `expectNoticeMessageMatches()` methods -* Removed the `expectWarning()`, `expectWarningMessage()`, and `expectWarningMessageMatches()` methods -* Removed the `PHPUnit\Runner\TestSuiteLoader` interface -* Removed the `` XML configuration element and its children -* Removed the `beStrictAboutResourceUsageDuringSmallTests` attribute on the `` XML configuration element and the `--disallow-resource-usage` option as well as the feature they used to control -* Removed the `beStrictAboutTodoAnnotatedTests` attribute on the `` XML configuration element and the `--disallow-todo-tests` option as well as the feature they used to control -* Removed the `convertDeprecationsToExceptions` attribute on the `` XML configuration element as well as the feature it used to control -* Removed the `convertErrorsToExceptions` attribute on the `` XML configuration element as well as the feature it used to control -* Removed the `convertNoticesToExceptions` attribute on the `` XML configuration element as well as the feature it used to control -* Removed the `convertWarningsToExceptions` attribute on the `` XML configuration element as well as the feature it used to control -* Removed the `noInteraction` attribute on the `` XML configuration element and `--no-interaction` option as well as the feature they used to control -* Removed the `processUncoveredFiles` attribute on the `` XML configuration element -* Removed the `testdoxGroups` XML configuration element, the `--testdox-group` option, and the `--testdox-exclude-group` option as well as the feature they used to control -* Removed the `PHPUnit\Framework\TestCase::getMockClass()` method -* Removed the `PHPUnit\Framework\TestCase::$backupGlobalsExcludeList` property, use the `#[ExcludeGlobalVariableFromBackup('variable')]` attribute instead for excluding a global variable from the backup/restore of global and super-global variables -* Removed the `PHPUnit\Framework\TestCase::$backupStaticAttributesExcludeList` property, use the `#[ExcludeStaticPropertyFromBackup('className', 'propertyName')]` attribute instead for excluding a static property from the backup/restore of static properties in user-defined classes -* Removed the `PHPUnit\Framework\TestCase::$preserveGlobalState` property, use the `@preserveGlobalState enabled` annotation or the `#[PreserveGlobalState(true)]` attribute instead for enabling the preservation of global state when running tests in isolation -* Removed the `--repeat` option -* Removed the `--debug` option -* Removed the `--extensions` option -* Removed the `--printer` option -* Removed the `printerClass` and `printerFile` attributes on the `` XML configuration element -* Removed the `--testdox-xml` option and the `` XML configuration element as well as the feature they used to control -* Removed the `--verbose` option -* Removed the `verbose` attribute on the `` XML configuration element -* Removed the `` XML configuration element (child of ``) -* The CLI test runner can no longer be extended through inheritance, the `PHPUnit\TextUI\Command` class has been removed -* PHP 7.3, PHP 7.4, and PHP 8.0 are no longer supported - -[10.0.0]: https://github.com/sebastianbergmann/phpunit/compare/9.6...10.0.0 diff --git a/vendor/phpunit/phpunit/ChangeLog-10.5.md b/vendor/phpunit/phpunit/ChangeLog-10.5.md new file mode 100644 index 00000000..8b96b2f1 --- /dev/null +++ b/vendor/phpunit/phpunit/ChangeLog-10.5.md @@ -0,0 +1,51 @@ +# Changes in PHPUnit 10.5 + +All notable changes of the PHPUnit 10.5 release series are documented in this file using the [Keep a CHANGELOG](https://keepachangelog.com/) principles. + +## [10.5.3] - 2023-12-13 + +### Deprecated + +* `Test\AssertionFailed` and `Test\AssertionSucceeded` events +* `PHPUnit\Runner\Extension\Facade::requireExportOfObjects()` and `PHPUnit\Runner\Extension\Facade::requiresExportOfObjects()` +* `registerMockObjectsFromTestArgumentsRecursively` attribute on the `` element of the XML configuration file +* `PHPUnit\TextUI\Configuration\Configuration::registerMockObjectsFromTestArgumentsRecursively()` + +### Fixed + +* [#5614](https://github.com/sebastianbergmann/phpunit/issues/5614): Infinite recursion when data provider provides recursive array + +## [10.5.2] - 2023-12-05 + +### Fixed + +* [#5561](https://github.com/sebastianbergmann/phpunit/issues/5561): JUnit XML logger does not handle assertion failures in before-test methods +* [#5567](https://github.com/sebastianbergmann/phpunit/issues/5567): Infinite recursion when recursive / self-referencing arrays are checked whether they contain only scalar values + +## [10.5.1] - 2023-12-01 + +### Fixed + +* [#5593](https://github.com/sebastianbergmann/phpunit/issues/5593): Return Value Generator fails to correctly create test stub for method with `static` return type declaration when used recursively +* [#5596](https://github.com/sebastianbergmann/phpunit/issues/5596): `PHPUnit\Framework\TestCase` has `@internal` annotation in PHAR + +## [10.5.0] - 2023-12-01 + +### Added + +* [#5532](https://github.com/sebastianbergmann/phpunit/issues/5532): `#[IgnoreDeprecations]` attribute to ignore `E_(USER_)DEPRECATED` issues on test class and test method level +* [#5551](https://github.com/sebastianbergmann/phpunit/issues/5551): Support for omitting parameter default values for `willReturnMap()` +* [#5577](https://github.com/sebastianbergmann/phpunit/issues/5577): `--composer-lock` CLI option for PHAR binary that displays the `composer.lock` used to build the PHAR + +### Changed + +* `MockBuilder::disableAutoReturnValueGeneration()` and `MockBuilder::enableAutoReturnValueGeneration()` are no longer deprecated + +### Fixed + +* [#5563](https://github.com/sebastianbergmann/phpunit/issues/5563): `createMockForIntersectionOfInterfaces()` does not automatically register mock object for expectation verification + +[10.5.3]: https://github.com/sebastianbergmann/phpunit/compare/10.5.2...10.5.3 +[10.5.2]: https://github.com/sebastianbergmann/phpunit/compare/10.5.1...10.5.2 +[10.5.1]: https://github.com/sebastianbergmann/phpunit/compare/10.5.0...10.5.1 +[10.5.0]: https://github.com/sebastianbergmann/phpunit/compare/10.4.2...10.5.0 diff --git a/vendor/phpunit/phpunit/ChangeLog-8.5.md b/vendor/phpunit/phpunit/ChangeLog-8.5.md deleted file mode 100644 index 6485b8e5..00000000 --- a/vendor/phpunit/phpunit/ChangeLog-8.5.md +++ /dev/null @@ -1,297 +0,0 @@ -# Changes in PHPUnit 8.5 - -All notable changes of the PHPUnit 8.5 release series are documented in this file using the [Keep a CHANGELOG](https://keepachangelog.com/) principles. - -## [8.5.32] - 2023-01-26 - -### Fixed - -* [#5120](https://github.com/sebastianbergmann/phpunit/issues/5120): Test Runner incorrectly treats `--testsuite` and `--list-tests` as not combinable options - -## [8.5.31] - 2022-10-28 - -### Fixed - -* [#5076](https://github.com/sebastianbergmann/phpunit/issues/5076): Test Runner does not warn about conflicting options - -## [8.5.30] - 2022-09-25 - -### Changed - -* The configuration generator now asks for a cache directory - -### Fixed - -* [#4913](https://github.com/sebastianbergmann/phpunit/issues/4913): Failed `assert()` should show a backtrace -* [#4966](https://github.com/sebastianbergmann/phpunit/issues/4966): `TestCase::assertSame()` (and related exact comparisons) must compare `float` exactly - -## [8.5.29] - 2022-08-22 - -### Changed - -* [#5033](https://github.com/sebastianbergmann/phpunit/issues/5033): Do not depend on phpspec/prophecy - -## [8.5.28] - 2022-07-29 - -### Fixed - -* [#5015](https://github.com/sebastianbergmann/phpunit/pull/5015): Ukraine banner unreadable on black background -* [#5016](https://github.com/sebastianbergmann/phpunit/issues/5016): PHPUnit 8.5.27 does not work on PHP 7.2.0-7.2.18 and PHP 7.3.0-7.3.5 - -## [8.5.27] - 2022-06-19 - -### Fixed - -* [#4950](https://github.com/sebastianbergmann/phpunit/issues/4950): False error on `atMost()` invocation rule without call -* [#4962](https://github.com/sebastianbergmann/phpunit/issues/4962): Ukraine banner unreadable on white background - -## [8.5.26] - 2022-04-01 - -### Fixed - -* [#4938](https://github.com/sebastianbergmann/phpunit/issues/4938): Test Double code generator does not handle `void` return type declaration on `__clone()` methods - -## [8.5.25] - 2022-03-16 - -### Fixed - -* [#4934](https://github.com/sebastianbergmann/phpunit/issues/4934): Code Coverage does not work with PHPUnit 8.5.24 PHAR on PHP 7 - -## [8.5.24] - 2022-03-05 - #StandWithUkraine - -### Changed - -* [#4874](https://github.com/sebastianbergmann/phpunit/pull/4874): `PHP_FLOAT_EPSILON` is now used instead of hardcoded `0.0000000001` in `PHPUnit\Framework\Constraint\IsIdentical` - -### Fixed - -* When the HTML code coverage report's configured low upper bound is larger than the high lower bound then the default values are used instead - -## [8.5.23] - 2022-01-21 - -### Fixed - -* [#4799](https://github.com/sebastianbergmann/phpunit/pull/4799): Memory leaks in `PHPUnit\Framework\TestSuite` class -* [#4857](https://github.com/sebastianbergmann/phpunit/pull/4857): Result of `debug_backtrace()` is not used correctly - -## [8.5.22] - 2021-12-25 - -### Changed - -* [#4812](https://github.com/sebastianbergmann/phpunit/issues/4812): Do not enforce time limits when a debugging session through DBGp is active -* [#4835](https://github.com/sebastianbergmann/phpunit/issues/4835): Support for `$GLOBALS['_composer_autoload_path']` introduced in Composer 2.2 - -### Fixed - -* [#4840](https://github.com/sebastianbergmann/phpunit/pull/4840): TestDox prettifying for class names does not correctly handle diacritics -* [#4846](https://github.com/sebastianbergmann/phpunit/pull/4846): Composer proxy script is not ignored - -## [8.5.21] - 2021-09-25 - -### Changed - -* PHPUnit no longer converts PHP deprecations to exceptions by default (configure `convertDeprecationsToExceptions="true"` to enable this) -* The PHPUnit XML configuration file generator now configures `convertDeprecationsToExceptions="true"` - -### Fixed - -* [#4772](https://github.com/sebastianbergmann/phpunit/pull/4772): TestDox HTML report not displayed correctly when browser has custom colour settings - -## [8.5.20] - 2021-08-31 - -### Fixed - -* [#4751](https://github.com/sebastianbergmann/phpunit/issues/4751): Configuration validation fails when using brackets in glob pattern - -## [8.5.19] - 2021-07-31 - -### Fixed - -* [#4740](https://github.com/sebastianbergmann/phpunit/issues/4740): `phpunit.phar` does not work with PHP 8.1 - -## [8.5.18] - 2021-07-19 - -### Fixed - -* [#4720](https://github.com/sebastianbergmann/phpunit/issues/4720): PHPUnit does not verify its own PHP extension requirements - -## [8.5.17] - 2021-06-23 - -### Changed - -* PHPUnit now errors out on startup when `PHP_VERSION` contains a value that is not compatible with `version_compare()`, for instance `X.Y.Z-(to be removed in future macOS)` - -## [8.5.16] - 2021-06-05 - -### Changed - -* The test result cache (the storage for which is implemented in `PHPUnit\Runner\DefaultTestResultCache`) no longer uses PHP's `serialize()` and `unserialize()` functions for persistence. It now uses a versioned JSON format instead that is independent of PHP implementation details (see [#3581](https://github.com/sebastianbergmann/phpunit/issues/3581) and [#4662](https://github.com/sebastianbergmann/phpunit/pull/4662) for examples why this is a problem). When PHPUnit tries to load the test result cache from a file that does not exist, or from a file that does not contain data in JSON format, or from a file that contains data in a JSON format version other than the one used by the currently running PHPUnit version, then this is considered to be a "cache miss". An empty `DefaultTestResultCache` object is created in this case. This should also prevent PHPUnit from crashing when trying to load a test result cache file created by a different version of PHPUnit (see [#4580](https://github.com/sebastianbergmann/phpunit/issues/4580) for example). - -### Fixed - -* [#4663](https://github.com/sebastianbergmann/phpunit/issues/4663): `TestCase::expectError()` works on PHP 7.3, but not on PHP >= 7.4 -* [#4678](https://github.com/sebastianbergmann/phpunit/pull/4678): Stubbed methods with `iterable` return types should return empty array by default -* [#4692](https://github.com/sebastianbergmann/phpunit/issues/4692): Annotations in single-line doc-comments are not handled correctly -* [#4694](https://github.com/sebastianbergmann/phpunit/issues/4694): `TestCase::getMockFromWsdl()` does not work with PHP 8.1-dev - -## [8.5.15] - 2021-03-17 - -### Fixed - -* [#4591](https://github.com/sebastianbergmann/phpunit/issues/4591): TeamCity logger logs warnings as test failures - -## [8.5.14] - 2021-01-17 - -### Fixed - -* [#4535](https://github.com/sebastianbergmann/phpunit/issues/4535): `getMockFromWsdl()` does not handle methods that do not have parameters correctly -* [#4572](https://github.com/sebastianbergmann/phpunit/issues/4572): Schema validation does not work with `%xx` sequences in path to `phpunit.xsd` -* [#4575](https://github.com/sebastianbergmann/phpunit/issues/4575): PHPUnit 8.5 incompatibility with PHP 8.1 - -## [8.5.13] - 2020-12-01 - -### Fixed - -* Running tests in isolated processes did not work with PHP 8 on Windows - -## [8.5.12] - 2020-11-30 - -### Changed - -* Changed PHP version constraint in `composer.json` from `^7.2` to `>=7.2` to allow the installation of PHPUnit 8.5 on PHP 8. Please note that the code coverage functionality is not available for PHPUnit 8.5 on PHP 8. - -### Fixed - -* [#4529](https://github.com/sebastianbergmann/phpunit/issues/4529): Debug mode of Xdebug 2 is not disabled for PHPT tests - -## [8.5.11] - 2020-11-27 - -### Changed - -* Bumped required version of `phpunit/php-code-coverage` - -## [8.5.10] - 2020-11-27 - -### Added - -* Support for Xdebug 3 - -### Fixed - -* [#4516](https://github.com/sebastianbergmann/phpunit/issues/4516): `phpunit/phpunit-selenium` does not work with PHPUnit 8.5.9 - -## [8.5.9] - 2020-11-10 - -### Fixed - -* [#3965](https://github.com/sebastianbergmann/phpunit/issues/3965): Process Isolation throws exceptions when PHPDBG is used -* [#4470](https://github.com/sebastianbergmann/phpunit/pull/4470): Infinite recursion when `--static-backup --strict-global-state` is used - -## [8.5.8] - 2020-06-22 - -### Fixed - -* [#4312](https://github.com/sebastianbergmann/phpunit/issues/4312): Fix for [#4299](https://github.com/sebastianbergmann/phpunit/issues/4299) breaks backward compatibility - -## [8.5.7] - 2020-06-21 - -### Fixed - -* [#4299](https://github.com/sebastianbergmann/phpunit/issues/4299): "No tests executed" does not always result in exit code `1` -* [#4306](https://github.com/sebastianbergmann/phpunit/issues/4306): Exceptions during code coverage driver initialization are not handled correctly - -## [8.5.6] - 2020-06-15 - -### Fixed - -* [#4211](https://github.com/sebastianbergmann/phpunit/issues/4211): `phpdbg_*()` functions are scoped to `PHPUnit\phpdbg_*()` - -## [8.5.5] - 2020-05-22 - -### Fixed - -* [#4033](https://github.com/sebastianbergmann/phpunit/issues/4033): Unexpected behaviour when `$GLOBALS` is deleted - -## [8.5.4] - 2020-04-23 - -### Changed - -* Changed how `PHPUnit\TextUI\Command` passes warnings to `PHPUnit\TextUI\TestRunner` - -## [8.5.3] - 2020-03-31 - -### Fixed - -* [#4017](https://github.com/sebastianbergmann/phpunit/issues/4017): Do not suggest refactoring to something that is also deprecated -* [#4133](https://github.com/sebastianbergmann/phpunit/issues/4133): `expectExceptionMessageRegExp()` has been removed in PHPUnit 9 without a deprecation warning being given in PHPUnit 8 -* [#4139](https://github.com/sebastianbergmann/phpunit/issues/4139): Cannot double interfaces that declare a constructor with PHP 8 -* [#4144](https://github.com/sebastianbergmann/phpunit/issues/4144): Empty objects are converted to empty arrays in JSON comparison failure diff - -## [8.5.2] - 2020-01-08 - -### Removed - -* `eval-stdin.php` has been removed, it was not used anymore since PHPUnit 7.2.7 - -## [8.5.1] - 2019-12-25 - -### Changed - -* `eval-stdin.php` can now only be executed with `cli` and `phpdbg` - -### Fixed - -* [#3983](https://github.com/sebastianbergmann/phpunit/issues/3983): Deprecation warning given too eagerly - -## [8.5.0] - 2019-12-06 - -### Added - -* [#3911](https://github.com/sebastianbergmann/phpunit/issues/3911): Support combined use of `addMethods()` and `onlyMethods()` -* [#3949](https://github.com/sebastianbergmann/phpunit/issues/3949): Introduce specialized assertions `assertFileEqualsCanonicalizing()`, `assertFileEqualsIgnoringCase()`, `assertStringEqualsFileCanonicalizing()`, `assertStringEqualsFileIgnoringCase()`, `assertFileNotEqualsCanonicalizing()`, `assertFileNotEqualsIgnoringCase()`, `assertStringNotEqualsFileCanonicalizing()`, and `assertStringNotEqualsFileIgnoringCase()` as alternative to using `assertFileEquals()` etc. with optional parameters - -### Changed - -* [#3860](https://github.com/sebastianbergmann/phpunit/pull/3860): Deprecate invoking PHPUnit commandline test runner with just a class name -* [#3950](https://github.com/sebastianbergmann/phpunit/issues/3950): Deprecate optional parameters of `assertFileEquals()` etc. -* [#3955](https://github.com/sebastianbergmann/phpunit/issues/3955): Deprecate support for doubling multiple interfaces - -### Fixed - -* [#3953](https://github.com/sebastianbergmann/phpunit/issues/3953): Code Coverage for test executed in isolation does not work when the PHAR is used -* [#3967](https://github.com/sebastianbergmann/phpunit/issues/3967): Cannot double interface that extends interface that extends `\Throwable` -* [#3968](https://github.com/sebastianbergmann/phpunit/pull/3968): Test class run in a separate PHP process are passing when `exit` called inside - -[8.5.32]: https://github.com/sebastianbergmann/phpunit/compare/8.5.31...8.5.32 -[8.5.31]: https://github.com/sebastianbergmann/phpunit/compare/8.5.30...8.5.31 -[8.5.30]: https://github.com/sebastianbergmann/phpunit/compare/8.5.29...8.5.30 -[8.5.29]: https://github.com/sebastianbergmann/phpunit/compare/8.5.28...8.5.29 -[8.5.28]: https://github.com/sebastianbergmann/phpunit/compare/8.5.27...8.5.28 -[8.5.27]: https://github.com/sebastianbergmann/phpunit/compare/8.5.26...8.5.27 -[8.5.26]: https://github.com/sebastianbergmann/phpunit/compare/8.5.25...8.5.26 -[8.5.25]: https://github.com/sebastianbergmann/phpunit/compare/8.5.24...8.5.25 -[8.5.24]: https://github.com/sebastianbergmann/phpunit/compare/8.5.23...8.5.24 -[8.5.23]: https://github.com/sebastianbergmann/phpunit/compare/8.5.22...8.5.23 -[8.5.22]: https://github.com/sebastianbergmann/phpunit/compare/8.5.21...8.5.22 -[8.5.21]: https://github.com/sebastianbergmann/phpunit/compare/8.5.20...8.5.21 -[8.5.20]: https://github.com/sebastianbergmann/phpunit/compare/8.5.19...8.5.20 -[8.5.19]: https://github.com/sebastianbergmann/phpunit/compare/8.5.18...8.5.19 -[8.5.18]: https://github.com/sebastianbergmann/phpunit/compare/8.5.17...8.5.18 -[8.5.17]: https://github.com/sebastianbergmann/phpunit/compare/8.5.16...8.5.17 -[8.5.16]: https://github.com/sebastianbergmann/phpunit/compare/8.5.15...8.5.16 -[8.5.15]: https://github.com/sebastianbergmann/phpunit/compare/8.5.14...8.5.15 -[8.5.14]: https://github.com/sebastianbergmann/phpunit/compare/8.5.13...8.5.14 -[8.5.13]: https://github.com/sebastianbergmann/phpunit/compare/8.5.12...8.5.13 -[8.5.12]: https://github.com/sebastianbergmann/phpunit/compare/8.5.11...8.5.12 -[8.5.11]: https://github.com/sebastianbergmann/phpunit/compare/8.5.10...8.5.11 -[8.5.10]: https://github.com/sebastianbergmann/phpunit/compare/8.5.9...8.5.10 -[8.5.9]: https://github.com/sebastianbergmann/phpunit/compare/8.5.8...8.5.9 -[8.5.8]: https://github.com/sebastianbergmann/phpunit/compare/8.5.7...8.5.8 -[8.5.7]: https://github.com/sebastianbergmann/phpunit/compare/8.5.6...8.5.7 -[8.5.6]: https://github.com/sebastianbergmann/phpunit/compare/8.5.5...8.5.6 -[8.5.5]: https://github.com/sebastianbergmann/phpunit/compare/8.5.4...8.5.5 -[8.5.4]: https://github.com/sebastianbergmann/phpunit/compare/8.5.3...8.5.4 -[8.5.3]: https://github.com/sebastianbergmann/phpunit/compare/8.5.2...8.5.3 -[8.5.2]: https://github.com/sebastianbergmann/phpunit/compare/8.5.1...8.5.2 -[8.5.1]: https://github.com/sebastianbergmann/phpunit/compare/8.5.0...8.5.1 -[8.5.0]: https://github.com/sebastianbergmann/phpunit/compare/8.4.3...8.5.0 diff --git a/vendor/phpunit/phpunit/ChangeLog-9.6.md b/vendor/phpunit/phpunit/ChangeLog-9.6.md deleted file mode 100644 index 06a35f22..00000000 --- a/vendor/phpunit/phpunit/ChangeLog-9.6.md +++ /dev/null @@ -1,14 +0,0 @@ -# Changes in PHPUnit 9.6 - -All notable changes of the PHPUnit 9.6 release series are documented in this file using the [Keep a CHANGELOG](https://keepachangelog.com/) principles. - -## [9.6.0] - 2023-02-03 - -### Changed - -* [#5062](https://github.com/sebastianbergmann/phpunit/issues/5062): Deprecate `expectDeprecation()`, `expectDeprecationMessage()`, `expectDeprecationMessageMatches()`, `expectError()`, `expectErrorMessage()`, `expectErrorMessageMatches()`, `expectNotice()`, `expectNoticeMessage()`, `expectNoticeMessageMatches()`, `expectWarning()`, `expectWarningMessage()`, and `expectWarningMessageMatches()` -* [#5063](https://github.com/sebastianbergmann/phpunit/issues/5063): Deprecate `withConsecutive()` -* [#5064](https://github.com/sebastianbergmann/phpunit/issues/5064): Deprecate `PHPUnit\Framework\TestCase::getMockClass()` -* [#5132](https://github.com/sebastianbergmann/phpunit/issues/5132): Deprecate `Test` suffix for abstract test case classes - -[9.6.0]: https://github.com/sebastianbergmann/phpunit/compare/9.5...9.6 diff --git a/vendor/phpunit/phpunit/DEPRECATIONS.md b/vendor/phpunit/phpunit/DEPRECATIONS.md new file mode 100644 index 00000000..d66cef7e --- /dev/null +++ b/vendor/phpunit/phpunit/DEPRECATIONS.md @@ -0,0 +1,91 @@ +# Deprecations + +## Soft Deprecations + +This functionality is currently [soft-deprecated](https://phpunit.de/backward-compatibility.html#soft-deprecation): + +### Writing Tests + +#### Assertions, Constraints, and Expectations + +| Issue | Description | Since | Replacement | +|-------------------------------------------------------------------|------------------------------------------------|--------|-------------| +| [#5472](https://github.com/sebastianbergmann/phpunit/issues/5472) | `TestCase::assertStringNotMatchesFormat()` | 10.4.0 | | +| [#5472](https://github.com/sebastianbergmann/phpunit/issues/5472) | `TestCase::assertStringNotMatchesFormatFile()` | 10.4.0 | | + +#### Test Double API + +| Issue | Description | Since | Replacement | +|-------------------------------------------------------------------|---------------------------------------------------|--------|-----------------------------------------------------------------------------------------| +| [#5240](https://github.com/sebastianbergmann/phpunit/issues/5240) | `TestCase::createTestProxy()` | 10.1.0 | | +| [#5241](https://github.com/sebastianbergmann/phpunit/issues/5241) | `TestCase::getMockForAbstractClass()` | 10.1.0 | | +| [#5242](https://github.com/sebastianbergmann/phpunit/issues/5242) | `TestCase::getMockFromWsdl()` | 10.1.0 | | +| [#5243](https://github.com/sebastianbergmann/phpunit/issues/5243) | `TestCase::getMockForTrait()` | 10.1.0 | | +| [#5244](https://github.com/sebastianbergmann/phpunit/issues/5244) | `TestCase::getObjectForTrait()` | 10.1.0 | | +| [#5305](https://github.com/sebastianbergmann/phpunit/issues/5305) | `MockBuilder::getMockForAbstractClass()` | 10.1.0 | | +| [#5306](https://github.com/sebastianbergmann/phpunit/issues/5306) | `MockBuilder::getMockForTrait()` | 10.1.0 | | +| [#5307](https://github.com/sebastianbergmann/phpunit/issues/5307) | `MockBuilder::disableProxyingToOriginalMethods()` | 10.1.0 | | +| [#5307](https://github.com/sebastianbergmann/phpunit/issues/5307) | `MockBuilder::enableProxyingToOriginalMethods()` | 10.1.0 | | +| [#5307](https://github.com/sebastianbergmann/phpunit/issues/5307) | `MockBuilder::setProxyTarget()` | 10.1.0 | | +| [#5308](https://github.com/sebastianbergmann/phpunit/issues/5308) | `MockBuilder::allowMockingUnknownTypes()` | 10.1.0 | | +| [#5308](https://github.com/sebastianbergmann/phpunit/issues/5308) | `MockBuilder::disallowMockingUnknownTypes()` | 10.1.0 | | +| [#5309](https://github.com/sebastianbergmann/phpunit/issues/5309) | `MockBuilder::disableAutoload()` | 10.1.0 | | +| [#5309](https://github.com/sebastianbergmann/phpunit/issues/5309) | `MockBuilder::enableAutoload()` | 10.1.0 | | +| [#5315](https://github.com/sebastianbergmann/phpunit/issues/5315) | `MockBuilder::disableArgumentCloning()` | 10.1.0 | | +| [#5315](https://github.com/sebastianbergmann/phpunit/issues/5315) | `MockBuilder::enableArgumentCloning()` | 10.1.0 | | +| [#5320](https://github.com/sebastianbergmann/phpunit/issues/5320) | `MockBuilder::addMethods()` | 10.1.0 | | +| [#5423](https://github.com/sebastianbergmann/phpunit/issues/5423) | `TestCase::onConsecutiveCalls()` | 10.3.0 | Use `$double->willReturn()` instead of `$double->will($this->onConsecutiveCalls())` | +| [#5423](https://github.com/sebastianbergmann/phpunit/issues/5423) | `TestCase::returnArgument()` | 10.3.0 | Use `$double->willReturnArgument()` instead of `$double->will($this->returnArgument())` | +| [#5423](https://github.com/sebastianbergmann/phpunit/issues/5423) | `TestCase::returnCallback()` | 10.3.0 | Use `$double->willReturnCallback()` instead of `$double->will($this->returnCallback())` | +| [#5423](https://github.com/sebastianbergmann/phpunit/issues/5423) | `TestCase::returnSelf()` | 10.3.0 | Use `$double->willReturnSelf()` instead of `$double->will($this->returnSelf())` | +| [#5423](https://github.com/sebastianbergmann/phpunit/issues/5423) | `TestCase::returnValue()` | 10.3.0 | Use `$double->willReturn()` instead of `$double->will($this->returnValue())` | +| [#5423](https://github.com/sebastianbergmann/phpunit/issues/5423) | `TestCase::returnValueMap()` | 10.3.0 | Use `$double->willReturnMap()` instead of `$double->will($this->returnValueMap())` | + +#### Miscellaneous + +| Issue | Description | Since | Replacement | +|-------------------------------------------------------------------|----------------------------------------------------------------|--------|--------------------------------------------------------------------| +| [#5236](https://github.com/sebastianbergmann/phpunit/issues/5236) | `PHPUnit\Framework\Attributes\CodeCoverageIgnore()` | 10.1.0 | | +| [#5214](https://github.com/sebastianbergmann/phpunit/issues/5214) | `TestCase::iniSet()` | 10.3.0 | | +| [#5216](https://github.com/sebastianbergmann/phpunit/issues/5216) | `TestCase::setLocale()` | 10.3.0 | | +| [#5236](https://github.com/sebastianbergmann/phpunit/issues/5513) | `PHPUnit\Framework\Attributes\IgnoreClassForCodeCoverage()` | 10.4.0 | Use `@codeCoverageIgnore` annotation in the class' doc-comment | +| [#5236](https://github.com/sebastianbergmann/phpunit/issues/5513) | `PHPUnit\Framework\Attributes\IgnoreMethodForCodeCoverage()` | 10.4.0 | Use `@codeCoverageIgnore` annotation in the method's doc-comment | +| [#5236](https://github.com/sebastianbergmann/phpunit/issues/5513) | `PHPUnit\Framework\Attributes\IgnoreFunctionForCodeCoverage()` | 10.4.0 | Use `@codeCoverageIgnore` annotation in the function's doc-comment | + +### Running Tests + +| Issue | Description | Since | Replacement | +|-------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------|--------|-------------| +| [#5481](https://github.com/sebastianbergmann/phpunit/issues/5481) | `dataSet` attribute for `testCaseMethod` elements in the XML document generated by `--list-tests-xml` | 10.4.0 | | + +### Extending PHPUnit + +| Issue | Description | Since | Replacement | +|-------|------------------------------------------------------------------------------------------------------------------------------|--------|--------------------------------------------------------------------------------| +| | `PHPUnit\TextUI\Configuration\Configuration::coverageExcludeDirectories()` | 10.2.0 | `PHPUnit\TextUI\Configuration\Configuration::source()->excludeDirectories()` | +| | `PHPUnit\TextUI\Configuration\Configuration::coverageExcludeFiles()` | 10.2.0 | `PHPUnit\TextUI\Configuration\Configuration::source()->excludeFiles()` | +| | `PHPUnit\TextUI\Configuration\Configuration::coverageIncludeDirectories()` | 10.2.0 | `PHPUnit\TextUI\Configuration\Configuration::source()->includeDirectories()` | +| | `PHPUnit\TextUI\Configuration\Configuration::coverageIncludeFiles()` | 10.2.0 | `PHPUnit\TextUI\Configuration\Configuration::source()->includeFiles()` | +| | `PHPUnit\TextUI\Configuration\Configuration::loadPharExtensions()` | 10.2.0 | `PHPUnit\TextUI\Configuration\Configuration::noExtensions()` | +| | `PHPUnit\TextUI\Configuration\Configuration::hasNonEmptyListOfFilesToBeIncludedInCodeCoverageReport()` | 10.2.0 | `PHPUnit\TextUI\Configuration\Configuration::source()->notEmpty()` | +| | `PHPUnit\TextUI\Configuration\Configuration::restrictDeprecations()` | 10.2.0 | `PHPUnit\TextUI\Configuration\Configuration::source()->restrictDeprecations()` | +| | `PHPUnit\TextUI\Configuration\Configuration::restrictNotices()` | 10.2.0 | `PHPUnit\TextUI\Configuration\Configuration::source()->restrictNotices()` | +| | `PHPUnit\TextUI\Configuration\Configuration::restrictWarnings()` | 10.2.0 | `PHPUnit\TextUI\Configuration\Configuration::source()->restrictWarnings()` | +| | `PHPUnit\TextUI\Configuration\Configuration::cliArgument()` | 10.4.0 | `PHPUnit\TextUI\Configuration\Configuration::cliArguments()[0]` | +| | `PHPUnit\TextUI\Configuration\Configuration::hasCliArgument()` | 10.4.0 | `PHPUnit\TextUI\Configuration\Configuration::hasCliArguments()` | +| | `PHPUnit\Framework\Constraint\Constraint::exporter()` | 10.4.0 | | +| | `PHPUnit\TextUI\Configuration\Configuration::registerMockObjectsFromTestArgumentsRecursively()` | 10.5.3 | | +| | `Test\AssertionFailed` and `Test\AssertionSucceeded` events | 10.5.3 | | +| | `PHPUnit\Runner\Extension\Facade::requireExportOfObjects()` and `PHPUnit\Runner\Extension\Facade::requiresExportOfObjects()` | 10.5.3 | | + +## Hard Deprecations + +This functionality is currently [hard-deprecated](https://phpunit.de/backward-compatibility.html#hard-deprecation): + +### Writing Tests + +#### Miscellaneous + +| Issue | Description | Since | Replacement | +|-------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------|--------|-------------| +| [#5100](https://github.com/sebastianbergmann/phpunit/issues/5100) | Support for non-static data provider methods, non-public data provider methods, and data provider methods that declare parameters | 10.0.0 | | diff --git a/vendor/phpunit/phpunit/README.md b/vendor/phpunit/phpunit/README.md index 0e4789a0..1ec859a1 100644 --- a/vendor/phpunit/phpunit/README.md +++ b/vendor/phpunit/phpunit/README.md @@ -1,5 +1,3 @@ -

🇺🇦 UKRAINE NEEDS YOUR HELP NOW!

- # PHPUnit [![Latest Stable Version](https://poser.pugx.org/phpunit/phpunit/v/stable.png)](https://packagist.org/packages/phpunit/phpunit) diff --git a/vendor/phpunit/phpunit/SECURITY.md b/vendor/phpunit/phpunit/SECURITY.md index dcc15385..965e5ed2 100644 --- a/vendor/phpunit/phpunit/SECURITY.md +++ b/vendor/phpunit/phpunit/SECURITY.md @@ -1,11 +1,33 @@ # Security Policy -PHPUnit is a framework for writing as well as a commandline tool for running tests. Writing and running tests is a development-time activity. There is no reason why PHPUnit should be installed on a webserver. +If you believe you have found a security vulnerability in PHPUnit, please report it to us through coordinated disclosure. + +**Please do not report security vulnerabilities through public GitHub issues, discussions, or pull requests.** + +Instead, please email `sebastian@phpunit.de`. + +Please include as much of the information listed below as you can to help us better understand and resolve the issue: + +* The type of issue +* Full paths of source file(s) related to the manifestation of the issue +* The location of the affected source code (tag/branch/commit or direct URL) +* Any special configuration required to reproduce the issue +* Step-by-step instructions to reproduce the issue +* Proof-of-concept or exploit code (if possible) +* Impact of the issue, including how an attacker might exploit the issue + +This information will help us triage your report more quickly. + +## Web Context + +PHPUnit is a framework for writing as well as a command-line tool for running tests. Writing and running tests is a development-time activity. There is no reason why PHPUnit should be installed on a webserver and/or in a production environment. **If you upload PHPUnit to a webserver then your deployment process is broken. On a more general note, if your `vendor` directory is publicly accessible on your webserver then your deployment process is also broken.** Please note that if you upload PHPUnit to a webserver "bad things" may happen. [You have been warned.](https://thephp.cc/articles/phpunit-a-security-risk) -## Security Contact Information +PHPUnit is developed with a focus on development environments and the command-line. No specific testing or hardening with regard to using PHPUnit in an HTTP or web context or with untrusted input data is performed. PHPUnit might also contain functionality that intentionally exposes internal application data for debugging purposes. -After the above, if you still would like to report a security vulnerability, please email `sebastian@phpunit.de`. +If PHPUnit is used in a web application, the application developer is responsible for filtering inputs or escaping outputs as necessary and for verifying that the used functionality is safe for use within the intended context. + +Vulnerabilities specific to the use outside a development context will be fixed as applicable, provided that the fix does not have an averse effect on the primary use case for development purposes. diff --git a/vendor/phpunit/phpunit/composer.json b/vendor/phpunit/phpunit/composer.json index 238d001d..4f81fae0 100644 --- a/vendor/phpunit/phpunit/composer.json +++ b/vendor/phpunit/phpunit/composer.json @@ -17,7 +17,8 @@ } ], "support": { - "issues": "https://github.com/sebastianbergmann/phpunit/issues" + "issues": "https://github.com/sebastianbergmann/phpunit/issues", + "security": "https://github.com/sebastianbergmann/phpunit/security/policy" }, "prefer-stable": true, "require": { @@ -31,7 +32,7 @@ "myclabs/deep-copy": "^1.10.1", "phar-io/manifest": "^2.0.3", "phar-io/version": "^3.0.2", - "phpunit/php-code-coverage": "^10.0", + "phpunit/php-code-coverage": "^10.1.5", "phpunit/php-file-iterator": "^4.0", "phpunit/php-invoker": "^4.0", "phpunit/php-text-template": "^3.0", @@ -41,8 +42,8 @@ "sebastian/comparator": "^5.0", "sebastian/diff": "^5.0", "sebastian/environment": "^6.0", - "sebastian/exporter": "^5.0", - "sebastian/global-state": "^6.0", + "sebastian/exporter": "^5.1", + "sebastian/global-state": "^6.0.1", "sebastian/object-enumerator": "^5.0", "sebastian/recursion-context": "^5.0", "sebastian/type": "^4.0", @@ -56,7 +57,7 @@ "sort-packages": true }, "suggest": { - "ext-soap": "*" + "ext-soap": "To be able to generate mocks based on WSDL files" }, "bin": [ "phpunit" @@ -76,12 +77,14 @@ "files": [ "tests/_files/CoverageNamespacedFunctionTest.php", "tests/_files/CoveredFunction.php", - "tests/_files/NamespaceCoveredFunction.php" + "tests/_files/Generator.php", + "tests/_files/NamespaceCoveredFunction.php", + "tests/end-to-end/code-coverage/ignore-function-using-attribute/src/CoveredFunction.php" ] }, "extra": { "branch-alias": { - "dev-main": "10.0-dev" + "dev-main": "10.5-dev" } } } diff --git a/vendor/phpunit/phpunit/composer.lock b/vendor/phpunit/phpunit/composer.lock new file mode 100644 index 00000000..7bd0edd5 --- /dev/null +++ b/vendor/phpunit/phpunit/composer.lock @@ -0,0 +1,1542 @@ +{ + "_readme": [ + "This file locks the dependencies of your project to a known state", + "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", + "This file is @generated automatically" + ], + "content-hash": "e06728e5442edec84af96f94a889b4a7", + "packages": [ + { + "name": "myclabs/deep-copy", + "version": "1.11.1", + "source": { + "type": "git", + "url": "https://github.com/myclabs/DeepCopy.git", + "reference": "7284c22080590fb39f2ffa3e9057f10a4ddd0e0c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/7284c22080590fb39f2ffa3e9057f10a4ddd0e0c", + "reference": "7284c22080590fb39f2ffa3e9057f10a4ddd0e0c", + "shasum": "" + }, + "require": { + "php": "^7.1 || ^8.0" + }, + "conflict": { + "doctrine/collections": "<1.6.8", + "doctrine/common": "<2.13.3 || >=3,<3.2.2" + }, + "require-dev": { + "doctrine/collections": "^1.6.8", + "doctrine/common": "^2.13.3 || ^3.2.2", + "phpunit/phpunit": "^7.5.20 || ^8.5.23 || ^9.5.13" + }, + "type": "library", + "autoload": { + "files": [ + "src/DeepCopy/deep_copy.php" + ], + "psr-4": { + "DeepCopy\\": "src/DeepCopy/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "Create deep copies (clones) of your objects", + "keywords": [ + "clone", + "copy", + "duplicate", + "object", + "object graph" + ], + "support": { + "issues": "https://github.com/myclabs/DeepCopy/issues", + "source": "https://github.com/myclabs/DeepCopy/tree/1.11.1" + }, + "funding": [ + { + "url": "https://tidelift.com/funding/github/packagist/myclabs/deep-copy", + "type": "tidelift" + } + ], + "time": "2023-03-08T13:26:56+00:00" + }, + { + "name": "nikic/php-parser", + "version": "v4.17.1", + "source": { + "type": "git", + "url": "https://github.com/nikic/PHP-Parser.git", + "reference": "a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d", + "reference": "a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d", + "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.17.1" + }, + "time": "2023-08-13T19:53:39+00:00" + }, + { + "name": "phar-io/manifest", + "version": "2.0.3", + "source": { + "type": "git", + "url": "https://github.com/phar-io/manifest.git", + "reference": "97803eca37d319dfa7826cc2437fc020857acb53" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/phar-io/manifest/zipball/97803eca37d319dfa7826cc2437fc020857acb53", + "reference": "97803eca37d319dfa7826cc2437fc020857acb53", + "shasum": "" + }, + "require": { + "ext-dom": "*", + "ext-phar": "*", + "ext-xmlwriter": "*", + "phar-io/version": "^3.0.1", + "php": "^7.2 || ^8.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0.x-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Arne Blankerts", + "email": "arne@blankerts.de", + "role": "Developer" + }, + { + "name": "Sebastian Heuer", + "email": "sebastian@phpeople.de", + "role": "Developer" + }, + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "Developer" + } + ], + "description": "Component for reading phar.io manifest information from a PHP Archive (PHAR)", + "support": { + "issues": "https://github.com/phar-io/manifest/issues", + "source": "https://github.com/phar-io/manifest/tree/2.0.3" + }, + "time": "2021-07-20T11:28:43+00:00" + }, + { + "name": "phar-io/version", + "version": "3.2.1", + "source": { + "type": "git", + "url": "https://github.com/phar-io/version.git", + "reference": "4f7fd7836c6f332bb2933569e566a0d6c4cbed74" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/phar-io/version/zipball/4f7fd7836c6f332bb2933569e566a0d6c4cbed74", + "reference": "4f7fd7836c6f332bb2933569e566a0d6c4cbed74", + "shasum": "" + }, + "require": { + "php": "^7.2 || ^8.0" + }, + "type": "library", + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Arne Blankerts", + "email": "arne@blankerts.de", + "role": "Developer" + }, + { + "name": "Sebastian Heuer", + "email": "sebastian@phpeople.de", + "role": "Developer" + }, + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "Developer" + } + ], + "description": "Library for handling version information and constraints", + "support": { + "issues": "https://github.com/phar-io/version/issues", + "source": "https://github.com/phar-io/version/tree/3.2.1" + }, + "time": "2022-02-21T01:04:05+00:00" + }, + { + "name": "phpunit/php-code-coverage", + "version": "10.1.9", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-code-coverage.git", + "reference": "a56a9ab2f680246adcf3db43f38ddf1765774735" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/a56a9ab2f680246adcf3db43f38ddf1765774735", + "reference": "a56a9ab2f680246adcf3db43f38ddf1765774735", + "shasum": "" + }, + "require": { + "ext-dom": "*", + "ext-libxml": "*", + "ext-xmlwriter": "*", + "nikic/php-parser": "^4.15", + "php": ">=8.1", + "phpunit/php-file-iterator": "^4.0", + "phpunit/php-text-template": "^3.0", + "sebastian/code-unit-reverse-lookup": "^3.0", + "sebastian/complexity": "^3.0", + "sebastian/environment": "^6.0", + "sebastian/lines-of-code": "^2.0", + "sebastian/version": "^4.0", + "theseer/tokenizer": "^1.2.0" + }, + "require-dev": { + "phpunit/phpunit": "^10.1" + }, + "suggest": { + "ext-pcov": "PHP extension that provides line coverage", + "ext-xdebug": "PHP extension that provides line coverage as well as branch and path coverage" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "10.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": "Library that provides collection, processing, and rendering functionality for PHP code coverage information.", + "homepage": "https://github.com/sebastianbergmann/php-code-coverage", + "keywords": [ + "coverage", + "testing", + "xunit" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", + "security": "https://github.com/sebastianbergmann/php-code-coverage/security/policy", + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/10.1.9" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-11-23T12:23:20+00:00" + }, + { + "name": "phpunit/php-file-iterator", + "version": "4.1.0", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-file-iterator.git", + "reference": "a95037b6d9e608ba092da1b23931e537cadc3c3c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/a95037b6d9e608ba092da1b23931e537cadc3c3c", + "reference": "a95037b6d9e608ba092da1b23931e537cadc3c3c", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "require-dev": { + "phpunit/phpunit": "^10.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "4.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": "FilterIterator implementation that filters files based on a list of suffixes.", + "homepage": "https://github.com/sebastianbergmann/php-file-iterator/", + "keywords": [ + "filesystem", + "iterator" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-file-iterator/issues", + "security": "https://github.com/sebastianbergmann/php-file-iterator/security/policy", + "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/4.1.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-08-31T06:24:48+00:00" + }, + { + "name": "phpunit/php-invoker", + "version": "4.0.0", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-invoker.git", + "reference": "f5e568ba02fa5ba0ddd0f618391d5a9ea50b06d7" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/f5e568ba02fa5ba0ddd0f618391d5a9ea50b06d7", + "reference": "f5e568ba02fa5ba0ddd0f618391d5a9ea50b06d7", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "require-dev": { + "ext-pcntl": "*", + "phpunit/phpunit": "^10.0" + }, + "suggest": { + "ext-pcntl": "*" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "4.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": "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/4.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-03T06:56:09+00:00" + }, + { + "name": "phpunit/php-text-template", + "version": "3.0.1", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-text-template.git", + "reference": "0c7b06ff49e3d5072f057eb1fa59258bf287a748" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/0c7b06ff49e3d5072f057eb1fa59258bf287a748", + "reference": "0c7b06ff49e3d5072f057eb1fa59258bf287a748", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "require-dev": { + "phpunit/phpunit": "^10.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "3.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": "Simple template engine.", + "homepage": "https://github.com/sebastianbergmann/php-text-template/", + "keywords": [ + "template" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-text-template/issues", + "security": "https://github.com/sebastianbergmann/php-text-template/security/policy", + "source": "https://github.com/sebastianbergmann/php-text-template/tree/3.0.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-08-31T14:07:24+00:00" + }, + { + "name": "phpunit/php-timer", + "version": "6.0.0", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-timer.git", + "reference": "e2a2d67966e740530f4a3343fe2e030ffdc1161d" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/e2a2d67966e740530f4a3343fe2e030ffdc1161d", + "reference": "e2a2d67966e740530f4a3343fe2e030ffdc1161d", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "require-dev": { + "phpunit/phpunit": "^10.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "6.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": "Utility class for timing", + "homepage": "https://github.com/sebastianbergmann/php-timer/", + "keywords": [ + "timer" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-timer/issues", + "source": "https://github.com/sebastianbergmann/php-timer/tree/6.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-03T06:57:52+00:00" + }, + { + "name": "sebastian/cli-parser", + "version": "2.0.0", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/cli-parser.git", + "reference": "efdc130dbbbb8ef0b545a994fd811725c5282cae" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/efdc130dbbbb8ef0b545a994fd811725c5282cae", + "reference": "efdc130dbbbb8ef0b545a994fd811725c5282cae", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "require-dev": { + "phpunit/phpunit": "^10.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "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 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/2.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-03T06:58:15+00:00" + }, + { + "name": "sebastian/code-unit", + "version": "2.0.0", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/code-unit.git", + "reference": "a81fee9eef0b7a76af11d121767abc44c104e503" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit/zipball/a81fee9eef0b7a76af11d121767abc44c104e503", + "reference": "a81fee9eef0b7a76af11d121767abc44c104e503", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "require-dev": { + "phpunit/phpunit": "^10.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "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": "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/2.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-03T06:58:43+00:00" + }, + { + "name": "sebastian/code-unit-reverse-lookup", + "version": "3.0.0", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", + "reference": "5e3a687f7d8ae33fb362c5c0743794bbb2420a1d" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/5e3a687f7d8ae33fb362c5c0743794bbb2420a1d", + "reference": "5e3a687f7d8ae33fb362c5c0743794bbb2420a1d", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "require-dev": { + "phpunit/phpunit": "^10.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "3.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + } + ], + "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/3.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-03T06:59:15+00:00" + }, + { + "name": "sebastian/comparator", + "version": "5.0.1", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/comparator.git", + "reference": "2db5010a484d53ebf536087a70b4a5423c102372" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/2db5010a484d53ebf536087a70b4a5423c102372", + "reference": "2db5010a484d53ebf536087a70b4a5423c102372", + "shasum": "" + }, + "require": { + "ext-dom": "*", + "ext-mbstring": "*", + "php": ">=8.1", + "sebastian/diff": "^5.0", + "sebastian/exporter": "^5.0" + }, + "require-dev": { + "phpunit/phpunit": "^10.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "5.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, + { + "name": "Jeff Welch", + "email": "whatthejeff@gmail.com" + }, + { + "name": "Volker Dusch", + "email": "github@wallbash.com" + }, + { + "name": "Bernhard Schussek", + "email": "bschussek@2bepublished.at" + } + ], + "description": "Provides the functionality to compare PHP values for equality", + "homepage": "https://github.com/sebastianbergmann/comparator", + "keywords": [ + "comparator", + "compare", + "equality" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/comparator/issues", + "security": "https://github.com/sebastianbergmann/comparator/security/policy", + "source": "https://github.com/sebastianbergmann/comparator/tree/5.0.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-08-14T13:18:12+00:00" + }, + { + "name": "sebastian/complexity", + "version": "3.1.0", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/complexity.git", + "reference": "68cfb347a44871f01e33ab0ef8215966432f6957" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/68cfb347a44871f01e33ab0ef8215966432f6957", + "reference": "68cfb347a44871f01e33ab0ef8215966432f6957", + "shasum": "" + }, + "require": { + "nikic/php-parser": "^4.10", + "php": ">=8.1" + }, + "require-dev": { + "phpunit/phpunit": "^10.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "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": "Library for calculating the complexity of PHP code units", + "homepage": "https://github.com/sebastianbergmann/complexity", + "support": { + "issues": "https://github.com/sebastianbergmann/complexity/issues", + "security": "https://github.com/sebastianbergmann/complexity/security/policy", + "source": "https://github.com/sebastianbergmann/complexity/tree/3.1.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-09-28T11:50:59+00:00" + }, + { + "name": "sebastian/diff", + "version": "5.0.3", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/diff.git", + "reference": "912dc2fbe3e3c1e7873313cc801b100b6c68c87b" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/912dc2fbe3e3c1e7873313cc801b100b6c68c87b", + "reference": "912dc2fbe3e3c1e7873313cc801b100b6c68c87b", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "require-dev": { + "phpunit/phpunit": "^10.0", + "symfony/process": "^4.2 || ^5" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "5.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, + { + "name": "Kore Nordmann", + "email": "mail@kore-nordmann.de" + } + ], + "description": "Diff implementation", + "homepage": "https://github.com/sebastianbergmann/diff", + "keywords": [ + "diff", + "udiff", + "unidiff", + "unified diff" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/diff/issues", + "security": "https://github.com/sebastianbergmann/diff/security/policy", + "source": "https://github.com/sebastianbergmann/diff/tree/5.0.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-05-01T07:48:21+00:00" + }, + { + "name": "sebastian/environment", + "version": "6.0.1", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/environment.git", + "reference": "43c751b41d74f96cbbd4e07b7aec9675651e2951" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/43c751b41d74f96cbbd4e07b7aec9675651e2951", + "reference": "43c751b41d74f96cbbd4e07b7aec9675651e2951", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "require-dev": { + "phpunit/phpunit": "^10.0" + }, + "suggest": { + "ext-posix": "*" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "6.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + } + ], + "description": "Provides functionality to handle HHVM/PHP environments", + "homepage": "https://github.com/sebastianbergmann/environment", + "keywords": [ + "Xdebug", + "environment", + "hhvm" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/environment/issues", + "security": "https://github.com/sebastianbergmann/environment/security/policy", + "source": "https://github.com/sebastianbergmann/environment/tree/6.0.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-04-11T05:39:26+00:00" + }, + { + "name": "sebastian/exporter", + "version": "5.1.1", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/exporter.git", + "reference": "64f51654862e0f5e318db7e9dcc2292c63cdbddc" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/64f51654862e0f5e318db7e9dcc2292c63cdbddc", + "reference": "64f51654862e0f5e318db7e9dcc2292c63cdbddc", + "shasum": "" + }, + "require": { + "ext-mbstring": "*", + "php": ">=8.1", + "sebastian/recursion-context": "^5.0" + }, + "require-dev": { + "phpunit/phpunit": "^10.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "5.1-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, + { + "name": "Jeff Welch", + "email": "whatthejeff@gmail.com" + }, + { + "name": "Volker Dusch", + "email": "github@wallbash.com" + }, + { + "name": "Adam Harvey", + "email": "aharvey@php.net" + }, + { + "name": "Bernhard Schussek", + "email": "bschussek@gmail.com" + } + ], + "description": "Provides the functionality to export PHP variables for visualization", + "homepage": "https://www.github.com/sebastianbergmann/exporter", + "keywords": [ + "export", + "exporter" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/exporter/issues", + "security": "https://github.com/sebastianbergmann/exporter/security/policy", + "source": "https://github.com/sebastianbergmann/exporter/tree/5.1.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-09-24T13:22:09+00:00" + }, + { + "name": "sebastian/global-state", + "version": "6.0.1", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/global-state.git", + "reference": "7ea9ead78f6d380d2a667864c132c2f7b83055e4" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/7ea9ead78f6d380d2a667864c132c2f7b83055e4", + "reference": "7ea9ead78f6d380d2a667864c132c2f7b83055e4", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "sebastian/object-reflector": "^3.0", + "sebastian/recursion-context": "^5.0" + }, + "require-dev": { + "ext-dom": "*", + "phpunit/phpunit": "^10.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "6.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + } + ], + "description": "Snapshotting of global state", + "homepage": "http://www.github.com/sebastianbergmann/global-state", + "keywords": [ + "global state" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/global-state/issues", + "security": "https://github.com/sebastianbergmann/global-state/security/policy", + "source": "https://github.com/sebastianbergmann/global-state/tree/6.0.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-07-19T07:19:23+00:00" + }, + { + "name": "sebastian/lines-of-code", + "version": "2.0.1", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/lines-of-code.git", + "reference": "649e40d279e243d985aa8fb6e74dd5bb28dc185d" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/649e40d279e243d985aa8fb6e74dd5bb28dc185d", + "reference": "649e40d279e243d985aa8fb6e74dd5bb28dc185d", + "shasum": "" + }, + "require": { + "nikic/php-parser": "^4.10", + "php": ">=8.1" + }, + "require-dev": { + "phpunit/phpunit": "^10.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "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 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", + "security": "https://github.com/sebastianbergmann/lines-of-code/security/policy", + "source": "https://github.com/sebastianbergmann/lines-of-code/tree/2.0.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-08-31T09:25:50+00:00" + }, + { + "name": "sebastian/object-enumerator", + "version": "5.0.0", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/object-enumerator.git", + "reference": "202d0e344a580d7f7d04b3fafce6933e59dae906" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/202d0e344a580d7f7d04b3fafce6933e59dae906", + "reference": "202d0e344a580d7f7d04b3fafce6933e59dae906", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "sebastian/object-reflector": "^3.0", + "sebastian/recursion-context": "^5.0" + }, + "require-dev": { + "phpunit/phpunit": "^10.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "5.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + } + ], + "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/5.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-03T07:08:32+00:00" + }, + { + "name": "sebastian/object-reflector", + "version": "3.0.0", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/object-reflector.git", + "reference": "24ed13d98130f0e7122df55d06c5c4942a577957" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/24ed13d98130f0e7122df55d06c5c4942a577957", + "reference": "24ed13d98130f0e7122df55d06c5c4942a577957", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "require-dev": { + "phpunit/phpunit": "^10.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "3.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + } + ], + "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/3.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-03T07:06:18+00:00" + }, + { + "name": "sebastian/recursion-context", + "version": "5.0.0", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/recursion-context.git", + "reference": "05909fb5bc7df4c52992396d0116aed689f93712" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/05909fb5bc7df4c52992396d0116aed689f93712", + "reference": "05909fb5bc7df4c52992396d0116aed689f93712", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "require-dev": { + "phpunit/phpunit": "^10.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "5.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, + { + "name": "Jeff Welch", + "email": "whatthejeff@gmail.com" + }, + { + "name": "Adam Harvey", + "email": "aharvey@php.net" + } + ], + "description": "Provides functionality to recursively process PHP variables", + "homepage": "https://github.com/sebastianbergmann/recursion-context", + "support": { + "issues": "https://github.com/sebastianbergmann/recursion-context/issues", + "source": "https://github.com/sebastianbergmann/recursion-context/tree/5.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-03T07:05:40+00:00" + }, + { + "name": "sebastian/type", + "version": "4.0.0", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/type.git", + "reference": "462699a16464c3944eefc02ebdd77882bd3925bf" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/462699a16464c3944eefc02ebdd77882bd3925bf", + "reference": "462699a16464c3944eefc02ebdd77882bd3925bf", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "require-dev": { + "phpunit/phpunit": "^10.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "4.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 types of the PHP type system", + "homepage": "https://github.com/sebastianbergmann/type", + "support": { + "issues": "https://github.com/sebastianbergmann/type/issues", + "source": "https://github.com/sebastianbergmann/type/tree/4.0.0" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-03T07:10:45+00:00" + }, + { + "name": "sebastian/version", + "version": "4.0.1", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/version.git", + "reference": "c51fa83a5d8f43f1402e3f32a005e6262244ef17" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/c51fa83a5d8f43f1402e3f32a005e6262244ef17", + "reference": "c51fa83a5d8f43f1402e3f32a005e6262244ef17", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "4.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 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/4.0.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-07T11:34:05+00:00" + }, + { + "name": "theseer/tokenizer", + "version": "1.2.2", + "source": { + "type": "git", + "url": "https://github.com/theseer/tokenizer.git", + "reference": "b2ad5003ca10d4ee50a12da31de12a5774ba6b96" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/theseer/tokenizer/zipball/b2ad5003ca10d4ee50a12da31de12a5774ba6b96", + "reference": "b2ad5003ca10d4ee50a12da31de12a5774ba6b96", + "shasum": "" + }, + "require": { + "ext-dom": "*", + "ext-tokenizer": "*", + "ext-xmlwriter": "*", + "php": "^7.2 || ^8.0" + }, + "type": "library", + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Arne Blankerts", + "email": "arne@blankerts.de", + "role": "Developer" + } + ], + "description": "A small library for converting tokenized PHP source code into XML and potentially other formats", + "support": { + "issues": "https://github.com/theseer/tokenizer/issues", + "source": "https://github.com/theseer/tokenizer/tree/1.2.2" + }, + "funding": [ + { + "url": "https://github.com/theseer", + "type": "github" + } + ], + "time": "2023-11-20T00:12:19+00:00" + } + ], + "packages-dev": [], + "aliases": [], + "minimum-stability": "stable", + "stability-flags": [], + "prefer-stable": true, + "prefer-lowest": false, + "platform": { + "php": ">=8.1", + "ext-dom": "*", + "ext-json": "*", + "ext-libxml": "*", + "ext-mbstring": "*", + "ext-xml": "*", + "ext-xmlwriter": "*" + }, + "platform-dev": [], + "platform-overrides": { + "php": "8.1.0" + }, + "plugin-api-version": "2.6.0" +} diff --git a/vendor/phpunit/phpunit/phpunit b/vendor/phpunit/phpunit/phpunit index 62ab6325..624c8b4d 100644 --- a/vendor/phpunit/phpunit/phpunit +++ b/vendor/phpunit/phpunit/phpunit @@ -38,22 +38,31 @@ if (version_compare('8.1.0', PHP_VERSION, '>')) { die(1); } -foreach (['dom', 'json', 'libxml', 'mbstring', 'tokenizer', 'xml', 'xmlwriter'] as $extension) { - if (extension_loaded($extension)) { - continue; - } +$requiredExtensions = ['dom', 'json', 'libxml', 'mbstring', 'tokenizer', 'xml', 'xmlwriter']; +$unavailableExtensions = array_filter( + $requiredExtensions, + static function ($extension) { + return !extension_loaded($extension); + } +); + +if ([] !== $unavailableExtensions) { fwrite( STDERR, sprintf( - 'PHPUnit requires the "%s" extension.' . PHP_EOL, - $extension + 'PHPUnit requires the "%s" extensions, but the "%s" %s not available.' . PHP_EOL, + implode('", "', $requiredExtensions), + implode('", "', $unavailableExtensions), + count($unavailableExtensions) === 1 ? 'extension is' : 'extensions are' ) ); die(1); } +unset($requiredExtensions, $unavailableExtensions); + if (!ini_get('date.timezone')) { ini_set('date.timezone', 'UTC'); } diff --git a/vendor/phpunit/phpunit/phpunit.xsd b/vendor/phpunit/phpunit/phpunit.xsd index 480d54de..42a84489 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 10.0 may be structured. + This Schema file defines the rules by which the XML configuration file of PHPUnit 10.5 may be structured. @@ -11,18 +11,49 @@ Root Element - + - + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -56,7 +87,7 @@ - + @@ -81,23 +112,6 @@ - - - - - - - - - - - - - - - - - @@ -120,17 +134,6 @@ - - - - - - - - - - - @@ -170,20 +173,26 @@ + + - - - - - - - + + + + + + + + + + + @@ -213,6 +222,7 @@ + @@ -230,12 +240,40 @@ - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/vendor/phpunit/phpunit/schema/10.0.xsd b/vendor/phpunit/phpunit/schema/10.0.xsd new file mode 100644 index 00000000..480d54de --- /dev/null +++ b/vendor/phpunit/phpunit/schema/10.0.xsd @@ -0,0 +1,284 @@ + + + + + This Schema file defines the rules by which the XML configuration file of PHPUnit 10.0 may be structured. + + + + + + Root Element + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + The main type specifying the document structure + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/vendor/phpunit/phpunit/src/Event/Dispatcher/DirectDispatcher.php b/vendor/phpunit/phpunit/src/Event/Dispatcher/DirectDispatcher.php index 81f07c81..042b2418 100644 --- a/vendor/phpunit/phpunit/src/Event/Dispatcher/DirectDispatcher.php +++ b/vendor/phpunit/phpunit/src/Event/Dispatcher/DirectDispatcher.php @@ -10,7 +10,10 @@ namespace PHPUnit\Event; use function array_key_exists; +use function dirname; use function sprintf; +use function str_starts_with; +use Throwable; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit @@ -20,7 +23,7 @@ final class DirectDispatcher implements SubscribableDispatcher private readonly TypeMap $typeMap; /** - * @psalm-var array> + * @psalm-var array> */ private array $subscribers = []; @@ -49,8 +52,8 @@ final class DirectDispatcher implements SubscribableDispatcher throw new UnknownSubscriberTypeException( sprintf( 'Subscriber "%s" does not implement any known interface - did you forget to register it?', - $subscriber::class - ) + $subscriber::class, + ), ); } @@ -64,6 +67,7 @@ final class DirectDispatcher implements SubscribableDispatcher } /** + * @throws Throwable * @throws UnknownEventTypeException */ public function dispatch(Event $event): void @@ -74,13 +78,17 @@ final class DirectDispatcher implements SubscribableDispatcher throw new UnknownEventTypeException( sprintf( 'Unknown event type "%s"', - $eventClassName - ) + $eventClassName, + ), ); } foreach ($this->tracers as $tracer) { - $tracer->trace($event); + try { + $tracer->trace($event); + } catch (Throwable $t) { + $this->handleThrowable($t); + } } if (!array_key_exists($eventClassName, $this->subscribers)) { @@ -88,7 +96,37 @@ final class DirectDispatcher implements SubscribableDispatcher } foreach ($this->subscribers[$eventClassName] as $subscriber) { - $subscriber->notify($event); + try { + $subscriber->notify($event); + } catch (Throwable $t) { + $this->handleThrowable($t); + } } } + + /** + * @throws Throwable + */ + public function handleThrowable(Throwable $t): void + { + if ($this->isThrowableFromThirdPartySubscriber($t)) { + Facade::emitter()->testRunnerTriggeredWarning( + sprintf( + 'Exception in third-party event subscriber: %s%s%s', + $t->getMessage(), + PHP_EOL, + $t->getTraceAsString(), + ), + ); + + return; + } + + throw $t; + } + + private function isThrowableFromThirdPartySubscriber(Throwable $t): bool + { + return !str_starts_with($t->getFile(), dirname(__DIR__, 2)); + } } diff --git a/vendor/phpunit/phpunit/src/Event/Emitter/DispatchingEmitter.php b/vendor/phpunit/phpunit/src/Event/Emitter/DispatchingEmitter.php index e7077134..2f9f97e5 100644 --- a/vendor/phpunit/phpunit/src/Event/Emitter/DispatchingEmitter.php +++ b/vendor/phpunit/phpunit/src/Event/Emitter/DispatchingEmitter.php @@ -9,17 +9,21 @@ */ namespace PHPUnit\Event; +use PHPUnit\Event\Code\ClassMethod; use PHPUnit\Event\Code\ComparisonFailure; use PHPUnit\Event\Code\Throwable; +use PHPUnit\Event\Test\DataProviderMethodCalled; +use PHPUnit\Event\Test\DataProviderMethodFinished; use PHPUnit\Event\TestSuite\Filtered as TestSuiteFiltered; use PHPUnit\Event\TestSuite\Finished as TestSuiteFinished; use PHPUnit\Event\TestSuite\Loaded as TestSuiteLoaded; +use PHPUnit\Event\TestSuite\Skipped as TestSuiteSkipped; use PHPUnit\Event\TestSuite\Sorted as TestSuiteSorted; use PHPUnit\Event\TestSuite\Started as TestSuiteStarted; use PHPUnit\Event\TestSuite\TestSuite; use PHPUnit\Framework\Constraint; use PHPUnit\TextUI\Configuration\Configuration; -use SebastianBergmann\Exporter\Exporter; +use PHPUnit\Util\Exporter; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit @@ -30,6 +34,7 @@ final class DispatchingEmitter implements Emitter private readonly Telemetry\System $system; private readonly Telemetry\Snapshot $startSnapshot; private Telemetry\Snapshot $previousSnapshot; + private bool $exportObjects = false; public function __construct(Dispatcher $dispatcher, Telemetry\System $system) { @@ -40,6 +45,22 @@ final class DispatchingEmitter implements Emitter $this->previousSnapshot = $system->snapshot(); } + /** + * @deprecated + */ + public function exportObjects(): void + { + $this->exportObjects = true; + } + + /** + * @deprecated + */ + public function exportsObjects(): bool + { + return $this->exportObjects; + } + /** * @throws InvalidArgumentException * @throws UnknownEventTypeException @@ -49,8 +70,8 @@ final class DispatchingEmitter implements Emitter $this->dispatcher->dispatch( new Application\Started( $this->telemetryInfo(), - new Runtime\Runtime - ) + new Runtime\Runtime, + ), ); } @@ -62,8 +83,8 @@ final class DispatchingEmitter implements Emitter { $this->dispatcher->dispatch( new TestRunner\Started( - $this->telemetryInfo() - ) + $this->telemetryInfo(), + ), ); } @@ -76,8 +97,8 @@ final class DispatchingEmitter implements Emitter $this->dispatcher->dispatch( new TestRunner\Configured( $this->telemetryInfo(), - $configuration - ) + $configuration, + ), ); } @@ -90,8 +111,8 @@ final class DispatchingEmitter implements Emitter $this->dispatcher->dispatch( new TestRunner\BootstrapFinished( $this->telemetryInfo(), - $filename - ) + $filename, + ), ); } @@ -106,8 +127,8 @@ final class DispatchingEmitter implements Emitter $this->telemetryInfo(), $filename, $name, - $version - ) + $version, + ), ); } @@ -124,8 +145,38 @@ final class DispatchingEmitter implements Emitter new TestRunner\ExtensionBootstrapped( $this->telemetryInfo(), $className, - $parameters - ) + $parameters, + ), + ); + } + + /** + * @throws InvalidArgumentException + * @throws UnknownEventTypeException + */ + public function dataProviderMethodCalled(ClassMethod $testMethod, ClassMethod $dataProviderMethod): void + { + $this->dispatcher->dispatch( + new DataProviderMethodCalled( + $this->telemetryInfo(), + $testMethod, + $dataProviderMethod, + ), + ); + } + + /** + * @throws InvalidArgumentException + * @throws UnknownEventTypeException + */ + public function dataProviderMethodFinished(ClassMethod $testMethod, ClassMethod ...$calledMethods): void + { + $this->dispatcher->dispatch( + new DataProviderMethodFinished( + $this->telemetryInfo(), + $testMethod, + ...$calledMethods, + ), ); } @@ -138,8 +189,8 @@ final class DispatchingEmitter implements Emitter $this->dispatcher->dispatch( new TestSuiteLoaded( $this->telemetryInfo(), - $testSuite - ) + $testSuite, + ), ); } @@ -152,8 +203,8 @@ final class DispatchingEmitter implements Emitter $this->dispatcher->dispatch( new TestSuiteFiltered( $this->telemetryInfo(), - $testSuite - ) + $testSuite, + ), ); } @@ -168,8 +219,8 @@ final class DispatchingEmitter implements Emitter $this->telemetryInfo(), $executionOrder, $executionOrderDefects, - $resolveDependencies - ) + $resolveDependencies, + ), ); } @@ -181,8 +232,8 @@ final class DispatchingEmitter implements Emitter { $this->dispatcher->dispatch( new TestRunner\EventFacadeSealed( - $this->telemetryInfo() - ) + $this->telemetryInfo(), + ), ); } @@ -195,8 +246,45 @@ final class DispatchingEmitter implements Emitter $this->dispatcher->dispatch( new TestRunner\ExecutionStarted( $this->telemetryInfo(), - $testSuite - ) + $testSuite, + ), + ); + } + + /** + * @throws InvalidArgumentException + * @throws UnknownEventTypeException + */ + public function testRunnerDisabledGarbageCollection(): void + { + $this->dispatcher->dispatch( + new TestRunner\GarbageCollectionDisabled($this->telemetryInfo()), + ); + } + + /** + * @throws InvalidArgumentException + * @throws UnknownEventTypeException + */ + public function testRunnerTriggeredGarbageCollection(): void + { + $this->dispatcher->dispatch( + new TestRunner\GarbageCollectionTriggered($this->telemetryInfo()), + ); + } + + /** + * @throws InvalidArgumentException + * @throws UnknownEventTypeException + */ + public function testSuiteSkipped(TestSuite $testSuite, string $message): void + { + $this->dispatcher->dispatch( + new TestSuiteSkipped( + $this->telemetryInfo(), + $testSuite, + $message, + ), ); } @@ -209,8 +297,8 @@ final class DispatchingEmitter implements Emitter $this->dispatcher->dispatch( new TestSuiteStarted( $this->telemetryInfo(), - $testSuite - ) + $testSuite, + ), ); } @@ -223,8 +311,22 @@ final class DispatchingEmitter implements Emitter $this->dispatcher->dispatch( new Test\PreparationStarted( $this->telemetryInfo(), - $test - ) + $test, + ), + ); + } + + /** + * @throws InvalidArgumentException + * @throws UnknownEventTypeException + */ + public function testPreparationFailed(Code\Test $test): void + { + $this->dispatcher->dispatch( + new Test\PreparationFailed( + $this->telemetryInfo(), + $test, + ), ); } @@ -240,8 +342,8 @@ final class DispatchingEmitter implements Emitter new Test\BeforeFirstTestMethodCalled( $this->telemetryInfo(), $testClassName, - $calledMethod - ) + $calledMethod, + ), ); } @@ -258,8 +360,8 @@ final class DispatchingEmitter implements Emitter $this->telemetryInfo(), $testClassName, $calledMethod, - $throwable - ) + $throwable, + ), ); } @@ -275,8 +377,8 @@ final class DispatchingEmitter implements Emitter new Test\BeforeFirstTestMethodFinished( $this->telemetryInfo(), $testClassName, - ...$calledMethods - ) + ...$calledMethods, + ), ); } @@ -292,8 +394,8 @@ final class DispatchingEmitter implements Emitter new Test\BeforeTestMethodCalled( $this->telemetryInfo(), $testClassName, - $calledMethod - ) + $calledMethod, + ), ); } @@ -309,8 +411,8 @@ final class DispatchingEmitter implements Emitter new Test\BeforeTestMethodFinished( $this->telemetryInfo(), $testClassName, - ...$calledMethods - ) + ...$calledMethods, + ), ); } @@ -326,8 +428,8 @@ final class DispatchingEmitter implements Emitter new Test\PreConditionCalled( $this->telemetryInfo(), $testClassName, - $calledMethod - ) + $calledMethod, + ), ); } @@ -343,8 +445,8 @@ final class DispatchingEmitter implements Emitter new Test\PreConditionFinished( $this->telemetryInfo(), $testClassName, - ...$calledMethods - ) + ...$calledMethods, + ), ); } @@ -357,8 +459,8 @@ final class DispatchingEmitter implements Emitter $this->dispatcher->dispatch( new Test\Prepared( $this->telemetryInfo(), - $test - ) + $test, + ), ); } @@ -373,42 +475,46 @@ final class DispatchingEmitter implements Emitter $this->dispatcher->dispatch( new Test\ComparatorRegistered( $this->telemetryInfo(), - $className - ) + $className, + ), ); } /** * @throws InvalidArgumentException * @throws UnknownEventTypeException + * + * @deprecated */ public function testAssertionSucceeded(mixed $value, Constraint\Constraint $constraint, string $message): void { $this->dispatcher->dispatch( new Test\AssertionSucceeded( $this->telemetryInfo(), - (new Exporter)->export($value), - $constraint->toString(), + Exporter::export($value, $this->exportObjects), + $constraint->toString($this->exportObjects), $constraint->count(), $message, - ) + ), ); } /** * @throws InvalidArgumentException * @throws UnknownEventTypeException + * + * @deprecated */ public function testAssertionFailed(mixed $value, Constraint\Constraint $constraint, string $message): void { $this->dispatcher->dispatch( new Test\AssertionFailed( $this->telemetryInfo(), - (new Exporter)->export($value), - $constraint->toString(), + Exporter::export($value, $this->exportObjects), + $constraint->toString($this->exportObjects), $constraint->count(), $message, - ) + ), ); } @@ -423,8 +529,8 @@ final class DispatchingEmitter implements Emitter $this->dispatcher->dispatch( new Test\MockObjectCreated( $this->telemetryInfo(), - $className - ) + $className, + ), ); } @@ -439,8 +545,8 @@ final class DispatchingEmitter implements Emitter $this->dispatcher->dispatch( new Test\MockObjectForIntersectionOfInterfacesCreated( $this->telemetryInfo(), - $interfaces - ) + $interfaces, + ), ); } @@ -455,8 +561,8 @@ final class DispatchingEmitter implements Emitter $this->dispatcher->dispatch( new Test\MockObjectForTraitCreated( $this->telemetryInfo(), - $traitName - ) + $traitName, + ), ); } @@ -471,8 +577,8 @@ final class DispatchingEmitter implements Emitter $this->dispatcher->dispatch( new Test\MockObjectForAbstractClassCreated( $this->telemetryInfo(), - $className - ) + $className, + ), ); } @@ -493,8 +599,8 @@ final class DispatchingEmitter implements Emitter $mockClassName, $methods, $callOriginalConstructor, - $options - ) + $options, + ), ); } @@ -510,8 +616,8 @@ final class DispatchingEmitter implements Emitter new Test\PartialMockObjectCreated( $this->telemetryInfo(), $className, - ...$methodNames - ) + ...$methodNames, + ), ); } @@ -527,8 +633,8 @@ final class DispatchingEmitter implements Emitter new Test\TestProxyCreated( $this->telemetryInfo(), $className, - (new Exporter)->export($constructorArguments) - ) + Exporter::export($constructorArguments, $this->exportObjects), + ), ); } @@ -543,8 +649,8 @@ final class DispatchingEmitter implements Emitter $this->dispatcher->dispatch( new Test\TestStubCreated( $this->telemetryInfo(), - $className - ) + $className, + ), ); } @@ -559,8 +665,8 @@ final class DispatchingEmitter implements Emitter $this->dispatcher->dispatch( new Test\TestStubForIntersectionOfInterfacesCreated( $this->telemetryInfo(), - $interfaces - ) + $interfaces, + ), ); } @@ -574,8 +680,8 @@ final class DispatchingEmitter implements Emitter new Test\Errored( $this->telemetryInfo(), $test, - $throwable - ) + $throwable, + ), ); } @@ -590,8 +696,8 @@ final class DispatchingEmitter implements Emitter $this->telemetryInfo(), $test, $throwable, - $comparisonFailure - ) + $comparisonFailure, + ), ); } @@ -605,7 +711,7 @@ final class DispatchingEmitter implements Emitter new Test\Passed( $this->telemetryInfo(), $test, - ) + ), ); } @@ -619,8 +725,8 @@ final class DispatchingEmitter implements Emitter new Test\ConsideredRisky( $this->telemetryInfo(), $test, - $message - ) + $message, + ), ); } @@ -634,8 +740,8 @@ final class DispatchingEmitter implements Emitter new Test\MarkedIncomplete( $this->telemetryInfo(), $test, - $throwable - ) + $throwable, + ), ); } @@ -649,8 +755,8 @@ final class DispatchingEmitter implements Emitter new Test\Skipped( $this->telemetryInfo(), $test, - $message - ) + $message, + ), ); } @@ -664,8 +770,8 @@ final class DispatchingEmitter implements Emitter new Test\PhpunitDeprecationTriggered( $this->telemetryInfo(), $test, - $message - ) + $message, + ), ); } @@ -673,7 +779,7 @@ final class DispatchingEmitter implements Emitter * @throws InvalidArgumentException * @throws UnknownEventTypeException */ - public function testTriggeredPhpDeprecation(Code\Test $test, string $message, string $file, int $line): void + public function testTriggeredPhpDeprecation(Code\Test $test, string $message, string $file, int $line, bool $suppressed, bool $ignoredByBaseline, bool $ignoredByTest): void { $this->dispatcher->dispatch( new Test\PhpDeprecationTriggered( @@ -681,8 +787,11 @@ final class DispatchingEmitter implements Emitter $test, $message, $file, - $line - ) + $line, + $suppressed, + $ignoredByBaseline, + $ignoredByTest, + ), ); } @@ -690,7 +799,7 @@ final class DispatchingEmitter implements Emitter * @throws InvalidArgumentException * @throws UnknownEventTypeException */ - public function testTriggeredDeprecation(Code\Test $test, string $message, string $file, int $line): void + public function testTriggeredDeprecation(Code\Test $test, string $message, string $file, int $line, bool $suppressed, bool $ignoredByBaseline, bool $ignoredByTest): void { $this->dispatcher->dispatch( new Test\DeprecationTriggered( @@ -698,8 +807,11 @@ final class DispatchingEmitter implements Emitter $test, $message, $file, - $line - ) + $line, + $suppressed, + $ignoredByBaseline, + $ignoredByTest, + ), ); } @@ -707,7 +819,7 @@ final class DispatchingEmitter implements Emitter * @throws InvalidArgumentException * @throws UnknownEventTypeException */ - public function testTriggeredError(Code\Test $test, string $message, string $file, int $line): void + public function testTriggeredError(Code\Test $test, string $message, string $file, int $line, bool $suppressed): void { $this->dispatcher->dispatch( new Test\ErrorTriggered( @@ -715,8 +827,9 @@ final class DispatchingEmitter implements Emitter $test, $message, $file, - $line - ) + $line, + $suppressed, + ), ); } @@ -724,7 +837,7 @@ final class DispatchingEmitter implements Emitter * @throws InvalidArgumentException * @throws UnknownEventTypeException */ - public function testTriggeredNotice(Code\Test $test, string $message, string $file, int $line): void + public function testTriggeredNotice(Code\Test $test, string $message, string $file, int $line, bool $suppressed, bool $ignoredByBaseline): void { $this->dispatcher->dispatch( new Test\NoticeTriggered( @@ -732,8 +845,10 @@ final class DispatchingEmitter implements Emitter $test, $message, $file, - $line - ) + $line, + $suppressed, + $ignoredByBaseline, + ), ); } @@ -741,7 +856,7 @@ final class DispatchingEmitter implements Emitter * @throws InvalidArgumentException * @throws UnknownEventTypeException */ - public function testTriggeredPhpNotice(Code\Test $test, string $message, string $file, int $line): void + public function testTriggeredPhpNotice(Code\Test $test, string $message, string $file, int $line, bool $suppressed, bool $ignoredByBaseline): void { $this->dispatcher->dispatch( new Test\PhpNoticeTriggered( @@ -749,8 +864,10 @@ final class DispatchingEmitter implements Emitter $test, $message, $file, - $line - ) + $line, + $suppressed, + $ignoredByBaseline, + ), ); } @@ -758,7 +875,7 @@ final class DispatchingEmitter implements Emitter * @throws InvalidArgumentException * @throws UnknownEventTypeException */ - public function testTriggeredWarning(Code\Test $test, string $message, string $file, int $line): void + public function testTriggeredWarning(Code\Test $test, string $message, string $file, int $line, bool $suppressed, bool $ignoredByBaseline): void { $this->dispatcher->dispatch( new Test\WarningTriggered( @@ -766,8 +883,10 @@ final class DispatchingEmitter implements Emitter $test, $message, $file, - $line - ) + $line, + $suppressed, + $ignoredByBaseline, + ), ); } @@ -775,7 +894,7 @@ final class DispatchingEmitter implements Emitter * @throws InvalidArgumentException * @throws UnknownEventTypeException */ - public function testTriggeredPhpWarning(Code\Test $test, string $message, string $file, int $line): void + public function testTriggeredPhpWarning(Code\Test $test, string $message, string $file, int $line, bool $suppressed, bool $ignoredByBaseline): void { $this->dispatcher->dispatch( new Test\PhpWarningTriggered( @@ -783,8 +902,10 @@ final class DispatchingEmitter implements Emitter $test, $message, $file, - $line - ) + $line, + $suppressed, + $ignoredByBaseline, + ), ); } @@ -799,7 +920,7 @@ final class DispatchingEmitter implements Emitter $this->telemetryInfo(), $test, $message, - ) + ), ); } @@ -814,7 +935,23 @@ final class DispatchingEmitter implements Emitter $this->telemetryInfo(), $test, $message, - ) + ), + ); + } + + /** + * @psalm-param non-empty-string $output + * + * @throws InvalidArgumentException + * @throws UnknownEventTypeException + */ + public function testPrintedUnexpectedOutput(string $output): void + { + $this->dispatcher->dispatch( + new Test\PrintedUnexpectedOutput( + $this->telemetryInfo(), + $output, + ), ); } @@ -828,8 +965,8 @@ final class DispatchingEmitter implements Emitter new Test\Finished( $this->telemetryInfo(), $test, - $numberOfAssertionsPerformed - ) + $numberOfAssertionsPerformed, + ), ); } @@ -845,8 +982,8 @@ final class DispatchingEmitter implements Emitter new Test\PostConditionCalled( $this->telemetryInfo(), $testClassName, - $calledMethod - ) + $calledMethod, + ), ); } @@ -862,8 +999,8 @@ final class DispatchingEmitter implements Emitter new Test\PostConditionFinished( $this->telemetryInfo(), $testClassName, - ...$calledMethods - ) + ...$calledMethods, + ), ); } @@ -879,8 +1016,8 @@ final class DispatchingEmitter implements Emitter new Test\AfterTestMethodCalled( $this->telemetryInfo(), $testClassName, - $calledMethod - ) + $calledMethod, + ), ); } @@ -896,8 +1033,8 @@ final class DispatchingEmitter implements Emitter new Test\AfterTestMethodFinished( $this->telemetryInfo(), $testClassName, - ...$calledMethods - ) + ...$calledMethods, + ), ); } @@ -913,8 +1050,8 @@ final class DispatchingEmitter implements Emitter new Test\AfterLastTestMethodCalled( $this->telemetryInfo(), $testClassName, - $calledMethod - ) + $calledMethod, + ), ); } @@ -930,8 +1067,8 @@ final class DispatchingEmitter implements Emitter new Test\AfterLastTestMethodFinished( $this->telemetryInfo(), $testClassName, - ...$calledMethods - ) + ...$calledMethods, + ), ); } @@ -945,7 +1082,7 @@ final class DispatchingEmitter implements Emitter new TestSuiteFinished( $this->telemetryInfo(), $testSuite, - ) + ), ); } @@ -958,8 +1095,8 @@ final class DispatchingEmitter implements Emitter $this->dispatcher->dispatch( new TestRunner\DeprecationTriggered( $this->telemetryInfo(), - $message - ) + $message, + ), ); } @@ -972,8 +1109,30 @@ final class DispatchingEmitter implements Emitter $this->dispatcher->dispatch( new TestRunner\WarningTriggered( $this->telemetryInfo(), - $message - ) + $message, + ), + ); + } + + /** + * @throws InvalidArgumentException + * @throws UnknownEventTypeException + */ + public function testRunnerEnabledGarbageCollection(): void + { + $this->dispatcher->dispatch( + new TestRunner\GarbageCollectionEnabled($this->telemetryInfo()), + ); + } + + /** + * @throws InvalidArgumentException + * @throws UnknownEventTypeException + */ + public function testRunnerExecutionAborted(): void + { + $this->dispatcher->dispatch( + new TestRunner\ExecutionAborted($this->telemetryInfo()), ); } @@ -984,7 +1143,7 @@ final class DispatchingEmitter implements Emitter public function testRunnerExecutionFinished(): void { $this->dispatcher->dispatch( - new TestRunner\ExecutionFinished($this->telemetryInfo()) + new TestRunner\ExecutionFinished($this->telemetryInfo()), ); } @@ -995,7 +1154,7 @@ final class DispatchingEmitter implements Emitter public function testRunnerFinished(): void { $this->dispatcher->dispatch( - new TestRunner\Finished($this->telemetryInfo()) + new TestRunner\Finished($this->telemetryInfo()), ); } @@ -1008,8 +1167,8 @@ final class DispatchingEmitter implements Emitter $this->dispatcher->dispatch( new Application\Finished( $this->telemetryInfo(), - $shellExitCode - ) + $shellExitCode, + ), ); } diff --git a/vendor/phpunit/phpunit/src/Event/Emitter/Emitter.php b/vendor/phpunit/phpunit/src/Event/Emitter/Emitter.php index 16ac5eca..cacfe72a 100644 --- a/vendor/phpunit/phpunit/src/Event/Emitter/Emitter.php +++ b/vendor/phpunit/phpunit/src/Event/Emitter/Emitter.php @@ -9,6 +9,7 @@ */ namespace PHPUnit\Event; +use PHPUnit\Event\Code\ClassMethod; use PHPUnit\Event\Code\ComparisonFailure; use PHPUnit\Event\Code\Throwable; use PHPUnit\Event\TestSuite\TestSuite; @@ -20,6 +21,16 @@ use PHPUnit\TextUI\Configuration\Configuration; */ interface Emitter { + /** + * @deprecated + */ + public function exportObjects(): void; + + /** + * @deprecated + */ + public function exportsObjects(): bool; + public function applicationStarted(): void; public function testRunnerStarted(): void; @@ -36,6 +47,10 @@ interface Emitter */ public function testRunnerBootstrappedExtension(string $className, array $parameters): void; + public function dataProviderMethodCalled(ClassMethod $testMethod, ClassMethod $dataProviderMethod): void; + + public function dataProviderMethodFinished(ClassMethod $testMethod, ClassMethod ...$calledMethods): void; + public function testSuiteLoaded(TestSuite $testSuite): void; public function testSuiteFiltered(TestSuite $testSuite): void; @@ -46,10 +61,18 @@ interface Emitter public function testRunnerExecutionStarted(TestSuite $testSuite): void; + public function testRunnerDisabledGarbageCollection(): void; + + public function testRunnerTriggeredGarbageCollection(): void; + + public function testSuiteSkipped(TestSuite $testSuite, string $message): void; + public function testSuiteStarted(TestSuite $testSuite): void; public function testPreparationStarted(Code\Test $test): void; + public function testPreparationFailed(Code\Test $test): void; + /** * @psalm-param class-string $testClassName */ @@ -92,8 +115,14 @@ interface Emitter */ public function testRegisteredComparator(string $className): void; + /** + * @deprecated + */ public function testAssertionSucceeded(mixed $value, Constraint\Constraint $constraint, string $message): void; + /** + * @deprecated + */ public function testAssertionFailed(mixed $value, Constraint\Constraint $constraint, string $message): void; /** @@ -156,24 +185,29 @@ interface Emitter public function testTriggeredPhpunitDeprecation(Code\Test $test, string $message): void; - public function testTriggeredPhpDeprecation(Code\Test $test, string $message, string $file, int $line): void; + public function testTriggeredPhpDeprecation(Code\Test $test, string $message, string $file, int $line, bool $suppressed, bool $ignoredByBaseline, bool $ignoredByTest): void; - public function testTriggeredDeprecation(Code\Test $test, string $message, string $file, int $line): void; + public function testTriggeredDeprecation(Code\Test $test, string $message, string $file, int $line, bool $suppressed, bool $ignoredByBaseline, bool $ignoredByTest): void; - public function testTriggeredError(Code\Test $test, string $message, string $file, int $line): void; + public function testTriggeredError(Code\Test $test, string $message, string $file, int $line, bool $suppressed): void; - public function testTriggeredNotice(Code\Test $test, string $message, string $file, int $line): void; + public function testTriggeredNotice(Code\Test $test, string $message, string $file, int $line, bool $suppressed, bool $ignoredByBaseline): void; - public function testTriggeredPhpNotice(Code\Test $test, string $message, string $file, int $line): void; + public function testTriggeredPhpNotice(Code\Test $test, string $message, string $file, int $line, bool $suppressed, bool $ignoredByBaseline): void; - public function testTriggeredWarning(Code\Test $test, string $message, string $file, int $line): void; + public function testTriggeredWarning(Code\Test $test, string $message, string $file, int $line, bool $suppressed, bool $ignoredByBaseline): void; - public function testTriggeredPhpWarning(Code\Test $test, string $message, string $file, int $line): void; + public function testTriggeredPhpWarning(Code\Test $test, string $message, string $file, int $line, bool $suppressed, bool $ignoredByBaseline): void; public function testTriggeredPhpunitError(Code\Test $test, string $message): void; public function testTriggeredPhpunitWarning(Code\Test $test, string $message): void; + /** + * @psalm-param non-empty-string $output + */ + public function testPrintedUnexpectedOutput(string $output): void; + public function testFinished(Code\Test $test, int $numberOfAssertionsPerformed): void; /** @@ -212,6 +246,10 @@ interface Emitter public function testRunnerTriggeredWarning(string $message): void; + public function testRunnerEnabledGarbageCollection(): void; + + public function testRunnerExecutionAborted(): void; + public function testRunnerExecutionFinished(): void; public function testRunnerFinished(): void; diff --git a/vendor/phpunit/phpunit/src/Event/Events/Application/Finished.php b/vendor/phpunit/phpunit/src/Event/Events/Application/Finished.php index e4b1e3d4..e196c4f6 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Application/Finished.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Application/Finished.php @@ -43,7 +43,7 @@ final class Finished implements Event { return sprintf( 'PHPUnit Finished (Shell Exit Code: %d)', - $this->shellExitCode + $this->shellExitCode, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Application/Started.php b/vendor/phpunit/phpunit/src/Event/Events/Application/Started.php index 04dfb5f6..da570a02 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Application/Started.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Application/Started.php @@ -44,7 +44,7 @@ final class Started implements Event { return sprintf( 'PHPUnit Started (%s)', - $this->runtime->asString() + $this->runtime->asString(), ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Assertion/AssertionFailed.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Assertion/AssertionFailed.php index 26c5d7ca..68954f20 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/Assertion/AssertionFailed.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Assertion/AssertionFailed.php @@ -15,16 +15,18 @@ use PHPUnit\Event\Telemetry; /** * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @deprecated */ final class AssertionFailed implements Event { private readonly Telemetry\Info $telemetryInfo; - private readonly mixed $value; + private readonly string $value; private readonly string $constraint; private readonly int $count; private readonly string $message; - public function __construct(Telemetry\Info $telemetryInfo, mixed $value, string $constraint, int $count, string $message) + public function __construct(Telemetry\Info $telemetryInfo, string $value, string $constraint, int $count, string $message) { $this->telemetryInfo = $telemetryInfo; $this->value = $value; @@ -38,7 +40,7 @@ final class AssertionFailed implements Event return $this->telemetryInfo; } - public function value(): mixed + public function value(): string { return $this->value; } @@ -60,7 +62,7 @@ final class AssertionFailed implements Event if (!empty($this->message)) { $message = sprintf( ', Message: %s', - $this->message + $this->message, ); } @@ -68,7 +70,7 @@ final class AssertionFailed implements Event 'Assertion Failed (Constraint: %s, Value: %s%s)', $this->constraint, $this->value, - $message + $message, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Assertion/AssertionFailedSubscriber.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Assertion/AssertionFailedSubscriber.php index a14cd5f5..c569bcc2 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/Assertion/AssertionFailedSubscriber.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Assertion/AssertionFailedSubscriber.php @@ -13,6 +13,8 @@ use PHPUnit\Event\Subscriber; /** * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @deprecated */ interface AssertionFailedSubscriber extends Subscriber { diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Assertion/AssertionSucceeded.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Assertion/AssertionSucceeded.php index 3e9acac6..d4f85484 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/Assertion/AssertionSucceeded.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Assertion/AssertionSucceeded.php @@ -15,16 +15,18 @@ use PHPUnit\Event\Telemetry; /** * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @deprecated */ final class AssertionSucceeded implements Event { private readonly Telemetry\Info $telemetryInfo; - private readonly mixed $value; + private readonly string $value; private readonly string $constraint; private readonly int $count; private readonly string $message; - public function __construct(Telemetry\Info $telemetryInfo, mixed $value, string $constraint, int $count, string $message) + public function __construct(Telemetry\Info $telemetryInfo, string $value, string $constraint, int $count, string $message) { $this->telemetryInfo = $telemetryInfo; $this->value = $value; @@ -38,7 +40,7 @@ final class AssertionSucceeded implements Event return $this->telemetryInfo; } - public function value(): mixed + public function value(): string { return $this->value; } @@ -60,7 +62,7 @@ final class AssertionSucceeded implements Event if (!empty($this->message)) { $message = sprintf( ', Message: %s', - $this->message + $this->message, ); } @@ -68,7 +70,7 @@ final class AssertionSucceeded implements Event 'Assertion Succeeded (Constraint: %s, Value: %s%s)', $this->constraint, $this->value, - $message + $message, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Assertion/AssertionSucceededSubscriber.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Assertion/AssertionSucceededSubscriber.php index 535860a3..59d72c0f 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/Assertion/AssertionSucceededSubscriber.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Assertion/AssertionSucceededSubscriber.php @@ -13,6 +13,8 @@ use PHPUnit\Event\Subscriber; /** * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @deprecated */ interface AssertionSucceededSubscriber extends Subscriber { diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/ComparatorRegistered.php b/vendor/phpunit/phpunit/src/Event/Events/Test/ComparatorRegistered.php index e3ec59e4..9e83d3d2 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/ComparatorRegistered.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/ComparatorRegistered.php @@ -53,7 +53,7 @@ final class ComparatorRegistered implements Event { return sprintf( 'Comparator Registered (%s)', - $this->className + $this->className, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/AfterLastTestMethodCalled.php b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/AfterLastTestMethodCalled.php index 9883a23a..fec2a79e 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/AfterLastTestMethodCalled.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/AfterLastTestMethodCalled.php @@ -62,7 +62,7 @@ final class AfterLastTestMethodCalled implements Event return sprintf( 'After Last Test Method Called (%s::%s)', $this->calledMethod->className(), - $this->calledMethod->methodName() + $this->calledMethod->methodName(), ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/AfterLastTestMethodFinished.php b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/AfterLastTestMethodFinished.php index 5ebbe142..40a6c9fc 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/AfterLastTestMethodFinished.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/AfterLastTestMethodFinished.php @@ -73,7 +73,7 @@ final class AfterLastTestMethodFinished implements Event $buffer .= sprintf( PHP_EOL . '- %s::%s', $calledMethod->className(), - $calledMethod->methodName() + $calledMethod->methodName(), ); } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/AfterTestMethodCalled.php b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/AfterTestMethodCalled.php index c6412206..52afc14c 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/AfterTestMethodCalled.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/AfterTestMethodCalled.php @@ -62,7 +62,7 @@ final class AfterTestMethodCalled implements Event return sprintf( 'After Test Method Called (%s::%s)', $this->calledMethod->className(), - $this->calledMethod->methodName() + $this->calledMethod->methodName(), ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/AfterTestMethodFinished.php b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/AfterTestMethodFinished.php index bc326668..e934eea8 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/AfterTestMethodFinished.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/AfterTestMethodFinished.php @@ -73,7 +73,7 @@ final class AfterTestMethodFinished implements Event $buffer .= sprintf( PHP_EOL . '- %s::%s', $calledMethod->className(), - $calledMethod->methodName() + $calledMethod->methodName(), ); } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/BeforeFirstTestMethodCalled.php b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/BeforeFirstTestMethodCalled.php index c1fc9043..da28f2bf 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/BeforeFirstTestMethodCalled.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/BeforeFirstTestMethodCalled.php @@ -62,7 +62,7 @@ final class BeforeFirstTestMethodCalled implements Event return sprintf( 'Before First Test Method Called (%s::%s)', $this->calledMethod->className(), - $this->calledMethod->methodName() + $this->calledMethod->methodName(), ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/BeforeFirstTestMethodErrored.php b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/BeforeFirstTestMethodErrored.php index 9f6f0686..81833227 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/BeforeFirstTestMethodErrored.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/BeforeFirstTestMethodErrored.php @@ -77,7 +77,7 @@ final class BeforeFirstTestMethodErrored implements Event 'Before First Test Method Errored (%s::%s)%s', $this->calledMethod->className(), $this->calledMethod->methodName(), - $message + $message, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/BeforeFirstTestMethodFinished.php b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/BeforeFirstTestMethodFinished.php index 0f3ff2b7..fba563d7 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/BeforeFirstTestMethodFinished.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/BeforeFirstTestMethodFinished.php @@ -73,7 +73,7 @@ final class BeforeFirstTestMethodFinished implements Event $buffer .= sprintf( PHP_EOL . '- %s::%s', $calledMethod->className(), - $calledMethod->methodName() + $calledMethod->methodName(), ); } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/BeforeTestMethodCalled.php b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/BeforeTestMethodCalled.php index dca36109..3b300fa3 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/BeforeTestMethodCalled.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/BeforeTestMethodCalled.php @@ -62,7 +62,7 @@ final class BeforeTestMethodCalled implements Event return sprintf( 'Before Test Method Called (%s::%s)', $this->calledMethod->className(), - $this->calledMethod->methodName() + $this->calledMethod->methodName(), ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/BeforeTestMethodFinished.php b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/BeforeTestMethodFinished.php index ded4b0b0..f84b51bb 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/BeforeTestMethodFinished.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/BeforeTestMethodFinished.php @@ -73,7 +73,7 @@ final class BeforeTestMethodFinished implements Event $buffer .= sprintf( PHP_EOL . '- %s::%s', $calledMethod->className(), - $calledMethod->methodName() + $calledMethod->methodName(), ); } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/PostConditionCalled.php b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/PostConditionCalled.php index 2cc2c9a8..e7b6c435 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/PostConditionCalled.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/PostConditionCalled.php @@ -62,7 +62,7 @@ final class PostConditionCalled implements Event return sprintf( 'Post Condition Method Called (%s::%s)', $this->calledMethod->className(), - $this->calledMethod->methodName() + $this->calledMethod->methodName(), ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/PostConditionFinished.php b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/PostConditionFinished.php index 6e5d45e8..fff07ce7 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/PostConditionFinished.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/PostConditionFinished.php @@ -73,7 +73,7 @@ final class PostConditionFinished implements Event $buffer .= sprintf( PHP_EOL . '- %s::%s', $calledMethod->className(), - $calledMethod->methodName() + $calledMethod->methodName(), ); } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/PreConditionCalled.php b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/PreConditionCalled.php index f6bb4c87..93752546 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/PreConditionCalled.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/PreConditionCalled.php @@ -62,7 +62,7 @@ final class PreConditionCalled implements Event return sprintf( 'Pre Condition Method Called (%s::%s)', $this->calledMethod->className(), - $this->calledMethod->methodName() + $this->calledMethod->methodName(), ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/PreConditionFinished.php b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/PreConditionFinished.php index a70973af..05340796 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/PreConditionFinished.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/HookMethod/PreConditionFinished.php @@ -73,7 +73,7 @@ final class PreConditionFinished implements Event $buffer .= sprintf( PHP_EOL . '- %s::%s', $calledMethod->className(), - $calledMethod->methodName() + $calledMethod->methodName(), ); } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/ConsideredRisky.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/ConsideredRisky.php index 6cd79480..5b90d1bf 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/ConsideredRisky.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/ConsideredRisky.php @@ -24,8 +24,15 @@ final class ConsideredRisky implements Event { private readonly Telemetry\Info $telemetryInfo; private readonly Code\Test $test; + + /** + * @psalm-var non-empty-string + */ private readonly string $message; + /** + * @psalm-param non-empty-string $message + */ public function __construct(Telemetry\Info $telemetryInfo, Code\Test $test, string $message) { $this->telemetryInfo = $telemetryInfo; @@ -43,6 +50,9 @@ final class ConsideredRisky implements Event return $this->test; } + /** + * @psalm-return non-empty-string + */ public function message(): string { return $this->message; diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/DeprecationTriggered.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/DeprecationTriggered.php index 08c109dc..d4d495da 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/DeprecationTriggered.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/DeprecationTriggered.php @@ -24,17 +24,40 @@ final class DeprecationTriggered implements Event { private readonly Telemetry\Info $telemetryInfo; private readonly Test $test; - private readonly string $message; - private readonly string $file; - private readonly int $line; - public function __construct(Telemetry\Info $telemetryInfo, Test $test, string $message, string $file, int $line) + /** + * @psalm-var non-empty-string + */ + private readonly string $message; + + /** + * @psalm-var non-empty-string + */ + private readonly string $file; + + /** + * @psalm-var positive-int + */ + private readonly int $line; + private readonly bool $suppressed; + private readonly bool $ignoredByBaseline; + private readonly bool $ignoredByTest; + + /** + * @psalm-param non-empty-string $message + * @psalm-param non-empty-string $file + * @psalm-param positive-int $line + */ + public function __construct(Telemetry\Info $telemetryInfo, Test $test, string $message, string $file, int $line, bool $suppressed, bool $ignoredByBaseline, bool $ignoredByTest) { - $this->telemetryInfo = $telemetryInfo; - $this->test = $test; - $this->message = $message; - $this->file = $file; - $this->line = $line; + $this->telemetryInfo = $telemetryInfo; + $this->test = $test; + $this->message = $message; + $this->file = $file; + $this->line = $line; + $this->suppressed = $suppressed; + $this->ignoredByBaseline = $ignoredByBaseline; + $this->ignoredByTest = $ignoredByTest; } public function telemetryInfo(): Telemetry\Info @@ -47,21 +70,45 @@ final class DeprecationTriggered implements Event return $this->test; } + /** + * @psalm-return non-empty-string + */ public function message(): string { return $this->message; } + /** + * @psalm-return non-empty-string + */ public function file(): string { return $this->file; } + /** + * @psalm-return positive-int + */ public function line(): int { return $this->line; } + public function wasSuppressed(): bool + { + return $this->suppressed; + } + + public function ignoredByBaseline(): bool + { + return $this->ignoredByBaseline; + } + + public function ignoredByTest(): bool + { + return $this->ignoredByTest; + } + public function asString(): string { $message = $this->message; @@ -70,10 +117,21 @@ final class DeprecationTriggered implements Event $message = PHP_EOL . $message; } + $status = ''; + + if ($this->ignoredByTest) { + $status = 'Test-Ignored '; + } elseif ($this->ignoredByBaseline) { + $status = 'Baseline-Ignored '; + } elseif ($this->suppressed) { + $status = 'Suppressed '; + } + return sprintf( - 'Test Triggered Deprecation (%s)%s', + 'Test Triggered %sDeprecation (%s)%s', + $status, $this->test->id(), - $message + $message, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/ErrorTriggered.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/ErrorTriggered.php index 8668a98d..0407c0b7 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/ErrorTriggered.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/ErrorTriggered.php @@ -24,17 +24,36 @@ final class ErrorTriggered implements Event { private readonly Telemetry\Info $telemetryInfo; private readonly Test $test; - private readonly string $message; - private readonly string $file; - private readonly int $line; - public function __construct(Telemetry\Info $telemetryInfo, Test $test, string $message, string $file, int $line) + /** + * @psalm-var non-empty-string + */ + private readonly string $message; + + /** + * @psalm-var non-empty-string + */ + private readonly string $file; + + /** + * @psalm-var positive-int + */ + private readonly int $line; + private readonly bool $suppressed; + + /** + * @psalm-param non-empty-string $message + * @psalm-param non-empty-string $file + * @psalm-param positive-int $line + */ + public function __construct(Telemetry\Info $telemetryInfo, Test $test, string $message, string $file, int $line, bool $suppressed) { $this->telemetryInfo = $telemetryInfo; $this->test = $test; $this->message = $message; $this->file = $file; $this->line = $line; + $this->suppressed = $suppressed; } public function telemetryInfo(): Telemetry\Info @@ -47,21 +66,35 @@ final class ErrorTriggered implements Event return $this->test; } + /** + * @psalm-return non-empty-string + */ public function message(): string { return $this->message; } + /** + * @psalm-return non-empty-string + */ public function file(): string { return $this->file; } + /** + * @psalm-return positive-int + */ public function line(): int { return $this->line; } + public function wasSuppressed(): bool + { + return $this->suppressed; + } + public function asString(): string { $message = $this->message; @@ -71,9 +104,10 @@ final class ErrorTriggered implements Event } return sprintf( - 'Test Triggered Error (%s)%s', + 'Test Triggered %sError (%s)%s', + $this->wasSuppressed() ? 'Suppressed ' : '', $this->test->id(), - $message + $message, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/NoticeTriggered.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/NoticeTriggered.php index 8baaff95..d8a27bbd 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/NoticeTriggered.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/NoticeTriggered.php @@ -24,17 +24,38 @@ final class NoticeTriggered implements Event { private readonly Telemetry\Info $telemetryInfo; private readonly Test $test; - private readonly string $message; - private readonly string $file; - private readonly int $line; - public function __construct(Telemetry\Info $telemetryInfo, Test $test, string $message, string $file, int $line) + /** + * @psalm-var non-empty-string + */ + private readonly string $message; + + /** + * @psalm-var non-empty-string + */ + private readonly string $file; + + /** + * @psalm-var positive-int + */ + private readonly int $line; + private readonly bool $suppressed; + private readonly bool $ignoredByBaseline; + + /** + * @psalm-param non-empty-string $message + * @psalm-param non-empty-string $file + * @psalm-param positive-int $line + */ + public function __construct(Telemetry\Info $telemetryInfo, Test $test, string $message, string $file, int $line, bool $suppressed, bool $ignoredByBaseline) { - $this->telemetryInfo = $telemetryInfo; - $this->test = $test; - $this->message = $message; - $this->file = $file; - $this->line = $line; + $this->telemetryInfo = $telemetryInfo; + $this->test = $test; + $this->message = $message; + $this->file = $file; + $this->line = $line; + $this->suppressed = $suppressed; + $this->ignoredByBaseline = $ignoredByBaseline; } public function telemetryInfo(): Telemetry\Info @@ -47,21 +68,40 @@ final class NoticeTriggered implements Event return $this->test; } + /** + * @psalm-return non-empty-string + */ public function message(): string { return $this->message; } + /** + * @psalm-return non-empty-string + */ public function file(): string { return $this->file; } + /** + * @psalm-return positive-int + */ public function line(): int { return $this->line; } + public function wasSuppressed(): bool + { + return $this->suppressed; + } + + public function ignoredByBaseline(): bool + { + return $this->ignoredByBaseline; + } + public function asString(): string { $message = $this->message; @@ -70,10 +110,19 @@ final class NoticeTriggered implements Event $message = PHP_EOL . $message; } + $status = ''; + + if ($this->ignoredByBaseline) { + $status = 'Baseline-Ignored '; + } elseif ($this->suppressed) { + $status = 'Suppressed '; + } + return sprintf( - 'Test Triggered Notice (%s)%s', + 'Test Triggered %sNotice (%s)%s', + $status, $this->test->id(), - $message + $message, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpDeprecationTriggered.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpDeprecationTriggered.php index 1d80f89e..9c93fd42 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpDeprecationTriggered.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpDeprecationTriggered.php @@ -24,17 +24,40 @@ final class PhpDeprecationTriggered implements Event { private readonly Telemetry\Info $telemetryInfo; private readonly Test $test; - private readonly string $message; - private readonly string $file; - private readonly int $line; - public function __construct(Telemetry\Info $telemetryInfo, Test $test, string $message, string $file, int $line) + /** + * @psalm-var non-empty-string + */ + private readonly string $message; + + /** + * @psalm-var non-empty-string + */ + private readonly string $file; + + /** + * @psalm-var positive-int + */ + private readonly int $line; + private readonly bool $suppressed; + private readonly bool $ignoredByBaseline; + private readonly bool $ignoredByTest; + + /** + * @psalm-param non-empty-string $message + * @psalm-param non-empty-string $file + * @psalm-param positive-int $line + */ + public function __construct(Telemetry\Info $telemetryInfo, Test $test, string $message, string $file, int $line, bool $suppressed, bool $ignoredByBaseline, bool $ignoredByTest) { - $this->telemetryInfo = $telemetryInfo; - $this->test = $test; - $this->message = $message; - $this->file = $file; - $this->line = $line; + $this->telemetryInfo = $telemetryInfo; + $this->test = $test; + $this->message = $message; + $this->file = $file; + $this->line = $line; + $this->suppressed = $suppressed; + $this->ignoredByBaseline = $ignoredByBaseline; + $this->ignoredByTest = $ignoredByTest; } public function telemetryInfo(): Telemetry\Info @@ -47,21 +70,45 @@ final class PhpDeprecationTriggered implements Event return $this->test; } + /** + * @psalm-return non-empty-string + */ public function message(): string { return $this->message; } + /** + * @psalm-return non-empty-string + */ public function file(): string { return $this->file; } + /** + * @psalm-return positive-int + */ public function line(): int { return $this->line; } + public function wasSuppressed(): bool + { + return $this->suppressed; + } + + public function ignoredByBaseline(): bool + { + return $this->ignoredByBaseline; + } + + public function ignoredByTest(): bool + { + return $this->ignoredByTest; + } + public function asString(): string { $message = $this->message; @@ -70,10 +117,21 @@ final class PhpDeprecationTriggered implements Event $message = PHP_EOL . $message; } + $status = ''; + + if ($this->ignoredByTest) { + $status = 'Test-Ignored '; + } elseif ($this->ignoredByBaseline) { + $status = 'Baseline-Ignored '; + } elseif ($this->suppressed) { + $status = 'Suppressed '; + } + return sprintf( - 'Test Triggered PHP Deprecation (%s)%s', + 'Test Triggered %sPHP Deprecation (%s)%s', + $status, $this->test->id(), - $message + $message, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpNoticeTriggered.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpNoticeTriggered.php index 7acbcc34..f03d0ba9 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpNoticeTriggered.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpNoticeTriggered.php @@ -24,17 +24,38 @@ final class PhpNoticeTriggered implements Event { private readonly Telemetry\Info $telemetryInfo; private readonly Test $test; - private readonly string $message; - private readonly string $file; - private readonly int $line; - public function __construct(Telemetry\Info $telemetryInfo, Test $test, string $message, string $file, int $line) + /** + * @psalm-var non-empty-string + */ + private readonly string $message; + + /** + * @psalm-var non-empty-string + */ + private readonly string $file; + + /** + * @psalm-var positive-int + */ + private readonly int $line; + private readonly bool $suppressed; + private readonly bool $ignoredByBaseline; + + /** + * @psalm-param non-empty-string $message + * @psalm-param non-empty-string $file + * @psalm-param positive-int $line + */ + public function __construct(Telemetry\Info $telemetryInfo, Test $test, string $message, string $file, int $line, bool $suppressed, bool $ignoredByBaseline) { - $this->telemetryInfo = $telemetryInfo; - $this->test = $test; - $this->message = $message; - $this->file = $file; - $this->line = $line; + $this->telemetryInfo = $telemetryInfo; + $this->test = $test; + $this->message = $message; + $this->file = $file; + $this->line = $line; + $this->suppressed = $suppressed; + $this->ignoredByBaseline = $ignoredByBaseline; } public function telemetryInfo(): Telemetry\Info @@ -47,21 +68,40 @@ final class PhpNoticeTriggered implements Event return $this->test; } + /** + * @psalm-return non-empty-string + */ public function message(): string { return $this->message; } + /** + * @psalm-return non-empty-string + */ public function file(): string { return $this->file; } + /** + * @psalm-return positive-int + */ public function line(): int { return $this->line; } + public function wasSuppressed(): bool + { + return $this->suppressed; + } + + public function ignoredByBaseline(): bool + { + return $this->ignoredByBaseline; + } + public function asString(): string { $message = $this->message; @@ -70,10 +110,19 @@ final class PhpNoticeTriggered implements Event $message = PHP_EOL . $message; } + $status = ''; + + if ($this->ignoredByBaseline) { + $status = 'Baseline-Ignored '; + } elseif ($this->suppressed) { + $status = 'Suppressed '; + } + return sprintf( - 'Test Triggered PHP Notice (%s)%s', + 'Test Triggered %sPHP Notice (%s)%s', + $status, $this->test->id(), - $message + $message, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpWarningTriggered.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpWarningTriggered.php index f3423375..a93dc73e 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpWarningTriggered.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpWarningTriggered.php @@ -24,17 +24,38 @@ final class PhpWarningTriggered implements Event { private readonly Telemetry\Info $telemetryInfo; private readonly Test $test; - private readonly string $message; - private readonly string $file; - private readonly int $line; - public function __construct(Telemetry\Info $telemetryInfo, Test $test, string $message, string $file, int $line) + /** + * @psalm-var non-empty-string + */ + private readonly string $message; + + /** + * @psalm-var non-empty-string + */ + private readonly string $file; + + /** + * @psalm-var positive-int + */ + private readonly int $line; + private readonly bool $suppressed; + private readonly bool $ignoredByBaseline; + + /** + * @psalm-param non-empty-string $message + * @psalm-param non-empty-string $file + * @psalm-param positive-int $line + */ + public function __construct(Telemetry\Info $telemetryInfo, Test $test, string $message, string $file, int $line, bool $suppressed, bool $ignoredByBaseline) { - $this->telemetryInfo = $telemetryInfo; - $this->test = $test; - $this->message = $message; - $this->file = $file; - $this->line = $line; + $this->telemetryInfo = $telemetryInfo; + $this->test = $test; + $this->message = $message; + $this->file = $file; + $this->line = $line; + $this->suppressed = $suppressed; + $this->ignoredByBaseline = $ignoredByBaseline; } public function telemetryInfo(): Telemetry\Info @@ -47,21 +68,40 @@ final class PhpWarningTriggered implements Event return $this->test; } + /** + * @psalm-return non-empty-string + */ public function message(): string { return $this->message; } + /** + * @psalm-return non-empty-string + */ public function file(): string { return $this->file; } + /** + * @psalm-return positive-int + */ public function line(): int { return $this->line; } + public function wasSuppressed(): bool + { + return $this->suppressed; + } + + public function ignoredByBaseline(): bool + { + return $this->ignoredByBaseline; + } + public function asString(): string { $message = $this->message; @@ -70,10 +110,19 @@ final class PhpWarningTriggered implements Event $message = PHP_EOL . $message; } + $status = ''; + + if ($this->ignoredByBaseline) { + $status = 'Baseline-Ignored '; + } elseif ($this->suppressed) { + $status = 'Suppressed '; + } + return sprintf( - 'Test Triggered PHP Warning (%s)%s', + 'Test Triggered %sPHP Warning (%s)%s', + $status, $this->test->id(), - $message + $message, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpunitDeprecationTriggered.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpunitDeprecationTriggered.php index a70e1e6b..fadc46d2 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpunitDeprecationTriggered.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpunitDeprecationTriggered.php @@ -59,7 +59,7 @@ final class PhpunitDeprecationTriggered implements Event return sprintf( 'Test Triggered PHPUnit Deprecation (%s)%s', $this->test->id(), - $message + $message, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpunitErrorTriggered.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpunitErrorTriggered.php index a86207f4..e5b75b4d 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpunitErrorTriggered.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpunitErrorTriggered.php @@ -11,6 +11,7 @@ namespace PHPUnit\Event\Test; use const PHP_EOL; use function sprintf; +use function trim; use PHPUnit\Event\Code\Test; use PHPUnit\Event\Event; use PHPUnit\Event\Telemetry; @@ -50,7 +51,7 @@ final class PhpunitErrorTriggered implements Event public function asString(): string { - $message = $this->message; + $message = trim($this->message); if (!empty($message)) { $message = PHP_EOL . $message; @@ -59,7 +60,7 @@ final class PhpunitErrorTriggered implements Event return sprintf( 'Test Triggered PHPUnit Error (%s)%s', $this->test->id(), - $message + $message, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpunitWarningTriggered.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpunitWarningTriggered.php index 2c6c083c..6a816ee4 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpunitWarningTriggered.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/PhpunitWarningTriggered.php @@ -59,7 +59,7 @@ final class PhpunitWarningTriggered implements Event return sprintf( 'Test Triggered PHPUnit Warning (%s)%s', $this->test->id(), - $message + $message, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/WarningTriggered.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/WarningTriggered.php index f36877df..9bccafa1 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/WarningTriggered.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Issue/WarningTriggered.php @@ -24,17 +24,38 @@ final class WarningTriggered implements Event { private readonly Telemetry\Info $telemetryInfo; private readonly Test $test; - private readonly string $message; - private readonly string $file; - private readonly int $line; - public function __construct(Telemetry\Info $telemetryInfo, Test $test, string $message, string $file, int $line) + /** + * @psalm-var non-empty-string + */ + private readonly string $message; + + /** + * @psalm-var non-empty-string + */ + private readonly string $file; + + /** + * @psalm-var positive-int + */ + private readonly int $line; + private readonly bool $suppressed; + private readonly bool $ignoredByBaseline; + + /** + * @psalm-param non-empty-string $message + * @psalm-param non-empty-string $file + * @psalm-param positive-int $line + */ + public function __construct(Telemetry\Info $telemetryInfo, Test $test, string $message, string $file, int $line, bool $suppressed, bool $ignoredByBaseline) { - $this->telemetryInfo = $telemetryInfo; - $this->test = $test; - $this->message = $message; - $this->file = $file; - $this->line = $line; + $this->telemetryInfo = $telemetryInfo; + $this->test = $test; + $this->message = $message; + $this->file = $file; + $this->line = $line; + $this->suppressed = $suppressed; + $this->ignoredByBaseline = $ignoredByBaseline; } public function telemetryInfo(): Telemetry\Info @@ -47,21 +68,40 @@ final class WarningTriggered implements Event return $this->test; } + /** + * @psalm-return non-empty-string + */ public function message(): string { return $this->message; } + /** + * @psalm-return non-empty-string + */ public function file(): string { return $this->file; } + /** + * @psalm-return positive-int + */ public function line(): int { return $this->line; } + public function wasSuppressed(): bool + { + return $this->suppressed; + } + + public function ignoredByBaseline(): bool + { + return $this->ignoredByBaseline; + } + public function asString(): string { $message = $this->message; @@ -70,10 +110,19 @@ final class WarningTriggered implements Event $message = PHP_EOL . $message; } + $status = ''; + + if ($this->ignoredByBaseline) { + $status = 'Baseline-Ignored '; + } elseif ($this->suppressed) { + $status = 'Suppressed '; + } + return sprintf( - 'Test Triggered Warning (%s)%s', + 'Test Triggered %sWarning (%s)%s', + $status, $this->test->id(), - $message + $message, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodCalled.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodCalled.php new file mode 100644 index 00000000..2b6becab --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodCalled.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 PHPUnit\Event\Test; + +use function sprintf; +use PHPUnit\Event\Code\ClassMethod; +use PHPUnit\Event\Event; +use PHPUnit\Event\Telemetry\Info; + +/** + * @psalm-immutable + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class DataProviderMethodCalled implements Event +{ + private readonly Info $telemetryInfo; + private readonly ClassMethod $testMethod; + private readonly ClassMethod $dataProviderMethod; + + public function __construct(Info $telemetryInfo, ClassMethod $testMethod, ClassMethod $dataProviderMethod) + { + $this->telemetryInfo = $telemetryInfo; + $this->testMethod = $testMethod; + $this->dataProviderMethod = $dataProviderMethod; + } + + public function telemetryInfo(): Info + { + return $this->telemetryInfo; + } + + public function testMethod(): ClassMethod + { + return $this->testMethod; + } + + public function dataProviderMethod(): ClassMethod + { + return $this->dataProviderMethod; + } + + public function asString(): string + { + return sprintf( + 'Data Provider Method Called (%s::%s for test method %s::%s)', + $this->dataProviderMethod->className(), + $this->dataProviderMethod->methodName(), + $this->testMethod->className(), + $this->testMethod->methodName(), + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodCalledSubscriber.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodCalledSubscriber.php new file mode 100644 index 00000000..5f7d4013 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodCalledSubscriber.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\Event\Test; + +use PHPUnit\Event\Subscriber; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +interface DataProviderMethodCalledSubscriber extends Subscriber +{ + public function notify(DataProviderMethodCalled $event): void; +} diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodFinished.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodFinished.php new file mode 100644 index 00000000..0036e408 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodFinished.php @@ -0,0 +1,77 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Event\Test; + +use const PHP_EOL; +use function sprintf; +use PHPUnit\Event\Code; +use PHPUnit\Event\Code\ClassMethod; +use PHPUnit\Event\Event; +use PHPUnit\Event\Telemetry; + +/** + * @psalm-immutable + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class DataProviderMethodFinished implements Event +{ + private readonly Telemetry\Info $telemetryInfo; + private readonly ClassMethod $testMethod; + + /** + * @psalm-var list + */ + private readonly array $calledMethods; + + public function __construct(Telemetry\Info $telemetryInfo, ClassMethod $testMethod, ClassMethod ...$calledMethods) + { + $this->telemetryInfo = $telemetryInfo; + $this->testMethod = $testMethod; + $this->calledMethods = $calledMethods; + } + + public function telemetryInfo(): Telemetry\Info + { + return $this->telemetryInfo; + } + + public function testMethod(): ClassMethod + { + return $this->testMethod; + } + + /** + * @psalm-return list + */ + public function calledMethods(): array + { + return $this->calledMethods; + } + + public function asString(): string + { + $buffer = sprintf( + 'Data Provider Method Finished for %s::%s:', + $this->testMethod->className(), + $this->testMethod->methodName(), + ); + + foreach ($this->calledMethods as $calledMethod) { + $buffer .= sprintf( + PHP_EOL . '- %s::%s', + $calledMethod->className(), + $calledMethod->methodName(), + ); + } + + return $buffer; + } +} diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodFinishedSubscriber.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodFinishedSubscriber.php new file mode 100644 index 00000000..624f8921 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/DataProviderMethodFinishedSubscriber.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\Event\Test; + +use PHPUnit\Event\Subscriber; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +interface DataProviderMethodFinishedSubscriber extends Subscriber +{ + public function notify(DataProviderMethodFinished $event): void; +} diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/PreparationFailed.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/PreparationFailed.php new file mode 100644 index 00000000..4989d9ee --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/PreparationFailed.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\Event\Test; + +use function sprintf; +use PHPUnit\Event\Code; +use PHPUnit\Event\Event; +use PHPUnit\Event\Telemetry; + +/** + * @psalm-immutable + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class PreparationFailed implements Event +{ + private readonly Telemetry\Info $telemetryInfo; + private readonly Code\Test $test; + + public function __construct(Telemetry\Info $telemetryInfo, Code\Test $test) + { + $this->telemetryInfo = $telemetryInfo; + $this->test = $test; + } + + public function telemetryInfo(): Telemetry\Info + { + return $this->telemetryInfo; + } + + public function test(): Code\Test + { + return $this->test; + } + + public function asString(): string + { + return sprintf( + 'Test Preparation Failed (%s)', + $this->test->id(), + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/PreparationFailedSubscriber.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/PreparationFailedSubscriber.php new file mode 100644 index 00000000..da20f11e --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Lifecycle/PreparationFailedSubscriber.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\Event\Test; + +use PHPUnit\Event\Subscriber; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +interface PreparationFailedSubscriber extends Subscriber +{ + public function notify(PreparationFailed $event): void; +} diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Outcome/Errored.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Outcome/Errored.php index ca18ccf1..0c3f4aa2 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/Outcome/Errored.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Outcome/Errored.php @@ -11,6 +11,7 @@ namespace PHPUnit\Event\Test; use const PHP_EOL; use function sprintf; +use function trim; use PHPUnit\Event\Code; use PHPUnit\Event\Code\Throwable; use PHPUnit\Event\Event; @@ -51,7 +52,7 @@ final class Errored implements Event public function asString(): string { - $message = $this->throwable->message(); + $message = trim($this->throwable->message()); if (!empty($message)) { $message = PHP_EOL . $message; @@ -60,7 +61,7 @@ final class Errored implements Event return sprintf( 'Test Errored (%s)%s', $this->test->id(), - $message + $message, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Outcome/Failed.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Outcome/Failed.php index 2709d015..0bce79ef 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/Outcome/Failed.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Outcome/Failed.php @@ -11,6 +11,7 @@ namespace PHPUnit\Event\Test; use const PHP_EOL; use function sprintf; +use function trim; use PHPUnit\Event\Code; use PHPUnit\Event\Code\ComparisonFailure; use PHPUnit\Event\Code\Throwable; @@ -74,7 +75,7 @@ final class Failed implements Event public function asString(): string { - $message = $this->throwable->message(); + $message = trim($this->throwable->message()); if (!empty($message)) { $message = PHP_EOL . $message; @@ -83,7 +84,7 @@ final class Failed implements Event return sprintf( 'Test Failed (%s)%s', $this->test->id(), - $message + $message, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Outcome/MarkedIncomplete.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Outcome/MarkedIncomplete.php index ffd0fa2f..c501fa46 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/Outcome/MarkedIncomplete.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Outcome/MarkedIncomplete.php @@ -11,6 +11,7 @@ namespace PHPUnit\Event\Test; use const PHP_EOL; use function sprintf; +use function trim; use PHPUnit\Event\Code; use PHPUnit\Event\Code\Throwable; use PHPUnit\Event\Event; @@ -51,7 +52,7 @@ final class MarkedIncomplete implements Event public function asString(): string { - $message = $this->throwable->message(); + $message = trim($this->throwable->message()); if (!empty($message)) { $message = PHP_EOL . $message; @@ -60,7 +61,7 @@ final class MarkedIncomplete implements Event return sprintf( 'Test Marked Incomplete (%s)%s', $this->test->id(), - $message + $message, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/Outcome/Skipped.php b/vendor/phpunit/phpunit/src/Event/Events/Test/Outcome/Skipped.php index fd8da8da..14501058 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/Outcome/Skipped.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/Outcome/Skipped.php @@ -59,7 +59,7 @@ final class Skipped implements Event return sprintf( 'Test Skipped (%s)%s', $this->test->id(), - $message + $message, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/PrintedUnexpectedOutput.php b/vendor/phpunit/phpunit/src/Event/Events/Test/PrintedUnexpectedOutput.php new file mode 100644 index 00000000..733520e6 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/PrintedUnexpectedOutput.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 PHPUnit\Event\Test; + +use function sprintf; +use PHPUnit\Event\Event; +use PHPUnit\Event\Telemetry; + +/** + * @psalm-immutable + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class PrintedUnexpectedOutput implements Event +{ + private readonly Telemetry\Info $telemetryInfo; + + /** + * @psalm-var non-empty-string + */ + private readonly string $output; + + /** + * @psalm-param non-empty-string $output + */ + public function __construct(Telemetry\Info $telemetryInfo, string $output) + { + $this->telemetryInfo = $telemetryInfo; + $this->output = $output; + } + + public function telemetryInfo(): Telemetry\Info + { + return $this->telemetryInfo; + } + + /** + * @psalm-return non-empty-string + */ + public function output(): string + { + return $this->output; + } + + public function asString(): string + { + return sprintf( + 'Test Printed Unexpected Output%s%s', + PHP_EOL, + $this->output, + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/PrintedUnexpectedOutputSubscriber.php b/vendor/phpunit/phpunit/src/Event/Events/Test/PrintedUnexpectedOutputSubscriber.php new file mode 100644 index 00000000..ee201572 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/PrintedUnexpectedOutputSubscriber.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\Event\Test; + +use PHPUnit\Event\Subscriber; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +interface PrintedUnexpectedOutputSubscriber extends Subscriber +{ + public function notify(PrintedUnexpectedOutput $event): void; +} diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/MockObjectCreated.php b/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/MockObjectCreated.php index b67a5b74..ad462440 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/MockObjectCreated.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/MockObjectCreated.php @@ -53,7 +53,7 @@ final class MockObjectCreated implements Event { return sprintf( 'Mock Object Created (%s)', - $this->className + $this->className, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/MockObjectForAbstractClassCreated.php b/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/MockObjectForAbstractClassCreated.php index 3b960d3a..7976a1c9 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/MockObjectForAbstractClassCreated.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/MockObjectForAbstractClassCreated.php @@ -53,7 +53,7 @@ final class MockObjectForAbstractClassCreated implements Event { return sprintf( 'Mock Object Created (%s)', - $this->className + $this->className, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/MockObjectForIntersectionOfInterfacesCreated.php b/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/MockObjectForIntersectionOfInterfacesCreated.php index 08ae1ca4..deb7ec75 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/MockObjectForIntersectionOfInterfacesCreated.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/MockObjectForIntersectionOfInterfacesCreated.php @@ -54,7 +54,7 @@ final class MockObjectForIntersectionOfInterfacesCreated implements Event { return sprintf( 'Mock Object Created (%s)', - implode('&', $this->interfaces) + implode('&', $this->interfaces), ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/MockObjectForTraitCreated.php b/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/MockObjectForTraitCreated.php index 35818168..fd09d594 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/MockObjectForTraitCreated.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/MockObjectForTraitCreated.php @@ -53,7 +53,7 @@ final class MockObjectForTraitCreated implements Event { return sprintf( 'Mock Object Created (%s)', - $this->traitName + $this->traitName, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/MockObjectFromWsdlCreated.php b/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/MockObjectFromWsdlCreated.php index 640a68dc..09992831 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/MockObjectFromWsdlCreated.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/MockObjectFromWsdlCreated.php @@ -103,7 +103,7 @@ final class MockObjectFromWsdlCreated implements Event { return sprintf( 'Mock Object Created (%s)', - $this->wsdlFile + $this->wsdlFile, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/PartialMockObjectCreated.php b/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/PartialMockObjectCreated.php index 397fdeb2..604ba3ce 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/PartialMockObjectCreated.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/PartialMockObjectCreated.php @@ -67,7 +67,7 @@ final class PartialMockObjectCreated implements Event { return sprintf( 'Partial Mock Object Created (%s)', - $this->className + $this->className, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/TestProxyCreated.php b/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/TestProxyCreated.php index deabf820..3f089412 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/TestProxyCreated.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/TestProxyCreated.php @@ -60,7 +60,7 @@ final class TestProxyCreated implements Event { return sprintf( 'Test Proxy Created (%s)', - $this->className + $this->className, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/TestStubCreated.php b/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/TestStubCreated.php index 0dae6d88..9d0330f6 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/TestStubCreated.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/TestStubCreated.php @@ -53,7 +53,7 @@ final class TestStubCreated implements Event { return sprintf( 'Test Stub Created (%s)', - $this->className + $this->className, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/TestStubForIntersectionOfInterfacesCreated.php b/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/TestStubForIntersectionOfInterfacesCreated.php index 0e36534b..4aded8c8 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/TestStubForIntersectionOfInterfacesCreated.php +++ b/vendor/phpunit/phpunit/src/Event/Events/Test/TestDouble/TestStubForIntersectionOfInterfacesCreated.php @@ -54,7 +54,7 @@ final class TestStubForIntersectionOfInterfacesCreated implements Event { return sprintf( 'Test Stub Created (%s)', - implode('&', $this->interfaces) + implode('&', $this->interfaces), ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/TestRunner/BootstrapFinished.php b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/BootstrapFinished.php index 406506a3..9ec3f348 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/TestRunner/BootstrapFinished.php +++ b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/BootstrapFinished.php @@ -43,7 +43,7 @@ final class BootstrapFinished implements Event { return sprintf( 'Bootstrap Finished (%s)', - $this->filename + $this->filename, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/TestRunner/DeprecationTriggered.php b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/DeprecationTriggered.php index c5f15ab3..31d27e28 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/TestRunner/DeprecationTriggered.php +++ b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/DeprecationTriggered.php @@ -43,7 +43,7 @@ final class DeprecationTriggered implements Event { return sprintf( 'Test Runner Triggered Deprecation (%s)', - $this->message + $this->message, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionAborted.php b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionAborted.php new file mode 100644 index 00000000..2e2b92ce --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionAborted.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\Event\TestRunner; + +use PHPUnit\Event\Event; +use PHPUnit\Event\Telemetry; + +/** + * @psalm-immutable + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class ExecutionAborted implements Event +{ + private readonly Telemetry\Info $telemetryInfo; + + public function __construct(Telemetry\Info $telemetryInfo) + { + $this->telemetryInfo = $telemetryInfo; + } + + public function telemetryInfo(): Telemetry\Info + { + return $this->telemetryInfo; + } + + public function asString(): string + { + return 'Test Runner Execution Aborted'; + } +} diff --git a/vendor/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionAbortedSubscriber.php b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionAbortedSubscriber.php new file mode 100644 index 00000000..00397cca --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionAbortedSubscriber.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\Event\TestRunner; + +use PHPUnit\Event\Subscriber; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +interface ExecutionAbortedSubscriber extends Subscriber +{ + public function notify(ExecutionAborted $event): void; +} diff --git a/vendor/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionStarted.php b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionStarted.php index 3085bc40..77fd570d 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionStarted.php +++ b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/ExecutionStarted.php @@ -45,7 +45,7 @@ final class ExecutionStarted implements Event return sprintf( 'Test Runner Execution Started (%d test%s)', $this->testSuite->count(), - $this->testSuite->count() !== 1 ? 's' : '' + $this->testSuite->count() !== 1 ? 's' : '', ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/TestRunner/ExtensionLoadedFromPhar.php b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/ExtensionLoadedFromPhar.php index c9c321ce..a2f1f147 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/TestRunner/ExtensionLoadedFromPhar.php +++ b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/ExtensionLoadedFromPhar.php @@ -58,7 +58,7 @@ final class ExtensionLoadedFromPhar implements Event return sprintf( 'Extension Loaded from PHAR (%s %s)', $this->name, - $this->version + $this->version, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionDisabled.php b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionDisabled.php new file mode 100644 index 00000000..b7ac6a05 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionDisabled.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\Event\TestRunner; + +use PHPUnit\Event\Event; +use PHPUnit\Event\Telemetry; + +/** + * @psalm-immutable + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class GarbageCollectionDisabled implements Event +{ + private readonly Telemetry\Info $telemetryInfo; + + public function __construct(Telemetry\Info $telemetryInfo) + { + $this->telemetryInfo = $telemetryInfo; + } + + public function telemetryInfo(): Telemetry\Info + { + return $this->telemetryInfo; + } + + public function asString(): string + { + return 'Test Runner Disabled Garbage Collection'; + } +} diff --git a/vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionDisabledSubscriber.php b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionDisabledSubscriber.php new file mode 100644 index 00000000..bb7e224f --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionDisabledSubscriber.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\Event\TestRunner; + +use PHPUnit\Event\Subscriber; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +interface GarbageCollectionDisabledSubscriber extends Subscriber +{ + public function notify(GarbageCollectionDisabled $event): void; +} diff --git a/vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionEnabled.php b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionEnabled.php new file mode 100644 index 00000000..9f3e8b8b --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionEnabled.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\Event\TestRunner; + +use PHPUnit\Event\Event; +use PHPUnit\Event\Telemetry; + +/** + * @psalm-immutable + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class GarbageCollectionEnabled implements Event +{ + private readonly Telemetry\Info $telemetryInfo; + + public function __construct(Telemetry\Info $telemetryInfo) + { + $this->telemetryInfo = $telemetryInfo; + } + + public function telemetryInfo(): Telemetry\Info + { + return $this->telemetryInfo; + } + + public function asString(): string + { + return 'Test Runner Enabled Garbage Collection'; + } +} diff --git a/vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionEnabledSubscriber.php b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionEnabledSubscriber.php new file mode 100644 index 00000000..437eddc2 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionEnabledSubscriber.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\Event\TestRunner; + +use PHPUnit\Event\Subscriber; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +interface GarbageCollectionEnabledSubscriber extends Subscriber +{ + public function notify(GarbageCollectionEnabled $event): void; +} diff --git a/vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionTriggered.php b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionTriggered.php new file mode 100644 index 00000000..5ab2f828 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionTriggered.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\Event\TestRunner; + +use PHPUnit\Event\Event; +use PHPUnit\Event\Telemetry; + +/** + * @psalm-immutable + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class GarbageCollectionTriggered implements Event +{ + private readonly Telemetry\Info $telemetryInfo; + + public function __construct(Telemetry\Info $telemetryInfo) + { + $this->telemetryInfo = $telemetryInfo; + } + + public function telemetryInfo(): Telemetry\Info + { + return $this->telemetryInfo; + } + + public function asString(): string + { + return 'Test Runner Triggered Garbage Collection'; + } +} diff --git a/vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionTriggeredSubscriber.php b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionTriggeredSubscriber.php new file mode 100644 index 00000000..8b941c53 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/GarbageCollectionTriggeredSubscriber.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\Event\TestRunner; + +use PHPUnit\Event\Subscriber; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +interface GarbageCollectionTriggeredSubscriber extends Subscriber +{ + public function notify(GarbageCollectionTriggered $event): void; +} diff --git a/vendor/phpunit/phpunit/src/Event/Events/TestRunner/WarningTriggered.php b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/WarningTriggered.php index b690f2f6..cb80a07b 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/TestRunner/WarningTriggered.php +++ b/vendor/phpunit/phpunit/src/Event/Events/TestRunner/WarningTriggered.php @@ -43,7 +43,7 @@ final class WarningTriggered implements Event { return sprintf( 'Test Runner Triggered Warning (%s)', - $this->message + $this->message, ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/TestSuite/Filtered.php b/vendor/phpunit/phpunit/src/Event/Events/TestSuite/Filtered.php index 85a3bce7..1beadde5 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/TestSuite/Filtered.php +++ b/vendor/phpunit/phpunit/src/Event/Events/TestSuite/Filtered.php @@ -44,7 +44,7 @@ final class Filtered implements Event return sprintf( 'Test Suite Filtered (%d test%s)', $this->testSuite->count(), - $this->testSuite->count() !== 1 ? 's' : '' + $this->testSuite->count() !== 1 ? 's' : '', ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/TestSuite/Finished.php b/vendor/phpunit/phpunit/src/Event/Events/TestSuite/Finished.php index b3801eaf..e89076c1 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/TestSuite/Finished.php +++ b/vendor/phpunit/phpunit/src/Event/Events/TestSuite/Finished.php @@ -41,17 +41,11 @@ final class Finished implements Event public function asString(): string { - $name = ''; - - if (!empty($this->testSuite->name())) { - $name = $this->testSuite->name() . ', '; - } - return sprintf( - 'Test Suite Finished (%s%d test%s)', - $name, + 'Test Suite Finished (%s, %d test%s)', + $this->testSuite->name(), $this->testSuite->count(), - $this->testSuite->count() !== 1 ? 's' : '' + $this->testSuite->count() !== 1 ? 's' : '', ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/TestSuite/Loaded.php b/vendor/phpunit/phpunit/src/Event/Events/TestSuite/Loaded.php index 7cd5f091..271ab37f 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/TestSuite/Loaded.php +++ b/vendor/phpunit/phpunit/src/Event/Events/TestSuite/Loaded.php @@ -44,7 +44,7 @@ final class Loaded implements Event return sprintf( 'Test Suite Loaded (%d test%s)', $this->testSuite->count(), - $this->testSuite->count() !== 1 ? 's' : '' + $this->testSuite->count() !== 1 ? 's' : '', ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Events/TestSuite/Skipped.php b/vendor/phpunit/phpunit/src/Event/Events/TestSuite/Skipped.php new file mode 100644 index 00000000..9a8f5230 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Events/TestSuite/Skipped.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\Event\TestSuite; + +use function sprintf; +use PHPUnit\Event\Event; +use PHPUnit\Event\Telemetry; + +/** + * @psalm-immutable + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class Skipped implements Event +{ + private readonly Telemetry\Info $telemetryInfo; + private readonly TestSuite $testSuite; + private readonly string $message; + + public function __construct(Telemetry\Info $telemetryInfo, TestSuite $testSuite, string $message) + { + $this->telemetryInfo = $telemetryInfo; + $this->testSuite = $testSuite; + $this->message = $message; + } + + public function telemetryInfo(): Telemetry\Info + { + return $this->telemetryInfo; + } + + public function testSuite(): TestSuite + { + return $this->testSuite; + } + + public function message(): string + { + return $this->message; + } + + public function asString(): string + { + return sprintf( + 'Test Suite Skipped (%s, %s)', + $this->testSuite->name(), + $this->message, + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Event/Events/TestSuite/SkippedSubscriber.php b/vendor/phpunit/phpunit/src/Event/Events/TestSuite/SkippedSubscriber.php new file mode 100644 index 00000000..30f509fc --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Events/TestSuite/SkippedSubscriber.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\Event\TestSuite; + +use PHPUnit\Event\Subscriber; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +interface SkippedSubscriber extends Subscriber +{ + public function notify(Skipped $event): void; +} diff --git a/vendor/phpunit/phpunit/src/Event/Events/TestSuite/Started.php b/vendor/phpunit/phpunit/src/Event/Events/TestSuite/Started.php index acc83811..1e34aa7d 100644 --- a/vendor/phpunit/phpunit/src/Event/Events/TestSuite/Started.php +++ b/vendor/phpunit/phpunit/src/Event/Events/TestSuite/Started.php @@ -41,17 +41,11 @@ final class Started implements Event public function asString(): string { - $name = ''; - - if (!empty($this->testSuite->name())) { - $name = $this->testSuite->name() . ', '; - } - return sprintf( - 'Test Suite Started (%s%d test%s)', - $name, + 'Test Suite Started (%s, %d test%s)', + $this->testSuite->name(), $this->testSuite->count(), - $this->testSuite->count() !== 1 ? 's' : '' + $this->testSuite->count() !== 1 ? 's' : '', ); } } diff --git a/vendor/phpunit/phpunit/src/Util/Exception/NoTestCaseObjectOnCallStackException.php b/vendor/phpunit/phpunit/src/Event/Exception/NoTestCaseObjectOnCallStackException.php similarity index 90% rename from vendor/phpunit/phpunit/src/Util/Exception/NoTestCaseObjectOnCallStackException.php rename to vendor/phpunit/phpunit/src/Event/Exception/NoTestCaseObjectOnCallStackException.php index eae142fa..6e5b0342 100644 --- a/vendor/phpunit/phpunit/src/Util/Exception/NoTestCaseObjectOnCallStackException.php +++ b/vendor/phpunit/phpunit/src/Event/Exception/NoTestCaseObjectOnCallStackException.php @@ -7,8 +7,9 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ -namespace PHPUnit\Util; +namespace PHPUnit\Event\Code; +use PHPUnit\Event\Exception; use RuntimeException; /** diff --git a/vendor/phpunit/phpunit/src/Event/Facade.php b/vendor/phpunit/phpunit/src/Event/Facade.php index 80b73459..bda44484 100644 --- a/vendor/phpunit/phpunit/src/Event/Facade.php +++ b/vendor/phpunit/phpunit/src/Event/Facade.php @@ -9,150 +9,172 @@ */ namespace PHPUnit\Event; +use function gc_status; use PHPUnit\Event\Telemetry\HRTime; +use PHPUnit\Event\Telemetry\Php81GarbageCollectorStatusProvider; +use PHPUnit\Event\Telemetry\Php83GarbageCollectorStatusProvider; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ final class Facade { - private static ?TypeMap $typeMap = null; - private static ?Emitter $emitter = null; - private static ?Emitter $suspended = null; - private static ?DeferringDispatcher $deferringDispatcher = null; - private static bool $sealed = false; + private static ?self $instance = null; + private Emitter $emitter; + private ?TypeMap $typeMap = null; + private ?Emitter $suspended = null; + private ?DeferringDispatcher $deferringDispatcher = null; + private bool $sealed = false; - /** - * @throws EventFacadeIsSealedException - * @throws UnknownSubscriberTypeException - */ - public static function registerSubscribers(Subscriber ...$subscribers): void + public static function instance(): self { - foreach ($subscribers as $subscriber) { - self::registerSubscriber($subscriber); - } - } - - /** - * @throws EventFacadeIsSealedException - * @throws UnknownSubscriberTypeException - */ - public static function registerSubscriber(Subscriber $subscriber): void - { - if (self::$sealed) { - throw new EventFacadeIsSealedException; + if (self::$instance === null) { + self::$instance = new self; } - self::deferredDispatcher()->registerSubscriber($subscriber); - } - - /** - * @throws EventFacadeIsSealedException - */ - public static function registerTracer(Tracer\Tracer $tracer): void - { - if (self::$sealed) { - throw new EventFacadeIsSealedException; - } - - self::deferredDispatcher()->registerTracer($tracer); + return self::$instance; } public static function emitter(): Emitter { - if (self::$emitter === null) { - self::$emitter = self::createDispatchingEmitter(); + return self::instance()->emitter; + } + + public function __construct() + { + $this->emitter = $this->createDispatchingEmitter(); + } + + /** + * @throws EventFacadeIsSealedException + * @throws UnknownSubscriberTypeException + */ + public function registerSubscribers(Subscriber ...$subscribers): void + { + foreach ($subscribers as $subscriber) { + $this->registerSubscriber($subscriber); + } + } + + /** + * @throws EventFacadeIsSealedException + * @throws UnknownSubscriberTypeException + */ + public function registerSubscriber(Subscriber $subscriber): void + { + if ($this->sealed) { + throw new EventFacadeIsSealedException; } - return self::$emitter; + $this->deferredDispatcher()->registerSubscriber($subscriber); + } + + /** + * @throws EventFacadeIsSealedException + */ + public function registerTracer(Tracer\Tracer $tracer): void + { + if ($this->sealed) { + throw new EventFacadeIsSealedException; + } + + $this->deferredDispatcher()->registerTracer($tracer); } /** @noinspection PhpUnused */ - public static function initForIsolation(HRTime $offset): CollectingDispatcher + public function initForIsolation(HRTime $offset, bool $exportObjects): CollectingDispatcher { $dispatcher = new CollectingDispatcher; - self::$emitter = new DispatchingEmitter( + $this->emitter = new DispatchingEmitter( $dispatcher, new Telemetry\System( new Telemetry\SystemStopWatchWithOffset($offset), - new Telemetry\SystemMemoryMeter - ) + new Telemetry\SystemMemoryMeter, + $this->garbageCollectorStatusProvider(), + ), ); - self::$sealed = true; + if ($exportObjects) { + $this->emitter->exportObjects(); + } + + $this->sealed = true; return $dispatcher; } - public static function forward(EventCollection $events): void + public function forward(EventCollection $events): void { - if (self::$suspended !== null) { + if ($this->suspended !== null) { return; } - $dispatcher = self::deferredDispatcher(); + $dispatcher = $this->deferredDispatcher(); foreach ($events as $event) { $dispatcher->dispatch($event); } } - public static function seal(): void + public function seal(): void { - self::$deferringDispatcher->flush(); + $this->deferredDispatcher()->flush(); - self::$sealed = true; + $this->sealed = true; - self::emitter()->testRunnerEventFacadeSealed(); + $this->emitter->testRunnerEventFacadeSealed(); } - private static function createDispatchingEmitter(): DispatchingEmitter + private function createDispatchingEmitter(): DispatchingEmitter { return new DispatchingEmitter( - self::deferredDispatcher(), - self::createTelemetrySystem() + $this->deferredDispatcher(), + $this->createTelemetrySystem(), ); } - private static function createTelemetrySystem(): Telemetry\System + private function createTelemetrySystem(): Telemetry\System { return new Telemetry\System( new Telemetry\SystemStopWatch, - new Telemetry\SystemMemoryMeter + new Telemetry\SystemMemoryMeter, + $this->garbageCollectorStatusProvider(), ); } - private static function deferredDispatcher(): DeferringDispatcher + private function deferredDispatcher(): DeferringDispatcher { - if (self::$deferringDispatcher === null) { - self::$deferringDispatcher = new DeferringDispatcher( - new DirectDispatcher(self::typeMap()) + if ($this->deferringDispatcher === null) { + $this->deferringDispatcher = new DeferringDispatcher( + new DirectDispatcher($this->typeMap()), ); } - return self::$deferringDispatcher; + return $this->deferringDispatcher; } - private static function typeMap(): TypeMap + private function typeMap(): TypeMap { - if (self::$typeMap === null) { + if ($this->typeMap === null) { $typeMap = new TypeMap; - self::registerDefaultTypes($typeMap); + $this->registerDefaultTypes($typeMap); - self::$typeMap = $typeMap; + $this->typeMap = $typeMap; } - return self::$typeMap; + return $this->typeMap; } - private static function registerDefaultTypes(TypeMap $typeMap): void + private function registerDefaultTypes(TypeMap $typeMap): void { $defaultEvents = [ Application\Started::class, Application\Finished::class, + Test\DataProviderMethodCalled::class, + Test\DataProviderMethodFinished::class, Test\MarkedIncomplete::class, Test\AfterLastTestMethodCalled::class, Test\AfterLastTestMethodFinished::class, @@ -186,6 +208,8 @@ final class Facade Test\PreConditionFinished::class, Test\PreparationStarted::class, Test\Prepared::class, + Test\PreparationFailed::class, + Test\PrintedUnexpectedOutput::class, Test\Skipped::class, Test\WarningTriggered::class, @@ -202,6 +226,7 @@ final class Facade TestRunner\BootstrapFinished::class, TestRunner\Configured::class, TestRunner\EventFacadeSealed::class, + TestRunner\ExecutionAborted::class, TestRunner\ExecutionFinished::class, TestRunner\ExecutionStarted::class, TestRunner\ExtensionLoadedFromPhar::class, @@ -210,10 +235,14 @@ final class Facade TestRunner\Started::class, TestRunner\DeprecationTriggered::class, TestRunner\WarningTriggered::class, + TestRunner\GarbageCollectionDisabled::class, + TestRunner\GarbageCollectionTriggered::class, + TestRunner\GarbageCollectionEnabled::class, TestSuite\Filtered::class, TestSuite\Finished::class, TestSuite\Loaded::class, + TestSuite\Skipped::class, TestSuite\Sorted::class, TestSuite\Started::class, ]; @@ -221,8 +250,17 @@ final class Facade foreach ($defaultEvents as $eventClass) { $typeMap->addMapping( $eventClass . 'Subscriber', - $eventClass + $eventClass, ); } } + + private function garbageCollectorStatusProvider(): Telemetry\GarbageCollectorStatusProvider + { + if (!isset(gc_status()['running'])) { + return new Php81GarbageCollectorStatusProvider; + } + + return new Php83GarbageCollectorStatusProvider; + } } diff --git a/vendor/phpunit/phpunit/src/Event/TypeMap.php b/vendor/phpunit/phpunit/src/Event/TypeMap.php index 4b548ef1..b4217320 100644 --- a/vendor/phpunit/phpunit/src/Event/TypeMap.php +++ b/vendor/phpunit/phpunit/src/Event/TypeMap.php @@ -39,59 +39,12 @@ final class TypeMap */ public function addMapping(string $subscriberInterface, string $eventClass): void { - if (!interface_exists($subscriberInterface)) { - throw new UnknownSubscriberException( - sprintf( - 'Subscriber "%s" does not exist or is not an interface', - $subscriberInterface - ) - ); - } - - if (!class_exists($eventClass)) { - throw new UnknownEventException( - sprintf( - 'Event class "%s" does not exist', - $eventClass - ) - ); - } - - if (!in_array(Subscriber::class, class_implements($subscriberInterface), true)) { - throw new InvalidSubscriberException( - sprintf( - 'Subscriber "%s" does not implement Subscriber interface', - $subscriberInterface - ) - ); - } - - if (!in_array(Event::class, class_implements($eventClass), true)) { - throw new InvalidEventException( - sprintf( - 'Event "%s" does not implement Event interface', - $eventClass - ) - ); - } - - if (array_key_exists($subscriberInterface, $this->mapping)) { - throw new SubscriberTypeAlreadyRegisteredException( - sprintf( - 'Subscriber type "%s" already registered - cannot overwrite', - $subscriberInterface - ) - ); - } - - if (in_array($eventClass, $this->mapping, true)) { - throw new EventAlreadyAssignedException( - sprintf( - 'Event "%s" already assigned - cannot add multiple subscriber types for an event type', - $eventClass - ) - ); - } + $this->ensureSubscriberInterfaceExists($subscriberInterface); + $this->ensureSubscriberInterfaceExtendsInterface($subscriberInterface); + $this->ensureEventClassExists($eventClass); + $this->ensureEventClassImplementsEventInterface($eventClass); + $this->ensureSubscriberWasNotAlreadyRegistered($subscriberInterface); + $this->ensureEventWasNotAlreadyAssigned($eventClass); $this->mapping[$subscriberInterface] = $eventClass; } @@ -113,6 +66,8 @@ final class TypeMap } /** + * @psalm-return class-string + * * @throws MapError */ public function map(Subscriber $subscriber): string @@ -126,8 +81,110 @@ final class TypeMap throw new MapError( sprintf( 'Subscriber "%s" does not implement a known interface', - $subscriber::class - ) + $subscriber::class, + ), ); } + + /** + * @psalm-param class-string $subscriberInterface + * + * @throws UnknownSubscriberException + */ + private function ensureSubscriberInterfaceExists(string $subscriberInterface): void + { + if (!interface_exists($subscriberInterface)) { + throw new UnknownSubscriberException( + sprintf( + 'Subscriber "%s" does not exist or is not an interface', + $subscriberInterface, + ), + ); + } + } + + /** + * @psalm-param class-string $eventClass + * + * @throws UnknownEventException + */ + private function ensureEventClassExists(string $eventClass): void + { + if (!class_exists($eventClass)) { + throw new UnknownEventException( + sprintf( + 'Event class "%s" does not exist', + $eventClass, + ), + ); + } + } + + /** + * @psalm-param class-string $subscriberInterface + * + * @throws InvalidSubscriberException + */ + private function ensureSubscriberInterfaceExtendsInterface(string $subscriberInterface): void + { + if (!in_array(Subscriber::class, class_implements($subscriberInterface), true)) { + throw new InvalidSubscriberException( + sprintf( + 'Subscriber "%s" does not extend Subscriber interface', + $subscriberInterface, + ), + ); + } + } + + /** + * @psalm-param class-string $eventClass + * + * @throws InvalidEventException + */ + private function ensureEventClassImplementsEventInterface(string $eventClass): void + { + if (!in_array(Event::class, class_implements($eventClass), true)) { + throw new InvalidEventException( + sprintf( + 'Event "%s" does not implement Event interface', + $eventClass, + ), + ); + } + } + + /** + * @psalm-param class-string $subscriberInterface + * + * @throws SubscriberTypeAlreadyRegisteredException + */ + private function ensureSubscriberWasNotAlreadyRegistered(string $subscriberInterface): void + { + if (array_key_exists($subscriberInterface, $this->mapping)) { + throw new SubscriberTypeAlreadyRegisteredException( + sprintf( + 'Subscriber type "%s" already registered', + $subscriberInterface, + ), + ); + } + } + + /** + * @psalm-param class-string $eventClass + * + * @throws EventAlreadyAssignedException + */ + private function ensureEventWasNotAlreadyAssigned(string $eventClass): void + { + if (in_array($eventClass, $this->mapping, true)) { + throw new EventAlreadyAssignedException( + sprintf( + 'Event "%s" already assigned', + $eventClass, + ), + ); + } + } } diff --git a/vendor/phpunit/phpunit/src/Event/Value/ComparisonFailure.php b/vendor/phpunit/phpunit/src/Event/Value/ComparisonFailure.php index 1de13ffb..b8e5cc93 100644 --- a/vendor/phpunit/phpunit/src/Event/Value/ComparisonFailure.php +++ b/vendor/phpunit/phpunit/src/Event/Value/ComparisonFailure.php @@ -9,12 +9,6 @@ */ namespace PHPUnit\Event\Code; -use function is_bool; -use function is_scalar; -use function print_r; -use PHPUnit\Framework\ExpectationFailedException; -use Throwable; - /** * @psalm-immutable * @@ -26,36 +20,7 @@ final class ComparisonFailure private readonly string $actual; private readonly string $diff; - public static function from(Throwable $t): ?self - { - if (!$t instanceof ExpectationFailedException) { - return null; - } - - if (!$t->getComparisonFailure()) { - return null; - } - - $expectedAsString = $t->getComparisonFailure()->getExpectedAsString(); - - if (empty($expectedAsString)) { - $expectedAsString = self::mapScalarValueToString($t->getComparisonFailure()->getExpected()); - } - - $actualAsString = $t->getComparisonFailure()->getActualAsString(); - - if (empty($actualAsString)) { - $actualAsString = self::mapScalarValueToString($t->getComparisonFailure()->getActual()); - } - - return new self( - $expectedAsString, - $actualAsString, - $t->getComparisonFailure()->getDiff() - ); - } - - private function __construct(string $expected, string $actual, string $diff) + public function __construct(string $expected, string $actual, string $diff) { $this->expected = $expected; $this->actual = $actual; @@ -76,21 +41,4 @@ final class ComparisonFailure { return $this->diff; } - - private static function mapScalarValueToString(mixed $value): string - { - if ($value === null) { - return 'null'; - } - - if (is_bool($value)) { - return $value ? 'true' : 'false'; - } - - if (is_scalar($value)) { - return print_r($value, true); - } - - return ''; - } } diff --git a/vendor/phpunit/phpunit/src/Event/Value/ComparisonFailureBuilder.php b/vendor/phpunit/phpunit/src/Event/Value/ComparisonFailureBuilder.php new file mode 100644 index 00000000..be411a9d --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Value/ComparisonFailureBuilder.php @@ -0,0 +1,68 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Event\Code; + +use function is_bool; +use function is_scalar; +use function print_r; +use PHPUnit\Framework\ExpectationFailedException; +use Throwable; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class ComparisonFailureBuilder +{ + public static function from(Throwable $t): ?ComparisonFailure + { + if (!$t instanceof ExpectationFailedException) { + return null; + } + + if (!$t->getComparisonFailure()) { + return null; + } + + $expectedAsString = $t->getComparisonFailure()->getExpectedAsString(); + + if (empty($expectedAsString)) { + $expectedAsString = self::mapScalarValueToString($t->getComparisonFailure()->getExpected()); + } + + $actualAsString = $t->getComparisonFailure()->getActualAsString(); + + if (empty($actualAsString)) { + $actualAsString = self::mapScalarValueToString($t->getComparisonFailure()->getActual()); + } + + return new ComparisonFailure( + $expectedAsString, + $actualAsString, + $t->getComparisonFailure()->getDiff(), + ); + } + + private static function mapScalarValueToString(mixed $value): string + { + if ($value === null) { + return 'null'; + } + + if (is_bool($value)) { + return $value ? 'true' : 'false'; + } + + if (is_scalar($value)) { + return print_r($value, true); + } + + return ''; + } +} diff --git a/vendor/phpunit/phpunit/src/Event/Value/Runtime/PHP.php b/vendor/phpunit/phpunit/src/Event/Value/Runtime/PHP.php index 0da3c5d2..717f3c12 100644 --- a/vendor/phpunit/phpunit/src/Event/Value/Runtime/PHP.php +++ b/vendor/phpunit/phpunit/src/Event/Value/Runtime/PHP.php @@ -52,7 +52,7 @@ final class PHP $extensions = array_merge( get_loaded_extensions(true), - get_loaded_extensions() + get_loaded_extensions(), ); sort($extensions); diff --git a/vendor/phpunit/phpunit/src/Event/Value/Runtime/Runtime.php b/vendor/phpunit/phpunit/src/Event/Value/Runtime/Runtime.php index a4fa9516..cea7ba32 100644 --- a/vendor/phpunit/phpunit/src/Event/Value/Runtime/Runtime.php +++ b/vendor/phpunit/phpunit/src/Event/Value/Runtime/Runtime.php @@ -38,7 +38,7 @@ final class Runtime $this->phpunit()->versionId(), $php->version(), $php->sapi(), - $this->operatingSystem()->operatingSystem() + $this->operatingSystem()->operatingSystem(), ); } diff --git a/vendor/phpunit/phpunit/src/Event/Value/Telemetry/Duration.php b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/Duration.php index 3d826cb4..000216cd 100644 --- a/vendor/phpunit/phpunit/src/Event/Value/Telemetry/Duration.php +++ b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/Duration.php @@ -30,7 +30,7 @@ final class Duration { return new self( $seconds, - $nanoseconds + $nanoseconds, ); } @@ -65,8 +65,8 @@ final class Duration public function asString(): string { $seconds = $this->seconds(); - $minutes = 00; - $hours = 00; + $minutes = 0; + $hours = 0; if ($seconds > 60 * 60) { $hours = floor($seconds / 60 / 60); @@ -83,7 +83,7 @@ final class Duration $hours, $minutes, $seconds, - $this->nanoseconds() + $this->nanoseconds(), ); } @@ -128,8 +128,8 @@ final class Duration throw new InvalidArgumentException( sprintf( 'Value for %s must not be negative.', - $type - ) + $type, + ), ); } } @@ -141,7 +141,7 @@ final class Duration { if ($nanoseconds > 999999999) { throw new InvalidArgumentException( - 'Value for nanoseconds must not be greater than 999999999.' + 'Value for nanoseconds must not be greater than 999999999.', ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Value/Telemetry/GarbageCollectorStatus.php b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/GarbageCollectorStatus.php new file mode 100644 index 00000000..51a5ac68 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/GarbageCollectorStatus.php @@ -0,0 +1,180 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Event\Telemetry; + +use PHPUnit\Event\RuntimeException; + +/** + * @psalm-immutable + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class GarbageCollectorStatus +{ + private readonly int $runs; + private readonly int $collected; + private readonly int $threshold; + private readonly int $roots; + private readonly ?float $applicationTime; + private readonly ?float $collectorTime; + private readonly ?float $destructorTime; + private readonly ?float $freeTime; + private readonly ?bool $running; + private readonly ?bool $protected; + private readonly ?bool $full; + private readonly ?int $bufferSize; + + public function __construct(int $runs, int $collected, int $threshold, int $roots, ?float $applicationTime, ?float $collectorTime, ?float $destructorTime, ?float $freeTime, ?bool $running, ?bool $protected, ?bool $full, ?int $bufferSize) + { + $this->runs = $runs; + $this->collected = $collected; + $this->threshold = $threshold; + $this->roots = $roots; + $this->applicationTime = $applicationTime; + $this->collectorTime = $collectorTime; + $this->destructorTime = $destructorTime; + $this->freeTime = $freeTime; + $this->running = $running; + $this->protected = $protected; + $this->full = $full; + $this->bufferSize = $bufferSize; + } + + public function runs(): int + { + return $this->runs; + } + + public function collected(): int + { + return $this->collected; + } + + public function threshold(): int + { + return $this->threshold; + } + + public function roots(): int + { + return $this->roots; + } + + /** + * @psalm-assert-if-true !null $this->applicationTime + * @psalm-assert-if-true !null $this->collectorTime + * @psalm-assert-if-true !null $this->destructorTime + * @psalm-assert-if-true !null $this->freeTime + * @psalm-assert-if-true !null $this->running + * @psalm-assert-if-true !null $this->protected + * @psalm-assert-if-true !null $this->full + * @psalm-assert-if-true !null $this->bufferSize + */ + public function hasExtendedInformation(): bool + { + return $this->running !== null; + } + + /** + * @throws RuntimeException on PHP < 8.3 + */ + public function applicationTime(): float + { + if ($this->applicationTime === null) { + throw new RuntimeException('Information not available'); + } + + return $this->applicationTime; + } + + /** + * @throws RuntimeException on PHP < 8.3 + */ + public function collectorTime(): float + { + if ($this->collectorTime === null) { + throw new RuntimeException('Information not available'); + } + + return $this->collectorTime; + } + + /** + * @throws RuntimeException on PHP < 8.3 + */ + public function destructorTime(): float + { + if ($this->destructorTime === null) { + throw new RuntimeException('Information not available'); + } + + return $this->destructorTime; + } + + /** + * @throws RuntimeException on PHP < 8.3 + */ + public function freeTime(): float + { + if ($this->freeTime === null) { + throw new RuntimeException('Information not available'); + } + + return $this->freeTime; + } + + /** + * @throws RuntimeException on PHP < 8.3 + */ + public function isRunning(): bool + { + if ($this->running === null) { + throw new RuntimeException('Information not available'); + } + + return $this->running; + } + + /** + * @throws RuntimeException on PHP < 8.3 + */ + public function isProtected(): bool + { + if ($this->protected === null) { + throw new RuntimeException('Information not available'); + } + + return $this->protected; + } + + /** + * @throws RuntimeException on PHP < 8.3 + */ + public function isFull(): bool + { + if ($this->full === null) { + throw new RuntimeException('Information not available'); + } + + return $this->full; + } + + /** + * @throws RuntimeException on PHP < 8.3 + */ + public function bufferSize(): int + { + if ($this->bufferSize === null) { + throw new RuntimeException('Information not available'); + } + + return $this->bufferSize; + } +} diff --git a/vendor/phpunit/phpunit/src/Event/Value/Telemetry/GarbageCollectorStatusProvider.php b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/GarbageCollectorStatusProvider.php new file mode 100644 index 00000000..15651208 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/GarbageCollectorStatusProvider.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 PHPUnit\Event\Telemetry; + +/** + * @internal This interface is not covered by the backward compatibility promise for PHPUnit + */ +interface GarbageCollectorStatusProvider +{ + public function status(): GarbageCollectorStatus; +} diff --git a/vendor/phpunit/phpunit/src/Event/Value/Telemetry/HRTime.php b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/HRTime.php index 5fe864f5..5a82ebb8 100644 --- a/vendor/phpunit/phpunit/src/Event/Value/Telemetry/HRTime.php +++ b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/HRTime.php @@ -29,7 +29,7 @@ final class HRTime { return new self( $seconds, - $nanoseconds + $nanoseconds, ); } @@ -76,7 +76,7 @@ final class HRTime return Duration::fromSecondsAndNanoseconds( $seconds, - $nanoseconds + $nanoseconds, ); } @@ -89,8 +89,8 @@ final class HRTime throw new InvalidArgumentException( sprintf( 'Value for %s must not be negative.', - $type - ) + $type, + ), ); } } @@ -102,7 +102,7 @@ final class HRTime { if ($nanoseconds > 999999999) { throw new InvalidArgumentException( - 'Value for nanoseconds must not be greater than 999999999.' + 'Value for nanoseconds must not be greater than 999999999.', ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Value/Telemetry/Info.php b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/Info.php index cf631b84..1546d940 100644 --- a/vendor/phpunit/phpunit/src/Event/Value/Telemetry/Info.php +++ b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/Info.php @@ -68,13 +68,18 @@ final class Info return $this->memorySincePrevious; } + public function garbageCollectorStatus(): GarbageCollectorStatus + { + return $this->current->garbageCollectorStatus(); + } + public function asString(): string { return sprintf( '[%s / %s] [%d bytes]', $this->durationSinceStart()->asString(), $this->durationSincePrevious()->asString(), - $this->memoryUsage()->bytes() + $this->memoryUsage()->bytes(), ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Value/Telemetry/MemoryMeter.php b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/MemoryMeter.php index db6d8fd7..4955397e 100644 --- a/vendor/phpunit/phpunit/src/Event/Value/Telemetry/MemoryMeter.php +++ b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/MemoryMeter.php @@ -10,7 +10,7 @@ namespace PHPUnit\Event\Telemetry; /** - * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @internal This interface is not covered by the backward compatibility promise for PHPUnit */ interface MemoryMeter { diff --git a/vendor/phpunit/phpunit/src/Event/Value/Telemetry/MemoryUsage.php b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/MemoryUsage.php index 95185b53..7e8bc699 100644 --- a/vendor/phpunit/phpunit/src/Event/Value/Telemetry/MemoryUsage.php +++ b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/MemoryUsage.php @@ -1,6 +1,4 @@ - + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Event\Telemetry; + +use function gc_status; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class Php81GarbageCollectorStatusProvider implements GarbageCollectorStatusProvider +{ + public function status(): GarbageCollectorStatus + { + $status = gc_status(); + + return new GarbageCollectorStatus( + $status['runs'], + $status['collected'], + $status['threshold'], + $status['roots'], + null, + null, + null, + null, + null, + null, + null, + null, + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Event/Value/Telemetry/Php83GarbageCollectorStatusProvider.php b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/Php83GarbageCollectorStatusProvider.php new file mode 100644 index 00000000..c3808b6b --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/Php83GarbageCollectorStatusProvider.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\Event\Telemetry; + +use function gc_status; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class Php83GarbageCollectorStatusProvider implements GarbageCollectorStatusProvider +{ + public function status(): GarbageCollectorStatus + { + $status = gc_status(); + + return new GarbageCollectorStatus( + $status['runs'], + $status['collected'], + $status['threshold'], + $status['roots'], + $status['application_time'], + $status['collector_time'], + $status['destructor_time'], + $status['free_time'], + $status['running'], + $status['protected'], + $status['full'], + $status['buffer_size'], + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Event/Value/Telemetry/Snapshot.php b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/Snapshot.php index 88c29fd8..6c5a1659 100644 --- a/vendor/phpunit/phpunit/src/Event/Value/Telemetry/Snapshot.php +++ b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/Snapshot.php @@ -19,12 +19,14 @@ final class Snapshot private readonly HRTime $time; private readonly MemoryUsage $memoryUsage; private readonly MemoryUsage $peakMemoryUsage; + private readonly GarbageCollectorStatus $garbageCollectorStatus; - public function __construct(HRTime $time, MemoryUsage $memoryUsage, MemoryUsage $peakMemoryUsage) + public function __construct(HRTime $time, MemoryUsage $memoryUsage, MemoryUsage $peakMemoryUsage, GarbageCollectorStatus $garbageCollectorStatus) { - $this->time = $time; - $this->memoryUsage = $memoryUsage; - $this->peakMemoryUsage = $peakMemoryUsage; + $this->time = $time; + $this->memoryUsage = $memoryUsage; + $this->peakMemoryUsage = $peakMemoryUsage; + $this->garbageCollectorStatus = $garbageCollectorStatus; } public function time(): HRTime @@ -41,4 +43,9 @@ final class Snapshot { return $this->peakMemoryUsage; } + + public function garbageCollectorStatus(): GarbageCollectorStatus + { + return $this->garbageCollectorStatus; + } } diff --git a/vendor/phpunit/phpunit/src/Event/Value/Telemetry/StopWatch.php b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/StopWatch.php index c19796ed..8a149257 100644 --- a/vendor/phpunit/phpunit/src/Event/Value/Telemetry/StopWatch.php +++ b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/StopWatch.php @@ -10,7 +10,7 @@ namespace PHPUnit\Event\Telemetry; /** - * @internal This class is not covered by the backward compatibility promise for PHPUnit + * @internal This interface is not covered by the backward compatibility promise for PHPUnit */ interface StopWatch { diff --git a/vendor/phpunit/phpunit/src/Event/Value/Telemetry/System.php b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/System.php index 00f1b150..53b394da 100644 --- a/vendor/phpunit/phpunit/src/Event/Value/Telemetry/System.php +++ b/vendor/phpunit/phpunit/src/Event/Value/Telemetry/System.php @@ -10,17 +10,19 @@ namespace PHPUnit\Event\Telemetry; /** - * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * @internal This class is not covered by the backward compatibility promise for PHPUnit */ final class System { private readonly StopWatch $stopWatch; private readonly MemoryMeter $memoryMeter; + private readonly GarbageCollectorStatusProvider $garbageCollectorStatusProvider; - public function __construct(StopWatch $stopWatch, MemoryMeter $memoryMeter) + public function __construct(StopWatch $stopWatch, MemoryMeter $memoryMeter, GarbageCollectorStatusProvider $garbageCollectorStatusProvider) { - $this->stopWatch = $stopWatch; - $this->memoryMeter = $memoryMeter; + $this->stopWatch = $stopWatch; + $this->memoryMeter = $memoryMeter; + $this->garbageCollectorStatusProvider = $garbageCollectorStatusProvider; } public function snapshot(): Snapshot @@ -28,7 +30,8 @@ final class System return new Snapshot( $this->stopWatch->current(), $this->memoryMeter->memoryUsage(), - $this->memoryMeter->peakMemoryUsage() + $this->memoryMeter->peakMemoryUsage(), + $this->garbageCollectorStatusProvider->status(), ); } } diff --git a/vendor/phpunit/phpunit/src/Event/Value/Test/Phpt.php b/vendor/phpunit/phpunit/src/Event/Value/Test/Phpt.php index 187b32bd..10567871 100644 --- a/vendor/phpunit/phpunit/src/Event/Value/Test/Phpt.php +++ b/vendor/phpunit/phpunit/src/Event/Value/Test/Phpt.php @@ -16,11 +16,6 @@ namespace PHPUnit\Event\Code; */ final class Phpt extends Test { - public function __construct(string $file) - { - parent::__construct($file); - } - /** * @psalm-assert-if-true Phpt $this */ @@ -29,11 +24,17 @@ final class Phpt extends Test return true; } + /** + * @psalm-return non-empty-string + */ public function id(): string { return $this->file(); } + /** + * @psalm-return non-empty-string + */ public function name(): string { return $this->file(); diff --git a/vendor/phpunit/phpunit/src/Event/Value/Test/Test.php b/vendor/phpunit/phpunit/src/Event/Value/Test/Test.php index db4fbd45..6ec899c6 100644 --- a/vendor/phpunit/phpunit/src/Event/Value/Test/Test.php +++ b/vendor/phpunit/phpunit/src/Event/Value/Test/Test.php @@ -16,13 +16,22 @@ namespace PHPUnit\Event\Code; */ abstract class Test { + /** + * @psalm-var non-empty-string + */ private readonly string $file; + /** + * @psalm-param non-empty-string $file + */ public function __construct(string $file) { $this->file = $file; } + /** + * @psalm-return non-empty-string + */ public function file(): string { return $this->file; @@ -44,7 +53,13 @@ abstract class Test return false; } + /** + * @psalm-return non-empty-string + */ abstract public function id(): string; + /** + * @psalm-return non-empty-string + */ abstract public function name(): string; } diff --git a/vendor/phpunit/phpunit/src/Event/Value/Test/TestDox.php b/vendor/phpunit/phpunit/src/Event/Value/Test/TestDox.php index 2c18ac36..948d55fd 100644 --- a/vendor/phpunit/phpunit/src/Event/Value/Test/TestDox.php +++ b/vendor/phpunit/phpunit/src/Event/Value/Test/TestDox.php @@ -9,10 +9,6 @@ */ namespace PHPUnit\Event\Code; -use PHPUnit\Event\TestData\MoreThanOneDataSetFromDataProviderException; -use PHPUnit\Framework\TestCase; -use PHPUnit\Logging\TestDox\NamePrettifier; - /** * @psalm-immutable * @@ -24,36 +20,7 @@ final class TestDox private readonly string $prettifiedMethodName; private readonly string $prettifiedAndColorizedMethodName; - /** - * @throws MoreThanOneDataSetFromDataProviderException - */ - public static function fromTestCase(TestCase $testCase): self - { - $prettifier = new NamePrettifier; - - return new self( - $prettifier->prettifyTestClassName($testCase::class), - $prettifier->prettifyTestCase($testCase, false), - $prettifier->prettifyTestCase($testCase, true), - ); - } - - /** - * @psalm-param class-string $className - * @psalm-param non-empty-string $methodName - */ - public static function fromClassNameAndMethodName(string $className, string $methodName): self - { - $prettifier = new NamePrettifier; - - return new self( - $prettifier->prettifyTestClassName($className), - $prettifier->prettifyTestMethodName($methodName), - $prettifier->prettifyTestMethodName($methodName), - ); - } - - private function __construct(string $prettifiedClassName, string $prettifiedMethodName, string $prettifiedAndColorizedMethodName) + public function __construct(string $prettifiedClassName, string $prettifiedMethodName, string $prettifiedAndColorizedMethodName) { $this->prettifiedClassName = $prettifiedClassName; $this->prettifiedMethodName = $prettifiedMethodName; diff --git a/vendor/phpunit/phpunit/src/Event/Value/Test/TestDoxBuilder.php b/vendor/phpunit/phpunit/src/Event/Value/Test/TestDoxBuilder.php new file mode 100644 index 00000000..2c174698 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Value/Test/TestDoxBuilder.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\Event\Code; + +use PHPUnit\Event\TestData\MoreThanOneDataSetFromDataProviderException; +use PHPUnit\Framework\TestCase; +use PHPUnit\Logging\TestDox\NamePrettifier; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class TestDoxBuilder +{ + /** + * @throws MoreThanOneDataSetFromDataProviderException + */ + public static function fromTestCase(TestCase $testCase): TestDox + { + $prettifier = new NamePrettifier; + + return new TestDox( + $prettifier->prettifyTestClassName($testCase::class), + $prettifier->prettifyTestCase($testCase, false), + $prettifier->prettifyTestCase($testCase, true), + ); + } + + /** + * @psalm-param class-string $className + * @psalm-param non-empty-string $methodName + */ + public static function fromClassNameAndMethodName(string $className, string $methodName): TestDox + { + $prettifier = new NamePrettifier; + + return new TestDox( + $prettifier->prettifyTestClassName($className), + $prettifier->prettifyTestMethodName($methodName), + $prettifier->prettifyTestMethodName($methodName), + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Event/Value/Test/TestMethod.php b/vendor/phpunit/phpunit/src/Event/Value/Test/TestMethod.php index 0d33453a..58b2e015 100644 --- a/vendor/phpunit/phpunit/src/Event/Value/Test/TestMethod.php +++ b/vendor/phpunit/phpunit/src/Event/Value/Test/TestMethod.php @@ -11,17 +11,10 @@ namespace PHPUnit\Event\Code; use function assert; use function is_int; -use function is_numeric; use function sprintf; -use PHPUnit\Event\TestData\DataFromDataProvider; -use PHPUnit\Event\TestData\DataFromTestDependency; -use PHPUnit\Event\TestData\MoreThanOneDataSetFromDataProviderException; use PHPUnit\Event\TestData\NoDataSetFromDataProviderException; use PHPUnit\Event\TestData\TestDataCollection; -use PHPUnit\Framework\TestCase; use PHPUnit\Metadata\MetadataCollection; -use PHPUnit\Util\Reflection; -use SebastianBergmann\Exporter\Exporter; /** * @psalm-immutable @@ -39,36 +32,20 @@ final class TestMethod extends Test * @psalm-var non-empty-string */ private readonly string $methodName; + + /** + * @psalm-var non-negative-int + */ private readonly int $line; private readonly TestDox $testDox; private readonly MetadataCollection $metadata; private readonly TestDataCollection $testData; - /** - * @throws MoreThanOneDataSetFromDataProviderException - */ - public static function fromTestCase(TestCase $testCase): self - { - $methodName = $testCase->name(); - - assert(!empty($methodName)); - - $location = Reflection::sourceLocationFor($testCase::class, $methodName); - - return new self( - $testCase::class, - $methodName, - $location['file'], - $location['line'], - TestDox::fromTestCase($testCase), - MetadataCollection::for($testCase::class, $methodName), - self::dataFor($testCase), - ); - } - /** * @psalm-param class-string $className * @psalm-param non-empty-string $methodName + * @psalm-param non-empty-string $file + * @psalm-param non-negative-int $line */ public function __construct(string $className, string $methodName, string $file, int $line, TestDox $testDox, MetadataCollection $metadata, TestDataCollection $testData) { @@ -98,6 +75,9 @@ final class TestMethod extends Test return $this->methodName; } + /** + * @psalm-return non-negative-int + */ public function line(): int { return $this->line; @@ -127,6 +107,8 @@ final class TestMethod extends Test } /** + * @psalm-return non-empty-string + * * @throws NoDataSetFromDataProviderException */ public function id(): string @@ -141,6 +123,8 @@ final class TestMethod extends Test } /** + * @psalm-return non-empty-string + * * @throws NoDataSetFromDataProviderException */ public function nameWithClass(): string @@ -149,6 +133,8 @@ final class TestMethod extends Test } /** + * @psalm-return non-empty-string + * * @throws NoDataSetFromDataProviderException */ public function name(): string @@ -162,44 +148,15 @@ final class TestMethod extends Test if (is_int($dataSetName)) { $dataSetName = sprintf( ' with data set #%d', - $dataSetName + $dataSetName, ); } else { $dataSetName = sprintf( ' with data set "%s"', - $dataSetName + $dataSetName, ); } return $this->methodName . $dataSetName; } - - /** - * @throws MoreThanOneDataSetFromDataProviderException - */ - private static function dataFor(TestCase $testCase): TestDataCollection - { - $testData = []; - - if ($testCase->usesDataProvider()) { - $dataSetName = $testCase->dataName(); - - if (is_numeric($dataSetName)) { - $dataSetName = (int) $dataSetName; - } - - $testData[] = DataFromDataProvider::from( - $dataSetName, - (new Exporter)->export($testCase->providedData()) - ); - } - - if ($testCase->hasDependencyInput()) { - $testData[] = DataFromTestDependency::from( - (new Exporter)->export($testCase->dependencyInput()) - ); - } - - return TestDataCollection::fromArray($testData); - } } diff --git a/vendor/phpunit/phpunit/src/Event/Value/Test/TestMethodBuilder.php b/vendor/phpunit/phpunit/src/Event/Value/Test/TestMethodBuilder.php new file mode 100644 index 00000000..8d413f63 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Value/Test/TestMethodBuilder.php @@ -0,0 +1,94 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Event\Code; + +use function assert; +use function debug_backtrace; +use function is_numeric; +use PHPUnit\Event\Facade as EventFacade; +use PHPUnit\Event\TestData\DataFromDataProvider; +use PHPUnit\Event\TestData\DataFromTestDependency; +use PHPUnit\Event\TestData\MoreThanOneDataSetFromDataProviderException; +use PHPUnit\Event\TestData\TestDataCollection; +use PHPUnit\Framework\TestCase; +use PHPUnit\Metadata\Parser\Registry as MetadataRegistry; +use PHPUnit\Util\Exporter; +use PHPUnit\Util\Reflection; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class TestMethodBuilder +{ + /** + * @throws MoreThanOneDataSetFromDataProviderException + */ + public static function fromTestCase(TestCase $testCase): TestMethod + { + $methodName = $testCase->name(); + + assert(!empty($methodName)); + + $location = Reflection::sourceLocationFor($testCase::class, $methodName); + + return new TestMethod( + $testCase::class, + $methodName, + $location['file'], + $location['line'], + TestDoxBuilder::fromTestCase($testCase), + MetadataRegistry::parser()->forClassAndMethod($testCase::class, $methodName), + self::dataFor($testCase), + ); + } + + /** + * @throws NoTestCaseObjectOnCallStackException + */ + public static function fromCallStack(): TestMethod + { + foreach (debug_backtrace() as $frame) { + if (isset($frame['object']) && $frame['object'] instanceof TestCase) { + return $frame['object']->valueObjectForEvents(); + } + } + + throw new NoTestCaseObjectOnCallStackException; + } + + /** + * @throws MoreThanOneDataSetFromDataProviderException + */ + private static function dataFor(TestCase $testCase): TestDataCollection + { + $testData = []; + + if ($testCase->usesDataProvider()) { + $dataSetName = $testCase->dataName(); + + if (is_numeric($dataSetName)) { + $dataSetName = (int) $dataSetName; + } + + $testData[] = DataFromDataProvider::from( + $dataSetName, + Exporter::export($testCase->providedData(), EventFacade::emitter()->exportsObjects()), + ); + } + + if ($testCase->hasDependencyInput()) { + $testData[] = DataFromTestDependency::from( + Exporter::export($testCase->dependencyInput(), EventFacade::emitter()->exportsObjects()), + ); + } + + return TestDataCollection::fromArray($testData); + } +} diff --git a/vendor/phpunit/phpunit/src/Event/Value/TestSuite/TestSuite.php b/vendor/phpunit/phpunit/src/Event/Value/TestSuite/TestSuite.php index d4b73082..744f7095 100644 --- a/vendor/phpunit/phpunit/src/Event/Value/TestSuite/TestSuite.php +++ b/vendor/phpunit/phpunit/src/Event/Value/TestSuite/TestSuite.php @@ -9,17 +9,7 @@ */ namespace PHPUnit\Event\TestSuite; -use function class_exists; -use function explode; use PHPUnit\Event\Code\TestCollection; -use PHPUnit\Event\RuntimeException; -use PHPUnit\Framework\DataProviderTestSuite; -use PHPUnit\Framework\TestCase; -use PHPUnit\Framework\TestSuite as FrameworkTestSuite; -use PHPUnit\Runner\PhptTestCase; -use ReflectionClass; -use ReflectionException; -use ReflectionMethod; /** * @psalm-immutable @@ -28,90 +18,16 @@ use ReflectionMethod; */ abstract class TestSuite { + /** + * @psalm-var non-empty-string + */ private readonly string $name; private readonly int $count; private readonly TestCollection $tests; /** - * @throws RuntimeException + * @psalm-param non-empty-string $name */ - public static function fromTestSuite(FrameworkTestSuite $testSuite): self - { - $groups = []; - - foreach ($testSuite->getGroupDetails() as $groupName => $tests) { - if (!isset($groups[$groupName])) { - $groups[$groupName] = []; - } - - foreach ($tests as $test) { - $groups[$groupName][] = $test::class; - } - } - - $tests = []; - - foreach ($testSuite->tests() as $test) { - if ($test instanceof TestCase || $test instanceof PhptTestCase) { - $tests[] = $test->valueObjectForEvents(); - } - } - - if ($testSuite instanceof DataProviderTestSuite) { - [$className, $methodName] = explode('::', $testSuite->getName()); - - try { - $reflector = new ReflectionMethod($className, $methodName); - - return new TestSuiteForTestMethodWithDataProvider( - $testSuite->getName(), - $testSuite->count(), - TestCollection::fromArray($tests), - $className, - $methodName, - $reflector->getFileName(), - $reflector->getStartLine(), - ); - // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new RuntimeException( - $e->getMessage(), - $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - } - - if (class_exists($testSuite->getName())) { - try { - $reflector = new ReflectionClass($testSuite->getName()); - - return new TestSuiteForTestClass( - $testSuite->getName(), - $testSuite->count(), - TestCollection::fromArray($tests), - $reflector->getFileName(), - $reflector->getStartLine(), - ); - // @codeCoverageIgnoreStart - } catch (ReflectionException $e) { - throw new RuntimeException( - $e->getMessage(), - $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - } - - return new TestSuiteWithName( - $testSuite->getName(), - $testSuite->count(), - TestCollection::fromArray($tests), - ); - } - public function __construct(string $name, int $size, TestCollection $tests) { $this->name = $name; @@ -119,6 +35,9 @@ abstract class TestSuite $this->tests = $tests; } + /** + * @psalm-return non-empty-string + */ public function name(): string { return $this->name; diff --git a/vendor/phpunit/phpunit/src/Event/Value/TestSuite/TestSuiteBuilder.php b/vendor/phpunit/phpunit/src/Event/Value/TestSuite/TestSuiteBuilder.php new file mode 100644 index 00000000..c8988693 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Value/TestSuite/TestSuiteBuilder.php @@ -0,0 +1,122 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Event\TestSuite; + +use function explode; +use PHPUnit\Event\Code\Test; +use PHPUnit\Event\Code\TestCollection; +use PHPUnit\Event\RuntimeException; +use PHPUnit\Framework\DataProviderTestSuite; +use PHPUnit\Framework\TestCase; +use PHPUnit\Framework\TestSuite as FrameworkTestSuite; +use PHPUnit\Runner\PhptTestCase; +use ReflectionClass; +use ReflectionException; +use ReflectionMethod; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class TestSuiteBuilder +{ + /** + * @throws RuntimeException + */ + public static function from(FrameworkTestSuite $testSuite): TestSuite + { + $groups = []; + + foreach ($testSuite->groupDetails() as $groupName => $tests) { + if (!isset($groups[$groupName])) { + $groups[$groupName] = []; + } + + foreach ($tests as $test) { + $groups[$groupName][] = $test::class; + } + } + + $tests = []; + + self::process($testSuite, $tests); + + if ($testSuite instanceof DataProviderTestSuite) { + [$className, $methodName] = explode('::', $testSuite->name()); + + try { + $reflector = new ReflectionMethod($className, $methodName); + + return new TestSuiteForTestMethodWithDataProvider( + $testSuite->name(), + $testSuite->count(), + TestCollection::fromArray($tests), + $className, + $methodName, + $reflector->getFileName(), + $reflector->getStartLine(), + ); + // @codeCoverageIgnoreStart + } catch (ReflectionException $e) { + throw new RuntimeException( + $e->getMessage(), + $e->getCode(), + $e, + ); + } + // @codeCoverageIgnoreEnd + } + + if ($testSuite->isForTestClass()) { + try { + $reflector = new ReflectionClass($testSuite->name()); + + return new TestSuiteForTestClass( + $testSuite->name(), + $testSuite->count(), + TestCollection::fromArray($tests), + $reflector->getFileName(), + $reflector->getStartLine(), + ); + // @codeCoverageIgnoreStart + } catch (ReflectionException $e) { + throw new RuntimeException( + $e->getMessage(), + $e->getCode(), + $e, + ); + } + // @codeCoverageIgnoreEnd + } + + return new TestSuiteWithName( + $testSuite->name(), + $testSuite->count(), + TestCollection::fromArray($tests), + ); + } + + /** + * @psalm-param list $tests + */ + private static function process(FrameworkTestSuite $testSuite, &$tests): void + { + foreach ($testSuite->tests() as $test) { + if ($test instanceof FrameworkTestSuite) { + self::process($test, $tests); + + continue; + } + + if ($test instanceof TestCase || $test instanceof PhptTestCase) { + $tests[] = $test->valueObjectForEvents(); + } + } + } +} diff --git a/vendor/phpunit/phpunit/src/Event/Value/TestSuite/TestSuiteForTestMethodWithDataProvider.php b/vendor/phpunit/phpunit/src/Event/Value/TestSuite/TestSuiteForTestMethodWithDataProvider.php index 7c678ee7..29bebc6f 100644 --- a/vendor/phpunit/phpunit/src/Event/Value/TestSuite/TestSuiteForTestMethodWithDataProvider.php +++ b/vendor/phpunit/phpunit/src/Event/Value/TestSuite/TestSuiteForTestMethodWithDataProvider.php @@ -22,12 +22,18 @@ final class TestSuiteForTestMethodWithDataProvider extends TestSuite * @psalm-var class-string */ private readonly string $className; + + /** + * @psalm-var non-empty-string + */ private readonly string $methodName; private readonly string $file; private readonly int $line; /** - * @psalm-param class-string $name + * @psalm-param non-empty-string $name + * @psalm-param class-string $className + * @psalm-param non-empty-string $methodName */ public function __construct(string $name, int $size, TestCollection $tests, string $className, string $methodName, string $file, int $line) { @@ -47,6 +53,9 @@ final class TestSuiteForTestMethodWithDataProvider extends TestSuite return $this->className; } + /** + * @psalm-return non-empty-string + */ public function methodName(): string { return $this->methodName; diff --git a/vendor/phpunit/phpunit/src/Event/Value/Throwable.php b/vendor/phpunit/phpunit/src/Event/Value/Throwable.php index e1462553..f94a8a22 100644 --- a/vendor/phpunit/phpunit/src/Event/Value/Throwable.php +++ b/vendor/phpunit/phpunit/src/Event/Value/Throwable.php @@ -11,9 +11,6 @@ namespace PHPUnit\Event\Code; use const PHP_EOL; use PHPUnit\Event\NoPreviousThrowableException; -use PHPUnit\Framework\Exception; -use PHPUnit\Util\Filter; -use PHPUnit\Util\ThrowableToStringMapper; /** * @psalm-immutable @@ -31,31 +28,10 @@ final class Throwable private readonly string $stackTrace; private readonly ?Throwable $previous; - /** - * @throws Exception - * @throws NoPreviousThrowableException - */ - public static function from(\Throwable $t): self - { - $previous = $t->getPrevious(); - - if ($previous !== null) { - $previous = self::from($previous); - } - - return new self( - $t::class, - $t->getMessage(), - ThrowableToStringMapper::map($t), - Filter::getFilteredStacktrace($t), - $previous - ); - } - /** * @psalm-param class-string $className */ - private function __construct(string $className, string $message, string $description, string $stackTrace, ?self $previous) + public function __construct(string $className, string $message, string $description, string $stackTrace, ?self $previous) { $this->className = $className; $this->message = $message; diff --git a/vendor/phpunit/phpunit/src/Event/Value/ThrowableBuilder.php b/vendor/phpunit/phpunit/src/Event/Value/ThrowableBuilder.php new file mode 100644 index 00000000..aed9144f --- /dev/null +++ b/vendor/phpunit/phpunit/src/Event/Value/ThrowableBuilder.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 PHPUnit\Event\Code; + +use PHPUnit\Event\NoPreviousThrowableException; +use PHPUnit\Framework\Exception; +use PHPUnit\Util\Filter; +use PHPUnit\Util\ThrowableToStringMapper; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class ThrowableBuilder +{ + /** + * @throws Exception + * @throws NoPreviousThrowableException + */ + public static function from(\Throwable $t): Throwable + { + $previous = $t->getPrevious(); + + if ($previous !== null) { + $previous = self::from($previous); + } + + return new Throwable( + $t::class, + $t->getMessage(), + ThrowableToStringMapper::map($t), + Filter::getFilteredStacktrace($t), + $previous, + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Assert.php b/vendor/phpunit/phpunit/src/Framework/Assert.php index 24b6b671..6694fb6c 100644 --- a/vendor/phpunit/phpunit/src/Framework/Assert.php +++ b/vendor/phpunit/phpunit/src/Framework/Assert.php @@ -51,6 +51,7 @@ use PHPUnit\Framework\Constraint\LogicalNot; use PHPUnit\Framework\Constraint\LogicalOr; use PHPUnit\Framework\Constraint\LogicalXor; use PHPUnit\Framework\Constraint\ObjectEquals; +use PHPUnit\Framework\Constraint\ObjectHasProperty; use PHPUnit\Framework\Constraint\RegularExpression; use PHPUnit\Framework\Constraint\SameSize; use PHPUnit\Framework\Constraint\StringContains; @@ -61,7 +62,6 @@ use PHPUnit\Framework\Constraint\StringStartsWith; use PHPUnit\Framework\Constraint\TraversableContainsEqual; use PHPUnit\Framework\Constraint\TraversableContainsIdentical; use PHPUnit\Framework\Constraint\TraversableContainsOnly; -use PHPUnit\Util\Type; use PHPUnit\Util\Xml\Loader as XmlLoader; use PHPUnit\Util\Xml\XmlException; @@ -94,7 +94,7 @@ abstract class Assert final public static function assertArrayNotHasKey(int|string $key, array|ArrayAccess $array, string $message = ''): void { $constraint = new LogicalNot( - new ArrayHasKey($key) + new ArrayHasKey($key), ); static::assertThat($array, $constraint, $message); @@ -103,12 +103,12 @@ abstract class Assert /** * @throws ExpectationFailedException */ - final public static function assertIsList(array $array, string $message = ''): void + final public static function assertIsList(mixed $array, string $message = ''): void { static::assertThat( $array, new IsList, - $message + $message, ); } @@ -144,7 +144,7 @@ abstract class Assert final public static function assertNotContains(mixed $needle, iterable $haystack, string $message = ''): void { $constraint = new LogicalNot( - new TraversableContainsIdentical($needle) + new TraversableContainsIdentical($needle), ); static::assertThat($haystack, $constraint, $message); @@ -176,9 +176,9 @@ abstract class Assert $haystack, new TraversableContainsOnly( $type, - $isNativeType + $isNativeType, ), - $message + $message, ); } @@ -194,9 +194,9 @@ abstract class Assert $haystack, new TraversableContainsOnly( $className, - false + false, ), - $message + $message, ); } @@ -217,10 +217,10 @@ abstract class Assert new LogicalNot( new TraversableContainsOnly( $type, - $isNativeType - ) + $isNativeType, + ), ), - $message + $message, ); } @@ -229,17 +229,18 @@ abstract class Assert * * @throws Exception * @throws ExpectationFailedException + * @throws GeneratorNotSupportedException */ final public static function assertCount(int $expectedCount, Countable|iterable $haystack, string $message = ''): void { if ($haystack instanceof Generator) { - throw new GeneratorNotSupportedException; + throw GeneratorNotSupportedException::fromParameterName('$haystack'); } static::assertThat( $haystack, new Count($expectedCount), - $message + $message, ); } @@ -248,11 +249,16 @@ abstract class Assert * * @throws Exception * @throws ExpectationFailedException + * @throws GeneratorNotSupportedException */ final public static function assertNotCount(int $expectedCount, Countable|iterable $haystack, string $message = ''): void { + if ($haystack instanceof Generator) { + throw GeneratorNotSupportedException::fromParameterName('$haystack'); + } + $constraint = new LogicalNot( - new Count($expectedCount) + new Count($expectedCount), ); static::assertThat($haystack, $constraint, $message); @@ -303,7 +309,7 @@ abstract class Assert { $constraint = new IsEqualWithDelta( $expected, - $delta + $delta, ); static::assertThat($actual, $constraint, $message); @@ -317,7 +323,7 @@ abstract class Assert final public static function assertNotEquals(mixed $expected, mixed $actual, string $message = ''): void { $constraint = new LogicalNot( - new IsEqual($expected) + new IsEqual($expected), ); static::assertThat($actual, $constraint, $message); @@ -331,7 +337,7 @@ abstract class Assert final public static function assertNotEqualsCanonicalizing(mixed $expected, mixed $actual, string $message = ''): void { $constraint = new LogicalNot( - new IsEqualCanonicalizing($expected) + new IsEqualCanonicalizing($expected), ); static::assertThat($actual, $constraint, $message); @@ -345,7 +351,7 @@ abstract class Assert final public static function assertNotEqualsIgnoringCase(mixed $expected, mixed $actual, string $message = ''): void { $constraint = new LogicalNot( - new IsEqualIgnoringCase($expected) + new IsEqualIgnoringCase($expected), ); static::assertThat($actual, $constraint, $message); @@ -361,8 +367,8 @@ abstract class Assert $constraint = new LogicalNot( new IsEqualWithDelta( $expected, - $delta - ) + $delta, + ), ); static::assertThat($actual, $constraint, $message); @@ -376,7 +382,7 @@ abstract class Assert static::assertThat( $actual, static::objectEquals($expected, $method), - $message + $message, ); } @@ -384,11 +390,16 @@ abstract class Assert * Asserts that a variable is empty. * * @throws ExpectationFailedException + * @throws GeneratorNotSupportedException * * @psalm-assert empty $actual */ final public static function assertEmpty(mixed $actual, string $message = ''): void { + if ($actual instanceof Generator) { + throw GeneratorNotSupportedException::fromParameterName('$actual'); + } + static::assertThat($actual, static::isEmpty(), $message); } @@ -396,11 +407,16 @@ abstract class Assert * Asserts that a variable is not empty. * * @throws ExpectationFailedException + * @throws GeneratorNotSupportedException * * @psalm-assert !empty $actual */ final public static function assertNotEmpty(mixed $actual, string $message = ''): void { + if ($actual instanceof Generator) { + throw GeneratorNotSupportedException::fromParameterName('$actual'); + } + static::assertThat($actual, static::logicalNot(static::isEmpty()), $message); } @@ -424,7 +440,7 @@ abstract class Assert static::assertThat( $actual, static::greaterThanOrEqual($expected), - $message + $message, ); } @@ -476,7 +492,7 @@ abstract class Assert static::assertFileExists($actual, $message); $constraint = new IsEqualCanonicalizing( - file_get_contents($expected) + file_get_contents($expected), ); static::assertThat(file_get_contents($actual), $constraint, $message); @@ -510,7 +526,7 @@ abstract class Assert static::assertFileExists($actual, $message); $constraint = new LogicalNot( - new IsEqual(file_get_contents($expected)) + new IsEqual(file_get_contents($expected)), ); static::assertThat(file_get_contents($actual), $constraint, $message); @@ -528,7 +544,7 @@ abstract class Assert static::assertFileExists($actual, $message); $constraint = new LogicalNot( - new IsEqualCanonicalizing(file_get_contents($expected)) + new IsEqualCanonicalizing(file_get_contents($expected)), ); static::assertThat(file_get_contents($actual), $constraint, $message); @@ -546,7 +562,7 @@ abstract class Assert static::assertFileExists($actual, $message); $constraint = new LogicalNot( - new IsEqualIgnoringCase(file_get_contents($expected)) + new IsEqualIgnoringCase(file_get_contents($expected)), ); static::assertThat(file_get_contents($actual), $constraint, $message); @@ -608,7 +624,7 @@ abstract class Assert static::assertFileExists($expectedFile, $message); $constraint = new LogicalNot( - new IsEqual(file_get_contents($expectedFile)) + new IsEqual(file_get_contents($expectedFile)), ); static::assertThat($actualString, $constraint, $message); @@ -625,7 +641,7 @@ abstract class Assert static::assertFileExists($expectedFile, $message); $constraint = new LogicalNot( - new IsEqualCanonicalizing(file_get_contents($expectedFile)) + new IsEqualCanonicalizing(file_get_contents($expectedFile)), ); static::assertThat($actualString, $constraint, $message); @@ -642,7 +658,7 @@ abstract class Assert static::assertFileExists($expectedFile, $message); $constraint = new LogicalNot( - new IsEqualIgnoringCase(file_get_contents($expectedFile)) + new IsEqualIgnoringCase(file_get_contents($expectedFile)), ); static::assertThat($actualString, $constraint, $message); @@ -918,6 +934,36 @@ abstract class Assert static::assertThat($actual, static::isNan(), $message); } + /** + * Asserts that an object has a specified property. + * + * @throws ExpectationFailedException + */ + final public static function assertObjectHasProperty(string $propertyName, object $object, string $message = ''): void + { + static::assertThat( + $object, + new ObjectHasProperty($propertyName), + $message, + ); + } + + /** + * Asserts that an object does not have a specified property. + * + * @throws ExpectationFailedException + */ + final public static function assertObjectNotHasProperty(string $propertyName, object $object, string $message = ''): void + { + static::assertThat( + $object, + new LogicalNot( + new ObjectHasProperty($propertyName), + ), + $message, + ); + } + /** * Asserts that two variables have the same type and value. * Used on objects, it asserts that two variables reference @@ -936,7 +982,7 @@ abstract class Assert static::assertThat( $actual, new IsIdentical($expected), - $message + $message, ); } @@ -956,9 +1002,9 @@ abstract class Assert static::assertThat( $actual, new LogicalNot( - new IsIdentical($expected) + new IsIdentical($expected), ), - $message + $message, ); } @@ -967,6 +1013,7 @@ abstract class Assert * * @throws Exception * @throws ExpectationFailedException + * @throws UnknownClassOrInterfaceException * * @psalm-template ExpectedType of object * @@ -983,7 +1030,7 @@ abstract class Assert static::assertThat( $actual, new IsInstanceOf($expected), - $message + $message, ); } @@ -1008,9 +1055,9 @@ abstract class Assert static::assertThat( $actual, new LogicalNot( - new IsInstanceOf($expected) + new IsInstanceOf($expected), ), - $message + $message, ); } @@ -1027,7 +1074,7 @@ abstract class Assert static::assertThat( $actual, new IsType(IsType::TYPE_ARRAY), - $message + $message, ); } @@ -1044,7 +1091,7 @@ abstract class Assert static::assertThat( $actual, new IsType(IsType::TYPE_BOOL), - $message + $message, ); } @@ -1061,7 +1108,7 @@ abstract class Assert static::assertThat( $actual, new IsType(IsType::TYPE_FLOAT), - $message + $message, ); } @@ -1078,7 +1125,7 @@ abstract class Assert static::assertThat( $actual, new IsType(IsType::TYPE_INT), - $message + $message, ); } @@ -1095,7 +1142,7 @@ abstract class Assert static::assertThat( $actual, new IsType(IsType::TYPE_NUMERIC), - $message + $message, ); } @@ -1112,7 +1159,7 @@ abstract class Assert static::assertThat( $actual, new IsType(IsType::TYPE_OBJECT), - $message + $message, ); } @@ -1129,7 +1176,7 @@ abstract class Assert static::assertThat( $actual, new IsType(IsType::TYPE_RESOURCE), - $message + $message, ); } @@ -1146,7 +1193,7 @@ abstract class Assert static::assertThat( $actual, new IsType(IsType::TYPE_CLOSED_RESOURCE), - $message + $message, ); } @@ -1163,7 +1210,7 @@ abstract class Assert static::assertThat( $actual, new IsType(IsType::TYPE_STRING), - $message + $message, ); } @@ -1180,7 +1227,7 @@ abstract class Assert static::assertThat( $actual, new IsType(IsType::TYPE_SCALAR), - $message + $message, ); } @@ -1197,7 +1244,7 @@ abstract class Assert static::assertThat( $actual, new IsType(IsType::TYPE_CALLABLE), - $message + $message, ); } @@ -1214,7 +1261,7 @@ abstract class Assert static::assertThat( $actual, new IsType(IsType::TYPE_ITERABLE), - $message + $message, ); } @@ -1231,7 +1278,7 @@ abstract class Assert static::assertThat( $actual, new LogicalNot(new IsType(IsType::TYPE_ARRAY)), - $message + $message, ); } @@ -1248,7 +1295,7 @@ abstract class Assert static::assertThat( $actual, new LogicalNot(new IsType(IsType::TYPE_BOOL)), - $message + $message, ); } @@ -1265,7 +1312,7 @@ abstract class Assert static::assertThat( $actual, new LogicalNot(new IsType(IsType::TYPE_FLOAT)), - $message + $message, ); } @@ -1282,7 +1329,7 @@ abstract class Assert static::assertThat( $actual, new LogicalNot(new IsType(IsType::TYPE_INT)), - $message + $message, ); } @@ -1299,7 +1346,7 @@ abstract class Assert static::assertThat( $actual, new LogicalNot(new IsType(IsType::TYPE_NUMERIC)), - $message + $message, ); } @@ -1316,7 +1363,7 @@ abstract class Assert static::assertThat( $actual, new LogicalNot(new IsType(IsType::TYPE_OBJECT)), - $message + $message, ); } @@ -1333,7 +1380,7 @@ abstract class Assert static::assertThat( $actual, new LogicalNot(new IsType(IsType::TYPE_RESOURCE)), - $message + $message, ); } @@ -1350,7 +1397,7 @@ abstract class Assert static::assertThat( $actual, new LogicalNot(new IsType(IsType::TYPE_CLOSED_RESOURCE)), - $message + $message, ); } @@ -1367,7 +1414,7 @@ abstract class Assert static::assertThat( $actual, new LogicalNot(new IsType(IsType::TYPE_STRING)), - $message + $message, ); } @@ -1384,7 +1431,7 @@ abstract class Assert static::assertThat( $actual, new LogicalNot(new IsType(IsType::TYPE_SCALAR)), - $message + $message, ); } @@ -1401,7 +1448,7 @@ abstract class Assert static::assertThat( $actual, new LogicalNot(new IsType(IsType::TYPE_CALLABLE)), - $message + $message, ); } @@ -1418,7 +1465,7 @@ abstract class Assert static::assertThat( $actual, new LogicalNot(new IsType(IsType::TYPE_ITERABLE)), - $message + $message, ); } @@ -1442,9 +1489,9 @@ abstract class Assert static::assertThat( $string, new LogicalNot( - new RegularExpression($pattern) + new RegularExpression($pattern), ), - $message + $message, ); } @@ -1454,13 +1501,22 @@ abstract class Assert * * @throws Exception * @throws ExpectationFailedException + * @throws GeneratorNotSupportedException */ final public static function assertSameSize(Countable|iterable $expected, Countable|iterable $actual, string $message = ''): void { + if ($expected instanceof Generator) { + throw GeneratorNotSupportedException::fromParameterName('$expected'); + } + + if ($actual instanceof Generator) { + throw GeneratorNotSupportedException::fromParameterName('$actual'); + } + static::assertThat( $actual, new SameSize($expected), - $message + $message, ); } @@ -1470,15 +1526,24 @@ abstract class Assert * * @throws Exception * @throws ExpectationFailedException + * @throws GeneratorNotSupportedException */ final public static function assertNotSameSize(Countable|iterable $expected, Countable|iterable $actual, string $message = ''): void { + if ($expected instanceof Generator) { + throw GeneratorNotSupportedException::fromParameterName('$expected'); + } + + if ($actual instanceof Generator) { + throw GeneratorNotSupportedException::fromParameterName('$actual'); + } + static::assertThat( $actual, new LogicalNot( - new SameSize($expected) + new SameSize($expected), ), - $message + $message, ); } @@ -1500,6 +1565,39 @@ abstract class Assert static::assertThat($actual, new StringEqualsStringIgnoringLineEndings($expected), $message); } + /** + * Asserts that a string matches a given format string. + * + * @throws ExpectationFailedException + */ + final public static function assertFileMatchesFormat(string $format, string $actualFile, string $message = ''): void + { + static::assertFileExists($actualFile, $message); + + static::assertThat( + file_get_contents($actualFile), + new StringMatchesFormatDescription($format), + $message, + ); + } + + /** + * Asserts that a string matches a given format string. + * + * @throws ExpectationFailedException + */ + final public static function assertFileMatchesFormatFile(string $formatFile, string $actualFile, string $message = ''): void + { + static::assertFileExists($formatFile, $message); + static::assertFileExists($actualFile, $message); + + static::assertThat( + file_get_contents($actualFile), + new StringMatchesFormatDescription(file_get_contents($formatFile)), + $message, + ); + } + /** * Asserts that a string matches a given format string. * @@ -1514,15 +1612,17 @@ abstract class Assert * Asserts that a string does not match a given format string. * * @throws ExpectationFailedException + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5472 */ final public static function assertStringNotMatchesFormat(string $format, string $string, string $message = ''): void { static::assertThat( $string, new LogicalNot( - new StringMatchesFormatDescription($format) + new StringMatchesFormatDescription($format), ), - $message + $message, ); } @@ -1538,9 +1638,9 @@ abstract class Assert static::assertThat( $string, new StringMatchesFormatDescription( - file_get_contents($formatFile) + file_get_contents($formatFile), ), - $message + $message, ); } @@ -1548,6 +1648,8 @@ abstract class Assert * Asserts that a string does not match a given format string. * * @throws ExpectationFailedException + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5472 */ final public static function assertStringNotMatchesFormatFile(string $formatFile, string $string, string $message = ''): void { @@ -1557,10 +1659,10 @@ abstract class Assert $string, new LogicalNot( new StringMatchesFormatDescription( - file_get_contents($formatFile) - ) + file_get_contents($formatFile), + ), ), - $message + $message, ); } @@ -1590,9 +1692,9 @@ abstract class Assert static::assertThat( $string, new LogicalNot( - new StringStartsWith($prefix) + new StringStartsWith($prefix), ), - $message + $message, ); } @@ -1662,9 +1764,9 @@ abstract class Assert static::assertThat( $string, new LogicalNot( - new StringEndsWith($suffix) + new StringEndsWith($suffix), ), - $message + $message, ); } @@ -1790,9 +1892,9 @@ abstract class Assert * * @throws ExpectationFailedException */ - final public static function assertJson(string $actualJson, string $message = ''): void + final public static function assertJson(string $actual, string $message = ''): void { - static::assertThat($actualJson, static::isJson(), $message); + static::assertThat($actual, static::isJson(), $message); } /** @@ -1821,9 +1923,9 @@ abstract class Assert static::assertThat( $actualJson, new LogicalNot( - new JsonMatches($expectedJson) + new JsonMatches($expectedJson), ), - $message + $message, ); } @@ -1859,9 +1961,9 @@ abstract class Assert static::assertThat( $actualJson, new LogicalNot( - new JsonMatches($expectedJson) + new JsonMatches($expectedJson), ), - $message + $message, ); } @@ -1882,7 +1984,7 @@ abstract class Assert static::assertJson($actualJson, $message); $constraintExpected = new JsonMatches( - $expectedJson + $expectedJson, ); $constraintActual = new JsonMatches($actualJson); @@ -1908,7 +2010,7 @@ abstract class Assert static::assertJson($actualJson, $message); $constraintExpected = new JsonMatches( - $expectedJson + $expectedJson, ); $constraintActual = new JsonMatches($actualJson); @@ -2082,7 +2184,7 @@ abstract class Assert { return static::logicalOr( new IsEqual($value), - new GreaterThan($value) + new GreaterThan($value), ); } @@ -2091,12 +2193,17 @@ abstract class Assert return new IsIdentical($value); } + /** + * @throws UnknownClassOrInterfaceException + */ final public static function isInstanceOf(string $className): IsInstanceOf { return new IsInstanceOf($className); } /** + * @psalm-param 'array'|'boolean'|'bool'|'double'|'float'|'integer'|'int'|'null'|'numeric'|'object'|'real'|'resource'|'resource (closed)'|'string'|'scalar'|'callable'|'iterable' $type + * * @throws Exception */ final public static function isType(string $type): IsType @@ -2113,7 +2220,7 @@ abstract class Assert { return static::logicalOr( new IsEqual($value), - new LessThan($value) + new LessThan($value), ); } diff --git a/vendor/phpunit/phpunit/src/Framework/Assert/Functions.php b/vendor/phpunit/phpunit/src/Framework/Assert/Functions.php index 3c20696c..21a74a3f 100644 --- a/vendor/phpunit/phpunit/src/Framework/Assert/Functions.php +++ b/vendor/phpunit/phpunit/src/Framework/Assert/Functions.php @@ -111,7 +111,7 @@ if (!function_exists('PHPUnit\Framework\assertIsList')) { * * @see Assert::assertIsList */ - function assertIsList(array $array, string $message = ''): void + function assertIsList(mixed $array, string $message = ''): void { Assert::assertIsList(...func_get_args()); } @@ -236,6 +236,7 @@ if (!function_exists('PHPUnit\Framework\assertCount')) { * * @throws Exception * @throws ExpectationFailedException + * @throws GeneratorNotSupportedException * * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * @@ -253,6 +254,7 @@ if (!function_exists('PHPUnit\Framework\assertNotCount')) { * * @throws Exception * @throws ExpectationFailedException + * @throws GeneratorNotSupportedException * * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * @@ -411,6 +413,7 @@ if (!function_exists('PHPUnit\Framework\assertEmpty')) { * Asserts that a variable is empty. * * @throws ExpectationFailedException + * @throws GeneratorNotSupportedException * * @psalm-assert empty $actual * @@ -429,6 +432,7 @@ if (!function_exists('PHPUnit\Framework\assertNotEmpty')) { * Asserts that a variable is not empty. * * @throws ExpectationFailedException + * @throws GeneratorNotSupportedException * * @psalm-assert !empty $actual * @@ -1122,6 +1126,38 @@ if (!function_exists('PHPUnit\Framework\assertNan')) { } } +if (!function_exists('PHPUnit\Framework\assertObjectHasProperty')) { + /** + * Asserts that an object has a specified property. + * + * @throws ExpectationFailedException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @see Assert::assertObjectHasProperty + */ + function assertObjectHasProperty(string $propertyName, object $object, string $message = ''): void + { + Assert::assertObjectHasProperty(...func_get_args()); + } +} + +if (!function_exists('PHPUnit\Framework\assertObjectNotHasProperty')) { + /** + * Asserts that an object does not have a specified property. + * + * @throws ExpectationFailedException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @see Assert::assertObjectNotHasProperty + */ + function assertObjectNotHasProperty(string $propertyName, object $object, string $message = ''): void + { + Assert::assertObjectNotHasProperty(...func_get_args()); + } +} + if (!function_exists('PHPUnit\Framework\assertSame')) { /** * Asserts that two variables have the same type and value. @@ -1170,6 +1206,7 @@ if (!function_exists('PHPUnit\Framework\assertInstanceOf')) { * * @throws Exception * @throws ExpectationFailedException + * @throws UnknownClassOrInterfaceException * * @psalm-template ExpectedType of object * @@ -1705,6 +1742,7 @@ if (!function_exists('PHPUnit\Framework\assertSameSize')) { * * @throws Exception * @throws ExpectationFailedException + * @throws GeneratorNotSupportedException * * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * @@ -1723,6 +1761,7 @@ if (!function_exists('PHPUnit\Framework\assertNotSameSize')) { * * @throws Exception * @throws ExpectationFailedException + * @throws GeneratorNotSupportedException * * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * @@ -1764,6 +1803,38 @@ if (!function_exists('PHPUnit\Framework\assertStringEqualsStringIgnoringLineEndi } } +if (!function_exists('PHPUnit\Framework\assertFileMatchesFormat')) { + /** + * Asserts that a string matches a given format string. + * + * @throws ExpectationFailedException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @see Assert::assertFileMatchesFormat + */ + function assertFileMatchesFormat(string $format, string $actualFile, string $message = ''): void + { + Assert::assertFileMatchesFormat(...func_get_args()); + } +} + +if (!function_exists('PHPUnit\Framework\assertFileMatchesFormatFile')) { + /** + * Asserts that a string matches a given format string. + * + * @throws ExpectationFailedException + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @see Assert::assertFileMatchesFormatFile + */ + function assertFileMatchesFormatFile(string $formatFile, string $actualFile, string $message = ''): void + { + Assert::assertFileMatchesFormatFile(...func_get_args()); + } +} + if (!function_exists('PHPUnit\Framework\assertStringMatchesFormat')) { /** * Asserts that a string matches a given format string. @@ -1786,6 +1857,8 @@ if (!function_exists('PHPUnit\Framework\assertStringNotMatchesFormat')) { * * @throws ExpectationFailedException * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5472 + * * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertStringNotMatchesFormat @@ -1818,6 +1891,8 @@ if (!function_exists('PHPUnit\Framework\assertStringNotMatchesFormatFile')) { * * @throws ExpectationFailedException * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5472 + * * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit * * @see Assert::assertStringNotMatchesFormatFile @@ -2089,7 +2164,7 @@ if (!function_exists('PHPUnit\Framework\assertJson')) { * * @see Assert::assertJson */ - function assertJson(string $actualJson, string $message = ''): void + function assertJson(string $actual, string $message = ''): void { Assert::assertJson(...func_get_args()); } @@ -2192,9 +2267,6 @@ if (!function_exists('PHPUnit\Framework\assertJsonFileNotEqualsJsonFile')) { } if (!function_exists('PHPUnit\Framework\logicalAnd')) { - /** - * @throws Exception - */ function logicalAnd(mixed ...$constraints): LogicalAnd { return Assert::logicalAnd(...func_get_args()); @@ -2300,9 +2372,6 @@ if (!function_exists('PHPUnit\Framework\containsIdentical')) { } if (!function_exists('PHPUnit\Framework\containsOnly')) { - /** - * @throws Exception - */ function containsOnly(string $type): TraversableContainsOnly { return Assert::containsOnly(...func_get_args()); @@ -2310,9 +2379,6 @@ if (!function_exists('PHPUnit\Framework\containsOnly')) { } if (!function_exists('PHPUnit\Framework\containsOnlyInstancesOf')) { - /** - * @throws Exception - */ function containsOnlyInstancesOf(string $className): TraversableContainsOnly { return Assert::containsOnlyInstancesOf(...func_get_args()); @@ -2425,9 +2491,6 @@ if (!function_exists('PHPUnit\Framework\isInstanceOf')) { } if (!function_exists('PHPUnit\Framework\isType')) { - /** - * @throws Exception - */ function isType(string $type): IsType { return Assert::isType(...func_get_args()); @@ -2463,9 +2526,6 @@ if (!function_exists('PHPUnit\Framework\matches')) { } if (!function_exists('PHPUnit\Framework\stringStartsWith')) { - /** - * @throws InvalidArgumentException - */ function stringStartsWith(string $prefix): StringStartsWith { return Assert::stringStartsWith(...func_get_args()); @@ -2473,9 +2533,6 @@ if (!function_exists('PHPUnit\Framework\stringStartsWith')) { } if (!function_exists('PHPUnit\Framework\stringContains')) { - /** - * @throws InvalidArgumentException - */ function stringContains(string $string, bool $case = true): StringContains { return Assert::stringContains(...func_get_args()); @@ -2483,9 +2540,6 @@ if (!function_exists('PHPUnit\Framework\stringContains')) { } if (!function_exists('PHPUnit\Framework\stringEndsWith')) { - /** - * @throws InvalidArgumentException - */ function stringEndsWith(string $suffix): StringEndsWith { return Assert::stringEndsWith(...func_get_args()); @@ -2542,7 +2596,7 @@ if (!function_exists('PHPUnit\Framework\atLeast')) { function atLeast(int $requiredInvocations): InvokedAtLeastCountMatcher { return new InvokedAtLeastCountMatcher( - $requiredInvocations + $requiredInvocations, ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Attributes/CodeCoverageIgnore.php b/vendor/phpunit/phpunit/src/Framework/Attributes/CodeCoverageIgnore.php index 235177ee..38ec37ad 100644 --- a/vendor/phpunit/phpunit/src/Framework/Attributes/CodeCoverageIgnore.php +++ b/vendor/phpunit/phpunit/src/Framework/Attributes/CodeCoverageIgnore.php @@ -15,6 +15,8 @@ use Attribute; * @psalm-immutable * * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5236 */ #[Attribute(Attribute::TARGET_CLASS | Attribute::TARGET_METHOD)] final class CodeCoverageIgnore diff --git a/vendor/phpunit/phpunit/src/Framework/Attributes/IgnoreClassForCodeCoverage.php b/vendor/phpunit/phpunit/src/Framework/Attributes/IgnoreClassForCodeCoverage.php new file mode 100644 index 00000000..28355074 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Attributes/IgnoreClassForCodeCoverage.php @@ -0,0 +1,44 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\Attributes; + +use Attribute; + +/** + * @psalm-immutable + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5513 + */ +#[Attribute(Attribute::TARGET_CLASS | Attribute::IS_REPEATABLE)] +final class IgnoreClassForCodeCoverage +{ + /** + * @psalm-var class-string + */ + private readonly string $className; + + /** + * @psalm-param class-string $className + */ + public function __construct(string $className) + { + $this->className = $className; + } + + /** + * @psalm-return class-string + */ + public function className(): string + { + return $this->className; + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Attributes/IgnoreDeprecations.php b/vendor/phpunit/phpunit/src/Framework/Attributes/IgnoreDeprecations.php new file mode 100644 index 00000000..cf48aac1 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Attributes/IgnoreDeprecations.php @@ -0,0 +1,22 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\Attributes; + +use Attribute; + +/** + * @psalm-immutable + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +#[Attribute(Attribute::TARGET_CLASS | Attribute::TARGET_METHOD)] +final class IgnoreDeprecations +{ +} diff --git a/vendor/phpunit/phpunit/src/Framework/Attributes/IgnoreFunctionForCodeCoverage.php b/vendor/phpunit/phpunit/src/Framework/Attributes/IgnoreFunctionForCodeCoverage.php new file mode 100644 index 00000000..90a4bab0 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Attributes/IgnoreFunctionForCodeCoverage.php @@ -0,0 +1,44 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\Attributes; + +use Attribute; + +/** + * @psalm-immutable + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5513 + */ +#[Attribute(Attribute::TARGET_CLASS | Attribute::IS_REPEATABLE)] +final class IgnoreFunctionForCodeCoverage +{ + /** + * @psalm-var non-empty-string + */ + private readonly string $functionName; + + /** + * @psalm-param non-empty-string $functionName + */ + public function __construct(string $functionName) + { + $this->functionName = $functionName; + } + + /** + * @psalm-return non-empty-string + */ + public function functionName(): string + { + return $this->functionName; + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Attributes/IgnoreMethodForCodeCoverage.php b/vendor/phpunit/phpunit/src/Framework/Attributes/IgnoreMethodForCodeCoverage.php new file mode 100644 index 00000000..a76188f9 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Attributes/IgnoreMethodForCodeCoverage.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 PHPUnit\Framework\Attributes; + +use Attribute; + +/** + * @psalm-immutable + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5513 + */ +#[Attribute(Attribute::TARGET_CLASS | Attribute::IS_REPEATABLE)] +final class IgnoreMethodForCodeCoverage +{ + /** + * @psalm-var class-string + */ + private readonly string $className; + + /** + * @psalm-var non-empty-string + */ + private readonly string $methodName; + + /** + * @psalm-param class-string $className + * @psalm-param non-empty-string $methodName + */ + public function __construct(string $className, string $methodName) + { + $this->className = $className; + $this->methodName = $methodName; + } + + /** + * @psalm-return class-string + */ + public function className(): string + { + return $this->className; + } + + /** + * @psalm-return non-empty-string + */ + public function methodName(): string + { + return $this->methodName; + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Attributes/WithoutErrorHandler.php b/vendor/phpunit/phpunit/src/Framework/Attributes/WithoutErrorHandler.php new file mode 100644 index 00000000..2dce1e98 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Attributes/WithoutErrorHandler.php @@ -0,0 +1,22 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\Attributes; + +use Attribute; + +/** + * @psalm-immutable + * + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +#[Attribute(Attribute::TARGET_METHOD)] +final class WithoutErrorHandler +{ +} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/Count.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/Count.php index 512013ce..2ec012a0 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/Count.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/Count.php @@ -37,7 +37,7 @@ class Count extends Constraint { return sprintf( 'count matches %d', - $this->expectedCount + $this->expectedCount, ); } @@ -73,7 +73,7 @@ class Count extends Constraint throw new Exception( $e->getMessage(), $e->getCode(), - $e + $e, ); } } @@ -120,7 +120,7 @@ class Count extends Constraint return sprintf( 'actual size %d matches expected size %d', (int) $this->getCountOf($other), - $this->expectedCount + $this->expectedCount, ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/GreaterThan.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/GreaterThan.php index 2c0e0685..7e8f0ee6 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/GreaterThan.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/GreaterThan.php @@ -9,14 +9,16 @@ */ namespace PHPUnit\Framework\Constraint; +use PHPUnit\Util\Exporter; + /** * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class GreaterThan extends Constraint { - private readonly float|int $value; + private readonly mixed $value; - public function __construct(float|int $value) + public function __construct(mixed $value) { $this->value = $value; } @@ -24,9 +26,9 @@ final class GreaterThan extends Constraint /** * Returns a string representation of the constraint. */ - public function toString(): string + public function toString(bool $exportObjects = false): string { - return 'is greater than ' . $this->exporter()->export($this->value); + return 'is greater than ' . Exporter::export($this->value, $exportObjects); } /** diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/IsEmpty.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/IsEmpty.php index 6710db3a..ddf4a9f7 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/IsEmpty.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/IsEmpty.php @@ -60,7 +60,7 @@ final class IsEmpty extends Constraint '%s %s %s', str_starts_with($type, 'a') || str_starts_with($type, 'o') ? 'an' : 'a', $type, - $this->toString() + $this->toString(true), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/LessThan.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/LessThan.php index db3b7bee..cc3ec344 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/LessThan.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Cardinality/LessThan.php @@ -9,14 +9,16 @@ */ namespace PHPUnit\Framework\Constraint; +use PHPUnit\Util\Exporter; + /** * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class LessThan extends Constraint { - private readonly float|int $value; + private readonly mixed $value; - public function __construct(float|int $value) + public function __construct(mixed $value) { $this->value = $value; } @@ -24,9 +26,9 @@ final class LessThan extends Constraint /** * Returns a string representation of the constraint. */ - public function toString(): string + public function toString(bool $exportObjects = false): string { - return 'is less than ' . $this->exporter()->export($this->value); + return 'is less than ' . Exporter::export($this->value, $exportObjects); } /** diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Constraint.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Constraint.php index 01045c6d..40ffb820 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Constraint.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Constraint.php @@ -9,20 +9,20 @@ */ namespace PHPUnit\Framework\Constraint; +use function gettype; use function sprintf; +use function strtolower; use Countable; use PHPUnit\Framework\ExpectationFailedException; use PHPUnit\Framework\SelfDescribing; +use PHPUnit\Util\Exporter; use SebastianBergmann\Comparator\ComparisonFailure; -use SebastianBergmann\Exporter\Exporter; /** * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ abstract class Constraint implements Countable, SelfDescribing { - private ?Exporter $exporter = null; - /** * Evaluates the constraint for parameter $other. * @@ -62,13 +62,12 @@ abstract class Constraint implements Countable, SelfDescribing return 1; } - protected function exporter(): Exporter + /** + * @deprecated + */ + protected function exporter(): \SebastianBergmann\Exporter\Exporter { - if ($this->exporter === null) { - $this->exporter = new Exporter; - } - - return $this->exporter; + return new \SebastianBergmann\Exporter\Exporter; } /** @@ -76,8 +75,6 @@ abstract class Constraint implements Countable, SelfDescribing * constraint is met, false otherwise. * * This method can be overridden to implement the evaluation algorithm. - * - * @codeCoverageIgnore */ protected function matches(mixed $other): bool { @@ -93,7 +90,7 @@ abstract class Constraint implements Countable, SelfDescribing { $failureDescription = sprintf( 'Failed asserting that %s.', - $this->failureDescription($other) + $this->failureDescription($other), ); $additionalFailureDescription = $this->additionalFailureDescription($other); @@ -108,7 +105,7 @@ abstract class Constraint implements Countable, SelfDescribing throw new ExpectationFailedException( $failureDescription, - $comparisonFailure + $comparisonFailure, ); } @@ -134,7 +131,7 @@ abstract class Constraint implements Countable, SelfDescribing */ protected function failureDescription(mixed $other): string { - return $this->exporter()->export($other) . ' ' . $this->toString(); + return Exporter::export($other, true) . ' ' . $this->toString(true); } /** @@ -174,7 +171,7 @@ abstract class Constraint implements Countable, SelfDescribing return ''; } - return $this->exporter()->export($other) . ' ' . $string; + return Exporter::export($other, true) . ' ' . $string; } /** @@ -241,4 +238,27 @@ abstract class Constraint implements Countable, SelfDescribing { return $this; } + + /** + * @psalm-return non-empty-string + */ + protected function valueToTypeStringFragment(mixed $value): string + { + $type = strtolower(gettype($value)); + + if ($type === 'double') { + $type = 'float'; + } + + if ($type === 'resource (closed)') { + $type = 'closed resource'; + } + + return match ($type) { + 'array', 'integer', 'object' => 'an ' . $type . ' ', + 'boolean', 'closed resource', 'float', 'resource', 'string' => 'a ' . $type . ' ', + 'null' => 'null ', + default => 'a value of ' . $type . ' ', + }; + } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqual.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqual.php index 217a9074..2238475d 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqual.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqual.php @@ -14,6 +14,7 @@ use function sprintf; use function str_contains; use function trim; use PHPUnit\Framework\ExpectationFailedException; +use PHPUnit\Util\Exporter; use SebastianBergmann\Comparator\ComparisonFailure; use SebastianBergmann\Comparator\Factory as ComparatorFactory; @@ -61,7 +62,7 @@ final class IsEqual extends Constraint try { $comparator = $comparatorFactory->getComparatorFor( $this->value, - $other + $other, ); $comparator->assertEquals( @@ -69,7 +70,7 @@ final class IsEqual extends Constraint $other, $this->delta, $this->canonicalize, - $this->ignoreCase + $this->ignoreCase, ); } catch (ComparisonFailure $f) { if ($returnResult) { @@ -78,7 +79,7 @@ final class IsEqual extends Constraint throw new ExpectationFailedException( trim($description . "\n" . $f->getMessage()), - $f + $f, ); } @@ -88,7 +89,7 @@ final class IsEqual extends Constraint /** * Returns a string representation of the constraint. */ - public function toString(): string + public function toString(bool $exportObjects = false): string { $delta = ''; @@ -99,21 +100,21 @@ final class IsEqual extends Constraint return sprintf( "is equal to '%s'", - $this->value + $this->value, ); } if ($this->delta != 0) { $delta = sprintf( ' with delta <%F>', - $this->delta + $this->delta, ); } return sprintf( 'is equal to %s%s', - $this->exporter()->export($this->value), - $delta + Exporter::export($this->value, $exportObjects), + $delta, ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualCanonicalizing.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualCanonicalizing.php index 5d5eab5c..109438ec 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualCanonicalizing.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualCanonicalizing.php @@ -14,6 +14,7 @@ use function sprintf; use function str_contains; use function trim; use PHPUnit\Framework\ExpectationFailedException; +use PHPUnit\Util\Exporter; use SebastianBergmann\Comparator\ComparisonFailure; use SebastianBergmann\Comparator\Factory as ComparatorFactory; @@ -55,7 +56,7 @@ final class IsEqualCanonicalizing extends Constraint try { $comparator = $comparatorFactory->getComparatorFor( $this->value, - $other + $other, ); $comparator->assertEquals( @@ -63,7 +64,7 @@ final class IsEqualCanonicalizing extends Constraint $other, 0.0, true, - false + false, ); } catch (ComparisonFailure $f) { if ($returnResult) { @@ -72,7 +73,7 @@ final class IsEqualCanonicalizing extends Constraint throw new ExpectationFailedException( trim($description . "\n" . $f->getMessage()), - $f + $f, ); } @@ -82,7 +83,7 @@ final class IsEqualCanonicalizing extends Constraint /** * Returns a string representation of the constraint. */ - public function toString(): string + public function toString(bool $exportObjects = false): string { if (is_string($this->value)) { if (str_contains($this->value, "\n")) { @@ -91,13 +92,13 @@ final class IsEqualCanonicalizing extends Constraint return sprintf( "is equal to '%s'", - $this->value + $this->value, ); } return sprintf( 'is equal to %s', - $this->exporter()->export($this->value) + Exporter::export($this->value, $exportObjects), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualIgnoringCase.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualIgnoringCase.php index d6fc31c1..f5b9b99d 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualIgnoringCase.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualIgnoringCase.php @@ -14,6 +14,7 @@ use function sprintf; use function str_contains; use function trim; use PHPUnit\Framework\ExpectationFailedException; +use PHPUnit\Util\Exporter; use SebastianBergmann\Comparator\ComparisonFailure; use SebastianBergmann\Comparator\Factory as ComparatorFactory; @@ -55,7 +56,7 @@ final class IsEqualIgnoringCase extends Constraint try { $comparator = $comparatorFactory->getComparatorFor( $this->value, - $other + $other, ); $comparator->assertEquals( @@ -63,7 +64,7 @@ final class IsEqualIgnoringCase extends Constraint $other, 0.0, false, - true + true, ); } catch (ComparisonFailure $f) { if ($returnResult) { @@ -72,7 +73,7 @@ final class IsEqualIgnoringCase extends Constraint throw new ExpectationFailedException( trim($description . "\n" . $f->getMessage()), - $f + $f, ); } @@ -82,7 +83,7 @@ final class IsEqualIgnoringCase extends Constraint /** * Returns a string representation of the constraint. */ - public function toString(): string + public function toString(bool $exportObjects = false): string { if (is_string($this->value)) { if (str_contains($this->value, "\n")) { @@ -91,13 +92,13 @@ final class IsEqualIgnoringCase extends Constraint return sprintf( "is equal to '%s'", - $this->value + $this->value, ); } return sprintf( 'is equal to %s', - $this->exporter()->export($this->value) + Exporter::export($this->value, $exportObjects), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualWithDelta.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualWithDelta.php index 2806c3b7..d587f6f7 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualWithDelta.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Equality/IsEqualWithDelta.php @@ -12,6 +12,7 @@ namespace PHPUnit\Framework\Constraint; use function sprintf; use function trim; use PHPUnit\Framework\ExpectationFailedException; +use PHPUnit\Util\Exporter; use SebastianBergmann\Comparator\ComparisonFailure; use SebastianBergmann\Comparator\Factory as ComparatorFactory; @@ -55,13 +56,13 @@ final class IsEqualWithDelta extends Constraint try { $comparator = $comparatorFactory->getComparatorFor( $this->value, - $other + $other, ); $comparator->assertEquals( $this->value, $other, - $this->delta + $this->delta, ); } catch (ComparisonFailure $f) { if ($returnResult) { @@ -70,7 +71,7 @@ final class IsEqualWithDelta extends Constraint throw new ExpectationFailedException( trim($description . "\n" . $f->getMessage()), - $f + $f, ); } @@ -80,12 +81,12 @@ final class IsEqualWithDelta extends Constraint /** * Returns a string representation of the constraint. */ - public function toString(): string + public function toString(bool $exportObjects = false): string { return sprintf( - 'is equal to %s with delta <%F>>', - $this->exporter()->export($this->value), - $this->delta + 'is equal to %s with delta <%F>', + Exporter::export($this->value, $exportObjects), + $this->delta, ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Exception/Exception.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Exception/Exception.php index 7152f8a2..14905e77 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Exception/Exception.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Exception/Exception.php @@ -14,7 +14,7 @@ use PHPUnit\Util\Filter; use Throwable; /** - * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * @internal This class is not covered by the backward compatibility promise for PHPUnit */ final class Exception extends Constraint { @@ -32,7 +32,7 @@ final class Exception extends Constraint { return sprintf( 'exception of type "%s"', - $this->className + $this->className, ); } @@ -55,25 +55,25 @@ final class Exception extends Constraint */ protected function failureDescription(mixed $other): string { - if ($other !== null) { - $message = ''; - - if ($other instanceof Throwable) { - $message = '. Message was: "' . $other->getMessage() . '" at' - . "\n" . Filter::getFilteredStacktrace($other); - } - + if ($other === null) { return sprintf( - 'exception of type "%s" matches expected exception "%s"%s', - $other::class, + 'exception of type "%s" is thrown', $this->className, - $message ); } + $message = ''; + + if ($other instanceof Throwable) { + $message = '. Message was: "' . $other->getMessage() . '" at' + . "\n" . Filter::getFilteredStacktrace($other); + } + return sprintf( - 'exception of type "%s" is thrown', - $this->className + 'exception of type "%s" matches expected exception "%s"%s', + $other::class, + $this->className, + $message, ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionCode.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionCode.php index f10bdb6e..255aff33 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionCode.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionCode.php @@ -10,9 +10,10 @@ namespace PHPUnit\Framework\Constraint; use function sprintf; +use PHPUnit\Util\Exporter; /** - * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * @internal This class is not covered by the backward compatibility promise for PHPUnit */ final class ExceptionCode extends Constraint { @@ -25,7 +26,7 @@ final class ExceptionCode extends Constraint public function toString(): string { - return 'exception code is '; + return 'exception code is ' . $this->expectedCode; } /** @@ -34,7 +35,7 @@ final class ExceptionCode extends Constraint */ protected function matches(mixed $other): bool { - return (string) $other->getCode() === (string) $this->expectedCode; + return (string) $other === (string) $this->expectedCode; } /** @@ -47,8 +48,8 @@ final class ExceptionCode extends Constraint { return sprintf( '%s is equal to expected exception code %s', - $this->exporter()->export($other->getCode()), - $this->exporter()->export($this->expectedCode) + Exporter::export($other, true), + Exporter::export($this->expectedCode, true), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Message/MessageIsOrContains.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionMessageIsOrContains.php similarity index 65% rename from vendor/phpunit/phpunit/src/Framework/Constraint/Message/MessageIsOrContains.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionMessageIsOrContains.php index 7df19a51..56ab6f0d 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Message/MessageIsOrContains.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionMessageIsOrContains.php @@ -11,28 +11,27 @@ namespace PHPUnit\Framework\Constraint; use function sprintf; use function str_contains; +use PHPUnit\Util\Exporter; /** - * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * @internal This class is not covered by the backward compatibility promise for PHPUnit */ -final class MessageIsOrContains extends Constraint +final class ExceptionMessageIsOrContains extends Constraint { - private readonly string $messageType; private readonly string $expectedMessage; - public function __construct(string $messageType, string $expectedMessage) + public function __construct(string $expectedMessage) { - $this->messageType = $messageType; $this->expectedMessage = $expectedMessage; } public function toString(): string { if ($this->expectedMessage === '') { - return $this->messageType . ' message is empty'; + return 'exception message is empty'; } - return $this->messageType . ' message contains '; + return 'exception message contains ' . Exporter::export($this->expectedMessage); } protected function matches(mixed $other): bool @@ -54,17 +53,15 @@ final class MessageIsOrContains extends Constraint { if ($this->expectedMessage === '') { return sprintf( - "%s message is empty but is '%s'", - $this->messageType, - $other + "exception message is empty but is '%s'", + $other, ); } return sprintf( - "%s message '%s' contains '%s'", - $this->messageType, + "exception message '%s' contains '%s'", $other, - $this->expectedMessage + $this->expectedMessage, ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Message/MessageMatchesRegularExpression.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionMessageMatchesRegularExpression.php similarity index 66% rename from vendor/phpunit/phpunit/src/Framework/Constraint/Message/MessageMatchesRegularExpression.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionMessageMatchesRegularExpression.php index 6ed1ea03..dfb477d0 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Message/MessageMatchesRegularExpression.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Exception/ExceptionMessageMatchesRegularExpression.php @@ -12,24 +12,23 @@ namespace PHPUnit\Framework\Constraint; use function preg_match; use function sprintf; use Exception; +use PHPUnit\Util\Exporter; /** - * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + * @internal This class is not covered by the backward compatibility promise for PHPUnit */ -final class MessageMatchesRegularExpression extends Constraint +final class ExceptionMessageMatchesRegularExpression extends Constraint { - private readonly string $messageType; private readonly string $regularExpression; - public function __construct(string $messageType, string $regularExpression) + public function __construct(string $regularExpression) { - $this->messageType = $messageType; $this->regularExpression = $regularExpression; } public function toString(): string { - return $this->messageType . ' message matches '; + return 'exception message matches ' . Exporter::export($this->regularExpression); } /** @@ -46,10 +45,9 @@ final class MessageMatchesRegularExpression extends Constraint if ($match === false) { throw new \PHPUnit\Framework\Exception( sprintf( - 'Invalid expected %s message regular expression given: %s', - $this->messageType, - $this->regularExpression - ) + 'Invalid expected exception message regular expression given: %s', + $this->regularExpression, + ), ); } @@ -65,10 +63,9 @@ final class MessageMatchesRegularExpression extends Constraint protected function failureDescription(mixed $other): string { return sprintf( - "%s message '%s' matches '%s'", - $this->messageType, + "exception message '%s' matches '%s'", $other, - $this->regularExpression + $this->regularExpression, ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/DirectoryExists.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/DirectoryExists.php index f0da8f69..83b991e1 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/DirectoryExists.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/DirectoryExists.php @@ -44,7 +44,7 @@ final class DirectoryExists extends Constraint { return sprintf( 'directory "%s" exists', - $other + $other, ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/FileExists.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/FileExists.php index 24bdb42b..cfc3b1b6 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/FileExists.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/FileExists.php @@ -44,7 +44,7 @@ final class FileExists extends Constraint { return sprintf( 'file "%s" exists', - $other + $other, ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/IsReadable.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/IsReadable.php index d4ad4911..1a32546c 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/IsReadable.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/IsReadable.php @@ -44,7 +44,7 @@ final class IsReadable extends Constraint { return sprintf( '"%s" is readable', - $other + $other, ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/IsWritable.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/IsWritable.php index 64d5acc7..24e94f82 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/IsWritable.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Filesystem/IsWritable.php @@ -44,7 +44,7 @@ final class IsWritable extends Constraint { return sprintf( '"%s" is writable', - $other + $other, ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/IsIdentical.php b/vendor/phpunit/phpunit/src/Framework/Constraint/IsIdentical.php index 67e10e70..48be6317 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/IsIdentical.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/IsIdentical.php @@ -14,7 +14,9 @@ use function is_object; use function is_string; use function sprintf; use PHPUnit\Framework\ExpectationFailedException; +use PHPUnit\Util\Exporter; use SebastianBergmann\Comparator\ComparisonFailure; +use UnitEnum; /** * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit @@ -57,17 +59,17 @@ final class IsIdentical extends Constraint $this->value, $other, sprintf("'%s'", $this->value), - sprintf("'%s'", $other) + sprintf("'%s'", $other), ); } - // if both values are array, make sure a diff is generated - if (is_array($this->value) && is_array($other)) { + // if both values are array or enums, make sure a diff is generated + if ((is_array($this->value) && is_array($other)) || ($this->value instanceof UnitEnum && $other instanceof UnitEnum)) { $f = new ComparisonFailure( $this->value, $other, - $this->exporter()->export($this->value), - $this->exporter()->export($other) + Exporter::export($this->value, true), + Exporter::export($other, true), ); } @@ -80,14 +82,14 @@ final class IsIdentical extends Constraint /** * Returns a string representation of the constraint. */ - public function toString(): string + public function toString(bool $exportObjects = false): string { if (is_object($this->value)) { return 'is identical to an object of class "' . $this->value::class . '"'; } - return 'is identical to ' . $this->exporter()->export($this->value); + return 'is identical to ' . Exporter::export($this->value, $exportObjects); } /** diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/JsonMatches.php b/vendor/phpunit/phpunit/src/Framework/Constraint/JsonMatches.php index 23bce7e7..0000c8ef 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/JsonMatches.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/JsonMatches.php @@ -35,7 +35,7 @@ final class JsonMatches extends Constraint { return sprintf( 'matches JSON string "%s"', - $this->value + $this->value, ); } @@ -88,7 +88,7 @@ final class JsonMatches extends Constraint json_decode($other), Json::prettify($recodedValue), Json::prettify($recodedOther), - 'Failed asserting that two json values are equal.' + 'Failed asserting that two json values are equal.', ); } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/JsonMatchesErrorMessageProvider.php b/vendor/phpunit/phpunit/src/Framework/Constraint/JsonMatchesErrorMessageProvider.php deleted file mode 100644 index 711ebb18..00000000 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/JsonMatchesErrorMessageProvider.php +++ /dev/null @@ -1,52 +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 const JSON_ERROR_CTRL_CHAR; -use const JSON_ERROR_DEPTH; -use const JSON_ERROR_NONE; -use const JSON_ERROR_STATE_MISMATCH; -use const JSON_ERROR_SYNTAX; -use const JSON_ERROR_UTF8; -use function strtolower; - -/** - * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit - */ -final class JsonMatchesErrorMessageProvider -{ - /** - * Translates JSON error to a human readable string. - */ - public static function determineJsonError(int $error, string $prefix = ''): ?string - { - return match ($error) { - JSON_ERROR_NONE => null, - JSON_ERROR_DEPTH => $prefix . 'Maximum stack depth exceeded', - JSON_ERROR_STATE_MISMATCH => $prefix . 'Underflow or the modes mismatch', - JSON_ERROR_CTRL_CHAR => $prefix . 'Unexpected control character found', - JSON_ERROR_SYNTAX => $prefix . 'Syntax error, malformed JSON', - JSON_ERROR_UTF8 => $prefix . 'Malformed UTF-8 characters, possibly incorrectly encoded', - default => $prefix . 'Unknown error', - }; - } - - /** - * Translates a given type to a human readable message prefix. - */ - public static function translateTypeToPrefix(string $type): string - { - return match (strtolower($type)) { - 'expected' => 'Expected value JSON decode error - ', - 'actual' => 'Actual value JSON decode error - ', - default => '', - }; - } -} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/ObjectEquals.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Object/ObjectEquals.php similarity index 92% rename from vendor/phpunit/phpunit/src/Framework/Constraint/ObjectEquals.php rename to vendor/phpunit/phpunit/src/Framework/Constraint/Object/ObjectEquals.php index 70ace344..b513545f 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/ObjectEquals.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Object/ObjectEquals.php @@ -57,7 +57,7 @@ final class ObjectEquals extends Constraint if (!$object->hasMethod($this->method)) { throw new ComparisonMethodDoesNotExistException( $other::class, - $this->method + $this->method, ); } @@ -66,7 +66,7 @@ final class ObjectEquals extends Constraint if (!$method->hasReturnType()) { throw new ComparisonMethodDoesNotDeclareBoolReturnTypeException( $other::class, - $this->method + $this->method, ); } @@ -75,28 +75,28 @@ final class ObjectEquals extends Constraint if (!$returnType instanceof ReflectionNamedType) { throw new ComparisonMethodDoesNotDeclareBoolReturnTypeException( $other::class, - $this->method + $this->method, ); } if ($returnType->allowsNull()) { throw new ComparisonMethodDoesNotDeclareBoolReturnTypeException( $other::class, - $this->method + $this->method, ); } if ($returnType->getName() !== 'bool') { throw new ComparisonMethodDoesNotDeclareBoolReturnTypeException( $other::class, - $this->method + $this->method, ); } if ($method->getNumberOfParameters() !== 1 || $method->getNumberOfRequiredParameters() !== 1) { throw new ComparisonMethodDoesNotDeclareExactlyOneParameterException( $other::class, - $this->method + $this->method, ); } @@ -105,7 +105,7 @@ final class ObjectEquals extends Constraint if (!$parameter->hasType()) { throw new ComparisonMethodDoesNotDeclareParameterTypeException( $other::class, - $this->method + $this->method, ); } @@ -114,7 +114,7 @@ final class ObjectEquals extends Constraint if (!$type instanceof ReflectionNamedType) { throw new ComparisonMethodDoesNotDeclareParameterTypeException( $other::class, - $this->method + $this->method, ); } @@ -128,7 +128,7 @@ final class ObjectEquals extends Constraint throw new ComparisonMethodDoesNotAcceptParameterTypeException( $other::class, $this->method, - $this->expected::class + $this->expected::class, ); } @@ -137,6 +137,6 @@ final class ObjectEquals extends Constraint protected function failureDescription(mixed $other): string { - return $this->toString(); + return $this->toString(true); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Object/ObjectHasProperty.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Object/ObjectHasProperty.php new file mode 100644 index 00000000..6c8bc415 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Object/ObjectHasProperty.php @@ -0,0 +1,80 @@ + + * + * 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 gettype; +use function is_object; +use function sprintf; +use ReflectionObject; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class ObjectHasProperty extends Constraint +{ + private readonly string $propertyName; + + public function __construct(string $propertyName) + { + $this->propertyName = $propertyName; + } + + /** + * Returns a string representation of the constraint. + */ + public function toString(): string + { + return sprintf( + 'has property "%s"', + $this->propertyName, + ); + } + + /** + * 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(mixed $other): bool + { + if (!is_object($other)) { + return false; + } + + return (new ReflectionObject($other))->hasProperty($this->propertyName); + } + + /** + * 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(mixed $other): string + { + if (is_object($other)) { + return sprintf( + 'object of class "%s" %s', + $other::class, + $this->toString(true), + ); + } + + return sprintf( + '"%s" (%s) %s', + $other, + gettype($other), + $this->toString(true), + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/BinaryOperator.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/BinaryOperator.php index dec2effd..4c3d8e4b 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/BinaryOperator.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/BinaryOperator.php @@ -26,7 +26,7 @@ abstract class BinaryOperator extends Operator { $this->constraints = array_map( fn ($constraint): Constraint => $this->checkConstraint($constraint), - $constraints + $constraints, ); } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalNot.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalNot.php index f79f140c..021afddd 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalNot.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalNot.php @@ -53,7 +53,7 @@ final class LogicalNot extends UnaryOperator $positives = array_map( static fn (string $s) => '/\\b' . preg_quote($s, '/') . '/', - $positives + $positives, ); if (count($matches) > 0) { @@ -64,15 +64,15 @@ final class LogicalNot extends UnaryOperator preg_replace( $positives, $negatives, - $nonInput + $nonInput, ), - $string + $string, ); } else { $negatedString = preg_replace( $positives, $negatives, - $string + $string, ); } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalXor.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalXor.php index f5b2b7df..e8ffc34d 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalXor.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Operator/LogicalXor.php @@ -60,7 +60,7 @@ final class LogicalXor extends BinaryOperator return array_reduce( $constraints, static fn (bool $matches, Constraint $constraint): bool => $matches xor $constraint->evaluate($other, '', true), - $initial->evaluate($other, '', true) + $initial->evaluate($other, '', true), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/String/IsJson.php b/vendor/phpunit/phpunit/src/Framework/Constraint/String/IsJson.php index 86b7a045..fdd663cd 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/String/IsJson.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/String/IsJson.php @@ -9,6 +9,7 @@ */ namespace PHPUnit\Framework\Constraint; +use function is_string; use function json_decode; use function json_last_error; use function sprintf; @@ -32,7 +33,7 @@ final class IsJson extends Constraint */ protected function matches(mixed $other): bool { - if ($other === '') { + if (!is_string($other) || $other === '') { return false; } @@ -53,20 +54,32 @@ final class IsJson extends Constraint */ protected function failureDescription(mixed $other): string { + if (!is_string($other)) { + return $this->valueToTypeStringFragment($other) . 'is valid JSON'; + } + if ($other === '') { return 'an empty string is valid JSON'; } - json_decode($other); - - $error = (string) JsonMatchesErrorMessageProvider::determineJsonError( - json_last_error() - ); - return sprintf( - '%s is valid JSON (%s)', - $this->exporter()->shortenedExport($other), - $error + 'a string is valid JSON (%s)', + $this->determineJsonError($other), ); } + + private function determineJsonError(string $json): string + { + json_decode($json); + + return match (json_last_error()) { + JSON_ERROR_NONE => '', + JSON_ERROR_DEPTH => 'Maximum stack depth exceeded', + JSON_ERROR_STATE_MISMATCH => 'Underflow or the modes mismatch', + JSON_ERROR_CTRL_CHAR => 'Unexpected control character found', + JSON_ERROR_SYNTAX => 'Syntax error, malformed JSON', + JSON_ERROR_UTF8 => 'Malformed UTF-8 characters, possibly incorrectly encoded', + default => 'Unknown error', + }; + } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/String/RegularExpression.php b/vendor/phpunit/phpunit/src/Framework/Constraint/String/RegularExpression.php index b550aaf4..03b0e4ea 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/String/RegularExpression.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/String/RegularExpression.php @@ -31,7 +31,7 @@ final class RegularExpression extends Constraint { return sprintf( 'matches PCRE pattern "%s"', - $this->pattern + $this->pattern, ); } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/String/StringContains.php b/vendor/phpunit/phpunit/src/Framework/Constraint/String/StringContains.php index be00ad06..7ba71587 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/String/StringContains.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/String/StringContains.php @@ -10,24 +10,31 @@ namespace PHPUnit\Framework\Constraint; use function is_string; +use function mb_detect_encoding; use function mb_stripos; use function mb_strtolower; use function sprintf; use function str_contains; +use function strlen; use function strtr; +use PHPUnit\Util\Exporter; /** * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class StringContains extends Constraint { - private readonly string $string; + private readonly string $needle; private readonly bool $ignoreCase; private readonly bool $ignoreLineEndings; - public function __construct(string $string, bool $ignoreCase = false, bool $ignoreLineEndings = false) + public function __construct(string $needle, bool $ignoreCase = false, bool $ignoreLineEndings = false) { - $this->string = $string; + if ($ignoreLineEndings) { + $needle = $this->normalizeLineEndings($needle); + } + + $this->needle = $needle; $this->ignoreCase = $ignoreCase; $this->ignoreLineEndings = $ignoreLineEndings; } @@ -37,57 +44,107 @@ final class StringContains extends Constraint */ public function toString(): string { - $string = $this->string; + $needle = $this->needle; if ($this->ignoreCase) { - $string = mb_strtolower($this->string, 'UTF-8'); - } - - if ($this->ignoreLineEndings) { - $string = $this->normalizeLineEndings($string); + $needle = mb_strtolower($this->needle, 'UTF-8'); } return sprintf( - 'contains "%s"', - $string + 'contains "%s" [%s](length: %s)', + $needle, + $this->getDetectedEncoding($needle), + strlen($needle), ); } + public function failureDescription(mixed $other): string + { + $stringifiedHaystack = Exporter::export($other, true); + $haystackEncoding = $this->getDetectedEncoding($other); + $haystackLength = $this->getHaystackLength($other); + + $haystackInformation = sprintf( + '%s [%s](length: %s) ', + $stringifiedHaystack, + $haystackEncoding, + $haystackLength, + ); + + $needleInformation = $this->toString(true); + + return $haystackInformation . $needleInformation; + } + /** * Evaluates the constraint for parameter $other. Returns true if the * constraint is met, false otherwise. */ protected function matches(mixed $other): bool { - if ('' === $this->string) { + $haystack = $other; + + if ('' === $this->needle) { return true; } - if (!is_string($other)) { + if (!is_string($haystack)) { return false; } if ($this->ignoreLineEndings) { - $other = $this->normalizeLineEndings($other); + $haystack = $this->normalizeLineEndings($haystack); } if ($this->ignoreCase) { /* - * We must use the multi byte safe version so we can accurately compare non latin upper characters with + * We must use the multibyte-safe version, so we can accurately compare non-latin uppercase characters with * their lowercase equivalents. */ - return mb_stripos($other, $this->string, 0, 'UTF-8') !== false; + return mb_stripos($haystack, $this->needle, 0, 'UTF-8') !== false; } /* - * Use the non multi byte safe functions to see if the string is contained in $other. + * Use the non-multibyte 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. + * 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 + * Additionally, we want this method to be binary safe, so we can check if some binary data is in other binary * data. */ - return str_contains($other, $this->string); + return str_contains($haystack, $this->needle); + } + + private function getDetectedEncoding(mixed $other): string + { + if ($this->ignoreCase) { + return 'Encoding ignored'; + } + + if (!is_string($other)) { + return 'Encoding detection failed'; + } + + $detectedEncoding = mb_detect_encoding($other, null, true); + + if (!$detectedEncoding) { + return 'Encoding detection failed'; + } + + return $detectedEncoding; + } + + private function getHaystackLength(mixed $haystack): int + { + if (!is_string($haystack)) { + return 0; + } + + if ($this->ignoreLineEndings) { + $haystack = $this->normalizeLineEndings($haystack); + } + + return strlen($haystack); } private function normalizeLineEndings(string $string): string @@ -97,7 +154,7 @@ final class StringContains extends Constraint [ "\r\n" => "\n", "\r" => "\n", - ] + ], ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/String/StringEqualsStringIgnoringLineEndings.php b/vendor/phpunit/phpunit/src/Framework/Constraint/String/StringEqualsStringIgnoringLineEndings.php index 82b150f3..56c59943 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/String/StringEqualsStringIgnoringLineEndings.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/String/StringEqualsStringIgnoringLineEndings.php @@ -31,7 +31,7 @@ final class StringEqualsStringIgnoringLineEndings extends Constraint { return sprintf( 'is equal to "%s" ignoring line endings', - $this->string + $this->string, ); } @@ -51,7 +51,7 @@ final class StringEqualsStringIgnoringLineEndings extends Constraint [ "\r\n" => "\n", "\r" => "\n", - ] + ], ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/String/StringMatchesFormatDescription.php b/vendor/phpunit/phpunit/src/Framework/Constraint/String/StringMatchesFormatDescription.php index 87021316..8e5072db 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/String/StringMatchesFormatDescription.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/String/StringMatchesFormatDescription.php @@ -15,7 +15,6 @@ use function implode; use function preg_match; use function preg_quote; use function preg_replace; -use function sprintf; use function strtr; use SebastianBergmann\Diff\Differ; use SebastianBergmann\Diff\Output\UnifiedDiffOutputBuilder; @@ -25,27 +24,16 @@ use SebastianBergmann\Diff\Output\UnifiedDiffOutputBuilder; */ final class StringMatchesFormatDescription extends Constraint { - private string $formatDescription; - private readonly string $regularExpression; + private readonly string $formatDescription; public function __construct(string $formatDescription) { - $this->regularExpression = $this->createRegularExpressionFromFormatDescription( - $this->convertNewlines($formatDescription) - ); - $this->formatDescription = $formatDescription; } - /** - * @todo Use format description instead of regular expression - */ public function toString(): string { - return sprintf( - 'matches PCRE pattern "%s"', - $this->regularExpression - ); + return 'matches format description:' . PHP_EOL . $this->formatDescription; } /** @@ -56,7 +44,14 @@ final class StringMatchesFormatDescription extends Constraint { $other = $this->convertNewlines($other); - return preg_match($this->regularExpression, $other) > 0; + $matches = preg_match( + $this->regularExpressionForFormatDescription( + $this->convertNewlines($this->formatDescription), + ), + $other, + ); + + return $matches > 0; } protected function failureDescription(mixed $other): string @@ -71,7 +66,7 @@ final class StringMatchesFormatDescription extends Constraint foreach ($from as $index => $line) { if (isset($to[$index]) && $line !== $to[$index]) { - $line = $this->createRegularExpressionFromFormatDescription($line); + $line = $this->regularExpressionForFormatDescription($line); if (preg_match($line, $to[$index]) > 0) { $from[$index] = $to[$index]; @@ -79,13 +74,13 @@ final class StringMatchesFormatDescription extends Constraint } } - $this->formatDescription = implode("\n", $from); - $other = implode("\n", $to); + $from = implode("\n", $from); + $to = implode("\n", $to); - return (new Differ(new UnifiedDiffOutputBuilder("--- Expected\n+++ Actual\n")))->diff($this->formatDescription, $other); + return $this->differ()->diff($from, $to); } - private function createRegularExpressionFromFormatDescription(string $string): string + private function regularExpressionForFormatDescription(string $string): string { $string = strtr( preg_quote($string, '/'), @@ -102,7 +97,7 @@ final class StringMatchesFormatDescription extends Constraint '%x' => '[0-9a-fA-F]+', '%f' => '[+-]?\.?\d+\.?\d*(?:[Ee][+-]?\d+)?', '%c' => '.', - ] + ], ); return '/^' . $string . '$/s'; @@ -112,4 +107,9 @@ final class StringMatchesFormatDescription extends Constraint { return preg_replace('/\r\n/', "\n", $text); } + + private function differ(): Differ + { + return new Differ(new UnifiedDiffOutputBuilder("--- Expected\n+++ Actual\n")); + } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/ArrayHasKey.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/ArrayHasKey.php index fff8597e..07bfa4fd 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/ArrayHasKey.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/ArrayHasKey.php @@ -12,6 +12,7 @@ namespace PHPUnit\Framework\Constraint; use function array_key_exists; use function is_array; use ArrayAccess; +use PHPUnit\Util\Exporter; /** * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit @@ -30,7 +31,7 @@ final class ArrayHasKey extends Constraint */ public function toString(): string { - return 'has the key ' . $this->exporter()->export($this->key); + return 'has the key ' . Exporter::export($this->key); } /** @@ -58,6 +59,6 @@ final class ArrayHasKey extends Constraint */ protected function failureDescription(mixed $other): string { - return 'an array ' . $this->toString(); + return 'an array ' . $this->toString(true); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/IsList.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/IsList.php index a34be7d9..2e2f60cb 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/IsList.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/IsList.php @@ -22,7 +22,7 @@ final class IsList extends Constraint */ public function toString(): string { - return 'is list'; + return 'is a list'; } /** @@ -46,6 +46,6 @@ final class IsList extends Constraint */ protected function failureDescription(mixed $other): string { - return 'an array ' . $this->toString(); + return $this->valueToTypeStringFragment($other) . $this->toString(true); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContains.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContains.php index 32ddc342..770bdb8a 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContains.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContains.php @@ -11,6 +11,7 @@ namespace PHPUnit\Framework\Constraint; use function is_array; use function sprintf; +use PHPUnit\Util\Exporter; /** * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit @@ -27,9 +28,9 @@ abstract class TraversableContains extends Constraint /** * Returns a string representation of the constraint. */ - public function toString(): string + public function toString(bool $exportObjects = false): string { - return 'contains ' . $this->exporter()->export($this->value); + return 'contains ' . Exporter::export($this->value, $exportObjects); } /** @@ -43,7 +44,7 @@ abstract class TraversableContains extends Constraint return sprintf( '%s %s', is_array($other) ? 'an array' : 'a traversable', - $this->toString() + $this->toString(true), ); } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContainsOnly.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContainsOnly.php index 54c4947a..72e3ccc0 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContainsOnly.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Traversable/TraversableContainsOnly.php @@ -45,7 +45,7 @@ final class TraversableContainsOnly extends Constraint * * @throws ExpectationFailedException */ - public function evaluate(mixed $other, string $description = '', bool $returnResult = false): ?bool + public function evaluate(mixed $other, string $description = '', bool $returnResult = false): bool { $success = true; @@ -57,15 +57,11 @@ final class TraversableContainsOnly extends Constraint } } - if ($returnResult) { - return $success; - } - - if (!$success) { + if (!$success && !$returnResult) { $this->fail($other, $description); } - return null; + return $success; } /** diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Type/IsInstanceOf.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Type/IsInstanceOf.php index ed45ce99..e69f4f86 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Type/IsInstanceOf.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Type/IsInstanceOf.php @@ -9,20 +9,40 @@ */ namespace PHPUnit\Framework\Constraint; +use function class_exists; +use function interface_exists; use function sprintf; -use ReflectionClass; -use ReflectionException; +use PHPUnit\Framework\UnknownClassOrInterfaceException; /** * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ final class IsInstanceOf extends Constraint { - private readonly string $className; + /** + * @psalm-var class-string + */ + private readonly string $name; - public function __construct(string $className) + /** + * @psalm-var 'class'|'interface' + */ + private readonly string $type; + + /** + * @throws UnknownClassOrInterfaceException + */ + public function __construct(string $name) { - $this->className = $className; + if (class_exists($name)) { + $this->type = 'class'; + } elseif (interface_exists($name)) { + $this->type = 'interface'; + } else { + throw new UnknownClassOrInterfaceException($name); + } + + $this->name = $name; } /** @@ -31,9 +51,9 @@ final class IsInstanceOf extends Constraint public function toString(): string { return sprintf( - 'is instance of %s "%s"', - $this->getType(), - $this->className + 'is an instance of %s %s', + $this->type, + $this->name, ); } @@ -43,7 +63,7 @@ final class IsInstanceOf extends Constraint */ protected function matches(mixed $other): bool { - return $other instanceof $this->className; + return $other instanceof $this->name; } /** @@ -54,25 +74,6 @@ final class IsInstanceOf extends Constraint */ protected function failureDescription(mixed $other): string { - return sprintf( - '%s is an instance of %s "%s"', - $this->exporter()->shortenedExport($other), - $this->getType(), - $this->className - ); - } - - private function getType(): string - { - try { - $reflection = new ReflectionClass($this->className); - - if ($reflection->isInterface()) { - return 'interface'; - } - } catch (ReflectionException) { - } - - return 'class'; + return $this->valueToTypeStringFragment($other) . $this->toString(true); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Constraint/Type/IsType.php b/vendor/phpunit/phpunit/src/Framework/Constraint/Type/IsType.php index 82c6b344..84c422f8 100644 --- a/vendor/phpunit/phpunit/src/Framework/Constraint/Type/IsType.php +++ b/vendor/phpunit/phpunit/src/Framework/Constraint/Type/IsType.php @@ -21,6 +21,7 @@ use function is_object; use function is_scalar; use function is_string; use function sprintf; +use PHPUnit\Framework\UnknownTypeException; /** * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit @@ -114,21 +115,21 @@ final class IsType extends Constraint 'callable' => true, 'iterable' => true, ]; + + /** + * @psalm-var 'array'|'boolean'|'bool'|'double'|'float'|'integer'|'int'|'null'|'numeric'|'object'|'real'|'resource'|'resource (closed)'|'string'|'scalar'|'callable'|'iterable' + */ private readonly string $type; /** - * @throws \PHPUnit\Framework\Exception + * @psalm-param 'array'|'boolean'|'bool'|'double'|'float'|'integer'|'int'|'null'|'numeric'|'object'|'real'|'resource'|'resource (closed)'|'string'|'scalar'|'callable'|'iterable' $type + * + * @throws UnknownTypeException */ public function __construct(string $type) { if (!isset(self::KNOWN_TYPES[$type])) { - throw new \PHPUnit\Framework\Exception( - sprintf( - 'Type specified for PHPUnit\Framework\Constraint\IsType <%s> ' . - 'is not a valid type.', - $type - ) - ); + throw new UnknownTypeException($type); } $this->type = $type; @@ -140,8 +141,8 @@ final class IsType extends Constraint public function toString(): string { return sprintf( - 'is of type "%s"', - $this->type + 'is of type %s', + $this->type, ); } diff --git a/vendor/phpunit/phpunit/src/Framework/DataProviderTestSuite.php b/vendor/phpunit/phpunit/src/Framework/DataProviderTestSuite.php index 0cbbee72..6975d1c6 100644 --- a/vendor/phpunit/phpunit/src/Framework/DataProviderTestSuite.php +++ b/vendor/phpunit/phpunit/src/Framework/DataProviderTestSuite.php @@ -33,10 +33,9 @@ final class DataProviderTestSuite extends TestSuite foreach ($this->tests() as $test) { if (!$test instanceof TestCase) { - // @codeCoverageIgnoreStart continue; - // @codeCoverageIgnoreStart } + $test->setDependencies($dependencies); } } @@ -47,7 +46,7 @@ final class DataProviderTestSuite extends TestSuite public function provides(): array { if ($this->providedTests === null) { - $this->providedTests = [new ExecutionOrderDependency($this->getName())]; + $this->providedTests = [new ExecutionOrderDependency($this->name())]; } return $this->providedTests; @@ -64,11 +63,11 @@ final class DataProviderTestSuite extends TestSuite } /** - * Returns the size of the each test created using the data provider(s). + * Returns the size of each test created using the data provider(s). */ public function size(): TestSize { - [$className, $methodName] = explode('::', $this->getName()); + [$className, $methodName] = explode('::', $this->name()); return (new Groups)->size($className, $methodName); } diff --git a/vendor/phpunit/phpunit/src/Framework/Exception/Exception.php b/vendor/phpunit/phpunit/src/Framework/Exception/Exception.php index 42be3e1b..01531f5e 100644 --- a/vendor/phpunit/phpunit/src/Framework/Exception/Exception.php +++ b/vendor/phpunit/phpunit/src/Framework/Exception/Exception.php @@ -11,10 +11,7 @@ namespace PHPUnit\Framework; use function array_keys; use function get_object_vars; -use PHPUnit\Util\Filter; -use PHPUnit\Util\ThrowableToStringMapper; use RuntimeException; -use Stringable; use Throwable; /** @@ -39,7 +36,7 @@ use Throwable; * * @internal This class is not covered by the backward compatibility promise for PHPUnit */ -class Exception extends RuntimeException implements \PHPUnit\Exception, Stringable +class Exception extends RuntimeException implements \PHPUnit\Exception { protected array $serializableTrace; @@ -54,20 +51,6 @@ class Exception extends RuntimeException implements \PHPUnit\Exception, Stringab } } - /** - * @throws Exception - */ - public function __toString(): string - { - $string = ThrowableToStringMapper::map($this); - - if ($trace = Filter::getFilteredStacktrace($this)) { - $string .= "\n" . $trace; - } - - return $string; - } - public function __sleep(): array { return array_keys(get_object_vars($this)); diff --git a/vendor/phpunit/phpunit/src/Framework/Exception/GeneratorNotSupportedException.php b/vendor/phpunit/phpunit/src/Framework/Exception/GeneratorNotSupportedException.php index f2a156da..2a6ff542 100644 --- a/vendor/phpunit/phpunit/src/Framework/Exception/GeneratorNotSupportedException.php +++ b/vendor/phpunit/phpunit/src/Framework/Exception/GeneratorNotSupportedException.php @@ -9,15 +9,20 @@ */ namespace PHPUnit\Framework; +use function sprintf; + /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ final class GeneratorNotSupportedException extends InvalidArgumentException { - public function __construct() + public static function fromParameterName(string $parameterName): self { - parent::__construct( - 'Generator objects are not supported by assertCount() and the Count constraint' + return new self( + sprintf( + 'Passing an argument of type Generator for the %s parameter is not supported', + $parameterName, + ), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ActualValueIsNotAnObjectException.php b/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ActualValueIsNotAnObjectException.php index 910dfe4d..c2579df3 100644 --- a/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ActualValueIsNotAnObjectException.php +++ b/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ActualValueIsNotAnObjectException.php @@ -9,8 +9,6 @@ */ namespace PHPUnit\Framework; -use const PHP_EOL; - /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ @@ -19,12 +17,7 @@ final class ActualValueIsNotAnObjectException extends Exception public function __construct() { parent::__construct( - 'Actual value is not an object' + 'Actual value is not an object', ); } - - public function __toString(): string - { - return $this->getMessage() . PHP_EOL; - } } diff --git a/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotAcceptParameterTypeException.php b/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotAcceptParameterTypeException.php index dd7c3434..19f4a490 100644 --- a/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotAcceptParameterTypeException.php +++ b/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotAcceptParameterTypeException.php @@ -9,7 +9,6 @@ */ namespace PHPUnit\Framework; -use const PHP_EOL; use function sprintf; /** @@ -24,13 +23,8 @@ final class ComparisonMethodDoesNotAcceptParameterTypeException extends Exceptio '%s is not an accepted argument type for comparison method %s::%s().', $type, $className, - $methodName - ) + $methodName, + ), ); } - - public function __toString(): string - { - return $this->getMessage() . PHP_EOL; - } } diff --git a/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotDeclareBoolReturnTypeException.php b/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotDeclareBoolReturnTypeException.php index 17d6e7ee..87cd241d 100644 --- a/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotDeclareBoolReturnTypeException.php +++ b/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotDeclareBoolReturnTypeException.php @@ -9,7 +9,6 @@ */ namespace PHPUnit\Framework; -use const PHP_EOL; use function sprintf; /** @@ -23,13 +22,8 @@ final class ComparisonMethodDoesNotDeclareBoolReturnTypeException extends Except sprintf( 'Comparison method %s::%s() does not declare bool return type.', $className, - $methodName - ) + $methodName, + ), ); } - - public function __toString(): string - { - return $this->getMessage() . PHP_EOL; - } } diff --git a/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotDeclareExactlyOneParameterException.php b/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotDeclareExactlyOneParameterException.php index e95d2c91..b8d61933 100644 --- a/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotDeclareExactlyOneParameterException.php +++ b/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotDeclareExactlyOneParameterException.php @@ -9,14 +9,12 @@ */ namespace PHPUnit\Framework; -use const PHP_EOL; use function sprintf; -use Stringable; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ -final class ComparisonMethodDoesNotDeclareExactlyOneParameterException extends Exception implements Stringable +final class ComparisonMethodDoesNotDeclareExactlyOneParameterException extends Exception { public function __construct(string $className, string $methodName) { @@ -24,13 +22,8 @@ final class ComparisonMethodDoesNotDeclareExactlyOneParameterException extends E sprintf( 'Comparison method %s::%s() does not declare exactly one parameter.', $className, - $methodName - ) + $methodName, + ), ); } - - public function __toString(): string - { - return $this->getMessage() . PHP_EOL; - } } diff --git a/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotDeclareParameterTypeException.php b/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotDeclareParameterTypeException.php index 075e0524..937a3b69 100644 --- a/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotDeclareParameterTypeException.php +++ b/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotDeclareParameterTypeException.php @@ -9,14 +9,12 @@ */ namespace PHPUnit\Framework; -use const PHP_EOL; use function sprintf; -use Stringable; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ -final class ComparisonMethodDoesNotDeclareParameterTypeException extends Exception implements Stringable +final class ComparisonMethodDoesNotDeclareParameterTypeException extends Exception { public function __construct(string $className, string $methodName) { @@ -24,13 +22,8 @@ final class ComparisonMethodDoesNotDeclareParameterTypeException extends Excepti sprintf( 'Parameter of comparison method %s::%s() does not have a declared type.', $className, - $methodName - ) + $methodName, + ), ); } - - public function __toString(): string - { - return $this->getMessage() . PHP_EOL; - } } diff --git a/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotExistException.php b/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotExistException.php index eb765ad9..a482fb4f 100644 --- a/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotExistException.php +++ b/vendor/phpunit/phpunit/src/Framework/Exception/ObjectEquals/ComparisonMethodDoesNotExistException.php @@ -9,14 +9,12 @@ */ namespace PHPUnit\Framework; -use const PHP_EOL; use function sprintf; -use Stringable; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ -final class ComparisonMethodDoesNotExistException extends Exception implements Stringable +final class ComparisonMethodDoesNotExistException extends Exception { public function __construct(string $className, string $methodName) { @@ -24,13 +22,8 @@ final class ComparisonMethodDoesNotExistException extends Exception implements S sprintf( 'Comparison method %s::%s() does not exist.', $className, - $methodName - ) + $methodName, + ), ); } - - public function __toString(): string - { - return $this->getMessage() . PHP_EOL; - } } diff --git a/vendor/phpunit/phpunit/src/Framework/Exception/UnknownClassOrInterfaceException.php b/vendor/phpunit/phpunit/src/Framework/Exception/UnknownClassOrInterfaceException.php index 4de87809..c3cab6c6 100644 --- a/vendor/phpunit/phpunit/src/Framework/Exception/UnknownClassOrInterfaceException.php +++ b/vendor/phpunit/phpunit/src/Framework/Exception/UnknownClassOrInterfaceException.php @@ -21,8 +21,8 @@ final class UnknownClassOrInterfaceException extends InvalidArgumentException parent::__construct( sprintf( 'Class or interface "%s" does not exist', - $name - ) + $name, + ), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/Exception/UnknownClassException.php b/vendor/phpunit/phpunit/src/Framework/Exception/UnknownTypeException.php similarity index 78% rename from vendor/phpunit/phpunit/src/Framework/Exception/UnknownClassException.php rename to vendor/phpunit/phpunit/src/Framework/Exception/UnknownTypeException.php index 69ffe808..b5f9debf 100644 --- a/vendor/phpunit/phpunit/src/Framework/Exception/UnknownClassException.php +++ b/vendor/phpunit/phpunit/src/Framework/Exception/UnknownTypeException.php @@ -14,15 +14,15 @@ use function sprintf; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ -final class UnknownClassException extends InvalidArgumentException +final class UnknownTypeException extends InvalidArgumentException { public function __construct(string $name) { parent::__construct( sprintf( - 'Class "%s" does not exist', - $name - ) + 'Type "%s" is not known', + $name, + ), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/ExecutionOrderDependency.php b/vendor/phpunit/phpunit/src/Framework/ExecutionOrderDependency.php index 1f0a20f2..9d5419b3 100644 --- a/vendor/phpunit/phpunit/src/Framework/ExecutionOrderDependency.php +++ b/vendor/phpunit/phpunit/src/Framework/ExecutionOrderDependency.php @@ -35,7 +35,7 @@ final class ExecutionOrderDependency implements Stringable '', '', false, - false + false, ); } @@ -45,7 +45,7 @@ final class ExecutionOrderDependency implements Stringable $metadata->className(), 'class', $metadata->deepClone(), - $metadata->shallowClone() + $metadata->shallowClone(), ); } @@ -55,7 +55,7 @@ final class ExecutionOrderDependency implements Stringable $metadata->className(), $metadata->methodName(), $metadata->deepClone(), - $metadata->shallowClone() + $metadata->shallowClone(), ); } @@ -69,8 +69,8 @@ final class ExecutionOrderDependency implements Stringable return array_values( array_filter( $dependencies, - static fn (self $d) => $d->isValid() - ) + static fn (self $d) => $d->isValid(), + ), ); } @@ -84,7 +84,7 @@ final class ExecutionOrderDependency implements Stringable { $existingTargets = array_map( static fn ($dependency) => $dependency->getTarget(), - $existing + $existing, ); foreach ($additional as $dependency) { @@ -118,7 +118,7 @@ final class ExecutionOrderDependency implements Stringable $diff = []; $rightTargets = array_map( static fn ($dependency) => $dependency->getTarget(), - $right + $right, ); foreach ($left as $dependency) { diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/ConfigurableMethod.php b/vendor/phpunit/phpunit/src/Framework/MockObject/ConfigurableMethod.php index 9f96899b..d48d6fa1 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/ConfigurableMethod.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/ConfigurableMethod.php @@ -16,26 +16,61 @@ use SebastianBergmann\Type\Type; */ final class ConfigurableMethod { + /** + * @psalm-var non-empty-string + */ private readonly string $name; + + /** + * @psalm-var array + */ + private readonly array $defaultParameterValues; + + /** + * @psalm-var non-negative-int + */ + private readonly int $numberOfParameters; private readonly Type $returnType; - public function __construct(string $name, Type $returnType) + /** + * @psalm-param non-empty-string $name + * @psalm-param array $defaultParameterValues + * @psalm-param non-negative-int $numberOfParameters + */ + public function __construct(string $name, array $defaultParameterValues, int $numberOfParameters, Type $returnType) { - $this->name = $name; - $this->returnType = $returnType; + $this->name = $name; + $this->defaultParameterValues = $defaultParameterValues; + $this->numberOfParameters = $numberOfParameters; + $this->returnType = $returnType; } + /** + * @psalm-return non-empty-string + */ public function name(): string { return $this->name; } + /** + * @psalm-return array + */ + public function defaultParameterValues(): array + { + return $this->defaultParameterValues; + } + + /** + * @psalm-return non-negative-int + */ + public function numberOfParameters(): int + { + return $this->numberOfParameters; + } + public function mayReturn(mixed $value): bool { - if ($value === null && $this->returnType->allowsNull()) { - return true; - } - return $this->returnType->isAssignable(Type::fromValue($value, false)); } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/CannotUseAddMethodsException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/CannotUseAddMethodsException.php index 0698870b..848746b5 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/CannotUseAddMethodsException.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/CannotUseAddMethodsException.php @@ -22,8 +22,8 @@ final class CannotUseAddMethodsException extends \PHPUnit\Framework\Exception im sprintf( 'Trying to configure method "%s" with addMethods(), but it exists in class "%s". Use onlyMethods() for methods that exist in the class', $methodName, - $type - ) + $type, + ), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/CannotUseOnlyMethodsException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/CannotUseOnlyMethodsException.php index 35a29b73..61fe0cc5 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/CannotUseOnlyMethodsException.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/CannotUseOnlyMethodsException.php @@ -20,10 +20,10 @@ final class CannotUseOnlyMethodsException extends \PHPUnit\Framework\Exception i { parent::__construct( sprintf( - 'Trying to configure method "%s" with onlyMethods(), but it does not exist in class "%s". Use addMethods() for methods that do not exist in the class', + 'Trying to configure method "%s" with onlyMethods(), but it does not exist in class "%s"', $methodName, - $type - ) + $type, + ), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/IncompatibleReturnValueException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/IncompatibleReturnValueException.php index 803028df..6409204a 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/IncompatibleReturnValueException.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/IncompatibleReturnValueException.php @@ -24,8 +24,8 @@ final class IncompatibleReturnValueException extends \PHPUnit\Framework\Exceptio 'Method %s may not return value of type %s, its declared return type is "%s"', $method->name(), get_debug_type($value), - $method->returnTypeDeclaration() - ) + $method->returnTypeDeclaration(), + ), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MatchBuilderNotFoundException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MatchBuilderNotFoundException.php index c05b2bce..f2e1a31e 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MatchBuilderNotFoundException.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MatchBuilderNotFoundException.php @@ -21,8 +21,8 @@ final class MatchBuilderNotFoundException extends \PHPUnit\Framework\Exception i parent::__construct( sprintf( 'No builder found for match builder identification <%s>', - $id - ) + $id, + ), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MatcherAlreadyRegisteredException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MatcherAlreadyRegisteredException.php index efcc13ed..0972ffaf 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MatcherAlreadyRegisteredException.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MatcherAlreadyRegisteredException.php @@ -21,8 +21,8 @@ final class MatcherAlreadyRegisteredException extends \PHPUnit\Framework\Excepti parent::__construct( sprintf( 'Matcher with id <%s> is already registered', - $id - ) + $id, + ), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MethodCannotBeConfiguredException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MethodCannotBeConfiguredException.php index 70729043..2f0bb5a6 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MethodCannotBeConfiguredException.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/MethodCannotBeConfiguredException.php @@ -21,8 +21,8 @@ final class MethodCannotBeConfiguredException extends \PHPUnit\Framework\Excepti 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 - ) + $method, + ), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/NeverReturningMethodException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/NeverReturningMethodException.php new file mode 100644 index 00000000..21aa6982 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/NeverReturningMethodException.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\Framework\MockObject; + +use function sprintf; +use RuntimeException; + +/** + * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit + */ +final class NeverReturningMethodException extends RuntimeException implements Exception +{ + /** + * @psalm-param class-string $className + * @psalm-param non-empty-string $methodName + */ + public function __construct(string $className, string $methodName) + { + parent::__construct( + sprintf( + 'Method %s::%s() is declared to never return', + $className, + $methodName, + ), + ); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ReturnValueNotConfiguredException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ReturnValueNotConfiguredException.php index 21808989..0b7bceb3 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ReturnValueNotConfiguredException.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ReturnValueNotConfiguredException.php @@ -20,10 +20,10 @@ final class ReturnValueNotConfiguredException extends \PHPUnit\Framework\Excepti { parent::__construct( sprintf( - 'Return value inference disabled and no expectation set up for %s::%s()', + 'No return value is configured for %s::%s() and return value generation is disabled', $invocation->className(), - $invocation->methodName() - ) + $invocation->methodName(), + ), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassAlreadyExistsException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ClassAlreadyExistsException.php similarity index 87% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassAlreadyExistsException.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ClassAlreadyExistsException.php index 0ba9a187..4ff72ab5 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassAlreadyExistsException.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ClassAlreadyExistsException.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\Framework\MockObject; +namespace PHPUnit\Framework\MockObject\Generator; use function sprintf; @@ -21,8 +21,8 @@ final class ClassAlreadyExistsException extends \PHPUnit\Framework\Exception imp parent::__construct( sprintf( 'Class "%s" already exists', - $className - ) + $className, + ), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsEnumerationException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ClassIsEnumerationException.php similarity index 87% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsEnumerationException.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ClassIsEnumerationException.php index 696c1905..96137c41 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsEnumerationException.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ClassIsEnumerationException.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\Framework\MockObject; +namespace PHPUnit\Framework\MockObject\Generator; use function sprintf; @@ -21,8 +21,8 @@ final class ClassIsEnumerationException extends \PHPUnit\Framework\Exception imp parent::__construct( sprintf( 'Class "%s" is an enumeration and cannot be doubled', - $className - ) + $className, + ), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsFinalException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ClassIsFinalException.php similarity index 87% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsFinalException.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ClassIsFinalException.php index e648f026..de9e9430 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsFinalException.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ClassIsFinalException.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\Framework\MockObject; +namespace PHPUnit\Framework\MockObject\Generator; use function sprintf; @@ -21,8 +21,8 @@ final class ClassIsFinalException extends \PHPUnit\Framework\Exception implement parent::__construct( sprintf( 'Class "%s" is declared "final" and cannot be doubled', - $className - ) + $className, + ), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsReadonlyException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ClassIsReadonlyException.php similarity index 87% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsReadonlyException.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ClassIsReadonlyException.php index aa1a7451..7cf07fe9 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsReadonlyException.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ClassIsReadonlyException.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\Framework\MockObject; +namespace PHPUnit\Framework\MockObject\Generator; use function sprintf; @@ -21,8 +21,8 @@ final class ClassIsReadonlyException extends \PHPUnit\Framework\Exception implem parent::__construct( sprintf( 'Class "%s" is declared "readonly" and cannot be doubled', - $className - ) + $className, + ), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/DuplicateMethodException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/DuplicateMethodException.php similarity index 90% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Exception/DuplicateMethodException.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/DuplicateMethodException.php index 1216b45d..71bed992 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/DuplicateMethodException.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/DuplicateMethodException.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\Framework\MockObject; +namespace PHPUnit\Framework\MockObject\Generator; use function array_diff_assoc; use function array_unique; @@ -28,8 +28,8 @@ final class DuplicateMethodException extends \PHPUnit\Framework\Exception implem sprintf( 'Cannot double using a method list that contains duplicates: "%s" (duplicate: "%s")', implode(', ', $methods), - implode(', ', array_unique(array_diff_assoc($methods, array_unique($methods)))) - ) + implode(', ', array_unique(array_diff_assoc($methods, array_unique($methods)))), + ), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/Exception.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/Exception.php new file mode 100644 index 00000000..9a3c2588 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/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\Framework\MockObject\Generator; + +use PHPUnit\Framework\MockObject\Exception as BaseException; + +/** + * @internal This interface is not covered by the backward compatibility promise for PHPUnit + */ +interface Exception extends BaseException +{ +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/InvalidMethodNameException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/InvalidMethodNameException.php similarity index 87% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Exception/InvalidMethodNameException.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/InvalidMethodNameException.php index d2444cf1..4a7bd68e 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/InvalidMethodNameException.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/InvalidMethodNameException.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\Framework\MockObject; +namespace PHPUnit\Framework\MockObject\Generator; use function sprintf; @@ -21,8 +21,8 @@ final class InvalidMethodNameException extends \PHPUnit\Framework\Exception impl parent::__construct( sprintf( 'Cannot double method with invalid name "%s"', - $method - ) + $method, + ), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/OriginalConstructorInvocationRequiredException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/OriginalConstructorInvocationRequiredException.php similarity index 92% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Exception/OriginalConstructorInvocationRequiredException.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/OriginalConstructorInvocationRequiredException.php index ecb9b63c..b91e2614 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/OriginalConstructorInvocationRequiredException.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/OriginalConstructorInvocationRequiredException.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\Framework\MockObject; +namespace PHPUnit\Framework\MockObject\Generator; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ConfigurableMethodsAlreadyInitializedException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ReflectionException.php similarity index 69% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ConfigurableMethodsAlreadyInitializedException.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ReflectionException.php index d12ac997..03efd52d 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ConfigurableMethodsAlreadyInitializedException.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/ReflectionException.php @@ -7,11 +7,11 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ -namespace PHPUnit\Framework\MockObject; +namespace PHPUnit\Framework\MockObject\Generator; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ -final class ConfigurableMethodsAlreadyInitializedException extends \PHPUnit\Framework\Exception implements Exception +final class ReflectionException extends \PHPUnit\Framework\Exception implements Exception { } diff --git a/vendor/phpunit/phpunit/src/Metadata/CodeCoverageIgnore.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/RuntimeException.php similarity index 66% rename from vendor/phpunit/phpunit/src/Metadata/CodeCoverageIgnore.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/RuntimeException.php index 3392cc0d..0cca5fa5 100644 --- a/vendor/phpunit/phpunit/src/Metadata/CodeCoverageIgnore.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/RuntimeException.php @@ -7,17 +7,11 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ -namespace PHPUnit\Metadata; +namespace PHPUnit\Framework\MockObject\Generator; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit - * - * @psalm-immutable */ -final class CodeCoverageIgnore extends Metadata +final class RuntimeException extends \PHPUnit\Framework\Exception implements Exception { - public function isCodeCoverageIgnore(): bool - { - return true; - } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/SoapExtensionNotAvailableException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/SoapExtensionNotAvailableException.php similarity index 89% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Exception/SoapExtensionNotAvailableException.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/SoapExtensionNotAvailableException.php index 98837c95..37af4913 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/SoapExtensionNotAvailableException.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/SoapExtensionNotAvailableException.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\Framework\MockObject; +namespace PHPUnit\Framework\MockObject\Generator; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit @@ -17,7 +17,7 @@ final class SoapExtensionNotAvailableException extends \PHPUnit\Framework\Except public function __construct() { parent::__construct( - 'The SOAP extension is required to generate a test double from WSDL' + '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/Generator/Exception/UnknownClassException.php similarity index 87% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownClassException.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/UnknownClassException.php index e124f9b1..64c79e0a 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownClassException.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/UnknownClassException.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\Framework\MockObject; +namespace PHPUnit\Framework\MockObject\Generator; use function sprintf; @@ -21,8 +21,8 @@ final class UnknownClassException extends \PHPUnit\Framework\Exception implement parent::__construct( sprintf( 'Class "%s" does not exist', - $className - ) + $className, + ), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownTraitException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/UnknownTraitException.php similarity index 79% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownTraitException.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/UnknownTraitException.php index 90fc8d84..67cecfa9 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownTraitException.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/UnknownTraitException.php @@ -7,12 +7,14 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ -namespace PHPUnit\Framework\MockObject; +namespace PHPUnit\Framework\MockObject\Generator; use function sprintf; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5243 */ final class UnknownTraitException extends \PHPUnit\Framework\Exception implements Exception { @@ -21,8 +23,8 @@ final class UnknownTraitException extends \PHPUnit\Framework\Exception implement parent::__construct( sprintf( 'Trait "%s" does not exist', - $traitName - ) + $traitName, + ), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownTypeException.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/UnknownTypeException.php similarity index 88% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownTypeException.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/UnknownTypeException.php index b1a70edd..ccda69bb 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/UnknownTypeException.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Exception/UnknownTypeException.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\Framework\MockObject; +namespace PHPUnit\Framework\MockObject\Generator; use function sprintf; @@ -21,8 +21,8 @@ final class UnknownTypeException extends \PHPUnit\Framework\Exception implements parent::__construct( sprintf( 'Class or interface "%s" does not exist', - $type - ) + $type, + ), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Generator.php similarity index 75% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Generator.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Generator.php index 0db43749..c140ca26 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/Generator.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\Framework\MockObject; +namespace PHPUnit\Framework\MockObject\Generator; use const PHP_EOL; use const PREG_OFFSET_CAPTURE; @@ -44,6 +44,16 @@ use Exception; use Iterator; use IteratorAggregate; use PHPUnit\Framework\InvalidArgumentException; +use PHPUnit\Framework\MockObject\ConfigurableMethod; +use PHPUnit\Framework\MockObject\DoubledCloneMethod; +use PHPUnit\Framework\MockObject\Method; +use PHPUnit\Framework\MockObject\MockObject; +use PHPUnit\Framework\MockObject\MockObjectApi; +use PHPUnit\Framework\MockObject\MockObjectInternal; +use PHPUnit\Framework\MockObject\ProxiedCloneMethod; +use PHPUnit\Framework\MockObject\Stub; +use PHPUnit\Framework\MockObject\StubApi; +use PHPUnit\Framework\MockObject\StubInternal; use ReflectionClass; use ReflectionMethod; use SoapClient; @@ -73,10 +83,14 @@ final class Generator '__clone' => true, '__halt_compiler' => true, ]; + + /** + * @psalm-var array + */ private static array $cache = []; /** - * Returns a mock object for the specified class. + * Returns a test double for the specified class. * * @throws ClassAlreadyExistsException * @throws ClassIsEnumerationException @@ -89,7 +103,7 @@ final class Generator * @throws RuntimeException * @throws UnknownTypeException */ - public function getMock(string $type, ?array $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 testDouble(string $type, bool $mockObject, ?array $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|Stub { if ($type === Traversable::class) { $type = Iterator::class; @@ -108,12 +122,13 @@ final class Generator $mock = $this->generate( $type, + $mockObject, $methods, $mockClassName, $callOriginalClone, $callAutoload, $cloneArguments, - $callOriginalMethods + $callOriginalMethods, ); $object = $this->getObject( @@ -123,10 +138,16 @@ final class Generator $arguments, $callOriginalMethods, $proxyTarget, - $returnValueGeneration + $returnValueGeneration, ); - assert($object instanceof MockObject); + assert($object instanceof $type); + + if ($mockObject) { + assert($object instanceof MockObject); + } else { + assert($object instanceof Stub); + } return $object; } @@ -137,7 +158,7 @@ final class Generator * @throws RuntimeException * @throws UnknownTypeException */ - public function getMockForInterfaces(array $interfaces, bool $callAutoload = true): MockObject + public function testDoubleForInterfaceIntersection(array $interfaces, bool $mockObject, bool $callAutoload = true): MockObject|Stub { if (count($interfaces) < 2) { throw new RuntimeException('At least two interfaces must be specified'); @@ -154,7 +175,7 @@ final class Generator $methods = []; foreach ($interfaces as $interface) { - $methods = array_merge($methods, $this->getClassMethods($interface)); + $methods = array_merge($methods, $this->namesOfMethodsIn($interface)); } if (count(array_unique($methods)) < count($methods)) { @@ -174,7 +195,7 @@ final class Generator $intersectionName = sprintf( 'Intersection_%s_%s', implode('_', $unqualifiedNames), - substr(md5((string) mt_rand()), 0, 8) + substr(md5((string) mt_rand()), 0, 8), ); } while (interface_exists($intersectionName, false)); @@ -184,12 +205,12 @@ final class Generator [ 'intersection' => $intersectionName, 'interfaces' => implode(', ', $interfaces), - ] + ], ); eval($template->render()); - return $this->getMock($intersectionName); + return $this->testDouble($intersectionName, $mockObject); } /** @@ -198,12 +219,6 @@ final class Generator * * 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 ClassAlreadyExistsException * @throws ClassIsEnumerationException * @throws ClassIsFinalException @@ -216,24 +231,15 @@ final class Generator * @throws RuntimeException * @throws UnknownClassException * @throws UnknownTypeException + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5241 */ - 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 + public function mockObjectForAbstractClass(string $originalClassName, array $arguments = [], string $mockClassName = '', bool $callOriginalConstructor = true, bool $callOriginalClone = true, bool $callAutoload = true, array $mockedMethods = null, bool $cloneArguments = true): MockObject { if (class_exists($originalClassName, $callAutoload) || interface_exists($originalClassName, $callAutoload)) { - try { - $reflector = new ReflectionClass($originalClassName); - // @codeCoverageIgnoreStart - } catch (\ReflectionException $e) { - throw new ReflectionException( - $e->getMessage(), - $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - - $methods = $mockedMethods; + $reflector = $this->reflectClass($originalClassName); + $methods = $mockedMethods; foreach ($reflector->getMethods() as $method) { if ($method->isAbstract() && !in_array($method->getName(), $methods ?? [], true)) { @@ -245,16 +251,22 @@ final class Generator $methods = null; } - return $this->getMock( + $mockObject = $this->testDouble( $originalClassName, + true, $methods, $arguments, $mockClassName, $callOriginalConstructor, $callOriginalClone, $callAutoload, - $cloneArguments + $cloneArguments, ); + + assert($mockObject instanceof $originalClassName); + assert($mockObject instanceof MockObject); + + return $mockObject; } throw new UnknownClassException($originalClassName); @@ -280,8 +292,10 @@ final class Generator * @throws UnknownClassException * @throws UnknownTraitException * @throws UnknownTypeException + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5243 */ - 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 + public function mockObjectForTrait(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 UnknownTraitException($traitName); @@ -290,7 +304,7 @@ final class Generator $className = $this->generateClassName( $traitName, '', - 'Trait_' + 'Trait_', ); $classTemplate = $this->loadTemplate('trait_class.tpl'); @@ -300,13 +314,13 @@ final class Generator 'prologue' => 'abstract ', 'class_name' => $className['className'], 'trait_name' => $traitName, - ] + ], ); $mockTrait = new MockTrait($classTemplate->render(), $className['className']); $mockTrait->generate(); - return $this->getMockForAbstractClass($className['className'], $arguments, $mockClassName, $callOriginalConstructor, $callOriginalClone, $callAutoload, $mockedMethods, $cloneArguments); + return $this->mockObjectForAbstractClass($className['className'], $arguments, $mockClassName, $callOriginalConstructor, $callOriginalClone, $callAutoload, $mockedMethods, $cloneArguments); } /** @@ -317,8 +331,10 @@ final class Generator * @throws ReflectionException * @throws RuntimeException * @throws UnknownTraitException + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5244 */ - public function getObjectForTrait(string $traitName, string $traitClassName = '', bool $callAutoload = true, bool $callOriginalConstructor = false, array $arguments = []): object + public function objectForTrait(string $traitName, string $traitClassName = '', bool $callAutoload = true, bool $callOriginalConstructor = false, array $arguments = []): object { if (!trait_exists($traitName, $callAutoload)) { throw new UnknownTraitException($traitName); @@ -327,7 +343,7 @@ final class Generator $className = $this->generateClassName( $traitName, $traitClassName, - 'Trait_' + 'Trait_', ); $classTemplate = $this->loadTemplate('trait_class.tpl'); @@ -337,17 +353,17 @@ final class Generator 'prologue' => '', 'class_name' => $className['className'], 'trait_name' => $traitName, - ] + ], ); return $this->getObject( new MockTrait( $classTemplate->render(), - $className['className'] + $className['className'], ), '', $callOriginalConstructor, - $arguments + $arguments, ); } @@ -357,38 +373,45 @@ final class Generator * @throws ClassIsReadonlyException * @throws ReflectionException * @throws RuntimeException + * + * @todo This method is only public because it is used to test generated code in PHPT tests + * + * @see https://github.com/sebastianbergmann/phpunit/issues/5476 */ - public function generate(string $type, array $methods = null, string $mockClassName = '', bool $callOriginalClone = true, bool $callAutoload = true, bool $cloneArguments = true, bool $callOriginalMethods = false): MockClass + public function generate(string $type, bool $mockObject, array $methods = null, string $mockClassName = '', bool $callOriginalClone = true, bool $callAutoload = true, bool $cloneArguments = true, bool $callOriginalMethods = false): MockClass { if ($mockClassName !== '') { - return $this->generateMock( + return $this->generateCodeForTestDoubleClass( $type, + $mockObject, $methods, $mockClassName, $callOriginalClone, $callAutoload, $cloneArguments, - $callOriginalMethods + $callOriginalMethods, ); } $key = md5( $type . + ($mockObject ? 'MockObject' : 'TestStub') . serialize($methods) . serialize($callOriginalClone) . serialize($cloneArguments) . - serialize($callOriginalMethods) + serialize($callOriginalMethods), ); if (!isset(self::$cache[$key])) { - self::$cache[$key] = $this->generateMock( + self::$cache[$key] = $this->generateCodeForTestDoubleClass( $type, + $mockObject, $methods, $mockClassName, $callOriginalClone, $callAutoload, $cloneArguments, - $callOriginalMethods + $callOriginalMethods, ); } @@ -398,6 +421,8 @@ final class Generator /** * @throws RuntimeException * @throws SoapExtensionNotAvailableException + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5242 */ public function generateClassFromWsdl(string $wsdlFile, string $className, array $methods = [], array $options = []): string { @@ -410,12 +435,13 @@ final class Generator try { $client = new SoapClient($wsdlFile, $options); $_methods = array_unique($client->__getFunctions()); + unset($client); } catch (SoapFault $e) { throw new RuntimeException( $e->getMessage(), $e->getCode(), - $e + $e, ); } @@ -426,6 +452,7 @@ final class Generator foreach ($_methods as $method) { preg_match_all('/[a-zA-Z_\x7f-\xff][a-zA-Z0-9_\x7f-\xff]*\(/', $method, $matches, PREG_OFFSET_CAPTURE); + $lastFunction = array_pop($matches[0]); $nameStart = $lastFunction[1]; $nameEnd = $nameStart + strlen($lastFunction[0]) - 1; @@ -434,7 +461,7 @@ final class Generator if (empty($methods) || in_array($name, $methods, true)) { $arguments = explode( ',', - str_replace(')', '', substr($method, $nameEnd + 1)) + str_replace(')', '', substr($method, $nameEnd + 1)), ); foreach (range(0, count($arguments) - 1) as $i) { @@ -451,7 +478,7 @@ final class Generator [ 'method_name' => $name, 'arguments' => implode(', ', $arguments), - ] + ], ); $methodsBuffer .= $methodTemplate->render(); @@ -482,42 +509,12 @@ final class Generator 'wsdl' => $wsdlFile, 'options' => $optionsBuffer, 'methods' => $methodsBuffer, - ] + ], ); return $classTemplate->render(); } - /** - * @throws ReflectionException - * - * @psalm-return list - */ - public function getClassMethods(string $className): array - { - try { - $class = new ReflectionClass($className); - // @codeCoverageIgnoreStart - } catch (\ReflectionException $e) { - throw new ReflectionException( - $e->getMessage(), - $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - - $methods = []; - - foreach ($class->getMethods() as $method) { - if ($method->isPublic() || $method->isAbstract()) { - $methods[] = $method->getName(); - } - } - - return $methods; - } - /** * @throws ReflectionException * @@ -525,18 +522,7 @@ final class Generator */ public function mockClassMethods(string $className, bool $callOriginalMethods, bool $cloneArguments): array { - try { - $class = new ReflectionClass($className); - // @codeCoverageIgnoreStart - } catch (\ReflectionException $e) { - throw new ReflectionException( - $e->getMessage(), - $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - + $class = $this->reflectClass($className); $methods = []; foreach ($class->getMethods() as $method) { @@ -548,34 +534,6 @@ final class Generator return $methods; } - /** - * @throws ReflectionException - * - * @psalm-return list - */ - public function mockInterfaceMethods(string $interfaceName, bool $cloneArguments): array - { - try { - $class = new ReflectionClass($interfaceName); - // @codeCoverageIgnoreStart - } catch (\ReflectionException $e) { - throw new ReflectionException( - $e->getMessage(), - $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - - $methods = []; - - foreach ($class->getMethods() as $method) { - $methods[] = MockMethod::fromReflection($method, false, $cloneArguments); - } - - return $methods; - } - /** * @psalm-param class-string $interfaceName * @@ -585,19 +543,8 @@ final class Generator */ private function userDefinedInterfaceMethods(string $interfaceName): array { - try { - // @codeCoverageIgnoreStart - $interface = new ReflectionClass($interfaceName); - } catch (\ReflectionException $e) { - throw new ReflectionException( - $e->getMessage(), - $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - - $methods = []; + $interface = $this->reflectClass($interfaceName); + $methods = []; foreach ($interface->getMethods() as $method) { if (!$method->isUserDefined()) { @@ -623,7 +570,7 @@ final class Generator $this->instantiateProxyTarget($proxyTarget, $object, $type, $arguments); } - if ($object instanceof MockObject) { + if ($object instanceof StubInternal) { $object->__phpunit_setReturnValueGeneration($returnValueGeneration); } @@ -637,21 +584,22 @@ final class Generator * @throws ReflectionException * @throws RuntimeException */ - private function generateMock(string $type, ?array $explicitMethods, string $mockClassName, bool $callOriginalClone, bool $callAutoload, bool $cloneArguments, bool $callOriginalMethods): MockClass + private function generateCodeForTestDoubleClass(string $type, bool $mockObject, ?array $explicitMethods, string $mockClassName, bool $callOriginalClone, bool $callAutoload, bool $cloneArguments, bool $callOriginalMethods): MockClass { - $classTemplate = $this->loadTemplate('mocked_class.tpl'); - $additionalInterfaces = []; - $mockedCloneMethod = false; - $unmockedCloneMethod = false; - $isClass = false; - $isInterface = false; - $class = null; - $mockMethods = new MockMethodSet; + $classTemplate = $this->loadTemplate('test_double_class.tpl'); + $additionalInterfaces = []; + $doubledCloneMethod = false; + $proxiedCloneMethod = false; + $isClass = false; + $isInterface = false; + $class = null; + $mockMethods = new MockMethodSet; + $testDoubleClassPrefix = $mockObject ? 'MockObject_' : 'TestStub_'; $_mockClassName = $this->generateClassName( $type, $mockClassName, - 'Mock_' + $testDoubleClassPrefix, ); if (class_exists($_mockClassName['fullClassName'], $callAutoload)) { @@ -671,19 +619,9 @@ final class Generator $epilogue = "\n\n}"; } - $mockedCloneMethod = true; + $doubledCloneMethod = true; } else { - try { - $class = new ReflectionClass($_mockClassName['fullClassName']); - // @codeCoverageIgnoreStart - } catch (\ReflectionException $e) { - throw new ReflectionException( - $e->getMessage(), - $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd + $class = $this->reflectClass($_mockClassName['fullClassName']); if ($class->isEnum()) { throw new ClassIsEnumerationException($_mockClassName['fullClassName']); @@ -702,18 +640,7 @@ final class Generator $actualClassName = Exception::class; $additionalInterfaces[] = $class->getName(); $isInterface = false; - - try { - $class = new ReflectionClass($actualClassName); - // @codeCoverageIgnoreStart - } catch (\ReflectionException $e) { - throw new ReflectionException( - $e->getMessage(), - $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd + $class = $this->reflectClass($actualClassName); foreach ($this->userDefinedInterfaceMethods($_mockClassName['fullClassName']) as $method) { $methodName = $method->getName(); @@ -727,14 +654,14 @@ final class Generator } $mockMethods->addMethods( - MockMethod::fromReflection($method, $callOriginalMethods, $cloneArguments) + MockMethod::fromReflection($method, $callOriginalMethods, $cloneArguments), ); } $_mockClassName = $this->generateClassName( $actualClassName, $_mockClassName['className'], - 'Mock_' + $testDoubleClassPrefix, ); } @@ -745,7 +672,7 @@ final class Generator $additionalInterfaces[] = Iterator::class; $mockMethods->addMethods( - ...$this->mockClassMethods(Iterator::class, $callOriginalMethods, $cloneArguments) + ...$this->mockClassMethods(Iterator::class, $callOriginalMethods, $cloneArguments), ); } @@ -754,25 +681,25 @@ final class Generator if (!$cloneMethod->isFinal()) { if ($callOriginalClone && !$isInterface) { - $unmockedCloneMethod = true; + $proxiedCloneMethod = true; } else { - $mockedCloneMethod = true; + $doubledCloneMethod = true; } } } else { - $mockedCloneMethod = true; + $doubledCloneMethod = true; } } 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->interfaceMethods($_mockClassName['fullClassName'], $cloneArguments), ); } @@ -783,7 +710,7 @@ final class Generator if ($this->canMethodBeDoubled($method)) { $mockMethods->addMethods( - MockMethod::fromReflection($method, $callOriginalMethods, $cloneArguments) + MockMethod::fromReflection($method, $callOriginalMethods, $cloneArguments), ); } } else { @@ -791,8 +718,8 @@ final class Generator MockMethod::fromName( $_mockClassName['fullClassName'], $methodName, - $cloneArguments - ) + $cloneArguments, + ), ); } } @@ -803,45 +730,65 @@ final class Generator foreach ($mockMethods->asArray() as $mockMethod) { $mockedMethods .= $mockMethod->generateCode(); - $configurable[] = new ConfigurableMethod($mockMethod->methodName(), $mockMethod->returnType()); + + $configurable[] = new ConfigurableMethod( + $mockMethod->methodName(), + $mockMethod->defaultParameterValues(), + $mockMethod->numberOfParameters(), + $mockMethod->returnType(), + ); } - $method = ''; + /** @psalm-var trait-string[] $traits */ + $traits = [StubApi::class]; + + if ($mockObject) { + $traits[] = MockObjectApi::class; + } if (!$mockMethods->hasMethod('method') && (!isset($class) || !$class->hasMethod('method'))) { - $method = PHP_EOL . ' use \PHPUnit\Framework\MockObject\Method;'; + $traits[] = Method::class; } - $cloneTrait = ''; - - if ($mockedCloneMethod) { - $cloneTrait = PHP_EOL . ' use \PHPUnit\Framework\MockObject\MockedCloneMethod;'; + if ($doubledCloneMethod) { + $traits[] = DoubledCloneMethod::class; } - if ($unmockedCloneMethod) { - $cloneTrait = PHP_EOL . ' use \PHPUnit\Framework\MockObject\UnmockedCloneMethod;'; + if ($proxiedCloneMethod) { + $traits[] = ProxiedCloneMethod::class; } + $useStatements = ''; + + foreach ($traits as $trait) { + $useStatements .= sprintf( + ' use %s;' . PHP_EOL, + $trait, + ); + } + + unset($traits); + $classTemplate->setVar( [ 'prologue' => $prologue ?? '', 'epilogue' => $epilogue ?? '', - 'class_declaration' => $this->generateMockClassDeclaration( + 'class_declaration' => $this->generateTestDoubleClassDeclaration( + $mockObject, $_mockClassName, $isInterface, - $additionalInterfaces + $additionalInterfaces, ), - 'clone' => $cloneTrait, + 'use_statements' => $useStatements, 'mock_class_name' => $_mockClassName['className'], 'mocked_methods' => $mockedMethods, - 'method' => $method, - ] + ], ); return new MockClass( $classTemplate->render(), $_mockClassName['className'], - $configurable + $configurable, ); } @@ -877,18 +824,22 @@ final class Generator ]; } - private function generateMockClassDeclaration(array $mockClassName, bool $isInterface, array $additionalInterfaces = []): string + private function generateTestDoubleClassDeclaration(bool $mockObject, array $mockClassName, bool $isInterface, array $additionalInterfaces = []): string { - $buffer = 'class '; + if ($mockObject) { + $additionalInterfaces[] = MockObjectInternal::class; + } else { + $additionalInterfaces[] = StubInternal::class; + } - $additionalInterfaces[] = MockObject::class; - $interfaces = implode(', ', $additionalInterfaces); + $buffer = 'class '; + $interfaces = implode(', ', $additionalInterfaces); if ($isInterface) { $buffer .= sprintf( '%s implements %s', $mockClassName['className'], - $interfaces + $interfaces, ); if (!in_array($mockClassName['originalClassName'], $additionalInterfaces, true)) { @@ -906,7 +857,7 @@ final class Generator $mockClassName['className'], !empty($mockClassName['namespaceName']) ? $mockClassName['namespaceName'] . '\\' : '', $mockClassName['originalClassName'], - $interfaces + $interfaces, ); } @@ -955,17 +906,19 @@ final class Generator */ private function ensureValidMethods(?array $methods): void { - 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 InvalidMethodNameException((string) $method); - } - } + if ($methods === null) { + return; + } - if ($methods !== array_unique($methods)) { - throw new DuplicateMethodException($methods); + foreach ($methods as $method) { + if (!preg_match('~[a-zA-Z_\x7f-\xff][a-zA-Z0-9_\x7f-\xff]*~', (string) $method)) { + throw new InvalidMethodNameException((string) $method); } } + + if ($methods !== array_unique($methods)) { + throw new DuplicateMethodException($methods); + } } /** @@ -975,17 +928,7 @@ final class Generator private function ensureMockedClassDoesNotAlreadyExist(string $mockClassName): void { if ($mockClassName !== '' && class_exists($mockClassName, false)) { - try { - $reflector = new ReflectionClass($mockClassName); - // @codeCoverageIgnoreStart - } catch (\ReflectionException $e) { - throw new ReflectionException( - $e->getMessage(), - $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd + $reflector = $this->reflectClass($mockClassName); if (!$reflector->implementsInterface(MockObject::class)) { throw new ClassAlreadyExistsException($mockClassName); @@ -1012,7 +955,7 @@ final class Generator throw new ReflectionException( $e->getMessage(), $e->getCode(), - $e + $e, ); } // @codeCoverageIgnoreEnd @@ -1025,10 +968,10 @@ final class Generator throw new ReflectionException( $e->getMessage(), $e->getCode(), - $e + $e, ); + // @codeCoverageIgnoreEnd } - // @codeCoverageIgnoreEnd } /** @@ -1053,7 +996,7 @@ final class Generator throw new ReflectionException( $e->getMessage(), $e->getCode(), - $e + $e, ); } // @codeCoverageIgnoreEnd @@ -1062,4 +1005,66 @@ final class Generator $object->__phpunit_setOriginalObject($proxyTarget); } + + /** + * @psalm-param class-string $className + * + * @throws ReflectionException + */ + private function reflectClass(string $className): ReflectionClass + { + try { + $class = new ReflectionClass($className); + // @codeCoverageIgnoreStart + } catch (\ReflectionException $e) { + throw new ReflectionException( + $e->getMessage(), + $e->getCode(), + $e, + ); + } + // @codeCoverageIgnoreEnd + + return $class; + } + + /** + * @psalm-param class-string $classOrInterfaceName + * + * @psalm-return list + * + * @throws ReflectionException + */ + private function namesOfMethodsIn(string $classOrInterfaceName): array + { + $class = $this->reflectClass($classOrInterfaceName); + $methods = []; + + foreach ($class->getMethods() as $method) { + if ($method->isPublic() || $method->isAbstract()) { + $methods[] = $method->getName(); + } + } + + return $methods; + } + + /** + * @psalm-param class-string $interfaceName + * + * @psalm-return list + * + * @throws ReflectionException + */ + private function interfaceMethods(string $interfaceName, bool $cloneArguments): array + { + $class = $this->reflectClass($interfaceName); + $methods = []; + + foreach ($class->getMethods() as $method) { + $methods[] = MockMethod::fromReflection($method, false, $cloneArguments); + } + + return $methods; + } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/MockClass.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/MockClass.php similarity index 91% rename from vendor/phpunit/phpunit/src/Framework/MockObject/MockClass.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/MockClass.php index 69a9c542..7606ea59 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/MockClass.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/MockClass.php @@ -7,10 +7,11 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ -namespace PHPUnit\Framework\MockObject; +namespace PHPUnit\Framework\MockObject\Generator; use function call_user_func; use function class_exists; +use PHPUnit\Framework\MockObject\ConfigurableMethod; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit @@ -53,7 +54,7 @@ final class MockClass implements MockType $this->mockName, '__phpunit_initConfigurableMethods', ], - ...$this->configurableMethods + ...$this->configurableMethods, ); } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/MockMethod.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/MockMethod.php similarity index 75% rename from vendor/phpunit/phpunit/src/Framework/MockObject/MockMethod.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/MockMethod.php index d12690a5..4c58e8c6 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/MockMethod.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/MockMethod.php @@ -7,8 +7,9 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ -namespace PHPUnit\Framework\MockObject; +namespace PHPUnit\Framework\MockObject\Generator; +use function count; use function explode; use function implode; use function is_object; @@ -34,7 +35,15 @@ use SebastianBergmann\Type\UnknownType; final class MockMethod { use TemplateLoader; + + /** + * @psalm-var class-string + */ private readonly string $className; + + /** + * @psalm-var non-empty-string + */ private readonly string $methodName; private readonly bool $cloneArguments; private readonly string $modifier; @@ -46,6 +55,16 @@ final class MockMethod private readonly bool $static; private readonly ?string $deprecation; + /** + * @psalm-var array + */ + private readonly array $defaultParameterValues; + + /** + * @psalm-var non-negative-int + */ + private readonly int $numberOfParameters; + /** * @throws ReflectionException * @throws RuntimeException @@ -86,32 +105,46 @@ final class MockMethod $modifier, self::methodParametersForDeclaration($method), self::methodParametersForCall($method), + self::methodParametersDefaultValues($method), + count($method->getParameters()), (new ReflectionMapper)->fromReturnType($method), $reference, $callOriginalMethod, $method->isStatic(), - $deprecation + $deprecation, ); } - public static function fromName(string $fullClassName, string $methodName, bool $cloneArguments): self + /** + * @param class-string $className + * @param non-empty-string $methodName + */ + public static function fromName(string $className, string $methodName, bool $cloneArguments): self { return new self( - $fullClassName, + $className, $methodName, $cloneArguments, 'public', '', '', + [], + 0, new UnknownType, '', false, false, - null + 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) + /** + * @psalm-param class-string $className + * @psalm-param non-empty-string $methodName + * @psalm-param array $defaultParameterValues + * @psalm-param non-negative-int $numberOfParameters + */ + private function __construct(string $className, string $methodName, bool $cloneArguments, string $modifier, string $argumentsForDeclaration, string $argumentsForCall, array $defaultParameterValues, int $numberOfParameters, Type $returnType, string $reference, bool $callOriginalMethod, bool $static, ?string $deprecation) { $this->className = $className; $this->methodName = $methodName; @@ -119,6 +152,8 @@ final class MockMethod $this->modifier = $modifier; $this->argumentsForDeclaration = $argumentsForDeclaration; $this->argumentsForCall = $argumentsForCall; + $this->defaultParameterValues = $defaultParameterValues; + $this->numberOfParameters = $numberOfParameters; $this->returnType = $returnType; $this->reference = $reference; $this->callOriginalMethod = $callOriginalMethod; @@ -126,6 +161,9 @@ final class MockMethod $this->deprecation = $deprecation; } + /** + * @psalm-return non-empty-string + */ public function methodName(): string { return $this->methodName; @@ -137,20 +175,24 @@ final class MockMethod public function generateCode(): string { if ($this->static) { - $templateFile = 'mocked_static_method.tpl'; - } elseif ($this->returnType->isNever() || $this->returnType->isVoid()) { - $templateFile = sprintf( - '%s_method_never_or_void.tpl', - $this->callOriginalMethod ? 'proxied' : 'mocked' - ); + $templateFile = 'doubled_static_method.tpl'; } else { $templateFile = sprintf( '%s_method.tpl', - $this->callOriginalMethod ? 'proxied' : 'mocked' + $this->callOriginalMethod ? 'proxied' : 'doubled', ); } - $deprecation = $this->deprecation; + $deprecation = $this->deprecation; + $returnResult = ''; + + if (!$this->returnType->isNever() && !$this->returnType->isVoid()) { + $returnResult = <<<'EOT' + + + return $__phpunit_result; +EOT; + } if (null !== $this->deprecation) { $deprecation = "The {$this->className}::{$this->methodName} method is deprecated ({$this->deprecation})."; @@ -159,7 +201,7 @@ final class MockMethod $deprecationTemplate->setVar( [ 'deprecation' => var_export($deprecation, true), - ] + ], ); $deprecation = $deprecationTemplate->render(); @@ -180,7 +222,8 @@ final class MockMethod 'reference' => $this->reference, 'clone_arguments' => $this->cloneArguments ? 'true' : 'false', 'deprecation' => $deprecation, - ] + 'return_result' => $returnResult, + ], ); return $template->render(); @@ -191,6 +234,22 @@ final class MockMethod return $this->returnType; } + /** + * @psalm-return array + */ + public function defaultParameterValues(): array + { + return $this->defaultParameterValues; + } + + /** + * @psalm-return non-negative-int + */ + public function numberOfParameters(): int + { + return $this->numberOfParameters; + } + /** * Returns the parameters of a function or method. * @@ -289,20 +348,38 @@ final class MockMethod substr( substr( $parameterAsString, - strpos($parameterAsString, ' ') + strlen(' ') + strpos($parameterAsString, ' ') + strlen(' '), ), 0, - -2 - ) + -2, + ), )[1]; // @codeCoverageIgnoreStart } catch (\ReflectionException $e) { throw new ReflectionException( $e->getMessage(), $e->getCode(), - $e + $e, ); } // @codeCoverageIgnoreEnd } + + /** + * @psalm-return array + */ + private static function methodParametersDefaultValues(ReflectionMethod $method): array + { + $result = []; + + foreach ($method->getParameters() as $i => $parameter) { + if (!$parameter->isDefaultValueAvailable()) { + continue; + } + + $result[$i] = $parameter->getDefaultValue(); + } + + return $result; + } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/MockMethodSet.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/MockMethodSet.php similarity index 95% rename from vendor/phpunit/phpunit/src/Framework/MockObject/MockMethodSet.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/MockMethodSet.php index 7a1f533f..31f48a6a 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/MockMethodSet.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/MockMethodSet.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\Framework\MockObject; +namespace PHPUnit\Framework\MockObject\Generator; use function array_key_exists; use function array_values; diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/MockTrait.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/MockTrait.php similarity index 88% rename from vendor/phpunit/phpunit/src/Framework/MockObject/MockTrait.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/MockTrait.php index 030b4a47..20e9301b 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/MockTrait.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/MockTrait.php @@ -7,12 +7,14 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ -namespace PHPUnit\Framework\MockObject; +namespace PHPUnit\Framework\MockObject\Generator; use function class_exists; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5243 */ final class MockTrait implements MockType { @@ -43,9 +45,4 @@ final class MockTrait implements MockType return $this->mockName; } - - public function classCode(): string - { - return $this->classCode; - } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/MockType.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/MockType.php similarity index 90% rename from vendor/phpunit/phpunit/src/Framework/MockObject/MockType.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/MockType.php index 6a03fb51..3f7799f0 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/MockType.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/MockType.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\Framework\MockObject; +namespace PHPUnit\Framework\MockObject\Generator; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/TemplateLoader.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/TemplateLoader.php similarity index 56% rename from vendor/phpunit/phpunit/src/Framework/MockObject/TemplateLoader.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/TemplateLoader.php index 3ee3c22f..fc3b73a1 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/TemplateLoader.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/TemplateLoader.php @@ -7,9 +7,8 @@ * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ -namespace PHPUnit\Framework\MockObject; +namespace PHPUnit\Framework\MockObject\Generator; -use SebastianBergmann\Template\Exception as TemplateException; use SebastianBergmann\Template\Template; /** @@ -23,22 +22,14 @@ trait TemplateLoader private static array $templates = []; /** - * @throws RuntimeException + * @psalm-suppress MissingThrowsDocblock */ private function loadTemplate(string $template): Template { - $filename = __DIR__ . DIRECTORY_SEPARATOR . 'Generator' . DIRECTORY_SEPARATOR . $template; + $filename = __DIR__ . '/templates/' . $template; if (!isset(self::$templates[$filename])) { - try { - self::$templates[$filename] = new Template($filename); - } catch (TemplateException $e) { - throw new RuntimeException( - $e->getMessage(), - $e->getCode(), - $e - ); - } + self::$templates[$filename] = new Template($filename); } return self::$templates[$filename]; diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/mocked_class.tpl b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/mocked_class.tpl deleted file mode 100644 index 593119fb..00000000 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/mocked_class.tpl +++ /dev/null @@ -1,6 +0,0 @@ -declare(strict_types=1); - -{prologue}{class_declaration} -{ - use \PHPUnit\Framework\MockObject\Api;{method}{clone} -{mocked_methods}}{epilogue} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/mocked_method_never_or_void.tpl b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/mocked_method_never_or_void.tpl deleted file mode 100644 index 39020220..00000000 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/mocked_method_never_or_void.tpl +++ /dev/null @@ -1,20 +0,0 @@ - - {modifier} function {reference}{method_name}({arguments_decl}){return_declaration} - {{deprecation} - $__phpunit_arguments = [{arguments_call}]; - $__phpunit_count = func_num_args(); - - if ($__phpunit_count > {arguments_count}) { - $__phpunit_arguments_tmp = func_get_args(); - - for ($__phpunit_i = {arguments_count}; $__phpunit_i < $__phpunit_count; $__phpunit_i++) { - $__phpunit_arguments[] = $__phpunit_arguments_tmp[$__phpunit_i]; - } - } - - $this->__phpunit_getInvocationHandler()->invoke( - new \PHPUnit\Framework\MockObject\Invocation( - '{class_name}', '{method_name}', $__phpunit_arguments, '{return_type}', $this, {clone_arguments} - ) - ); - } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/proxied_method_never_or_void.tpl b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/proxied_method_never_or_void.tpl deleted file mode 100644 index cce19882..00000000 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/proxied_method_never_or_void.tpl +++ /dev/null @@ -1,22 +0,0 @@ - - {modifier} function {reference}{method_name}({arguments_decl}){return_declaration} - { - $__phpunit_arguments = [{arguments_call}]; - $__phpunit_count = func_num_args(); - - if ($__phpunit_count > {arguments_count}) { - $__phpunit_arguments_tmp = func_get_args(); - - for ($__phpunit_i = {arguments_count}; $__phpunit_i < $__phpunit_count; $__phpunit_i++) { - $__phpunit_arguments[] = $__phpunit_arguments_tmp[$__phpunit_i]; - } - } - - $this->__phpunit_getInvocationHandler()->invoke( - new \PHPUnit\Framework\MockObject\Invocation( - '{class_name}', '{method_name}', $__phpunit_arguments, '{return_type}', $this, {clone_arguments}, true - ) - ); - - call_user_func_array(array($this->__phpunit_originalObject, "{method_name}"), $__phpunit_arguments); - } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/deprecation.tpl b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/deprecation.tpl similarity index 100% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Generator/deprecation.tpl rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/deprecation.tpl diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/mocked_method.tpl b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/doubled_method.tpl similarity index 94% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Generator/mocked_method.tpl rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/doubled_method.tpl index 114ff8d0..8b4af38b 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/mocked_method.tpl +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/doubled_method.tpl @@ -16,7 +16,5 @@ new \PHPUnit\Framework\MockObject\Invocation( '{class_name}', '{method_name}', $__phpunit_arguments, '{return_type}', $this, {clone_arguments} ) - ); - - return $__phpunit_result; + );{return_result} } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/mocked_static_method.tpl b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/doubled_static_method.tpl similarity index 100% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Generator/mocked_static_method.tpl rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/doubled_static_method.tpl diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/intersection.tpl b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/intersection.tpl similarity index 100% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Generator/intersection.tpl rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/intersection.tpl diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/proxied_method.tpl b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/proxied_method.tpl similarity index 84% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Generator/proxied_method.tpl rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/proxied_method.tpl index 91bef463..330cdcfc 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/proxied_method.tpl +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/proxied_method.tpl @@ -18,5 +18,5 @@ ) ); - return call_user_func_array(array($this->__phpunit_originalObject, "{method_name}"), $__phpunit_arguments); + $__phpunit_result = call_user_func_array([$this->__phpunit_originalObject, "{method_name}"], $__phpunit_arguments);{return_result} } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/test_double_class.tpl b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/test_double_class.tpl new file mode 100644 index 00000000..369a47a6 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/test_double_class.tpl @@ -0,0 +1,5 @@ +declare(strict_types=1); + +{prologue}{class_declaration} +{ +{use_statements}{mocked_methods}}{epilogue} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/trait_class.tpl b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/trait_class.tpl similarity index 100% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Generator/trait_class.tpl rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/trait_class.tpl diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/wsdl_class.tpl b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/wsdl_class.tpl similarity index 100% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Generator/wsdl_class.tpl rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/wsdl_class.tpl diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/wsdl_method.tpl b/vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/wsdl_method.tpl similarity index 100% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Generator/wsdl_method.tpl rename to vendor/phpunit/phpunit/src/Framework/MockObject/Generator/templates/wsdl_method.tpl diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Invocation.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Invocation.php deleted file mode 100644 index 28aa57b3..00000000 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Invocation.php +++ /dev/null @@ -1,274 +0,0 @@ - - * - * 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 array_map; -use function explode; -use function implode; -use function in_array; -use function interface_exists; -use function is_object; -use function sprintf; -use function str_contains; -use function str_starts_with; -use function strtolower; -use function substr; -use PHPUnit\Framework\SelfDescribing; -use PHPUnit\Util\Cloner; -use ReflectionClass; -use SebastianBergmann\Exporter\Exporter; -use stdClass; -use Throwable; - -/** - * @internal This class is not covered by the backward compatibility promise for PHPUnit - */ -final class Invocation implements SelfDescribing -{ - private readonly string $className; - private readonly string $methodName; - private array $parameters; - private readonly string $returnType; - private bool $isReturnTypeNullable = false; - private readonly bool $proxiedCall; - private readonly object $object; - - public function __construct(string $className, string $methodName, array $parameters, string $returnType, object $object, bool $cloneObjects = false, bool $proxiedCall = false) - { - $this->className = $className; - $this->methodName = $methodName; - $this->parameters = $parameters; - $this->object = $object; - $this->proxiedCall = $proxiedCall; - - if (strtolower($methodName) === '__tostring') { - $returnType = 'string'; - } - - if (str_starts_with($returnType, '?')) { - $returnType = substr($returnType, 1); - $this->isReturnTypeNullable = true; - } - - $this->returnType = $returnType; - - if (!$cloneObjects) { - return; - } - - foreach ($this->parameters as $key => $value) { - if (is_object($value)) { - $this->parameters[$key] = Cloner::clone($value); - } - } - } - - public function className(): string - { - return $this->className; - } - - public function methodName(): string - { - return $this->methodName; - } - - public function parameters(): array - { - return $this->parameters; - } - - /** - * @throws Exception - */ - public function generateReturnValue(): mixed - { - if ($this->isReturnTypeNullable || $this->proxiedCall) { - return null; - } - - $intersection = false; - $union = false; - $unionContainsIntersections = false; - - if (str_contains($this->returnType, '|')) { - $types = explode('|', $this->returnType); - $union = true; - - if (str_contains($this->returnType, '(')) { - $unionContainsIntersections = true; - } - } elseif (str_contains($this->returnType, '&')) { - $types = explode('&', $this->returnType); - $intersection = true; - } else { - $types = [$this->returnType]; - } - - $types = array_map('strtolower', $types); - - if (!$intersection && !$unionContainsIntersections) { - if (in_array('', $types, true) || - in_array('null', $types, true) || - in_array('mixed', $types, true) || - in_array('void', $types, true)) { - return null; - } - - if (in_array('true', $types, true)) { - return true; - } - - if (in_array('false', $types, true) || - in_array('bool', $types, true)) { - return false; - } - - if (in_array('float', $types, true)) { - return 0.0; - } - - if (in_array('int', $types, true)) { - return 0; - } - - if (in_array('string', $types, true)) { - return ''; - } - - if (in_array('array', $types, true)) { - return []; - } - - if (in_array('static', $types, true)) { - try { - return (new ReflectionClass($this->object::class))->newInstanceWithoutConstructor(); - // @codeCoverageIgnoreStart - } catch (\ReflectionException $e) { - throw new ReflectionException( - $e->getMessage(), - $e->getCode(), - $e - ); - } - // @codeCoverageIgnoreEnd - } - - if (in_array('object', $types, true)) { - return new stdClass; - } - - if (in_array('callable', $types, true) || - in_array('closure', $types, true)) { - return static function (): void - { - }; - } - - if (in_array('traversable', $types, true) || - in_array('generator', $types, true) || - in_array('iterable', $types, true)) { - $generator = static function (): \Generator - { - yield from []; - }; - - return $generator(); - } - - if (!$union) { - try { - return (new Generator)->getMock($this->returnType, [], [], '', false); - } catch (Throwable $t) { - if ($t instanceof Exception) { - throw $t; - } - - throw new RuntimeException( - $t->getMessage(), - (int) $t->getCode(), - $t - ); - } - } - } - - if ($intersection && $this->onlyInterfaces($types)) { - try { - return (new Generator)->getMockForInterfaces($types); - } catch (Throwable $t) { - throw new RuntimeException( - sprintf( - 'Return value for %s::%s() cannot be generated: %s', - $this->className, - $this->methodName, - $t->getMessage(), - ), - (int) $t->getCode(), - ); - } - } - - $reason = ''; - - if ($union) { - $reason = ' because the declared return type is a union'; - } elseif ($intersection) { - $reason = ' because the declared return type is an intersection'; - } - - throw new RuntimeException( - sprintf( - 'Return value for %s::%s() cannot be generated%s, please configure a return value for this method', - $this->className, - $this->methodName, - $reason - ) - ); - } - - public function toString(): string - { - $exporter = new Exporter; - - return sprintf( - '%s::%s(%s)%s', - $this->className, - $this->methodName, - implode( - ', ', - array_map( - [$exporter, 'shortenedExport'], - $this->parameters - ) - ), - $this->returnType ? sprintf(': %s', $this->returnType) : '' - ); - } - - public function object(): object - { - return $this->object; - } - - /** - * @psalm-param non-empty-list $types - */ - private function onlyInterfaces(array $types): bool - { - foreach ($types as $type) { - if (!interface_exists($type)) { - return false; - } - } - - return true; - } -} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/MockBuilder.php b/vendor/phpunit/phpunit/src/Framework/MockObject/MockBuilder.php index dd87cd72..ffd130c4 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/MockBuilder.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/MockBuilder.php @@ -10,6 +10,20 @@ namespace PHPUnit\Framework\MockObject; use function array_merge; +use function assert; +use function trait_exists; +use PHPUnit\Framework\InvalidArgumentException; +use PHPUnit\Framework\MockObject\Generator\ClassAlreadyExistsException; +use PHPUnit\Framework\MockObject\Generator\ClassIsEnumerationException; +use PHPUnit\Framework\MockObject\Generator\ClassIsFinalException; +use PHPUnit\Framework\MockObject\Generator\ClassIsReadonlyException; +use PHPUnit\Framework\MockObject\Generator\DuplicateMethodException; +use PHPUnit\Framework\MockObject\Generator\Generator; +use PHPUnit\Framework\MockObject\Generator\InvalidMethodNameException; +use PHPUnit\Framework\MockObject\Generator\OriginalConstructorInvocationRequiredException; +use PHPUnit\Framework\MockObject\Generator\ReflectionException; +use PHPUnit\Framework\MockObject\Generator\RuntimeException; +use PHPUnit\Framework\MockObject\Generator\UnknownTypeException; use PHPUnit\Framework\TestCase; use ReflectionClass; @@ -21,10 +35,22 @@ use ReflectionClass; final class MockBuilder { private readonly TestCase $testCase; + + /** + * @psalm-var class-string|trait-string + */ private readonly string $type; - private ?array $methods = []; - private bool $emptyMethodsArray = false; - private string $mockClassName = ''; + + /** + * @psalm-var list + */ + private array $methods = []; + private bool $emptyMethodsArray = false; + + /** + * @psalm-var ?class-string + */ + private ?string $mockClassName = null; private array $constructorArgs = []; private bool $originalConstructor = true; private bool $originalClone = true; @@ -37,7 +63,7 @@ final class MockBuilder private readonly Generator $generator; /** - * @psalm-param class-string $type + * @psalm-param class-string|trait-string $type */ public function __construct(TestCase $testCase, string $type) { @@ -49,12 +75,12 @@ final class MockBuilder /** * Creates a mock object using a fluent interface. * - * @throws \PHPUnit\Framework\InvalidArgumentException * @throws ClassAlreadyExistsException * @throws ClassIsEnumerationException * @throws ClassIsFinalException * @throws ClassIsReadonlyException * @throws DuplicateMethodException + * @throws InvalidArgumentException * @throws InvalidMethodNameException * @throws OriginalConstructorInvocationRequiredException * @throws ReflectionException @@ -63,13 +89,14 @@ final class MockBuilder * * @psalm-return MockObject&MockedType */ - public function getMock(bool $register = true): MockObject + public function getMock(): MockObject { - $object = $this->generator->getMock( + $object = $this->generator->testDouble( $this->type, + true, !$this->emptyMethodsArray ? $this->methods : null, $this->constructorArgs, - $this->mockClassName, + $this->mockClassName ?? '', $this->originalConstructor, $this->originalClone, $this->autoload, @@ -77,12 +104,13 @@ final class MockBuilder $this->callOriginalMethods, $this->proxyTarget, $this->allowMockingUnknownTypes, - $this->returnValueGeneration + $this->returnValueGeneration, ); - if ($register) { - $this->testCase->registerMockObject($object); - } + assert($object instanceof $this->type); + assert($object instanceof MockObject); + + $this->testCase->registerMockObject($object); return $object; } @@ -95,20 +123,24 @@ final class MockBuilder * @throws \PHPUnit\Framework\Exception * @throws ReflectionException * @throws RuntimeException + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5305 */ public function getMockForAbstractClass(): MockObject { - $object = $this->generator->getMockForAbstractClass( + $object = $this->generator->mockObjectForAbstractClass( $this->type, $this->constructorArgs, - $this->mockClassName, + $this->mockClassName ?? '', $this->originalConstructor, $this->originalClone, $this->autoload, $this->methods, - $this->cloneArguments + $this->cloneArguments, ); + assert($object instanceof MockObject); + $this->testCase->registerMockObject($object); return $object; @@ -122,20 +154,26 @@ final class MockBuilder * @throws \PHPUnit\Framework\Exception * @throws ReflectionException * @throws RuntimeException + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5306 */ public function getMockForTrait(): MockObject { - $object = $this->generator->getMockForTrait( + assert(trait_exists($this->type)); + + $object = $this->generator->mockObjectForTrait( $this->type, $this->constructorArgs, - $this->mockClassName, + $this->mockClassName ?? '', $this->originalConstructor, $this->originalClone, $this->autoload, $this->methods, - $this->cloneArguments + $this->cloneArguments, ); + assert($object instanceof MockObject); + $this->testCase->registerMockObject($object); return $object; @@ -144,7 +182,7 @@ final class MockBuilder /** * Specifies the subset of methods to mock, requiring each to exist in the class. * - * @psalm-param list $methods + * @psalm-param list $methods * * @throws CannotUseOnlyMethodsException * @throws ReflectionException @@ -166,10 +204,10 @@ final class MockBuilder throw new ReflectionException( $e->getMessage(), $e->getCode(), - $e + $e, ); + // @codeCoverageIgnoreEnd } - // @codeCoverageIgnoreEnd foreach ($methods as $method) { if (!$reflector->hasMethod($method)) { @@ -177,7 +215,7 @@ final class MockBuilder } } - $this->methods = array_merge($this->methods ?? [], $methods); + $this->methods = array_merge($this->methods, $methods); return $this; } @@ -185,13 +223,15 @@ final class MockBuilder /** * Specifies methods that don't exist in the class which you want to mock. * - * @psalm-param list $methods + * @psalm-param list $methods * * @throws CannotUseAddMethodsException * @throws ReflectionException * @throws RuntimeException * * @return $this + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5320 */ public function addMethods(array $methods): self { @@ -208,10 +248,10 @@ final class MockBuilder throw new ReflectionException( $e->getMessage(), $e->getCode(), - $e + $e, ); + // @codeCoverageIgnoreEnd } - // @codeCoverageIgnoreEnd foreach ($methods as $method) { if ($reflector->hasMethod($method)) { @@ -219,7 +259,7 @@ final class MockBuilder } } - $this->methods = array_merge($this->methods ?? [], $methods); + $this->methods = array_merge($this->methods, $methods); return $this; } @@ -239,6 +279,8 @@ final class MockBuilder /** * Specifies the name for the mock class. * + * @psalm-param class-string $name + * * @return $this */ public function setMockClassName(string $name): self @@ -300,6 +342,8 @@ final class MockBuilder * Disables the use of class autoloading while creating the mock object. * * @return $this + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5309 */ public function disableAutoload(): self { @@ -312,6 +356,8 @@ final class MockBuilder * Enables the use of class autoloading while creating the mock object. * * @return $this + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5309 */ public function enableAutoload(): self { @@ -324,6 +370,8 @@ final class MockBuilder * Disables the cloning of arguments passed to mocked methods. * * @return $this + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5315 */ public function disableArgumentCloning(): self { @@ -336,6 +384,8 @@ final class MockBuilder * Enables the cloning of arguments passed to mocked methods. * * @return $this + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5315 */ public function enableArgumentCloning(): self { @@ -348,6 +398,8 @@ final class MockBuilder * Enables the invocation of the original methods. * * @return $this + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5307 */ public function enableProxyingToOriginalMethods(): self { @@ -360,6 +412,8 @@ final class MockBuilder * Disables the invocation of the original methods. * * @return $this + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5307 */ public function disableProxyingToOriginalMethods(): self { @@ -373,6 +427,8 @@ final class MockBuilder * Sets the proxy target. * * @return $this + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5307 */ public function setProxyTarget(object $object): self { @@ -383,6 +439,8 @@ final class MockBuilder /** * @return $this + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5308 */ public function allowMockingUnknownTypes(): self { @@ -393,6 +451,8 @@ final class MockBuilder /** * @return $this + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5308 */ public function disallowMockingUnknownTypes(): self { diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Api/MockedCloneMethod.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/DoubledCloneMethod.php similarity index 95% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Api/MockedCloneMethod.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/DoubledCloneMethod.php index 41e5b315..bb02daf8 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Api/MockedCloneMethod.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/DoubledCloneMethod.php @@ -12,7 +12,7 @@ namespace PHPUnit\Framework\MockObject; /** * @internal This trait is not covered by the backward compatibility promise for PHPUnit */ -trait MockedCloneMethod +trait DoubledCloneMethod { public function __clone(): void { diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Api/Method.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/Method.php similarity index 96% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Api/Method.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/Method.php index 5507d0fd..a991eae4 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Api/Method.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/Method.php @@ -25,7 +25,7 @@ trait Method return call_user_func_array( [$expects, 'method'], - func_get_args() + func_get_args(), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/MockObjectApi.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/MockObjectApi.php new file mode 100644 index 00000000..b6b3bd52 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/MockObjectApi.php @@ -0,0 +1,52 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Framework\MockObject; + +use PHPUnit\Framework\MockObject\Builder\InvocationMocker as InvocationMockerBuilder; +use PHPUnit\Framework\MockObject\Rule\InvocationOrder; + +/** + * @internal This trait is not covered by the backward compatibility promise for PHPUnit + */ +trait MockObjectApi +{ + private object $__phpunit_originalObject; + + /** @noinspection MagicMethodsValidityInspection */ + public function __phpunit_hasMatchers(): bool + { + return $this->__phpunit_getInvocationHandler()->hasMatchers(); + } + + /** @noinspection MagicMethodsValidityInspection */ + public function __phpunit_setOriginalObject(object $originalObject): void + { + $this->__phpunit_originalObject = $originalObject; + } + + /** @noinspection MagicMethodsValidityInspection */ + public function __phpunit_verify(bool $unsetInvocationMocker = true): void + { + $this->__phpunit_getInvocationHandler()->verify(); + + if ($unsetInvocationMocker) { + $this->__phpunit_unsetInvocationMocker(); + } + } + + abstract public function __phpunit_getInvocationHandler(): InvocationHandler; + + abstract public function __phpunit_unsetInvocationMocker(): void; + + public function expects(InvocationOrder $matcher): InvocationMockerBuilder + { + return $this->__phpunit_getInvocationHandler()->expects($matcher); + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Api/UnmockedCloneMethod.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/ProxiedCloneMethod.php similarity index 95% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Api/UnmockedCloneMethod.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/ProxiedCloneMethod.php index 9bca7000..ae0dbc78 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Api/UnmockedCloneMethod.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/ProxiedCloneMethod.php @@ -12,7 +12,7 @@ namespace PHPUnit\Framework\MockObject; /** * @internal This trait is not covered by the backward compatibility promise for PHPUnit */ -trait UnmockedCloneMethod +trait ProxiedCloneMethod { public function __clone(): void { diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Api/Api.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/StubApi.php similarity index 55% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Api/Api.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/StubApi.php index ce1fb3d9..64bed690 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Api/Api.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Api/StubApi.php @@ -9,40 +9,24 @@ */ namespace PHPUnit\Framework\MockObject; -use PHPUnit\Framework\MockObject\Builder\InvocationMocker as InvocationMockerBuilder; -use PHPUnit\Framework\MockObject\Rule\InvocationOrder; - /** * @internal This trait is not covered by the backward compatibility promise for PHPUnit */ -trait Api +trait StubApi { /** * @psalm-var list */ private static array $__phpunit_configurableMethods; - private object $__phpunit_originalObject; private bool $__phpunit_returnValueGeneration = true; private ?InvocationHandler $__phpunit_invocationMocker = null; /** @noinspection MagicMethodsValidityInspection */ public static function __phpunit_initConfigurableMethods(ConfigurableMethod ...$configurableMethods): void { - if (isset(static::$__phpunit_configurableMethods)) { - throw new ConfigurableMethodsAlreadyInitializedException( - 'Configurable methods is already initialized and can not be reinitialized' - ); - } - static::$__phpunit_configurableMethods = $configurableMethods; } - /** @noinspection MagicMethodsValidityInspection */ - public function __phpunit_setOriginalObject(object $originalObject): void - { - $this->__phpunit_originalObject = $originalObject; - } - /** @noinspection MagicMethodsValidityInspection */ public function __phpunit_setReturnValueGeneration(bool $returnValueGeneration): void { @@ -55,7 +39,7 @@ trait Api if ($this->__phpunit_invocationMocker === null) { $this->__phpunit_invocationMocker = new InvocationHandler( static::$__phpunit_configurableMethods, - $this->__phpunit_returnValueGeneration + $this->__phpunit_returnValueGeneration, ); } @@ -63,23 +47,8 @@ trait Api } /** @noinspection MagicMethodsValidityInspection */ - public function __phpunit_hasMatchers(): bool + public function __phpunit_unsetInvocationMocker(): void { - return $this->__phpunit_getInvocationHandler()->hasMatchers(); - } - - /** @noinspection MagicMethodsValidityInspection */ - public function __phpunit_verify(bool $unsetInvocationMocker = true): void - { - $this->__phpunit_getInvocationHandler()->verify(); - - if ($unsetInvocationMocker) { - $this->__phpunit_invocationMocker = null; - } - } - - public function expects(InvocationOrder $matcher): InvocationMockerBuilder - { - return $this->__phpunit_getInvocationHandler()->expects($matcher); + $this->__phpunit_invocationMocker = null; } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Builder/Identity.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/Identity.php similarity index 100% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Builder/Identity.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/Identity.php diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Builder/InvocationMocker.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/InvocationMocker.php similarity index 80% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Builder/InvocationMocker.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/InvocationMocker.php index ac5415f7..fbff6cbd 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Builder/InvocationMocker.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/InvocationMocker.php @@ -13,10 +13,14 @@ use function array_flip; use function array_key_exists; use function array_map; use function array_merge; +use function array_pop; +use function assert; use function count; use function is_string; +use function range; use function strtolower; use PHPUnit\Framework\Constraint\Constraint; +use PHPUnit\Framework\InvalidArgumentException; use PHPUnit\Framework\MockObject\ConfigurableMethod; use PHPUnit\Framework\MockObject\IncompatibleReturnValueException; use PHPUnit\Framework\MockObject\InvocationHandler; @@ -94,14 +98,16 @@ final class InvocationMocker implements InvocationStubber, MethodNameMatch $this->ensureTypeOfReturnValues([$value]); $stub = $value instanceof Stub ? $value : new ReturnStub($value); - } else { - $values = array_merge([$value], $nextValues); - $this->ensureTypeOfReturnValues($values); - - $stub = new ConsecutiveCalls($values); + return $this->will($stub); } + $values = array_merge([$value], $nextValues); + + $this->ensureTypeOfReturnValues($values); + + $stub = new ConsecutiveCalls($values); + return $this->will($stub); } @@ -114,7 +120,45 @@ final class InvocationMocker implements InvocationStubber, MethodNameMatch public function willReturnMap(array $valueMap): self { - $stub = new ReturnValueMap($valueMap); + $method = $this->configuredMethod(); + + assert($method instanceof ConfigurableMethod); + + $numberOfParameters = $method->numberOfParameters(); + $defaultValues = $method->defaultParameterValues(); + $hasDefaultValues = !empty($defaultValues); + + $_valueMap = []; + + foreach ($valueMap as $mapping) { + $numberOfConfiguredParameters = count($mapping) - 1; + + if ($numberOfConfiguredParameters === $numberOfParameters || !$hasDefaultValues) { + $_valueMap[] = $mapping; + + continue; + } + + $_mapping = []; + $returnValue = array_pop($mapping); + + foreach (range(0, $numberOfParameters - 1) as $i) { + if (isset($mapping[$i])) { + $_mapping[] = $mapping[$i]; + + continue; + } + + if (isset($defaultValues[$i])) { + $_mapping[] = $defaultValues[$i]; + } + } + + $_mapping[] = $returnValue; + $_valueMap[] = $_mapping; + } + + $stub = new ReturnValueMap($_valueMap); return $this->will($stub); } @@ -196,7 +240,7 @@ final class InvocationMocker implements InvocationStubber, MethodNameMatch } /** - * @throws \PHPUnit\Framework\InvalidArgumentException + * @throws InvalidArgumentException * @throws MethodCannotBeConfiguredException * @throws MethodNameAlreadyConfiguredException * @@ -209,10 +253,12 @@ final class InvocationMocker implements InvocationStubber, MethodNameMatch } if (is_string($constraint)) { - $this->configurableMethodNames ??= array_flip(array_map( - static fn (ConfigurableMethod $configurable) => strtolower($configurable->name()), - $this->configurableMethods - )); + $this->configurableMethodNames ??= array_flip( + array_map( + static fn (ConfigurableMethod $configurable) => strtolower($configurable->name()), + $this->configurableMethods, + ), + ); if (!array_key_exists(strtolower($constraint), $this->configurableMethodNames)) { throw new MethodCannotBeConfiguredException($constraint); @@ -271,7 +317,7 @@ final class InvocationMocker implements InvocationStubber, MethodNameMatch if (!$configuredMethod->mayReturn($value)) { throw new IncompatibleReturnValueException( $configuredMethod, - $value + $value, ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Builder/InvocationStubber.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/InvocationStubber.php similarity index 100% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Builder/InvocationStubber.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/InvocationStubber.php diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Builder/MethodNameMatch.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/MethodNameMatch.php similarity index 100% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Builder/MethodNameMatch.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/MethodNameMatch.php diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Builder/ParametersMatch.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/ParametersMatch.php similarity index 100% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Builder/ParametersMatch.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/ParametersMatch.php diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Builder/Stub.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/Stub.php similarity index 100% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Builder/Stub.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Builder/Stub.php diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/MockObject.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/MockObject.php similarity index 56% rename from vendor/phpunit/phpunit/src/Framework/MockObject/MockObject.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/MockObject.php index 5fc9687c..4096d73f 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/MockObject.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/MockObject.php @@ -9,19 +9,15 @@ */ namespace PHPUnit\Framework\MockObject; -use PHPUnit\Framework\MockObject\Builder\InvocationMocker as BuilderInvocationMocker; +use PHPUnit\Framework\MockObject\Builder\InvocationMocker; use PHPUnit\Framework\MockObject\Rule\InvocationOrder; /** - * @method BuilderInvocationMocker method($constraint) + * @method InvocationMocker method($constraint) * * @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit */ interface MockObject extends Stub { - public function __phpunit_setOriginalObject(object $originalObject): void; - - public function __phpunit_verify(bool $unsetInvocationMocker = true): void; - - public function expects(InvocationOrder $invocationRule): BuilderInvocationMocker; + public function expects(InvocationOrder $invocationRule): InvocationMocker; } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/MockObjectInternal.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/MockObjectInternal.php new file mode 100644 index 00000000..bb84ffac --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/MockObjectInternal.php @@ -0,0 +1,22 @@ + + * + * 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 interface is not covered by the backward compatibility promise for PHPUnit + */ +interface MockObjectInternal extends MockObject, StubInternal +{ + public function __phpunit_hasMatchers(): bool; + + public function __phpunit_setOriginalObject(object $originalObject): void; + + public function __phpunit_verify(bool $unsetInvocationMocker = true): void; +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/Stub.php similarity index 71% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Stub.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/Stub.php index 2b032e2d..96f84d23 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/Stub.php @@ -18,9 +18,4 @@ use PHPUnit\Framework\MockObject\Builder\InvocationStubber; */ interface Stub { - public function __phpunit_getInvocationHandler(): InvocationHandler; - - public function __phpunit_hasMatchers(): bool; - - public function __phpunit_setReturnValueGeneration(bool $returnValueGeneration): void; } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/StubInternal.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/StubInternal.php new file mode 100644 index 00000000..79cc6a27 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Interface/StubInternal.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 PHPUnit\Framework\MockObject; + +/** + * @internal This interface is not covered by the backward compatibility promise for PHPUnit + */ +interface StubInternal extends Stub +{ + public static function __phpunit_initConfigurableMethods(ConfigurableMethod ...$configurableMethods): void; + + public function __phpunit_getInvocationHandler(): InvocationHandler; + + public function __phpunit_setReturnValueGeneration(bool $returnValueGeneration): void; + + public function __phpunit_unsetInvocationMocker(): void; +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Invocation.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Invocation.php new file mode 100644 index 00000000..e3dbefd4 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Invocation.php @@ -0,0 +1,150 @@ + + * + * 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 array_map; +use function implode; +use function is_object; +use function sprintf; +use function str_starts_with; +use function strtolower; +use function substr; +use PHPUnit\Framework\SelfDescribing; +use PHPUnit\Util\Cloner; +use SebastianBergmann\Exporter\Exporter; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class Invocation implements SelfDescribing +{ + /** + * @psalm-var class-string + */ + private readonly string $className; + + /** + * @psalm-var non-empty-string + */ + private readonly string $methodName; + private readonly array $parameters; + private readonly string $returnType; + private readonly bool $isReturnTypeNullable; + private readonly bool $proxiedCall; + private readonly MockObjectInternal|StubInternal $object; + + /** + * @psalm-param class-string $className + * @psalm-param non-empty-string $methodName + */ + public function __construct(string $className, string $methodName, array $parameters, string $returnType, MockObjectInternal|StubInternal $object, bool $cloneObjects = false, bool $proxiedCall = false) + { + $this->className = $className; + $this->methodName = $methodName; + $this->object = $object; + $this->proxiedCall = $proxiedCall; + + if (strtolower($methodName) === '__tostring') { + $returnType = 'string'; + } + + if (str_starts_with($returnType, '?')) { + $returnType = substr($returnType, 1); + $this->isReturnTypeNullable = true; + } else { + $this->isReturnTypeNullable = false; + } + + $this->returnType = $returnType; + + if (!$cloneObjects) { + $this->parameters = $parameters; + + return; + } + + foreach ($parameters as $key => $value) { + if (is_object($value)) { + $parameters[$key] = Cloner::clone($value); + } + } + + $this->parameters = $parameters; + } + + /** + * @psalm-return class-string + */ + public function className(): string + { + return $this->className; + } + + /** + * @psalm-return non-empty-string + */ + public function methodName(): string + { + return $this->methodName; + } + + public function parameters(): array + { + return $this->parameters; + } + + /** + * @throws Exception + */ + public function generateReturnValue(): mixed + { + if ($this->returnType === 'never') { + throw new NeverReturningMethodException( + $this->className, + $this->methodName, + ); + } + + if ($this->isReturnTypeNullable || $this->proxiedCall) { + return null; + } + + return (new ReturnValueGenerator)->generate( + $this->className, + $this->methodName, + $this->object::class, + $this->returnType, + ); + } + + public function toString(): string + { + $exporter = new Exporter; + + return sprintf( + '%s::%s(%s)%s', + $this->className, + $this->methodName, + implode( + ', ', + array_map( + [$exporter, 'shortenedExport'], + $this->parameters, + ), + ), + $this->returnType ? sprintf(': %s', $this->returnType) : '', + ); + } + + public function object(): MockObjectInternal|StubInternal + { + return $this->object; + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/InvocationHandler.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/InvocationHandler.php similarity index 86% rename from vendor/phpunit/phpunit/src/Framework/MockObject/InvocationHandler.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/InvocationHandler.php index 2c4c5a86..45baebbb 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/InvocationHandler.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/InvocationHandler.php @@ -35,7 +35,6 @@ final class InvocationHandler */ private readonly array $configurableMethods; private readonly bool $returnValueGeneration; - private ?ReturnValueNotConfiguredException $deferredError = null; /** * @psalm-param list $configurableMethods @@ -88,7 +87,7 @@ final class InvocationHandler return new InvocationMocker( $this, $matcher, - ...$this->configurableMethods + ...$this->configurableMethods, ); } @@ -126,31 +125,16 @@ final class InvocationHandler } if (!$this->returnValueGeneration) { - $exception = new ReturnValueNotConfiguredException($invocation); - if (strtolower($invocation->methodName()) === '__tostring') { - $this->deferredError = $exception; - return ''; } - throw $exception; + throw new ReturnValueNotConfiguredException($invocation); } return $invocation->generateReturnValue(); } - public function matches(Invocation $invocation): bool - { - foreach ($this->matchers as $matcher) { - if (!$matcher->matches($invocation)) { - return false; - } - } - - return true; - } - /** * @throws Throwable */ @@ -159,10 +143,6 @@ final class InvocationHandler foreach ($this->matchers as $matcher) { $matcher->verify(); } - - if ($this->deferredError) { - throw $this->deferredError; - } } private function addMatcher(Matcher $matcher): void diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Matcher.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Matcher.php similarity index 82% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Matcher.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Matcher.php index 55763024..f53c1d9f 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Matcher.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Matcher.php @@ -9,8 +9,6 @@ */ namespace PHPUnit\Framework\MockObject; -use function assert; -use function implode; use function sprintf; use PHPUnit\Framework\ExpectationFailedException; use PHPUnit\Framework\MockObject\Rule\AnyInvokedCount; @@ -94,8 +92,8 @@ final class Matcher if ($this->afterMatchBuilderId !== null) { $matcher = $invocation->object() - ->__phpunit_getInvocationHandler() - ->lookupMatcher($this->afterMatchBuilderId); + ->__phpunit_getInvocationHandler() + ->lookupMatcher($this->afterMatchBuilderId); if (!$matcher) { throw new MatchBuilderNotFoundException($this->afterMatchBuilderId); @@ -112,9 +110,9 @@ final class Matcher "Expectation failed for %s when %s\n%s", $this->methodNameRule->toString(), $this->invocationRule->toString(), - $e->getMessage() + $e->getMessage(), ), - $e->getComparisonFailure() + $e->getComparisonFailure(), ); } @@ -135,15 +133,13 @@ final class Matcher { if ($this->afterMatchBuilderId !== null) { $matcher = $invocation->object() - ->__phpunit_getInvocationHandler() - ->lookupMatcher($this->afterMatchBuilderId); + ->__phpunit_getInvocationHandler() + ->lookupMatcher($this->afterMatchBuilderId); if (!$matcher) { throw new MatchBuilderNotFoundException($this->afterMatchBuilderId); } - assert($matcher instanceof self); - if (!$matcher->invocationRule->hasBeenInvoked()) { return false; } @@ -167,9 +163,9 @@ final class Matcher "Expectation failed for %s when %s\n%s", $this->methodNameRule->toString(), $this->invocationRule->toString(), - $e->getMessage() + $e->getMessage(), ), - $e->getComparisonFailure() + $e->getComparisonFailure(), ); } @@ -206,32 +202,9 @@ final class Matcher "Expectation failed for %s when %s.\n%s", $this->methodNameRule->toString(), $this->invocationRule->toString(), - ThrowableToStringMapper::map($e) - ) + ThrowableToStringMapper::map($e), + ), ); } } - - public function toString(): string - { - $list = [$this->invocationRule->toString()]; - - if ($this->methodNameRule !== null) { - $list[] = 'where ' . $this->methodNameRule->toString(); - } - - if ($this->parametersRule !== null) { - $list[] = 'and ' . $this->parametersRule->toString(); - } - - if ($this->afterMatchBuilderId !== null) { - $list[] = 'after ' . $this->afterMatchBuilderId; - } - - if ($this->stub !== null) { - $list[] = 'will ' . $this->stub->toString(); - } - - return implode(' ', $list); - } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/MethodNameConstraint.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/MethodNameConstraint.php similarity index 81% rename from vendor/phpunit/phpunit/src/Framework/MockObject/MethodNameConstraint.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/MethodNameConstraint.php index 47da874b..450331ec 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/MethodNameConstraint.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/MethodNameConstraint.php @@ -9,7 +9,6 @@ */ namespace PHPUnit\Framework\MockObject; -use function is_string; use function sprintf; use function strtolower; use PHPUnit\Framework\Constraint\Constraint; @@ -30,16 +29,12 @@ final class MethodNameConstraint extends Constraint { return sprintf( 'is "%s"', - $this->methodName + $this->methodName, ); } protected function matches(mixed $other): bool { - if (!is_string($other)) { - return false; - } - - return strtolower($this->methodName) === strtolower($other); + return strtolower($this->methodName) === strtolower((string) $other); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/ReturnValueGenerator.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/ReturnValueGenerator.php new file mode 100644 index 00000000..8ae64c9b --- /dev/null +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/ReturnValueGenerator.php @@ -0,0 +1,242 @@ + + * + * 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 array_keys; +use function array_map; +use function explode; +use function in_array; +use function interface_exists; +use function sprintf; +use function str_contains; +use function str_ends_with; +use function str_starts_with; +use function substr; +use PHPUnit\Framework\MockObject\Generator\Generator; +use ReflectionClass; +use stdClass; +use Throwable; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class ReturnValueGenerator +{ + /** + * @psalm-param class-string $className + * @psalm-param non-empty-string $methodName + * @psalm-param class-string $stubClassName + * + * @throws Exception + */ + public function generate(string $className, string $methodName, string $stubClassName, string $returnType): mixed + { + $intersection = false; + $union = false; + + if (str_contains($returnType, '|')) { + $types = explode('|', $returnType); + $union = true; + + foreach (array_keys($types) as $key) { + if (str_starts_with($types[$key], '(') && str_ends_with($types[$key], ')')) { + $types[$key] = substr($types[$key], 1, -1); + } + } + } elseif (str_contains($returnType, '&')) { + $types = explode('&', $returnType); + $intersection = true; + } else { + $types = [$returnType]; + } + + $types = array_map('strtolower', $types); + + if (!$intersection) { + if (in_array('', $types, true) || + in_array('null', $types, true) || + in_array('mixed', $types, true) || + in_array('void', $types, true)) { + return null; + } + + if (in_array('true', $types, true)) { + return true; + } + + if (in_array('false', $types, true) || + in_array('bool', $types, true)) { + return false; + } + + if (in_array('float', $types, true)) { + return 0.0; + } + + if (in_array('int', $types, true)) { + return 0; + } + + if (in_array('string', $types, true)) { + return ''; + } + + if (in_array('array', $types, true)) { + return []; + } + + if (in_array('static', $types, true)) { + return $this->newInstanceOf($stubClassName, $className, $methodName); + } + + if (in_array('object', $types, true)) { + return new stdClass; + } + + if (in_array('callable', $types, true) || + in_array('closure', $types, true)) { + return static function (): void + { + }; + } + + if (in_array('traversable', $types, true) || + in_array('generator', $types, true) || + in_array('iterable', $types, true)) { + $generator = static function (): \Generator + { + yield from []; + }; + + return $generator(); + } + + if (!$union) { + return $this->testDoubleFor($returnType, $className, $methodName); + } + } + + if ($union) { + foreach ($types as $type) { + if (str_contains($type, '&')) { + $_types = explode('&', $type); + + if ($this->onlyInterfaces($_types)) { + return $this->testDoubleForIntersectionOfInterfaces($_types, $className, $methodName); + } + } + } + } + + if ($intersection && $this->onlyInterfaces($types)) { + return $this->testDoubleForIntersectionOfInterfaces($types, $className, $methodName); + } + + $reason = ''; + + if ($union) { + $reason = ' because the declared return type is a union'; + } elseif ($intersection) { + $reason = ' because the declared return type is an intersection'; + } + + throw new RuntimeException( + sprintf( + 'Return value for %s::%s() cannot be generated%s, please configure a return value for this method', + $className, + $methodName, + $reason, + ), + ); + } + + /** + * @psalm-param non-empty-list $types + */ + private function onlyInterfaces(array $types): bool + { + foreach ($types as $type) { + if (!interface_exists($type)) { + return false; + } + } + + return true; + } + + /** + * @psalm-param class-string $stubClassName + * @psalm-param class-string $className + * @psalm-param non-empty-string $methodName + * + * @throws RuntimeException + */ + private function newInstanceOf(string $stubClassName, string $className, string $methodName): Stub + { + try { + return (new ReflectionClass($stubClassName))->newInstanceWithoutConstructor(); + } catch (Throwable $t) { + throw new RuntimeException( + sprintf( + 'Return value for %s::%s() cannot be generated: %s', + $className, + $methodName, + $t->getMessage(), + ), + ); + } + } + + /** + * @psalm-param class-string $type + * @psalm-param class-string $className + * @psalm-param non-empty-string $methodName + * + * @throws RuntimeException + */ + private function testDoubleFor(string $type, string $className, string $methodName): Stub + { + try { + return (new Generator)->testDouble($type, false, [], [], '', false); + } catch (Throwable $t) { + throw new RuntimeException( + sprintf( + 'Return value for %s::%s() cannot be generated: %s', + $className, + $methodName, + $t->getMessage(), + ), + ); + } + } + + /** + * @psalm-param non-empty-list $types + * @psalm-param class-string $className + * @psalm-param non-empty-string $methodName + * + * @throws RuntimeException + */ + private function testDoubleForIntersectionOfInterfaces(array $types, string $className, string $methodName): Stub + { + try { + return (new Generator)->testDoubleForInterfaceIntersection($types, false); + } catch (Throwable $t) { + throw new RuntimeException( + sprintf( + 'Return value for %s::%s() cannot be generated: %s', + $className, + $methodName, + $t->getMessage(), + ), + ); + } + } +} diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/AnyInvokedCount.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/AnyInvokedCount.php similarity index 100% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Rule/AnyInvokedCount.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/AnyInvokedCount.php diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/AnyParameters.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/AnyParameters.php similarity index 87% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Rule/AnyParameters.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/AnyParameters.php index 61de7887..75232027 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/AnyParameters.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/AnyParameters.php @@ -16,11 +16,6 @@ use PHPUnit\Framework\MockObject\Invocation as BaseInvocation; */ final class AnyParameters implements ParametersRule { - public function toString(): string - { - return 'with any parameters'; - } - public function apply(BaseInvocation $invocation): void { } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/InvocationOrder.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvocationOrder.php similarity index 90% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Rule/InvocationOrder.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvocationOrder.php index 62292288..2d7a7d25 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/InvocationOrder.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvocationOrder.php @@ -11,13 +11,12 @@ namespace PHPUnit\Framework\MockObject\Rule; use function count; use PHPUnit\Framework\MockObject\Invocation as BaseInvocation; -use PHPUnit\Framework\MockObject\Verifiable; use PHPUnit\Framework\SelfDescribing; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ -abstract class InvocationOrder implements SelfDescribing, Verifiable +abstract class InvocationOrder implements SelfDescribing { /** * @psalm-var list @@ -43,6 +42,8 @@ abstract class InvocationOrder implements SelfDescribing, Verifiable abstract public function matches(BaseInvocation $invocation): bool; + abstract public function verify(): void; + protected function invokedDo(BaseInvocation $invocation): void { } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedAtLeastCount.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvokedAtLeastCount.php similarity index 65% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedAtLeastCount.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvokedAtLeastCount.php index 757b7f73..d6d251bd 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedAtLeastCount.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvokedAtLeastCount.php @@ -9,6 +9,7 @@ */ namespace PHPUnit\Framework\MockObject\Rule; +use function sprintf; use PHPUnit\Framework\ExpectationFailedException; use PHPUnit\Framework\MockObject\Invocation as BaseInvocation; @@ -26,7 +27,11 @@ final class InvokedAtLeastCount extends InvocationOrder public function toString(): string { - return 'invoked at least ' . $this->requiredInvocations . ' times'; + return sprintf( + 'invoked at least %d time%s', + $this->requiredInvocations, + $this->requiredInvocations !== 1 ? 's' : '', + ); } /** @@ -37,12 +42,17 @@ final class InvokedAtLeastCount extends InvocationOrder */ public function verify(): void { - $count = $this->numberOfInvocations(); + $actualInvocations = $this->numberOfInvocations(); - if ($count < $this->requiredInvocations) { + if ($actualInvocations < $this->requiredInvocations) { throw new ExpectationFailedException( - 'Expected invocation at least ' . $this->requiredInvocations . - ' times but it occurred ' . $count . ' time(s).' + sprintf( + 'Expected invocation at least %d time%s but it occurred %d time%s.', + $this->requiredInvocations, + $this->requiredInvocations !== 1 ? 's' : '', + $actualInvocations, + $actualInvocations !== 1 ? 's' : '', + ), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedAtLeastOnce.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvokedAtLeastOnce.php similarity index 99% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedAtLeastOnce.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvokedAtLeastOnce.php index 19e1cff5..efe51838 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedAtLeastOnce.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvokedAtLeastOnce.php @@ -34,7 +34,7 @@ final class InvokedAtLeastOnce extends InvocationOrder if ($count < 1) { throw new ExpectationFailedException( - 'Expected invocation at least once but it never occurred.' + 'Expected invocation at least once but it never occurred.', ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedAtMostCount.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvokedAtMostCount.php similarity index 65% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedAtMostCount.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvokedAtMostCount.php index 6000c0b1..64ed9403 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedAtMostCount.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvokedAtMostCount.php @@ -9,6 +9,7 @@ */ namespace PHPUnit\Framework\MockObject\Rule; +use function sprintf; use PHPUnit\Framework\ExpectationFailedException; use PHPUnit\Framework\MockObject\Invocation as BaseInvocation; @@ -26,7 +27,11 @@ final class InvokedAtMostCount extends InvocationOrder public function toString(): string { - return 'invoked at most ' . $this->allowedInvocations . ' times'; + return sprintf( + 'invoked at most %d time%s', + $this->allowedInvocations, + $this->allowedInvocations !== 1 ? 's' : '', + ); } /** @@ -37,12 +42,17 @@ final class InvokedAtMostCount extends InvocationOrder */ public function verify(): void { - $count = $this->numberOfInvocations(); + $actualInvocations = $this->numberOfInvocations(); - if ($count > $this->allowedInvocations) { + if ($actualInvocations > $this->allowedInvocations) { throw new ExpectationFailedException( - 'Expected invocation at most ' . $this->allowedInvocations . - ' times but it occurred ' . $count . ' time(s).' + sprintf( + 'Expected invocation at most %d time%s but it occurred %d time%s.', + $this->allowedInvocations, + $this->allowedInvocations !== 1 ? 's' : '', + $actualInvocations, + $actualInvocations !== 1 ? 's' : '', + ), ); } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedCount.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvokedCount.php similarity index 78% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedCount.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvokedCount.php index f80401a5..638317ca 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/InvokedCount.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/InvokedCount.php @@ -32,7 +32,11 @@ final class InvokedCount extends InvocationOrder public function toString(): string { - return 'invoked ' . $this->expectedCount . ' time(s)'; + return sprintf( + 'invoked %d time%s', + $this->expectedCount, + $this->expectedCount !== 1 ? 's' : '', + ); } public function matches(BaseInvocation $invocation): bool @@ -48,16 +52,17 @@ final class InvokedCount extends InvocationOrder */ public function verify(): void { - $count = $this->numberOfInvocations(); + $actualCount = $this->numberOfInvocations(); - if ($count !== $this->expectedCount) { + if ($actualCount !== $this->expectedCount) { throw new ExpectationFailedException( sprintf( - 'Method was expected to be called %d times, ' . - 'actually called %d times.', + 'Method was expected to be called %d time%s, actually called %d time%s.', $this->expectedCount, - $count - ) + $this->expectedCount !== 1 ? 's' : '', + $actualCount, + $actualCount !== 1 ? 's' : '', + ), ); } } @@ -77,7 +82,7 @@ final class InvokedCount extends InvocationOrder 1 => 'was not expected to be called more than once.', default => sprintf( 'was not expected to be called more than %d times.', - $this->expectedCount + $this->expectedCount, ), }; diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/MethodName.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/MethodName.php similarity index 100% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Rule/MethodName.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/MethodName.php diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/Parameters.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/Parameters.php similarity index 90% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Rule/Parameters.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/Parameters.php index 3761973c..4119a0ec 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/Parameters.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/Parameters.php @@ -38,7 +38,7 @@ final class Parameters implements ParametersRule foreach ($parameters as $parameter) { if (!($parameter instanceof Constraint)) { $parameter = new IsEqual( - $parameter + $parameter, ); } @@ -46,21 +46,6 @@ final class Parameters implements ParametersRule } } - public function toString(): string - { - $text = 'with parameter'; - - foreach ($this->parameters as $index => $parameter) { - if ($index > 0) { - $text .= ' and'; - } - - $text .= ' ' . $index . ' ' . $parameter->toString(); - } - - return $text; - } - /** * @throws Exception */ @@ -116,7 +101,7 @@ final class Parameters implements ParametersRule } throw new ExpectationFailedException( - sprintf($message, $this->invocation->toString()) + sprintf($message, $this->invocation->toString()), ); } @@ -127,8 +112,8 @@ final class Parameters implements ParametersRule 'Parameter %s for invocation %s does not match expected ' . 'value.', $i, - $this->invocation->toString() - ) + $this->invocation->toString(), + ), ); } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/ParametersRule.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/ParametersRule.php similarity index 83% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Rule/ParametersRule.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/ParametersRule.php index 70c47fe3..03cfe2a4 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Rule/ParametersRule.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Rule/ParametersRule.php @@ -11,13 +11,11 @@ namespace PHPUnit\Framework\MockObject\Rule; use PHPUnit\Framework\ExpectationFailedException; 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 +interface ParametersRule { /** * @throws ExpectationFailedException if the invocation violates the rule diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub/ConsecutiveCalls.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ConsecutiveCalls.php similarity index 59% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Stub/ConsecutiveCalls.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ConsecutiveCalls.php index 164ebfa1..155226ee 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub/ConsecutiveCalls.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ConsecutiveCalls.php @@ -10,9 +10,7 @@ namespace PHPUnit\Framework\MockObject\Stub; use function array_shift; -use function sprintf; use PHPUnit\Framework\MockObject\Invocation; -use SebastianBergmann\Exporter\Exporter; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit @@ -20,7 +18,6 @@ use SebastianBergmann\Exporter\Exporter; final class ConsecutiveCalls implements Stub { private array $stack; - private mixed $value; public function __construct(array $stack) { @@ -29,22 +26,12 @@ final class ConsecutiveCalls implements Stub public function invoke(Invocation $invocation): mixed { - $this->value = array_shift($this->stack); + $value = array_shift($this->stack); - if ($this->value instanceof Stub) { - $this->value = $this->value->invoke($invocation); + if ($value instanceof Stub) { + $value = $value->invoke($invocation); } - return $this->value; - } - - public function toString(): string - { - $exporter = new Exporter; - - return sprintf( - 'return user-specified value %s', - $exporter->export($this->value) - ); + return $value; } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub/Exception.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/Exception.php similarity index 73% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Stub/Exception.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/Exception.php index 228a4ae7..c2b349ca 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub/Exception.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/Exception.php @@ -9,9 +9,7 @@ */ namespace PHPUnit\Framework\MockObject\Stub; -use function sprintf; use PHPUnit\Framework\MockObject\Invocation; -use SebastianBergmann\Exporter\Exporter; use Throwable; /** @@ -33,14 +31,4 @@ final class Exception implements Stub { throw $this->exception; } - - public function toString(): string - { - $exporter = new Exporter; - - return sprintf( - 'raise user-specified exception %s', - $exporter->export($this->exception) - ); - } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnArgument.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnArgument.php similarity index 84% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnArgument.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnArgument.php index d3cf7c3c..4b28813c 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnArgument.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnArgument.php @@ -9,7 +9,6 @@ */ namespace PHPUnit\Framework\MockObject\Stub; -use function sprintf; use PHPUnit\Framework\MockObject\Invocation; /** @@ -28,9 +27,4 @@ final class ReturnArgument implements Stub { return $invocation->parameters()[$this->argumentIndex] ?? null; } - - public function toString(): string - { - return sprintf('return argument #%d', $this->argumentIndex); - } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnCallback.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnCallback.php similarity index 51% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnCallback.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnCallback.php index eb783c6a..be4a0151 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnCallback.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnCallback.php @@ -10,9 +10,6 @@ namespace PHPUnit\Framework\MockObject\Stub; use function call_user_func_array; -use function is_array; -use function is_object; -use function sprintf; use PHPUnit\Framework\MockObject\Invocation; /** @@ -34,28 +31,4 @@ final class ReturnCallback implements Stub { return call_user_func_array($this->callback, $invocation->parameters()); } - - public function toString(): string - { - if (is_array($this->callback)) { - if (is_object($this->callback[0])) { - $class = $this->callback[0]::class; - $type = '->'; - } else { - $class = $this->callback[0]; - $type = '::'; - } - - return sprintf( - 'return result of user defined callback %s%s%s() with the ' . - 'passed arguments', - $class, - $type, - $this->callback[1] - ); - } - - return 'return result of user defined callback ' . $this->callback . - ' with the passed arguments'; - } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnReference.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnReference.php similarity index 72% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnReference.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnReference.php index 45bab37e..fd9e34de 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnReference.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnReference.php @@ -9,9 +9,7 @@ */ namespace PHPUnit\Framework\MockObject\Stub; -use function sprintf; use PHPUnit\Framework\MockObject\Invocation; -use SebastianBergmann\Exporter\Exporter; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit @@ -29,14 +27,4 @@ final class ReturnReference implements Stub { return $this->reference; } - - public function toString(): string - { - $exporter = new Exporter; - - return sprintf( - 'return user-specified reference %s', - $exporter->export($this->reference) - ); - } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnSelf.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnSelf.php similarity index 87% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnSelf.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnSelf.php index db5ed288..059ef18b 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnSelf.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnSelf.php @@ -24,9 +24,4 @@ final class ReturnSelf implements Stub { return $invocation->object(); } - - public function toString(): string - { - return 'return the current object'; - } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnStub.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnStub.php similarity index 72% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnStub.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnStub.php index 01875436..d810ceba 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnStub.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnStub.php @@ -9,9 +9,7 @@ */ namespace PHPUnit\Framework\MockObject\Stub; -use function sprintf; use PHPUnit\Framework\MockObject\Invocation; -use SebastianBergmann\Exporter\Exporter; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit @@ -29,14 +27,4 @@ final class ReturnStub implements Stub { return $this->value; } - - public function toString(): string - { - $exporter = new Exporter; - - return sprintf( - 'return user-specified value %s', - $exporter->export($this->value) - ); - } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnValueMap.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnValueMap.php similarity index 92% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnValueMap.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnValueMap.php index b8fb66df..2cdf1604 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub/ReturnValueMap.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/ReturnValueMap.php @@ -44,9 +44,4 @@ final class ReturnValueMap implements Stub return null; } - - public function toString(): string - { - return 'return value from a map'; - } } diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub/Stub.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/Stub.php similarity index 89% rename from vendor/phpunit/phpunit/src/Framework/MockObject/Stub/Stub.php rename to vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/Stub.php index 96958407..e889adfe 100644 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Stub/Stub.php +++ b/vendor/phpunit/phpunit/src/Framework/MockObject/Runtime/Stub/Stub.php @@ -10,12 +10,11 @@ namespace PHPUnit\Framework\MockObject\Stub; use PHPUnit\Framework\MockObject\Invocation; -use PHPUnit\Framework\SelfDescribing; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit */ -interface Stub extends SelfDescribing +interface Stub { /** * Fakes the processing of the invocation $invocation by returning a diff --git a/vendor/phpunit/phpunit/src/Framework/MockObject/Verifiable.php b/vendor/phpunit/phpunit/src/Framework/MockObject/Verifiable.php deleted file mode 100644 index 8c9a82c5..00000000 --- a/vendor/phpunit/phpunit/src/Framework/MockObject/Verifiable.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 PHPUnit\Framework\MockObject; - -use PHPUnit\Framework\ExpectationFailedException; - -/** - * @internal This class is not covered by the backward compatibility promise for PHPUnit - */ -interface Verifiable -{ - /** - * Verifies that the current expectation is valid. If everything is OK the - * code should just return, if not it must throw an exception. - * - * @throws ExpectationFailedException - */ - public function verify(): void; -} diff --git a/vendor/phpunit/phpunit/src/Framework/TestBuilder.php b/vendor/phpunit/phpunit/src/Framework/TestBuilder.php index 551e26e9..8e5e019d 100644 --- a/vendor/phpunit/phpunit/src/Framework/TestBuilder.php +++ b/vendor/phpunit/phpunit/src/Framework/TestBuilder.php @@ -37,44 +37,45 @@ final class TestBuilder $data = (new DataProvider)->providedData( $className, - $methodName + $methodName, ); if ($data !== null) { - $test = $this->buildDataProviderTestSuite( + return $this->buildDataProviderTestSuite( $methodName, $className, $data, $this->shouldTestMethodBeRunInSeparateProcess($className, $methodName), $this->shouldGlobalStateBePreserved($className, $methodName), $this->shouldAllTestMethodsOfTestClassBeRunInSingleSeparateProcess($className), - $this->backupSettings($className, $methodName) + $this->backupSettings($className, $methodName), ); - } else { - $test = new $className($methodName); } - if ($test instanceof TestCase) { - $this->configureTestCase( - $test, - $this->shouldTestMethodBeRunInSeparateProcess($className, $methodName), - $this->shouldGlobalStateBePreserved($className, $methodName), - $this->shouldAllTestMethodsOfTestClassBeRunInSingleSeparateProcess($className), - $this->backupSettings($className, $methodName) - ); - } + $test = new $className($methodName); + + assert($test instanceof TestCase); + + $this->configureTestCase( + $test, + $this->shouldTestMethodBeRunInSeparateProcess($className, $methodName), + $this->shouldGlobalStateBePreserved($className, $methodName), + $this->shouldAllTestMethodsOfTestClassBeRunInSingleSeparateProcess($className), + $this->backupSettings($className, $methodName), + ); return $test; } /** * @psalm-param class-string $className + * @psalm-param non-empty-string $methodName * @psalm-param array{backupGlobals: ?bool, backupGlobalsExcludeList: list, backupStaticProperties: ?bool, backupStaticPropertiesExcludeList: array>} $backupSettings */ private function buildDataProviderTestSuite(string $methodName, string $className, array $data, bool $runTestInSeparateProcess, ?bool $preserveGlobalState, bool $runClassInSeparateProcess, array $backupSettings): DataProviderTestSuite { $dataProviderTestSuite = DataProviderTestSuite::empty( - $className . '::' . $methodName + $className . '::' . $methodName, ); $groups = (new Groups)->groups($className, $methodName); @@ -91,7 +92,7 @@ final class TestBuilder $runTestInSeparateProcess, $preserveGlobalState, $runClassInSeparateProcess, - $backupSettings + $backupSettings, ); $dataProviderTestSuite->addTest($_test, $groups); @@ -136,6 +137,7 @@ final class TestBuilder /** * @psalm-param class-string $className + * @psalm-param non-empty-string $methodName * * @psalm-return array{backupGlobals: ?bool, backupGlobalsExcludeList: list, backupStaticProperties: ?bool, backupStaticPropertiesExcludeList: array>} */ @@ -184,7 +186,7 @@ final class TestBuilder $backupStaticProperties = true; } } elseif ($metadataForClass->isBackupStaticProperties()->isNotEmpty()) { - $metadata = $metadataForMethod->isBackupStaticProperties()->asArray()[0]; + $metadata = $metadataForClass->isBackupStaticProperties()->asArray()[0]; assert($metadata instanceof BackupStaticProperties); @@ -213,6 +215,7 @@ final class TestBuilder /** * @psalm-param class-string $className + * @psalm-param non-empty-string $methodName */ private function shouldGlobalStateBePreserved(string $className, string $methodName): ?bool { @@ -241,6 +244,7 @@ final class TestBuilder /** * @psalm-param class-string $className + * @psalm-param non-empty-string $methodName */ private function shouldTestMethodBeRunInSeparateProcess(string $className, string $methodName): bool { diff --git a/vendor/phpunit/phpunit/src/Framework/TestCase.php b/vendor/phpunit/phpunit/src/Framework/TestCase.php index 7b4fafb9..51333014 100644 --- a/vendor/phpunit/phpunit/src/Framework/TestCase.php +++ b/vendor/phpunit/phpunit/src/Framework/TestCase.php @@ -18,8 +18,10 @@ use const LC_TIME; use const PATHINFO_FILENAME; use const PHP_EOL; use const PHP_URL_PATH; +use function array_keys; use function array_merge; use function array_values; +use function assert; use function basename; use function chdir; use function class_exists; @@ -58,11 +60,12 @@ use PHPUnit\Event\TestData\MoreThanOneDataSetFromDataProviderException; use PHPUnit\Event\TestData\NoDataSetFromDataProviderException; use PHPUnit\Framework\Constraint\Exception as ExceptionConstraint; use PHPUnit\Framework\Constraint\ExceptionCode; -use PHPUnit\Framework\Constraint\MessageIsOrContains; -use PHPUnit\Framework\Constraint\MessageMatchesRegularExpression; -use PHPUnit\Framework\MockObject\Generator as MockGenerator; +use PHPUnit\Framework\Constraint\ExceptionMessageIsOrContains; +use PHPUnit\Framework\Constraint\ExceptionMessageMatchesRegularExpression; +use PHPUnit\Framework\MockObject\Generator\Generator as MockGenerator; use PHPUnit\Framework\MockObject\MockBuilder; use PHPUnit\Framework\MockObject\MockObject; +use PHPUnit\Framework\MockObject\MockObjectInternal; use PHPUnit\Framework\MockObject\Rule\AnyInvokedCount as AnyInvokedCountMatcher; use PHPUnit\Framework\MockObject\Rule\InvokedAtLeastCount as InvokedAtLeastCountMatcher; use PHPUnit\Framework\MockObject\Rule\InvokedAtLeastOnce as InvokedAtLeastOnceMatcher; @@ -138,6 +141,10 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T private array $providedTests = []; private array $data = []; private int|string $dataName = ''; + + /** + * @psalm-var non-empty-string + */ private string $name; /** @@ -154,12 +161,11 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T /** * @psalm-var array */ - private array $iniSettings = []; - private array $locale = []; - private ?MockGenerator $mockObjectGenerator = null; + private array $iniSettings = []; + private array $locale = []; /** - * @psalm-var list + * @psalm-var list */ private array $mockObjects = []; private bool $registerMockObjectsFromTestArgumentsRecursively = false; @@ -181,6 +187,11 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T private ?Event\Code\TestMethod $testValueObjectForEvents = null; private bool $wasPrepared = false; + /** + * @psalm-var array + */ + private array $failureTypes = []; + /** * Returns a matcher that matches when the method is executed * zero or more times. @@ -205,7 +216,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T final public static function atLeast(int $requiredInvocations): InvokedAtLeastCountMatcher { return new InvokedAtLeastCountMatcher( - $requiredInvocations + $requiredInvocations, ); } @@ -243,30 +254,45 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T return new InvokedAtMostCountMatcher($allowedInvocations); } + /** + * @deprecated Use $double->willReturn() instead of $double->will($this->returnValue()) + * @see https://github.com/sebastianbergmann/phpunit/issues/5423 + */ final public static function returnValue(mixed $value): ReturnStub { return new ReturnStub($value); } + /** + * @deprecated Use $double->willReturnMap() instead of $double->will($this->returnValueMap()) + * @see https://github.com/sebastianbergmann/phpunit/issues/5423 + */ final public static function returnValueMap(array $valueMap): ReturnValueMapStub { return new ReturnValueMapStub($valueMap); } + /** + * @deprecated Use $double->willReturnArgument() instead of $double->will($this->returnArgument()) + * @see https://github.com/sebastianbergmann/phpunit/issues/5423 + */ final public static function returnArgument(int $argumentIndex): ReturnArgumentStub { return new ReturnArgumentStub($argumentIndex); } + /** + * @deprecated Use $double->willReturnCallback() instead of $double->will($this->returnCallback()) + * @see https://github.com/sebastianbergmann/phpunit/issues/5423 + */ final public static function returnCallback(callable $callback): ReturnCallbackStub { return new ReturnCallbackStub($callback); } /** - * Returns the current object. - * - * This method is useful when mocking a fluent interface. + * @deprecated Use $double->willReturnSelf() instead of $double->will($this->returnSelf()) + * @see https://github.com/sebastianbergmann/phpunit/issues/5423 */ final public static function returnSelf(): ReturnSelfStub { @@ -278,12 +304,19 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T return new ExceptionStub($exception); } + /** + * @deprecated Use $double->willReturn() instead of $double->will($this->onConsecutiveCalls()) + * @see https://github.com/sebastianbergmann/phpunit/issues/5423 + * @see https://github.com/sebastianbergmann/phpunit/issues/5425 + */ final public static function onConsecutiveCalls(mixed ...$arguments): ConsecutiveCallsStub { return new ConsecutiveCallsStub($arguments); } /** + * @psalm-param non-empty-string $name + * * @internal This method is not covered by the backward compatibility promise for PHPUnit */ public function __construct(string $name) @@ -343,18 +376,23 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T * Returns a string representation of the test case. * * @throws Exception + * + * @internal This method is not covered by the backward compatibility promise for PHPUnit */ public function toString(): string { $buffer = sprintf( '%s::%s', (new ReflectionClass($this))->getName(), - $this->name + $this->name, ); return $buffer . $this->dataSetAsStringWithData(); } + /** + * @internal This method is not covered by the backward compatibility promise for PHPUnit + */ final public function count(): int { return 1; @@ -417,6 +455,9 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T $this->doesNotPerformAssertions = true; } + /** + * @internal This method is not covered by the backward compatibility promise for PHPUnit + */ final public function status(): TestStatus { return $this->status; @@ -450,7 +491,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T (new TestRunner)->runInSeparateProcess( $this, $this->runClassInSeparateProcess && !$this->runTestInSeparateProcess, - $this->preserveGlobalState + $this->preserveGlobalState, ); } } @@ -469,15 +510,6 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T return new MockBuilder($this, $className); } - final public function registerComparator(Comparator $comparator): void - { - ComparatorFactory::getInstance()->register($comparator); - - Event\Facade::emitter()->testRegisteredComparator($comparator::class); - - $this->customComparators[] = $comparator; - } - /** * @internal This method is not covered by the backward compatibility promise for PHPUnit */ @@ -503,6 +535,8 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T } /** + * @psalm-return non-empty-string + * * @internal This method is not covered by the backward compatibility promise for PHPUnit */ final public function name(): string @@ -517,20 +551,20 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T { return (new Groups)->size( static::class, - $this->name + $this->name, ); } /** * @internal This method is not covered by the backward compatibility promise for PHPUnit */ - final public function hasOutput(): bool + final public function hasUnexpectedOutput(): bool { if ($this->output === '') { return false; } - if ($this->hasExpectationOnOutput()) { + if ($this->expectsOutput()) { return false; } @@ -560,13 +594,15 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T /** * @internal This method is not covered by the backward compatibility promise for PHPUnit */ - final public function hasExpectationOnOutput(): bool + final public function expectsOutput(): bool { - return is_string($this->outputExpectedString) || is_string($this->outputExpectedRegex) || $this->outputRetrievedForAssertion; + return $this->hasExpectationOnOutput() || $this->outputRetrievedForAssertion; } /** * @internal This method is not covered by the backward compatibility promise for PHPUnit + * + * @deprecated */ final public function registerMockObjectsFromTestArgumentsRecursively(): void { @@ -583,7 +619,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T $emitter = Event\Facade::emitter(); $emitter->testPreparationStarted( - $this->valueObjectForEvents() + $this->valueObjectForEvents(), ); $this->snapshotGlobalState(); @@ -604,7 +640,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T } if (method_exists(static::class, $this->name) && - MetadataRegistry::parser()->forMethod(static::class, $this->name)->isDoesNotPerformAssertions()->isNotEmpty()) { + MetadataRegistry::parser()->forClassAndMethod(static::class, $this->name)->isDoesNotPerformAssertions()->isNotEmpty()) { $this->doesNotPerformAssertions = true; } @@ -612,7 +648,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T $this->invokePreConditionHookMethods($hookMethods, $emitter); $emitter->testPrepared( - $this->valueObjectForEvents() + $this->valueObjectForEvents(), ); $this->wasPrepared = true; @@ -627,48 +663,75 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T $emitter->testMarkedAsIncomplete( $this->valueObjectForEvents(), - Event\Code\Throwable::from($e) + Event\Code\ThrowableBuilder::from($e), ); } catch (SkippedTest $e) { $this->status = TestStatus::skipped($e->getMessage()); $emitter->testSkipped( $this->valueObjectForEvents(), - $e->getMessage() + $e->getMessage(), ); } catch (AssertionError|AssertionFailedError $e) { + if (!$this->wasPrepared) { + $this->wasPrepared = true; + + $emitter->testPreparationFailed( + $this->valueObjectForEvents(), + ); + } + $this->status = TestStatus::failure($e->getMessage()); $emitter->testFailed( $this->valueObjectForEvents(), - Event\Code\Throwable::from($e), - Event\Code\ComparisonFailure::from($e) + Event\Code\ThrowableBuilder::from($e), + Event\Code\ComparisonFailureBuilder::from($e), ); } catch (TimeoutException $e) { $this->status = TestStatus::risky($e->getMessage()); } catch (Throwable $_e) { - $e = $_e; - $this->status = TestStatus::error($_e->getMessage()); + if ($this->isRegisteredFailure($_e)) { + $this->status = TestStatus::failure($_e->getMessage()); - $emitter->testErrored( - $this->valueObjectForEvents(), - Event\Code\Throwable::from($_e) - ); + $emitter->testFailed( + $this->valueObjectForEvents(), + Event\Code\ThrowableBuilder::from($_e), + null, + ); + } else { + $e = $this->transformException($_e); + + $this->status = TestStatus::error($e->getMessage()); + + $emitter->testErrored( + $this->valueObjectForEvents(), + Event\Code\ThrowableBuilder::from($e), + ); + } } - if ($this->stopOutputBuffering() && !isset($e)) { + $outputBufferingStopped = false; + + if (!isset($e) && + $this->hasExpectationOnOutput() && + $this->stopOutputBuffering()) { + $outputBufferingStopped = true; + $this->performAssertionsOnOutput(); } if ($this->status->isSuccess()) { - Event\Facade::emitter()->testPassed( + $emitter->testPassed( $this->valueObjectForEvents(), ); - PassedTests::instance()->testMethodPassed( - $this->valueObjectForEvents(), - $this->testResult - ); + if (!$this->usesDataProvider()) { + PassedTests::instance()->testMethodPassed( + $this->valueObjectForEvents(), + $this->testResult, + ); + } } $this->mockObjects = []; @@ -683,12 +746,28 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T $this->invokeAfterClassHookMethods($hookMethods, $emitter); } } - } catch (Throwable $_e) { - $e = $e ?? $_e; + } catch (AssertionError|AssertionFailedError $e) { + $this->status = TestStatus::failure($e->getMessage()); + + $emitter->testFailed( + $this->valueObjectForEvents(), + Event\Code\ThrowableBuilder::from($e), + Event\Code\ComparisonFailureBuilder::from($e), + ); + } catch (Throwable $exceptionRaisedDuringTearDown) { + if (!isset($e)) { + $this->status = TestStatus::error($exceptionRaisedDuringTearDown->getMessage()); + $e = $exceptionRaisedDuringTearDown; + + $emitter->testErrored( + $this->valueObjectForEvents(), + Event\Code\ThrowableBuilder::from($exceptionRaisedDuringTearDown), + ); + } } - if (isset($_e)) { - $this->status = TestStatus::error($_e->getMessage()); + if (!$outputBufferingStopped) { + $this->stopOutputBuffering(); } clearstatcache(); @@ -711,6 +790,8 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T } /** + * @psalm-param non-empty-string $name + * * @internal This method is not covered by the backward compatibility promise for PHPUnit */ final public function setName(string $name): void @@ -851,6 +932,8 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T */ final public function registerMockObject(MockObject $mockObject): void { + assert($mockObject instanceof MockObjectInternal); + $this->mockObjects[] = $mockObject; } @@ -915,7 +998,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T return $this->dataSetAsString() . sprintf( ' (%s)', - (new Exporter)->shortenedRecursiveExport($this->data) + (new Exporter)->shortenedRecursiveExport($this->data), ); } @@ -985,7 +1068,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T return $this->testValueObjectForEvents; } - $this->testValueObjectForEvents = Event\Code\TestMethod::fromTestCase($this); + $this->testValueObjectForEvents = Event\Code\TestMethodBuilder::fromTestCase($this); return $this->testValueObjectForEvents; } @@ -998,6 +1081,23 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T return $this->wasPrepared; } + final protected function registerComparator(Comparator $comparator): void + { + ComparatorFactory::getInstance()->register($comparator); + + Event\Facade::emitter()->testRegisteredComparator($comparator::class); + + $this->customComparators[] = $comparator; + } + + /** + * @psalm-param class-string $classOrInterface + */ + final protected function registerFailureType(string $classOrInterface): void + { + $this->failureTypes[$classOrInterface] = true; + } + /** * @throws AssertionFailedError * @throws Exception @@ -1035,6 +1135,8 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T * test is run. * * @throws Exception + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5214 */ protected function iniSet(string $varName, string $newValue): void { @@ -1047,8 +1149,8 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T sprintf( 'INI setting "%s" could not be set to "%s".', $varName, - $newValue - ) + $newValue, + ), ); } } @@ -1058,6 +1160,8 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T * resets the locale to its original value after the test is run. * * @throws Exception + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5216 */ protected function setLocale(mixed ...$arguments): void { @@ -1083,47 +1187,11 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T throw new Exception( 'The locale functionality is not implemented on your platform, ' . 'the specified locale does not exist or the category name is ' . - 'invalid.' + 'invalid.', ); } } - /** - * Creates a test stub for the specified interface or class. - * - * @psalm-template RealInstanceType of object - * - * @psalm-param class-string $originalClassName - * - * @psalm-return Stub&RealInstanceType - * - * @throws \PHPUnit\Framework\MockObject\Exception - * @throws InvalidArgumentException - * @throws NoPreviousThrowableException - */ - protected function createStub(string $originalClassName): Stub - { - $stub = $this->createMockObject($originalClassName, false); - - Event\Facade::emitter()->testCreatedStub($originalClassName); - - return $stub; - } - - /** - * @psalm-param list $interfaces - * - * @throws \PHPUnit\Framework\MockObject\Exception - */ - protected function createStubForIntersectionOfInterfaces(array $interfaces): Stub - { - $stub = $this->getMockObjectGenerator()->getMockForInterfaces($interfaces); - - Event\Facade::emitter()->testCreatedStubForIntersectionOfInterfaces($interfaces); - - return $stub; - } - /** * Creates a mock object for the specified interface or class. * @@ -1139,7 +1207,19 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T */ protected function createMock(string $originalClassName): MockObject { - $mock = $this->createMockObject($originalClassName); + $mock = (new MockGenerator)->testDouble( + $originalClassName, + true, + callOriginalConstructor: false, + callOriginalClone: false, + cloneArguments: false, + allowMockingUnknownTypes: false, + ); + + assert($mock instanceof $originalClassName); + assert($mock instanceof MockObject); + + $this->registerMockObject($mock); Event\Facade::emitter()->testCreatedMockObject($originalClassName); @@ -1153,7 +1233,11 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T */ protected function createMockForIntersectionOfInterfaces(array $interfaces): MockObject { - $mock = $this->getMockObjectGenerator()->getMockForInterfaces($interfaces); + $mock = (new MockGenerator)->testDoubleForInterfaceIntersection($interfaces, true); + + assert($mock instanceof MockObject); + + $this->registerMockObject($mock); Event\Facade::emitter()->testCreatedMockObjectForIntersectionOfInterfaces($interfaces); @@ -1175,7 +1259,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T */ protected function createConfiguredMock(string $originalClassName, array $configuration): MockObject { - $o = $this->createMockObject($originalClassName); + $o = $this->createMock($originalClassName); foreach ($configuration as $method => $return) { $o->method($method)->willReturn($return); @@ -1187,7 +1271,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T /** * Creates a partial mock object for the specified interface or class. * - * @psalm-param list $methods + * @psalm-param list $methods * * @psalm-template RealInstanceType of object * @@ -1210,7 +1294,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T Event\Facade::emitter()->testCreatedPartialMockObject( $originalClassName, - ...$methods + ...$methods, ); return $partialMock; @@ -1227,6 +1311,8 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T * * @throws \PHPUnit\Framework\MockObject\Exception * @throws InvalidArgumentException + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5240 */ protected function createTestProxy(string $originalClassName, array $constructorArguments = []): MockObject { @@ -1237,7 +1323,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T Event\Facade::emitter()->testCreatedTestProxy( $originalClassName, - $constructorArguments + $constructorArguments, ); return $testProxy; @@ -1256,10 +1342,12 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T * * @throws \PHPUnit\Framework\MockObject\Exception * @throws InvalidArgumentException + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5241 */ protected function getMockForAbstractClass(string $originalClassName, array $arguments = [], string $mockClassName = '', bool $callOriginalConstructor = true, bool $callOriginalClone = true, bool $callAutoload = true, array $mockedMethods = [], bool $cloneArguments = false): MockObject { - $mockObject = $this->getMockObjectGenerator()->getMockForAbstractClass( + $mockObject = (new MockGenerator)->mockObjectForAbstractClass( $originalClassName, $arguments, $mockClassName, @@ -1267,26 +1355,25 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T $callOriginalClone, $callAutoload, $mockedMethods, - $cloneArguments + $cloneArguments, ); $this->registerMockObject($mockObject); Event\Facade::emitter()->testCreatedMockObjectForAbstractClass($originalClassName); + assert($mockObject instanceof $originalClassName); + assert($mockObject instanceof MockObject); + return $mockObject; } /** * Creates a mock object based on the given WSDL file. * - * @psalm-template RealInstanceType of object - * - * @psalm-param class-string|string $originalClassName - * - * @psalm-return MockObject&RealInstanceType - * * @throws \PHPUnit\Framework\MockObject\Exception + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5242 */ protected function getMockFromWsdl(string $wsdlFile, string $originalClassName = '', string $mockClassName = '', array $methods = [], bool $callOriginalConstructor = true, array $options = []): MockObject { @@ -1297,23 +1384,24 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T if (!class_exists($originalClassName)) { eval( - $this->getMockObjectGenerator()->generateClassFromWsdl( + (new MockGenerator)->generateClassFromWsdl( $wsdlFile, $originalClassName, $methods, - $options + $options, ) ); } - $mockObject = $this->getMockObjectGenerator()->getMock( + $mockObject = (new MockGenerator)->testDouble( $originalClassName, + true, $methods, ['', $options], $mockClassName, $callOriginalConstructor, false, - false + false, ); Event\Facade::emitter()->testCreatedMockObjectFromWsdl( @@ -1322,9 +1410,11 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T $mockClassName, $methods, $callOriginalConstructor, - $options + $options, ); + assert($mockObject instanceof MockObject); + $this->registerMockObject($mockObject); return $mockObject; @@ -1339,10 +1429,12 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T * * @throws \PHPUnit\Framework\MockObject\Exception * @throws InvalidArgumentException + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5243 */ protected function getMockForTrait(string $traitName, array $arguments = [], string $mockClassName = '', bool $callOriginalConstructor = true, bool $callOriginalClone = true, bool $callAutoload = true, array $mockedMethods = [], bool $cloneArguments = false): MockObject { - $mockObject = $this->getMockObjectGenerator()->getMockForTrait( + $mockObject = (new MockGenerator)->mockObjectForTrait( $traitName, $arguments, $mockClassName, @@ -1350,7 +1442,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T $callOriginalClone, $callAutoload, $mockedMethods, - $cloneArguments + $cloneArguments, ); $this->registerMockObject($mockObject); @@ -1366,18 +1458,25 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T * @psalm-param trait-string $traitName * * @throws \PHPUnit\Framework\MockObject\Exception + * + * @deprecated https://github.com/sebastianbergmann/phpunit/issues/5244 */ protected function getObjectForTrait(string $traitName, array $arguments = [], string $traitClassName = '', bool $callOriginalConstructor = true, bool $callOriginalClone = true, bool $callAutoload = true): object { - return $this->getMockObjectGenerator()->getObjectForTrait( + return (new MockGenerator)->objectForTrait( $traitName, $traitClassName, $callAutoload, $callOriginalConstructor, - $arguments + $arguments, ); } + protected function transformException(Throwable $t): Throwable + { + return $t; + } + /** * This method is called when a test method did not execute successfully. * @@ -1399,7 +1498,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T } $mockObject->__phpunit_verify( - $this->shouldInvocationMockerBeReset($mockObject) + $this->shouldInvocationMockerBeReset($mockObject), ); } } @@ -1415,7 +1514,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T $missingRequirements = (new Requirements)->requirementsNotSatisfiedFor( static::class, - $this->name + $this->name, ); if (!empty($missingRequirements)) { @@ -1471,7 +1570,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T if ($passedTests->isGreaterThan($dependencyTarget, $this->size())) { Event\Facade::emitter()->testConsideredRisky( $this->valueObjectForEvents(), - 'This test depends on a test that is larger than itself' + 'This test depends on a test that is larger than itself', ); return false; @@ -1508,7 +1607,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T if ($dependency !== null) { $message = sprintf( 'This test depends on "%s" which does not exist', - $dependency->targetIsClass() ? $dependency->getTargetClassName() : $dependency->getTarget() + $dependency->targetIsClass() ? $dependency->getTargetClassName() : $dependency->getTarget(), ); } @@ -1516,7 +1615,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T Event\Facade::emitter()->testErrored( $this->valueObjectForEvents(), - Event\Code\Throwable::from($exception) + Event\Code\ThrowableBuilder::from($exception), ); $this->status = TestStatus::error($message); @@ -1529,29 +1628,17 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T { $message = sprintf( 'This test depends on "%s" to pass', - $dependency->getTarget() + $dependency->getTarget(), ); Event\Facade::emitter()->testSkipped( $this->valueObjectForEvents(), - $message + $message, ); $this->status = TestStatus::skipped($message); } - /** - * Get the mock object generator, creating it if it doesn't exist. - */ - private function getMockObjectGenerator(): MockGenerator - { - if ($this->mockObjectGenerator === null) { - $this->mockObjectGenerator = new MockGenerator; - } - - return $this->mockObjectGenerator; - } - private function startOutputBuffering(): void { ob_start(); @@ -1565,16 +1652,22 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T */ private function stopOutputBuffering(): bool { - if (ob_get_level() !== $this->outputBufferingLevel) { + $bufferingLevel = ob_get_level(); + + if ($bufferingLevel !== $this->outputBufferingLevel) { + if ($bufferingLevel > $this->outputBufferingLevel) { + $message = 'Test code or tested code did not close its own output buffers'; + } else { + $message = 'Test code or tested code closed output buffers other than its own'; + } + while (ob_get_level() >= $this->outputBufferingLevel) { ob_end_clean(); } - $message = 'Test code or tested code did not (only) close its own output buffers'; - Event\Facade::emitter()->testConsideredRisky( $this->valueObjectForEvents(), - $message + $message, ); $this->status = TestStatus::risky($message); @@ -1614,7 +1707,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T if (ConfigurationRegistry::get()->beStrictAboutChangesToGlobalState()) { $this->compareGlobalStateSnapshots( $this->snapshot, - $this->createGlobalStateSnapshot($this->backupGlobals === true) + $this->createGlobalStateSnapshot($this->backupGlobals === true), ); } @@ -1665,7 +1758,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T false, false, false, - false + false, ); } @@ -1680,13 +1773,13 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T $this->compareGlobalStateSnapshotPart( $before->globalVariables(), $after->globalVariables(), - "--- Global variables before the test\n+++ Global variables after the test\n" + "--- Global variables before the test\n+++ Global variables after the test\n", ); $this->compareGlobalStateSnapshotPart( $before->superGlobalVariables(), $after->superGlobalVariables(), - "--- Super-global variables before the test\n+++ Super-global variables after the test\n" + "--- Super-global variables before the test\n+++ Super-global variables after the test\n", ); } @@ -1694,7 +1787,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T $this->compareGlobalStateSnapshotPart( $before->staticProperties(), $after->staticProperties(), - "--- Static properties before the test\n+++ Static properties after the test\n" + "--- Static properties before the test\n+++ Static properties after the test\n", ); } } @@ -1714,9 +1807,9 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T trim( $differ->diff( $exporter->export($before), - $exporter->export($after) - ) - ) + $exporter->export($after), + ), + ), ); } } @@ -1736,6 +1829,9 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T return !in_array($mock, $enumerator->enumerate($this->testResult), true); } + /** + * @deprecated + */ private function registerMockObjectsFromTestArguments(array $testArguments, Context $context = new Context): void { if ($this->registerMockObjectsFromTestArgumentsRecursively) { @@ -1745,17 +1841,18 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T } } } else { - foreach ($testArguments as $testArgument) { + foreach ($testArguments as &$testArgument) { if ($testArgument instanceof MockObject) { $testArgument = Cloner::clone($testArgument); $this->registerMockObject($testArgument); } elseif (is_array($testArgument) && !$context->contains($testArgument)) { + $testArgumentCopy = $testArgument; $context->add($testArgument); $this->registerMockObjectsFromTestArguments( - $testArgument, - $context + $testArgumentCopy, + $context, ); } } @@ -1814,7 +1911,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T throw new Exception( $e->getMessage(), $e->getCode(), - $e + $e, ); } // @codeCoverageIgnoreEnd @@ -1865,31 +1962,10 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T } return TestUtil::isTestMethod( - $class->getMethod($methodName) + $class->getMethod($methodName), ); } - /** - * @psalm-template RealInstanceType of object - * - * @psalm-param class-string $originalClassName - * - * @psalm-return MockObject&RealInstanceType - * - * @throws \PHPUnit\Framework\MockObject\Exception - * @throws InvalidArgumentException - * @throws NoPreviousThrowableException - */ - private function createMockObject(string $originalClassName, bool $register = true): MockObject - { - return $this->getMockBuilder($originalClassName) - ->disableOriginalConstructor() - ->disableOriginalClone() - ->disableArgumentCloning() - ->disallowMockingUnknownTypes() - ->getMock($register); - } - /** * @throws Exception * @throws ExpectationFailedException @@ -1902,78 +1978,96 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T if ($this->outputExpectedRegex !== null) { $this->assertMatchesRegularExpression($this->outputExpectedRegex, $this->output); } elseif ($this->outputExpectedString !== null) { - $this->assertEquals($this->outputExpectedString, $this->output); + $this->assertSame($this->outputExpectedString, $this->output); } } catch (ExpectationFailedException $e) { $this->status = TestStatus::failure($e->getMessage()); Event\Facade::emitter()->testFailed( $this->valueObjectForEvents(), - Event\Code\Throwable::from($e), - Event\Code\ComparisonFailure::from($e) + Event\Code\ThrowableBuilder::from($e), + Event\Code\ComparisonFailureBuilder::from($e), ); throw $e; } } + /** + * @throws Throwable + */ private function invokeBeforeClassHookMethods(array $hookMethods, Event\Emitter $emitter): void { $this->invokeHookMethods( $hookMethods['beforeClass'], $emitter, 'testBeforeFirstTestMethodCalled', - 'testBeforeFirstTestMethodFinished' + 'testBeforeFirstTestMethodFinished', ); } + /** + * @throws Throwable + */ private function invokeBeforeTestHookMethods(array $hookMethods, Event\Emitter $emitter): void { $this->invokeHookMethods( $hookMethods['before'], $emitter, 'testBeforeTestMethodCalled', - 'testBeforeTestMethodFinished' + 'testBeforeTestMethodFinished', ); } + /** + * @throws Throwable + */ private function invokePreConditionHookMethods(array $hookMethods, Event\Emitter $emitter): void { $this->invokeHookMethods( $hookMethods['preCondition'], $emitter, 'testPreConditionCalled', - 'testPreConditionFinished' + 'testPreConditionFinished', ); } + /** + * @throws Throwable + */ private function invokePostConditionHookMethods(array $hookMethods, Event\Emitter $emitter): void { $this->invokeHookMethods( $hookMethods['postCondition'], $emitter, 'testPostConditionCalled', - 'testPostConditionFinished' + 'testPostConditionFinished', ); } + /** + * @throws Throwable + */ private function invokeAfterTestHookMethods(array $hookMethods, Event\Emitter $emitter): void { $this->invokeHookMethods( $hookMethods['after'], $emitter, 'testAfterTestMethodCalled', - 'testAfterTestMethodFinished' + 'testAfterTestMethodFinished', ); } + /** + * @throws Throwable + */ private function invokeAfterClassHookMethods(array $hookMethods, Event\Emitter $emitter): void { $this->invokeHookMethods( $hookMethods['afterClass'], $emitter, 'testAfterLastTestMethodCalled', - 'testAfterLastTestMethodFinished' + 'testAfterLastTestMethodFinished', ); } @@ -1981,6 +2075,8 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T * @psalm-param list $hookMethods * @psalm-param 'testBeforeFirstTestMethodCalled'|'testBeforeTestMethodCalled'|'testPreConditionCalled'|'testPostConditionCalled'|'testAfterTestMethodCalled'|'testAfterLastTestMethodCalled' $calledMethod * @psalm-param 'testBeforeFirstTestMethodFinished'|'testBeforeTestMethodFinished'|'testPreConditionFinished'|'testPostConditionFinished'|'testAfterTestMethodFinished'|'testAfterLastTestMethodFinished' $finishedMethod + * + * @throws Throwable */ private function invokeHookMethods(array $hookMethods, Event\Emitter $emitter, string $calledMethod, string $finishedMethod): void { @@ -1991,11 +2087,14 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T continue; } - $this->{$methodName}(); + try { + $this->{$methodName}(); + } catch (Throwable $t) { + } $methodInvoked = new Event\Code\ClassMethod( static::class, - $methodName + $methodName, ); $emitter->{$calledMethod}( @@ -2004,6 +2103,10 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T ); $methodsInvoked[] = $methodInvoked; + + if (isset($t)) { + break; + } } if (!empty($methodsInvoked)) { @@ -2012,6 +2115,10 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T ...$methodsInvoked ); } + + if (isset($t)) { + throw $t; + } } private function methodDoesNotExistOrIsDeclaredInTestCase(string $methodName): bool @@ -2025,43 +2132,41 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T /** * @throws ExpectationFailedException */ - private function verifyExceptionExpectations(Throwable|\Exception $exception): void + private function verifyExceptionExpectations(\Exception|Throwable $exception): void { if ($this->expectedException !== null) { $this->assertThat( $exception, new ExceptionConstraint( - $this->expectedException - ) + $this->expectedException, + ), ); } if ($this->expectedExceptionMessage !== null) { $this->assertThat( $exception->getMessage(), - new MessageIsOrContains( - 'exception', - $this->expectedExceptionMessage - ) + new ExceptionMessageIsOrContains( + $this->expectedExceptionMessage, + ), ); } if ($this->expectedExceptionMessageRegExp !== null) { $this->assertThat( $exception->getMessage(), - new MessageMatchesRegularExpression( - 'exception', - $this->expectedExceptionMessageRegExp - ) + new ExceptionMessageMatchesRegularExpression( + $this->expectedExceptionMessageRegExp, + ), ); } if ($this->expectedExceptionCode !== null) { $this->assertThat( - $exception, + $exception->getCode(), new ExceptionCode( - $this->expectedExceptionCode - ) + $this->expectedExceptionCode, + ), ); } } @@ -2074,7 +2179,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T if ($this->expectedException !== null) { $this->assertThat( null, - new ExceptionConstraint($this->expectedException) + new ExceptionConstraint($this->expectedException), ); } elseif ($this->expectedExceptionMessage !== null) { $this->numberOfAssertionsPerformed++; @@ -2082,8 +2187,8 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T throw new AssertionFailedError( sprintf( 'Failed asserting that exception with message "%s" is thrown', - $this->expectedExceptionMessage - ) + $this->expectedExceptionMessage, + ), ); } elseif ($this->expectedExceptionMessageRegExp !== null) { $this->numberOfAssertionsPerformed++; @@ -2091,8 +2196,8 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T throw new AssertionFailedError( sprintf( 'Failed asserting that exception with message matching "%s" is thrown', - $this->expectedExceptionMessageRegExp - ) + $this->expectedExceptionMessageRegExp, + ), ); } elseif ($this->expectedExceptionCode !== null) { $this->numberOfAssertionsPerformed++; @@ -2100,9 +2205,98 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T throw new AssertionFailedError( sprintf( 'Failed asserting that exception with code "%s" is thrown', - $this->expectedExceptionCode - ) + $this->expectedExceptionCode, + ), ); } } + + private function isRegisteredFailure(Throwable $t): bool + { + foreach (array_keys($this->failureTypes) as $failureType) { + if ($t instanceof $failureType) { + return true; + } + } + + return false; + } + + /** + * @internal This method is not covered by the backward compatibility promise for PHPUnit + */ + private function hasExpectationOnOutput(): bool + { + return is_string($this->outputExpectedString) || is_string($this->outputExpectedRegex); + } + + /** + * Creates a test stub for the specified interface or class. + * + * @psalm-template RealInstanceType of object + * + * @psalm-param class-string $originalClassName + * + * @psalm-return Stub&RealInstanceType + * + * @throws \PHPUnit\Framework\MockObject\Exception + * @throws InvalidArgumentException + * @throws NoPreviousThrowableException + */ + protected static function createStub(string $originalClassName): Stub + { + $stub = (new MockGenerator)->testDouble( + $originalClassName, + true, + callOriginalConstructor: false, + callOriginalClone: false, + cloneArguments: false, + allowMockingUnknownTypes: false, + ); + + Event\Facade::emitter()->testCreatedStub($originalClassName); + + assert($stub instanceof $originalClassName); + assert($stub instanceof Stub); + + return $stub; + } + + /** + * @psalm-param list $interfaces + * + * @throws \PHPUnit\Framework\MockObject\Exception + */ + protected static function createStubForIntersectionOfInterfaces(array $interfaces): Stub + { + $stub = (new MockGenerator)->testDoubleForInterfaceIntersection($interfaces, false); + + Event\Facade::emitter()->testCreatedStubForIntersectionOfInterfaces($interfaces); + + return $stub; + } + + /** + * Creates (and configures) a test stub for the specified interface or class. + * + * @psalm-template RealInstanceType of object + * + * @psalm-param class-string $originalClassName + * + * @psalm-return Stub&RealInstanceType + * + * @throws \PHPUnit\Framework\MockObject\Exception + * @throws InvalidArgumentException + * @throws NoPreviousThrowableException + */ + final protected static function createConfiguredStub(string $originalClassName, array $configuration): Stub + { + $o = self::createStub($originalClassName); + + foreach ($configuration as $method => $return) { + $o->method($method)->willReturn($return); + } + + return $o; + } } diff --git a/vendor/phpunit/phpunit/src/Framework/TestRunner.php b/vendor/phpunit/phpunit/src/Framework/TestRunner.php index 4415fdac..e5f5b033 100644 --- a/vendor/phpunit/phpunit/src/Framework/TestRunner.php +++ b/vendor/phpunit/phpunit/src/Framework/TestRunner.php @@ -30,9 +30,9 @@ use PHPUnit\Event\TestData\NoDataSetFromDataProviderException; use PHPUnit\Metadata\Api\CodeCoverage as CodeCoverageMetadataApi; use PHPUnit\Metadata\Parser\Registry as MetadataRegistry; use PHPUnit\Runner\CodeCoverage; +use PHPUnit\Runner\ErrorHandler; use PHPUnit\TextUI\Configuration\Configuration; use PHPUnit\TextUI\Configuration\Registry as ConfigurationRegistry; -use PHPUnit\Util\ErrorHandler; use PHPUnit\Util\GlobalState; use PHPUnit\Util\PHP\AbstractPhpProcess; use ReflectionClass; @@ -75,7 +75,7 @@ final class TestRunner $shouldCodeCoverageBeCollected = (new CodeCoverageMetadataApi)->shouldCodeCoverageBeCollectedFor( $test::class, - $test->name() + $test->name(), ); $error = false; @@ -84,13 +84,15 @@ final class TestRunner $risky = false; $skipped = false; - ErrorHandler::instance()->enable(); + if ($this->shouldErrorHandlerBeUsed($test)) { + ErrorHandler::instance()->enable(); + } - $collectCodeCoverage = CodeCoverage::isActive() && + $collectCodeCoverage = CodeCoverage::instance()->isActive() && $shouldCodeCoverageBeCollected; if ($collectCodeCoverage) { - CodeCoverage::start($test); + CodeCoverage::instance()->start($test); } try { @@ -122,8 +124,8 @@ final class TestRunner '%s in %s:%s', $e->getMessage(), $frame['file'], - $frame['line'] - ) + $frame['line'], + ), ); } catch (Throwable $e) { $error = true; @@ -132,6 +134,7 @@ final class TestRunner $test->addToAssertionCount(Assert::getCount()); if ($this->configuration->reportUselessTests() && + !$test->doesNotPerformAssertions() && $test->numberOfAssertionsPerformed() === 0) { $risky = true; } @@ -141,7 +144,7 @@ final class TestRunner !$this->hasCoverageMetadata($test::class, $test->name())) { Event\Facade::emitter()->testConsideredRisky( $test->valueObjectForEvents(), - 'This test does not define a code coverage target but is expected to do so' + 'This test does not define a code coverage target but is expected to do so', ); $risky = true; @@ -156,33 +159,33 @@ final class TestRunner try { $linesToBeCovered = (new CodeCoverageMetadataApi)->linesToBeCovered( $test::class, - $test->name() + $test->name(), ); $linesToBeUsed = (new CodeCoverageMetadataApi)->linesToBeUsed( $test::class, - $test->name() + $test->name(), ); } catch (InvalidCoversTargetException $cce) { Event\Facade::emitter()->testTriggeredPhpunitWarning( $test->valueObjectForEvents(), - $cce->getMessage() + $cce->getMessage(), ); } } try { - CodeCoverage::stop( + CodeCoverage::instance()->stop( $append, $linesToBeCovered, - $linesToBeUsed + $linesToBeUsed, ); } catch (UnintentionallyCoveredCodeException $cce) { Event\Facade::emitter()->testConsideredRisky( $test->valueObjectForEvents(), 'This test executed code that is not listed as code to be covered or used:' . PHP_EOL . - $cce->getMessage() + $cce->getMessage(), ); } catch (OriginalCodeCoverageException $cce) { $error = true; @@ -193,23 +196,15 @@ final class TestRunner ErrorHandler::instance()->disable(); - if (isset($e)) { - if ($test->wasPrepared()) { - Event\Facade::emitter()->testFinished( - $test->valueObjectForEvents(), - $test->numberOfAssertionsPerformed() - ); - } - - return; - } - - if ($this->configuration->reportUselessTests() && + if (!$error && + !$incomplete && + !$skipped && + $this->configuration->reportUselessTests() && !$test->doesNotPerformAssertions() && $test->numberOfAssertionsPerformed() === 0) { Event\Facade::emitter()->testConsideredRisky( $test->valueObjectForEvents(), - 'This test did not perform any assertions' + 'This test did not perform any assertions', ); } @@ -218,26 +213,31 @@ final class TestRunner Event\Facade::emitter()->testConsideredRisky( $test->valueObjectForEvents(), sprintf( - 'This test is not expected to perform assertions but performed %d assertions', - $test->numberOfAssertionsPerformed() - ) + 'This test is not expected to perform assertions but performed %d assertion%s', + $test->numberOfAssertionsPerformed(), + $test->numberOfAssertionsPerformed() > 1 ? 's' : '', + ), ); } - if ($this->configuration->disallowTestOutput() && $test->hasOutput()) { + if ($test->hasUnexpectedOutput()) { + Event\Facade::emitter()->testPrintedUnexpectedOutput($test->output()); + } + + if ($this->configuration->disallowTestOutput() && $test->hasUnexpectedOutput()) { Event\Facade::emitter()->testConsideredRisky( $test->valueObjectForEvents(), sprintf( 'This test printed output: %s', - $test->output() - ) + $test->output(), + ), ); } if ($test->wasPrepared()) { Event\Facade::emitter()->testFinished( $test->valueObjectForEvents(), - $test->numberOfAssertionsPerformed() + $test->numberOfAssertionsPerformed(), ); } } @@ -258,11 +258,11 @@ final class TestRunner if ($runEntireClass) { $template = new Template( - __DIR__ . '/../Util/PHP/Template/TestCaseClass.tpl' + __DIR__ . '/../Util/PHP/Template/TestCaseClass.tpl', ); } else { $template = new Template( - __DIR__ . '/../Util/PHP/Template/TestCaseMethod.tpl' + __DIR__ . '/../Util/PHP/Template/TestCaseMethod.tpl', ); } @@ -283,7 +283,9 @@ final class TestRunner $iniSettings = GlobalState::getIniSettingsAsString(); } - $coverage = CodeCoverage::isActive() ? 'true' : 'false'; + $exportObjects = Event\Facade::emitter()->exportsObjects() ? 'true' : 'false'; + $coverage = CodeCoverage::instance()->isActive() ? 'true' : 'false'; + $linesToBeIgnored = var_export(CodeCoverage::instance()->linesToBeIgnored(), true); if (defined('PHPUNIT_COMPOSER_INSTALL')) { $composerAutoload = var_export(PHPUNIT_COMPOSER_INSTALL, true); @@ -303,14 +305,13 @@ final class TestRunner $includePath = var_export(get_include_path(), 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 . ".'"; - - $offset = hrtime(); - + $data = "'." . $data . ".'"; + $dataName = "'.(" . $dataName . ").'"; + $dependencyInput = "'." . $dependencyInput . ".'"; + $includePath = "'." . $includePath . ".'"; + $offset = hrtime(); $serializedConfiguration = $this->saveConfigurationForChildProcess(); + $processResultFile = tempnam(sys_get_temp_dir(), 'phpunit_'); $var = [ 'bootstrap' => $bootstrap, @@ -319,6 +320,7 @@ final class TestRunner 'filename' => $class->getFileName(), 'className' => $class->getName(), 'collectCodeCoverageInformation' => $coverage, + 'linesToBeIgnored' => $linesToBeIgnored, 'data' => $data, 'dataName' => $dataName, 'dependencyInput' => $dependencyInput, @@ -331,6 +333,8 @@ final class TestRunner 'offsetSeconds' => $offset[0], 'offsetNanoseconds' => $offset[1], 'serializedConfiguration' => $serializedConfiguration, + 'processResultFile' => $processResultFile, + 'exportObjects' => $exportObjects, ]; if (!$runEntireClass) { @@ -340,13 +344,14 @@ final class TestRunner $template->setVar($var); $php = AbstractPhpProcess::factory(); - $php->runTestJob($template->render(), $test); + $php->runTestJob($template->render(), $test, $processResultFile); @unlink($serializedConfiguration); } /** * @psalm-param class-string $className + * @psalm-param non-empty-string $methodName */ private function hasCoverageMetadata(string $className, string $methodName): bool { @@ -428,8 +433,8 @@ final class TestRunner sprintf( 'This test was aborted after %d second%s', $_timeout, - $_timeout !== 1 ? 's' : '' - ) + $_timeout !== 1 ? 's' : '', + ), ); return true; @@ -443,7 +448,7 @@ final class TestRunner */ private function saveConfigurationForChildProcess(): string { - $path = tempnam(sys_get_temp_dir(), 'PHPUnit'); + $path = tempnam(sys_get_temp_dir(), 'phpunit_'); if (!$path) { throw new ProcessIsolationException; @@ -455,4 +460,13 @@ final class TestRunner return $path; } + + private function shouldErrorHandlerBeUsed(TestCase $test): bool + { + if (MetadataRegistry::parser()->forMethod($test::class, $test->name())->isWithoutErrorHandler()->isNotEmpty()) { + return false; + } + + return true; + } } diff --git a/vendor/phpunit/phpunit/src/Framework/TestSuite.php b/vendor/phpunit/phpunit/src/Framework/TestSuite.php index ac5bb8c1..15a144cf 100644 --- a/vendor/phpunit/phpunit/src/Framework/TestSuite.php +++ b/vendor/phpunit/phpunit/src/Framework/TestSuite.php @@ -19,6 +19,7 @@ use function count; use function implode; use function is_callable; use function is_file; +use function is_subclass_of; use function sprintf; use function str_ends_with; use function str_starts_with; @@ -26,7 +27,6 @@ use function trim; use Iterator; use IteratorAggregate; use PHPUnit\Event; -use PHPUnit\Event\Code\TestDox; use PHPUnit\Event\Code\TestMethod; use PHPUnit\Event\NoPreviousThrowableException; use PHPUnit\Metadata\Api\Dependencies; @@ -38,8 +38,7 @@ use PHPUnit\Runner\Exception as RunnerException; use PHPUnit\Runner\Filter\Factory; use PHPUnit\Runner\PhptTestCase; use PHPUnit\Runner\TestSuiteLoader; -use PHPUnit\TestRunner\TestResult\Facade; -use PHPUnit\TextUI\Configuration\Registry; +use PHPUnit\TestRunner\TestResult\Facade as TestResultFacade; use PHPUnit\Util\Filter; use PHPUnit\Util\Reflection; use PHPUnit\Util\Test as TestUtil; @@ -55,13 +54,16 @@ use Throwable; */ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test { - protected string $name = ''; + /** + * @psalm-var non-empty-string + */ + private string $name; /** * @psalm-var array> */ - protected array $groups = []; - protected ?array $requiredTests = null; + private array $groups = []; + private ?array $requiredTests = null; /** * @psalm-var list @@ -69,20 +71,12 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test private array $tests = []; private ?array $providedTests = null; private ?Factory $iteratorFilter = null; - private readonly bool $stopOnError; - private readonly bool $stopOnFailure; - private readonly bool $stopOnWarning; - private readonly bool $stopOnRisky; - private readonly bool $stopOnIncomplete; - private readonly bool $stopOnSkipped; - private readonly bool $stopOnDefect; - public static function empty(string $name = null): static + /** + * @psalm-param non-empty-string $name + */ + public static function empty(string $name): static { - if ($name === null) { - $name = ''; - } - return new static($name); } @@ -108,14 +102,14 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test Event\Facade::emitter()->testRunnerTriggeredWarning( sprintf( 'Class "%s" has no public constructor.', - $class->getName() - ) + $class->getName(), + ), ); return $testSuite; } - foreach ((new Reflection)->publicMethodsInTestClass($class) as $method) { + foreach (Reflection::publicMethodsInTestClass($class) as $method) { if ($method->getDeclaringClass()->getName() === Assert::class) { continue; } @@ -135,27 +129,20 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test Event\Facade::emitter()->testRunnerTriggeredWarning( sprintf( 'No tests found in class "%s".', - $class->getName() - ) + $class->getName(), + ), ); } return $testSuite; } + /** + * @psalm-param non-empty-string $name + */ final private function __construct(string $name) { $this->name = $name; - - $configuration = Registry::get(); - - $this->stopOnError = $configuration->stopOnError(); - $this->stopOnFailure = $configuration->stopOnFailure(); - $this->stopOnWarning = $configuration->stopOnWarning(); - $this->stopOnRisky = $configuration->stopOnRisky(); - $this->stopOnIncomplete = $configuration->stopOnIncomplete(); - $this->stopOnSkipped = $configuration->stopOnSkipped(); - $this->stopOnDefect = $configuration->stopOnDefect(); } /** @@ -163,7 +150,7 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test */ public function toString(): string { - return $this->getName(); + return $this->name(); } /** @@ -178,7 +165,7 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test $this->clearCaches(); if ($test instanceof self && empty($groups)) { - $groups = $test->getGroups(); + $groups = $test->groups(); } if ($this->containsOnlyVirtualGroups($groups)) { @@ -210,8 +197,8 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test throw new Exception( sprintf( 'Class %s is abstract', - $testClass->getName() - ) + $testClass->getName(), + ), ); } @@ -220,8 +207,8 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test sprintf( 'Class %s is not a subclass of %s', $testClass->getName(), - TestCase::class - ) + TestCase::class, + ), ); } @@ -245,7 +232,7 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test $this->addTest(new PhptTestCase($filename)); } catch (RunnerException $e) { Event\Facade::emitter()->testRunnerTriggeredWarning( - $e->getMessage() + $e->getMessage(), ); } @@ -254,11 +241,11 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test try { $this->addTestSuite( - (new TestSuiteLoader)->load($filename) + (new TestSuiteLoader)->load($filename), ); } catch (RunnerException $e) { Event\Facade::emitter()->testRunnerTriggeredWarning( - $e->getMessage() + $e->getMessage(), ); } } @@ -295,9 +282,9 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test } /** - * Returns the name of the suite. + * @psalm-return non-empty-string */ - public function getName(): string + public function name(): string { return $this->name; } @@ -307,15 +294,15 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test * * @psalm-return list */ - public function getGroups(): array + public function groups(): array { return array_map( 'strval', - array_keys($this->groups) + array_keys($this->groups), ); } - public function getGroupDetails(): array + public function groupDetails(): array { return $this->groups; } @@ -334,113 +321,26 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test return; } - /** @psalm-var class-string $className */ - $className = $this->name; - $hookMethods = (new HookMethods)->hookMethods($className); - $emitter = Event\Facade::emitter(); - $testSuiteValueObjectForEvents = Event\TestSuite\TestSuite::fromTestSuite($this); + $testSuiteValueObjectForEvents = Event\TestSuite\TestSuiteBuilder::from($this); $emitter->testSuiteStarted($testSuiteValueObjectForEvents); - $methodsCalledBeforeFirstTest = []; - - if (class_exists($this->name, false)) { - try { - foreach ($hookMethods['beforeClass'] as $beforeClassMethod) { - if ($this->methodDoesNotExistOrIsDeclaredInTestCase($beforeClassMethod)) { - continue; - } - - if ($missingRequirements = (new Requirements)->requirementsNotSatisfiedFor($this->name, $beforeClassMethod)) { - $this->markTestSuiteSkipped(implode(PHP_EOL, $missingRequirements)); - } - - $methodCalledBeforeFirstTest = new Event\Code\ClassMethod( - $this->name, - $beforeClassMethod - ); - - $emitter->testBeforeFirstTestMethodCalled( - $this->name, - $methodCalledBeforeFirstTest - ); - - $methodsCalledBeforeFirstTest[] = $methodCalledBeforeFirstTest; - - call_user_func([$this->name, $beforeClassMethod]); - } - } catch (SkippedTestSuiteError) { - return; - } catch (Throwable $t) { - assert(isset($methodCalledBeforeFirstTest)); - - $emitter->testBeforeFirstTestMethodErrored( - $this->name, - $methodCalledBeforeFirstTest, - Event\Code\Throwable::from($t) - ); - - if (!empty($methodsCalledBeforeFirstTest)) { - $emitter->testBeforeFirstTestMethodFinished( - $this->name, - ...$methodsCalledBeforeFirstTest - ); - } - - return; - } - } - - if (!empty($methodsCalledBeforeFirstTest)) { - $emitter->testBeforeFirstTestMethodFinished( - $this->name, - ...$methodsCalledBeforeFirstTest - ); + if (!$this->invokeMethodsBeforeFirstTest($emitter, $testSuiteValueObjectForEvents)) { + return; } foreach ($this as $test) { - if ($this->shouldStop()) { + if (TestResultFacade::shouldStop()) { + $emitter->testRunnerExecutionAborted(); + break; } $test->run(); } - $methodsCalledAfterLastTest = []; - - if (class_exists($this->name, false)) { - foreach ($hookMethods['afterClass'] as $afterClassMethod) { - if ($this->methodDoesNotExistOrIsDeclaredInTestCase($afterClassMethod)) { - continue; - } - - try { - call_user_func([$this->name, $afterClassMethod]); - - $methodCalledAfterLastTest = new Event\Code\ClassMethod( - $this->name, - $afterClassMethod - ); - - $emitter->testAfterLastTestMethodCalled( - $this->name, - $methodCalledAfterLastTest - ); - - $methodsCalledAfterLastTest[] = $methodCalledAfterLastTest; - } catch (Throwable) { - // @todo - } - } - } - - if (!empty($methodsCalledAfterLastTest)) { - $emitter->testAfterLastTestMethodFinished( - $this->name, - ...$methodsCalledAfterLastTest - ); - } + $this->invokeMethodsAfterLastTest($emitter); $emitter->testSuiteFinished($testSuiteValueObjectForEvents); } @@ -514,10 +414,9 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test foreach ($this->tests as $test) { if (!($test instanceof Reorderable)) { - // @codeCoverageIgnoreStart continue; - // @codeCoverageIgnoreEnd } + $this->providedTests = ExecutionOrderDependency::mergeUnique($this->providedTests, $test->provides()); } } @@ -535,13 +434,12 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test foreach ($this->tests as $test) { if (!($test instanceof Reorderable)) { - // @codeCoverageIgnoreStart continue; - // @codeCoverageIgnoreEnd } + $this->requiredTests = ExecutionOrderDependency::mergeUnique( ExecutionOrderDependency::filterInvalid($this->requiredTests), - $test->requires() + $test->requires(), ); } @@ -553,7 +451,15 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test public function sortId(): string { - return $this->getName() . '::class'; + return $this->name() . '::class'; + } + + /** + * @psalm-assert-if-true class-string $this->name + */ + public function isForTestClass(): bool + { + return class_exists($this->name, false) && is_subclass_of($this->name, TestCase::class); } /** @@ -576,19 +482,19 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test $methodName, $class->getFileName(), $method->getStartLine(), - TestDox::fromClassNameAndMethodName( + Event\Code\TestDoxBuilder::fromClassNameAndMethodName( $className, - $methodName + $methodName, ), MetadataCollection::fromArray([]), - Event\TestData\TestDataCollection::fromArray([]) + Event\TestData\TestDataCollection::fromArray([]), ), sprintf( "The data provider specified for %s::%s is invalid\n%s", $className, $methodName, - $this->throwableToString($e) - ) + $this->throwableToString($e), + ), ); return; @@ -596,13 +502,13 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test if ($test instanceof TestCase || $test instanceof DataProviderTestSuite) { $test->setDependencies( - Dependencies::dependencies($class->getName(), $methodName) + Dependencies::dependencies($class->getName(), $methodName), ); } $this->addTest( $test, - (new Groups)->groups($class->getName(), $methodName) + (new Groups)->groups($class->getName(), $methodName), ); } @@ -631,35 +537,6 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test $reflector->getMethod($methodName)->getDeclaringClass()->getName() === TestCase::class; } - private function shouldStop(): bool - { - if (($this->stopOnDefect || $this->stopOnError) && Facade::hasTestErroredEvents()) { - return true; - } - - if (($this->stopOnDefect || $this->stopOnFailure) && Facade::hasTestFailedEvents()) { - return true; - } - - if (($this->stopOnDefect || $this->stopOnWarning) && Facade::hasWarningEvents()) { - return true; - } - - if (($this->stopOnDefect || $this->stopOnRisky) && Facade::hasTestConsideredRiskyEvents()) { - return true; - } - - if ($this->stopOnSkipped && Facade::hasTestSkippedEvents()) { - return true; - } - - if ($this->stopOnIncomplete && Facade::hasTestMarkedIncompleteEvents()) { - return true; - } - - return false; - } - /** * @throws Exception */ @@ -675,7 +552,7 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test return sprintf( "%s\n%s", $message, - Filter::getFilteredStacktrace($t) + Filter::getFilteredStacktrace($t), ); } @@ -683,7 +560,123 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test "%s: %s\n%s", $t::class, $message, - Filter::getFilteredStacktrace($t) + Filter::getFilteredStacktrace($t), ); } + + /** + * @throws Exception + * @throws NoPreviousThrowableException + */ + private function invokeMethodsBeforeFirstTest(Event\Emitter $emitter, Event\TestSuite\TestSuite $testSuiteValueObjectForEvents): bool + { + if (!$this->isForTestClass()) { + return true; + } + + $methodsCalledBeforeFirstTest = []; + + $beforeClassMethods = (new HookMethods)->hookMethods($this->name)['beforeClass']; + + try { + foreach ($beforeClassMethods as $beforeClassMethod) { + if ($this->methodDoesNotExistOrIsDeclaredInTestCase($beforeClassMethod)) { + continue; + } + + if ($missingRequirements = (new Requirements)->requirementsNotSatisfiedFor($this->name, $beforeClassMethod)) { + $this->markTestSuiteSkipped(implode(PHP_EOL, $missingRequirements)); + } + + $methodCalledBeforeFirstTest = new Event\Code\ClassMethod( + $this->name, + $beforeClassMethod, + ); + + $emitter->testBeforeFirstTestMethodCalled( + $this->name, + $methodCalledBeforeFirstTest, + ); + + $methodsCalledBeforeFirstTest[] = $methodCalledBeforeFirstTest; + + call_user_func([$this->name, $beforeClassMethod]); + } + } catch (SkippedTest|SkippedTestSuiteError $e) { + $emitter->testSuiteSkipped( + $testSuiteValueObjectForEvents, + $e->getMessage(), + ); + + return false; + } catch (Throwable $t) { + assert(isset($methodCalledBeforeFirstTest)); + + $emitter->testBeforeFirstTestMethodErrored( + $this->name, + $methodCalledBeforeFirstTest, + Event\Code\ThrowableBuilder::from($t), + ); + + if (!empty($methodsCalledBeforeFirstTest)) { + $emitter->testBeforeFirstTestMethodFinished( + $this->name, + ...$methodsCalledBeforeFirstTest, + ); + } + + return false; + } + + if (!empty($methodsCalledBeforeFirstTest)) { + $emitter->testBeforeFirstTestMethodFinished( + $this->name, + ...$methodsCalledBeforeFirstTest, + ); + } + + return true; + } + + private function invokeMethodsAfterLastTest(Event\Emitter $emitter): void + { + if (!$this->isForTestClass()) { + return; + } + + $methodsCalledAfterLastTest = []; + + $afterClassMethods = (new HookMethods)->hookMethods($this->name)['afterClass']; + + foreach ($afterClassMethods as $afterClassMethod) { + if ($this->methodDoesNotExistOrIsDeclaredInTestCase($afterClassMethod)) { + continue; + } + + try { + call_user_func([$this->name, $afterClassMethod]); + + $methodCalledAfterLastTest = new Event\Code\ClassMethod( + $this->name, + $afterClassMethod, + ); + + $emitter->testAfterLastTestMethodCalled( + $this->name, + $methodCalledAfterLastTest, + ); + + $methodsCalledAfterLastTest[] = $methodCalledAfterLastTest; + } catch (Throwable) { + // @todo + } + } + + if (!empty($methodsCalledAfterLastTest)) { + $emitter->testAfterLastTestMethodFinished( + $this->name, + ...$methodsCalledAfterLastTest, + ); + } + } } diff --git a/vendor/phpunit/phpunit/src/Framework/TestSuiteIterator.php b/vendor/phpunit/phpunit/src/Framework/TestSuiteIterator.php index 5b783ba3..32ee7c6d 100644 --- a/vendor/phpunit/phpunit/src/Framework/TestSuiteIterator.php +++ b/vendor/phpunit/phpunit/src/Framework/TestSuiteIterator.php @@ -64,7 +64,7 @@ final class TestSuiteIterator implements RecursiveIterator { if (!$this->hasChildren()) { throw new NoChildTestSuiteException( - 'The current item is not a TestSuite instance and therefore does not have any children.' + 'The current item is not a TestSuite instance and therefore does not have any children.', ); } diff --git a/vendor/phpunit/phpunit/src/Logging/EventLogger.php b/vendor/phpunit/phpunit/src/Logging/EventLogger.php index 786907d7..559fb5ec 100644 --- a/vendor/phpunit/phpunit/src/Logging/EventLogger.php +++ b/vendor/phpunit/phpunit/src/Logging/EventLogger.php @@ -43,7 +43,7 @@ final class EventLogger implements Tracer file_put_contents( $this->path, $telemetryInfo . implode($indentation, $lines) . PHP_EOL, - FILE_APPEND | LOCK_EX + FILE_APPEND | LOCK_EX, ); } diff --git a/vendor/phpunit/phpunit/src/Logging/JUnit/JunitXmlLogger.php b/vendor/phpunit/phpunit/src/Logging/JUnit/JunitXmlLogger.php index 86ba8638..188de2eb 100644 --- a/vendor/phpunit/phpunit/src/Logging/JUnit/JunitXmlLogger.php +++ b/vendor/phpunit/phpunit/src/Logging/JUnit/JunitXmlLogger.php @@ -11,7 +11,6 @@ namespace PHPUnit\Logging\JUnit; use function assert; use function basename; -use function class_exists; use function is_int; use function sprintf; use function str_replace; @@ -20,15 +19,16 @@ use DOMDocument; use DOMElement; use PHPUnit\Event\Code\Test; use PHPUnit\Event\Code\TestMethod; -use PHPUnit\Event\Code\Throwable; use PHPUnit\Event\EventFacadeIsSealedException; use PHPUnit\Event\Facade; use PHPUnit\Event\InvalidArgumentException; use PHPUnit\Event\Telemetry\HRTime; +use PHPUnit\Event\Telemetry\Info; use PHPUnit\Event\Test\Errored; use PHPUnit\Event\Test\Failed; use PHPUnit\Event\Test\Finished; use PHPUnit\Event\Test\MarkedIncomplete; +use PHPUnit\Event\Test\PreparationStarted; use PHPUnit\Event\Test\Prepared; use PHPUnit\Event\Test\Skipped; use PHPUnit\Event\TestData\NoDataSetFromDataProviderException; @@ -36,8 +36,6 @@ use PHPUnit\Event\TestSuite\Started; use PHPUnit\Event\UnknownSubscriberTypeException; use PHPUnit\TextUI\Output\Printer; use PHPUnit\Util\Xml; -use ReflectionClass; -use ReflectionException; /** * @internal This class is not covered by the backward compatibility promise for PHPUnit @@ -85,16 +83,18 @@ final class JunitXmlLogger private int $testSuiteLevel = 0; private ?DOMElement $currentTestCase = null; private ?HRTime $time = null; + private bool $prepared = false; + private bool $preparationFailed = false; /** * @throws EventFacadeIsSealedException * @throws UnknownSubscriberTypeException */ - public function __construct(Printer $printer) + public function __construct(Printer $printer, Facade $facade) { $this->printer = $printer; - $this->registerSubscribers(); + $this->registerSubscribers($facade); $this->createDocument(); } @@ -110,13 +110,8 @@ final class JunitXmlLogger $testSuite = $this->document->createElement('testsuite'); $testSuite->setAttribute('name', $event->testSuite()->name()); - if (class_exists($event->testSuite()->name(), false)) { - try { - $class = new ReflectionClass($event->testSuite()->name()); - - $testSuite->setAttribute('file', $class->getFileName()); - } catch (ReflectionException) { - } + if ($event->testSuite()->isForTestClass()) { + $testSuite->setAttribute('file', $event->testSuite()->file()); } if ($this->testSuiteLevel > 0) { @@ -139,41 +134,41 @@ final class JunitXmlLogger { $this->testSuites[$this->testSuiteLevel]->setAttribute( 'tests', - (string) $this->testSuiteTests[$this->testSuiteLevel] + (string) $this->testSuiteTests[$this->testSuiteLevel], ); $this->testSuites[$this->testSuiteLevel]->setAttribute( 'assertions', - (string) $this->testSuiteAssertions[$this->testSuiteLevel] + (string) $this->testSuiteAssertions[$this->testSuiteLevel], ); $this->testSuites[$this->testSuiteLevel]->setAttribute( 'errors', - (string) $this->testSuiteErrors[$this->testSuiteLevel] + (string) $this->testSuiteErrors[$this->testSuiteLevel], ); $this->testSuites[$this->testSuiteLevel]->setAttribute( 'failures', - (string) $this->testSuiteFailures[$this->testSuiteLevel] + (string) $this->testSuiteFailures[$this->testSuiteLevel], ); $this->testSuites[$this->testSuiteLevel]->setAttribute( 'skipped', - (string) $this->testSuiteSkipped[$this->testSuiteLevel] + (string) $this->testSuiteSkipped[$this->testSuiteLevel], ); $this->testSuites[$this->testSuiteLevel]->setAttribute( 'time', - sprintf('%F', $this->testSuiteTimes[$this->testSuiteLevel]) + sprintf('%F', $this->testSuiteTimes[$this->testSuiteLevel]), ); if ($this->testSuiteLevel > 1) { - $this->testSuiteTests[$this->testSuiteLevel - 1] += $this->testSuiteTests[$this->testSuiteLevel]; + $this->testSuiteTests[$this->testSuiteLevel - 1] += $this->testSuiteTests[$this->testSuiteLevel]; $this->testSuiteAssertions[$this->testSuiteLevel - 1] += $this->testSuiteAssertions[$this->testSuiteLevel]; - $this->testSuiteErrors[$this->testSuiteLevel - 1] += $this->testSuiteErrors[$this->testSuiteLevel]; - $this->testSuiteFailures[$this->testSuiteLevel - 1] += $this->testSuiteFailures[$this->testSuiteLevel]; - $this->testSuiteSkipped[$this->testSuiteLevel - 1] += $this->testSuiteSkipped[$this->testSuiteLevel]; - $this->testSuiteTimes[$this->testSuiteLevel - 1] += $this->testSuiteTimes[$this->testSuiteLevel]; + $this->testSuiteErrors[$this->testSuiteLevel - 1] += $this->testSuiteErrors[$this->testSuiteLevel]; + $this->testSuiteFailures[$this->testSuiteLevel - 1] += $this->testSuiteFailures[$this->testSuiteLevel]; + $this->testSuiteSkipped[$this->testSuiteLevel - 1] += $this->testSuiteSkipped[$this->testSuiteLevel]; + $this->testSuiteTimes[$this->testSuiteLevel - 1] += $this->testSuiteTimes[$this->testSuiteLevel]; } $this->testSuiteLevel--; @@ -183,42 +178,39 @@ final class JunitXmlLogger * @throws InvalidArgumentException * @throws NoDataSetFromDataProviderException */ - public function testPrepared(Prepared $event): void + public function testPreparationStarted(PreparationStarted $event): void { $this->createTestCase($event); } + /** + * @throws InvalidArgumentException + * @throws NoDataSetFromDataProviderException + */ + public function testPreparationFailed(): void + { + $this->preparationFailed = true; + } + + /** + * @throws InvalidArgumentException + * @throws NoDataSetFromDataProviderException + */ + public function testPrepared(): void + { + $this->prepared = true; + } + /** * @throws InvalidArgumentException */ public function testFinished(Finished $event): void { - assert($this->currentTestCase !== null); - assert($this->time !== null); + if ($this->preparationFailed) { + return; + } - $time = $event->telemetryInfo()->time()->duration($this->time)->asFloat(); - - $this->testSuiteAssertions[$this->testSuiteLevel] += $event->numberOfAssertionsPerformed(); - - $this->currentTestCase->setAttribute( - 'assertions', - (string) $event->numberOfAssertionsPerformed() - ); - - $this->currentTestCase->setAttribute( - 'time', - sprintf('%F', $time) - ); - - $this->testSuites[$this->testSuiteLevel]->appendChild( - $this->currentTestCase - ); - - $this->testSuiteTests[$this->testSuiteLevel]++; - $this->testSuiteTimes[$this->testSuiteLevel] += $time; - - $this->currentTestCase = null; - $this->time = null; + $this->handleFinish($event->telemetryInfo(), $event->numberOfAssertionsPerformed()); } /** @@ -245,7 +237,7 @@ final class JunitXmlLogger */ public function testErrored(Errored $event): void { - $this->handleFault($event->test(), $event->throwable(), 'error'); + $this->handleFault($event, 'error'); $this->testSuiteErrors[$this->testSuiteLevel]++; } @@ -256,20 +248,56 @@ final class JunitXmlLogger */ public function testFailed(Failed $event): void { - $this->handleFault($event->test(), $event->throwable(), 'failure'); + $this->handleFault($event, 'failure'); $this->testSuiteFailures[$this->testSuiteLevel]++; } + /** + * @throws InvalidArgumentException + */ + private function handleFinish(Info $telemetryInfo, int $numberOfAssertionsPerformed): void + { + assert($this->currentTestCase !== null); + assert($this->time !== null); + + $time = $telemetryInfo->time()->duration($this->time)->asFloat(); + + $this->testSuiteAssertions[$this->testSuiteLevel] += $numberOfAssertionsPerformed; + + $this->currentTestCase->setAttribute( + 'assertions', + (string) $numberOfAssertionsPerformed, + ); + + $this->currentTestCase->setAttribute( + 'time', + sprintf('%F', $time), + ); + + $this->testSuites[$this->testSuiteLevel]->appendChild( + $this->currentTestCase, + ); + + $this->testSuiteTests[$this->testSuiteLevel]++; + $this->testSuiteTimes[$this->testSuiteLevel] += $time; + + $this->currentTestCase = null; + $this->time = null; + $this->prepared = false; + } + /** * @throws EventFacadeIsSealedException * @throws UnknownSubscriberTypeException */ - private function registerSubscribers(): void + private function registerSubscribers(Facade $facade): void { - Facade::registerSubscribers( + $facade->registerSubscribers( new TestSuiteStartedSubscriber($this), new TestSuiteFinishedSubscriber($this), + new TestPreparationStartedSubscriber($this), + new TestPreparationFailedSubscriber($this), new TestPreparedSubscriber($this), new TestFinishedSubscriber($this), new TestErroredSubscriber($this), @@ -293,25 +321,34 @@ final class JunitXmlLogger * @throws InvalidArgumentException * @throws NoDataSetFromDataProviderException */ - private function handleFault(Test $test, Throwable $throwable, string $type): void + private function handleFault(Errored|Failed $event, string $type): void { + if (!$this->prepared) { + $this->createTestCase($event); + } + assert($this->currentTestCase !== null); - $buffer = $this->testAsString($test); + $buffer = $this->testAsString($event->test()); + $throwable = $event->throwable(); $buffer .= trim( $throwable->description() . PHP_EOL . - $throwable->stackTrace() + $throwable->stackTrace(), ); $fault = $this->document->createElement( $type, - Xml::prepareString($buffer) + Xml::prepareString($buffer), ); $fault->setAttribute('type', $throwable->className()); $this->currentTestCase->appendChild($fault); + + if (!$this->prepared) { + $this->handleFinish($event->telemetryInfo(), 0); + } } /** @@ -320,7 +357,7 @@ final class JunitXmlLogger */ private function handleIncompleteOrSkipped(MarkedIncomplete|Skipped $event): void { - if ($this->currentTestCase === null) { + if (!$this->prepared) { $this->createTestCase($event); } @@ -331,6 +368,10 @@ final class JunitXmlLogger $this->currentTestCase->appendChild($skipped); $this->testSuiteSkipped[$this->testSuiteLevel]++; + + if (!$this->prepared) { + $this->handleFinish($event->telemetryInfo(), 0); + } } /** @@ -375,22 +416,24 @@ final class JunitXmlLogger return sprintf( '%s with data set #%d', $test->methodName(), - $dataSetName + $dataSetName, ); } return sprintf( '%s with data set "%s"', $test->methodName(), - $dataSetName + $dataSetName, ); } /** * @throws InvalidArgumentException * @throws NoDataSetFromDataProviderException + * + * @psalm-assert !null $this->currentTestCase */ - private function createTestCase(Prepared|MarkedIncomplete|Skipped $event): void + private function createTestCase(Errored|Failed|MarkedIncomplete|PreparationStarted|Prepared|Skipped $event): void { $testCase = $this->document->createElement('testcase'); diff --git a/vendor/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestPreparationFailedSubscriber.php b/vendor/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestPreparationFailedSubscriber.php new file mode 100644 index 00000000..a8ae3cf9 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestPreparationFailedSubscriber.php @@ -0,0 +1,30 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Logging\JUnit; + +use PHPUnit\Event\InvalidArgumentException; +use PHPUnit\Event\Test\PreparationFailed; +use PHPUnit\Event\Test\PreparationFailedSubscriber; +use PHPUnit\Event\TestData\NoDataSetFromDataProviderException; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class TestPreparationFailedSubscriber extends Subscriber implements PreparationFailedSubscriber +{ + /** + * @throws InvalidArgumentException + * @throws NoDataSetFromDataProviderException + */ + public function notify(PreparationFailed $event): void + { + $this->logger()->testPreparationFailed(); + } +} diff --git a/vendor/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestPreparationStartedSubscriber.php b/vendor/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestPreparationStartedSubscriber.php new file mode 100644 index 00000000..0799bb50 --- /dev/null +++ b/vendor/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestPreparationStartedSubscriber.php @@ -0,0 +1,30 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace PHPUnit\Logging\JUnit; + +use PHPUnit\Event\InvalidArgumentException; +use PHPUnit\Event\Test\PreparationStarted; +use PHPUnit\Event\Test\PreparationStartedSubscriber; +use PHPUnit\Event\TestData\NoDataSetFromDataProviderException; + +/** + * @internal This class is not covered by the backward compatibility promise for PHPUnit + */ +final class TestPreparationStartedSubscriber extends Subscriber implements PreparationStartedSubscriber +{ + /** + * @throws InvalidArgumentException + * @throws NoDataSetFromDataProviderException + */ + public function notify(PreparationStarted $event): void + { + $this->logger()->testPreparationStarted($event); + } +} diff --git a/vendor/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestPreparedSubscriber.php b/vendor/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestPreparedSubscriber.php index 98027dc9..aee8e47f 100644 --- a/vendor/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestPreparedSubscriber.php +++ b/vendor/phpunit/phpunit/src/Logging/JUnit/Subscriber/TestPreparedSubscriber.php @@ -25,6 +25,6 @@ final class TestPreparedSubscriber extends Subscriber implements PreparedSubscri */ public function notify(Prepared $event): void { - $this->logger()->testPrepared($event); + $this->logger()->testPrepared(); } } diff --git a/vendor/phpunit/phpunit/src/Logging/TeamCity/TeamCityLogger.php b/vendor/phpunit/phpunit/src/Logging/TeamCity/TeamCityLogger.php index b37a99d8..203e2337 100644 --- a/vendor/phpunit/phpunit/src/Logging/TeamCity/TeamCityLogger.php +++ b/vendor/phpunit/phpunit/src/Logging/TeamCity/TeamCityLogger.php @@ -53,11 +53,11 @@ final class TeamCityLogger * @throws EventFacadeIsSealedException * @throws UnknownSubscriberTypeException */ - public function __construct(Printer $printer) + public function __construct(Printer $printer, Facade $facade) { $this->printer = $printer; - $this->registerSubscribers(); + $this->registerSubscribers($facade); $this->setFlowId(); } @@ -70,14 +70,10 @@ final class TeamCityLogger $this->writeMessage( 'testCount', - ['count' => $testSuite->count()] + ['count' => $testSuite->count()], ); } - if ($testSuite->isWithName() && $testSuite->name() === '') { - return; - } - $parameters = ['name' => $testSuite->name()]; if ($testSuite->isForTestClass()) { @@ -86,7 +82,7 @@ final class TeamCityLogger $parameters['locationHint'] = sprintf( 'php_qn://%s::\\%s', $testSuite->file(), - $testSuite->name() + $testSuite->name(), ); } elseif ($testSuite->isForTestMethodWithDataProvider()) { assert($testSuite instanceof TestSuiteForTestMethodWithDataProvider); @@ -94,7 +90,7 @@ final class TeamCityLogger $parameters['locationHint'] = sprintf( 'php_qn://%s::\\%s', $testSuite->file(), - $testSuite->name() + $testSuite->name(), ); $parameters['name'] = $testSuite->methodName(); @@ -107,10 +103,6 @@ final class TeamCityLogger { $testSuite = $event->testSuite(); - if ($testSuite->isWithName() && $testSuite->name() === '') { - return; - } - $parameters = ['name' => $testSuite->name()]; if ($testSuite->isForTestMethodWithDataProvider()) { @@ -137,7 +129,7 @@ final class TeamCityLogger 'php_qn://%s::\\%s::%s', $test->file(), $test->className(), - $test->methodName() + $test->methodName(), ); } @@ -162,7 +154,7 @@ final class TeamCityLogger 'message' => $event->throwable()->message(), 'details' => $this->details($event->throwable()), 'duration' => $this->duration($event), - ] + ], ); } @@ -201,7 +193,7 @@ final class TeamCityLogger 'message' => $this->message($event->throwable()), 'details' => $this->details($event->throwable()), 'duration' => $this->duration($event), - ] + ], ); } @@ -246,7 +238,7 @@ final class TeamCityLogger 'message' => $event->message(), 'details' => '', 'duration' => $this->duration($event), - ] + ], ); } @@ -260,7 +252,7 @@ final class TeamCityLogger [ 'name' => $event->test()->name(), 'duration' => $this->duration($event), - ] + ], ); $this->time = null; @@ -275,9 +267,9 @@ final class TeamCityLogger * @throws EventFacadeIsSealedException * @throws UnknownSubscriberTypeException */ - private function registerSubscribers(): void + private function registerSubscribers(Facade $facade): void { - Facade::registerSubscribers( + $facade->registerSubscribers( new TestSuiteStartedSubscriber($this), new TestSuiteFinishedSubscriber($this), new TestPreparedSubscriber($this), @@ -303,8 +295,8 @@ final class TeamCityLogger $this->printer->print( sprintf( "\n##teamcity[%s", - $eventName - ) + $eventName, + ), ); if ($this->flowId !== null) { @@ -316,8 +308,8 @@ final class TeamCityLogger sprintf( " %s='%s'", $key, - $this->escape((string) $value) - ) + $this->escape((string) $value), + ), ); } @@ -341,7 +333,7 @@ final class TeamCityLogger return str_replace( ['|', "'", "\n", "\r", ']', '['], ['||', "|'", '|n', '|r', '|]', '|['], - $string + $string, ); } @@ -370,7 +362,7 @@ final class TeamCityLogger $buffer .= sprintf( "\nCaused by\n%s\n%s", $throwable->description(), - $throwable->stackTrace() + $throwable->stackTrace(), ); } diff --git a/vendor/phpunit/phpunit/src/Logging/TestDox/HtmlRenderer.php b/vendor/phpunit/phpunit/src/Logging/TestDox/HtmlRenderer.php index ca4e5a35..fd65a309 100644 --- a/vendor/phpunit/phpunit/src/Logging/TestDox/HtmlRenderer.php +++ b/vendor/phpunit/phpunit/src/Logging/TestDox/HtmlRenderer.php @@ -28,6 +28,7 @@ final class HtmlRenderer